ClaudeMods
☰
ZH-TW
● 0 人在線上 · 瀏覽 0 次
贊助提交作品
GitHub 儲存庫 · 發布者 severinlindenmann

orch-session

一個 Claude Code 外掛,透過狀態列、提示列上方的列、/orch 面板和交接 toast 顯示目前工作階段持有的 orch 工單。

severinlindenmann@severinlindenmann

severinlindenmann/orch-core/tree/main/plugins/orch-session

已翻譯

關於這個 mod

orch-session 是一個 Claude Code 外掛,只顯示目前工作階段持有的 orch 工單,不顯示其他內容:沒有積壓,也沒有佇列。所有內容都會先說明輪到誰行動,以圖示加文字呈現(絕不只靠顏色),並使用 orch-core 設計系統的顏色。

  • 狀態列:每個已認領工單一項,例如 ◐ L-0001 working ● L-0002 Answer Q1。
  • 提示列上方的列:最重要的行動優先顯示你的行動,例如 ● L-0002 0/1 Your move: Answer Q1 · Which one?。
  • /orch:每張工單一張卡片的面板,顯示輪到誰行動、要做什麼、帶選項的開放問題、建議選項、orch answer 命令、任務、父層 epic、上次 verdict 和 PR。
  • Toast 只用於交接:你的行動開始或結束、工單被阻擋、出現 verdict、取得或失去認領。

它是唯讀的:呼叫 orch list --mine --json 和 orch show <id> --json,在每次 agent orch 命令後以及定期重新整理(依活動情況為 20s/60s/5m),一次只進行一次重新整理。重新整理失敗時保留上一個完整狀態,並在面板中回報。它從不執行寫入命令或僅限人工的命令,而是顯示 orch answer 命令,不執行它。

要求:PATH 上有 orch CLI、orch-core schema 1.4.0+,以及支援 function-hook 外掛的 Claude Code 版本。

claude plugin install orch-session@orch-core

它刻意作為獨立外掛存在,這樣 Claude Code 的 hooks-API 變更就不會影響 orch-core 的 guard 和 session-start hooks。開發使用 node --test、claude plugin validate、claude plugin test 和 claude --plugin-dir。

安裝

請先查看作者 README,確認 marketplace 與外掛名稱;指令可能隨儲存庫結構而變動。

claude plugin marketplace add severinlindenmann/orch-core
claude plugin install orch-session
原文 / README

orch-session

Shows the orch tickets this session holds, inside Claude Code. Nothing else: no backlog, no queue.

Everything leads with whose move it is, as orch-core says it (move in orch show --json, the dashboard's own rules) and in its design system's colours: pink ● only for your move (answer a question, approve a plan, re-approve a changed gate, do your task, give the verdict), blue ◐ while the agent works, amber ▲ when the ticket is blocked, red ✕ when orch cannot be read. Every status is an icon and a word, never colour alone.

  • Status line: ◐ L-0001 working ● L-0002 Answer Q1, one entry per claimed ticket.
  • Band above the prompt: one row with the move that matters most, yours first: ● L-0002 0/1 Your move: Answer Q1 · Which one?.
  • /orch: a pane with one card per ticket: whose move and what, an open question with its options, the recommended one and the orch answer command to run in your own terminal, every task (doing and blocked first), the epic it belongs to, the last verdict and the PR.
  • Toasts on hand-overs only: your move starts or ends, the ticket is blocked, a verdict, a claim gained or lost.

It only reads: orch list --mine --json with the session's id and orch show <id> --json for each ticket. It refreshes after every orch command the agent runs and every 20 seconds while things change (60 seconds after three quiet polls, 5 minutes where there is no orch workspace), one refresh at a time, without holding up the tool call. A refresh in which any read fails keeps the last complete state and says so in the pane. It never runs a command that writes or that only a human may run; it shows the orch answer command, it does not run it.

What it shows. orch list --mine lists only the claims held by this session's own id, so a fresh claude shows nothing until the agent runs orch claim. Epics cannot be claimed: an epic appears only as "in epic DEMO-0031" on its claimed children, without progress of its own (open it in Mission Control for that). In a folder without an orch workspace, /orch shows a short toast instead of a pane, and the refresh slows to every 5 minutes.

The status line is drawn by Claude Code, which currently styles every plugin status like a warning (⚠ orch-session: ...) and ignores plugin colours there. That is the host's behaviour, so the line is kept short.

The plugin has no rules of its own for whose move it is. An orch that predates move (orch-core schema below 1.4.0) shows "Update orch-core" on each ticket and an amber note in the pane, never a guess.

Install

Needs the orch CLI on the PATH, orch-core with schema 1.4.0 or newer (see orch-core's README, "The CLI in your own terminal"), and a Claude Code build with function-hook plugins (early access; the API may change between releases).

claude plugin install orch-session@orch-core

It is a separate plugin on purpose: if a Claude Code update breaks the hooks API, orch-core's guard and session-start hooks keep working.

Develop

node --test plugins/orch-session/test/*.spec.ts   # the logic, against real orch output; no claude CLI needed
claude plugin validate plugins/orch-session
claude plugin test plugins/orch-session           # the hooks inside the engine
claude --plugin-dir plugins/orch-session          # load it into a session

The fixtures in test/fixtures are real orch-core output. After a change to what orch list or orch show print, make them again (CI also runs the tests against freshly made ones):

uv run --project plugins/orch-core python plugins/orch-session/test/make_fixtures.py plugins/orch-session/test/fixtures

更多類似作品