
codebase-wiki
How to work in a Codebase Wiki project (the codebase-wiki starter pack): an agent-authored, source-grounded wiki of the surrounding codebase. Read when the project has a wiki/ knowledge base with architecture/, modules/, flows/, concepts/, and guides/ sections plus wiki/OVERVIEW.md, or when asked to generate or refresh a wiki of this codebase. Carries the per-folder rules and freshness + log discipline, summarizes the audience/depth knobs and source-reference convention, and bundles the full generate/refresh procedure in references/. Complements the platform open-knowledge skill; does not replace it.
- Installs
- 438
- Last 24h
- —
- Trending rank
- —
- Security
- Not audited
Install
Works with every agent the skills CLI supports.
npx skills add https://github.com/inkeep/open-knowledge-skills --skill codebase-wiki- 01
Install
Run the command in your project. The CLI asks which agents to install for.
- 02
Describe the task
Ask your agent for something this skill covers. It loads codebase-wiki automatically when relevant.
- 03
Review the result
The agent follows the SKILL.md steps, scripts and references bundled with the skill.
SKILL.md
The instructions your agent reads when the skill is triggered.
Codebase Wiki pack — how to work here
This project holds an agent-authored wiki of a codebase — DeepWiki, but living in the repo. A coding agent reads the source and writes a navigable, diagram-rich, source-grounded wiki as markdown under wiki/. It is version-controlled and diffable, private by default, human+agent co-editable, renders in OK's live preview, and doubles as durable grounding context for future agent sessions. There is no separate Q&A surface — Q&A is "the OK-grounded agent + search".
This skill is pack guidance. The platform
/open-knowledgeskill (read/write/preview/linking/grounding rules) still governs every markdown operation — this layers the wiki workflow on top.
The shape
wiki/
OVERVIEW.md hub: what it is, a big-picture architecture diagram, a nav map to every section.
Frontmatter carries `profile` (audience/depth) + `source_commit` (freshness anchor).
log.md append-only generation / refresh audit trail
architecture/ system boundaries, layers, subsystems, cross-cutting concerns + diagrams
modules/ one page per package / module: purpose, entry points, key files, deps
flows/ key end-to-end flows as sequence / flow diagrams + narrative
concepts/ glossary: atomic pages for domain terms / core abstractions
guides/ task-oriented "how / where do I change X" (filled at depth >= standard)
Generating + refreshing
Don't free-hand it — read references/generate-and-refresh.md and follow the phased, STOP-gated procedure. It auto-detects mode: a stubbed OVERVIEW.md (empty source_commit) → generate (survey → overview → architecture → modules → flows → concepts → link-graph audit); a stamped source_commit → refresh (diff source_commit..HEAD, update only affected pages, re-stamp).
Two toolsets. Read source code with NATIVE tools (Read/Grep/Glob/Bash) — OK MCP does not index non-markdown source. Author and audit the wiki with OK MCP verbs (write/edit for pages, links/search for the graph). Never hand-write wiki markdown with native Write/Edit.
The two knobs
Two natural-language knobs, read from the user's request (e.g. "build the wiki, public and exhaustive") and recorded in OVERVIEW.md frontmatter (profile: <audience>/<depth>) so refreshes stay consistent:
audience—internal(default) orpublic.publicmeans polished prose, no secrets / internal infra / ticket numbers, and GitHub-URL source references.depth—tour|standard(default) |exhaustive. Scales coverage from OVERVIEW + architecture + top flows up through per-package module pages, concepts, and task guides.
references/generate-and-refresh.md is the authoritative source for exactly how each knob shapes the output — read it before generating.
Source-reference convention
- Intra-wiki navigation → OK doc links — they build the backlink / hub / orphan graph, so link liberally; density is how the wiki stays navigable.
- Code references → relative links + symbol code-spans (
internal) or GitHub blob URLs (public). Source-file links stay out of the navigation graph (linkstracks only.md/.mdxedges, so they never show as graph dead-links or orphans) — but a wrong-depth path still surfaces in the write/editbrokenLinksresponse (no-such-file, orunresolvableif it overshoots the content root), so count the../hops from the page's folder. Never invent paths — reference only files you actually read.
The full rules — the GitHub-URL / relative fallback, the #Lxx caveat, and the exact code-span shape — live in references/generate-and-refresh.md.
Per-folder rules
architecture/ — One page per architectural area (boundaries, layers, subsystems, cross-cutting concerns). Each: a mermaid system-context or component diagram, key components (with source refs), and the design decisions behind them. Uses the architecture-page template. At depth: tour, modules fold in here.
modules/ — One page per package / module: purpose, responsibilities, public API / entry points, key files (linked per the convention), dependencies, and flows it participates in. Uses the module-page template. Skipped at tour; sub-module depth scales with the knob.
flows/ — Key end-to-end sequences as mermaid sequence / flow diagrams + narrative. Uses the flow-page template; add a Failure modes section at exhaustive. Link every module and concept the flow crosses.
concepts/ — Atomic glossary pages (one term each): definition, why it matters, where it lives in the code. Uses the concept-page template. Keep small and densely cross-linked so each concept becomes a hub.
guides/ — Task-oriented "how / where do I change X" walkthroughs: goal, steps, relevant code, gotchas. Uses the guide-page template. Populated at standard, rich at exhaustive, thin/empty at tour.
Freshness discipline (MUST)
OVERVIEW.md frontmatter carries source_commit — the git HEAD the wiki was last generated/refreshed against. It is the freshness anchor: refresh mode diffs source_commit..HEAD to update only the affected pages, then re-stamps it. Always re-stamp source_commit after a generate or refresh run — a stale anchor silently breaks incremental refresh.
Log discipline (MUST)
wiki/log.md is an append-only audit trail. Append one dated entry per generation or refresh run — one per run, not per page. Reference touched pages as markdown links ([Server](./modules/server.md)) so they register in the backlink graph. Entry shape:
## YYYY-MM-DD: <generate | refresh>
- Profile: <audience>/<depth>
- source_commit: <short-sha> (was <prev-sha> on refresh)
- Coverage: <sections / packages written or updated>
- Pages: [Overview](./OVERVIEW.md), [Server](./modules/server.md), ...
Templates
Each folder ships a starter template (architecture-page, module-page, flow-page, concept-page, guide-page). Create with write({ document: { path, template: "<name>" } }). Templates carry only structure (headings + frontmatter scaffold); what each section is for is described above and in references/generate-and-refresh.md, not repeated inside document bodies.
FAQ
What does the codebase-wiki skill do?
How to work in a Codebase Wiki project (the codebase-wiki starter pack): an agent-authored, source-grounded wiki of the surrounding codebase. Read when the project has a wiki/ knowledge base with architecture/, modules/, flows/, concepts/, and guides/ sections plus wiki/OVERVIEW.md, or when asked to generate or refresh a wiki of this codebase. Carries the per-folder rules and freshness + log discipline, summarizes the audience/depth knobs and source-reference convention, and bundles the full generate/refresh procedure in references/. Complements the platform open-knowledge skill; does not replace it.
How do I install codebase-wiki?
Run npx skills add https://github.com/inkeep/open-knowledge-skills --skill codebase-wiki in your project. The skills CLI detects the agents you use and copies the skill into the right folder. For Claude Code you can also place the skill folder at ~/.claude/skills/codebase-wiki/ (personal) or .claude/skills/codebase-wiki/ (project).
Which AI agents can use codebase-wiki?
Any agent that supports the open Agent Skills format (a folder with a SKILL.md file), including Claude Code, Codex, Cursor, GitHub Copilot, Gemini CLI, Windsurf, Cline, OpenCode and more.
Is codebase-wiki safe to install?
No partner security audit is available yet. Skills can run commands and scripts, so read the SKILL.md and any bundled files before installing.
Who maintains codebase-wiki?
It is published by inkeep in inkeep/open-knowledge-skills. It has 438 recorded installs.
More from inkeep/open-knowledge-skills
open-knowledge-discovery
inkeep/open-knowledge-skills
Read when the user asks what OpenKnowledge is, wants to install it on a repository, wants to open or preview a single markdown file that is not part of an OpenKnowledge project, wants to share an OpenKnowledge project with collaborators, asks whether OpenKnowledge supports a particular capability, or asks how ok init / ok cowork / OK Desktop set up a project. Do NOT load to perform OpenKnowledge reads/writes — the runtime guidance for editing markdown inside an initialized OK project ships as a separate project-local skill installed into each detected agent's skills dir (for example .claude/skills/open-knowledge/) whenever ok init runs.
okf-knowledge-base
inkeep/open-knowledge-skills
Open Knowledge Format (OKF) v0.2 guidance. Use when creating, reading, reviewing, or maintaining an OKF bundle; responding to OpenKnowledge okf plugin warnings; or choosing types, provenance, links, indexes, or logs.
open-knowledge-write-skill
inkeep/open-knowledge-skills
Use when the user wants to create, author, write, or design a new Agent Skill (a SKILL.md) — for OpenKnowledge or for their editors — including requests like 'help me write a skill', 'make a skill that…', 'turn this workflow into a skill', or improving an existing skill's triggering and discipline. Also use when capturing reusable agent guidance that should live as an installable skill rather than a one-off prompt. Covers choosing scope (project vs global), authoring inside a plugin or skills-distribution repo (write in the repo's own layout, never install), the SKILL.md frontmatter contract, progressive-disclosure structure, evaluating the skill, and installing it into the user's editors.
open-knowledge
inkeep/open-knowledge-skills
Authoritative agent-runtime contract for working inside an OpenKnowledge project — a markdown-CRDT knowledge base exposed over MCP. Use whenever reading, listing, searching, editing, or linting any .md or .mdx file in the project, and before any mcpopen-knowledge tool call (exec, search, write, edit, lint, and the rest). Installed by ok init, so its presence means this is an OpenKnowledge project and it governs every markdown file here. Covers the read/write tool surface, grounding and linking rules, folder/template conventions, the live browser preview, and the rule that OK's MCP tools — never native file tools — handle in-scope markdown.
knowledge-base
inkeep/open-knowledge-skills
How to work in a Knowledge Base project (the knowledge-base starter pack). Read when the project has the three-layer source-grounded layout — external-sources/ → research/ → articles/ — or when asked how this project is organized. Carries the layer model, per-folder rules, status flows, and log discipline so this guidance does NOT live inside template bodies or log.md. The three procedures live elsewhere: ingest in the platform open-knowledge skill, research and consolidate as their own sibling skills in this pack. Complements the platform open-knowledge skill; does not replace it.
research-with-sources
inkeep/open-knowledge-skills
Investigate a topic against preserved sources and write a draft-status research article under research/ in a Knowledge Base project (the knowledge-base starter pack). Read when asked to research a topic, compare options, synthesize sources, gather evidence, or extend an existing research doc. Carries the full procedure: scan existing coverage, agree a research rubric, capture every source verbatim before analyzing, write the article incrementally so a crash never loses work, cite every claim, and link it back into the graph. Does not promote findings to canonical knowledge — that is the sibling consolidate-notes skill, after a decision lands.
Popular code quality & workflow skills
grill-me
mattpocock/skills
A relentless interview to sharpen a plan or design.
improve-codebase-architecture
mattpocock/skills
Scan a codebase for deepening opportunities, present them as a visual HTML report, then grill through whichever one you pick.
handoff
mattpocock/skills
Compact the current conversation into a handoff document for another agent to pick up.
domain-modeling
mattpocock/skills
Build and sharpen a project's domain model. Use when discussing codebase terminology, writing or editing a GLOSSARY.md, or recording or editing an ADR.
codebase-design
mattpocock/skills
Shared vocabulary for designing deep modules. Use when the user wants to design or improve a module's interface, find deepening opportunities, decide where a seam goes, make code more testable or AI-navigable, or when another skill needs the deep-module vocabulary.
diagnosing-bugs
mattpocock/skills
Diagnosis loop for hard bugs and performance regressions. Use when the user says "diagnose"/"debug this", or reports something broken/throwing/failing/slow.