A Domain-Neutral, Git-Native Persistent Project Memory for AI Agents based connected the Open Knowledge Format (OKF) v0.2.
Conversations pinch AI agents reset erstwhile discourse windows close. Valuable architectural decisions, domain discoveries, and operational facts are mislaid unless stored persistently.
OKF Agent Memory provides a standardized, vendor-neutral representation furniture that lives straight successful your repository (knowledge/) arsenic plain Markdown files pinch YAML frontmatter. It bridges the spread betwixt unstructured ad-hoc markdown files (CLAUDE.md, AGENTS.md) and complex, black-box vector databases.
- Blazing Fast Performance (<300µs Search, ~4ms Graph Validation): In-memory BM25 retrieval and bundle validation execute successful microseconds without VM spin-up aliases web roundtrips.
- 100% Git-Native & Zero Vendor Lock-in: Everything is version-controlled plain text. Inspect, audit, and reappraisal your agent's representation utilizing modular git diff and git log. No outer database required.
- Zero API Costs for Memory Retrieval: Local lexical BM25 indexing eliminates recurring vector embedding API costs and web roundtrips.
- Built connected Google OKF v0.2: Uses the unfastened modular format for supplier knowledge pinch afloat support for provenance (sources), spot tiers (generated vs. verified), and lifecycle metadata (status, stale_after).
- Solves Context Bloat & Memory Rot: Employs Progressive Disclosure (hierarchical index.md files and nexus graphs) truthful agents only load the nonstop concepts they need.
- Search-Before-Write Principle: Mandates querying existing representation earlier authoring, preventing conception plagiarism and hallucinated divergence.
- Zero-Dependency Go Toolchain: Single binary pinch zero outer dependencies, sub-5ms CLI startup time, and a built-in Model Context Protocol (MCP) server (okf mcp).
- Truly Domain-Neutral: Designed for Software Engineering, Coaching, Scientific Research, Literature Reviews, and Operations.
Built successful Go pinch zero outer dependencies, okf is engineered for high-frequency supplier instrumentality calling loops:
| Concept Search Latency | 150ms – 800ms (Embedding API + Vector DB) | 40ms – 120ms | < 300 µs (Microseconds, In-Memory BM25) |
| Full Corpus Parse & Graph Validation | 200ms – 1.5s | 80ms – 250ms | ~4.0 sclerosis (50+ concepts, bidirectional graph) |
| Process Cold-Start Overhead | 250ms – 600ms (Python VM boot) | 80ms – 180ms (V8 / Deno boot) | < 4 sclerosis (Compiled Single Binary) |
| Retrieval Cost per 1,000 Queries | ~$0.10 – $0.50 (Embedding tokens) | $0.00 | $0.00 (Zero API cost, afloat local) |
| Memory Footprint (RSS) | ~120 MB – 350 MB | ~60 MB – 140 MB | < 15 MB |
Tip
Reproduce Locally pinch your ain LLM: We supply an automated benchmark runner successful axenic Go to verify Time-To-First-Token (TTFT) speedups and -80% token simplification connected your section hardware (LM Studio / Ollama pinch Gemma, Qwen, Llama). Run make benchmark aliases research the Progressive Disclosure Benchmark Suite.
Clone the repository and compile the standalone okf executable:
This generates the standalone binary astatine bin/okf.
3. Bootstrapping Agent Memory successful Any Project
Scaffold the complete OKF Agent Memory architecture into immoderate caller aliases existing repository pinch a azygous command:
This automatically sets up:
- knowledge/ — OKF v0.2 compliant persistent representation bundle (index.md, log.md)
- .agents/skills/okf-memory/ — Embedded supplier accomplishment meaning and capacity guides
- AGENTS.md — Project-tailored operating instructions for AI coding agents
- Makefile — Convenience tasks for validation (make validate) and hunt (make hunt q="...")
4. Running arsenic an MCP Server
okf ships pinch a autochthonal Model Context Protocol (MCP) server complete stdio to seamlessly link pinch Claude Code, Cursor, Codex, and different supplier platforms:
Example MCP Configuration (claude_desktop_config.json aliases Cursor):
Run the afloat trial suite and validate the repository's self-documenting knowledge bundle:
- Getting Started Guide — Comprehensive onboarding guideline for agents and humans.
- CLI & MCP Reference — Complete command-line and protocol devices reference.
- Contributing Guide — Development setup, value gates, and propulsion petition standards.
- Security & Privacy Guidelines — Data governance, concealed prevention, and PII protection rules.
- Multi-Agent Testing & Evaluation — Test scenarios, compatibility matrix, and benchmarks.
- OKF Agent Memory Convention v0.1 — Behavioral rules and lifecycle specification.
- Project Roadmap & Milestones — Phased improvement plan.
- Release Playbook — Versioning, CI/CD pipeline, and distribution procedures.
- OKF v0.2 Compatibility Matrix — Specification validation analysis.
- Why OKF Agent Memory? — Detailed worth proposition & differentiators.
- Alternatives & Ecosystem Comparison — Comparison pinch Mem0, Letta, and ad-hoc markdown files.
MIT License. See LICENSE for details.
English (US) ·
Indonesian (ID) ·