The why behind every
line of code
Git-anchored intent ledger with built-in RAG. Your agent starts every session knowing exactly why — with minimal token cost.
Works with Claude Code only. Cursor, Codex, Windsurf, Copilot, Kiro, ... on the way.
Two problems
Everything flows from them
Intent has no ledger
Code has git. Every line, every change, every author — recorded forever. But the reasoning behind the code has nothing. The conversations where decisions were made vanish the moment the session ends.
The code says what. The intent says why. And the why has no permanent record.
Agents can't remember
An AI agent starts every session blank. It reads the code but doesn't know why it looks the way it does. It doesn't know what was tried and rejected last week.
Humans have institutional memory — imperfect, but real. Agents have none.
How it works
Two personas, one flow
You commit and push as normal. Your agent recalls what it needs.
▶Developer touchpoints
git commitPost-commit hook runs rekal checkpoint — snapshots your active AI session into an append-only local database.
git pushPre-push hook runs rekal push — encodes only your data into compact wire format (zstd + string interning) and pushes to your orphan branch.
rekal syncPull your team's session data from remote. Intentionally manual — you decide when to import team context.
▶Agent touchpoints
rekal "query"Three-signal hybrid search (BM25 + LSA + Nomic). Returns scored JSON with the best-matching turn index for progressive drill-down.
rekal queryDrill into a session with --offset and --limit for pagination, or --role human for intent only. Full session when needed.
rekal --fileScoped search filtered by file path. The agent controls how much context it loads — minimal tokens by default.
Beliefs
Opinionated by design
Immutable
Append-only wire format. No byte is ever modified after written. The record is the record.
Intent next to code
Distributed through git orphan branches. No sync server. Works with any remote.
Thin on the wire
A 2–10 MB session becomes ~300 bytes. Indexes and embeddings computed locally.
Secure by design
No external calls. Embedding model ships inside the binary. No API keys. No accounts.
Simple
Single binary, everything embedded. Database engine, embedding model, compression — one file.
Agent first
Three-signal ranking. Structured JSON output. The agent controls the token budget.
Get started
Single binary. Zero dependencies. Takes 10 seconds.
cd your-project
rekal init
# done. commit and push as normal.
The CLI is free and local — forever.
No plans for enterprise yet. If Rekal gets adoption and teams need dashboards, analytics, or cross-repo search — we'll build it. Until then, the CLI is the product.