Codex Meetup01

Codex Meetup · April 27, 2026 / Singapore

CodeDB: Efficient Code Intelligence Server

Index a codebase once. Serve structured answers to agents through MCP, HTTP, and CLI with lower latency and fewer tokens.

MCPJSON-RPCHTTPZigGitHub
Problem02

Agents are not only model-bound. They are IO-bound and token-bound.

A coding agent spends a surprising amount of time doing the same loop: walk files, open files, dump raw text, infer structure, edit, read again.

searchwalk + scan
readserialize
parseinfer
editpatch
verifyrepeat
~59 mssingle rg search on a local Zig reporaw line matches
100squeries per agent sessionsame cost repeated
raw textmodel has to parse ittokens become compute
Evolution03

From fast code search to durable code memory

The original idea was already useful: a Zig code intelligence server with MCP, HTTP, CLI, structural indexing, trigram search, word lookup, and dependency graphs.

Then

Code intelligence server: index on startup, answer tree, outline, symbol, search, and dependency questions.

Now

Agent memory layer: snapshots, worker-local indexing, SIMD lookup, remote GitHub queries, locks, heartbeats, and change tracking.

The evolution is from returning matches to maintaining a current, structured model of the codebase.

Architecture04

Index once. Query the codebase like a database.

agentsClaude CodeCodexCursor
codedb daemonhot structured memory
MCP stdioHTTP :7719CLI

One index serves every tree, symbol, search, and dependency question.

indexes
Structure
treeoutlinesymbol
Search
wordtrigramdeps
Freshness
snapshotwatcherchanges
agent asksWhere is handleBatch and what can it affect?
codedb returnssymbol + outline + deps useful context, not a whole file dump

Agents ask for the minimum useful structure instead of rediscovering it from raw files.

Token savings05

Structured answers cut token volume by orders of magnitude

Benchmarked on the codedb repo (Apple M4 Pro). Tokens ≈ chars ÷ 4.

search 'allocator'
raw
32,564
codedb
20
1,628×
outline main.zig
raw
4,800
codedb
45
107×
edit handleBatch
raw
29,600
codedb
3,200

Most token waste is full-file dumps and repeated reads. codedb returns only what the agent asked for.

Performance06

v0.2.572 made the index dramatically cheaper

Benchmark: openclaw, 6,315 files, Apple M4 Pro, ReleaseFast.

Initial index time3.6 s346 ms10x faster
Cold RSS~3.5 GB~580 MB-83%
Warm RSS~1.9 GB~150 MB-92%
Git subprocesses / 30s152-87%
worker-localindex fragments merge without lock contention
24B -> 8Bpacked WordHit drove warm RSS down
SIMDraw buffers scan before line computation
Fast path07

Most queries should stop before touching file contents

T0Word indexDirect exact identifier lookup<1 ms
T1Trigram covering setIntersect posting lists for candidates~2 ms
T2SIMD content scan16-byte vector scan on candidates~10 ms
T3Sparse trigram fallbackSkip covering set when enough hits exist~20 ms
T4Case-insensitive scanFull content path only when needed~35 ms
T5Full fallbackDeferred maps and exhaustive path~55 ms

Start with the cheapest index. Escalate only when cheaper evidence is insufficient.

Muonry08

The action plane: every tool in-process, every op in one call.

read
  • outline
  • symbol
  • lines
  • smart_range
search
  • literal
  • word
  • regex
  • meta
edit
  • symbol
  • pattern
  • range
  • after
diff
  • verify result
memo
  • store
  • recall
  • cross-session
batch
  • N ops · 1 round-trip
  • 10× faster
fork / exec
~15 ms / op
muonry
~0.7 ms / op · 21× faster
Sandbox agents09

A controlled loop: structured context, scoped writes, inspectable trail.

agentClaude / Codex / Cursor

receives task, emits tool calls

sandbox runtime
file scope lockheartbeat timeoutdeferred opsaudit log
knowledgecodedb

symbols · deps · snapshots · changes

actionmuonry

read · edit · diff · memo · batch

Every run is reproducible: same task, same snapshot, same diff. Kuri is our open runtime for this loop.

Demo10

codedb + muonry: ~9× fewer bytes per task, ~1,600× on search

