Skip to content

feat(web): show only authoritative subagent model metadata - #1223

Merged
tiann merged 1 commit into
tiann:mainfrom
swear01:fix/1221-authoritative-subagent-model
Jul 29, 2026
Merged

feat(web): show only authoritative subagent model metadata#1223
tiann merged 1 commit into
tiann:mainfrom
swear01:fix/1221-authoritative-subagent-model

Conversation

@swear01

@swear01 swear01 commented Jul 28, 2026

Copy link
Copy Markdown
Contributor

Fixes #1221

Root cause

The existing subagent model badge only inspects model-bearing child blocks. That is sufficient for Claude sidechains, but Codex app-server collaboration events already preserve an authoritative explicit per-invocation model in the spawn tool input and may not expose child blocks in the parent trace.

Change

  • Fall back to the explicit subagent invocation model only when no executed child model is available.
  • Keep executed child-model data authoritative and first.
  • Never fall back to the caller/session model, so Cursor/Grok/OpenCode cards remain blank when their ACP events do not expose per-subagent model metadata.

Impact

Codex and any other backend that explicitly reports the subagent invocation model now show it in the existing badge. No inferred model is displayed.

Validation

  • bun typecheck
  • bun run test — CLI 1527, hub 643, web 1562, shared 142 tests passed
  • git diff --check
  • bun run build:web
  • isolated hub health check on port 43006

AI disclosure

Investigated and implemented with OpenAI Codex under human direction.

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Review mode: initial

No issues found in the diff.

Residual risk: I could not run bun test here because bun is not installed in this environment. The new helper coverage exercises the fallback path, but there is still no rendered-component test for the badge in ToolCard/ToolMessage.

@tiann
tiann merged commit 9102253 into tiann:main Jul 29, 2026
2 checks passed
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.

feat(web): show only authoritative subagent model metadata

2 participants