Hybrid 3-File Architecture (v1.5.3)
The Hybrid 3-File Model solves the “Token Waste vs. Amnesia” problem for AI agents managing tasks. Instead of forcing the agent to read a massive backlog file every session, work is distributed across three specialized files.
🌉 A Bridge Between Two Thinking Worlds
This model acts as a bridge between:
- Short-term Thinking (AI Agent): Requires extreme focus and minimal input data to avoid noise and token waste.
- Long-term Thinking (Human): Requires full history, macro planning, and completion evidence for project governance.
📦 The Three Core Components
The system operates around 3 files located in the artifacts/tasks/ directory:
artifacts/tasks/
├── backlog.md # 📌 Operational Authority — single source of truth
├── sprint-current.md # 🔥 Hot Lane — agent-writable buffer for ad-hoc quick tasks
└── done.md # ✅ Historical Archive — plan-grouped, append-only log
| File | Role | Read/Write |
|---|---|---|
backlog.md | Operational Authority — all tasks (active tables + compressed Completed section) | Agent + User |
sprint-current.md | Hot Lane — ad-hoc quick tasks during coding session | Agent-writable |
done.md | Historical Archive — completed tasks grouped by plan, with origin tags | Append-only |
1. backlog.md (Operational Authority)
- Role: The single source of truth storing the entire task lifecycle (Bugs, Features, ICE Scores).
- Problem Solved: Keeps the Macro View intact for humans without forcing the AI to re-read thousands of lines of old plans constantly.
- Rule: Updated exclusively via the
/backlogcommand.
2. sprint-current.md (🔥 Hot Lane)
- Role: An agent-writable buffer for ad-hoc quick tasks that arise during a coding session.
- Problem Solved: Eliminates ceremony — the agent writes quick tasks directly here instead of going through
/backlog updatefor every small item. - Rule: Agent writes directly during sessions. Flushed to
done.mdby/end.
[!NOTE] In v1.5.3,
sprint-current.mdis no longer a system-generated mirror of the backlog. It is the Hot Lane — a lightweight buffer where the agent captures quick tasks as they arise during work, with zero overhead.
3. done.md (Historical Archive)
- Role: An append-only archive of every completed task, grouped by plan with origin tags (
#backlogor#session). - Problem Solved: Battles “AI Amnesia” during long chat sessions. Provides quantitative evidence for
/retroto calculate Project Velocity.
🗜️ Backlog Compression (/backlog clean)
Done items are compressed, not deleted. The clean action moves Done items from active tables into the ✅ Completed (Archived) section (1 line per plan + IDs list).
Lookup chain:
backlog.md (✅ Completed: plan name + IDs)
↓ link
done.md (per-task detail, grouped by plan heading)
↓ link
plans/done/*.md (full plan: phases, architecture, DoD)
This preserves backlog.md as the single source of truth for all tasks while keeping it token-efficient.
🔄 Operation Flow
Two Parallel Streams
- Strategic stream:
/plan→/backlog sync→ work →/end→done.md(origin:#backlog) - Quick task stream: session request → Hot Lane →
/end→done.md(origin:#session) or promote →backlog.md
Key Workflow Integration
| Workflow | Role |
|---|---|
/open | Reads backlog Summary (~10 lines) + Hot Lane. Never the full backlog. |
/end | Sole sync point — Hot Lane Sync + Smart Suggest + plan check |
/backlog clean | Compress Done items into Completed section. Details → done.md |
/plan review | Counts task IDs in done.md to measure Phase progress |
/retro | Analyzes done.md — #backlog vs #session ratio for velocity |
[!IMPORTANT] Critical Requirement: The 3-file mechanism only becomes operational after you execute the
/backlog synccommand following your planning phase (/plan). Without this synchronization, tasks exist only as “blueprints” inplan.mdand will never receive the IDs required to trigger the Agent’s high-speed operational flow.
📊 Token Budget
One of the key design goals is keeping the /open context ultra-light:
| Source | Tokens | Condition |
|---|---|---|
| project.md | ~80-120 | Always |
| sprint-current.md | ~50-100 | Always (if exists) |
| backlog.md Summary | ~80-130 | Always (grep summary + active) |
| session log | ~50-100 | Always (tail) |
| plan (if active) | ~30-50 | Only if active_plan set |
| SYNC.md | ~50-100 | Only if downstream set |
| Total (simple) | ~260-450 | No plan, no sync |
| Total (full) | ~360-640 | Plan + sync |
Compare this to the traditional approach where a single backlog read could consume ~3,000+ tokens.
📜 Version History
The architecture has evolved significantly across recent versions:
| Aspect | v1.5.2 (Working Checkmarks) | v1.5.3 (Hot Lane) |
|---|---|---|
| sprint-current.md | Mirror backlog (unused) | Hot Lane — agent writes directly |
| Quick tasks | Unstructured | sprint-current.md = Hot Lane |
| Sync point | Multiple commands | /end only |
| Ceremony during coding | /backlog update per task | Zero |
| done.md structure | Flat, date-grouped | Plan-grouped with origin tags |
/backlog clean | Delete from backlog | Compress into Completed section |
📚 References
- Rule: Hybrid 3-File Integrity — C1 (Hot Lane), C2 (plan-grouped done.md), C3 (compress-not-delete), C5 (/end sync)
- Workflow: /backlog, /end, /plan, /retro
- Learn: Defense-in-Depth — File Guard Headers (Layer 4)
→ Explore Workflow /open with Hybrid 3-File → Explore Workflow /backlog → Explore Workflow /end — The Sole Sync Point