Repository navigation
fix(showcase/langgraph-python): force reasoning emission in reasoning-chain agent - #4747
Merged
Merged
Conversation
…-chain agent The tool-rendering-reasoning-chain D5 probe has been red since the probe was added (PR #4743) — the reasoningMessage slot's <ReasoningBlock> never mounts because the agent doesn't emit reasoning summaries. Compared to the working reasoning_agent.py (which powers reasoning-default + reasoning-custom and is green), the only meaningful difference was the reasoning config: reasoning_agent.py (works): reasoning={"effort": "medium", "summary": "detailed"} tools=[] tool_rendering_reasoning_chain_agent.py (was broken): reasoning={"effort": "low", "summary": "auto"} tools=[get_weather, search_flights, ...] `summary: "auto"` lets the model decide whether to emit a reasoning summary. With tools present the model often skips it (chain-of-thought goes straight into the tool call without a summary). `summary: "detailed"` forces emission on every response, which lights up the ReasoningBlock slot. Bumping effort medium so the surface visible to the user reads as a real chain-of-thought, matching reasoning-display. Probe diagnostics from prod confirmed the toolCalls were firing fine (WeatherCard mounted, assistant text landed) — only the reasoning emission was missing. Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
tylerslaton
requested review from
jpr5,
marthakelly,
mme and
ranst91
as code owners
May 9, 2026 05:06
Contributor
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Contributor
📣 Social Copy GeneratorGenerate social media copies (Twitter/X, LinkedIn, Blog Post) for this PR using Claude.
|
This branch was successfully deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
tool-rendering-reasoning-chainD5 probe has been sustained red since it was added (PR #4743) — every tick fails withexpected [data-testid="reasoning-block"] to mount within 30000ms.Diagnostic dumps from prod confirmed the failure mode:
reasoningMessageslot never received an eventRoot cause
Comparing to the working
reasoning_agent.py(which backsreasoning-default+reasoning-custom, both D5 green):reasoning_agent.py(works)tool_rendering_reasoning_chain_agent.py(was broken)effort"medium""low"summary"detailed""auto"[][get_weather, search_flights, get_stock_price, roll_dice]summary: "auto"lets the model decide whether to emit a reasoning summary. With tools present, the model frequently skips emission entirely — the chain-of-thought goes straight to the tool call without a summary step. That leavesrole: "reasoning"messages off the wire, so the v2<ReasoningBlock>slot never mounts.summary: "detailed"forces emission on every response. Bumpingeffortto"medium"to match the working agent.Test plan
reasoningfield to the aimock fixture forweather in Tokyofirst leg — that part of the wire is finetool-rendering-reasoning-chainshould flip green on the next e2e-deep tickKnown follow-up (NOT in this PR)
gen-ui-agent(Agent State) is intermittently flapping (~22% failure rate over recent ticks), with two distinct error modes ("no assistant response" and "agent-state-card never mounts"). Need to dig deeper to determine root cause — separate investigation.🤖 Generated with Claude Code