Build Your Own Personal AI Knowledge Base
A personal knowledge base is files with content, organized into folders, tagged, or linked using [[wikilinks]]. A good knowledge base should be in the format that both you and an AI can read. Depending on your needs, you can choose to set it up locally using markdown format (as it is easier to read than PDFs) or in the cloud using a database like Notion or inside InfraNodus graphs.
Organizations usually land on Notion or a custom repository, because they need database queries and collaborative editing. Individuals rarely need either, and end up with Obsidian or plain notes in folders. Interestingly, local setup is more versatile if you want to use the AI, because you can choose the models, the harness, and customize the agents that are going to query your data. The setup below is the second kind; most of it applies to the first.
What follows is the setup we recommend for an AI personal knowledge base, in the order it makes sense to build it: the files, the folder structure, version control, a viewer, and the connection to an LLM. Then the part most guides skip — why a folder tree is not enough structure for a model to reason over, and what to add so it is. This is the storage layer of an AI knowledge base; the other two are covered separately.
Set It Up
Create an Account
Sign up for a free InfraNodus account to get access to the knowledge graph tools and your API key.
Create a Free AccountGet InfraNodus MCP
https://mcp.infranodus.com
Add this URL as a connector via Settings > Connectors in Claude Web / Desktop and authenticate with your InfraNodus API key via OAuth.
https://mcp.infranodus.com
Open the ChatGPT Apps page > Advanced Settings > enable Developer Mode > Create App, paste this URL (leave the OAuth fields empty), click Connect, and authenticate with your InfraNodus API key. Full guide: ChatGPT setup.
claude mcp add infranodus -s user --transport http https://mcp.infranodus.com/mcp
Then open Claude Code in terminal, run /mcp and pick
"Authenticate" — it opens the browser OAuth flow where you will need to
put in your InfraNodus API key to connect to
the MCP server.
{
"mcpServers": {
"infranodus": {
"url": "https://mcp.infranodus.com"
}
}
}
Add this to ~/.cursor/mcp.json (all projects) or
.cursor/mcp.json (one project) — or use
Cursor Settings > MCP > New MCP Server. Then
click "Login" next to the server to authenticate with your
InfraNodus API key.
codex mcp add infranodus --url https://mcp.infranodus.com
codex mcp login infranodus
Run these commands in your terminal — the login command opens the
browser OAuth flow where you enter your
InfraNodus API key. (You can also add the
server to ~/.codex/config.toml manually.)
{
"mcpServers": {
"infranodus": {
"command": "npx",
"args": ["-y", "infranodus-mcp-server"],
"env": {
"INFRANODUS_API_KEY": "your-api-key"
}
}
}
}
Add this to your LLM client's MCP configuration file (it runs the
infranodus-mcp-server npm package via npx), replacing
your-api-key with your
InfraNodus API key. See our
deployment guides for client-specific
instructions (n8n, Make.com, local setup, and more).
Install the Skill
/plugin marketplace add infranodus/skills
/plugin install infranodus@infranodus-skills
Run these two commands in the Claude Code prompt to install
the skill as a plugin (use
infranodus-all@infranodus-skills to install all
our skills at once). Or use npx in your terminal:
npx skills add infranodus/skills --skill infranodus -g -a claude-code -y
Download the skill as a .zip file from our GitHub
repository:
Then open Claude Desktop (or Claude Web), go to
Customize > Skills (in older versions:
Settings > Capabilities > Skills), make
sure "Code execution and file creation" is enabled, click
Upload Skill (or the + button)
and select the infranodus.zip file you just
downloaded. The skill will be available in all your new
conversations.
Option 1: ask Codex to install the skill for you with its built-in skill installer. Type this in the Codex prompt:
$skill-installer install the infranodus skill from https://github.com/infranodus/skills
Option 2: use npx in your terminal (it will fetch the skill from our GitHub repository and add it to Codex):
npx skills add infranodus/skills --skill infranodus -g -a codex -y
Both options install the skill into the
~/.codex/skills folder. Start a new Codex session
to pick it up, then type $ in the prompt to see the
skill in the list and invoke it.
npx skills add infranodus/skills --skill infranodus -g
When prompted, select the agents where you want to add the skill — e.g. claude-code, codex, or cursor.
npx comes bundled with Node.js. For ChatGPT and OpenClaw, see the full installation instructions.
Didn't work? You can simply download infranodus.zip from our GitHub repository and add it to your LLM client manually — see the step-by-step instructions.
Add Graph View to Your Knowledge Base
VSCode / Cursor Graph View Plugin Obsidian Graph View
What Files and Formats to Use for a Knowledge Base?
Keep PDFs as your raw material when the source matters — papers, reports, scans. But convert anything you want the model to work with often into Markdown. It preserves headings, lists, and links while staying plain text, which makes it far faster for an LLM to read and far easier for you to diff, search, and version.
Markdown is also the format the linking convention runs on. [[wikilinks]] between files let you state a relation directly — this note is about that concept — which adds a network layer of coherence on top of the folder hierarchy. That distinction matters later.
For example, you can have a folder with raw sources (e.g. PDFs in the /raw or /research folder with subfolders identifying different research areas or projects). You can then convert the PDFs into markdown files (using AI-generated PDF to markdown conversion script) and use one of the Claude skills from InfraNodus to create knowledge graph for a specific folder or an LLM wiki layer on top, so it is easier for the model to query this data later.
What's the Best Folder Structure for a Knowledge Base?
The main risk here is over-design. A structure with too many levels adds cognitive load at exactly the wrong moment — when you have something to file and have to decide where it belongs. Every second spent on that decision is a reason not to save the thing at all.
Two conventions keep it workable. Add a general Incoming folder, plus an incoming folder inside each category, so anything can be saved in one move. Then sort the incoming folders on a regular schedule and keep them close to empty. The structure emerges from what you actually collect rather than from a taxonomy you guessed at the start.
Keep one vault with everything in it. A single base is where cross-domain connections become visible, and those are the ones worth having. Split into sub-bases only when the domains you work with are genuinely unrelated and the noise starts to outweigh the connections.
Track Changes in a Knowledge Base with Version Control
Running the folder under Git is optional but cheap, and it changes what you can do with the base. You keep local control of how it evolved, you can revert to any previous state, and you can fork it — which is genuinely useful when you want to restructure aggressively or let an AI rewrite a section without risking the original. A private GitHub repository doubles as backup.
It also gives you a record of how your thinking changed, which is a different thing from a record of what you currently think.
To set it up, install Git on your local machine and then use it from Terminal or your IDE of choice (Cursor, VSCode), or Obsidian (via the Terminal plugin).
Navigate and Edit a Knowledge Base with a Viewer
You need something to navigate and edit the files with. Four that work, depending on where you want the data to live.
Obsidian — local, reads markdown, and renders [[wikilinks]] as a navigable graph. The most common choice for a personal knowledge base, and the one most graph tooling targets; an Obsidian vault and a personal knowledge base are the same folder.
Cursor or VSCode — an IDE rather than a note app, but it reads markdown and PDFs, handles code and data files properly, and is highly extensible. If your base contains repositories or datasets alongside notes, this is the better fit: Obsidian shows only markdown, formats code poorly, and its AI capabilities are limited. You can add the InfraNodus graph view, run Claude Code in the terminal beside it, and have Cursor's own agent working in parallel.
Notion — cloud, collaborative, with database queries. The usual choice for organizations. You give up local control in exchange for shared editing.
InfraNodus — cloud, with the graph analysis and AI built in, if you would rather not assemble the parts yourself.
Connecting an LLM
If the base is in InfraNodus or Notion, use the built-in AI to query specific documents. If it is a local folder, use Claude Code or OpenAI's Codex — via the terminal or the desktop app.
Both vendors also offer a general co-work chat mode you can point at a folder. Use the code tools instead. They handle multi-file work properly and, more importantly, they support tool use — which is what lets the model call out to graph analysis, search, or anything else you connect later. Starting there costs nothing and avoids a migration.
Source files and notes in a folder structure, a viewer to navigate them, and an LLM pointed at the folder. Git for backup and observability if you want it. Everything after this is about giving the model more structure to reason over.
Tools: Obsidian or Cursor for a local base, Notion or InfraNodus for a cloud one; optionally Git with a private GitHub repository for backup; Claude Code or InfraNodus for querying.
First step: put your source material and notes into one folder and organize them roughly. Do not get precise about the structure yet.
Observability: Add a Knowledge Graph to Your Knowledge Base
At this point the knowldege base works. You can find things, and the model can answer questions about them. The limit shows up when you ask for something that isn't already written down somewhere.
A folder tree is a hierarchy: each file has one place, and its relation to everything outside its branch is unrecorded. An AI reading it retrieves the chunks most similar to your query and answers from those (this is referred to as RAG or Retrieval-Augmented Generation). That is fine for lookup and poor for anything requiring several hops across the material — which is where most non-obvious connections live.
[[wikilinks]] are the first correction: they let you curate by hand how notes and ideas relate, one link at a time, adding a rhizomatic layer of coherence that cuts across the branches of the tree. A knowledge graph is the second: the concepts and relations across the whole base are extracted into a network, and network science reads its shape — which concepts hold the material together, which topics have formed, and which pairs of topics are not connected to each other. That last measure is the one you cannot get any other way, because it describes something that isn't in any single file.
There are two established ways to add this layer — an LLM wiki, where the model writes interlinked pages summarizing your sources, and a knowledge graph, where the relations are extracted into a traversable network. They combine. The comparison is in RAG vs. LLM wiki vs. knowledge graph, and the assembled workflow in the AI second brain.
Keeping It Yours
Everything above is plain files in open formats. Markdown, PDFs, a Git repository, wikilinks — nothing that requires a specific vendor to remain readable, and nothing that has to be exported to be moved. The tools that add the semantic layer are open source, and the ontology files they generate are markdown too.
This is worth being deliberate about. A personal knowledge base is a long-lived object — the value compounds over years — and the failure mode is not losing the files but losing the ability to read them outside the app you built them in. Personal knowledge management tools come and go; markdown in a Git repository does not.
Tools
- InfraNodus skill — run
/infranodusin a vault to build knowledge graphs for its folders and write the manifest your AI reads. - LLM Wiki skill — scaffolds a wiki layer over a set of sources, with ontology generation and gap detection.
- MCP server — network analysis of your knowledge base, available to Claude as a tool.
- Obsidian graph view plugin — topics, gaps, and central concepts inside an existing vault.
- VSCode / Cursor extension — the same, for any file or folder in an IDE.
- API and GraphRAG endpoints — for building the analysis into your own pipeline.
FAQ
How do I create a knowledge base for AI?
Put your sources and notes in a folder structure, convert what you can to markdown, and point an AI agent like Claude Code at the folder. That is a working knowledge base. To get past summarization, add a semantic layer — an LLM wiki or a knowledge graph — that describes the concepts and their relations, and make it available to the model as a tool.
Do I need to know how to code?
No. The setup is folders, markdown files, and a viewer. The only command-line step is optional — running Claude Code in a terminal rather than a desktop app, which is worth doing because it supports tool use.
Is there an open source AI knowledge base?
The knowledge base itself is open by construction: markdown files, PDFs, and a Git repository you own. The InfraNodus skills that build the semantic layer are open source, and the ontology files they write are plain markdown you can read and edit.
One knowledge base or several?
One, unless the domains are genuinely unrelated. A single base is where cross-domain connections become visible, and those are usually the valuable ones. Split only when the noise between areas starts to outweigh the connections between them.
Markdown or PDF?
Both. Keep PDFs when the original source matters, and convert to markdown anything the model will read often — it preserves formatting, stays plain text, and is much faster to process.
What does InfraNodus add to a knowledge base?
The structural layer. It represents the base as a knowledge graph and applies network analysis to show which concepts are most influential, which topics have formed, and which pairs of topics are not connected to each other — the content gaps. The model then uses that structure to answer, instead of retrieving the nearest paragraph.
Build Your Knowledge Base
Connect your files to a knowledge graph that shows you the topics inside them, the concepts that hold them together, and the gaps between them:
Sign Up Log In