Skip to main content

Overview

The Model Playground is Veydra’s central workspace where you build, modify, and test your system dynamics models. It provides an interactive environment with real-time feedback and powerful visualization tools.

Playground Modes

The Model Playground is organized around a mode-based workflow that guides you through the full modeling lifecycle. Each mode focuses on a specific phase and adapts the UI — showing relevant panels, controls, and AI assistant context. Switch modes using the color-coded buttons in the top navigation bar.

Presentation

Interactive guided walkthrough of the model with slides, quizzes, and embedded content

Design

Build and structure your model — edit parameters, code, and stock-flow diagrams

Calibrate

Fine-tune parameters to match real-world data (Pro)

Experiment

Run what-if scenarios and explore different futures

Decide

Compare multiple scenarios side-by-side for decision analysis (Pro)

Presentation Mode

A read-only guided experience for learning about a model. Content is displayed as scrollable slides with a sticky table of contents sidebar. Slides can include rich text, embedded videos, quizzes, and buttons that navigate to other modes.
  • No editable controls — Model Controls, System Map, and Code Editor are hidden
  • AI Assistant adapts with presentation-specific prompts like “Take a Quick Quiz” and “Summarize this model”
  • Ideal for onboarding, classroom use, or sharing insights with stakeholders

Design Mode

The primary building mode where all structural changes happen. Parameter changes in Design mode update the baseline configuration that applies across all scenarios.
  • Model Editor Panel — Full access to all sliders (stocks, flows, parameters, simulation settings)
  • Stock-Flow Diagram — Fully expanded with Flow, Causal, Params, and Loops tabs
  • Code Editor — Direct Python code editing with Pyodide execution panel
  • Charts are hidden so you can focus on model structure
Changes made in Design mode affect the baseline for ALL scenarios. Use Experiment mode for what-if analysis.

Calibrate Mode (Pro)

Fine-tune your model to match historical or real-world data. Calibration changes update both baseline and scenario values simultaneously.
  • Calibration Panel — Specialized parameter controls for data fitting
  • Charts visible — See how parameter adjustments affect model output in real time
  • System Map — Minimized by default but expandable
  • Supports parameter estimation, historical fit, and validation workflows
Calibrate mode requires a Pro subscription. Free users are redirected to Experiment mode.

Experiment Mode

Run what-if scenarios using your calibrated baseline. Slider changes only affect the current scenario’s post-intervention behavior — the baseline stays fixed for comparison.
  • Model Controls — Shows parameter sliders (not simulation settings) with save/load scenario support
  • Compare Mode — Enabled by default, showing baseline vs. scenario on charts
  • Scenario Selector — Save, load, rename, and delete named scenarios
  • Specialized visualizations — Gantt charts, wait-time scatter plots, spatial visualizations (for applicable models)

Decide Mode (Pro)

Compare multiple saved scenarios side-by-side to make strategic decisions. Automatically selects the baseline plus up to two user scenarios for comparison.
  • Multi-Scenario Selector — Choose which scenarios to overlay on charts
  • Multi-Stock Chart Area — All stocks shown with scenario overlays
  • Analysis Card — Aggregated comparison metrics across scenarios
  • System Map is fully hidden to maximize chart space

Mode Availability

Not all modes appear for every model. The available modes are determined by the model’s metadata:
ModeDefaultNotes
DesignAlways availableCore building mode
CalibrateAlways availablePro-gated
ExperimentAlways availablePrimary analysis mode
PresentationOpt-in per modelRequires slide content
DecideOpt-in per modelPro-gated

AI Assistant Per Mode

The AI Assistant panel automatically adapts to the current mode with a matching color theme, contextual welcome message, and mode-specific action buttons. For example, Design mode offers “Start a guided tutorial” while Decide mode offers “Strategy Comparison” and “Risk Analysis”.

Key Components

The Model Playground consists of several integrated panels that work together:

Model Controls

