-
Notifications
You must be signed in to change notification settings - Fork 5
Description
[P2] Feature: Entity Diagram Progress Tracker Tab
Summary
Add a new "Entity Diagram" tab to the project dashboard that visualizes build progress at the entity level rather than the traditional file/directory level. This shifts the progress metaphor from "files and line changes" to "domain entities and their relationships"—aligning with CodeFRAME's entity-centric, agentic approach.
Problem Statement
Traditional IDEs track progress through:
- Individual files and directory structures
- Lines of code added/deleted
- Git diffs and file-based commits
This file-centric view doesn't map well to how autonomous agents think about work. CodeFRAME agents operate on entities (User, Task, Project, Agent, etc.) and their relationships. There's currently no visual representation of:
- Which entities exist in the system
- What development phase each entity is in (TDD red/green/refactor)
- How entities connect to each other (APIs, dependencies)
- Deployment status per entity or entity group
Proposed Solution
New Dashboard Tab: "Entity Diagram"
A visual diagram that:
- Gets generated after discovery/specification documents (PRD, technical specs) are created
- Displays entities as nodes with their names and relationships
- Color-codes TDD status using a traffic-light progression
- Shows deployment environment status
Entity Color States
| Color | Phase | Meaning |
|---|---|---|
| Gray | Initial | Entity defined in specs, no implementation yet |
| Red | TDD Red | Tests exist but are failing |
| Green | TDD Green | Tests are passing (minimum viable implementation) |
| Purple | TDD Refactor | Code refactored and optimized |
| Blue | Deployed | Merged to main and deployed |
Relationship Connectors (Arrows)
Arrows between entities represent:
- API relationships (one entity calls another)
- Data dependencies (foreign keys, references)
- Event flows (pub/sub, webhooks)
- Import/inheritance relationships
Arrow styles could differentiate relationship types (solid for API, dashed for events, etc.)
Deployment Status Indicator
A diagram-level badge or legend showing current deployment environment:
- Local/Dev - Running on developer machine
- Test - Deployed to test environment
- Staging - Deployed to staging environment
- Production - Live in production
Optionally, individual entities could show their deployment status if they deploy independently (microservices pattern).
User Experience
- User submits PRD to CodeFRAME
- Discovery agent generates specs including entity definitions
- Entity Diagram auto-populates with gray nodes and connectors
- As agents work on each entity:
- Node turns red when test files are created (failing tests)
- Node turns green when tests pass
- Node turns purple when refactoring is complete
- Node turns blue when deployed
- User sees the application "light up" progressively as agents complete work
Technical Considerations
Data Model
May require new fields or a new table to track:
entity_name: String identifierentity_status: Enum (gray, red, green, purple, blue)deployment_env: Enum (dev, test, staging, production)relationships: Array of connected entity IDs with relationship type
Diagram Rendering
Options to evaluate:
- React Flow - Interactive node-based diagrams (already popular in AI/agent UIs)
- Mermaid.js - Markdown-based diagrams (simpler, less interactive)
- D3.js - Maximum flexibility but more implementation effort
- Cytoscape.js - Graph visualization library
Recommend React Flow given the existing React/TypeScript frontend and need for real-time updates via WebSocket.
Integration Points
- Discovery Agent: Generates initial entity list and relationships from PRD/specs
- Test Worker: Updates status to red (tests created) → green (tests passing)
- Review Worker: Updates status to purple (refactor phase complete)
- Deployment/Git Integration: Updates status to blue (merged/deployed)
- WebSocket: Real-time status updates to dashboard
Acceptance Criteria
- New "Entity Diagram" tab appears in project dashboard after specs are generated
- Entities display as labeled nodes with correct initial (gray) coloring
- Relationship arrows render between connected entities
- Entity color updates in real-time as TDD phases complete
- Deployment environment indicator is visible and accurate
- Clicking an entity shows detail panel (tests, files, status history)
- Diagram is responsive and handles 20+ entities gracefully
Out of Scope (Future Enhancements)
- Entity grouping/clustering by domain or module
- Historical timeline view ("watch the build happen" replay)
- Drag-and-drop entity rearrangement
- Export diagram as image/PDF
- Entity-level deployment (for microservices)
Related
- Existing dashboard components:
web-ui/src/components/ - WebSocket implementation: Real-time updates already exist for agents/blockers
- Quality Gates: Could trigger purple status transition
- Checkpoint/Recovery: Diagram state should be included in checkpoints
Labels
enhancement, P2-medium-beta, dashboard, ux