Alternative · Claude Code

Claude Code, Without the Amnesia.

Same agentic terminal workflow. Plus local-first execution and a memory that compounds — so session 50 costs less context than session 1.

Direct answer

Anvaya is the local-first Claude Code alternative with persistent memory. Where Claude Code locks you to Anthropic models, restarts every session from a hand-maintained CLAUDE.md, and burns ~50K raw tokens re-reading your repo, Anvaya runs Ollama-first with zero API keys (Anthropic, OpenAI, and custom gateways optional), works fully offline, and stores every session's decisions, patterns, and bugfixes in a local knowledge graph — typed nodes with half-lives, git drift detection, and outcome-calibrated utility. Each turn assembles 2–4K packed tokens instead of ~50K raw (12–25x per-node design estimate). Prefer Claude's reasoning? Point Anvaya at Anthropic, or serve Anvaya's memory to Claude Code itself over MCP. Memory is model-agnostic; providers are interchangeable.

Head to Head

Where Each One Wins.

Honest table. Claude Code's reasoning depth is real; so is its per-session tax.

DimensionClaude CodeCursorAnvaya
ModelsAnthropic onlyMulti (curated)Ollama-first + Anthropic, OpenAI, custom
MemoryCLAUDE.md, hand-keptRules + index, retrievesGraph: typed, decaying, calibrated
Session 50 costSame ~50K as day 1Same as day 1~2–4K packed (design est.)
OfflineNoNoYes, fully
PrivacyCloud processingCloud processingLocal by default
Starting price$20/mo$20/mo$0 local loop (pre-1.0)

Switching

Three Steps Over.

Keep your CLAUDE.md. Add memory under it.

01Keep your instruction filesCLAUDE.md and AGENTS.md stay — short rules load every turn. Anvaya reads the same repo; nothing to migrate.
02Attach memoryanv init scaffolds .anvaya/mind/ in under 50ms. Sessions start recording decisions, fixes, and patterns immediately.
03Optionally bridgeServe the graph to Claude Code over MCP (mind-mcp, 8 tools) and get memory inside the harness you already use.

Questions

Asked Before Switching.

Q

What is the best local alternative to Claude Code?

If your priority is privacy plus compounding memory, Anvaya: Ollama-first with zero keys, fully offline, and a memory graph so sessions improve instead of restarting from zero. If you want Claude models with a different harness, OpenCode (75+ providers) and Aider (git-native) are strong open-source picks — neither ships a calibrated memory engine.

Q

Can I use my Claude subscription with Anvaya?

Anvaya talks to Anthropic as one of four providers (Ollama, Anthropic, OpenAI, custom gateways). Configure an API key and the same memory graph serves Claude-powered turns — memory is model-agnostic, so switching providers never invalidates it.

Q

Does Anvaya work with my existing CLAUDE.md?

Yes. Keep short, non-inferable rules in CLAUDE.md — it loads every turn and survives compaction. Anvaya handles everything CLAUDE.md can't: accumulated decisions, bug history, and patterns, weighted by whether they actually helped, decayed by type, and drift-checked against git.

Q

Is Anvaya cheaper than Claude Code?

Claude Code starts at $20/mo with usage windows; heavy use pushes toward $100–200/mo tiers. Anvaya's local loop costs $0 marginal per turn on your hardware, and its 12–25x per-node compression shrinks paid cloud turns when you escalate. Pre-1.0 pricing isn't set; the core stays local-first.

Q

What does Claude Code still do better?

Honestly: frontier reasoning depth. Opus-class models lead public coding benchmarks, and Claude Code's git integration and hooks are mature. Anvaya's bet is different — memory that compounds plus local-first execution — and you can combine both via MCP: Claude Code turns served from Anvaya's memory.

Stop Starting From Zero.

One binary. 11+9 Rust crates. 545 tests. Hand-written HNSW index. Three transport modes. Four providers, Ollama, Anthropic, OpenAI, Siemens. Zero API keys required to start. Mind remembers everything after the first session.