codexqa-code-wiki
Skill341 starsChanged 3 months agoApache-2.0View on GitHub
Builds a local architecture wiki for a repository from the CodexQA symbol graph (no model needed): modules, who calls whom and how often, reading paths, and one self-contained HTML page. Use when the user mentions codexqa-code-wiki, code-wiki, wiki, knowledge graph, architecture wiki, module map, reading guide, 代码知识图谱, 架构 Wiki, 模块地图, 阅读导览, wiki inputs, --no-llm, community detection, 社区检测, HTML 报告, or asks to map modules / generate a repo wiki without an LLM. Not change review (that is codexqa-code-analyzer), not CodexQA evidence-pack HTML review (that is codexqa-code-reviewer), and not SAST+agent code-risk scan reports (that is codexqa-defect-analyzer). Former skill name: code-wiki.
- Installs packages
In this repository13 other files it gives its agents.
- AGENTS.mdAGENTS.md
- llms.txtllms.txt
- codexqa-change-analysisSkill
- codexqa-code-analyzerSkill
- codexqa-code-reviewerSkill
- codexqa-defect-analyzerSkill
- codexqa-jev-browserSkill
- codexqa-requirement-analyzerSkill
- codexqa-rootcause-analyzerSkill
- codexqa-skill-routerSkill
- codexqa-testcase-generatorSkill
- codexqa-testdata-generatorSkill
- slot-scaffolderSkill
The file
We split this skill into the rules it gives an agent
6 rules. About 0 are common, 0 are distinctive, and 6 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈0
Distinctive · estimate
This author's own choices. Worth a look.
6
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- could be automatic: a setting could enforce it
- Very specific: line 54
Brief: Run node <skill>/scripts/wiki.mjs brief <repo>.
- Very specific: line 60
Notes: Read references/notes.md, then fill notes.json.
- Very specific: line 65
Build: Run node <skill>/scripts/wiki.mjs build <repo>.
- Very specific: line 102
Write for someone who just cloned the repo.
- Very specific: line 105
Do not run codexqa wiki without --no-llm, wiki embed, or query wiki.
- Very specific: line 107
Do not hand-edit the generated HTML.
≈ “Common” is an estimate: at least 1 in 5 of the 383,637 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Code Wiki
Three commands, one file to write:
node <skill>/scripts/wiki.mjs brief <repo> # index + export facts + print the brief
→ you write .codexqa-wiki/<repo>/notes.json # names and sentences only
node <skill>/scripts/wiki.mjs build <repo> # validate + render one HTML fileThe script owns every fact on the page: modules, sizes, call counts, groups, the architecture diagram, public symbols, files, links, search. You own the words: what the repo is, what each module does, and which reading path fits which task. You never edit HTML, CSS, or diagrams.
<skill> is this skill's directory. <repo> is a local checkout (preferred).
README.md / README.zh-CN.md are for humans; do not load them.
Documents (load on demand)
| File | Load when |
SKILL.md (this file) | always |
| references/notes.md | before writing notes.json |
| references/playbook.md | one module only, index problems, persisting for the Web UI |
| references/cli.md | codexqa missing, PATH, repo ids, maintenance |
Default flow
- Brief. Run
node <skill>/scripts/wiki.mjs brief <repo>. It indexes incrementally, exportscodexqa wiki inputs, and writes.codexqa-wiki/<repo>/withinputs.json,meta.json,brief.md, and anotes.jsonscaffold (kept if it already exists). Read the printed brief: groups, suggested paths, and per module its files, calls, callers, public symbols, and key flows. - Notes. Read references/notes.md, then fill
notes.json. EveryP01-style id and group id in it must exist in the brief. Write 简体中文 unless the user asked for English ("lang": "en").langis the language the page opens in. The HTML also has a 中文 / EN switch for the chrome; it does not translatenotes.json. - Build. Run
node <skill>/scripts/wiki.mjs build <repo>. If it printserror:lines, fix those fields and rerun; they name the field and the fix.check <repo>validates without writing HTML. - Deliver. Tell the user the printed file path plus two or three lines on what the wiki says. Do not paste the HTML or open it in chat.
The user only wants a quick look → build <repo> --draft right after
brief. The page uses rule-based names and says it is a draft. Offer to
write the notes afterwards.
Useful flags: brief --limit 8 (large repos), brief --lang en,
brief --skip-index (index is fresh), build --out FILE,
build --source-url 'https://host/repo/blob/{commit}/{path}' (file links
when the remote is not GitHub / GitLab / Gitee / Bitbucket).
Scenario routing
| User is asking… | Do |
| What is this repo / module map / architecture wiki / knowledge graph | Default flow |
| Where should I start reading / onboarding path | Default flow; put the effort into guides |
| What does module X do / who does it talk to | Answer from brief.md; deeper digest in playbook Explain one module |
| Store a rule-only wiki for the CodexQA Web UI | playbook Persist rule-only wiki |
brief failed / empty export / wrong branch | playbook Index health |
Change review, callers of a symbol, test gaps, and stack traces belong to
codexqa-code-analyzer.
Rules
- Facts come only from this run's export. Do not add modules, calls, or responsibilities that the brief does not support; do not use the README or a website as evidence for a module's role.
- A reading path follows real calls: each step must call or be called by the
next.
buildrejects anything else and lists the valid neighbours. - Standalone modules (no calls to or from other modules) get a name and a role, never a layer.
- Write for someone who just cloned the repo. No internal field names
(
deps,cross_community,called_by,wiki inputs);buildrejects them. - Do not run
codexqa wikiwithout--no-llm,wiki embed, orquery wiki. Those call a model or need model-written pages. - Do not hand-edit the generated HTML. Change
notes.jsonand rebuild.
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
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.

