Lessons Learned from Maintaining a Side Project (Kaydet) for Nine Years (mirat.dev)

🤖 AI Summary
Kaydet is a nine‑year terminal diary that evolved from a 20‑line vim wrapper into a local-first, queryable personal database with SQLite indexing and AI integration. The author rebuilt it when a client requested monthly activity reports, adding structured metadata (key:value pairs), numeric parsing (e.g., 2h → 2.0, 90m → 1.5), comparison operators (time:>2), ranges (time:1..3), wildcards (branch:feature/*), and a sync layer that keeps plain .txt files (the source of truth) and a SQLite index in sync. The implemented schema (entries, tags, words for full‑text search, metadata with numeric_value) enables optimized SQL joins for fast, precise searches. Stability for edits is handled by embedding stable entry IDs in files ([42]) and a --doctor command can rebuild the database from text when needed. Technically significant for the AI/ML community is how lightweight, human‑readable storage plus structured metadata makes data both durable and machine‑actionable: Claude Desktop MCP integration lets the model query the diary as context (mcp_server), turning prose into a “second brain” that can summarize sprints, extract billable expenses, or compute time spent. The project highlights practical engineering tradeoffs—file vs index consistency, regex pitfalls (metadata key rules to avoid parsing URLs), and the power of small, test‑covered tools (~3,200 Python lines, 99% tests). It’s a concrete pattern for building private, versionable personal knowledge bases that are immediately useful to AI agents.
Loading comments...
loading comments...