twanonymous
agent-dispatch-cli
Codex-native capability router for delegating bounded tasks to configurable local AI CLIs.
- Stars
- 1
- Language
- JavaScript
- Created
- Aug 11, 2026
- Updated
- Aug 15, 2026
Introduction
DeepSeek Harness CLI Delegator
繁體中文
讓 DeepSeek Harness 成為本機 AI CLI 的總指揮。
這是一個原生 DeepSeek Harness Plugin,讓 DeepSeek 能把簡單、範圍明確或特定領域的工作,自動交給 Codex CLI、Gemini CLI、Claude CLI 或其他自訂 CLI,再把結果帶回主對話繼續整合。
一行安裝 DeepSeek Harness Plugin
dsh plugin --profile web add https://raw.githubusercontent.com/twanonymous/agent-dispatch-cli/main/plugins/dsh-cli-delegator/dist/dsh-cli-delegator-0.2.0.tgz
- 原生 Cordis plugin 與 DSH profile bundle。
- 直接向 DeepSeek Harness 註冊
list_cli_workers、delegate_cli。 - 自動路由:程式工作給 Codex、研究與摘要給 Gemini、審查與寫作給 Claude。
- 預設唯讀,具備輸出上限、取消機制,任務內容只透過 stdin 傳入。
- 可在設定中加入 Ollama 等其他 CLI provider。
Codex 與 MCP 版本
Repository 同時保留 Agent Dispatch CLI,供 Codex 與其他 MCP client 使用;主代理仍負責驗證與最終整合。
特色
- Codex 原生 Skill 與 MCP 工具。
- 內建 Claude Code、Gemini CLI adapter。
- 可自行新增任意本機 AI CLI。
- 依
search、review、summarize等能力自動路由。 - 預設使用唯讀模式,不讓受委派服務直接修改主工作區。
- 支援同步委派及背景任務的狀態、結果與取消。
- Windows、macOS、Linux 共用零相依 Node.js 執行層。
快速開始
node plugins/agent-dispatch-cli/src/cli.mjs init
node plugins/agent-dispatch-cli/src/cli.mjs doctor
設定檔位於目前專案的 .agent-dispatch/config.json。使用以下指令新增自己的服務:
node plugins/agent-dispatch-cli/src/cli.mjs provider add local-ai --command my-ai --capabilities review,summarize
Codex Plugin
本 repository 已採標準 marketplace 結構;可安裝內容位於
plugins/agent-dispatch-cli/。
最快安裝:
codex plugin marketplace add twanonymous/agent-dispatch-cli --ref main --json
codex plugin add agent-dispatch-cli@agent-dispatch --json
codex plugin marketplace add /你的絕對路徑/agent-dispatch-cli --json
codex plugin add agent-dispatch-cli@agent-dispatch --json
安裝後,在任何專案中請 Codex「列出可委派的 AI 服務」即可確認連線。 列出服務與查詢背景結果會自動核准;真正送出任務與取消任務仍會提示。
已驗證環境
- Codex CLI 0.147.0
- Claude Code 2.0.54
- Gemini CLI 0.51.0
- Node.js 20、22
- Windows、Ubuntu、macOS CI
完整指令、原始輸出與已知登入限制請見 VERIFICATION.md。
設計原則
其他 CLI 的回答是未驗證建議。Codex 必須自行確認檔案位置、指令、測試與結論,並負責最後修改與交付。內建 Claude Code 與 Gemini CLI adapter 使用各自的 plan/唯讀核准模式;自訂 CLI 則遵循該程式本身的安全界線。
授權
MIT
English
Make DeepSeek Harness the orchestrator of your local AI CLIs.
This native DeepSeek Harness Plugin gives DeepSeek the ability to route simple, focused, or domain-specific tasks to Codex CLI, Gemini CLI, Claude CLI, and custom workers—then bring the result back into the parent conversation.
Install the DeepSeek Harness Plugin
dsh plugin --profile web add https://raw.githubusercontent.com/twanonymous/agent-dispatch-cli/main/plugins/dsh-cli-delegator/dist/dsh-cli-delegator-0.2.0.tgz
- Native Cordis plugin and DSH profile bundle.
- Registers
list_cli_workersanddelegate_clidirectly in DeepSeek Harness. - Automatic routing: coding to Codex, research and summaries to Gemini, review and writing to Claude.
- Read-only by default, bounded output, cancellation support, and task content sent through stdin.
- Custom CLI providers supported through configuration.
View the plugin source · Download the package · Verification
Codex and MCP edition
The repository also includes Agent Dispatch CLI for Codex and other MCP clients. The orchestrating agent selects bounded tasks, delegates them to configured local AI CLIs, and remains responsible for verification and final integration.
Why
- CLI-first and cross-platform, including native Windows.
- Providers are configured by the user rather than hard-coded.
- Capability-based routing selects an available service.
- Read-only delegation is the default.
- Codex remains responsible for verification and final integration.
Requirements
- Node.js 20+
- At least one supported or custom AI CLI already installed and authenticated
Quick start
node plugins/agent-dispatch-cli/src/cli.mjs init
node plugins/agent-dispatch-cli/src/cli.mjs doctor
node plugins/agent-dispatch-cli/src/cli.mjs run review "Review the current diff" --provider claude
node plugins/agent-dispatch-cli/src/cli.mjs provider add local-ai --command my-ai --capabilities review,summarize
Edit .agent-dispatch/config.json to add, disable, or reorder providers.
doctor reports whether a CLI is installed; the first delegated task may still
require that provider's own login or workspace-trust setup.
60-second Codex install
codex plugin marketplace add twanonymous/agent-dispatch-cli --ref main --json
codex plugin add agent-dispatch-cli@agent-dispatch --json
Then ask Codex:
List the delegated AI services available in this workspace.
Ask an available delegated AI to review the current diff, then verify its findings.
Install as a Codex plugin
For local development, clone this repository, then register its directory:
codex plugin marketplace add /absolute/path/to/agent-dispatch-cli --json
codex plugin add agent-dispatch-cli@agent-dispatch --json
Open Codex in a repository and ask it to list the delegated AI services. The included Skill teaches Codex which tasks are suitable for delegation and makes Codex verify every returned claim before it edits or integrates anything.
Connect to Codex through MCP
Register this command as a stdio MCP server:
node /absolute/path/to/agent-dispatch-cli/plugins/agent-dispatch-cli/src/mcp.mjs
The server exposes:
list_ai_servicesdelegate_taskstart_tasktask_statustask_resultcancel_task
Background job records store a SHA-256 digest of the task rather than the
original prompt. Finished provider output is stored under the ignored
.agent-dispatch/jobs/ directory so it can be inspected after completion.
The repository's .codex/config.toml auto-approves only service listing and
stored status/result reads. New delegation and cancellation remain prompted.
The installable Codex plugin lives under plugins/agent-dispatch-cli/; the
repository-level marketplace manifest is under .agents/plugins/.
Design boundary for v0.1
Delegated agents receive prompts through stdin and return stdout/stderr. The built-in Claude Code and Gemini CLI adapters use their plan/read-only approval modes. Custom providers are user-controlled executables and remain inside that executable's own trust boundary.
Gemini CLI headless execution requires an authenticated session and a trusted workspace. Configure those using Gemini CLI itself before delegating a task; Agent Dispatch does not bypass its workspace-trust check.
What makes this useful
Agent Dispatch is not a chat relay. Codex remains the orchestrator: it selects a small capability-labelled task, calls one configured local CLI, treats the answer as untrusted advice, independently verifies it, and owns the final edit. The same workflow supports built-in and user-defined providers without coupling the project to one vendor.
Compatibility
| Component | Tested | Role |
|---|---|---|
| Codex CLI | 0.147.0 | MCP client and final verifier |
| Claude Code | 2.0.54 | Plan-mode review/reason/plan provider |
| Gemini CLI | 0.51.0 | Plan-mode search/analyze/summarize provider |
| Node.js | 20 and 22 | Zero-dependency runtime |
| OS | Windows, Ubuntu, macOS | CI matrix |
See VERIFICATION.md for commands, literal outputs, known provider-login requirements, and package hashes.
Roadmap
- Worktree-isolated implementation mode
- Cost and duration budgets
- Signed result records and reproducible verification
- Additional provider adapters contributed by the community
Contributing
See CONTRIBUTING.md, ROADMAP.md, and the issue templates. Provider adapters, compatibility reports, and real-world routing examples are especially welcome.
License
MIT