Skip to content

TUI Mode

Human includes a full-screen terminal user interface (TUI) for interactive agent sessions. It provides split panes, streaming output, tool approval prompts, and multi-session tabs.

Terminal window
human agent --tui

TUI mode requires the build flag HU_ENABLE_TUI. If TUI support is not compiled in, the command reports that TUI is unavailable.

FeatureDescription
Split panesInput area and output/response area
Streaming outputToken-by-token display as the model responds
Tool executionTool calls shown in a tool log with status
Tool approvalPrompt to allow/deny medium-risk tools (y/n)
Multi-session tabsSwitch between conversations with Ctrl+T
Input historyNavigate previous inputs with arrow keys
Observer bridgeTUI observer records tool events for live status

The TUI is implemented with termbox2 and is guarded by HU_ENABLE_TUI. It also requires HU_GATEWAY_POSIX (POSIX platform). On Windows or when the flag is off, --tui falls back to an error message.

  • Title bar: Provider and model
  • Output area: Agent responses, possibly streaming
  • Tool log: List of tool calls with duration and success/failure
  • Status bar: Approval prompt or last tool status
  • Input area: User message input

When the agent requests a tool that requires approval, the TUI shows a prompt such as:

Allow <tool_name>? [y/n] args: <args>

Type y to allow or n to deny. The agent continues with the result.