-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Labels
Description
Summary
The schema defines 23 diagram types, but only 4 have actual distinct implementations. The remaining 19 types fall back to the flowchart template.
Current State
Implemented with distinct templates (4):
| Type | Implementation |
|---|---|
flowchart |
Default rectangles, straight arrows, TB layout |
architecture |
Wider spacing, elbow connectors |
mindmap |
Radial layout via applyRadialLayout() |
sequence |
Broken - see #68 |
Unimplemented (19) - all fall back to flowchart:
orgchart, class, er, gantt, timeline, tree, network,
dataflow, state, swimlane, concept, fishbone, swot,
pyramid, funnel, venn, matrix, infographic, decision-tree
Fallback logic in packages/backend/lib/templates/index.ts:
return TEMPLATES[diagramType.toLowerCase()] ?? FlowchartTemplate;Scope
Each diagram type needs:
- Template - Node shapes, colors, spacing defaults
- Layout algorithm - Positioning logic (dagre config or custom)
- Grading criteria - Visual evaluation prompts
- Prompts - Generation guidance for the AI
Needs Grooming
This issue needs to be groomed and split into logical phases based on priority. Suggested approach:
Phase 1: High-value, achievable
Types that can be implemented with dagre config tweaks + shape mappings:
decision-tree(already has layout config, needs template)orgchart(hierarchical TB layout)tree(similar to orgchart)state(already has layout config)
Phase 2: Moderate complexity
Types needing custom layout logic:
er(entity-relationship with crow's foot notation)class(UML class diagrams with compartments)swimlane(lane-based horizontal partitioning)dataflow(DFD notation)
Phase 3: Specialized/Complex
Types requiring significant custom rendering:
gantt(timeline bars, dependencies)timeline(chronological axis)network(force-directed or hierarchical)fishbone(Ishikawa cause-effect)
Phase 4: Evaluate necessity
Types that may not be worth implementing or could be consolidated:
concept(may overlap with mindmap)swot(2x2 matrix - simple)pyramid/funnel(stacked shapes)venn(overlapping circles)matrix(grid layout)infographic(too generic?)
Next Steps
- Groom this issue into separate phase issues
- Prioritize based on user demand / analytics
- Consider removing unsupported types from schema to avoid false advertising
Reactions are currently unavailable