Borrowing it
Nothing to install: this file belongs to daedalus/fuzzer. 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/daedalus/fuzzer/master/AGENTS.mdgit clone --depth 1 https://github.com/daedalus/fuzzerWrote 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/daedalus/fuzzer/agents-md)<a href="https://agentmods.dev/instructions/daedalus/fuzzer/agents-md"><img src="https://agentmods.dev/badge/instructions/daedalus/fuzzer/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.
<a href="https://agentmods.dev/instructions/daedalus/fuzzer/agents-md"><img src="https://agentmods.dev/badge/instructions/daedalus/fuzzer/agents-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.05522 | $0.05522 |
| Opus 5.5 | $0.02209 | $0.02209 |
| Sonnet 5.5 | $0.01104 | $0.01104 |
| Haiku 4.5 | $0.00552 | $0.00552 |
Grade C, and why
fuzzer AGENTS.md 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 9d 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.
- **Do not clean the corpus between runs.** The corpus directory accumulates discovered inputs across sessions. `rm -rf corpus/*` destroys coverage history and forces rediscovery from scratch. Always use `--resume` to co How it starts
The opening of the file, as written. The whole thing — 229 lines — stays where its author put it; the contents beside it link to each section on GitHub.
AGENTS.md — fuzzer-tool
Coverage-guided binary fuzzer: ASAN/MSAN/TSAN/UBSAN detection, dictionary mutations,
Markov chain generation, Monte Carlo optimization, format-aware grammar mutations, and
state persistence. CLI tool that fuzzes arbitrary binaries (see fuzzer-tool --help).
The fuzzer executes attacker-controlled input against instrumented targets and parses the targets' own binaries — any bug in this tool's parsing/process code is a bug in the fuzzer, not just the target.
References (read on demand)
| File | Open when |
|---|---|
docs/refs/bug-classes.md |
Touching process/signal handling, timeouts, ptrace, concurrency, resource cleanup, hashing/identity, caching, ELF/low-level parsing, numeric edge cases, state persistence, dispatch tables, error swallowing, .so symbol visibility, widely-used return-value APIs, or test mocks. Also carries the regression-testing rules. |
docs/refs/architecture.md |
Working inside coverage/SHM internals, the AFL shim, --no-shm/--deep-coverage, the Elo meta-scheduler, or state persistence (state.json / edge_tracker.json / markov.json). |
Hard Rules
- Always make surgical changes.
- Always follow existing conventions. Before adding anything — a target, a script, a scheduler, a test fixture — find the closest existing example and match it: directory layout, file naming, function shape, flag names, error handling, comment style. Read the surrounding code first; do not invent a parallel way of doing something the repo already does. Concretely:
- Vendored library sources go in
$FUZZ_VENDOR_ROOT/<lib>/(default~/fuzzing/vendoring/<lib>/, legacyvendor/<lib>/via--in-tree-vendor), fetched by atools/vendor_<lib>.shscript. Never commit them; never put them under the build root ($FUZZ_BUILD_ROOT/<lib>/, default~/fuzzing/builds/, legacytargets/via--in-tree-targets). - New fuzz targets are wired into
tools/build_targets.shrather than built by hand. - New schedulers register in
_OPERATOR_STRATEGY_NAMESand follow theselect_op/record/bandit_statsinterface. - If a convention appears wrong, fix it in one place for everything rather than working around it locally, and say so.
- Vendored library sources go in
- Never bypass the pre-commit hooks (
--no-verify). Fix the warnings, then recommit. - Always fix impactguard breaking changes.
- Always use clang, never gcc (build scripts prefer clang automatically).
- Stop suggesting
use_direct_lite = Falseto work around ASAN indirect_litemode — debug the root cause instead. - Never commit binary files or corpus directories — build targets from source, keep corpus data local.
- Before deleting code, find where it should be wired first; if not found, clean up. When removing code, stay strictly within the scope of the removal — do not remove unrelated code.
- Do not nuke the repo.
- All fuzz targets: compile with ASAN (
-fsanitize=address) and AFL edge coverage viaafl_shim.c(-include src/fuzzer_tool/adapters/afl_shim.c). Pre-compile library sources as.ofiles; link the shim only into the target wrapper. - Always create TODOs. Always commit and push after finishing a task.
- Update
docs/DEEP_DIVE.mdwith new features (the comprehensive reference). UpdateREADME.mdonly when adding or changing high-level capabilities visible in the quick-start or feature overview. - Op mutators have a single source of truth:
src/fuzzer_tool/core/operator_registry.py'sREGISTRY. Register new operators there only — the dispatch table (build_dispatch), the per-input op list (build_ops), scheduler arming (_register_arms), andOPERATOR_CATEGORIESall derive from it. Never add operator names to the legacyMUTATIONS/FORMAT_MUTATIONS/DICT_MUTATIONSlists or hand-editOPERATOR_CATEGORIES; schedulers discover ops through the services layer and never hardcode op lists. - Only run the full pytest suite if a file in the codebase was modified.
- Always after developing a new function and verify its correctness try to vectorize it after the fact, keep the fastest version.
- Always use the existing pickle machinery, avoid json.
- For random always use the prng in
src/fuzzer_tool/core/rand_pool.py. - Do not create artifacts in the source codebase dir.
- Always create corpus on ~/.
- Always make sure a new functionality is wired up where needed.
- try except pass is a bad pattern.
- Always exercise hygiene: every test must clean up their mess.
- If you solved the halting problem you are allowed to run tests that the user is saying they are hanging otherwise read the code to see what it does.
- For every new functionality always add one falsification test and one adversarial test.
- Always use subagents for multiple file exploring or long tasks.
- Without any question when the user instructs you to git and commit now, you obey, create the commit message, commit and push. no questions asked and no deliberation.
- When writing something intended for human consumption, (comment, commit message, reply to prompt) use as few words as possible. Pick every word meticulously to reduce the volume to a strict minimum. Be down to the point. Less is more.
- Avoid superlatives and praise. Stop telling me I am absolutely right. Give me the cold hard truth.
- Avoid magic numbers and strings by extracting recurring or meaningful values into descriptive constants (const) or enums. Keep self-explanatory, one-off values inline to avoid clutter. If a value comes from a spec (e.g. HTTP 200 OK), use a constant regardless.
- Reduce code indentation. Avoid Arrow Anti-Pattern. Leverage early return and continue.
- Keep function names short. Less than 30 characters.
- Use enums instead of booleans for function parameters.
- Let the reader of the code breathe. Add empty lines between logical blocks of code.
- Add a small, to the point, comment to explain what the block does and why. Use examples when possible. Propose ASCII drawings to explain complete systems.
- Treat member visibility changes as a breaking design shift. Keep all fields and functions private unless external access is strictly required by the design. Prompt the user for explicit approval before changing any access modifier from private to internal or public.
- Program to levels of abstraction. Lower-level mechanics must be encapsulated in a dedicated driver/abstraction layer. Expose clean, high-level APIs to the rest of the application so calling code works with domain concepts, not raw implementation details. 36a. Don't touch blocks of code unrelated to the feature you implement. e.g. Don't add comments to a block of code if you did not create it or modify it. As much as possible try to minimize the number of changed lines when implementing a feature. 36b. Strictly adhere to the layered boundary hierarchy: each layer may only communicate with its immediate neighbor directly below it. Never "punch holes" through layers (e.g., controllers or UI components must never directly call database queries, raw hardware drivers, or low-level network clients; always route through the intermediate service/abstraction layer).
- If the prompt indicates that a bug is being fixed, don't write the fix right away. First write the test. Observe it failing. Then write the fix. And observe the test passing.
- When implementing a new feature don't write it right away. First write the test. Observe it failing. Then write the feature. And observe the test passing (Test driven development).
- No retry-until-random-hit loops in tests (
for _ in range(N): if cond: break/found=True). This tests luck, not behavior — it can pass while the code is broken and fails unreproducibly when it doesn't.- Inject a scripted/fake RNG that deterministically drives the exact call sequence and assert the exact output.
- See
docs/refs/bug-classes.md§Testing.
- Every scheduler armed through
_register_arms(src/fuzzer_tool/services/fuzzer.py) must declare an explicit class-levelsupports_priorsbool:Trueonly when itsinit_arm()accepts an informative(prior_alpha, prior_beta)override._register_armsgates priors behindgetattr(scheduler, "supports_priors", False), so a scheduler that omits the flag silently discards format-operator priors instead of failing loudly. Declare it directly after the class docstring with a one-line reason, followingop_monte_carlo.py/op_exp3.py. - Always check that the new features implemented or bug fixes do not introduce speed penalty regressions.
- When implementing new features always think of edge cases for the tests.
- Always maintain succinct, brief, down to the point and updated documentation.
- When adding, removing or wiring a new subsystem update
architecture.png. - Every time a new source
file.pyis created runlizard --CCN=15 file.pyand fix warnings. - Always run the control against itself; it's what exposes a broken oracle. Whenever a test compares an implementation against a reference — two samples, two policies, old code as oracle — also compare the reference against a second run of itself, and assert that control passes first. A control that fails means the comparison is wrong, not the code.
- Measured here: comparing two Thompson selection policies with
stats.chisquare(obs, exp)treats one sample's counts as fixed frequencies, halves the variance and roughly doubles chi2. It reportedchi2=526on 264 arms (df 264, p=0.0000) for two implementations that were in fact identical. - The control run under the correct
stats.chi2_contingencygives p=0.74. The tell was the ~2x ratio to the degrees of freedom, and only the self-comparison surfaces it. - See
tests/test_seed_quality_beta_identity.py::test_matches_betavariate_in_distribution. - This is the statistical sibling of Hard Rule 39: an oracle that cannot fail on identical inputs is not an oracle.
- Measured here: comparing two Thompson selection policies with
- Always do git commit and push after tests pass do not run tests after git commit and push.
- When planning to add new features: add code sketches and always add a section with the fully wiring the new feature.
- When planning a new feature always reason over small targeted code tests, copy the function to test and test it.
- The full pytest battery is over 14k tests, running it is unpractical, always run the tests for the affected code.
- Whenever any method from scipy, sympy or gmpy is needed implement it by ourselves instead of importing more libraries.
- Always run calibrations against fuzzgoat target and make sure it's built with clang.
- For every layout update in
afl_shim.cthen increment__AFL_SHM_LAYOUT+1. - Always keep memory usage bounded.
- For cleanliness and maintainability: A big class with a lot of members and reentrancy is preferable than a big procedure.
- Always rebuild targets if
afl_shim.cchanges. - Push ifs up, fors down wherever possible.
- Ifs up: decide flags, modes and feature availability once (setup, per run or per exec) and bind the result (a bound method, a table, a filtered list). Don't re-check them per mutation, per byte or per edge, and don't pass a mode flag down for the callee to branch on.
- Fors down: give functions the whole batch (
randbytes(n),randint_list,translate, numpy) instead of calling them per item, and hoist loop-invariant checks out of loops. - Measure: benchmark before and after. Keep the change only if it is faster; if it isn't, record why (see
docs/DEEP_DIVE.md§Push ifs up, fors down). - Cache safely: a cache of state that can change must be revalidated cheaply or reset at a known boundary, for example
mutate()clearing_meta_strategy_cached.
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.
- 9d ago Changed · +2 tokens per session b26f191d95a9
- 12d ago Changed · +2 lines · +107 tokens per session ab93889bbd10
- 13d ago Changed · +9 tokens per session d9ea1e6d1fa7
- 15d ago Changed · +6 lines · +255 tokens per session 4d48b6e09b09
- 17d ago Changed · +10 lines · +42 tokens per session 69379b8cde9c
- 25d ago Changed · +1 lines · +28 tokens per session 2f780f5571b9
- 29d ago Changed · +2 lines · +55 tokens per session 44a0ecb3acc0
- 1mo ago Changed · +1 lines · +27 tokens per session b324107cbe3c
- 1mo ago Changed · +1 lines · +16 tokens per session 94e516908509
- 1mo ago First seen · 206 lines · 4,981 tokens per session scan C ec55f82445eb
fuzzer AGENTS.md is an instructions file published in the GitHub repository daedalus/fuzzer (45 stars, last pushed today), licensed MIT. It adds 5,522 tokens to every session, about $0.0221 per session on Opus 5.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-30.
Other instructions, from other repositories
vscode buildNext.instructions.md
Working notes and architecture documentation for the new esbuild-based build system in build/next. Use when making changes to the new build pipeline (transpile/bundle commands, NLS plugin, source-map handling, resource copying, or self-hosting watch tasks).
next.js AGENTS.md
AGENTS.md instructions for vercel/next.js, covering next.js development guide, codebase structure, monorepo overview, core package: packages/next and other important packages.
vscode oss-third-party-notices.instructions.md
Instructions for microsoft/vscode, covering vs code oss third-party-notices pipeline, architecture, pipeline flow in ci, cache eligibility and rollout and applying the notice (cutover).
langchain AGENTS.md
AGENTS.md instructions for langchain-ai/langchain, covering global development guidelines for the langchain monorepo, corridor security analysis, project architecture and context, monorepo structure and development tools & commands.
vscode copilot-instructions.md
Copilot instructions for microsoft/vscode, covering vs code copilot instructions, project overview, root folders, core architecture (src/ folder) and built-in extensions (extensions/ folder).
deepseek-harness AGENTS.md
AGENTS.md instructions for deepseek-ai/deepseek-harness, covering agents.md, pre-stable apis and released session data, repository layout, commands and host sandbox failures.