Skip to content
Back to search

llm-wiki

Hệ thống knowledge base cá nhân hoàn toàn tự động, vận hành bởi LLM. Dựa trên pattern LLM Wiki của Andrej Karpathy.

Safety scan

A static text scan, not a guarantee. Select the badge to see what was scanned and every finding.

Checked today
Badge for your README
findsafeskills safety rating

Markdown

[![findsafeskills safety rating](/api/listings/mduongvandinh--llm-wiki/badge.svg)](/listings/mduongvandinh--llm-wiki)

HTML

<a href="/listings/mduongvandinh--llm-wiki"><img src="/api/listings/mduongvandinh--llm-wiki/badge.svg" alt="findsafeskills safety rating" /></a>

Install

i

Install instructions from the README

As written by the repo's author. findsafeskills has not verified these steps.

Option A — Start with a ready-made variant (recommended)

Don't configure from scratch. Pick a variant that matches your use case — config, schema, and demo data are pre-tuned:

git clone https://github.com/mduongvandinh/llm-wiki.git my-wiki
cd my-wiki

# Install skill (Claude Code only — other tools skip this)
cp -r skills/llm-wiki ~/.claude/skills/llm-wiki

# Pick your variant:
/llm-wiki setup book-companion      # 📚 Reading companion
/llm-wiki setup competitive-intel   # 🎯 Track competitors
/llm-wiki setup job-search          # 💼 Job search research

Option B — Start from scratch

git clone https://github.com/mduongvandinh/llm-wiki.git my-wiki
cd my-wiki

cp config.example.yaml config.yaml
# Edit config.yaml: set your topics, keywords, feeds

Then drop content into `raw/articles/` and run your first cycle.

---

What was scanned

The files the safety scan read, as written by the repository's author and shown as plain text. Lines with a finding are marked.

README.md · README · 476 lines

View this file on GitHub (read at the repository's current version: the scan did not record which commit it read)

  1. # LLM Wiki
  2. **A personal knowledge base that builds and maintains itself.**
  3. Drop articles, notes, PDFs, or Reddit threads into a folder. Your AI reads everything, builds a structured wiki with cross-references, detects contradictions between sources, and keeps it all up to date — automatically.
  4. You just read and ask questions.
  5. > Inspired by [Andrej Karpathy's LLM Wiki pattern](https://gist.github.com/karpathy/442a6bf555914893e9891c11519de94f). Extended with auto-discovery, Reddit scanning, GitHub tracking, and ready-made variants for common use cases.
  6. ---
  7. ## Why not just use RAG?
  8. | | Traditional RAG | LLM Wiki |
  9. |---|---|---|
  10. | Knowledge | Re-retrieved fresh every query | Compiled once, maintained continuously |
  11. | Cross-references | None | Built and maintained automatically |
  12. | Contradictions | Not detected | Flagged immediately on ingest |
  13. | Compounding | Flat | Grows richer over time |
  14. | Infrastructure | Vector DB + embeddings | Just folders + markdown |
  15. ---
  16. ## Quick Start
  17. ### Option A — Start with a ready-made variant (recommended)
  18. Don't configure from scratch. Pick a variant that matches your use case — config, schema, and demo data are pre-tuned:
  19. ```bash
  20. git clone https://github.com/mduongvandinh/llm-wiki.git my-wiki
  21. cd my-wiki
  22. # Install skill (Claude Code only — other tools skip this)
  23. cp -r skills/llm-wiki ~/.claude/skills/llm-wiki
  24. # Pick your variant:
  25. /llm-wiki setup book-companion # 📚 Reading companion
  26. /llm-wiki setup competitive-intel # 🎯 Track competitors
  27. /llm-wiki setup job-search # 💼 Job search research
  28. ```
  29. ### Option B — Start from scratch
  30. ```bash
  31. git clone https://github.com/mduongvandinh/llm-wiki.git my-wiki
  32. cd my-wiki
  33. cp config.example.yaml config.yaml
  34. # Edit config.yaml: set your topics, keywords, feeds
  35. ```
  36. Then drop content into `raw/articles/` and run your first cycle.
  37. ---
  38. ## Variants
  39. Pre-configured templates for specific use cases. One command setup, includes demo data.
  40. | | Variant | Use Case | Key Command |
  41. |---|---------|----------|-------------|
  42. | 📚 | [book-companion](variants/book-companion/README.md) | Build a companion wiki as you read — characters, timeline, factions, lore auto-extracted | `book-summary` · [demo](demo/book-companion/) |
  43. | 🎯 | [competitive-intel](variants/competitive-intel/README.md) | Track competitors, detect pricing/feature changes, generate battlecards | `competitive-brief "Linear"` |
  44. | 💼 | [job-search](variants/job-search/README.md) | Research target companies, prep interview 1-pagers | `interview-prep "Stripe"` |
  45. → [See all variants →](variants/README.md)
  46. ---
  47. ## Using with Your AI Tool
  48. LLM Wiki works with any AI coding assistant. The wiki is just folders and markdown — the AI reads `CLAUDE.md` (or `AGENTS.md`) to understand the schema and rules, then operates on files.
  49. ### Claude Code
  50. The primary supported tool. Has a slash command skill for the best experience.
  51. **Install the skill:**
  52. ```bash
  53. cp -r skills/llm-wiki ~/.claude/skills/llm-wiki
  54. ```
  55. **Commands:**
  56. ```bash
  57. /llm-wiki setup book-companion # Set up a variant
  58. /llm-wiki run # Full cycle: discover → ingest → lint
  59. /llm-wiki ingest # Process new files in raw/
  60. /llm-wiki query "What is X?" # Ask questions against the wiki
  61. /llm-wiki discover # Auto-find new sources from the web
  62. /llm-wiki lint # Health check: contradictions, orphans, gaps
  63. /llm-wiki status # Overview of wiki state
  64. /llm-wiki digest # Daily brief: new sources, insights, changes
  65. /llm-wiki book-summary # Structured book summary (book-companion variant)
  66. /llm-wiki competitive-brief "Name" # Battlecard for a competitor
  67. /llm-wiki interview-prep "Company" # Interview prep 1-pager
  68. ```
  69. **Auto-run:**
  70. ```bash
  71. /loop 1h /llm-wiki run # Runs every hour in current session
  72. /loop 2h /llm-wiki run # Every 2 hours
  73. ```
  74. ---
  75. ### Cursor
  76. Cursor reads `AGENTS.md` from the project root automatically. No installation needed.
  77. **Open the project in Cursor, then chat:**
  78. ```
  79. Follow AGENTS.md. Run full cycle: discover new sources, ingest into wiki, then lint.
  80. ```
  81. ```
  82. Follow AGENTS.md. Ingest everything new in raw/ and update the wiki.
  83. ```
  84. ```
  85. Follow AGENTS.md. Query the wiki: what do we know about [topic]?
  86. ```
  87. ```
  88. Follow AGENTS.md. Run competitive-brief for "Linear" and save to outputs/.
  89. ```
  90. ---
  91. ### GitHub Copilot (VS Code)
  92. Copilot reads `.github/copilot-instructions.md` automatically when you open the project. No installation needed.
  93. **Open project in VS Code, then use Copilot Chat:**
  94. ```
  95. Read CLAUDE.md then run discover, ingest, and lint for this wiki.
  96. ```
  97. ```
  98. Based on the wiki schema in CLAUDE.md, ingest the new files in raw/articles/.
  99. ```
  100. ```
  101. Query the wiki: summarize everything we know about [topic].
  102. ```
  103. > **Note:** Copilot Chat doesn't support background loops. Run manually or use system scheduler.
  104. ---
  105. ### Windsurf (Codeium)
  106. Windsurf reads `AGENTS.md` or `.windsurfrules` from the project root.
  107. **Chat in Windsurf:**
  108. ```
  109. Read AGENTS.md. Run the full llm-wiki cycle: discover → ingest → lint.
  110. ```
  111. ```
  112. Read AGENTS.md. I've added new files to raw/articles/. Please ingest them into the wiki.
  113. ```
  114. ---
  115. ### Gemini CLI
  116. Gemini CLI reads `GEMINI.md` from the project root (or falls back to `AGENTS.md`).
  117. **Create `GEMINI.md`** (copy from `AGENTS.md`):
  118. ```bash
  119. cp AGENTS.md GEMINI.md
  120. ```
  121. **Then run:**
  122. ```bash
  123. gemini "Read GEMINI.md and run full cycle: discover, ingest, lint"
  124. gemini "Read GEMINI.md and query the wiki: what do we know about [topic]?"
  125. ```
  126. ---
  127. ### Codex CLI (OpenAI)
  128. Codex reads `AGENTS.md` from the project root.
  129. ```bash
  130. codex "Read AGENTS.md and run full cycle: discover → ingest → lint"
  131. codex "Read AGENTS.md and ingest new files in raw/"
  132. codex "Read AGENTS.md and query: summarize the wiki on [topic]"
  133. ```
  134. ---
  135. ### Aider
  136. Aider works best with explicit file references.
  137. ```bash
  138. aider --message "Read CLAUDE.md to understand the schema. Run ingest on all new files in raw/articles/. Update wiki/ accordingly." CLAUDE.md raw/articles/*.md
  139. ```
  140. ---
  141. ### Continue.dev
  142. Add `CLAUDE.md` to Continue's context, then chat:
  143. ```
  144. @CLAUDE.md Ingest the new articles in raw/ and update the wiki with entities, concepts, and cross-references.
  145. ```
  146. ---
  147. ### Tool Comparison
  148. | Tool | Config File | Skill/Slash Command | Auto-loop | Best For |
  149. |------|------------|-------------------|-----------|----------|
  150. | Claude Code | `CLAUDE.md` | ✅ `/llm-wiki` | ✅ `/loop` | Full experience, all features |
  151. | Cursor | `AGENTS.md` | ❌ chat only | ❌ | IDE-integrated workflow |
  152. | GitHub Copilot | `.github/copilot-instructions.md` | ❌ chat only | ❌ | VS Code users |
  153. | Windsurf | `AGENTS.md` | ❌ chat only | ❌ | VS Code alternative |
  154. | Gemini CLI | `GEMINI.md` | ❌ chat only | via cron | Google ecosystem |
  155. | Codex CLI | `AGENTS.md` | ❌ chat only | via cron | OpenAI preference |
  156. | Aider | `CLAUDE.md` | ❌ explicit | via cron | Terminal-only |
  157. > All tools use the same `raw/`, `wiki/`, `outputs/` folder structure. The AI config file tells each tool how to operate — same content, different filenames.
  158. ---
  159. ## Auto-Run Without Claude Code
  160. For tools without `/loop`, use your system scheduler.
  161. **Windows — Task Scheduler** (run once as Admin):
  162. ```powershell
  163. powershell -ExecutionPolicy Bypass -File "scripts/setup-scheduler.ps1"
  164. ```
  165. **macOS / Linux — crontab:**
  166. ```bash
  167. # Claude Code (headless)
  168. 0 */2 * * * cd /path/to/my-wiki && claude --print "/llm-wiki run" >> outputs/auto-run.log 2>&1
  169. # Codex
  170. 0 */2 * * * cd /path/to/my-wiki && codex "Read AGENTS.md and run full cycle" >> outputs/auto-run.log 2>&1
  171. # Gemini CLI
  172. 0 */2 * * * cd /path/to/my-wiki && gemini "Read GEMINI.md and run full cycle" >> outputs/auto-run.log 2>&1
  173. ```
  174. ---
  175. ## How It Works
  176. ```
  177. ┌─────────────────────────────────────────────────┐
  178. │ YOU (read & ask) │
  179. ├──────────────┬──────────────┬────────────────────┤
  180. │ wiki/ │ outputs/ │ wiki-viewer.html │
  181. │ (Obsidian) │ (reports) │ (browser view) │
  182. ├──────────────┴──────────────┴────────────────────┤
  183. │ LLM (writes & maintains) │
  184. ├──────────┬──────────┬──────────┬─────────────────┤
  185. │ discover │ ingest │ query │ lint │
  186. │ (find) │ (process)│ (answer) │ (health check) │
  187. ├──────────┴──────────┴──────────┴─────────────────┤
  188. │ raw/ │ config.yaml │ CLAUDE.md │
  189. │ (sources) │ (settings) │ (schema/rules) │
  190. └───────────────┴────────────────┴──────────────────┘
  191. ```
  192. **Main flow:** `discover` → `raw/` → `ingest` → `wiki/` → `query` → `outputs/`
  193. **Self-improvement loop:** `lint` finds gaps → `discover` finds sources → `ingest` fills them → wiki grows richer
  194. ### Core Workflows
  195. **`discover`** — Searches the web for new sources based on your topics in `config.yaml`. Can scan Reddit for pain points, track GitHub trending repos, follow RSS feeds, and snowball from references found in existing sources.
  196. **`ingest`** — Reads each new file in `raw/`. Extracts entities, concepts, and key claims. Creates wiki pages. Adds cross-references. Flags contradictions with existing content. One source typically creates 5–15 wiki pages.
  197. **`query`** — Reads `wiki/INDEX.md`, finds relevant pages, synthesizes an answer with citations. Valuable answers are automatically saved as synthesis pages.
  198. **`lint`** — Scans the entire wiki for: contradictions, orphan pages, broken links, stale claims, and knowledge gaps. Updates `.discoveries/gaps.json` so `discover` knows what to find next.
  199. ---
  200. ## Adding Sources
  201. ### Drop a file manually
  202. Create a markdown file in `raw/articles/` with frontmatter, then run `ingest`:
  203. ```markdown
  204. ---
  205. title: "Article Title"
  206. url: "https://example.com/article"
  207. author: "Author Name"
  208. discovered: 2026-04-14
  209. topic: "your topic"
  210. ---
  211. Article content here...
  212. ```
  213. For **book notes** (book-companion variant), add `chapter: N`:
  214. ```markdown
  215. ---
  216. title: "Dune Chapter 5 Notes"
  217. chapter: 5
  218. book: "Dune"
  219. ---
  220. ```
  221. For **competitor data** (competitive-intel variant), add `competitor: "Name"`:
  222. ```markdown
  223. ---
  224. title: "Linear — Pricing Page"
  225. competitor: "Linear"
  226. ---
  227. ```
  228. ### Obsidian Web Clipper
  229. 1. Install [Obsidian Web Clipper](https://obsidian.md/clipper) browser extension
  230. 2. See an interesting article → click clip → save to `raw/articles/`
  231. 3. Run ingest
  232. ### Auto-discovery
  233. Configure `config.yaml` with topics, Reddit subreddits, GitHub orgs, and RSS feeds — the `discover` command handles the rest.
  234. ---
  235. ## Viewing Your Wiki
  236. **Obsidian** (recommended): `File → Open vault → select your wiki folder` → Graph View shows connections
  237. **Browser**: Open `wiki-viewer.html` — mobile-first dark theme dashboard with graph view
  238. **Any markdown editor**: All wiki pages are plain `.md` files
  239. ---
  240. ## Folder Structure
  241. ```
  242. my-wiki/
  243. ├── CLAUDE.md ← Schema + rules for Claude Code
  244. ├── AGENTS.md ← Schema + rules for Cursor, Codex, Windsurf, Aider
  245. ├── GEMINI.md ← Schema + rules for Gemini CLI (copy of AGENTS.md)
  246. ├── .github/
  247. │ └── copilot-instructions.md ← Schema for GitHub Copilot
  248. ├── config.yaml ← Your topics, feeds, schedule
  249. ├── config.example.yaml ← Template to start from
  250. ├── wiki-viewer.html ← Browser-based wiki viewer
  251. │
  252. ├── variants/ ← Ready-made use case templates
  253. │ ├── book-companion/ ← 📚 Reading companion
  254. │ ├── competitive-intel/ ← 🎯 Competitor tracking
  255. │ └── job-search/ ← 💼 Job search research
  256. │
  257. ├── raw/ ← YOUR SOURCES (LLM never modifies these)
  258. │ ├── articles/ ← Web articles, blog posts, papers
  259. │ ├── reddit/ ← Reddit threads, pain points
  260. │ ├── notes/ ← Personal notes
  261. │ └── media/ ← Screenshots, diagrams
  262. │
  263. ├── wiki/ ← LLM-maintained wiki (don't edit manually)
  264. │ ├── INDEX.md ← Master catalog of all wiki pages
  265. │ ← LOG.md ← Activity log
  266. │ ├── entities/ ← People, orgs, tools, projects
  267. │ ├── concepts/ ← Ideas, patterns, methodologies
  268. │ ├── sources/ ← Summary of each raw source
  269. │ └── syntheses/ ← Analysis, comparisons, rankings
  270. │
  271. ├── outputs/ ← Query results, reports, battlecards, briefs
  272. ├── .discoveries/ ← Auto-discovery metadata
  273. │ ├── feeds.json ← Sources being tracked
  274. │ ├── gaps.json ← Knowledge gaps to fill
  275. │ └── history.json ← Processed sources (dedup)
  276. │
  277. └── skills/llm-wiki/SKILL.md ← Claude Code skill definition
  278. ```
  279. ---
  280. ## Configuration
  281. All behavior is controlled by `config.yaml`. Copy `config.example.yaml` to get started.
  282. Key sections:
  283. ```yaml
  284. wiki:
  285. name: "My Wiki"
  286. language: "en" # Any language — wiki content will be in this language
  287. topics:
  288. - name: "Topic Name"
  289. keywords: ["keyword1", "keyword2"]
  290. priority: high
  291. feeds:
  292. reddit:
  293. enabled: true
  294. subreddits_pain_points:
  295. - sub: "r/SaaS"
  296. hackernews:
  297. enabled: true
  298. min_score: 50
  299. github_trending:
  300. enabled: true
  301. languages: ["python", "typescript"]
  302. schedule:
  303. run:
  304. loop_interval: "1h" # For /loop in Claude Code
  305. ```
  306. → See `config.example.yaml` for the full reference with all options.
  307. ---
  308. ## Commands Reference
  309. | Command | Description |
  310. |---------|-------------|
  311. | `setup <variant>` | Initialize wiki from a variant template (book-companion, competitive-intel, job-search) |
  312. | `init "Topic"` | Add a new topic to an existing wiki |
  313. | `ingest` | Process all new files in `raw/` |
  314. | `query "..."` | Answer a question using the wiki; saves valuable answers |
  315. | `discover` | Auto-find new sources from the web based on topics |
  316. | `run` | Full cycle: discover → ingest → lint |
  317. | `lint` | Health check: contradictions, orphans, gaps, stale content |
  318. | `status` | Show wiki stats and health overview |
  319. | `digest` | Daily brief: new sources, top insights, detected changes |
  320. | `pain-rank` | Rank pain points by business opportunity (Reddit data) |
  321. | `book-summary` | Structured book summary: cast, timeline, themes, mysteries |
  322. | `competitive-brief "Name"` | Battlecard 1-pager for a specific competitor |
  323. | `interview-prep "Company"` | Interview prep 1-pager for a target company |
  324. For tools without slash commands, use the equivalent natural language prompt:
  325. ```
  326. Read CLAUDE.md (or AGENTS.md). Then [describe what you want].
  327. ```
  328. ---
  329. ## FAQ
  330. **What AI model do I need?**
  331. Any capable model with tool use (web search, file read/write). Claude Sonnet/Opus recommended. Works with GPT-4o, Gemini 1.5 Pro, and others via their respective CLI tools.
  332. **How much does it cost to run?**
  333. A typical `/llm-wiki run` cycle (discover + ingest 5 sources + lint) costs $0.10–0.40 depending on wiki size and source length. Running every 2 hours = ~$50/month.
  334. **My wiki is getting large. How do I query it efficiently?**
  335. The skill reads `wiki/INDEX.md` first to find relevant pages, then reads only those. Even large wikis (500+ pages) query efficiently because you never load everything at once.
  336. **Can I use this for a team?**
  337. Yes — put the wiki folder in a shared Git repo. Each team member runs ingest on their own sources; the wiki is a shared output. Conflicts are resolved by `lint`.
  338. **Does it hallucinate?**
  339. The query and ingest commands only use information from your `raw/` sources. They cannot add claims not supported by your sources. If something is uncertain, the wiki page will say so.
  340. **Can I write in a language other than English?**
  341. Yes. Set `wiki.language` in `config.yaml`. The LLM will write all wiki content in that language while keeping file names and frontmatter in English.
  342. ---
  343. ## Credits
  344. - Original pattern: [Andrej Karpathy — LLM Wiki](https://gist.github.com/karpathy/442a6bf555914893e9891c11519de94f)
  345. - Inspiration: [Nick Spisak — How to Build Your Second Brain](https://x.com/NickSpisak_/status/2040448463540830705)
  346. - Built for: [Claude Code](https://claude.ai/code) (Anthropic) + compatible with all major AI coding assistants
  347. - Wiki viewer: [Obsidian](https://obsidian.md/)
  348. ## License
  349. MIT — use it, fork it, build variants, share back.

Ratings and comments

Sign in to rate this skill.

Sign in

Free to use. If it’s helped, pass it on.