mirror of
https://github.com/deepseek-ai/deepseek-harness
synced 2026-08-15 21:04:50 +00:00
1.1 KiB
1.1 KiB
Subagent And Session Lineage
Maintenance mode: curated Mermaid flow; provider inventory is visible in the generated capability seam graph.
This graph keeps delegation semantics separate from hook observation. A subagent backend creates an ordinary child agent/session through the shared provider registry.
flowchart TD
parent["Parent Agent + Session"]
tool["tool-subagent<br/>model-facing name"]
registry["ctx.subagents provider registry"]
spawn["spawn provider<br/>fresh child session"]
fork["fork provider<br/>seeded from completed-turn prefix"]
acp["ACP provider<br/>out-of-process child"]
child["Child AgentHandle<br/>ordinary Agent lifecycle"]
result["SubagentResult returned to tool"]
parent --> tool --> registry
registry --> spawn --> child
registry --> fork --> child
registry --> acp --> child
child --> result --> parent
The hooks stack adds richer lifecycle observation around child runs; the core ownership rule stays the same: the provider owns the child handle and must dispose it.