Skip to content

Feat/subagent tool#3

Merged
angelocavallo merged 3 commits into
mainfrom
feat/subagent-tool
Jun 24, 2026
Merged

Feat/subagent tool#3
angelocavallo merged 3 commits into
mainfrom
feat/subagent-tool

Conversation

@angelocavallo

Copy link
Copy Markdown
Contributor

No description provided.

Angelo and others added 3 commits June 24, 2026 23:30
…tion

Introduce a subagent orchestration factory that builds and runs a fresh
subagent per `spawnSubagent` call from a declarative config, so consumers
no longer hand-write a spawn closure. Lives in core since it needs
`createAgent` at runtime (a same-package call there).

Threading the parent run's `AbortSignal` through:
- new `ToolContext` (passed to a handler alongside its validated args)
  carrying the parent run's signal; the executor threads the run signal
  into every handler call. Existing handlers keep working — fewer-param
  assignability means `(args) => ...` still satisfies the new signature.
- executor takes + forwards `signal`; loop passes the run signal through.

Add a `apps/subagent-demo` vanilla-TS showcase (config overlay, chat,
reasoning panel, confirm queue, DOMPurify sanitization) exercising the
subagent tool end-to-end, plus core + demo tests.

Document the factory, `ToolContext`, and the move of the factory out of
bundled-tools (cross-package runtime dep would break its types-only /
self-contained-IIFE relationship with core) in the core, bundled-tools,
and root READMEs.

Co-Authored-By: Claude <noreply@anthropic.com>
Co-Authored-By: Claude <noreply@anthropic.com>
Lockstep version bump for the release accompanying the declarative
createSubagentTool work landed on this branch.

Co-Authored-By: Claude <noreply@anthropic.com>
@angelocavallo angelocavallo merged commit 138d64b into main Jun 24, 2026
1 check passed
@angelocavallo angelocavallo deleted the feat/subagent-tool branch June 25, 2026 16:46
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