Install
openclaw skills install @dennisrongo/codebase-explainerProduce a durable onboarding artifact for a codebase — writes ONBOARDING.md covering a "read this first" minimum, system overview, dependency map, startup flow, auth flow, and 5-15 important files, every claim backed by file:line citations; refreshes an existing onboarding doc instead of rewriting it. Use this skill whenever the user says "explain this codebase", "explain the codebase", "onboard me", "give me a tour", "tour this repo", "what does this repo do", "where do I start", "codebase overview", "read this first", "I haven't looked at this in months", or "/codebase-explainer" — even if they don't name the skill.
openclaw skills install @dennisrongo/codebase-explainerProduce a durable onboarding artifact — the document past-you wishes you'd written before stepping away from this repo for six months. Not a chat answer that disappears: a committed ONBOARDING.md with a tight "read this first" list, system overview, dependency map, startup flow, auth flow, and the important files. Every claim cited with file:line.
/codebase-explainer / /onboardDo not auto-trigger for:
improve-codebase-architecturetask-executordiagnosecode-reviewhandoffRead root-level signals directly to scope the exploration:
package.json, pyproject.toml, Cargo.toml, go.mod, *.csproj, *.sln, Gemfile, composer.json, pom.xml, build.gradle*.next.config.*, vite.config.*, tsconfig.json, Procfile, Dockerfile, docker-compose*.yml, main.*, Program.cs, manage.py.README.md, CONTEXT.md, docs/, any ONBOARDING.md already present.pnpm-workspace.yaml, lerna.json, nx.json, turbo.json) vs. single project.If an ONBOARDING.md already exists, this is refresh mode: read it first, then look for drift (new top-level deps, moved entry points, new/removed routes, auth changes) and update in place — don't rewrite from scratch.
Spawn subagent_type=Explore calls in a single message so they run concurrently. Brief each agent self-containedly — it has no conversation context. Default fan-out:
file:line). If a dep is genuinely non-obvious (niche library, internal fork, name that doesn't reveal its purpose), the agent MAY check context7 (or any docs-MCP server available in the environment) for a one-line "what is this library" — context7__resolve-library-id → context7__query-docs. Skip the lookup for well-known libraries (React, Express, Prisma, etc.) — the generic description is what we're trying to avoid; what matters is how it's used here. The "how it's used here" line requires a call site the agent actually opened. If no call site is found, the row reads "declared but no usage found" — that's a finding (candidate for removal), not a gap to paper over with a guess from the package name.file:line per step.file:line — never an inference from an auth library appearing in the manifest. If none, the agent must say "no auth detected" explicitly AND state what was searched (e.g. "grepped for middleware, session, jwt, [Authorize], guards — no hits") so Step 3 doesn't fabricate one.Each agent reports back in ≤300 words with file:line citations. Don't ask Explore to read entire files — ask for the specific answer plus citations.
Write the artifact to docs/ONBOARDING.md if a docs/ directory exists, otherwise ONBOARDING.md at repo root.
No-fabrication gate: every claim in the file traces to a probe run this session — a file an agent read, a grep it ran. If a claim can't name its probe, it's a hypothesis: verify it or omit it. Never fill a section by inference from framework conventions ("Next.js apps usually…").
Sections, in this order:
file:line per step.Dependency | What it does here | Key call site.file:line and a one-line "why it matters."CONTEXT.md exists or domain terms surfaced repeatedly during exploration./codebase-explainer. Re-run to refresh."No timestamps in the file body (dates rot). The git history is the timestamp.
After writing the file, render in chat: the "Read this first" bullets verbatim, plus a one-sentence pointer to the file path. Do not re-paste the full document — the file is the artifact.
If making this teammate-accessible would help, mention ShareOnboardingGuide — it uploads ONBOARDING.md and returns a link. Offer once; never auto-invoke.
User: "I haven't touched this repo since November — onboard me"
Claude:
package.json, next.config.ts, prisma/schema.prisma, existing README.md. Notes: Next.js App Router + NextAuth + Prisma + Postgres.ONBOARDING.md with startup flow rooted at app/layout.tsx:12 → lib/auth.ts:34 and auth flow citing the NextAuth authOptions and the requireSession() helper.ShareOnboardingGuide.User: "/codebase-explainer — refresh the onboarding doc, I added Stripe and a new admin route last sprint"
Claude:
docs/ONBOARDING.md. Spawns Explore agents scoped to "what's changed": new top-level deps, new routes under app/**/route.ts, auth changes.lib/payments/stripe.ts:18 citation), appends the admin route to startup flow, leaves untouched sections alone.next-auth sits in package.json vs. ✅ "Requests hit middleware.ts:8 → auth() from lib/auth.ts:12; unauthenticated users redirect at middleware.ts:19." Trace the path or write "none detected (searched: …)".file:line citations — trust them.file:line citations. A claim the next reader can't verify rots fast.ONBOARDING.md from scratch when the user asked to refresh.improve-codebase-architecture: an onboarding pass often surfaces shallow-module clusters worth a deepening review. Hand the user a pointer; don't propose refactors here.handoff: ONBOARDING.md is project-level orientation (durable across many sessions); a handoff is session-level state. Different artifacts, both useful.ShareOnboardingGuide (when available in the environment) uploads ONBOARDING.md and returns a teammate-shareable link. Optional; user-initiated.