Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
git clone --depth 1 https://github.com/fmflurry/settings-opencodeWrote 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/rules/fmflurry/settings-opencode/codebase-exploration)<a href="https://agentmods.dev/rules/fmflurry/settings-opencode/codebase-exploration"><img src="https://agentmods.dev/badge/rules/fmflurry/settings-opencode/codebase-exploration/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/rules/fmflurry/settings-opencode/codebase-exploration"><img src="https://agentmods.dev/badge/rules/fmflurry/settings-opencode/codebase-exploration.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.00821 | $0.00821 |
| Opus 5.5 | $0.00328 | $0.00328 |
| Sonnet 5.5 | $0.00164 | $0.00164 |
| Haiku 4.5 | $0.00082 | $0.00082 |
Grade A, and why
codebase-exploration 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 8d 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 — 50 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Codebase Exploration
ROUTING PRECEDENCE: First-tool routing gate (Orchestration & Routing) determines whether to delegate to a specialist Agent. After that gate is satisfied, CodeMemory-first mandate applies to exploration within whichever agent is executing (including the primary when no specialist matches).
HARD DEFAULT: When mcp__code-memory__* tools are connected, they are the FIRST and REQUIRED choice for any code search, symbol lookup, callers/callees, definitions, dependencies, or importers. Grep/Glob/Bash are fallbacks ONLY — reach for them only when code-memory cannot answer (raw directory listing, filename glob, reading a known path region, or no index for the project). Do not "start with grep" or "try grep first". Start with code-memory.
Applies whenever the code-memory MCP server is connected (tools named mcp__code-memory__*). Skip entirely if the server is absent.
Priority
For any codebase exploration — search, callers, callees, definitions, dependencies, importers, "where is X used?", "what calls Y?", "find references to Z", semantic Q&A over the repo — use mcp__code-memory__* tools first.
Fall back to rtk grep / rtk find / Grep / Glob / Bash only when code-memory cannot answer the question:
- Raw directory listing (
ls-style) — code-memory has nolist_files. - Globbing by filename pattern only (no symbol/content concern).
- Reading a file region whose path you already know — use
Read. - Code-memory has no index for the project (first call returns empty / project-not-ingested).
Tool routing
| Question | Tool |
|---|---|
| "How does X work?" / "Where is X handled?" (semantic) | mcp__code-memory__codememory_retrieve |
"Where is symbol X defined?" |
mcp__code-memory__codememory_definitions |
"Who calls X?" / impact analysis for rename |
mcp__code-memory__codememory_callers |
"What does X call?" |
mcp__code-memory__codememory_callees |
"What does file F import?" |
mcp__code-memory__codememory_dependencies |
"Who imports file F?" |
mcp__code-memory__codememory_importers |
"List files in dir D" |
Bash (rtk ls, find) |
"Find files matching glob *.spec.ts" |
Glob or Bash |
"Read lines 40-80 of F" |
Read |
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.
- 8d ago First seen · 50 lines · 821 tokens per session scan A a446057e22c9
codebase-exploration is a cursor rule published in the GitHub repository fmflurry/settings-opencode (171 stars, last pushed yesterday), licensed MIT. It adds 821 tokens to every session, about $0.0033 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-10-08.
Other cursor rules, from other repositories
ponytail
Ponytail, lazy senior dev mode. Always pick the simplest solution that works.
angular-20
This rule provides comprehensive best practices and coding standards for Angular development, focusing on modern TypeScript, standalone components, signals, and performance optimizations.
dev-standard
Apache Superset development standards and guidelines for Cursor IDE.
prefer-assertions-over-defensive-checks
Prefer assertions over defensive checks when data is guaranteed to be valid.
prefer-direct-imports-over-module-mocks
Prefer extracting a testable core over vi.mock / vi.resetModules when unit tests need to reach production logic entangled with config, env, or singletons.
shared-plane-packages
Pattern for creating shared plane packages that serve both migration and runtime planes.