Files
deepseek-harness/examples/coding-agent/composition.md
T
Dudu-0223 e0f20088d8 feat: bash-backed glob/grep discovery tools (dsh-tool-fs-search)
Implements docs/rfc/implemented/feature/2026-07-09-bash-backed-grep-glob-
discovery.md: model-facing glob/grep in a new @deepseek-ai/dsh-tool-fs-search
package, executing fixed ripgrep templates through ctx.bash.resolve/run —
not ctx.fs provider methods — so filesystem backends stay free of a search
contract and sandboxed/remote executors substitute cleanly. The tools never
call ctx.bash.start(); the tool layer owns quoting (one singleQuote safety
boundary), rg --json parsing, ItemRetainer/TextRetainer retention, and the
first tool-owned ctx.spillFiles.saveText() handoff (item-level retention the
generic post-execute spill policy cannot recover).

RFC amendments on the way to implemented/: a shared src/search-core.ts (the
SEARCH_* vocabulary + bash-run/raw-spill/spill plumbing was byte-identical
across both tools — the missed-extraction smell), and a snapshot-gap note:
wiring the acp-agent tree changes the assembled prompt, so goldens need a
keyed re-record; the spill notice text is pinned by unit tests instead and
only the coding-agent example ships the tools for now.
2026-07-09 21:04:08 +08:00

3.8 KiB

Coding Agent App Composition

The coding REPL demo adds the real DeepSeek adapter, filesystem tools, todo_write, compaction, and both subagent transports on top of the stdio app package.

flowchart LR
  cfg["examples/coding-agent<br/>cordis.yml"]
  plugin_coding_hmr["hmr<br/>@cordisjs/plugin-hmr"]
  cfg --> plugin_coding_hmr
  plugin_coding_llm_deepseek["llm-deepseek<br/>@deepseek-ai/dsh-llm-deepseek"]
  cfg --> plugin_coding_llm_deepseek
  plugin_coding_bash["bash<br/>@deepseek-ai/dsh-bash-local"]
  cfg --> plugin_coding_bash
  plugin_coding_stdio_agent["stdio-agent<br/>@deepseek-ai/dsh-stdio-agent"]
  cfg --> plugin_coding_stdio_agent
  plugin_coding_stdio_agent --> bundle_agent_core["@deepseek-ai/dsh-agent-core"]
  plugin_coding_stdio_agent --> bundle_jsonl["@deepseek-ai/dsh-session-persistence-jsonl"]
  plugin_coding_stdio_agent --> frontdoor_stdio["readline UI<br/>console logger<br/>pre-created main agent"]
  bundle_agent_core --> spine_llm["ctx.llm"]
  bundle_agent_core --> spine_sessions["ctx.sessions"]
  bundle_agent_core --> spine_tools["ctx.tools + tool-bash"]
  bundle_agent_core --> spine_loop["ctx.agents + ctx.agentLoop"]
  plugin_coding_compact_basic["compact-basic<br/>@deepseek-ai/dsh-compact-basic"]
  cfg --> plugin_coding_compact_basic
  plugin_coding_subagent["subagent<br/>@deepseek-ai/dsh-subagent"]
  cfg --> plugin_coding_subagent
  plugin_coding_subagent_spawn["subagent-spawn<br/>@deepseek-ai/dsh-subagent-spawn"]
  cfg --> plugin_coding_subagent_spawn
  plugin_coding_subagent_fork["subagent-fork<br/>@deepseek-ai/dsh-subagent-fork"]
  cfg --> plugin_coding_subagent_fork
  plugin_coding_tool_subagent["tool-subagent<br/>@deepseek-ai/dsh-tool-subagent"]
  cfg --> plugin_coding_tool_subagent
  plugin_coding_tool_subagent_fork["tool-subagent-fork<br/>@deepseek-ai/dsh-tool-subagent"]
  cfg --> plugin_coding_tool_subagent_fork
  plugin_coding_tool_todo["tool-todo<br/>@deepseek-ai/dsh-tool-todo"]
  cfg --> plugin_coding_tool_todo
  plugin_coding_fs_local["fs-local<br/>@deepseek-ai/dsh-fs-local"]
  cfg --> plugin_coding_fs_local
  plugin_coding_fs_policy["fs-policy<br/>@deepseek-ai/dsh-fs-policy"]
  cfg --> plugin_coding_fs_policy
  plugin_coding_tool_fs["tool-fs<br/>@deepseek-ai/dsh-tool-fs"]
  cfg --> plugin_coding_tool_fs
  plugin_coding_tool_fs_search["tool-fs-search<br/>@deepseek-ai/dsh-tool-fs-search"]
  cfg --> plugin_coding_tool_fs_search
  plugin_coding_spill_local["spill-local<br/>@deepseek-ai/dsh-spill-local"]
  cfg --> plugin_coding_spill_local
  plugin_coding_spill_policy["spill-policy<br/>@deepseek-ai/dsh-spill-policy"]
  cfg --> plugin_coding_spill_policy
Plugin id Package / module
hmr @cordisjs/plugin-hmr
llm-deepseek @deepseek-ai/dsh-llm-deepseek
bash @deepseek-ai/dsh-bash-local
stdio-agent @deepseek-ai/dsh-stdio-agent
compact-basic @deepseek-ai/dsh-compact-basic
subagent @deepseek-ai/dsh-subagent
subagent-spawn @deepseek-ai/dsh-subagent-spawn
subagent-fork @deepseek-ai/dsh-subagent-fork
tool-subagent @deepseek-ai/dsh-tool-subagent
tool-subagent-fork @deepseek-ai/dsh-tool-subagent
tool-todo @deepseek-ai/dsh-tool-todo
fs-local @deepseek-ai/dsh-fs-local
fs-policy @deepseek-ai/dsh-fs-policy
tool-fs @deepseek-ai/dsh-tool-fs
tool-fs-search @deepseek-ai/dsh-tool-fs-search
spill-local @deepseek-ai/dsh-spill-local
spill-policy @deepseek-ai/dsh-spill-policy

Source config: examples/coding-agent/cordis.yml.

Maintenance mode: hybrid: the leaf plugin list is parsed from its cordis.yml; app package expansion is curated from package source.