TUI Interactive Launch

fastsim_tui is a lazygit-inspired two-panel terminal interface built with Textual. It provides the same functionality as the fastsim CLI with a visual command browser and real-time output.

bash
fastsim_tui

Layout

  • Left panel: Command list grouped by category (Simulation / Config Tools / Recording / Registry). Navigate with arrow keys, press Enter to run.
  • Right panel: Terminal output area + bottom status bar showing real-time command output and simulation state.

Command Groups

GroupCommandsDescription
Simulationlaunch_simulationStart simulation (subprocess mode)
Config Toolsvalidate_configuration, show_config, diff_config, inspect_scene, inspect_task, inspect_extensionConfig validation and inspection
Recordinginspect_recording, plot_trajectoryRecording data analysis
Registryshow_registery, show_stereotype_params, show_static_apiRegistry and API inspection

Execution Flow

  1. Select command: Navigate with Up / Down in the left panel
  2. Press Enter: An input modal pops up for command arguments
  3. Fill arguments: Text inputs for paths, toggle switches for boolean options
  4. Confirm: Press Enter or click Run to execute; Esc to cancel
  5. View output: Real-time output streams to the right panel

Commands requiring confirmation (like launch_simulation) show a confirmation dialog first.

Execution Modes

  • Function call: Runs in-process, output redirected to the right panel. Used for lightweight operations (validate, show config, inspect).
  • Subprocess: Runs as a separate process with stdout streaming. Used by launch_simulation to avoid blocking the TUI.

Only one subprocess can run at a time.

Status Monitor

When launch_simulation runs with --monitor yes (the default), the TUI parses real-time state from the simulation process, displaying simulation step count, dt, and running status in the bottom status bar.

Command Filtering

Press / to enter search mode and filter commands by keyword. Press Esc to clear the filter.

Keyboard Shortcuts

KeyAction
Up / DownNavigate command list
EnterRun selected command
TabSwitch focus between panels
/Filter commands (search mode)
EscClear filter / cancel modal
Ctrl+XKill running subprocess
Ctrl+LClear output panel
Ctrl+SSave output to file
?Show help modal
Ctrl+CExit TUI

Typical Usage

  1. Run fastsim_tui
  2. Select validate_configuration, enter config path, verify results
  3. Select inspect_scene to check entity details
  4. Select launch_simulation, confirm and start
  5. Monitor real-time output and status in the right panel
  6. Press Ctrl+X to stop if needed
  7. After simulation, select inspect_recording to analyze data