- Removed broken LaunchSwarmDialog (formula-based) from TopBar/LeftPanel - All Rocket buttons (TopBar, LeftPanel, DAG nodes, social cards) now open AssignmentPanel (archetype-based) which actually works - Every Rocket clears taskId first so assignMode && !taskId condition passes - Conversation button priority: taskId always shows conversation, not assign panel - Added TelemetryStrip: minimized right sidebar with status dots when non-telemetry panel (conversation/assignment) is active - Live feed has minimize button → restores last taskId or assignMode - DAG nodes: Signal icon → restores telemetry feed - Social button on DAG nodes: single router.push to avoid race (setView + setTaskId) - Fixed social card message button: opens right panel with drawer:closed (no popup) Co-Authored-By: Oz <oz-agent@warp.dev>
5.4 KiB
CLAUDE.md
This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository.
What Is BeadBoard
BeadBoard is a Windows-native local dashboard for the Beads issue tracker. It reads .beads/issues.jsonl files directly from repos and renders them as an agent-first operations console: a unified shell with Social, Graph, and Activity lenses for monitoring multi-agent work, managing swarms, and intervening on blockers. It supports multi-project aggregation, real-time file watching with SSE, and swarm/archetype coordination.
Active UX implementation spec: docs/plans/2026-02-28-ux-redesign-synthesis-prd.md
Commands
npm run dev # Start Next.js dev server (localhost:3000)
npm run build # Production build
npm run typecheck # tsc --noEmit
npm run lint # eslint
npm run test # Runs all tests (explicitly enumerated in package.json)
Run a single test:
node --import tsx --test tests/lib/parser.test.ts
New test files must be added to the test script in package.json — the suite is explicitly enumerated, not auto-discovered.
Verification gates (run before closing any code bead)
npm run typecheck && npm run lint && npm run test
Architecture
Stack: Next.js 15 (App Router) · React 19 · Tailwind CSS · TypeScript (strict) · @xyflow/react (graphs) · Dagre (layout) · Chokidar (file watching) · Remotion (video generation)
Data flow
- Source of truth:
.beads/issues.jsonlfiles on disk, mutated only viabdCLI commands. - Parser (
src/lib/parser.ts): Reads JSONL, normalizes dependencies and fields intoBeadIssueobjects. - Aggregate read (
src/lib/aggregate-read.ts): Merges issues across multiple project roots based on project scope/mode. - Realtime (
src/lib/realtime.ts):IssuesEventBussingleton dispatches change events. SSE endpoint (src/app/api/events/route.ts) streams them to the browser. - Watcher (
src/lib/watcher.ts): Chokidar-basedIssuesWatchManagerwatches JSONL + WAL +.last_touchedfiles, coalesces events viaProjectEventCoalescer, and emits through the event bus. Snapshot diffing detects per-issue changes. - Writeback (
src/lib/writeback.ts): API mutations write back to JSONL throughbd-compatible paths.
Key directories
src/app/— Next.js App Router pages and API routes/— Primary entry point.UnifiedShellwith query-param-driven views:?view=social|graph|activity/graph,/sessions,/timeline— Legacy routes. Still exist but are not linked from the unified shell. Do not add new features here; migrate functionality into the unified shell instead./api/beads/— CRUD endpoints for beads (create, read, update, close, reopen, comment)/api/events/— SSE endpoint for real-time updates/api/swarm/— Swarm coordination endpoints (create, launch, join, leave, status, templates)/api/mission/— Mission/epic management endpoints/api/agents/— Agent registry endpoints
src/components/— UI components organized by feature (kanban, graph, sessions, swarm, shared, activity, etc.)shared/unified-shell.tsx— Root layout. Top bar, left panel, middle content (view-switched), right panel, thread drawershared/left-panel.tsx— Navigation spine: view switcher (Social/Graph/Activity), epic tree, filtersshared/top-bar.tsx— Global header: identity, health, blocked triage, metric tilesactivity/contextual-right-panel.tsx— Right panel content router (branches on URL context)activity/activity-panel.tsx— Activity/telemetry feed (also used as theactivityview content)graph/smart-dag.tsx— DAG renderer using @xyflow/react + Dagresocial/social-page.tsx— Social lens: grouped task cards with dependency/thread context
src/lib/— Core logic (parser, types, pathing, watcher, realtime, registry, scanner, mutations, graph layout)types.ts— Central type definitions (BeadIssue,BeadStatus,ProjectContext, etc.)pathing.ts— Windows path canonicalization (drive letter normalization, path keys)bd-path.ts— Resolves thebdCLI binary path
src/hooks/— React hooks for subscriptions (use-beads-subscription,use-swarm-list,use-url-state, etc.)components/ui/— shadcn/ui primitivestests/— Node.js native test runner with tsx loader; mirrors src structurescripts/— CLI utilities (bb.ts— BeadBoard CLI, Playwright capture scripts)docs/— RFCs, ADRs, protocols, and feature specs
Path alias
@/* maps to the project root (configured in tsconfig.json).
Windows considerations
- All path handling must canonicalize Windows paths (drive letter casing, backslash normalization). Use
canonicalizeWindowsPathandwindowsPathKeyfromsrc/lib/pathing.ts. - Webpack filesystem cache is disabled in dev mode (
next.config.ts) to avoid Windows ENOENT errors.
ESLint config
@typescript-eslint/no-explicit-any and prefer-const are intentionally turned off. eslint.config.mjs uses flat config with next/core-web-vitals and next/typescript.
Beads workflow
Use bd as the sole interface for mutating beads. Never write to .beads/issues.jsonl directly. See AGENTS.md for the full operating manual including dependency discipline, parallel agent patterns, and session completion protocol.