Adds Budget panel (B key) to TUI with per-bead/per-worker cost tracking,
EMA-smoothed burn rate, time-series storage, and CostDashboard web component.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Implements persistent storage for historical session analytics:
- Add HistoricalStore class using better-sqlite3
- Schema includes sessions, task_metrics, and error_history tables
- Session management: start/end sessions with worker/task/cost metrics
- Task metrics: record per-bead completion times, costs, tokens
- Error history: track errors with resolution status
- Historical queries: worker comparison across sessions
- Learned recoveries: extract patterns from historical error resolutions
- Integration with EventStore for automatic session persistence
- Historical query methods in WorkerAnalytics
- Enhanced recovery suggestions using historical data in RecoveryManager
- Comprehensive unit tests (20 passing tests)
Database stored at ~/.needle/fabric.db for cross-session persistence.
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude Worker <noreply@anthropic.com>
Implements bd-3a4 and bd-2pa.1 (project setup):
- Initialize npm project with TypeScript configuration
- Add package.json with build scripts and dependencies
- Create src/ structure with types and CLI entry point
- Add CLI commands: tui, web, tail (placeholders)
- Configure tsconfig.json for NodeNext modules
This addresses worker starvation (bd-29a) by demonstrating
that direct implementation is a viable alternative when
workers cannot claim beads due to dependency resolution issues.
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>