Skip to content

[Fix] Fast Brain query details fall back to raw JSON when truncated - #1748

Draft
roomote-roomote[bot] wants to merge 1 commit into
developfrom
fix/fast-brain-tool-details-1tc6mpra77lkp
Draft

[Fix] Fast Brain query details fall back to raw JSON when truncated#1748
roomote-roomote[bot] wants to merge 1 commit into
developfrom
fix/fast-brain-tool-details-1tc6mpra77lkp

Conversation

@roomote-roomote

Copy link
Copy Markdown
Contributor

​Opened on behalf of @mrubens. Follow up by mentioning @roomote-roomote, in the web UI, or in Slack.

What changed

  • Preserve recognized tool inputs when result text cannot be parsed as JSON, and render that output as a YAML block scalar instead of falling back to raw JSON.
  • Read the query from Fast's canonical nested rawInput.arguments.query shape without changing persistence contracts.
  • Add Fast transcript coverage comparing a normal Brain entity result with a head/tail-truncated Brain query result.

Why this change was made

Fast pretty-serializes integration results and truncates large outputs at 50,000 characters. Brain query results can cross that limit, making the persisted text invalid JSON; smaller entity results remained parseable, so only query rows bypassed YAML formatting and lost their visible query input.

Impact

Truncated Fast Brain query rows now show the persisted query alongside the complete preserved head/tail output in YAML, while generic invalid or plain-text results keep their existing treatment. Focused ACP detail, tool-row, and Fast transcript tests pass, along with web typecheck, ESLint, formatting, and repository pre-push checks. Local browser proof was unavailable because the sandbox dev account remained on the setup wizard; the regression test exercises the canonical persisted Fast payload shape directly.

Related PRs

  • Original YAML tool-detail rendering: #1745

@roomote-community

roomote-community Bot commented Aug 27, 2026

Copy link
Copy Markdown
Contributor

No code issues found. See task

Reviewed 84b9934

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant