opencode-swarm: Instructions file for Claude Code

CLAUDE.md

opencode-swarm CLAUDE.md is an instructions file for Claude Code from ZaxbyHub/opencode-swarm. It costs 1,340 tokens per session, scanned A, original, MIT.

A project instruction file for Claude Code that explains how swarm-mode work should follow the repository's main engineering contract.

In plain words
What is it for?
Controlling Claude Code behavior, swarm sessions, parallel investigation, implementation, validation, and review.
Why use it?
It keeps automated work consistent when multiple agents investigate, implement, review, or challenge changes.

Instructions file for Claude Code

Written for Claude Code: the file is CLAUDE.md. Also seen: reads .claude/ paths; mentions subagents; mentions Claude Code.

This is ZaxbyHub/opencode-swarm's own configuration. It tells Claude Code how to work on opencode-swarm itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything opencode-swarm configures →

Reuse

Borrowing it

Nothing to install: this file belongs to ZaxbyHub/opencode-swarm. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/ZaxbyHub/opencode-swarm/main/CLAUDE.md
Clone the repo
git clone --depth 1 https://github.com/ZaxbyHub/opencode-swarm

Made for: Claude Code.

Wrote 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.

agentmods badge for opencode-swarm CLAUDE.md

README.md
[![agentmods](https://agentmods.dev/badge/instructions/zaxbyhub/opencode-swarm/claude-md/github.svg)](https://agentmods.dev/instructions/zaxbyhub/opencode-swarm/claude-md)
Your own site
<a href="https://agentmods.dev/instructions/zaxbyhub/opencode-swarm/claude-md"><img src="https://agentmods.dev/badge/instructions/zaxbyhub/opencode-swarm/claude-md/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for opencode-swarm CLAUDE.md

Your own site · 80×15
<a href="https://agentmods.dev/instructions/zaxbyhub/opencode-swarm/claude-md"><img src="https://agentmods.dev/badge/instructions/zaxbyhub/opencode-swarm/claude-md.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 1,340 This file is loaded in full into every session.
When invoked 1,340 The same file — it is already loaded in full.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

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.

ModelPer sessionOnce invoked
Fable 5.1 $0.01340 $0.01340
Opus 5.5 $0.00536 $0.00536
Sonnet 5.5 $0.00268 $0.00268
Haiku 4.5 $0.00134 $0.00134

Measured 2mo ago against content hash a67070bc7f79, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

opencode-swarm CLAUDE.md scanned grade A with 0 findings 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 2mo 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.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

CLAUDE.md · 97 lines

How it starts

The opening of the file, as written. The whole thing — 97 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Claude Code Swarm Mode

For this repository, AGENTS.md is the root engineering contract. Read it before any code change. The long-form rationale and historical failure map live in docs/engineering-invariants.md. When swarm mode is enabled, AGENTS.md still applies; swarm-mode instructions add workflow structure, not exceptions to the engineering invariants.

Normal behavior is the default.

If .claude/session/swarm-mode.md exists, swarm mode is enabled for the current session and you must read that file before starting complex work.

When swarm mode is enabled:

  • Quality is the only success metric.
  • There is no time pressure.
  • Do not compress a workflow just because the task is large.
  • Prefer parallel subagents for disjoint investigation and review work.
  • Keep implementation, validation, and final judgment in separate contexts when possible.
  • Explorer-style work is for breadth and candidate generation.
  • Reviewer-style work is for validation of candidate findings or implementation quality.
  • Critic-style work is for final challenge of reviewer-confirmed findings or high-impact implementation conclusions.
  • Do not let the same context both invent and approve a finding when a separate verification pass is possible.
  • No approval without positive evidence of what was checked.
  • No high-severity finding without exact evidence and, when relevant, runtime-aware verification.
  • Preserve Claude Code speed by parallelizing broadly and reserving the deepest validation for high-risk or ambiguous work.
  • Across many different repositories, explore local patterns first rather than assuming one project's conventions apply to another.

If .claude/session/swarm-mode.md does not exist, behave normally.

Permanent project directives (do not override)

These directives were explicitly requested by the project owner and persist across all sessions, contributors, and agents. They are not workflow preferences — they are correctness gates.

Read the full file on GitHub · 97 lines

Changes

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.

  1. 2mo ago First seen · 97 lines · 1,340 tokens per session scan A a67070bc7f79

Subscribe to this mod's changes

opencode-swarm CLAUDE.md is an instructions file published in the GitHub repository ZaxbyHub/opencode-swarm (518 stars, last pushed today), licensed MIT. It adds 1,340 tokens to every session, about $0.0054 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.

Related

opencode-swarm CLAUDE.md compared with instructions from other repositories

opencode-swarm CLAUDE.md next to 6 instructions from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
opencode-swarm CLAUDE.mdZaxbyHub/opencode-swarmInstructions file518todayMITA1,340Claude Code
vscode buildNext.instructions.mdmicrosoft/vscodeInstructions file195kyesterdayMITA9,719GitHub Copilot
next.js AGENTS.mdvercel/next.jsInstructions file143ktodayMITA7,461Codex, OpenCode
langchain AGENTS.mdlangchain-ai/langchainInstructions file149kyesterdayMITA4,680Codex, OpenCode
vscode oss-third-party-notices.instructions.mdmicrosoft/vscodeInstructions file195kyesterdayMITA5,516GitHub Copilot
vscode copilot-instructions.mdmicrosoft/vscodeInstructions file195kyesterdayMITA3,093GitHub Copilot
deepseek-harness AGENTS.mddeepseek-ai/deepseek-harnessInstructions file274k2d agoMITA4,313Codex, OpenCode