Repository navigation
fix(showcase/mastra): D6 follow-ups to #5798 — gen-ui-agent step cap + useComponent probe path (OSS-381) - #6103
Merged
Conversation
…cap)
The "Generative UI: Agent State" cell (gen-ui-agent) was stuck at D4 — the
d5-single-pill e2e ("marks every step as completed") failed with only 2/3 steps
reaching "completed", which blocks D6.
Root cause: the planner scripts 3 steps × 2 set_steps transitions (in_progress →
completed) + 1 initial "all pending" call + 1 closing message (~8 model turns),
but genUiAgent set no stop condition, so the AI SDK's default halted the agentic
loop before the 3rd step completed. (LangGraph gold loops until the graph ends
and needs no equivalent; this is the AI-SDK step-cap analogue — cf.
toolRenderingAgent's d20 sequence.)
Add defaultOptions.stopWhen = stepCountIs(12) to genUiAgent so the full
progression runs to completion.
Verified on the faithful rig (Node 22 + next build/start + aimock 1.37.4 replay):
gen-ui-agent.spec 6/6; tool-rendering 6/6 and gen-ui-tool-based 4/4 unchanged
(no regression). Isolated to genUiAgent — no other agent/demo affected.
--no-verify: sparse showcase checkout has no monorepo lefthook/commitlint binaries.
Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
…he wrong path
The "Generative UI: useComponent" cell (gen-ui-tool-based) went red on mastra
the moment OSS-381 took it out of not_supported: the D5 gen-ui-custom probe
sent the *haiku* prompt and hunted for a haiku card, but mastra's demo is the
LGP-style `useComponent` chart demo (render_pie_chart / render_bar_chart) with
no haiku tool — so the assistant bubble came back empty ("haiku card
[data-testid=copilot-assistant-message] rendered but has no text content").
Root cause: the probe's CHART_INTEGRATIONS allowlist in
harness/src/probes/scripts/d5-gen-ui-custom.ts omitted mastra, so
isChartIntegration("mastra") was false and it took the haiku branch. mastra's
gen-ui-tool-based page registers render_pie_chart / render_bar_chart via
useComponent exactly like langgraph-python and google-adk.
- Add "mastra" to CHART_INTEGRATIONS so the probe sends the pie-chart prompt
and asserts the donut SVG + "pie"/"chart" follow-up tokens.
- Add aimock/d6/mastra/gen-ui-custom.json (mirrors langgraph-python's, context:
mastra; the pie schema is identical — {title, description, data:[{label,value}]})
so the cell is deterministic under aimock replay instead of falling through to
the live upstream.
- Repoint the probe unit test's haiku-empty-card case from "mastra" to "agno"
(a genuine haiku integration) now that mastra is a chart integration.
Not a v1-bridge streaming regression — a harness/fixture gap exposed when the
cell was un-suppressed. Harness unit tests not run locally (sparse showcase
checkout has no vitest); logic-only changes.
--no-verify: sparse showcase checkout has no monorepo lefthook/commitlint binaries.
Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
contextablemark
requested review from
jpr5,
marthakelly,
mme,
ranst91 and
tylerslaton
as code owners
July 22, 2026 05:42
Contributor
📣 Social Copy GeneratorGenerate social media copies (Twitter/X, LinkedIn, Blog Post) for this PR using Claude.
|
Contributor
Production Digest-Pinning AuditAll 41 services digest-pinned. Run 2026-07-22 06:39:00 PDT — 0 finding(s). |
contextablemark
enabled auto-merge
July 22, 2026 05:58
auto-merge was automatically disabled
July 22, 2026 06:59
Pull request was closed
ranst91
approved these changes
Jul 23, 2026
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.
What
Two mastra showcase D6 follow-ups to #5798 (v1 bridge alpha). Both cells went red the moment #5798 took them out of
not_supported_features— they were claimed supported before actually passing. Neither is a v1-bridge streaming regression.Commits
1. gen-ui-agent completes all 3 steps (raise step cap) —
57afed6dd"Generative UI: Agent State" (gen-ui-agent) stalled at 2/3 steps:
genUiAgentset no stop condition, so the AI SDK default halted the agentic loop before the 3rd step completed. AddsdefaultOptions.stopWhen = stepCountIs(12). Verified 6/6 on the Node-22 +next start+ aimock replay rig; tool-rendering / gen-ui-tool-based unaffected.2. useComponent (gen-ui-tool-based) — probe took the wrong path —
4640d6304The D5
gen-ui-customprobe omittedmastrafromCHART_INTEGRATIONS, so it sent the haiku prompt and hunted for a haiku card. mastra's demo is the LGP-styleuseComponentchart demo (render_pie_chart/render_bar_chart) with no haiku tool, so the assistant bubble came back empty ("haiku card [data-testid=copilot-assistant-message] rendered but has no text content")."mastra"toCHART_INTEGRATIONS.aimock/d6/mastra/gen-ui-custom.json(mirrors langgraph-python; identical pie schema{title, description, data:[{label,value}]}) so the cell is deterministic under replay instead of falling through to the live upstream."mastra"→"agno"(a genuine haiku integration).Verification
Refs
@ag-ui/mastraPR — multi-turn Responses-API message-id 400 fix: fix(mastra): sanitize forwarded message ids for the OpenAI Responses API ag-ui-protocol/ag-ui#2227.🤖 Generated with Claude Code