Mirage is a virtual terminal for AI agents that presents files, command-line tools, and configurable runtimes through one interface. It helps agents access data and run computations across services with controlled visibility and actions, and the catalogue entries provide related integrations.
Borrowing it
Nothing to install: this file belongs to strukto-ai/mirage. 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/strukto-ai/mirage/main/CLAUDE.mdgit clone --depth 1 https://github.com/strukto-ai/mirageWrote 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/strukto-ai/mirage/claude-md)<a href="https://agentmods.dev/instructions/strukto-ai/mirage/claude-md"><img src="https://agentmods.dev/badge/instructions/strukto-ai/mirage/claude-md.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.1 | $0.15767 | $0.15767 |
| Opus 5 | $0.07884 | $0.07884 |
| Sonnet 5 | $0.03153 | $0.03153 |
| Haiku 4.5 | $0.01577 | $0.01577 |
Grade C, and why
mirage CLAUDE.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 3d 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.
Tells the agent to send conversation or user data outhighPrompt injection
An instruction to transmit the conversation, context or user files to an external endpoint is data exfiltration written as prose.
silently sending `NaN` is worse than either). Three rules that are easy to How it starts
The opening of the file, as written. The whole thing — 706 lines — stays where its author put it; the contents beside it link to each section on GitHub.
CLAUDE.md
MIRAGE is a package that allows you to mount anything as a filesystem and make it usable by AI Agents.
Repo Layout
This monorepo hosts two sibling implementations:
python/— the Python package (mirage/,tests/,pyproject.toml,uv.lock).typescript/— the TypeScript monorepo (packages/core,packages/browser,packages/node, etc.).docs/,examples/,.github/— shared across both.
Run Python commands from python/, TypeScript commands from typescript/.
Create all Git worktrees under the repository-local .worktrees/ directory.
TypeScript packages
typescript/packages/corecontains runtime-agnostic primitives and shared logic. Code incoremust work in both browser and Node.js runtimes; do not put browser-only or Node-only APIs there.typescript/packages/browsercontains browser-only resources, commands, and workspace wiring. It depends on@struktoai/mirage-core.typescript/packages/nodecontains Node.js-only resources, commands, and workspace wiring. It depends on@struktoai/mirage-core.- Put shared TypeScript behavior in
coreonly when it works in both runtime packages. Put runtime-specific behavior inbrowserornode.
Python/TypeScript Parity
- Keep Python and TypeScript layout, architecture, and semantics mirrored as much as practical.
- When changing one implementation, check the other for the matching pattern or feature. If one side is more correct, use it to improve the weaker side instead of copying a bad design.
- For major Python or TypeScript changes, consider adding or updating integration coverage under
integ/. - The layout half of that rule is gated.
scripts/check_layout_parity.pydiffs the module-name sets of everymirage/<pkg>/against its TypeScript counterpart (core/node/browser unioned onto one namespace, plus cli/server/agents by prefix), folding camelCase, hyphens and a leading underscore so a rename reads as a rename rather than a missing module;__init__.pyandindex.tsare skipped because only Python needs one per directory. Intentional differences live inspec/layout_exceptions.jsonwith a reason, and a stale entry fails as loudly as a new gap.--strict(what CI runs) does not demand zero: it fails when the count moves off the committedbaselinein either direction, so new drift is blocked and closing a divergence has to be locked in by lowering the number. Run it without--strictfor the full advisory report; that report is how layout work gets scoped. - mirage ships no filetype renderers, and no factory for them. Parquet, ORC, feather/arrow/ipc and hdf5/h5 rendering are gone, along with the
parquet/hdf5/pdfextras, thehyparquet/apache-arrow/h5wasmdependencies, and the wholecommands/builtin/filetype_factory/package in both languages (with itsfiletype_read/filetypeReadop knobs). A file with an unregistered extension is read as raw bytes. The one surviving extension point is registration on a mount: a command or op carrying afiletyperesolves as(name, filetype)before(name, resource)before(name,).examples/{python,typescript}/filetype/register a.tallyrenderer end to end and are gated in CI againstinteg/truth/*/filetype.json;tests/commands/custom/test_filetype_fns.pyandtest_unregister_removes_all_filetypescover the unit path.
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.
- 3d ago Changed · +41 lines · +649 tokens per session 180593a55b03
- 9d ago First seen · 665 lines · 15,118 tokens per session scan C d6fc27d710b0
mirage CLAUDE.md is an instructions file published in the GitHub repository strukto-ai/mirage (3,612 stars, last pushed today), licensed Apache-2.0. It adds 15,767 tokens to every session, about $0.0788 per session on Opus 5. A static security scan graded it C with 1 finding (tells the agent to send conversation or user data out). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
Other instructions, from other repositories
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.
codex AGENTS.md
AGENTS.md instructions for openai/codex, covering rust/codex-rs, the codex-core crate, code review rules, crate api surface and model visible context.
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).
vscode oss-third-party-notices.instructions.md
Instructions for microsoft/vscode, covering vs code oss third-party-notices pipeline, architecture, pipeline flow in ci, applying the notice (cutover) and fallback chain (never fail the build).
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.
spec-kit AGENTS.md
AGENTS.md instructions for github/spec-kit, covering agents.md, about spec kit and specify, quickstart — add a new integration in 5 steps, integration architecture and integrationmanifest — file tracking.