On this page

On November 12, 2026, OpenAI shipped Python SDK v3.50.0 (commit f44c1ec, PR 4268) and Node SDK v7.56.0 (PR 3145), exposing a new optional input_transformations array on both Response and BetaResponse objects in the Responses API. Previously, when an application running in stateless mode (store set to False) or managing its own conversation history accidentally altered earlier context, the API silently discarded affected encrypted reasoning items—leaving developers to infer the failure from unexplained spikes in reasoning_tokens and latency. With v3.50.0, the response payload explicitly reports every withheld reasoning item ID and the exact reason it was dropped.

Schema of input_transformations and the Five Removal Reasons

First, note that input_transformations is a read-only diagnostic field on the response object rather than a request parameter. Whenever the API withholds one or more reasoning items passed in your input array, response.input_transformations lists those items in input order. Each entry contains four required fields: type (fixed to reasoning), id (the original reasoning item ID from an earlier response), action (fixed to removed), and reason, which takes one of five enum values:

**prefix_mismatch (Most Common): **For frontier reasoning models, the Responses API validates the exact conversation prefix preceding every reasoning item sent back in input. If your application edits, shortens, reorders, or inserts an item anywhere before that reasoning item compared to the history that originally produced it, the API drops the affected reasoning item.

**turn_boundary: **The selected model or the request's reasoning.context policy (such as auto versus all_turns) does not allow carrying that reasoning item across the current turn boundary.

**model_mismatch: **The continuation request switched to a different model ID or lineage that cannot reuse the encrypted reasoning item generated by the earlier model.

**organization_mismatch: **The OpenAI organization ID authenticating the follow-up request differs from the organization under which the reasoning item was originally created.

**end_user_mismatch: **The user or safety_identifier value sent on the current request does not match the end-user identifier attached when the reasoning item was produced.

Figure 1 OpenAI Responses API input_transformations removal reason enums and diagnostic matrix
Figure 1 OpenAI Responses API input_transformations removal reason enums and diagnostic matrix

Image source: compiled by DigIntoAI from openai-python v3.50.0 type definitions and OpenAI API documentation.

How Silent Drops Work and a Four-Step Debugging Workflow

A critical detail to keep in mind is that prefix_mismatch in the Responses API does not return an HTTP 400 error. Instead, the server silently strips the invalidated reasoning items, proceeds with the remaining conversation history, and forces the model to generate fresh reasoning from scratch. That silent fallback explains why multi-turn agents can suddenly double their reasoning token burn without triggering application error handlers.

OpenAI's official Preserved reasoning guide illustrates partial preservation with a ledger-query workflow. Suppose Turn 1 runs User prompt, Reasoning A, tool call lookup_ledger(), raw tool output rows, and Reasoning B. If Turn 2 replaces those raw rows with a compact subtotal string, Reasoning A (which precedes the edited tool output) still has an intact prefix and remains reusable, whereas Reasoning B (which follows the edited tool output) is dropped with reason prefix_mismatch even if sent back byte-for-byte unchanged.

Once upgraded to openai-python v3.50.0 or later, follow four steps to diagnose and eliminate dropped reasoning:

**Step 1 — Log Non-Empty input_transformations Arrays: **After each client.responses.create call, inspect response.input_transformations and log every reported id and reason whenever the list is populated.

**Step 2 — Cross-Reference the Item ID Against Prior Output: **Take the reported reasoning item id and locate it inside the earlier turn's response.output list to see where it sat in the original sequence.

**Step 3 — Diff the Preceding Prefix to Find the First Mutation: **Compare the items preceding that reasoning ID in your current input payload against the original conversation. Common culprits include truncating past function_call_output payloads, rewriting developer instructions mid-thread, or adding and removing entries in the top-level tools array.

**Step 4 — Migrate to Append-Only History Patterns: **Filter or trim large tool results before sending function_call_output the first time, and append a corrective message or new tool call if data changes later. Keep known tools definitions stable when switching modes—using allowed_tools under tool_choice or appending an additional_tools developer item instead. For long histories, use OpenAI compaction and continue from its returned context rather than replaying old reasoning items after a custom text summary.

Figure 2 Avoiding prefix edits in multi-turn workflows and separating Prompt Cache hits from reasoning reuse
Figure 2 Avoiding prefix edits in multi-turn workflows and separating Prompt Cache hits from reasoning reuse

Image source: compiled by DigIntoAI from the OpenAI Preserved reasoning guide and Responses API schema.

Why Prompt Cache Hits Do Not Equal Reasoning Reuse

It is easy to assume that a non-zero usage.input_tokens_details.cached_tokens counter means your encrypted reasoning items were also preserved. In reality, Prompt Caching and Preserved Reasoning govern two separate layers of the runtime:

Prompt Caching operates on input token KV-cache reuse and billing discounts—if your system prompt and early turns remain unchanged, repeated prefix tokens receive cache discounts (and misses can be inspected via prompt_cache_diagnostics). Preserved Reasoning governs whether encrypted chain-of-thought state is reloaded into the model's active reasoning context, subject to strict prefix integrity, model compatibility, organization alignment, end-user matching, and reasoning.context rules.

Consequently, a request can score substantial cached_tokens on its static prompt prefix while still suffering a turn_boundary or end_user_mismatch drop in input_transformations—forcing the model to spend fresh output reasoning_tokens re-deriving prior work. Auditing both metrics side by side gives full visibility into input cost savings and reasoning continuity.