{"version":"2.1.326","anchor":"oversized-prompt-replaced-by-headtail-with-note-gated-by-t","canonical_anchor":"prompt-as-file-long-pasted-prompts-can-be-written-to-a-file","heading":"Experiments for prompts too long to send: save to a file, or cut to head and tail","tier":"soon","area":"Agents","scope":"individual","heads_up":false,"url":"https:\/\/changelogs.core-directive.com\/v\/2.1.326\/e\/oversized-prompt-replaced-by-headtail-with-note-gated-by-t","release_url":"https:\/\/changelogs.core-directive.com\/v\/2.1.326","markdown":"### Experiments for prompts too long to send: save to a file, or cut to head and tail\n\nTwo switched-off experiments handle oversized prompts, by saving them to a file the model can read or by trimming them to their start and end with a note\n\n**What**\n\nClaude Code has new code for prompts that are too long to send to the model. It sits behind two experiment switches, settings Anthropic's server can turn on remotely.\n\n- Prompt as a file: when `tengu_paper_heron` is true, Claude Code writes the largest oversized prompt you typed or pasted to a file and adds a `prompt_as_file` attachment giving the prompt's id, the file path and its length in characters. This only happens when a Read tool (the tool Claude uses to open files) is available, the session is allowed to do it, and the prompt is under a maximum size. Otherwise it records why it skipped: `no_read_tool`, `not_allowed` or `over_max_bytes`.\n\n- Head and tail: when `tengu_lucky_crane` is true, a message too long to send is cut down to its first and last characters, and a note tells the model what is missing. If the prompt was saved as a file, the note gives its path.\n\n- New names: `refused_prompt_note` and `prompt_as_file` were added to a list of event or notice types. A list of environment variables that includes `CLAUDE_CODE_USER_DELEGATED_SESSION` gained one more entry whose name could not be worked out.\n\nWhen these switches were read, the flag server returned off for both `tengu_paper_heron` and `tengu_lucky_crane`, for this site's account and for an anonymous account. Neither has been read under this release yet.\n\n**Why**\n\nIf turned on, a very long prompt would no longer simply fail to send: the model would get either a file to read or a shortened copy with a note explaining what was cut.\n\n- Flag `tengu_lucky_crane`: Not enough to say (read for one account on one subscription tier against v2.1.326; this account: no value returned, anonymous baseline: off, compiled default: off) These values were read against a different version of Claude Code, so treat them as the nearest reading available instead of one taken on this release.\n- Area: Agents\n- Names: `tengu_lucky_crane`\n- Tier: Nothing to try yet\n- Useful: 3\/5\n- Signal: 3\/5\n- Scope: individual\n- Heads-up: no\n- Present in the build but not switched on"}