DEV Community

changmyoungkim
changmyoungkim

Posted on

Doby: How I Cut Claude Code's Navigation Tokens by 95% with a Spec-First Workflow

  1. The Problem — Token waste on "where is X?" + code-spec drift
    1. Existing Solutions — Manual context, @-mentions, MCP memory — all incomplete
    2. The 4-Layer Architecture — L1 grep index, L2 wiki, L3 RAG, L4 compile
    3. The Killer Feature: Spec-First Fix — Phase 0-7 workflow with consensus loops
    4. Real Numbers — Before/after token comparison from production use
    5. Getting Started — 4-step setup
    6. What's Next — Roadmap, contributions welcome

GitHub logo changmyoungkim / doby

Doby — Structured Memory + Spec-First Fix Workflow for LLM-Driven Development

doby — Spec-First Code Modification for LLM-Driven Development

Doby — Your loyal code elf

License: MIT GitHub stars GitHub forks

Keyword → Plan Doc → Code File → Symbol in 2 grep calls (~100 tokens).

The Problem

The biggest token waste in LLM-driven development is finding where to make changes. A single change request burns 2,000-5,000 tokens just on navigation. Then comes the greater waste: implementing code that violates the spec, requiring iteration and rework.

doby cuts navigation to ~100 tokens via pre-compiled indexing. More importantly, it enforces spec-first workflows — your plan docs become the source of truth, verified before code is written.

How L1 Works

User: "fix the audio playback"

grep "audio" INDEX-keywords.md
→ audio:audio-playback.md,tts-config.md

grep "audio-playback.md" INDEX.md
→ @audio|audio-playback.md|src/hooks/useAudio.ts#useAudio,play;api/audio.py#get_audio|active

Done. 2 grep calls. Domain, plan doc, code files, symbols, status — all in one line.

Spec-First Fix Workflow (Mode 6)

The core differentiator. When any code modification is requested:




flowchart TD
A["Phase 0: doby resolve\n🔍 grep 2 calls





Top comments (0)