How to Build a Personal AI Knowledge Base with Claude Code and Obsidian
A step-by-step guide to setting up an AI agent that organizes your notes, articles, and transcripts into a searchable, interlinked wiki using free tools.
Practical Summary
This tutorial shows how to use Claude Code and Obsidian to automatically ingest raw sources (like articles or video transcripts) and transform them into a structured, cross-linked markdown knowledge base. The workflow eliminates manual organization, making information easily queryable and reusable over time.
Why It Matters
For professionals and teams, this workflow offers a low-cost, reproducible method to centralize and connect knowledge from disparate sources. It can reduce time spent searching for information, improve learning retention, and create a growing asset that enhances decision-making and productivity without requiring specialized AI or database skills.
Step 1: Set Up Obsidian and Claude Code
Download and install Obsidian, a free note-taking application. Create a new vault (a folder) for your knowledge base. Open this folder in Claude Code, which will serve as your AI agent for processing and organizing content.
Step 2: Use Karpathy's LLM Wiki Gist
Search for 'Karpathy LLM wiki gist' to find the template idea file created by Andrej Karpathy. Copy the entire content of this gist.
Step 3: Prompt Claude Code to Initialize the System
Paste the copied gist into Claude Code, then add the following prompt: "You are now my LLM wiki agent. Implement this exact idea as my complete second brain. Create the CLAUDE.md schema, the raw and wiki folders, the index and log, and guide me step by step." Claude Code will automatically build the necessary folder structure: a 'raw' folder for untouched sources, a 'wiki' folder for organized pages, and a CLAUDE.md configuration file.
Step 4: Ingest and Organize Your Sources
To add content, drop any source file (e.g., an article, transcript, PDF) into the 'raw' folder. Then, in Claude Code, use the prompt: "ingest this." Claude Code will read the source, split it into relevant linked pages in the 'wiki' folder, and connect it to existing knowledge automatically.
Step 5: Maintain and Query Your Knowledge Base
The core workflow is to continuously ingest new sources and query across all stored knowledge. You can also run a lint check periodically to identify gaps or inconsistencies. The system is built entirely on markdown files, making it simple to backup, version control, and scale without complex infrastructure.
