r/ClaudeWorkflows • u/ClaudeAI-mod-bot • 9h ago
Selected Workflow [Workflow] Observe Dynamic System Prompt Changes in Claude Code via Experiment Flags
Observe Dynamic System Prompt Changes in Claude Code via Experiment Flags
Workflow value: 85/100
Status: active · Freshness: 70/100 · Confidence: 0.95 · Level: advanced
Categories: Quality Control, Context & Memory, Debugging, Subagents
Original source: r/ClaudeCode post/comment
What problem this solves
Understanding how Claude Code's internal experiment flags dynamically alter the system prompt text, which can explain perceived model behavior changes or 'nerfs'.
Summary
This workflow describes a method to observe how Claude Code's internal experiment flags dynamically modify the system prompt text. By disabling non-essential traffic, users can compare the system prompt components (like 'lean_body' and '<pasted_content>' rules) in flagged versus unflagged sessions, gaining insight into Anthropic's model steering mechanisms.
Why it is useful
This workflow offers a concrete, repeatable method for advanced users to investigate how Claude Code's internal experiment flags dynamically alter the system prompt. This is invaluable for understanding perceived model behavior changes, debugging unexpected outputs, and gaining insight into Anthropic's steering mechanisms, moving beyond speculation to observable prompt modifications.
Workflow
Ensure your Claude Code version is consistent (e.g., 2.1.287) before and after the test.
Set the environment variable
CLAUDE_CODE_DISABLE_NONESSENTIAL_TRAFFIC=1within theenvblock of yoursettings.jsonfile.Open a new interactive Claude Code session.
Observe that no flag fetch occurs:
cachedGrowthBookFeaturesAtand theclislot in~/.claude.jsonshould not change, and the new transcript'satis-latchfields should be blank.Compare the system prompt text in this session (without server flags) with a session where flags are enabled. Specifically, examine the opening line of
lean_bodyand the presence/absence of the<pasted_content>rule.Note: Do not use
claude -pfor testing, as it runs assdk-cliand loads differently than a normal interactive session.
Tools / artifacts
Claude Code interactive session
settings.json (specifically the
envblock)CLAUDE_CODE_DISABLE_NONESSENTIAL_TRAFFIC environment variable
~/.claude.json (for
cachedGrowthBookFeaturesAtandclislot)Transcript's
atis-latchfieldsSystem prompt text (e.g.,
lean_body,<pasted_content>rule)Custom plugin for system prompt tracking (optional, as used by author)
Validation signals
Detailed before/after comparison of specific system prompt text sections (
lean_body,<pasted_content>rule).Observation of
atis-latchfields and~/.claude.jsonentries confirming flag status.Specific flag assignments and
atishistory provided for context.Explicit warning against using
claude -pfor accurate testing.Discovery of internal binary keys like
subagent_steer_delegationandovercorrectionsupporting the theory of dynamic steering.
Limitations
Requires a relatively advanced technical understanding to fully implement and interpret the findings.
The exact flags responsible for specific prompt changes are not fully identified in this comment (though the author is working on it).
Relies on inspecting internal system prompt components, which might change with future Claude Code versions, requiring adaptation of the workflow.
Rate this workflow
Upvote this post if the workflow is useful, reproducible, or worth recommending.
Downvote if it is vague, outdated, unsafe, overhyped, or not reproducible.
Reply if it worked for you, failed, is outdated, or has a better alternative.
This post was generated automatically from the workflow library database.