Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx agentmods add commands/higoralves/orc/cleanupgit clone --depth 1 https://github.com/HigorAlves/orcWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/commands/higoralves/orc/cleanup)<a href="https://agentmods.dev/commands/higoralves/orc/cleanup"><img src="https://agentmods.dev/badge/commands/higoralves/orc/cleanup.svg" alt="Measured on agentmods" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5 | $0.00039 | $0.03672 |
| Opus 5 | $0.00019 | $0.01836 |
| Sonnet 5 | $0.00008 | $0.00734 |
| Haiku 4.5 | $0.00004 | $0.00367 |
Grade C, and why
cleanup scanned grade C with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 4d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Recursive force deletehighDestructive command
rm -rf with a variable or a broad path is one typo away from removing the wrong tree.
- Bash(rm -rf .orc:*) How it starts
The opening of the file, as written. The whole thing — 276 lines — stays where its author put it; the contents beside it link to each section on GitHub.
/orc:cleanup
Close the loop on finished orc work — remove the workspace state, the worktree, and (if safe) the local feature branch.
Arguments
-
--auto[=guided|full]— autopilot level for this run (overridesinteraction_policy; taxonomy inorc:using-orc). Soft-inward gates consult the resolved policy —guidedauto-advances mechanical confirms with a printed one-liner;fullpre-approves them from settled decisions (orc:state-protocol), stopping only on escalation-only conditions. Hard-outward gates are unaffected at every level. -
<session-id-or-branch>— optional. Clean up exactly one session. Accepts thesessionIdfrom.orc/orc.json(list viaorc-state sessions; schema perorc:state-protocol) or a (sanitized or raw) branch name.
Autopilot: at guided/full, the standard cleanup plan (state dir, clean worktree, merged branch) auto-applies after printing it; anything anomalous — partial workspace merges, unmerged branches, a dirty worktree — still gates at every level.
--all-completed— clean up every session whosestatusin.orc/orc.jsoniscompletedorabandoned. Respects all the safety checks below per session.--dry-run— print what would happen but make no changes. Recommended for the first run.--per-repo— workspace mode: clean each linked repo independently as its PR merges, instead of waiting for all to merge. Use only when you intend to abandon some repos (rare).--down-volumes— when tearing down a session's Docker environment, also remove its named volumes (default keeps them: the next boot on that branch reuses DB data).
Workflow
Phase 0 — Detect context
!orc-workspace-detect --banner
Context is injected above (ORC_* vars are exported for any Bash you run — do not re-run detection).
In workspace mode, the registry to read in Phase 2 is ${ORC_STATE_DIR}/orc.json (workspace-level). Workspace sessions have scope: "workspace" and a repos array. For each candidate workspace session, fetch PR merge status for every URL in linkedPRs:
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 4d ago First seen · 276 lines · 39 tokens per session scan C f555ff0297a7
cleanup is a command published in the GitHub repository HigorAlves/orc (6 stars, last pushed 8d ago), licensed MIT. It adds 39 tokens to every session and 3,672 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it C with 1 finding (recursive force delete). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.
Other commands, from other repositories
setup
Set up Postman MCP Server. Authenticate via OAuth or API key, verify connection, select workspace.
test
Run Postman collection tests, analyze results, diagnose failures, and suggest fixes.
refine-title
深度分析 Issue 或 PR 内容,并将其标题重构为 Conventional Commits 格式.
get-flow-run
Inspect a Postman Flow run by its Run ID — per-block logs, failing block, and status.
warden-cost
Dollar accounting — what does each active rule actually save, in money? Translates the token-measured verdict into dollars using a price table and the agent's own token-type mix, with a per-session net and a break-even. Read-only; spends no tokens.
routine
Execute one maintenance routine defined in scv/routines/ .md (task + guardrails + exit-criteria contract), or list defined routines. SCV never schedules — pair with host features like /loop or cron yourself. Use whenever the user asks to run a recurring maintenance task, or asks what routines exist — not only when…