{"slug": "introducing-kilo-memory-project-scoped-memory-for-your-agents", "title": "Introducing Kilo Memory: Project-Scoped Memory for Your Agents", "summary": "Kilo has introduced Kilo Memory, a local, project-scoped memory system for AI coding agents that stores session digests, project environment details, user corrections, and explicit memory updates to share context across sessions and worktrees. The feature, available in Kilo's CLI and VS Code Agent Manager, captures high-signal information on session close and recalls it via startup injection, prompt-targeted recall, and an explicit tool, with a consolidation step to keep memory lean and token costs low.", "body_md": "# Introducing Kilo Memory: Project-Scoped Memory for Your Agents\n\n### Your agents shouldn't have to re-learn your project every session\n\nThe other day, one of our engineers was debugging an issue in Kilo’s CLI. He’d spent a full session isolating the problem, identifying the root cause, and narrowing down the fix. Then his session timed out. He started a fresh one, and the agent immediately tried the exact thing he’d already ruled out twenty minutes earlier.\n\nThis is a familiar frustration. Every new AI coding session starts from zero. The agent has to re-derive your project structure, re-read your test setup, re-figure out your deployment pipeline. It doesn’t know that you prefer vitest over jest, that the packages/core directory has a weird circular dependency you’ve been working around, or that the last three sessions all failed because of a missing environment variable.\n\nWe built [Kilo Memory](https://github.com/Kilo-Org/kilocode/pull/11172) to fix that.\n\n## How engineers actually work now\n\nThe way we write code has changed. I don’t have one terminal open with one coding session anymore. On a typical day, I might have:\n\nA CLI session refactoring a module\n\nA VS Code Agent Manager tab running tests in parallel\n\nAnother session handling a quick PR review\n\nAn agent in GitHub dealing with a bug in a related service\n\nThat’s four surfaces, all working in the same repo, all starting with no shared context. Each new session is a blank slate that has to bootstrap itself — read_file calls, directory traversals, grepping through git history just to understand what happened an hour ago.\n\nMultiply that by a team, and you’ve got agents spending significant portions of their context window just getting oriented.\n\n## What Kilo Memory does\n\nKilo Memory is a local, project-scoped memory system. Memories are stored in Kilo's global data directory, with each repository getting its own isolated memory store (for example, **<Kilo Global Path>/memory/<repo-path-hash>**). When enabled, it lets your agents share context across sessions and worktrees, so you don't have to manually re-explain things every time you switch contexts.\n\nIt stores:\n\n**Session digests**— Short summaries of what happened in recent sessions (capped at the last 10)** Project environment**— Your repo setup, testing config, build pipeline, relevant tooling context** User corrections**— When you tell the agent “no, we don’t use that library” or “always run tests with --coverage”, it remembers** Explicit memory updates —**Anything you explicitly tell Kilo to remember or forget (for example, using /memory).\n\nAnd it recalls context in three ways:\n\n**Startup injection**— High-signal project context gets loaded at session start** Prompt-targeted recall**— When your current request looks memory-relevant, it pulls in related context** Explicit tool recall**— The kilo_memory_recall tool with search, typed, digest, and catalog modes\n\nThe key design decision: a consolidation step decides what’s worth saving. Most things get skipped. This keeps memory lean and token costs low rather than naively dumping everything into a growing blob.\n\n## The architecture\n\nMemory is file-system based and stored locally on your machine. There is no separate cloud sync or external memory database. Memory is stored in Kilo’s global data directory and scoped to each project using a hash of its repository path, so every repository gets its own isolated memory store.\n\nThe memory store consists of durable memory files, short session digests, and a search index.\n\n**Memory Store**\n\n├── Memory files\n\n├── Sessions/\n\n└── Search index\n\nCapture happens automatically on session close. When a session ends, the system evaluates what’s worth remembering — decisions made, corrections issued, environment details discovered — and writes only durable, useful information.\n\nRecall is selective. Rather than expensive full-index searches on every turn, a digest layer sits above the index and only triggers deeper recall when the current request looks memory-relevant.\n\nMemory can be enabled or disabled through the configuration or the /memory commands. If anything goes sideways, a single toggle turns it off without deleting stored memory.\n\n## Controlling memory\n\nThe same `/memory`\n\ncommands are available in the CLI, TUI, and VS Code chat.\n\n**Commands:**\n\n/memory on|off — Toggle memory on or off\n\n/memory auto on|off — Toggle automatic memory capture on or off\n\n/memory remember <message> — Explicitly save something\n\n/memory status — View memory status and configuration\n\n/memory show — Inspect what’s stored\n\n/memory forget <query> — Remove specific memories\n\n/memory purge — Removes all project memory files completely\n\nVS Code also provides a dedicated Settings page for memory control and storage inspection.\n\nWhen you disable memory, no context is injected — but your memory remains on disk. You can re-enable it at any time without losing anything.\n\n## Why local matters\n\nI’ve been watching the memory-for-agents space closely. [Engram](https://github.com/cyanheads/engram-mcp-server) uses SQLite, [Continuum](https://www.continuum.sh/) is MCP-based, [Kairo](https://github.com/nicobailon/kairo) scans your repo once and remembers architecture, [mem0](https://mem0.ai/) is building managed memory services.\n\nAll of them are external tools that require separate setup and MCP plumbing.\n\nKilo Memory is different because it's built into Kilo. No MCP server to configure. No external service to trust with your codebase context. Once enabled, it works across the CLI, TUI, and VS Code without requiring separate integrations for each surface.\n\n## Trade-offs and limitations\n\nThis is still experimental. Some things to know:\n\n**Capture quality is still evolving —** The consolidation step tries to retain durable, useful information while filtering out transient, noisy, or sensitive context, but the heuristics are not perfect yet.**Multilingual support is still evolving**— Memory is designed to work across languages rather than relying on English-specific logic. As a result, capture and retrieval quality may occasionally be less precise while the system continues to improve.**Needs adversarial testing**— We haven’t fully stress-tested for false positives (injecting irrelevant memory), stale facts (remembering something that’s no longer true), or missed recalls (failing to surface relevant context).**Prompt injection surface**— Memory content is injected as non-instructional context, but any time you inject stored text into a model context, you need to think about prompt injection boundaries. We’re reviewing this carefully.**Stored outside the repository**— Memory is stored in Kilo’s global data directory rather than inside the repository. This allows it to be shared across worktrees and keeps generated files out of the project, but it also means memory cannot currently be versioned or shared with teammates through Git.\n\n**Memory ships as an opt-in feature.** Turn it on if you want to try it. Turn it off if it gets in the way.\n\n## Try it\n\nKilo Memory is available now as an opt-in feature. To enable it:\n\nMake sure you’re on the latest Kilo version\n\nIn any session, run /memory enable\n\nWork normally — memory captures automatically on session close\n\nStart a new session and notice the agent already knows your project context\n\nTell it to remember specific things: `/memory`\n\nremember we use pnpm, not npm or /`memory`\n\nremember the auth service requires REDIS_URL to be set locally.\n\nIf you hit issues or have feedback, drop into the [Kilo Discord](https://discord.gg/kilocode) — we’re actively collecting input on recall quality, capture decisions, and what kinds of context are most useful to persist.\n\n*Kilo Memory is part of PR #11172, built by johnnyeric.*", "url": "https://wpnews.pro/news/introducing-kilo-memory-project-scoped-memory-for-your-agents", "canonical_source": "https://blog.kilo.ai/p/introducing-kilo-memory", "published_at": "2026-07-22 16:08:32+00:00", "updated_at": "2026-07-22 16:29:11.149220+00:00", "lang": "en", "topics": ["ai-tools", "developer-tools", "ai-agents", "machine-learning"], "entities": ["Kilo", "Kilo Memory", "Kilo CLI", "VS Code Agent Manager", "GitHub"], "alternates": {"html": "https://wpnews.pro/news/introducing-kilo-memory-project-scoped-memory-for-your-agents", "markdown": "https://wpnews.pro/news/introducing-kilo-memory-project-scoped-memory-for-your-agents.md", "text": "https://wpnews.pro/news/introducing-kilo-memory-project-scoped-memory-for-your-agents.txt", "jsonld": "https://wpnews.pro/news/introducing-kilo-memory-project-scoped-memory-for-your-agents.jsonld"}}