Skip to main content

Introduction

Flower Engine TUI includes a powerful command system that allows you to control and configure your storytelling sessions in real-time. All commands are entered directly into the chat interface and begin with a forward slash (/).

Command Categories

Commands are organized into the following categories:

Model Management

Hot-swap AI models without restarting

World Management

Select worlds and attach lore

Character Management

Switch between characters

Session Management

Create, continue, and delete sessions

Rules Management

Activate and manage content rules

Command Structure

Commands follow a consistent structure:
/command [subcommand] [arguments]
  • command: The primary action (e.g., /model, /world, /session)
  • subcommand: Optional secondary action (e.g., select, add, new)
  • arguments: Required parameters for the command

How Commands Work

When you enter a command:
  1. The engine parses the command string by splitting on spaces
  2. Validates that the command exists and has required parameters
  3. Executes the command and updates engine state
  4. Sends a system_update event back to the client with results
  5. Broadcasts state changes to all connected clients
Commands are processed server-side via WebSocket and provide immediate feedback through system messages.

Command Validation

The engine validates:
  • Command existence: Unknown commands are ignored
  • Parameter count: Commands require specific numbers of arguments
  • Resource existence: IDs and file references are checked before execution
  • Prerequisites: Some commands require prior setup (e.g., world/character selection before creating sessions)

State Persistence

Most commands automatically save state changes to disk, ensuring your configuration persists across engine restarts:
  • Active model selection
  • Current world and character
  • Active rules
  • Session information

Error Handling

When a command fails, you’ll receive a system message explaining the issue:
✗ Error message explaining what went wrong
Successful commands respond with:
✓ Success message confirming the action

Next Steps

Explore the specific command documentation:

Build docs developers (and LLMs) love