AI DevelopmentFramework8 min readPublished September 2, 2026

“The block is bound to a different conversation

Agent Frameworks That Rewrite History Now Break on Fable 5.1

Claude Fable 5.1 checks that nothing before a thinking block has changed since the block was produced. Most agent frameworks shorten conversations by changing exactly that. This census reads ten frameworks’ own context-management docs, records the mechanism each uses, and says which ones trip the check and what the fix is.

DA
Digital Applied Team
Senior strategists · Published Sep 2, 2026
PublishedSep 2, 2026
Read time8 min
As ofSep 3, 2026
Frameworks in the census
10
read from each project’s current context-management docs
That rewrite history in a way the check rejects
6
by default or in their documented compaction path
Enforced for accounts created on or after
Aug 31
2026, 00:00 UTC; older accounts record the mismatch only
Client-side shapes that are safe
1 of 3
replace everything with one summary; the other two need thinking stripped

When Claude Fable 5.1 shipped on September 1, 2026, the third of its breaking changes was a rule about conversation history: each thinking block the model produces is valid only against the system prompt, the tools array and every message that preceded it. Send the block back after any of those changed and, where the check is enforced, the API returns a 400: “Invalid `signature` in `thinking` block. The block is bound to a different conversation.”

That rule collides with how agent frameworks keep long sessions inside a context window. Trimming the oldest turns, deleting old tool results, summarising early history behind a kept tail of recent turns, and refreshing the system prompt each request are the standard tools of the trade, and every one of them changes the prefix. Our launch-day post listed the change; this census applies it framework by framework, using each project’s current documentation as the source, so a team can find its own row rather than reading the migration guide against its own code base at 2am.

Key takeaways
  1. 01
    Six of ten frameworks shorten history in a way the check rejects.LangChain/LangGraph, Vercel AI SDK, OpenClaw, Mastra, Semantic Kernel and Agno all trim or summarise on the client by default or in their documented path; Pydantic AI’s documented shape is safe but its processors can be misused. Anthropic’s own SDKs and Claude Code are exempt because they keep the prefix.
  2. 02
    The dangerous shape is the popular one: keep recent turns behind a summary.Anthropic names three client-side compaction shapes. Replacing the whole history with one summary is safe. Keeping a verbatim tail, or swapping a summary in later, invalidates every thinking block in the tail unless those blocks are stripped or drop_block is set.
  3. 03
    Framework authors will not see it; their users on new keys will.The check is enforced for accounts created on or after August 31, 2026, 00:00 UTC, and recorded but not enforced for older ones. A maintainer testing on a year-old key gets no 400. Anthropic’s advice to tool authors is to set prefix_mismatch_behavior explicitly so you see what new users see.
  4. 04
    The fixes are the same ones that keep the prompt cache warm.Server-side compaction and context editing do not count as edits. Mid-conversation system messages replace rebuilding system or tools. Every fix in the table also preserves prompt-cache hits that an edited history would lose.

01The ruleWhat the check compares.

Anthropic’s preserved-thinking guide states three conditions for a thinking block to be accepted on a later request. The model must be the same or newer, which is the one-way binding our downgrade post covered. Nothing before the block may have changed: the top-level system prompt, the set of tools, and every message before it. And the chain of earlier thinking blocks must be unbroken; each block records the one before it, so removing a block from the middle invalidates every block after it, while removing blocks from the front is allowed.

The migration guide then lists the patterns that fail. Editing, reordering or removing earlier turns, including deleting old tool results and snipping turns from the middle. Client-side compaction that keeps recent turns and their thinking blocks verbatim behind a summary, including background compaction that swaps the summary in a few turns later. Injecting content you do not persist, such as a per-turn reminder appended after tool results and removed next request. Rebuilding the system prompt or the tools array between requests, for example to update the date or add a tool. And an image or document URL that serves different bytes later. The patterns that keep working are append-only histories, removing thinking blocks oldest-first, changing request parameters outside system, tools and messages, and server-side compaction or context editing, which “don’t count as edits, because the check compares the conversation as you sent it.”

Two exemptions worth knowing

Claude Mythos 5.1, the same model with looser safeguards, does not run the conversation check at all; edits restart its prompt cache but do not invalidate its blocks. And Anthropic states that Claude Code, claude.ai, Claude Managed Agents and the Claude Agent SDK already keep the prefix intact, so the check applies only to code that builds the messages array itself.

02The datasetThe framework census.

Each row below records the history-shortening mechanism a framework documents, the shape it produces in Anthropic’s terms, whether that shape trips the check, and the fix. “Breaks” is a reading of the documented mechanism against Anthropic’s stated rules, not an observed failure: we did not run each framework against the API, and a framework may have shipped a Claude-specific path since its docs were read on September 3, 2026.

Agent frameworks and their documented context-management mechanisms, read against Claude Fable 5.1’s conversation check as described in Anthropic’s migration guide and preserved-thinking guide. Docs read September 3, 2026. “Keep-tail” means recent turns are retained verbatim behind a summary.
FrameworkDocumented mechanismShapeAgainst the checkFix
Hand-rolled loop (the baseline)Whatever the code does: sliding windows, deleting old tool results, refreshing the date in the system prompt, adding a tool mid-sessionAny edit before a thinking blockBreaks if it edits; fine if append-onlyRun the three-step check in Anthropic’s guide; freeze system and tools; move changes to mid-conversation system messages
LangChain / LangGraphtrim_messages middleware and RemoveMessage / REMOVE_ALL_MESSAGES to cut oldest turns; delete_messages; SummarizationMiddleware replaces earlier messages with a summaryFront trim and keep-tail summaryBreaks on the kept tailStrip thinking blocks from turns kept behind the summary, or send drop_block; prefer Anthropic server-side compaction
Vercel AI SDKprepareStep returns a new messages array that becomes the base for later steps; pruneMessages removes selected messages; Anthropic provider sends reasoning back by default (sendReasoning: true)Arbitrary client-side rewriteBreaks if pruned mid-historyPrune whole thinking blocks oldest-first only, or replace the whole history with one summary; set drop_block in production
OpenClawClient-side compaction keeps a recent tail verbatim (keepRecentTokens, default 20,000) behind a summary; auto-compaction on context pressure; can also replay a provider-returned compacted windowKeep-tail compactionBreaks on the kept tailStrip thinking from the retained tail or set drop_block; use the provider-side compacted window where the provider offers one
MastraMemory processors (TokenLimiter, ToolCallFilter) filter and trim messages; Observational Memory replaces raw history with an observation log carried in the system messageFront trim; system prompt rewritten between requestsBreaks on both pathsCarry observations as an appended mid-conversation system message rather than editing system; trim thinking blocks oldest-first
Pydantic AIProcessHistory history processors summarise or filter messages before each request (the docs’ example returns a summary plus the last message); client-supplied CompactionParts are keptSimple compaction or full filterFine if the summary replaces everything; breaks if the tail keeps thinkingUse the documented summary-plus-last-message shape, which carries no thinking, or server-side compaction blocks
Semantic KernelChatHistoryTruncationReducer drops oldest messages; ChatHistorySummarizationReducer summarises removed messages and adds the summary back as one messageFront trim and keep-tail summaryBreaks on the kept tailStrip thinking from retained messages after a reduce, or set drop_block
Agnoadd_history_to_context with num_history_runs / num_history_messages caps: earlier runs fall out of the window by countFront trim by countBreaks when the window slidesKeep the window fixed for a session, or drop thinking blocks oldest-first before the cut
OpenAI Agents SDKOpenAIResponsesCompactionSession calls responses.compact on OpenAI’s server; session.pop_item removes items client-sideServer-side on OpenAI; client edits via pop_itemNot applicable to Claude blocks unless routed through a third-party model adapterIf routing Claude through it, treat pop_item as a history edit
Claude Agent SDK, Claude Code, Managed AgentsAnthropic-managed history; the migration guide states these already keep the prefix intactAppend-only with server-side compactionFineNone required

One framework is missing on purpose. CrewAI’s current memory documentation describes a unified memory store that saves and retrieves facts with an LLM; it does not document how the crew loop trims or rewrites the message array sent to the model, so we could not classify it from the docs and have not guessed. It will get a row when the mechanism is documented or when we have run it. The same census shape we used for redirect validation on fetch tools in August applies here: the row is only as good as the source it names.

03The mechanicsThree compaction shapes.

The migration guide’s most useful paragraph for framework authors is the one that sorts client-side compaction into three shapes and says which survive. It is worth reading in the framework’s own terms, because most of the rows above are one of these three.

Shape
Simple compaction
Replace everything with one summary

The whole history becomes one summary message plus the new user turn, and nothing else is replayed. No thinking blocks are carried over, so nothing fails. Anthropic recommends this shape and says Claude models are trained on long-horizon tasks with it and that it performs comparably to more elaborate schemes for most workloads. Pydantic AI’s documented example is this shape.

Safe
Shape
Keep-tail compaction
Summary, then recent turns verbatim

The most common framework design: LangGraph’s summarisation, OpenClaw’s keepRecentTokens tail, Semantic Kernel’s summarisation reducer. The retained turns carry thinking produced against the full history, which now sits behind a summary, so every block in the tail fails. Fix: strip thinking and redacted_thinking from the kept turns (text and tool calls can stay), or set prefix_mismatch_behavior to drop_block.

Breaks unless stripped
Shape
Background compaction
Summary built off the critical path, swapped in later

Every turn produced between building the summary and swapping it in carries thinking that predates the swap. Anthropic’s instruction is to send drop_block on every request still carrying pre-swap blocks, or to strip them using the input_transformations list on the first post-swap response, or to compact synchronously.

Breaks unless handled

One pattern has no client-side fix at all: snipping individual turns out of the middle of the transcript, which invalidates every later block whatever else you do. Anthropic’s alternatives are a mid-conversation system message for the instruction change you were making, or server-side context editing for selective removal. Both keep earlier turns byte-identical, which is also what keeps the prompt cache warm, and the guide is explicit that an integration that invalidates prior thinking on every request “restarts the prompt cache each time, which can raise cost per task.” Our cache-first agent architecture post arrived at the same append-only design from the cost side.

04EnforcementWho sees the error, and when.

The check is enforced for API accounts created on or after August 31, 2026, 00:00 UTC, on the Claude API and on cloud platforms alike. For older accounts the API records the mismatch but takes no action unless the request sets thinking.block_binding.prefix_mismatch_behavior, which opts into enforcement. Anthropic says it plans to enforce the check for every account on future models. The consequence for framework maintainers is stated plainly in the guide: “your key is probably on an older account, and your users on new ones hit the check before you do.”

Two details change how you handle the failure. The error is permanent for that request body, so a retry loop does not clear it; the options are to strip the thinking blocks from the history and retry once, or to send the thinking-binding-controls-2026-08-01 beta header with prefix_mismatch_behavior set to drop_block, which drops the mismatched block and every block after it, succeeds, and reports each drop in an input_transformations array with reason prefix_binding_mismatch. Dropped blocks are not billed. The same array reports model_binding_mismatch after a model switch, which is a different event and not a bug in your code. The token-counting endpoint runs the same check.

05PracticeHow to test your own loop.

Anthropic’s three-step check works from any account and is the right test whether you maintain a framework or merely use one. First, capture the exact request bodies your integration sends over a few normal turns, including a compaction or a tool change if the product does those, and for each consecutive pair compare system, tools and the shared prefix of messages; they should be byte-identical up to the newly appended turns. Second, run a multi-turn session against claude-fable-5-1 with the beta header and drop_block set, logging input_transformations on every response; an empty array on every turn means the history is intact, and a prefix_binding_mismatch entry names the path of the block whose prefix changed. Third, pick a production setting: leave the default error if a mismatch can only mean a bug, or set drop_block and monitor the array. In CI, Anthropic suggests error, so an edit fails the run.

For teams that use a framework rather than write one, the practical order is to find your row above, run step two against your actual traffic, and apply the row’s fix or move compaction to the server. Our AI transformation practice runs this check as part of any Fable 5.1 migration, because the failure mode, an agent that loses its reasoning mid-task on a customer’s new API key while the vendor’s own tests stay green, is the kind that reaches a client before it reaches a dashboard.

06MethodMethodology.

Methodology

A documentation census: each row is read from the framework’s current context-management docs and classified against Anthropic’s published rules. No framework was executed against the API for this table.

What was collected
For ten agent frameworks: the documented mechanism for shortening or rewriting conversation history, the compaction shape it produces in Anthropic’s terms, whether that shape edits the prefix before a thinking block, and the fix Anthropic’s guides prescribe for that shape.
Sources
Anthropic’s Fable 5.1 migration guide and preserved-thinking guide (platform.claude.com); LangChain short-term memory and middleware docs; Vercel AI SDK loop-control and Anthropic-provider docs; OpenClaw compaction docs; Mastra memory and memory-processor docs; Pydantic AI message-history docs; Semantic Kernel chat-history docs; Agno sessions docs; OpenAI Agents SDK sessions docs; CrewAI memory docs (unclassifiable, see text).
As-of date
Docs read September 3, 2026. The page is dated September 2 for the week it covers; this row is the only statement of the collection date.
Classification rule
“Breaks” means the documented default or primary mechanism changes system, tools or an earlier message before a thinking block that is then sent back. “Fine” means the documented shape carries no earlier thinking or keeps the prefix. A framework can be used safely in a configuration its docs do not lead with.
Known limitations
Framework docs change weekly and several projects may add Claude-specific handling in response to this change. Verdicts are about documented mechanisms, not observed 400s. Frameworks not listed were not read.

07ConclusionAppend-only, or strip the tail.

Framework census

Most frameworks keep long sessions short by editing the past. Fable 5.1 now checks the past. The fixes are known, and they are the cache-friendly ones.

Six of the ten frameworks in this census shorten history in a shape Anthropic says will fail the check, and the most common shape, a summary with a verbatim tail, is the one that fails silently on a maintainer’s old key and loudly on a user’s new one.

The fix is not exotic. Replace the whole history with a summary, or strip thinking from the tail you keep, or move compaction to the server, and stop rebuilding system and tools between requests. Every one of those also keeps the prompt cache warm, which is why the teams that built cache-first loops in August have nothing to change in September.

Migration without the 2am 400

Keep the history append-only.

We run Anthropic’s three-step history check against real traffic on every Fable 5.1 migration, fix the compaction shape, and leave the loop append-only so the cache and the reasoning both survive.

Free consultationExpert guidanceTailored solutions
What we work on

Agent loop migration engagements

  • Request-body capture and prefix diffing per turn
  • Compaction redesign: server-side or stripped tail
  • Mid-conversation system messages for instruction and tool changes
  • input_transformations monitoring in production
  • Framework upgrades with a Claude-specific path
FAQ · History rewriting

The questions we get about Fable 5.1 and conversation history.

Claude Fable 5.1 accepts a thinking block on a later request only if the system prompt, the tools array and every message before it are byte-identical to when the block was produced, and only if earlier thinking blocks have not been removed from the middle. The 400 means one of those changed. It is permanent for that request body; strip the thinking blocks and retry once, or send the beta header with prefix_mismatch_behavior set to drop_block.
Related dispatches

Continue exploring agent architecture.

AI Development

Why an AI’s Reasoning Can’t Follow You to Another Model

Anthropic, OpenAI and Google now bind a model’s reasoning to the model that produced it. What each locks, what breaks on a switch, and how a router copes.

September 2, 2026 · 7 minRead
AI Development

Who Gets the Cyber AI Models: Every Vetting Programme Listed

Google’s Fairwind joins Anthropic’s Glasswing and CVP, OpenAI’s Daybreak and Microsoft’s MDASH. One table of who is eligible for each cyber-capable model.

September 2, 2026 · 6 minRead
AI Development

AI Model Releases: September 2026 Tracker and Dated Ledger

A dated ledger of AI model releases in September 2026, each row verified against the vendor’s announcement, with price, context and what it replaces.

September 2, 2026 · 5 minRead
AI Development

Switch Off Claude Fable 5.1 Mid-Task and It Forgets Why

Claude Fable 5.1 reasoning cannot be read by Opus 5 or Sonnet 5. Any router, retry or refusal fallback that moves a task down loses it silently. What to change.

September 1, 2026 · 12 minRead
AI Development

AI Video Generation 2026: Omni vs Sora vs Veo 3 Compared

Gemini Omni, OpenAI Sora 2, and Google Veo 3.1 compared for video — quality, per-second cost spread of 17x, and the September 24 Sora API sunset clock.

May 22, 2026 · 15 minRead
AI Development

Google Intelligent Eyewear: Gemini AI Glasses Fall 2026

Google announces Gemini-powered smart glasses with Samsung, Gentle Monster, and Warby Parker at I/O. Audio glasses ship fall 2026; display tier TBD.

May 20, 2026 · 18 minRead