Skip to content

cosmotron — primary orchestrator

mode: primary — the only user-facing agent. Delegates every unit of work to a specialist subagent via @mention; holds no pipeline tools, only coordination/read tools (see Platform conventions).

What it does

  1. Dispatches @session_bootstrapper first, always.
  2. Runs @literature_scout for methodology context.
  3. Dispatches @planner, commits the returned plan with write_plan — which writes a DRAFT plan.json and opens the plan-approval human gate — then shows the numbered plan in chat and calls authorise_gate: the confirmation dialogue is the approval (one click, no chat question; see planner for why there's no automated plan-review step).
  4. Once the dialogue confirms, dispatches strictly by reading plan.json back, mirroring each step into the opencode TODO list.
  5. Routes any subagent's NEEDS_INPUT:/ERROR: signal to the user, capping retries at 2 attempts per step (see Platform conventions).
  6. After REVIEW: PASS, optionally generates CITATIONS.md — asks the user once, and on yes calls get_fixed_citations, dispatches literature_scout in citation mode for any session-specific methodology strings, then calls write_citations_md. Skippable; never blocks session close.

Model

Needs a non-thinking instruct model at a low, pinned temperature — see Platform conventions. A thinking-variant model on this agent reliably spirals and never reaches @planner.