1
Indexcodedb_index /path/to/repo346 ms · 6,315 files · <2 ms re-index
2
Structural viewcodedb_outline src/mcp.zig45 tokens vs ~4,800 for cat
3
Locate symbolcodedb_word handleBatch · muonry symbol~170 tokens total
4
Precise editmuonry edit symbol=handleBatch · muonry diff~500 token diff, not the full file
5
Blast radiuscodedb_deps · codedb_changes since=<seq>dep graph + change log, ~200 tokens

Full session: ~915 tokens vs ~29,600 for the same task with raw rg + cat.

Built with11

The same stack, across the whole toolchain.

codedbcode intelligence738

Index a codebase once. Serve structured answers to agents via MCP, HTTP, and CLI.

346 ms to index 6,315 filesgithub.com/justrach/codedb
merjszig web framework320

Next.js DX compiled to WebAssembly and native binaries. No Node.js.

115,093 req/s · <5ms cold start · 260 KBgithub.com/justrach/merjs
turboapipython + zig943
🏆 Top 3 on GitHub Trending

FastAPI-compatible framework with a Zig HTTP core. Same Python API, way faster.

140,000 req/s · 12–18× faster than FastAPIgithub.com/justrach/turboapi
nanobrewpackage manager987
🏆 Top 5 on GitHub Trending

Homebrew-compatible package manager in Zig. Parallel downloads, content-addressed cache.

3.5ms warm install · 13× faster than apt · 1.2 MBgithub.com/justrach/nanobrew
devswarmagent orchestration43

MCP server that decomposes large coding tasks across parallel specialised agents.

37 tools · 8 agent roles · auto Opus/Sonnet/Haiku routinggithub.com/justrach/devswarm
codedb tools12

The knowledge plane: 18 tools to read code without flooding context.

outline
  • functions · structs
  • 4–15× fewer tokens
symbol
  • exact definitions
  • with body
word
  • O(1) lookup
  • inverted index
search
  • full-text · regex
  • scope blocks
find
  • fuzzy file
  • typo-tolerant
deps
  • imported_by
  • transitive blast radius
tree
  • full layout
  • languages · counts
read
  • range · compact
  • if_hash skip
query
  • pipeline
  • find→deps→outline
bundle
  • 20 ops
  • 1 round-trip
hot
  • recent files
  • active surface
changes
  • since seq
  • polling watch

outline first, read only the slice that matters — every tool feeds the same trigram + word index.

wiki.codes13

Public code intelligence API — any GitHub repo, no fork, no keys.

livehttps://api.wiki.codes
codedb_remoteMCPHTTP
GET /api/<repo>/treefull file tree, paginated
GET /api/<repo>/outlinesymbols + line numbers
GET /api/<repo>/symbolexact definitions
GET /api/<repo>/searchfull-text grep
GET /api/<repo>/readfile slice by lines
GET /api/<repo>/depsimport graph
GET /api/<repo>/scorecode health · A–F
GET /api/<repo>/cvesknown vulnerabilities

Same shape as local codedb. The cloud router serves precomputed parquet artifacts — no parse-on-request.

DevSwarm14

Subagent swarms with an evolutionary loop. codedb feeds them context.

One MCP server, provider-agnostic — Codex routes to GPT-5.5, Claude Code routes to Sonnet / Opus. Per-role model choice, MAP-Elites prompt archive, and a fitness-driven evolutionary loop.

orchestrator · Opusplan + dispatch
fan-out
explorermap blast radiusSonnet
architectdesign changesOpus
fixerapply patchGPT-5.5
reviewerverify diffSonnet
fan-in
synthesizer · GPT-5.5one report
1 · run

workers execute with prompts sampled from the archive

2 · score

fitness = success · cost · speed · errors

3 · place

winners slot into a MAP-Elites grid (token_eff × thoroughness)

4 · sample

softmax weighted — diversity preserved, best prompts win more often

codedb shrinks each worker's context — more workers fit, the archive evolves faster, the swarm gets smarter every run.

Takeaway15

Give agents code memory, safe actions, and a sandbox to run in

CodeDB

A structured, current model of the repository.

Muonry

A precise action layer for reads, edits, diffs, batches, and memory.

Sandbox agents

A controlled execution loop with scopes, locks, logs, and workflows.

Join the waitlist — fastest sandbox for AI agents

codegraff.com/agents

Join waitlist →