mandible: Instructions file for Codex

AGENTS.md

mandible AGENTS.md is an instructions file for Codex, OpenCode from AS-FOSS/mandible. It costs 5,467 tokens per session, scanned A, original, Apache-2.0.

Repository working agreements for Mandible, a tool that extracts information from developer tools without hard-coded rules for each tool. They define the project's core design rule, architecture boundaries, and verification approach.

In plain words
What is it for?
Making architecture-compliant changes, locating user-specific overrides, and checking behavior beyond merely seeing that automated tests pass.
Why use it?
They prevent tool-specific exceptions from spreading through the code and explain which document takes priority when design rules conflict.

Instructions file for CodexOpenCode

Written for Codex and OpenCode: the file is AGENTS.md. Also seen: mentions AGENTS.md.

This is AS-FOSS/mandible's own configuration. It tells Codex and OpenCode how to work on mandible 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 mandible configures →

Reuse

Borrowing it

Nothing to install: this file belongs to AS-FOSS/mandible. 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/AS-FOSS/mandible/main/AGENTS.md
Clone the repo
git clone --depth 1 https://github.com/AS-FOSS/mandible

Made for: Codex, OpenCode.

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 mandible AGENTS.md

README.md
[![agentmods](https://agentmods.dev/badge/instructions/as-foss/mandible/agents-md/github.svg)](https://agentmods.dev/instructions/as-foss/mandible/agents-md)
Your own site
<a href="https://agentmods.dev/instructions/as-foss/mandible/agents-md"><img src="https://agentmods.dev/badge/instructions/as-foss/mandible/agents-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 mandible AGENTS.md

Your own site · 80×15
<a href="https://agentmods.dev/instructions/as-foss/mandible/agents-md"><img src="https://agentmods.dev/badge/instructions/as-foss/mandible/agents-md.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 5,467 This file is loaded in full into every session.
When invoked 5,467 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.05467 $0.05467
Opus 5.5 $0.02187 $0.02187
Sonnet 5.5 $0.01093 $0.01093
Haiku 4.5 $0.00547 $0.00547

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

Security

Grade A, and why

mandible AGENTS.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 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.

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.

AGENTS.md · 403 lines

How it starts

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

AGENTS.md — working agreements for AI agents in this repo

Read this before touching code. Every rule a script can check is a pointer to that script. What is left is prose, because no lint can catch it.

Precedence: docs/design.md is the design authority, so it says what to build and why. This file is the operational authority, so it says how to work here. CONTRIBUTING.md is for humans. If this file and docs/design.md disagree about design, docs/design.md wins and you should fix this file.


1. The invariant that defines the project

No per-tool logic, ever. No if tool == "docker", no tool-name-keyed special case in any extraction tier, no per-tool patch file vendored into this repo.

Tool-specific knowledge lives in exactly one place: user-local override files under ~/.config/mandible/overrides/, which are never committed here. (Spec revision 3 deleted the vendored catalog that used to be the second place — a per-tool catalog is per-tool knowledge relocated into data, and it cannot stay current with the tool actually installed. Parsing is keyed by framework now: see spec §7 Tier A′ and mandible-extract/src/help_text/profile.rs, where adding a framework is one match arm plus one fingerprint.)

If a tool renders badly, the fix is a better general parser, a new general tier, or an honest low-confidence badge in the UI. It is never a special case. This is the entire reason the tiered architecture exists; one exception starts the erosion that the architecture was built to prevent.


2. Hard limits

Every number here is enforced, and none of them is a law of nature. Changing one is a decision, and a decision goes in docs/design.md §16.

Limit Number Enforced by
Code lines in a .rs file before mod tests 800 scripts/shape_guard.sh
Lines in a function 150 clippy.toml, clippy::too_many_lines
Cognitive complexity of a function 30 clippy.toml, clippy::cognitive_complexity
Lines in one comment block 12 scripts/shape_guard.sh
Comment lines over code lines in a file 0.5 scripts/shape_guard.sh
Tools that show a parser shape recurs (reported, not gated) 5 xtask sweep-diff, read by a human

Read the full file on GitHub · 403 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. 4d ago Changed · +15 lines · +275 tokens per session d6c30fd485f2
  2. 11d ago Changed · +7 tokens per session 721718eb8ea9
  3. 18d ago Changed · +5 lines · +82 tokens per session 4a3e93e43701
  4. 25d ago Changed · +2 lines · +31 tokens per session 5d0ec65a67ac
  5. 1mo ago Changed · +9 lines · +119 tokens per session b4f69abd56bd
  6. 1mo ago Changed · -1 tokens per session 0dc9667ba51a
  7. 1mo ago Changed · +2 lines · +33 tokens per session 66d4348e3040
  8. 1mo ago Changed · +3 lines · +56 tokens per session 9cd231afac1a
  9. 2mo ago Changed · +6 lines · +124 tokens per session 2d2eeb2495b6
  10. 2mo ago First seen · 361 lines · 4,741 tokens per session scan A e96e1d2a64ae

Subscribe to this mod's changes

mandible AGENTS.md is an instructions file published in the GitHub repository AS-FOSS/mandible (227 stars, last pushed yesterday), licensed Apache-2.0. It adds 5,467 tokens to every session, about $0.0219 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.

Related

mandible AGENTS.md compared with instructions from other repositories

mandible AGENTS.md next to 6 instructions from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
mandible AGENTS.mdAS-FOSS/mandibleInstructions file227yesterdayApache-2.0A5,467Codex, OpenCode
vscode buildNext.instructions.mdmicrosoft/vscodeInstructions file195kyesterdayMITA9,719GitHub Copilot
next.js AGENTS.mdvercel/next.jsInstructions file143kyesterdayMITA7,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