Commit e793e9f
fix: Add Identity section to CLAUDE.md template with principal/DA names
CLAUDE.md.template uses {DAIDENTITY.NAME} for the assistant's name in
output format lines, but never includes {PRINCIPAL.NAME} (the user's
name). This means the generated CLAUDE.md tells the LLM the assistant's
name but not the user's name.
In setups where the assistant's name appears in system paths, project
names, or OS usernames, the LLM can mistake the assistant's name for
the user's identity — leading to the AI addressing the user by the
wrong name.
Add an Identity section between Subagent Defaults and Critical Rules
that explicitly states both names. BuildCLAUDE.ts already resolves
{PRINCIPAL.NAME} from settings.json, so this just needs the template
reference.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>1 parent 301d541 commit e793e9f
2 files changed
Lines changed: 18 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
47 | 47 | | |
48 | 48 | | |
49 | 49 | | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
50 | 59 | | |
51 | 60 | | |
52 | 61 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
47 | 47 | | |
48 | 48 | | |
49 | 49 | | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
50 | 59 | | |
51 | 60 | | |
52 | 61 | | |
| |||
0 commit comments