Parameter adjustment and simulation controls

Stock-Flow Diagram

Visual representation of your model structure

Chart Area

Real-time simulation results and comparisons

Code Editor

Direct Python code editing and customization

Model Controls Panel

Parameter Management

The Model Controls panel is your command center for model interaction:
  • Active Parameters: Parameters available for real-time adjustment
  • Parameter Sliders: Interactive controls for each parameter
  • Reset Functions: Quickly return to default values
  • Scenario Management: Save and load different parameter sets

Control Features

Mark parameters as “Active” to enable real-time slider controls during simulation
Use the refresh button to reset all parameters to defaults while keeping them active for quick experimentation
Enable “Compare Mode” to see baseline vs current scenario side-by-side

Stock-Flow Diagram Area

Visual Model Building

The diagram area provides an interactive view of your model’s structure:
  • Stock Elements: Rectangular boxes representing accumulations
  • Flow Elements: Arrows showing rates of change
  • Connectors: Links showing influence relationships
  • Parameters: Variable elements that can be adjusted

Interactive Features

  • Drag and Drop: Reposition elements for better layout
  • Real-time Updates: See value changes during simulation
  • Zoom and Pan: Navigate large, complex models
  • Element Properties: Click to edit element details
The diagram automatically updates to reflect changes made in the code editor

Chart Area

Visualization Options

Single Stock View

Focus on individual model components

Multi-Stock View

Display all stocks simultaneously

Comparison Mode

Baseline vs scenario analysis

Data Export

Export simulation results

Chart Features

  • Interactive Legends: Show/hide data series
  • Zoom and Pan: Explore different time ranges
  • Tooltips: Detailed value information on hover
  • Time Units: Automatic scaling (days, weeks, months, years)

Code Editor

Python-Based Models

Veydra uses Python for model execution, giving you full flexibility:
# Example model structure
def model_function(parameters):
    # Define stocks and flows
    population = parameters['initial_population']
    growth_rate = parameters['growth_rate']
    
    # Calculate changes
    new_population = population * (1 + growth_rate)
    
    return {
        'population': new_population,
        'growth': new_population - population
    }

Editor Features

  • Syntax Highlighting: Python code formatting
  • Auto-completion: Intelligent code suggestions
  • Error Detection: Real-time syntax checking
  • Version Control: Git integration for change tracking

Simulation Engine

Real-Time Execution

The simulation engine processes your models using:
  • Pyodide Integration: Python execution in the browser
  • WebAssembly: High-performance computation
  • Incremental Updates: Fast parameter changes
  • Memory Management: Efficient data handling

Performance Features

  • Caching: Smart caching of model files and configurations
  • Parallel Processing: Multiple scenario execution
  • Optimization: Automatic performance tuning
  • Error Handling: Graceful failure recovery

Workflow Example

1

Model Setup

  1. Load or create a new model
  2. Review the stock-flow diagram
  3. Identify key parameters to activate
2

Parameter Configuration

  1. Mark important parameters as “Active”
  2. Set initial values using sliders
  3. Configure simulation time range
3

Simulation

  1. Run initial baseline simulation
  2. Adjust parameters in real-time
  3. Compare different scenarios
4

Analysis

  1. Review chart results
  2. Export data for further analysis
  3. Save interesting scenarios

Advanced Features

Git Integration

  • Version Control: Track all model changes
  • Branching: Experiment with different approaches
  • Merging: Collaborate on model development
  • History: Review past versions and changes

Collaboration Tools

  • Real-time Sharing: Multiple users in same playground
  • Comments: Annotate models and results
  • Permissions: Control who can edit vs view
  • Change Notifications: Track team member activities
Use the Model Playground’s reset functionality to quickly experiment with different parameter combinations while maintaining your baseline for comparison

Next Steps

Simulation Features

Learn about advanced simulation capabilities

Model Controls Guide

Detailed guide to parameter management