agentleFS
shinzoxDshinzoxD/knackbox/skills/coding/codebase-orientation/SKILL.md

codebase-orientation

Skill0 starsChanged 5 months agoApache-2.0View on GitHub

Orient an engineer (or agent) in an unfamiliar codebase — map

4 other projects use a version of this.

Adopted by

Most recently taken up by

The file

We split this skill into the rules it gives an agent

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

  • 0

    Common

    Most of the 4 edited versions we read keep these.

  • 4

    Distinctive

    This author's own choices. Worth a look.

  • 0

    Very specific

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

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Where to change X: Search names, routes, types, and tests.

    line 41
  2. Distinctive:

    Never invent package names, binaries, or scripts.

    line 68
  3. Distinctive:

    Do not dump the whole tree.

    line 72
  4. Distinctive:

    If the checkout is sparse or blocked, say what you could not see instead of filling gaps.

    line 77

“Common” is measured: kept by at least 6 in 10 of the 4 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

Codebase Orientation

Map the tree from evidence, not memory. Never invent package names, scripts, or paths. Output a map, entrypoints, how to run, and where to change X.

Company onboarding is onboarding-guides. A specific crash or 500 is debugging. New API design is api-design. Daily status is standup-updates.

Workflow

  1. Scope. Whole repo vs "where is X". If they name X, hunt that first; still sketch the map so X has a place.
  2. Inventory. List the repo root. Read README, CONTRIBUTING, and the manifests that exist (package.json, pyproject.toml, Cargo.toml, go.mod, Makefile, CI). Quote names you saw.
  3. Map modules. First-party directories only. Skip node_modules, vendor, dist, build, .git, .venv, target. One line per module: path → role, with the file that proves it.
  4. Entrypoints. Files that start a process: main, cmd/, bin/, app/, src/index.*, documented CLIs, server listen sites. Cite the file.
  5. How to run. Copy install/test/dev commands from those manifests, Makefile, or CI — not from habit. If README and a script block disagree, prefer the file that would actually execute; note the conflict.
  6. Where to change X. Search names, routes, types, and tests. Rank 1–3 files with why. Stop at the location; do not design the change unless asked.

Output format

## Map
| Path | Role | Evidence |

## Entrypoints
- `path` — what it starts (evidence)

## How to run
- install: `…` (from …)
- tests: `…` (from …)
- app/dev: `…` (from …)

## Where to change
**X:** `file` — why. Next: `file`.

## Unknowns
- commands or paths not in the tree

Rules

  1. Never invent package names, binaries, or scripts. If it is not in the tree, write not found.
  2. Distinguish facts (paths, script names) from inferences (what a folder "probably" does). Label them.
  3. Do not dump the whole tree. Top-level plus one extra level into the relevant subtree.
  4. Generated code: point at the generator or schema, not the generated dump.
  5. Execution is optional. List and read first. Run existing test/help only when allowed, to confirm how-to-run. Do not install deps unless asked.
  6. If the checkout is sparse or blocked, say what you could not see instead of filling gaps.

Good: packages/cli/bin/knackbox.js is the CLI (package.json bin). Tests: the test script in that package's package.json. Bad: "Typical Express app; run npm test with Jest."

Edge cases

  • Monorepo: map packages/apps/crates first; dive only into the asked package.
  • No tests found: say so; do not invent pytest or npm test.
  • Multiple languages: one how-to-run section per runtime.
  • User pastes a tree only: orient from that paste; do not assume files they did not show.
  • "Write our new-hire handbook": onboarding-guides, not this skill.

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.