sc:codebase-index

sc:codebase-index is a skill for Claude Code, Codex from squadcodercom/squadcoder. It costs 136 tokens per session (749 once invoked), scanned A, original, MIT.

A guide for finding relevant code and documentation by meaning, including in a large or unfamiliar codebase. It uses a local index when the code-memory tools are available.

In plain words
What is it for?
Use it to trace features such as authentication or billing, find related code, search project documentation, and investigate which changes introduced a behavior.
Why use it?
It reduces the need to guess file locations or search only for exact words. It also separates broad questions from exact searches and history lookups.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it to trace features such as authentication or billing, find related code, search project documentation, and investigate which changes introduced a behavior.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/squadcodercom/squadcoder/sc-codebase-index
Install

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.

Any agent
npx skills add squadcodercom/squadcoder --skill sc-codebase-index
Clone the repo
git clone --depth 1 https://github.com/squadcodercom/squadcoder

Made for: Claude Code, Codex.

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 sc:codebase-index

README.md
[![agentmods](https://agentmods.dev/badge/skills/squadcodercom/squadcoder/sc-codebase-index/github.svg)](https://agentmods.dev/skills/squadcodercom/squadcoder/sc-codebase-index)
Your own site
<a href="https://agentmods.dev/skills/squadcodercom/squadcoder/sc-codebase-index"><img src="https://agentmods.dev/badge/skills/squadcodercom/squadcoder/sc-codebase-index/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 sc:codebase-index

Your own site · 80×15
<a href="https://agentmods.dev/skills/squadcodercom/squadcoder/sc-codebase-index"><img src="https://agentmods.dev/badge/skills/squadcodercom/squadcoder/sc-codebase-index.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 136 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 749 The whole file, excluding the scripts and references it only reads on demand.
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.00136 $0.00749
Opus 5.5 $0.00054 $0.00300
Sonnet 5.5 $0.00027 $0.00150
Haiku 4.5 $0.00014 $0.00075

Measured 1mo ago against content hash 19318ba8336f, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

sc:codebase-index 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 1mo 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.

.squadcoder/skills/sc-codebase-index/SKILL.md · 48 lines

How it starts

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

Codebase indexing & semantic search (reuse the code-memory MCP)

SquadCoder ships the code-memory MCP (local, offline, no API key — uvx code-memory) for Cursor-style semantic code search. This skill tells you when and how to use it so the agent indexes and searches the codebase the way a Cursor user expects — without anyone wiring it by hand.

If the code-memory tools (index_codebase, search_code, search_docs, search_history) are not available, the MCP is disabled — fall back to grep/glob and (optionally) tell the user they can enable code-memory in Settings ▸ MCP for semantic search. Do not invent these tools.

When to use semantic search vs grep

  • Conceptual / fuzzy ("where is rate-limiting handled?", "find everything about billing", "how does auth flow work?") → semantic (search_code / search_docs). It finds relevant code even when the wording differs from the symbols.
  • Exact token (a known symbol, string literal, error code, file name) → grep/glob. Don't pay for embeddings when you already know the literal.
  • History / "who changed this and why" → search_history (commit/blame/file-history).

Flow

  1. Index once per workspace. On the first semantic query in a session (or when the user opens a new / large codebase), call index_codebase for the project root. It's incremental — re-running is cheap and keeps the index fresh after edits. The first ever run downloads the embedding model (~600 MB) and may take a minute; say so if the user is waiting.
  2. Search. Use search_code (and search_docs for prose/markdown) with a natural-language query. Pull the top hits.
  3. ALWAYS verify before acting. Semantic hits are leads, not ground truth — open the actual files and read the real lines before you edit, quote, or conclude. Never edit a file you only saw in a search snippet.
  4. Keep it fresh. After a batch of edits that change structure, re-index so later searches stay accurate.

Read the full file on GitHub · 48 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. 1mo ago First seen · 48 lines · 136 tokens per session scan A 19318ba8336f

Subscribe to this mod's changes

sc:codebase-index is a skill published in the GitHub repository squadcodercom/squadcoder (12 stars, last pushed 3mo ago), licensed MIT. It adds 136 tokens to every session and 749 once invoked, about $0.0005 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-09-03.