khive: Local knowledge-graph runtime for long-horizon AI agents
khive, from Ohdearquant, is a research knowledge graph runtime that supplies persistent, typed memory for AI agents. It runs as a Model Context Protocol server and extracts entities and relations into a queryable graph, so agents can maintain project-level context and surface contradictions. Key capabilities include a nine-kind typed entity system, hybrid retrieval combining FTS5 and vector similarity, an MCP verb surface, and provenance tracking. It targets developers and researchers building long-horizon agent workflows.
What tasks can you actually use it for?
khive functions as a knowledge-graph runtime that gives agents a persistent, typed substrate to read and update. The system supports nine distinct entity kinds, including concepts, documents, datasets, projects, and resources, and it automatically extracts entities and relations so agents can track lineage and project state across sessions. Typical uses are long-horizon research coordination, contradiction detection across notes, and structured task management driven by agent logic.
How accurate is retrieval and structured output?
Retrieval combines FTS5 keyword search with vector similarity and merges results using Reciprocal Rank Fusion, a design meant to increase recovery accuracy for mixed queries. The memory pack ranks notes by semantic salience and implements decay to downweight stale items. Provenance is recorded with a Git pack for source-code ingestion, so structured outputs retain lineage metadata that agents can query when validating or tracing information sources.
What inputs and queries does it accept, and how does traversal work?
khive ingests documents and code via modular packs and exposes graph traversal primitives for agents. The system supports BFS, shortest-path, and GQL/SPARQL-style queries across typed edges. By default khive loads a set of functional packs, such as KG, GTD, Memory, Brain, and Git, which developers can extend. The typed edges and query surface let agents follow dependencies and assemble multi-step reasoning paths.
How does it handle latency and local data handling?
khive is built for local-first execution on a high-performance SQLite backend and runs a background daemon called khived that auto-spawns on first request to keep embedding models and database connections warm. That design reduces cold-start delays for repeated agent interactions and keeps graph and vector storage on the host system. The single-binary orientation eliminates the need for external graph databases as part of the local runtime.
khive is a focused infrastructure choice for agent developers
Install via Cargo with 'cargo install kkernel' or via npm with 'npm install -g khive' to run the kkernel binary locally and pair it with an MCP client such as Claude Desktop or IDE extensions. khive suits developers and researchers who need typed, persistent agent memory; expect integration work to connect it to your agent stack and to learn the MCP verb surface for effective automation.




