Skip to content

Auto-generated model diagrams from spec #49

@jc-macdonald

Description

@jc-macdonald

Summary

Generate compartmental flow diagrams automatically from a parsed op_system specification.

Problem

Users currently have no way to visualize the model structure defined by their YAML spec. For presentations, documentation, and debugging, a visual representation of states and transitions is essential. Model diagrams are currently hand-drawn or produced with external tools.

Scope

  • Accept a NormalizedRhs (or raw spec dict) and produce a directed graph of states and transitions
  • Support at least one output format (e.g., Graphviz DOT, Mermaid markdown, or matplotlib figure)
  • Label edges with rate expressions
  • Optionally collapse axis-expanded states back to template form for readability
  • Handle chain-generated stages (show the chain as a grouped subgraph or linear chain)
  • Consider a CLI entry point or utility function: op_system diagram spec.yaml -o model.png

Non-Goals (for now)

  • Interactive/web-based visualization
  • Real-time state trajectory animation

Related

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions