- Create src/web/frontend/src/components/WorkerDetail.tsx as dedicated component
- Port TUI WorkerDetail functionality to React web frontend
- Features:
- Worker ID and status with status icon
- Activity statistics (event count, current tool)
- Timing information (last seen)
- Recent events list (last 10 events)
- Collision warning with affected files
- Close button to deselect worker
- Update App.tsx to use new WorkerDetail component
- Add comprehensive CSS styles for new component
Co-Authored-By: Claude Worker <noreply@anthropic.com>
Move ReplaySpeed and ReplayState types to central types file for
consistency and re-export them from the component for external use.
Co-Authored-By: Claude Worker <noreply@anthropic.com>
- Add comprehensive tests for /api/health endpoint
- Add tests for /api/workers and /api/workers/:id endpoints
- Add tests for /api/events with filtering (worker, level, limit)
- Add tests for /api/collisions and /api/workers/:id/collisions
- Add tests for cross-reference API endpoints (/api/xref/*)
- Add tests for WebSocket functionality exposure
- Add tests for server lifecycle and error handling
- All 42 new tests pass (225 total tests)
Co-Authored-By: Claude Worker <noreply@anthropic.com>
- Add comprehensive unit tests for WorkerGrid component
- Mock blessed box and screen elements
- Test constructor, updateWorkers, selection navigation
- Test render output (status icons, collision indicators)
- Test key bindings (up/down/k/j/g/G)
- Cover edge cases (no workers, empty events, long descriptions)
All 29 tests pass. Total test suite: 183 tests passing.
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>
Add recovery playbook feature that suggests recovery actions when workers encounter errors.
Implementation includes:
- RecoverySuggestion, RecoveryAction, RecoveryPlaybookEntry types in types.ts
- recoveryPlaybook.ts utility module with RecoveryManager class
- Predefined playbooks for each error category (network, permission, timeout, etc.)
- Pattern matching to map errors to actionable recovery steps
- Integration with InMemoryEventStore for easy access to suggestions
- RecoveryPanel TUI component for displaying suggestions
- Console formatting utilities for CLI output
Recovery actions include:
- Automated actions (retry, backoff, investigate)
- Manual actions (fix permissions, install dependencies)
- Escalation to human when automated recovery not possible
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>
Implement file heatmap visualization that tracks which files are modified
most frequently and by which workers. Helps identify hotspots and potential
collision areas.
Features:
- Track file modifications across all workers
- Heat levels (cold/warm/hot/critical) based on modification frequency
- Worker contribution percentages per file
- Collision risk detection for files with multiple workers
- Sortable by modifications, recent activity, workers, or collisions
- Filter by directory or collision-only files
- Statistics overview with heat distribution
Integration:
- Press 'H' in TUI to toggle heatmap view
- Press 's' to cycle sort modes
- Press 'c' to toggle collision-only filter
- Press 'Esc' to return to default view
Also fixed pre-existing DependencyDag component build issues:
- Created missing dagUtils.ts utility module
- Fixed import paths and type annotations
Tests: 20 new tests for file heatmap, all 154 tests passing
Co-Authored-By: Claude Worker <noreply@anthropic.com>
- Add SessionReplay component with full playback controls
- Add replay command to CLI with filter support
- Fix color type references in SessionReplay
- Add EventFilter type import to CLI
- Add File Heatmap types for future feature
Co-Authored-By: Claude Worker <noreply@anthropic.com>
Implement smart error grouping to cluster similar errors together and reduce
noise in the activity stream. Uses pattern matching on error messages and
stack traces to group related errors.
Features:
- Error categorization into 9 categories (network, permission, validation, etc.)
- Pattern-based fingerprinting for grouping similar errors
- Normalization of variable data (IPs, paths, UUIDs, timestamps)
- Severity calculation based on frequency and recency
- Integration with InMemoryEventStore for automatic error tracking
New files:
- src/errorGrouping.ts - Error grouping module
- src/errorGrouping.test.ts - Comprehensive test suite (34 tests)
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>
- Add 9 new tests for collision detection:
- Detect collision when multiple workers modify same file
- Handle time window boundaries (5 second window)
- Only flag file modification tools (Edit, Write, NotebookEdit)
- Track hasCollision flag on worker info
- Track active files for workers
- Get collisions for specific worker
- Update web types for collision info
- Add collision visual indicator to TUI WorkerGrid (⚠ warning)
- Add collision visual indicator to Web WorkerGrid (pulsing border)
- Add /api/collisions endpoint to web server
- Include collisions in WebSocket initial state
Co-Authored-By: Claude Worker <noreply@anthropic.com>
Implements working `fabric tail` command with:
- Log tailer module (src/tailer.ts)
- File watching with fs.watch
- Follow mode for real-time updates
- Buffer management for partial lines
- Graceful shutdown handling
- JSON parser module (src/parser.ts)
- Validates NEEDLE log format
- Extracts optional fields (tool, path, bead, duration_ms, error)
- Human-readable event formatting with color support
- In-memory event store (src/store.ts)
- Stores events with worker indexing
- Supports querying with filters
- Auto-updates worker status based on events
- Working CLI (src/cli.ts)
- Filters by worker (-w) and level (-l)
- Supports --json output
- Shows existing lines with -n flag
Resolves HUMAN bead bd-17q (worker starvation) by providing
working implementation and creating beads for remaining phases.
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <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>