[Bug] Auto-generated session titles ignore CLAUDE.md terminology rules (e.g. brand spelling) and no hook can correct them
Summary
The auto-generated session title ignores spelling and brand-name rules that are stated in CLAUDE.md, and there is no hook point to correct the title after it is generated.
Concrete case: my global ~/.claude/CLAUDE.md says, verbatim, Use "Runpod", never "RunPod". The model follows this in every reply. The session namer does not: it regularly produces sidebar titles like "RunPod keyword ranking strategies" and "RunPod sentiment reading missing" (4 of roughly 100 sessions in my desktop sidebar this week). The old stylization is what the model saw most in training, so without the instruction it defaults to it.
Why this happens (as far as I can tell)
The title generator runs as a separate summarization call that does not load CLAUDE.md, memory, or output-style instructions. So project and user rules about terminology never reach it.
Why a hook can't fix it today
- No hook event fires after the title is generated, so a
RunPod->Runpodfind/replace on the produced title is not possible. hookSpecificOutput.sessionTitleis only honored onSessionStart,Setup, andSubagentStart.SessionStartruns before any conversation content exists, so a hook there can only stamp a filesystem-derived name (cwd, git branch). For anyone working from a home directory or a monorepo, that is a worse title than the AI one.UserPromptSubmitandStopdo not acceptsessionTitle.
Requested fix (either would do)
- Have the namer include CLAUDE.md (at least the user-level and project-level files) in its context, or a designated subset such as a
## Session titlessection or asessionTitleInstructionsfield insettings.json. - Or add a post-naming hook event (e.g.
SessionTitleGenerated) whosehookSpecificOutput.sessionTitlereplaces the generated title, so users can enforce terminology themselves.
Related but different: #83455 asks for a configurable naming format (kebab-case etc). This issue is about the namer not honoring content rules that the rest of the session already follows.
Environment
- Claude Code 2.1.261, macOS 25.6.0 (Darwin), desktop app (Code tab) and CLI
- Reproduces with any brand or product name whose canonical casing differs from the common training-data form.
Workaround
/rename or set_session_title per offending session. Works, but it is manual and recurs with every new session.