Eliminate context window amnesia. OGM-Slim combines Tree-Sitter AST call-graph indexing with bi-temporal episodic memory ranking to empower Claude Desktop, Cursor, and autonomous AI agents with instant, high-precision recall.
npm install -g ogm-slim
Everything your AI agent needs to understand massive multi-package codebases and maintain continuous operational learnings.
Instantly maps symbols, functions, methods, structs, and interfaces across multiple files and packages. Automatically detects downstream callers, dependencies, and type contracts.
Separates raw observation logs (Episodes) from verified architectural conclusions (Memories). AI agents anchor bug fixes, runbooks, and design decisions directly to symbol keys.
Zero friction connection with Claude Desktop, Cursor, Roo-Code, and Antigravity. Equipped with 12 atomic tools for real-time querying, observing, committing, and indexing.
Zero cloud subscriptions or external databases required. All data resides in a single, high-performance embedded SQLite database using Write-Ahead Logging for lightning-fast reads.
Code is a deterministic graph of call hierarchies and exact contracts, not just loose text similarity.
| Capability | Naive Prompting / Context Window | Vector Embeddings (Vector RAG) | OGM-Slim Engine |
|---|---|---|---|
| Cross-File Call Graph | ❌ Impossible (Token limits) | ⚠️ Inaccurate text chunks | ✅ Deterministic AST Call Hierarchy |
| Memory Retention | ❌ Lost upon session close | ⚠️ Loose similarity recall | ✅ Bi-temporal Provenance + BM25 |
| Bug Regression Prevention | ❌ AI repeats same mistakes | ❌ No structured conclusion | ✅ Anchored Memories to Symbol Keys |
| Storage & Setup | None | ❌ Heavy external cloud/vector DB | ✅ 100% Local SQLite WAL (<5ms) |
| Integration Protocol | Manual Copy-Paste | ⚠️ Custom API wrappers | ✅ Standard MCP 1.5 Protocol (12 Tools) |
Claude and Cursor automatically invoke these tools to navigate codebases and record operational memories.
codebase_index
Index local directory with AST parser
codebase_search
Search symbols by name, file, or kind
codebase_get_callees
Inspect downstream caller/callee relations
codebase_symbol_info
Get signature, contract, & docstrings
memory_observe
Record immutable raw observation episode
memory_commit
Commit structured durable solution memory
memory_recall
FTS5 hybrid search across agent memory
memory_inspect
Get full provenance trace & citations
memory_invalidate
Archive or supersede outdated memory
dataset_list
List isolated codebase workspaces
dataset_stats
Get symbol, relation, and cluster counts
dataset_delete
Cascade purge codebase dataset
Choose your preferred setup: Claude Desktop, Cursor, CLI, or TypeScript Library.
{
"mcpServers": {
"ogm-slim": {
"command": "npx",
"args": ["-y", "ogm-slim", "mcp"]
}
}
}
Name: ogm-slim
Type: command
Command: npx -y ogm-slim mcp
# 1. Index your current project codebase
ogm-slim index . --project my-app
# 2. Launch the visualizer dashboard & REST API
ogm-slim serve --port 8765
# 3. Open browser at http://localhost:8765/admin
import { indexCodebaseDirectory, recallMemories, commitMemory } from 'ogm-slim';
// Index codebase into knowledge graph
await indexCodebaseDirectory('./src', 'my-project');
// Recall relevant memories with hybrid ranking
const results = await recallMemories('WASM lifecycle', 'my-project');
console.log(results);