agentleFS
iadr-deviadr-dev/colab/skills/explore-codebase/SKILL.md

explore-codebase

Skill2 starsChanged 7 months agoMITView on GitHub

Systematically understand an unfamiliar codebase or feature area. Outputs a populated .ohc/PROJECT.md with stack, architecture, conventions, entry points, and gotchas. Run at project start or when entering new feature territory.

  • Reads credentials

13 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use debug-issue, review-changes and 4 more.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • NVIDIASkill

    debug-issue

    Use when the user asks to debug, investigate, or fix a GitHub issue or supplies a repository bug report.

    Also in 5 projects that use this

  • DockerSkill

    review-changes

    Review uncommitted or recently committed documentation changes for correctness, coherence, and style compliance. Use before creating a PR to catch issues. "review my changes", "review the diff", "check the fix before submitting", "does this look right".

    Also in 4 projects that use this

  • testified-ossSkill

    incident-triage

    Triage production incidents with severity assessment, root cause hypothesis, impact analysis, and escalation recommendations. Use when analyzing outages, errors, or production issues.

    Also in 3 projects that use this

  • zbruhnkeSkill

    explain-code

    Explain how code works in detail. Use when trying to understand unfamiliar code, complex logic, or system architecture.

    Also in 3 projects that use this

  • SentrySkill

    write-tests

    Write tests following project conventions. Use when adding new tests or modifying existing ones.

    Also in 3 projects that use this

  • GoogleSkill

    code-review

    Adversarial systems, concurrency, memory-model, and architecture code review protocol. Use this skill whenever asked to review code, PRs, diffs, or branches in Filament.

    Also in 3 projects that use this

The file

We split this skill into the rules it gives an agent

4 rules. 0 are common, 2 are distinctive, and 2 are very specific to this project.

  • 0

    Common

    Most of the 11 edited versions we read keep these.

  • 2

    Distinctive

    This author's own choices. Worth a look.

  • 2

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Use when: new project, new feature area, or significant time since last session.

    line 12
  2. Distinctive:

    Stop when you can answer all output questions below.

    line 16
  3. Very specific:

    Test configuration (jest.config.ts, pytest.ini, vitest.config.ts, flutter test, XCTest)

    line 33
  4. Very specific:

    Write findings to .ohc/PROJECT.md:

    line 41

“Common” is measured: kept by at least 6 in 10 of the 11 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Explore Codebase

Use when: new project, new feature area, or significant time since last session.

Reading Order

Stop when you can answer all output questions below.

Round 1 — Project meta (always read)

  1. README.md — purpose, quick start, architecture overview
  2. package.json / pyproject.toml / go.mod / Cargo.toml / pubspec.yaml / build.gradle — deps, scripts, version
  3. .env.example — what environment the app expects
  4. docker-compose.yml or Dockerfile — infrastructure shape
  5. (Monorepo) pnpm-workspace.yaml / turbo.json / nx.json / lerna.json — workspace structure

Round 2 — Entry points

  1. Main entry file (src/index.ts, main.py, cmd/main.go, lib/main.dart, MainActivity.kt, ContentView.swift)
  2. Router / URL definitions (routes.ts, urls.py, router/index.ts)
  3. Database schema (schema.prisma, drizzle.config.ts, models.py, migrations/)
  4. (Mobile) App manifest (AndroidManifest.xml, Info.plist, app.json)

Round 3 — Tests

  1. One complete test file — understand test style and patterns
  2. Test configuration (jest.config.ts, pytest.ini, vitest.config.ts, flutter test, XCTest)

Round 4 — Spot checks (3 files minimum)

  1. 3 representative source files — understand code style, patterns
  2. CI configuration (.github/workflows/)

What to Extract

Write findings to .ohc/PROJECT.md:

  • Tech stack: language, runtime (Node/Deno/Bun), framework, ORM, test runner, package manager, CI
  • Monorepo: tool used, workspace layout, shared packages
  • Entry points: main file, router file, config files, test directory
  • Architecture: how data flows (client → API → service → DB or similar)
  • Conventions: naming style, file structure, import style, error handling
  • Gotchas: anything surprising, undocumented, or non-obvious

Run the Generator

# Node (preferred — zero Python dependency):
node skills/explore-codebase/scripts/generate-project-map.js

# Python fallback (if Node 18+ unavailable):
python3 skills/explore-codebase/scripts/generate-project-map.py

Auto-detects stack and fills the tech stack table in PROJECT.md.

Output

Tell user: "Exploration complete. PROJECT.md updated. Key findings: [top 3]"

See references/exploration-checklist.md for full checklist.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.