跳到主要内容
    ↑↓ 选择↵ 打开esc 关闭
    中文English
    VicenteOlmos

    Herdr

    v0.1.2智能体编排
    opencode-herdr

    Route OpenCode agents through Herdr panes as herdr/<adapter>/<model> (Cursor, Claude, Codex, OpenCode)

    GitHub 星标

    1

    月装机量

    363

    近 7 天 19

    综合评分SCORE

    38.2

    生态多维模型

    最近提交

    1 天前

    2026-08-18

    快速安装与配置

    opencode.json

    写入当前项目的 opencode.json,只对这个仓库生效。

    opencode.json

    {
      "$schema": "https://opencode.ai/config.json",
      "plugin": ["opencode-herdr@0.1.2"]
    }

    opencode 启动时会通过内嵌运行时自动加载 npm 依赖并缓存至本地目录,无需手动在全局环境执行安装。

    npm license GitHub

    OpenCode plugin: route selected agents through Herdr as herdr/<adapter>/<nativeModel> (runtime + model from the id).

    Requires Herdr and at least one runtime CLI on PATH (agent, claude, codex, or opencode).

    Find it: npm · search opencode herdr · GitHub topics opencode herdr

    Install

    opencode plugin opencode-herdr -g
    

    Or in ~/.config/opencode/opencode.json:

    {
      "plugin": [
        ["opencode-herdr", { "handoverDefault": "cursor" }]
      ]
    }
    

    handoverDefault is optional. The plugin injects the provider entrypoint as a file:// URL so OpenCode can load createHerdr even when the project cwd has no local node_modules link.

    Tested runtimes

    Runtime CLI
    Cursor agent
    Claude Code claude
    Codex codex
    OpenCode opencode

    Usage

    Command Description
    /herdr-status Herdr availability, runtimes, and target count
    /herdr-test Create pane, ask agent a random sum, read the answer back into this chat
    /herdr-delete Close all oh-* job panes in the opencode-herdr tab
    /herdr-pane <runtime> <task> Delegate a task (asks if runtime/task missing)
    /herdr-handover <runtime> [note] Split pane, wait idle, send one-line context

    CLI (no LLM):

    opencode-herdr-handover --runtime cursor --session <id> --cwd <path>
    

    On each new OpenCode session the plugin shows a readiness toast. The bundled Herdr skill is installed idempotently to ~/.config/opencode/skills/herdr/SKILL.md on config load.

    Model refs

    Configure an agent with e.g. herdr/cursor/composer-2.5 → provider herdr, runtime cursor, model composer-2.5.

    Dev / debug

    Path plugin (local checkout):

    {
      "plugin": [[
        "/absolute/path/to/opencode-herdr/src/index.ts",
        { "handoverDefault": "cursor", "debug": true }
      ]]
    }
    
    Option Effect
    keepPanes Do not close oh-* panes after a job (inspect [herdr] runner logs)
    keepJobs Keep /tmp/.opencode-herdr-* (request.json / result.json)
    debug Implies keepPanes + keepJobs

    Env: OPENCODE_HERDR_DEBUG=1, OPENCODE_HERDR_KEEP_PANES=1, OPENCODE_HERDR_KEEP_JOBS=1.

    Close leftovers with /herdr-delete.

    bun install && bun test
    

    License

    MIT