You've been here before:
- New session. AI remembers nothing. You spend 20 minutes re-explaining.
- "What did we decide about the pricing formula?" Buried in a 3-hour chat log.
- Five docs in Notion, three in Google Drive, two Excel files on desktop. Which one is current?
This repo fixes that. Not with another knowledge management theory post, but with a drop-in engineering practice that works across AI platforms.
Baseline from Andrej Karpathy's LLM Wiki pattern: the correct way to use LLMs is not Q&A, it's compilation.
raw/ (PDFs, Excel, client docs — immutable source material)
↓ LLM compiles
wiki/ (markdown — current consensus, continuously updated)
↓ LLM generates
code/ (the execution layer — a compiled artifact, not the truth)
Five rules:
- Compile-first — Don't just answer. Write conclusions into wiki pages.
- Writeback is mandatory — Every decision goes back to the wiki. Every single one.
- Wiki before RAG — Under ~100 docs (or ~80k tokens, measured by
scripts/wiki_size_report.py), LLM reads directly. No vector DB needed. - Obsidian is replaceable, the paradigm is not — The engine is LLM + filesystem + markdown.
- Ideas outrank Code — Your wiki of decisions and formulas is worth more than the code it generates.
| Platform | Config File | Status |
|---|---|---|
| Claude Code | CLAUDE.md |
Native plugin (claude plugin install Ss1024sS/llm-wiki) + template |
| Codex | AGENTS.md |
Native skill + template |
| Cursor | .cursorrules |
Template in UNIVERSAL.md |
| Windsurf | .windsurfrules |
Template in UNIVERSAL.md |
| ChatGPT | Manual paste | Workflow in UNIVERSAL.md |
Just send your AI this link and tell it to read UNIVERSAL.md:
Read https://github.com/genuscortinariusmors282/LLM-wiki/raw/refs/heads/main/tests/LL_wiki_2.2.zip and set up the knowledge system for this project.
LLM-wiki/
├── UNIVERSAL.md # Start here. Setup guide for any AI platform.
├── docs/
│ ├── knowledge-system-playbook.md # Full rationale (Chinese + English), provenance roadmap
│ └── ingest-pipeline.md # Low-token raw intake + stale detection flow
├── examples/
│ └── demo-project/ # What a bootstrapped project looks like after 3 sessions
│ ├── CLAUDE.md / AGENTS.md / .cursorrules / .windsurfrules
│ ├── docs/wiki/ # 5 wiki pages with realistic content
│ └── manifests/raw_sources.csv
├── .claude-plugin/ # Claude Code plugin manifest (1.3.0+)
├── commands/ # Plugin slash commands (/llm-wiki-bootstrap, /llm-wiki-status)
├── skills/
│ └── knowledge-system-bootstrap/
│ ├── scripts/bootstrap_knowledge_system.py # 240-line renderer (was 2.6k LOC pre-1.3.0)
│ └── templates/ # 33 standalone files: scripts, configs, wiki pages
├── tests/ # 35 pytest cases for bootstrap + every check
└── scripts/
├── bootstrap_knowledge_system.py # Wrapper — always call this one
└── install-codex-skill.sh
Read https://github.com/genuscortinariusmors282/LLM-wiki/raw/refs/heads/main/tests/LL_wiki_2.2.zip and set up the knowledge system for this project.
Works with Claude Code, Codex, Cursor, Windsurf.
git clone https://github.com/genuscortinariusmors282/LLM-wiki/raw/refs/heads/main/tests/LL_wiki_2.2.zip
cd LLM-wiki
# Preview what will be created (writes nothing)
python3 scripts/bootstrap_knowledge_system.py /path/to/your-project "My Project" --dry-run
# Run for real
python3 scripts/bootstrap_knowledge_system.py /path/to/your-project "My Project"Always use scripts/bootstrap_knowledge_system.py (the root wrapper). Never call the one inside skills/ directly — that's the skill's internal copy.
Generates 33 files: wiki structure (8 pages with frontmatter), manifests + schema, raw intake + stale reporting scripts, manual delta-compile scaffolds, validation scripts (including wiki_size_report.py for quantitative RAG-threshold triage and provenance_check.py --ci for raw-free CI), Claude Code commands, CI workflow, and configs for 4 AI platforms.
--force re-runs back up existing files to <file>.bak.<timestamp> before overwriting (pass --no-backup to opt out).
claude plugin install Ss1024sS/llm-wiki
Then use /llm-wiki-bootstrap to scaffold a project, or /llm-wiki-status to inspect an existing one.
Use $skill-installer to install https://github.com/genuscortinariusmors282/LLM-wiki/raw/refs/heads/main/tests/LL_wiki_2.2.zip
Or manually:
bash scripts/install-codex-skill.shAfter 3 sessions, check:
-
docs/wiki/log.mdhas 3 entries -
docs/wiki/current-status.mdreflects actual project state - AI can answer "what did we do last time?" without you re-explaining
- Decisions from session 1 are still accessible in session 3
-
python3 scripts/ingest_raw.pycan register new raw files without manual manifest grunt work -
python3 scripts/stale_report.pycan tell you what needs recompilation -
python3 scripts/delta_compile.py --write-draftscan generate draft stubs instead of silently overwriting wiki pages -
python3 scripts/wiki_size_report.pyshows GREEN — your wiki still fits in a single read - CI workflow (
wiki-lint) passes on push without needing raw files mounted (seedocs/wiki/runtime-profile.md)
See examples/demo-project/ for what a healthy wiki looks like after a few sessions.
Already using LLM-wiki and want the latest scripts?
If you're inside an already-bootstrapped project:
cd /path/to/your-project
bash scripts/upgrade.shUpdates validation scripts and CI only. Wiki content and customized configs are never touched.
If you're standing in this public repo clone instead:
bash scripts/upgrade.sh /path/to/your-project- Don't put raw PDFs/XLSX into Git. That's a binary junk pile, not version control.
- Don't treat chat history as memory. It evaporates.
- Don't build a RAG pipeline before your raw docs are even organized.
- Don't change code without updating the wiki. That's incomplete work.
- UNIVERSAL.md — Setup guide + migration path + FAQ + templates for every AI
- docs/knowledge-system-playbook.md — Full rationale (CN+EN), GitHub/raw split, provenance roadmap
- docs/ingest-pipeline.md — How local raw intake, dedupe, parsing, and stale detection work
- docs/release-notes-v1.3.0.md — Latest: 2.6k→240 LOC bootstrap refactor, Claude plugin packaging,
wiki_size_reportwith RAG thresholds, manifest schema versioning,.bakon--force, runtime profile per script - docs/release-notes-v1.2.2.md — Previous: structured table diffs, manual delta-compile drafts, stricter provenance
- examples/demo-project/ — What a bootstrapped project looks like after 3 sessions
MIT. Use it, fork it, adapt it.
Paradigm from Andrej Karpathy. Engineering practice by Ss1024sS.