Index, memory and data
IZ Code keeps three kinds of data for agents: a code index of your project, a layered memory of past work, and connections to your databases. All three run in or beside the Rust core, store their data in SQLite on the machine that holds the code, and answer agents through IZ Code's own tools.
Where the data lives#
your-project/.izcode/
├── awe-index.sqlite code index (symbols, references, call graph)
├── agent-memory/ scene and persona Markdown files
└── settings.json workspace settings
IZ Code data folder/workspaces/<folder>-<hash>/
├── agent-memory.sqlite Agent Memory (L0–L3, skills, wiki index)
└── tasks.sqlite tasks and workflows| Data | Where | Scope |
|---|---|---|
| Code index | .izcode/awe-index.sqlite in each root | One per workspace folder |
| Agent Memory database, tasks | IZ Code's data folder, one subfolder per workspace | One per workspace folder |
| Scenes and persona | Markdown files in .izcode/agent-memory/ | One per workspace folder |
| Cross-project persona (L4) | IZ Code's data folder | Your user, all projects |
| Database connections, history, saved SQL | IZ Code's data folder | Your user, not the workspace |
The memory and task databases are kept outside the project on purpose: no agent file tool, shell command or git clean that works inside the project can reach them. On macOS and Linux a link is left at .izcode/ so older versions still find them.
Each machine keeps its own copy of this data. An SSH, peer or cloud workspace keeps its index and memory on that machine. Nothing is uploaded to build them.
Code index#
The code index is a local, always-fresh map of your code. It is what agents use when they ask "where is this defined", "who calls it" or "what breaks if I change it".
flowchart TD
f["Files"] --> parse["Parse"]
parse --> sym["Symbols and references"]
sym --> res["Resolve calls"]
res --> db[("SQLite index")]
w["File watcher"] -- "changed files" --> parseWhat is stored. One row per definition (functions, classes, methods, types and so on), with signature, visibility, docstring and position. Every call or reference site is stored too, and resolved calls become edges of a call graph. A full-text index over symbol names makes name lookups fast. Framework routes and navigation (for example Django, FastAPI, Express and Next.js) are stored separately and marked as heuristic, so an agent can tell them apart from real call edges.
Resolving calls carefully. A call is linked to a definition by looking in the same file first, then by imports, receiver types and the rest of the project. When a name is ambiguous, the reference is parked and retried later instead of guessed.
Impact analysis. Callers, callees and a breadth-first "blast radius" walk over the graph show which code depends on a symbol, grouped by definition so two functions with the same name are not mixed up.
Always fresh. A file watcher re-indexes only the files that changed, in one transaction, and retries parked references that a new file may resolve. A periodic check compares content hashes to catch anything the watcher missed. The index builds itself the first time you open a folder; the status bar shows the progress while it runs.
Languages. 20+ languages, including Rust, TypeScript, JavaScript, Python, Go, Java, C, C++, Ruby, PHP and C#, which get the richest symbol details.
Sized to your machine. Worker counts follow your CPU count and the memory actually available, including container limits on Linux.
Optional semantic search#
Name search finds AuthService; semantic search also finds it when you ask "how are tokens validated". It is off by default.
- Small local model. Embeddings come from a compact static embedding model that runs on the CPU, with no neural-network inference step and no external service. It is downloaded once when you turn the feature on. The default model is tuned for code; English, retrieval and multilingual models are also offered.
- Stored in the same SQLite file, using a vector extension compiled into IZ Code.
- Hybrid ranking. Results from name search and vector search are fused, leaning towards names when your query looks like a symbol and balancing both for a plain-language question.
Tools agents get#
| Tool | Use |
|---|---|
codeExplore | One call returns entry points, related symbols and real code snippets within a size budget. On by default. |
codeSearch | Find symbols by name (and by meaning, with semantic search on). |
codeNode | Read one symbol or file with its callers and callees. |
codeCallers, codeCallees | One hop along the call graph. |
codeImpact | Everything affected by a change, a few levels deep. |
codeFiles, codeStatus | The indexed file tree; index health and freshness. |
codeRipgrep | Live text and regex search over file contents. |
Only codeExplore is on by default; turn on the others in Configure Tools. If a folder has no index yet, the tools say so in plain text and the agent falls back to other tools. See Code Intelligence.
Agent Memory#
Agent Memory runs inside the core, with no extra process. It turns conversations into reusable knowledge in layers:
flowchart TD
l0["L0 conversation: messages, replies, tool calls"] -- "every few turns or when quiet" --> l1["L1 atomic facts"]
l1 -- "on a timer, new facts" --> l2["L2 scenes: Markdown files"]
l2 -- "on thresholds" --> l3["L3 project persona"]
l4["L4 global persona across projects"]Next to the layers:
- Skills. Reusable procedures with version history, created from long sessions or by agents (with your approval).
- Wiki. Pages ingested from documents, folders or Git repositories. The wiki is re-ingested when watched sources change, and is searched with full-text ranking plus a walk over links between pages.
How agents use it. A short static block (persona, scene index, wiki summary) can be added to the first-turn context, and relevant facts can be recalled for each message. Agents also get memory tools to search facts, conversations, skills and the wiki. Writes to skills go through the permission engine.
Which model does the work. Building L1–L3 and ingesting the wiki needs a language model. You choose either an HTTP chat-completion API or one of your installed agents. Fact search can also use embeddings, from the same local models as the code index or from an OpenAI-compatible embeddings endpoint.
See Agent Memory.
Database engine#
The database feature lets you browse and query databases and lets agents run SQL with guard rails. It is off by default and costs nothing while off: no process runs and no database tools appear in an agent's tool list.
flowchart LR
ui["UI"] -- "token" --> side["Database sidecar: drivers, connection store, MCP policy"]
tools["Agent tools"] --> core["Rust core"]
core --> sideThe isolation, layer by layer:
| Layer | What it does |
|---|---|
| Separate process | All database drivers live in a sidecar, not in the core. It starts on first use and stops after it has been idle (10 minutes by default). |
| Loopback and token | The sidecar listens on 127.0.0.1 only, checks a fresh token on every start, and accepts requests only from IZ Code's own window. |
| Watchdog | If IZ Code exits, even if it is killed, the sidecar shuts itself down. |
| Credentials | Passwords stay in the sidecar's store. Agents only see connection name, type and host, never the password. |
| Per-call approval | Reads run without asking. Writes and DDL ask. DROP, TRUNCATE, GRANT and UPDATE/DELETE without WHERE are marked dangerous. Anything that cannot be classified is treated as a write. |
| Second policy | Independently, the sidecar refuses agent writes until you allow them in its MCP policy, per connection. |
| Redaction | Secret-looking fields are removed from tool results, memory records and logs. |
See Database.
Settings#
| Setting | Values | Default |
|---|---|---|
izcode.awe.index.enabled | true, false | true |
izcode.awe.semanticSearch.enabled | true, false | false |
izcode.awe.semanticSearch.model | Model id | potion-code-16M-v2 |
izcode.ame.enabled | true, false | true |
izcode.adb.enabled | true, false | false |
izcode.adb.idleStopMinutes | Minutes, 0 = never | 10 |