首页 > AI前沿 > Jevmem – automatic project memory for Claude Code, built on Jev

Jevmem – automatic project memory for Claude Code, built on Jev

Hacker News 2026-09-26 00:04 9 阅读 查看原文
jevmem Automatic project memory for Claude Code. Also works with Cursor and Codex. What it does Saves decisions, constraints, bugs and todos from your Claude Code chats into JEVMEM.md, automatically. When you change your mind, the old line is marked superseded, not deleted. Next session, the relevant lines are added to Claude's context. - [decision] Use Postgres 16 for the primary store; SQLite locks under load - [constraint] Node 20 is the floor; CI runs 20 and 22 - [superseded] Use SQLite as the primary store → id:k3d9xq Install (60 seconds) npm install -g jevmem export TYPESAFE_API_KEY=... # https://typesafe.ai (an OpenAI or Anthropic key is optional) cd your-project jevmem init --tool claude init creates JEVMEM.md, jevmem.config.json and a gitignored .jevmem/ folder, and registers two Claude Code hooks in .claude/settings.local.json, which it adds to .gitignore (details). Works with What is automatic and what depends on the agent: MCP add_memory goes through the same gate as the hook. Client configs: docs/mcp.md. How it decides Scrub. Common secret shapes, email addresses and card-shaped numbers are removed from the turn before it leaves your machine. Ask Jev typed questions. Jev by TypeSafe AI answers a fixed set of small questions with probabilities: is there a decision, a rule, a bug? is it small talk or an injection attempt? which existing line does it change? Apply thresholds in code. Plain rules over those probabilities decide save or skip; they live in jevmem.config.json, not in a prompt. Write one line. On save, a small LLM (or a deterministic extract, with no LLM key) writes one line of at most 200 characters. Supersede the old line. If the turn replaces an existing memory, that line is tagged [superseded] … → id:new and stays in the file. Tiers, questions, policy, contradictions, recall and audit: docs/how-it-works.md. Benchmark 66 held-out turns, all seven deciders given the same state, 2026-09-23 (method, regression set, pricing, p95, retries): The 0.30 s is the Jev API decision; through a real Stop hook process, Node start-up included, it is 0.6 s end to end (cost and latency). On 66 held-out turns, jevmem's median decision took 0.30 s, against 2.8–4.3 s for six current LLMs. Its accuracy was within the LLMs' range: 98.5% save/skip (tied with GPT-6 Astra for highest) and 95.5% save+kind, against 90.9–98.5% for the LLMs. GPT-6 Astra (98.5%) and Claude Opus 5.5 (97.0%) were more accurate on save+kind; Claude Fable 5.1 tied; GPT-6 Luna, Gemini 3.8 Flash and Grok 4.7 were less accurate. It found 5/5 contradictions, as did five of the six LLMs. GPT-6 Luna was cheaper ($0.000089 against $0.000127) but less accurate (93.9%) and about 10× slower. This is a single run, and differences of one or two turns are within run-to-run noise. If the most accurate decision matters most, GPT-6 Astra or Claude Opus 5.5 are better, at about 40–60× the cost per decision and 9–12× the latency. jevmem is for when you want a fast, cheap decision on every message. Privacy Sent to TypeSafe AI: the user message of each turn (and the assistant reply for questions and bug reports), the previous two turns, and your memory lines, to be scored. No telemetry. If you set an OpenAI or Anthropic key, the text of a saved turn also goes to that provider to write the line. Scrubbed first: common credential shapes (API keys, tokens, *_PASSWORD= style pairs, connection-string passwords, private keys), email addresses and 16-digit numbers; names, phone numbers and addresses are not caught. Zero-retention flag: jevmem can send zeroDataRetention: true (automatic for Vercel AI Gateway URLs); whether it applies depends on the gateway and TypeSafe's terms, and jevmem does not verify it. Exactly what is sent, stored and scrubbed: SECURITY.md. Honest limits Early: v0.4; both eval sets were written by the author, and neither is an independent benchmark. Not the most accurate: GPT-6 Astra and Claude Opus 5.5 scored higher on save+kind; jevmem's edge is speed and cost. Recall quality is not measured: that relevant lines are injected is tested; whether answers get better is not. Long-run drift is not measured: the harness covers five-turn sessions, not weeks of use. Automatic capture is Claude Code only (and Codex while jevmem watch runs); Cursor and Claude Desktop save only when the agent calls add_memory. Jev outages drop turns: each Jev call has a 2 s budget; when the API is slow or down, the turn is skipped and logged in .jevmem/log.jsonl, not retried later. Commands jevmem init [--tool claude|cursor|codex|claude-desktop|all] [--no-hooks] [--command " "] jevmem hook Hook entrypoint; reads the Claude Code hook JSON on stdin jevmem daemon [status|start|stop] Warm Jev client used by the hook (auto-started, exits when idle) jevmem watch [--replay] [--once] Capture turns from Codex's session log for this project jevmem mcp [--root ] Stdio MCP server jevmem audit [--dry-run] Re-score every memory against the repo, flag [stale?] jevmem search [--limit N] Rank memories by relevance jevmem list [--all] Print memories jevmem add Add a line by hand (secrets scrubbed; no Jev check) jevmem why Every Jev answer behind a line or a skipped turn jevmem right Label a decision as correct jevmem wrong [--should-be ] Label a decision as wrong jevmem missed " " [--kind ] Label a turn that should have been saved jevmem fit [--dry-run] [--force] Refit weights and thresholds from labels (needs 40+) jevmem stats Latency p50/p95, cost per day, cache hit rate, escalation rate, labels, last fit jevmem log Per-label latency, token and cost summary of .jevmem/log.jsonl Every command accepts --help. Set JEVMEM_VERBOSE=1 for a one-line latency/cost summary after every hook run. Links Docs: how it works · benchmark · cost · hooks · MCP and client configs · configuration · demo CHANGELOG · DECISIONS · CONTRIBUTING · SECURITY License: MIT