OpenKB
Compile raw documents into a persistent, interlinked LLM wiki instead of re-deriving knowledge on every query.
- Source repo
- VectifyAI/OpenKB
- Stars
- ★ 4.6k
- Last updated
- 2mo ago
- License
- Apache-2.0
- Primary language
- Python
- FA score
- 59/100 · Major gaps
At a glance
- Works with
- Universal · cross-platformCodex · Claude Code · OpenAI API · Claude APIChatGPT (Partial support)
- You'll need
- Typical use
- A researcher ingesting a dozen papers one at a time with openkb add, letting the LLM maintain concept and entity pages so questions do not require re-reading source PDFs.
- Main limitation
- Every core step depends on LLM calls, so ingestion, querying, and skill distillation consume model budget with no published cost estimate or offline fallback.
- Source review
- 59/100 · Major gaps
What does this agent do, and when should you use it?
OpenKB is a CLI, open-source system from VectifyAI that compiles raw documents into a structured, interlinked wiki-style knowledge base using LLMs, with retrieval powered by PageIndex's vectorless, reasoning-based tree index for long documents. It splits into a wiki foundation layer (openkb init/add/list/status/watch/lint/remove/recompile) that compiles and maintains knowledge, and a generator layer (query, chat, visualize, skill new, deck new) that turns the wiki into outputs. Short documents go through markitdown into Markdown and are read in full; PDFs of 20 pages or more are turned by PageIndex into a hierarchical tree index that the LLM reasons over, with figures, tables and images handled natively. The result is a plain-.md wiki/ directory that opens directly in Obsidian, plus a bundled FastAPI service and Knowledge Workbench web UI for browsing, uploading, and streaming queries.
openkb init writes .openkb/config.yaml and scaffolds the wiki; openkb add accepts files, directories, or URLs, converting short inputs via markitdown and long PDFs via PageIndex tree indexing, then the LLM generates a summary page, reads existing concept and entity pages, performs cross-document synthesis, creates or updates concepts and entities (people, orgs, places, products), and updates the index and log. openkb query returns a grounded, cited answer and can --save into wiki/explorations/; openkb chat runs multi-turn sessions with --resume/--list/--delete management and slash commands such as /add, /skill, /deck, /lint, /save. openkb skill new distills a redistributable agent skill (with validate, eval, history, rollback) installable by Claude Code, Codex, and Gemini CLI. openkb visualize emits a self-contained 3D/mind-map/radial knowledge graph HTML; openkb deck new produces a single-file HTML slide deck with an optional --critique quality pass. Models are reached through LiteLLM using provider/model strings in config.yaml, with keys in .env as LLM_API_KEY.
- A researcher ingesting a dozen papers one at a time with openkb add, letting the LLM maintain concept and entity pages so questions do not require re-reading source PDFs.
- An analyst tracking a field long-term who leaves openkb watch running on raw/ so newly dropped PDFs compile automatically.
- Someone with an existing Obsidian vault who opens the generated wiki/ directly to browse concept links and the graph view.
- An engineer distributing team knowledge as an installable read-only skill for Claude Code, Codex, or Gemini CLI via openkb skill new.
- Teams with scanned or very large PDFs who set PAGEINDEX_API_KEY to enable PageIndex Cloud OCR and faster structure generation.
- Developers who need to query the knowledge base from their own app, installing openkb[web] and starting openkb-web to use the FastAPI service and its /docs reference.
How do you install or deploy this agent?
Requires Python and pip. Base install: pip install openkb. Alternatives: pip install git+https://github.com/VectifyAI/OpenKB.git for the latest GitHub code, or git clone followed by pip install -e . for an editable development install. The web UI and REST API need an extra: pip install "openkb[web]". Put your model credential in a .env file as LLM_API_KEY=your_llm_api_key; OAuth device-flow subscription providers such as chatgpt/* and github_copilot/* need no API key. To enable PageIndex Cloud (OCR for scanned PDFs, faster structure generation), add PAGEINDEX_API_KEY to the same .env.
How do you use this agent?
Create a working directory (mkdir my-kb && cd my-kb) and run openkb init, choosing a model such as anthropic/claude-sonnet-4-6 or gpt-5.4. Ingest content with openkb add paper.pdf, openkb add ~/papers/, or openkb add https://arxiv.org/pdf/2509.11420. Ask a single question with openkb query "What are the main findings?" or start an interactive session with openkb chat (type / inside chat for slash commands). For outputs, run openkb skill new my-expert "Reason like an expert on <your-topic>", openkb visualize, or openkb deck new my-deck "An intro deck on <your-topic>". For the browser experience: pip install "openkb[web]" then openkb-web, and open http://127.0.0.1:7566/ for the Knowledge Workbench; auth is off by default, so set OPENKB_API_TOKEN before exposing it. Frontend work uses cd frontend && npm install && npm run dev.
What are this agent's strengths and limitations?
- Knowledge lands as plain .md files with [[wikilinks]] under wiki/, so Obsidian opens it as a vault and there is no proprietary storage format to escape.
- Long-document retrieval uses PageIndex tree indexing rather than a vector DB; the LLM reasons over the index, and scanned PDFs can optionally be handled by PageIndex Cloud OCR.
- Model access is abstracted through LiteLLM, with OpenAI, Claude, Gemini, and OAuth subscription providers such as chatgpt/* and github_copilot/* documented, so switching is mostly a config.yaml provider/model edit.
- Generators sit on top of a stable wiki layer: the same compiled knowledge feeds cited answers, multi-turn chat, an interactive graph, distributable agent skills, and HTML slide decks.
- Every core step depends on LLM calls, so ingestion, querying, and skill distillation consume model budget with no published cost estimate or offline fallback.
- Long-PDF accuracy is tied to PageIndex, so query citation quality tracks index quality, and scanned documents need the cloud option for OCR in practice.
- LLM compilation rewrites concept pages, and recompile overwrites manual edits; the README warns about this with --dry-run but there is no built-in versioning or human review gate.
- wiki/AGENTS.md is the LLM's instruction manual for maintaining the wiki, so changing structural conventions requires understanding that file.
- The roadmap still lists non-PDF long documents, nested folders, hierarchical concept indexing, and a database-backed storage engine as unfinished, which limits very large collections today.
How does this agent compare with similar options?
Karpathy's documented workflow: short documents are read by the LLM directly, long documents hit context limits and context rot, input arrives via a web clipper into .md, and entity extraction is manual. OpenKB normalizes short inputs through markitdown, handles long ones with PageIndex tree indexing, accepts PDF, Word, PPT, Excel, HTML, text, CSV, Markdown, and URLs, auto-extracts entities (people, orgs, places, products), and adds Skill Factory plus agent CLI integration on top of the wiki.
Traditional RAG: the README argues traditional RAG rediscovers knowledge from scratch on every query and accumulates nothing, whereas OpenKB compiles knowledge once into a persistent wiki where cross-references already exist and contradictions are flagged.
Key facts side by side with the most closely related agents.
| Agent | Source review | Stars | Updated | Language | Full support on |
|---|---|---|---|---|---|
| OpenKB This agent | 59 · Major gaps | ★ 4.6k | 2mo ago | Python | Codex · Claude Code · OpenAI API · Claude API |
| DeepTutor: Lifelong Personalized Tutoring | 49 · Major gaps | ★ 40k | today | Python | Codex · Claude Code · OpenAI API · Claude API |
| LLM Wiki | 85 · Good | ★ 1.3k | 8d ago | Python | Codex · Claude Code |
| SwarmVault | 67 · Some gaps | ★ 694 | 2mo ago | TypeScript | Codex · Claude Code |
How does FollowAgents rate this agent?
Why each dimension lost points
least_privilege: CI explicitly sets permissions: contents: read and checkout with persist-credentials: false, and wiki tools deny path escapes (../outside.png, ../../etc/passwd) with 'Access denied', showing least-privilege awareness; however no full permission inventory is provided, so capped at 2. user_confirmation: README claims the SKILL.md is read-only and will not run add/remove/lint --fix without asking, but this is a documentation assertion with no code-level confirmation gate shown, so 1. data_flow_transparency: docs state documents and queries go through LiteLLM to the chosen LLM provider, but there is no systematic disclosure of data flows, retention, or third-party handling, so 1. sensitive_data_handling: only guidance to store LLM_API_KEY in .env and optionally set OPENKB_API_TOKEN; no key rotation, log redaction, or sensitive-document policy, so 1. dependency_security: pyproject pins every direct dependency exactly and comments on the litellm supply-chain incident and the openai version cap; CI uses uv sync --locked to lock transitive deps; strong evidence, 3. external_effects: add/remove/recompile mutate the wiki and .openkb state, and watch auto-compiles continuously, but there is no explicit confirmation design for destructive external effects, so 1. rollback: tests cover rollback of converted artifacts on compile failure, long-doc rollback removing only the newly created blob, dedup hits not deleting pre-existing blobs, and directory-level DirtyRollbackError stopping, so rollback is evidenced, 3. source_attribution: query claims cited answers and the wiki has sources pages, but citation format and provenance tracking details are absent, so 2.
self_consistency: README command tables, pyproject entry points (openkb, openkb-web, openkb-api alias) and tested CLI behavior largely agree, but the conftest fixture uses legacy config fields (embedding_model, chunk_size) inconsistent with README's model/language/pageindex_threshold, indicating doc-code drift, so 2. dependency_availability: dependencies are exact versions available on PyPI, but pageindex==0.3.0.dev3 is a dev pre-release whose availability and long-term stability are questionable, so 2. failure_messages: tests assert clear failure strings such as 'No knowledge base found', 'Unsupported file type', 'does not exist', 'SKIP', 'Access denied', but there is no unified strategy for runtime errors like LLM call failures or network timeouts, so 2.
audience_and_scenarios: README targets developers and knowledge workers with CLI, Web UI, Obsidian, and Claude Code/Codex/Gemini integrations, covering a broad set of scenarios, so 2. capability_boundaries: docs explain short vs long PDF (>=20 pages) handling, local vs cloud PageIndex, and Roadmap gaps, giving fairly clear boundaries, but unsupported formats and scale limits are not systematically listed, so 2. trigger_precision: skill eval claims to check triggering on the right prompts, but trigger conditions, false-trigger rates, or thresholds are undefined, so 1. environment_fit: requires Python >=3.10, optional web extra, Node 20 for frontend builds, and documents timeout tuning for local Ollama/LM Studio; environment fit is described but not exhaustive across platforms, so 2.
information_architecture: README is well structured into What/Getting Started/How it Works/Usage/Configuration/Integrations/REST API with commands organized in two layers, 3. install_notes: pip install openkb, GitHub install, editable source install, web extra, and frontend build are all documented, 3. naming_stability: openkb-api retained as a historical alias and api as a compatibility alias for web show naming-stability awareness, but the project is Alpha with hatch-vcs dynamic versioning, limiting stability, so 2. examples_and_faq: README links extensively to real artifacts under examples/ (commands, chat, skills, slides, rest-api), but those files are not in this evidence set and cannot be verified, so 2. known_limitations: only a Roadmap of unfinished items; no dedicated section on known defects, performance limits, or failure modes, so 1. license: full Apache-2.0 text present and consistently declared in pyproject and README, 3. versioning_changelog: publish.yml documents tag-triggered releases, hatch-vcs version derivation, and auto-generated release notes, but there is no in-repo CHANGELOG file, so 2. maintenance_responsibility: pyproject lists author emails and an Issues link, but publisher identity is unverified and there is no governance, security-response, or maintenance-commitment statement, so 1.
output_usability: outputs include Markdown wiki, cited answers, HTML slide decks, installable skills, and a knowledge graph, all directly usable, but no output-quality evaluation or format spec is provided, so 2. marginal_value: versus traditional RAG, the compiled wiki and PageIndex tree indexing offer differentiated value for long documents, but there is no quantified comparison against alternatives, so 2. cost_benefit: each add triggers multiple LLM calls (a single source may touch 10-15 wiki pages) and long documents may incur PageIndex cloud costs, yet README gives no cost estimate or optimization guidance, so 1.
claim_traceability: most capability claims in README lack verifiable evidence (performance data, benchmarks); examples/ are linked but not included in this evidence, so 1. cross_source_corroboration: README, pyproject, CI workflows, and tests partially corroborate each other (dependency pins, rollback tests), but core functional claims lack multi-source cross-validation, so 1. fact_inference_separation: the docs blend design intent with factual statements (e.g. 'Knowledge compounds', 'accurate and scalable retrieval') without separating verified facts from inference, so 1.
- Publisher identity is unverified; maintenance responsibility and security-response paths are unclear, so enterprises should verify independently before adoption.
- The project is Alpha with hatch-vcs dynamic versioning; interfaces and config fields may change (legacy config fields already appear in test fixtures).
- The dependency pageindex==0.3.0.dev3 is a pre-release, posing long-term availability and compatibility risk.
- Each add triggers multiple LLM calls and long documents may use PageIndex cloud, so cost and data-egress scope must be assessed independently.
- The Web UI has auth off by default (local-first); set OPENKB_API_TOKEN before exposing the server.
- Many capability claims and examples/ links in the README are not included in this static evidence and cannot be verified.