$git clone https://github.com/rvk7895/llm-knowledge-basesClaude Code plugin for building LLM-maintained Obsidian wikis from raw research — compile, query, lint, and evolve your personal knowledge base. Inspired by Karpathy's knowledge base workflow.
| 1 | # LLM Knowledge Bases |
| 2 | |
| 3 | A Claude Code plugin that turns raw research material into an LLM-maintained Obsidian wiki -- inspired by [Andrej Karpathy's description](https://x.com/karpathy/status/2039805659525644595) of using LLMs as knowledge compilers rather than just code manipulators. |
| 4 | |
| 5 | You drop source material into `raw/`, run a single command, and Claude handles the rest: compiling interlinked wiki articles, maintaining indexes and backlinks, answering complex questions at multiple depth levels, and continuously improving the knowledge base over time. |
| 6 | |
| 7 | The LLM owns the wiki. You rarely edit it manually -- just explore in Obsidian and keep feeding it raw data. |
| 8 | |
| 9 | ## How It Works |
| 10 | |
| 11 | 1. **Ingest** -- Raw documents (articles, papers, repos, YouTube transcripts, images, datasets) go into `raw/` |
| 12 | 2. **Compile** -- Claude builds a structured Obsidian vault with summaries, backlinks, concept articles, and auto-generated indexes |
| 13 | 3. **Query** -- Three depth levels: |
| 14 | - **Quick** -- Answers from wiki indexes and summaries alone |
| 15 | - **Standard** -- Cross-references the full wiki, supplements with web search |
| 16 | - **Deep** -- Multi-agent research pipeline with parallel web search agents |
| 17 | 4. **Output** -- Markdown reports, Marp slides, matplotlib charts -- saved to `output/` and optionally filed back into the wiki |
| 18 | 5. **Maintain** -- Automated health checks (broken links, orphans, inconsistencies) and suggestions for new articles and connections |
| 19 | |
| 20 | ## Prerequisites |
| 21 | |
| 22 | - [Claude Code](https://docs.anthropic.com/en/docs/claude-code) (CLI), installed and authenticated |
| 23 | - [Obsidian](https://obsidian.md) |
| 24 | |
| 25 | Obsidian plugins (Dataview, Obsidian Git, etc.) are installed automatically by the setup script during `/kb-init`. |
| 26 | |
| 27 | ## Installation |
| 28 | |
| 29 | In Claude Code, run: |
| 30 | |
| 31 | ``` |
| 32 | /plugin marketplace add rvk7895/llm-knowledge-bases |
| 33 | /plugin install kb@llm-knowledge-bases |
| 34 | ``` |
| 35 | |
| 36 | All skills are installed as a single plugin. |
| 37 | |
| 38 | ## Quick Start |
| 39 | |
| 40 | ```bash |
| 41 | # Initialize a new knowledge base |
| 42 | /kb-init |
| 43 | |
| 44 | # Add sources to raw/, then compile the wiki |
| 45 | /kb compile |
| 46 | |
| 47 | # Query the knowledge base |
| 48 | /kb query |
| 49 | |
| 50 | # Run a health check |
| 51 | /kb lint |
| 52 | |
| 53 | # Deep multi-agent research on a topic |
| 54 | /research <topic> |
| 55 | /research-deep |
| 56 | ``` |
| 57 | |
| 58 | ## Available Skills |
| 59 | |
| 60 | | Skill | Purpose | |
| 61 | |-------|---------| |
| 62 | | `kb-init` | One-time setup: scaffolds directories, generates config, writes project files | |
| 63 | | `kb` | Main skill with four workflows: compile, query, lint, evolve | |
| 64 | | `research` | Generate a structured research outline for a topic | |
| 65 | | `research-deep` | Launch parallel agents for deep research on each outline item | |
| 66 | | `research-add-fields` | Add field definitions to an existing research outline | |
| 67 | | `research-add-items` | Add research targets to an existing outline | |
| 68 | | `research-report` | Compile deep research results into a markdown report | |
| 69 | |
| 70 | ## Directory Structure (after `/kb-init`) |
| 71 | |
| 72 | ``` |
| 73 | raw/ -- Raw source documents |
| 74 | wiki/ -- LLM-compiled Obsidian vault |
| 75 | output/ -- Query results, slides, charts, reports |
| 76 | kb.yaml -- Configuration |
| 77 | CLAUDE.md -- Project instructions for Claude |
| 78 | ``` |
| 79 | |
| 80 | ## X/Twitter Integration (Optional) |
| 81 | |
| 82 | To ingest tweets, threads, and bookmarks from X, install [Smaug](https://github.com/alexknowshtml/smaug): |
| 83 | |
| 84 | ```bash |
| 85 | npm install -g @steipete/bird |
| 86 | git clone https://github.com/alexknowshtml/smaug && cd smaug && npm install |
| 87 | npx smaug setup # configures X session cookies |
| 88 | ``` |
| 89 | |
| 90 | Once configured, paste any `x.com` link and the kb skill will fetch and compile it automatically. Without Smaug, you can still add X content by pasting tweet text directly or using [Thread Reader App](https://threadreaderapp.com) for threads. |
| 91 | |
| 92 | **Note:** Smaug uses X session cookies for read-only access to your own data. This is not officially supported by X's TOS. Practical risk for personal use is very low, but be aware. |
| 93 | |
| 94 | ## Attribution |
| 95 | |
| 96 | - [Andrej Karpathy](https://x.com/karpathy/status/2039805659525644595) -- Original vision for LLM-maintained knowledge bases |
| 97 | - [Weizhena](https://github.com/Weizhena/Deep-Research-skills) -- Deep Research skills adapted for the research pipeline |