scan-codebase

Solid

Scan the Python codebase and build a structural JSON index (import graph + blast-radius metrics + symbol table). Explicit invocation only via `$codemap-py:scan-codebase [--root <path>] [--incremental]` — never auto-trigger this from conversation reasoning. Use when the index is missing, stale, or after significant project changes.

AI & Automation 23 stars 3 forks Updated today Apache-2.0

Install

View on GitHub

Quality Score: 81/100

Stars 20%
46
Recency 20%
100
Frontmatter 20%
70
Documentation 15%
100
Issue Health 10%
80
License 10%
100
Description 5%
100

Skill Content

# Scan Codebase Python only — `ast.parse` extracts import graph + symbol metadata (classes, functions, methods with line ranges) across every `.py` file; non-Python files are not indexed. Writes `.cache/codemap/<project>.json`. No external dependencies. Zero-Python project (no `.py` files): index writes but empty — downstream queries return no results. Symbol data lets `$codemap-py:query-code symbol`/`find-symbol` return target function source instead of a full file read (~70–94% token reduction vs `Read`). NOT for: querying an existing index (use `$codemap-py:query-code`); integration health checks (use `$codemap-py:integration`). **Explicit invocation only** — Codex has no `disable-model-invocation` frontmatter field, so this constraint is enforced by convention, not schema: never call this skill from autonomous reasoning; run it only in direct response to the user's literal `$codemap-py:scan-codebase` trigger. ## Runtime note Codex has no `bin/` PATH entry and no `$CLAUDE_PLUGIN_ROOT`-equivalent environment variable. Resolve this skill's installed plugin-root path once, then substitute that literal path for `PLUGIN_ROOT` in every command below. Shell state (including exported variables) does not persist across tool calls — keep the resolved path in reasoning and paste it in literally rather than caching it in a shell variable or tmpfile. ## Workflow ### Step 1: Run the scanner Parse the invocation text for `--root <path>` and `--incremental`. Any other `--`-prefix...

Details

Author
Borda
Repository
Borda/AI-Rig
Created
5 months ago
Last Updated
today
Language
Python
License
Apache-2.0

Similar Skills

Semantically similar based on skill content — not just same category