Blog
Engineering notes & updates
Behind the scenes of building a personal OS.
#18 — Photograph a receipt, and your inventory fills itself in
Knowing what you own, where it is and what it's worth is one of those jobs everyone abandons after a week. So the work of keeping it current got moved off you: point a camera at a receipt, approve a list, done.
#17 — Three ways to look at your money. Pick the one that's you.
The money module in Micelclaw isn't one screen trying to serve everyone. It's three: one for a person who wants to know where it went, one for a freelancer chasing invoices, and one for a company that has to file. Same data, three lenses.
#16 — A 45% cut, and two things I was wrong about
One of our agents stopped fitting in its own context window. Trimming the tool catalogue by 45% took two lines of deletion — but getting there meant retracting two confident conclusions and one bug that turned out not to exist.
#15 — Seven agents per user: delegation, and every way it broke
We gave each user seven specialist agents and one coordinator. Then we spent four months finding out that the hard part isn't the topology — it's what happens when one agent hands work to another.
#14 — Deterministic agent identity: a before_tool_call hook fills the token the model kept getting wrong
Our MCP facade needs an auth_token on every tool call. The model kept mangling that 64-hex secret — and subagents spawned via sessions_spawn never got one at all, so delegated tasks failed silently ("Dalí doesn't answer"). Here's the native OpenClaw before_tool_call hook that injects each agent's token host-side, keyed by ctx.agentId, so the model never touches it.
#13 — The MCP facade: how agents talk to the backend without curl
Our agents used to curl the Core API from inside a sandboxed container — and it failed with exit 7, every single time. Here's the MCP facade that replaced it: one typed tool per domain, dispatched through the full auth-scope-approval-audit pipeline via app.inject(), with zero business logic rewritten.
#12 — Building a process manager for 40 services on 8GB of RAM
Docker containers, systemd services, Ollama models, and internal workers — all in one table. How we built a unified process manager with a RAM budget engine that decides what runs, what waits, and what gets evicted.
#11 — Designing an AI approval system: when should your agent ask for permission?
An AI agent that can send emails, delete files, and configure VPNs needs guardrails. We built a 4-level approval system with shell control, PIN verification, and configurable timeouts — without slowing down everyday operations.
#10 — PII-aware routing: how to use cloud AI and keep your sensitive data local
When your personal AI system needs cloud models for complex reasoning but handles sensitive data, you need a privacy router. Here's how we built one with regex, pseudonyms, and a routing table — no ML required.
#09 — Sleep-time compute for personal data: what your AI should do while you sleep
Most personal AI systems sit idle 95% of the time. We built a background intelligence engine that discovers cross-domain connections, learns your preferences, and pre-computes insights — all while you're not using it.
#08 — Hybrid search with RRF: combining pgvector, tsvector, and a knowledge graph in one query
How we fused semantic search, full-text search, knowledge graph traversal, and heat scoring into a single search pipeline using Reciprocal Rank Fusion — all inside PostgreSQL.
#07 — Your AI agent is wasting 90% of its tokens on field names
We audited our agent's token consumption and found that 25% of the context window was skills, 10% was identity files, and the actual user message was a rounding error. Here's what we did about it.
#06 — From JSON to compact: reducing API payloads 60% for LLM consumption
Your AI agent doesn't need pretty JSON. We built a compact response format that cuts token usage dramatically — and learned what to kill along the way.
#05 — Heat scoring: teaching your data to forget (gracefully)
Every record in our system has a temperature. It rises when you interact with it and decays exponentially when you don't. Here's how a simple formula changed the way search, digest, and the AI agent work with personal data.
#04 — Building a personal knowledge graph with just PostgreSQL (no Neo4j needed)
How two tables, three ALTER statements, and recursive CTEs replaced what most people reach for a graph database to do. At personal scale, PostgreSQL is the graph database.
#02 — The 4-slot hook pipeline: how every CRUD operation feeds four systems at once
A simple post-CRUD pipeline that feeds embeddings, heat tracking, entity extraction, and the changelog — without any of them blocking each other or the user.
#03 — Entity extraction with a 2B model: benchmarks from a personal knowledge graph
We benchmarked qwen3-vl (2B parameters, quantized) for NER on personal data — notes, emails, diary entries, and photos. The results surprised us, but not in the way F1 scores suggest.
#01 — 137 migrations and counting: building a personal OS schema from scratch
How a weekend project to save contacts efficiently turned into a 147-table PostgreSQL schema powering a full personal operating system.