perspt-tui¶
Ratatui-based terminal user interface with two application modes.
Applications¶
Type |
Description |
|---|---|
|
Interactive chat with markdown rendering and response streaming |
|
Agent dashboard with DAG tree, energy display, and review modal |
Widgets and Rendering Modules¶
Module |
Description |
|---|---|
|
|
|
DAG visualization showing node states and energy |
|
|
|
|
|
Minimal input widget with full control over key handling |
|
Markdown, table, and LaTeX-math rendering for the chat TUI |
|
LaTeX to Unicode transpilation for terminal math rendering |
|
Message-area and input-box rendering for the chat TUI |
|
Chat-local slash commands and conversation export |
|
|
Entry Points¶
pub fn run_chat_tui(...) -> Result<()>;
pub fn run_agent_tui_with_runtime(...) -> Result<()>;
Terminal setup and teardown live in tui_runner:
pub fn init_terminal(config: &TuiRunnerConfig) -> io::Result<TuiTerminal>;
pub fn restore_terminal(config: &TuiRunnerConfig) -> io::Result<()>;
Channels¶
pub fn create_app_event_channel() -> (AppEventSender, AppEventReceiver);
pub fn create_telemetry_channel() -> (TelemetrySender, TelemetryReceiver);