From 9092b7d8c375597755db4e13461f07c1b91868ae Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Arnaud=20H=C3=A9ritier?= Date: Tue, 9 Jun 2026 04:02:54 +0000 Subject: [PATCH] docs: document --session-read-only flag for TUI read-only mode Add --session-read-only to the CLI reference flags table and add usage examples in both the CLI reference and TUI feature docs. Closes #3026 --- docs/features/cli/index.md | 2 ++ docs/features/tui/index.md | 3 +++ 2 files changed, 5 insertions(+) diff --git a/docs/features/cli/index.md b/docs/features/cli/index.md index 38833405a..6789cc915 100644 --- a/docs/features/cli/index.md +++ b/docs/features/cli/index.md @@ -32,6 +32,7 @@ $ docker agent run [config] [message...] [flags] | `--model ` | Override model(s). Use `provider/model` for all agents, or `agent=provider/model` for specific agents. Comma-separate multiple overrides. | | `--session ` | Resume a previous session. Supports relative refs (`-1` = last, `-2` = second to last) | | `-s, --session-db ` | Path to the SQLite session database (default: `~/.cagent/session.db`) | +| `--session-read-only` | Open the TUI in read-only mode: conversation history is displayed but no new messages can be sent to the LLM. Cannot be used with `--exec`. | | `--prompt-file ` | Include file contents as additional system context (repeatable) | | `--attach ` | Attach an image file to the initial message | | `--dry-run` | Initialize the agent without executing anything (useful for validating a config) | @@ -75,6 +76,7 @@ $ docker agent run agent.yaml -a developer --yolo $ docker agent run agent.yaml --model anthropic/claude-sonnet-4-5 $ docker agent run agent.yaml --model "dev=openai/gpt-4o,reviewer=anthropic/claude-sonnet-4-5" $ docker agent run agent.yaml --session -1 # resume last session +$ docker agent run agent.yaml --session -1 --session-read-only # review last session without sending messages $ docker agent run agent.yaml --prompt-file ./context.md # include file as context # Add hooks from the command line diff --git a/docs/features/tui/index.md b/docs/features/tui/index.md index 9def27d68..1bbb6f027 100644 --- a/docs/features/tui/index.md +++ b/docs/features/tui/index.md @@ -38,6 +38,9 @@ $ docker agent run agent.yaml --sidebar=false # Disable specific slash commands $ docker agent run agent.yaml --disable-commands="/cost,/eval,/model" + +# Open in read-only mode to review a past session without sending new messages +$ docker agent run agent.yaml --session -1 --session-read-only ``` ## Slash Commands