Part of #297 (Bootstrap mode).
Rom's steer on #297: treat Claude Code as a black box and wrap the user prompt, rather than injecting via --append-system-prompt / --system-prompt. Instructions carried in the prompt itself outweigh "contextual" system-prompt text the agent is tempted to skip.
#448 shipped bootstrap as a forceful system-prompt preamble (BOOTSTRAP_PREAMBLE prepended in systemPromptBlock). This reworks the mechanism to Rom's approach:
- New
wrapBootstrapPrompt(userPrompt): rewords the intent into instructions (analyze the request, showMarkdown() the analysis + plan, then await approval; no code before approval). Original request rides at the end unchanged.
- Direct-prompt path (
runPrompt): wrap the first user prompt when bootstrap is on.
- Build path (
runFramework): a short JSON-compatible bootstrap note on the architect turn; the existing plan-approval gate already stops for the plan.
- Drop the system-prompt preamble path (
BOOTSTRAP_PREAMBLE, the bootstrap branch of systemPromptBlock).
- CLI
--bootstrap flag + daemon flag mapping unchanged.
Verify: a real claude -p run in an empty dir with the wrapped prompt stops for a plan (no files written).
Part of #297 (Bootstrap mode).
Rom's steer on #297: treat Claude Code as a black box and wrap the user prompt, rather than injecting via
--append-system-prompt/--system-prompt. Instructions carried in the prompt itself outweigh "contextual" system-prompt text the agent is tempted to skip.#448 shipped bootstrap as a forceful system-prompt preamble (
BOOTSTRAP_PREAMBLEprepended insystemPromptBlock). This reworks the mechanism to Rom's approach:wrapBootstrapPrompt(userPrompt): rewords the intent into instructions (analyze the request, showMarkdown() the analysis + plan, then await approval; no code before approval). Original request rides at the end unchanged.runPrompt): wrap the first user prompt when bootstrap is on.runFramework): a short JSON-compatible bootstrap note on the architect turn; the existing plan-approval gate already stops for the plan.BOOTSTRAP_PREAMBLE, thebootstrapbranch ofsystemPromptBlock).--bootstrapflag + daemon flag mapping unchanged.Verify: a real
claude -prun in an empty dir with the wrapped prompt stops for a plan (no files written).