dsh-subagent-parent-message
Manifest valid★ 1DSH plugin: bidirectional subagent messaging - subagent_parent_message (child to parent; one-shot/workflow OK) + subagent_send_message (parent to direct continuable child). 子 agent 双向:直连父会话 + 父联系直接子。
dsh-subagent-parent-message
Bidirectional messaging tools for delegated DSH subagents.
subagent_parent_message— child → direct parent. It reads the parent from the child's own Session header and delivers a durable peer-session message, so one-shot/workflow children can report without writing a file first.subagent_send_message— a namespaced alias for the core adjacent-agent channel (parent ↔ direct continuable child). Use it when the parent'ssend_messageis shadowed by a team-scoped tool with a different schema.
Why
DSH core send_message only authorizes a resident continuable child to message its direct parent, and the parent often sees a different send_message ({target, message} from the experimental team tool) instead of the core one ({agent_id, message}). In practice:
subagent/subagent_forkchildren can reach the parent, but the parent cannot reply when itssend_messageis team-scoped.workflowagent()/pipeline()children are one-shot; they have no continuation activation, so coresend_messagefails.- Nested children often only know a root/grandparent id; core only accepts the direct parent/child (
subagent "<id>" is unavailable). - The old workaround was "write everything to disk so the parent can read it". It still works, but it is not a message.
These two namespaced tools cover both directions without adding another send_message collision.
Tools
subagent_parent_message — child → parent
subagent_parent_message({ "message": "self-contained progress or result" })
subagent_parent_message({ "message": "...", "mode": "steer" })
followup(default): queue a new parent turn; wakes an idle parent.steer: inject at the parent's next step while it is running.- Resolves the direct parent from
session.header.parentSession; no parent id required. - Uses the live parent Agent or
sessionController.resolveAgentcold resume, thenagent.followup/steer+ctx.sessions.flush. - Works for one-shot/workflow children because it does not depend on a continuation activation.
- Refuses self-delivery and never accepts an arbitrary target.
subagent_send_message — parent ↔ direct continuable child
subagent_send_message({ "agent_id": "session-…", "message": "keep going" })
- Thin namespaced adapter over
ctx.subagents.sendMessage(). - The subagent service still enforces direct parent/child adjacency and continuation residency.
- Useful when the parent's
send_messageis team-scoped (targetschema), so the core channel is otherwise unreachable by name. - It cannot wake a one-shot child; for a one-shot child's report use
subagent_parent_messagein the child.
Delivery shape
[Subagent message from session-…]
This is a peer message from a delegated child, not the human user. Treat it as a task update.
---
<your message>
subagent_parent_message uses agent.followup(message) (or agent.steer) + ctx.sessions.flush(agent.session); subagent_send_message delegates to ctx.subagents.sendMessage().
Limits
subagent_parent_message: direct parent only, no attachments, no team mailbox; parent must be live or resumable.subagent_send_message: only direct parent/child with a resident continuable activation; it does not replace teamsend_messagefor teammates.- Neither tool waits for the other side's answer; one call is one message.
- For file attachments use
dsh-cross-session; for teammates useagent_teams_send_message.
Install
Requires DSH 0.2.x.
dsh plugin --profile <profile> add C:\path\to\dsh-subagent-parent-message-0.1.2.tgz
# or
dsh plugin --profile <profile> add https://codeload.github.com/zhyunran/dsh-subagent-parent-message/tar.gz/<40-char-commit>
Restart DSH once after install; both tools are global and visible to subagents.
Status
- 7 unit tests (
node --test test/*.test.mjs): live parent, cold resume, steer, missing parent, empty message,subagent_send_messagedelegation, missing service. - Real
dsh-toolsschema compile for both tools. - Live verified:
subagentchild → parent via coresend_message;workflowone-shot child → parent viasubagent_parent_message(followupandsteer). - No runtime dependencies; peer-depends only on
@deepseek-ai/dsh-tools.
License
MIT. See LICENSE.
Built for DeepSeek Harness.
Comments
Loading…
From the same category
by ranxianglei
基本稳定可用 100K tokens is enough. Universal context-compression proxy for ALL AI coding agents,10w上下文足矣
★ 4.1k
↓ 957.2k/wk
MIT
TypeScript
Nov 5, 2026
dsh plugin --profile web add billion-contextA DeepSeek coding agent harness: persistent shell, Ultra subagents, auto approval, Chrome MCP and session telemetry
★ 1k
MIT
JavaScript
by Han-1413141
DeepSeek Harness session cost meter plugin: session/daily cost, budget, history, OpenCode Go quota, official & custom-provider balance, Codex-like token heatmap, peak/off-peak pricing with pre-switch
★ 629
↓ 26k/wk
MIT
JavaScript
Nov 5, 2026
dsh plugin --profile web add dsh-cost-meterby Yuuyuko-uu
DSH 鱼的记忆:给会话一份会淡忘的长期记忆,每条都带时间
★ 481
MIT
JavaScript
Nov 4, 2026
dsh plugin --profile web add dsh-fish-memoryby MichengAI
DSH Archive Manager — 在 DeepSeek Harness 中安全查看、恢复和管理已归档会话 · Safely view, restore, and manage archived sessions in DSH
★ 294
↓ 37.5k/wk
Apache-2.0
JavaScript
Nov 5, 2026
dsh plugin --profile web add @michengai/dsh-archive-managerby Nwflower
Import 14+ external agent chat histories (Claude Code, Codex, ChatGPT, Cursor, Gemini, Reasonix, opencode, ZCode, Grok Build, OpenClaw, Pi, Hermes, Kimi CLI, DSH) into DeepSeek Harness as resumable se
★ 282
↓ 5.3k/wk
MIT
JavaScript
Nov 3, 2026
dsh plugin --profile web add dsh-chat-import