Knowledge Vault
A local research knowledge base for Codex and Claude Code. Ingest papers, URLs, notes, and Zotero collections; compile linked summaries and concepts; ask grounded questions; browse the result in Obsidian.

What it does
- Stores each vault inside the current project under
.vault/.
- Preserves source artifacts and creates compact Markdown extracts.
- Compiles sources into an Obsidian-compatible wiki with
[[wikilinks]].
- Answers questions from the vault before falling back to source documents.
- Optionally searches academic MCP sources and imports Zotero collections.
- Optionally builds PageIndex trees for targeted PDF retrieval.
The core workflows require Python 3.10 or newer and run on Linux, macOS, and Windows. External research sources, Poppler PDF extraction, and PageIndex tree indexing are optional.
Install
Codex
codex plugin marketplace add psypeal/knowledge-vault
codex plugin add knowledge-vault@knowledge-vault
In Codex, invoke @knowledge-vault or ask naturally:
Initialize a knowledge vault in this project.
Add this PDF to my knowledge vault.
Compile the pending vault sources.
Answer this question from my knowledge vault: ...
Claude Code
/plugin marketplace add psypeal/knowledge-vault
/plugin install knowledge-vault@knowledge-vault
/reload-plugins
Claude Code supports the same natural-language requests plus /knowledge-vault:* commands.
Quick start
-
Initialize the vault:
Initialize a knowledge vault in this project.
-
Add material:
Add https://example.com/article to my knowledge vault.
Add ./papers/example.pdf to my knowledge vault.
Add these meeting notes to my knowledge vault: ...
-
Compile pending sources:
Compile my knowledge vault.
-
Ask a grounded question:
Ask my knowledge vault: What evidence supports this conclusion?
Knowledge Vault adds concise project guidance to both AGENTS.md and CLAUDE.md, so either host recognizes an initialized vault later.
New vaults also include .vault/.gitignore, so research material stays out of version control by default. Advanced users can run the core initializer with --track to opt in deliberately.
Workflows
| Workflow | Natural-language example | Claude Code command |
|---|
| Initialize | Initialize a knowledge vault | /knowledge-vault:init |
| Ingest | Add this URL/PDF/note to the vault | /knowledge-vault:ingest |
| Import Zotero | Import my neuroimaging Zotero collection | /knowledge-vault:ingest-zotero |
| Collect papers | Find recent papers about ... | /knowledge-vault:collect |
| Compile | Compile pending vault sources | /knowledge-vault:compile |
| Query | Ask the vault: ... | /knowledge-vault:query |
| Enrich references | Find full text for reference-only items | /knowledge-vault:enrich-references |
| Process inbox | Process the vault inbox | /knowledge-vault:process |
| Check health | Lint the knowledge vault | /knowledge-vault:lint |
| Repair wiki | Clean up the compiled vault | /knowledge-vault:cleanup |
| Configure sources | Set up research sources | /knowledge-vault:setup-sources |
| Show status | Show vault status | /knowledge-vault:status |
Vault layout
.vault/
├── .gitignore Privacy-first Git exclusion
├── agent.json Retrieval hints recorded after queries
├── agent.md Readable rendering of agent.json
├── inbox/ Files waiting for the process workflow
├── originals/ Preserved PDFs, HTML, and other source artifacts
├── preferences.md Domain and compilation preferences
├── raw/
│ ├── .manifest.json Source state
│ ├── <slug>.md Compact extracted source
│ └── <slug>.tree.json Optional PageIndex tree
├── sources.json Enabled research-source preferences
├── templates/ Concept, summary, and inbox note templates
└── wiki/
├── concepts/ Cross-source concept articles
├── summaries/ Per-source summaries
├── outputs/ Filed answers and lint reports
├── _backlinks.json
├── .state.json
└── index.md
Open .vault/ directly in Obsidian to browse links and graph relationships. Use plugin workflows to modify generated wiki content so manifests and indexes stay consistent.
Architecture