Disclosure: I’m the developer of the tool mentioned below. Been running Claude Code full-time on a growing TypeScript codebase. Two problems kept burning me: Token waste. Claude reads files linearly to build context. A single query was pulling ~18k tokens, most of it irrelevant. On Max plan that means hitting the usage cap faster. On API it’s just money on fire. Session amnesia. Every new session, Claude re-discovers the same architecture, re-reads the same files, asks the same questions. All the understanding from yesterday’s session? Gone. So I built a VS Code extension to fix both. For token waste: it builds a dependency graph from your code’s AST using tree-sitter. Not embeddings, not semantic search, actual structural relationships. Who calls what, who imports what, what types flow where. When Claude asks for context, it gets a token-budgeted capsule with only the relevant subgraph. ~2.4k tokens instead of ~18k. Better context, fewer tokens. For session memory: observations from each session are linked to specific nodes in the dependency graph. What Claude explored, what it changed, what patterns it noticed. But here’s the thing I didn’t expect: Claude won’t save its own notes even if you ask. Put “save what you learn” in CLAUDE.md, it cooperates maybe 10% of the time. So the extension also observes passively, it watches what Claude does, detects file changes at the AST level (not “file modified” but “function signature changed, parameter added”), and generates memory automatically. When code changes later, linked observations go stale. Next session, Claude sees “previous context exists but code changed since, re-evaluate.” Also catches anti-patterns: dead-end exploration (added something then removed it same session) and file thrashing (modifying same file 4+ times in 5 minutes). Auto-generates .claude/CLAUDE.md with the full MCP tool descriptions based on your project structure. Auto-detects Claude Code via env vars. Native Rust binary under the hood, SQLite, 100% local, zero cloud, zero network calls. Works with Cursor, Copilot, Windsurf, Zed, Continue, and other agents too, but built Claude Code-first. It’s called vexp ( https://vexp.dev/ ), free on the VS Code Marketplace. What’s your current approach for session continuity? Curious what’s working for people. submitted by /u/Objective_Law2034
Originally posted by u/Objective_Law2034 on r/ClaudeCode
