Catalogue / codebase-scout
codebase-scout
Older skill: source not recordedSignedTurns an unfamiliar repository checkout into a written, evidence-cited briefing covering project layout, the toolchain read from manifest files, documented contributor rules, recurring code habits, and the maintainers' issue and pull-request template and label conventions. Produces one markdown brie…--- name: codebase-scout description: > Turns an unfamiliar repository checkout into a written, evidence-cited briefing covering project layout, the toolchain read from manifest files, documented contributor rules, recurring code habits, and the maintainers' issue and pull-request template and label conventions. Produces one markdown briefing outside the studied repository and returns a short summary to the caller. Use when the user asks to onboard onto, summarize, audit the conventions of, or hand off a codebase that exists on the local machine. Not for editing code, debugging, running builds or tests, or studying repositories that are not locally available. license: MIT ---
Codebase Scout
An unfamiliar repository already holds most of the answers someone needs: the maintainers wrote many of them down, and the code reveals the rest through repetition. Your job is to read a checkout thoroughly, keep documented rules separate from mere habits, and leave behind one briefing file that lets the next person — human or agent — act with confidence. You never modify the repository itself; the briefing is your only output, and it lives outside the repository.
This skill adapts an MIT-licensed community skill for repository research; preserve the MIT terms if you redistribute this file.
What to settle with the user first
Ask for anything missing before you begin:
- Repository path — the local checkout to study. Required.
- Research focus — optional, e.g. "how failures are reported to callers" or "what it takes to add a new endpoint". When given, put it first during pattern work and name it in the brief.
- Briefing directory — where the briefing goes. Required, and it must sit outside the studied repository.
Skim the shape before reading anything
Reading in depth only pays off once you know where things live:
- List the repository root including dotfiles, to spot documentation, manifests, and CI configuration at a glance.
- Map directories two to three levels deep.
- Form a rough picture of where source, tests, and configuration concentrate.
Use whatever listing tools the environment offers; shell equivalents:
ls -A <repo-root> find <repo-root> -maxdepth 2 -type d -not -path '*/.git/*'
Read the rulebook cover to cover
Read these in full rather than sampling — they encode decisions already made on the reader's behalf:
README.mdfor purpose, audience, and the quickstart.CONTRIBUTING.mdfor how changes are expected to arrive.ARCHITECTURE.mdor adocs/design folder for settled decisions.- Agent instruction files (
CLAUDE.md,AGENTS.md, editor rule files) — treat these as binding for any follow-on work. - CI workflow definitions — the project's quality gates, in writing.
For each document, note its freshness (last commit date or file modification time) so the brief can flag rules that may have drifted from reality.
Identify the stack from its manifests
Manifests are authoritative; trust them over guesses inferred from imports.
| File at the root | Usually means | Also settle | |---|---|---| | package.json | JavaScript or TypeScript | npm, pnpm, yarn or bun — let the lockfile name decide | | pyproject.toml, setup.py, requirements*.txt | Python | pip, poetry or uv, from lock and build config | | Cargo.toml | Rust | edition, workspace members | | go.mod | Go | module path, toolchain version | | Gemfile | Ruby | bundler | | composer.json | PHP | | | pom.xml, build.gradle* | JVM | maven or gradle | | mix.exs | Elixir | |
Record language, framework, package manager, build tool, and test runner in the brief, each with the file that proves it — the test runner often shows up as a script entry or a dedicated config file such as a vitest or pytest setting.
Learn how maintainers triage issues and pull requests
Issue intake is a convention like any other, and the label scheme is part of it. Gather everything a checkout can prove:
- Read every file under the issue-template directory — markdown templates and YAML form definitions alike — plus the chooser config that can redirect reporters to support links.
- Find the pull-request template wherever it hides: the
.githubdirectory, adocs/folder, or a variant filename. - Look for any further templates the project keeps, such as RFCs, feature requests, or security reports.
- Hunt for label evidence: workflow files that add, require, or gate on labels; label-definition files kept in the repository;
CODEOWNERSmappings; bot configuration that auto-labels incoming work. From these, reconstruct the categorization scheme — which labels express kind (bug, feature), which express area or subsystem (often a shared prefix plus a module name), which express priority or status, and whether humans or automation apply them.
Label definitions often exist only on the hosting platform. When the checkout holds no trace of them, record exactly that — "no label conventions discoverable locally; labels appear to be managed on the platform" — instead of inventing a scheme. A finding of absence is still a finding and belongs in the brief.
Example of a well-evidenced line: "Automation applies area: payments and kind: bug during triage (.github/workflows/triage.yml:18); no local evidence of priority labels."
Mine the code for habits, and cite everything
Start with the user's focus if one was given; otherwise cover naming, file placement, import style, error handling, and test layout.
- Search for repeated shapes with the environment's grep and glob tools, filtered to source files.
- Call something a habit only after two independent sightings or an explicit written rule — never generalize from a single example.
- Cite evidence as
path/to/file.ext:line. - Keep two buckets that never mix: written rules (a document says so) and inferred habits (the code consistently does so).
- Nominate one small, idiomatic file as the model that later work should imitate, and explain why it is a good model.
Example: "Route handlers live one-per-file under routes/ and export a default function — routes/charges.ts:6, routes/refunds.ts:1 (inferred)."
Save the briefing without clobbering anything
Default destination: briefing-<repo-name>.md inside the directory the user chose. Resolve the filename before writing a single byte:
- Check whether that path already exists.
- If it does not exist, proceed.
- If it does exist, stop — do not overwrite. Show the user the path and the existing file's title line, then ask: replace it, or save under a new name? Replace only on an explicit yes from the user; anything less means you derive an unused filename (for instance by appending a number) and state clearly where the briefing went.
Then write the brief to this shape, filling every heading — write "none found" rather than dropping a heading:
# Briefing: <repo-name> Captured <ISO date> · Focus: <user focus or "general"> ## What this project is Two sentences: purpose and intended audience. ## Stack | Layer | Choice | Shown by | | Language | TypeScript 5.x | package.json | | Package manager | pnpm | pnpm-lock.yaml | | Test runner | Vitest | vitest.config.ts | ## Map of the tree Key directories and entry points, one line each. ## Rules the project wrote down One bullet per documented rule, citing the document and section. ## Habits the code shows Patterns with path:line evidence, each marked (inferred). ## Issue and PR intake | Template | Path | It requires | | Bug form | .github/ISSUE_TEMPLATE/bug.yml | version, steps, logs | Labels: <the scheme with evidence, or the no-local-evidence sentence> ## Sharp edges Generated files that are also hand-edited, undocumented setup steps, documents that have drifted (with their dates). ## File to imitate Path to one small exemplary file and why. ## Where to start Two or three ordered steps toward the user's stated goal. ## Files read Every path consulted.
Hand a summary back
Close with this for the caller:
Briefing finished — <repo-name> Saved: <path> Stack: <language · package manager · test runner> Shape: <one line on layout> Worth knowing: 1. <finding> (<path>) 2. <finding> (<path>) Next step can be planning, a contribution, or implementation.
What you must not do
- Never create, edit, delete, or move anything inside the repository under study; the briefing is your only output and belongs in the agreed directory outside it.
- Never replace an existing file at the destination without the explicit confirmation described above.
- Never run the project's build, tests, package installs, or any of its scripts — this is a static reading exercise.
- Never open files whose purpose is holding secrets, such as environment-variable files, key stores, or credential directories; note that they exist and move on.
- Never state a finding without a path behind it, or promote one sighting to a convention without a second sighting or a written rule.
This skill does not cover spawning sub-agents or orchestrating studies of several repositories at once; it runs as one pass in the current session, and everything it needs is contained in this file.
| File | Size | SHA-256 |
|---|---|---|
| SKILL.md | 9.3 kB | bebb10e075f4 |
| THIRD_PARTY_NOTICES.md | 1.4 kB | 12c1367b794f |
| examples.json | 1.9 kB | 145651221e78 |
Published verbatim from the pinned commit. Nothing is rewritten.
| Version | Pinned commit | Signed | |
|---|---|---|---|
| 1.0.0 Current | Not recorded | 13 Oct 2026 |
Locking a skill to one version needs Pro.