Borrowing it
Nothing to install: this file belongs to terret-org/terret. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.
curl -O https://raw.githubusercontent.com/terret-org/terret/main/CLAUDE.mdgit clone --depth 1 https://github.com/terret-org/terretWrote 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/instructions/terret-org/terret/claude-md)<a href="https://agentmods.dev/instructions/terret-org/terret/claude-md"><img src="https://agentmods.dev/badge/instructions/terret-org/terret/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.
<a href="https://agentmods.dev/instructions/terret-org/terret/claude-md"><img src="https://agentmods.dev/badge/instructions/terret-org/terret/claude-md.svg" alt="Reviewed on agentmods" width="80" 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.1 | $0.02643 | $0.02643 |
| Opus 5.5 | $0.01057 | $0.01057 |
| Sonnet 5.5 | $0.00529 | $0.00529 |
| Haiku 4.5 | $0.00264 | $0.00264 |
Grade A, and why
terret 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.
How it starts
The opening of the file, as written. The whole thing — 152 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Terret
Ruby-native, model-agnostic agent harness where everything is a plugin. Twelve gems in one repo:
gems/hamesis the kernel. Services in a context, typed events, reversible effects, dependency-driven boot. It knows nothing about LLMs and is reusable for any plugin-composed application.gems/terret-coreis the harness built on it. Session log, tools pipeline, agent loop, LLM seam (vocabulary,AdapterBaseretry policy,FakeAdapter), plus the M6 long-lived-agent services: durable approvals (ctx[:approvals], opt-in per tool), the compactor on the sole-providerctx[:summarizer]seam, the titler, and hot-reloadable per-agent policy (AllowListas a log projection). M8 added the sole-providerctx[:subagents]seam (a child agent on a fresh session, run to completion) and the loop's tool barrier, which runs a message'sconcurrency: :parallelcalls together on the reactor while a:serialtool is a barrier of one.Terret::Credentials(ctx[:credentials]) lives here too: ENV<PROVIDER>_API_KEYfirst, then an optional AES-256-GCM file store, every resolved value fed to the scrubber.gems/terret-openrouteris the one real adapter (plan §6.5): OpenRouter's OpenAI-compatible API behindctx.llm, streaming SSE with tool calling and usage accounting. The transport is injectable, so its unit tests need no network and no gems; only the defaultAsyncTransportrequiresasync-http.gems/terret-store-sqliteis the durable session store (M3): the append-only log one event per row in SQLite (WAL) behind thectx[:session_store]seam. Memory and JSONL providers live in terret-core; the store row is explicit in every boot.gems/terret-wsis the v1 interface (M4): one WebSocket per agent behindctx[:ws], the §9.2 frames, exact replay-then-tail on the session log; wire contract indocs/protocol.md; only the real endpoint requiresasync-websocket.gems/terret-acpis the second interface (M8): an Agent Client Protocol server behindctx[:acp]so an editor can drive an agent over JSON-RPC on stdio. It consumessession/eventand drivesctx[:loop]— the same two seams the socket does, on a different transport, with no change to core; mapping indocs/acp.md. stdlib-only.gems/terret-mcpis the MCP client (M5): manceps-backed stdio and streamable-HTTP servers mounted asmcp__<server>__<tool>sources behindctx[:tools], per-server approval, per-call timeouts, the allow list in terret-core; mapping indocs/mcp.md.gems/terret-morphis actx[:summarizer]provider (M6): Morph's Compact API on the wire proven in the deployed agora integration (bearer key,compression_ratio: 0.4, nil-on-any-failure), an injectable transport so its unit tests need no network, and aMORPH_LIVE=1live lane (pending aMORPH_API_KEYin this environment).gems/terret-execis the execution world (M7, plan §6.6):ctx[:fs]with every path realpath-contained to a granted workspace dir behind anfs/authorizewaterfall,ctx[:subprocess](spawn and PTY under the one reactor, SIGTERM→SIGKILL cancellation),ctx[:shell](one persistent bash per agent, sentinel protocol),ctx[:terminals](named long-lived PTYs, capped), andctx[:sandbox]with theNoneprovider — every argv passessandbox.wrapbefore it spawns. Stdlib only.gems/terret-tools-stdis the standard roster (M7, plan §6.7):Read,Write,Edit,Glob,Grep,Bash,WebFetch,terminal_open/input/read/close— Claude Code's names verbatim, no alias map — registered on those seams with honestmutating/approval/concurrencymetadata.Bash's approval derives fromsandbox.isolated?at registration;WebFetchsits behind a deny-by-default domain policy re-checked per redirect hop, plus a host-side loopback/link-local floor. M8 addedTask(delegate to a child agent viactx[:subagents]),TodoWrite, andjob_start/job_collect/job_stopoverctx[:jobs].gems/terret-sandbox-dockeris the container provider (M7): a long-lived container per boot, each workspace dir bind-mounted at the same absolute path, argv wrapped intodocker exec,--network noneby default. One patch row moves the execution world into it; docker-gated tests skip clean when the daemon is absent.gems/terretis the meta-gem and the composition layer (M8, plan §7): bundles ship ordered config rows, profiles stack bundles, patches adjust rows by id, andTerret.boothands the result to the Hames loader. It shipsterret-base(config/bundle.yml), theheadlessprofile template, and thetrtexecutable (boot,dump-config,doctor,acp). Itsdiscover_bundlesmounts a third-party bundle off that gem's gemspecmetadata["terret"], so a plugin gem becomes composable by shipping normally. The contract isdocs/composition.md; read it and plan §7 before changing anything here.Terret::Meta::VERSIONis the gem's version —Terret::VERSIONbelongs to terret-core.
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.
- 2mo ago First seen · 152 lines · 2,643 tokens per session scan A 7b0e1e6f0331
terret CLAUDE.md is an instructions file published in the GitHub repository terret-org/terret (24 stars, last pushed 28d ago), licensed MIT. It adds 2,643 tokens to every session, about $0.0106 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-08-30.
terret CLAUDE.md compared with instructions from other repositories
| Mod | Type | Stars | Last push | Licence | Scan | Tokens | Works with |
|---|---|---|---|---|---|---|---|
| terret CLAUDE.mdterret-org/terret | Instructions file | 24 | 28d ago | MIT | A | 2,643 | Claude Code |
| vscode buildNext.instructions.mdmicrosoft/vscode | Instructions file | 195k | yesterday | MIT | A | 9,719 | GitHub Copilot |
| next.js AGENTS.mdvercel/next.js | Instructions file | 143k | yesterday | MIT | A | 7,461 | Codex, OpenCode |
| langchain AGENTS.mdlangchain-ai/langchain | Instructions file | 149k | yesterday | MIT | A | 4,680 | Codex, OpenCode |
| vscode oss-third-party-notices.instructions.mdmicrosoft/vscode | Instructions file | 195k | yesterday | MIT | A | 5,516 | GitHub Copilot |
| vscode copilot-instructions.mdmicrosoft/vscode | Instructions file | 195k | yesterday | MIT | A | 3,093 | GitHub Copilot |
| deepseek-harness AGENTS.mddeepseek-ai/deepseek-harness | Instructions file | 274k | 2d ago | MIT | A | 4,313 | Codex, OpenCode |