Skip to content

feat(web): inspect bounded Subagent owner details - #548

Open
testikun wants to merge 1 commit into
openpi-dev:mainfrom
testikun:codex/issue-346-subagent-detail
Open

testikun wants to merge 1 commit into
openpi-dev:mainfrom
testikun:codex/issue-346-subagent-detail

Conversation

@testikun

Copy link
Copy Markdown
Contributor

Problem

Subagent activity in the Web workbench is a passive chip. The manager already owns exact progress and terminal outcome, but only Background Terminals have an inspectable detail path. Refs #346.

Value

Operators can inspect a Web Session’s delegated work, including its model, source, turn/record counts, recent tools, bounded output, failure and interruption evidence, without inventing a second resource state or adding browser control authority.

Approach

  • Extend the existing Session-scoped Web observer registry with an exact-id Subagent detail projection from manager.view.get(id); the existing authenticated /api/capabilities/detail Host route continues to enforce the active Session identity.
  • Bound title/model, cwd, error, current output and the last eight tool previews at the projection boundary; report omitted bytes/tools and truncation. A restarted running child does not present a previous run’s final text as current output.
  • Wire Subagent chips into the existing InspectionPanel as text-only, read-only details. Keep terminal inspection and runtime status separate; no stop/cancel/write API is introduced.
  • Ablation removed an extra queued-message field; turn count, retained record count, recent tool progress and exact outcome still satisfy this slice.

Validation

  • bun run check: passed (Node 24, checkout base f6b49ae59605b1276b8267f2886d22c03f01533c).
  • bun run test: Node 1660 passed, 1 platform skip; Vitest 222 passed.
  • Focused Host/registry 47/47 and UI 51/51 passed. Real Chrome Subagent desktop/mobile test passed, including refresh, exact Session/id GET, escaped text and no writes; isolated pi list showed one local OpenPI source at this checkout.
  • Full real-Chrome Web suite: 33/34 passed. The existing touch-viewport test intermittently closed its sidebar after a page-level Escape and timed out looking for Workspace options; that unchanged test passed when rerun alone. PR feat(web): browse archived and terminal Session history #547 fixes this test focus race, so this PR intentionally does not duplicate its patch. The new Subagent test passed in both full and focused runs.

Subagent detail desktop
Subagent detail mobile

Impact

  • User-visible: Subagent activity chips open a bounded, read-only detail panel; existing Terminal and status panels remain available.
  • Model-visible context/tools: none.
  • Runtime/lifecycle: one synchronous owner read through the existing registry; no new controller, cancellation, or persisted state.
  • Persisted config/data: none.
  • Compatibility/risk: output is intentionally partial; full child transcript stays in Pi. This branch shares generated Web assets and UI files with PR feat(web): browse archived and terminal Session history #547, so it should be rebased after that PR lands. Refs feat(web): add inspectable and controllable OpenPI capability panels #346, not a closure of Workflow/control work.

@github-actions github-actions Bot added documentation Improvements or additions to documentation area:subagents Subagent delegation, skills, or tests area:github GitHub workflows, templates, ownership, or tests labels Sep 17, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:github GitHub workflows, templates, ownership, or tests area:subagents Subagent delegation, skills, or tests documentation Improvements or additions to documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant