docs: add resume history display to sessions, CLI, config, and AGENTS docs

- sessions.md: New 'Conversation Recap on Resume' subsection with visual
  example, feature bullet points, and config snippet
- cli.md: New 'Session Resume Display' subsection with cross-reference
- configuration.md: Add resume_display to display settings YAML block
- AGENTS.md: Add _preload_resumed_session() and _display_resumed_history()
  to key components, add UX note about resume panel
This commit is contained in:
teknium1
2026-03-08 17:55:14 -07:00
parent 3aded1d4e5
commit cf63b2471f
4 changed files with 37 additions and 0 deletions

View File

@@ -185,6 +185,8 @@ Key components:
- `agent/skill_commands.py` - Scans skills and builds invocation messages (shared with gateway) - `agent/skill_commands.py` - Scans skills and builds invocation messages (shared with gateway)
- `load_cli_config()` - Loads config, sets environment variables for terminal - `load_cli_config()` - Loads config, sets environment variables for terminal
- `build_welcome_banner()` - Displays ASCII art logo, tools, and skills summary - `build_welcome_banner()` - Displays ASCII art logo, tools, and skills summary
- `_preload_resumed_session()` - Loads session history early (before banner) for immediate display on resume
- `_display_resumed_history()` - Renders a compact conversation recap in a Rich Panel on session resume
CLI UX notes: CLI UX notes:
- Thinking spinner (during LLM API call) shows animated kawaii face + verb (`(⌐■_■) deliberating...`) - Thinking spinner (during LLM API call) shows animated kawaii face + verb (`(⌐■_■) deliberating...`)
@@ -194,6 +196,7 @@ CLI UX notes:
- The prompt shows `⚕ ` when the agent is working, `` when idle - The prompt shows `⚕ ` when the agent is working, `` when idle
- Pasting 5+ lines auto-saves to `~/.hermes/pastes/` and collapses to a reference - Pasting 5+ lines auto-saves to `~/.hermes/pastes/` and collapses to a reference
- Multi-line input via Alt+Enter or Ctrl+J - Multi-line input via Alt+Enter or Ctrl+J
- When resuming a session (`--continue`/`--resume`), a "Previous Conversation" panel shows previous messages before the input prompt (configurable via `display.resume_display`)
- `/commands` - Process user commands like `/help`, `/clear`, `/personality`, etc. - `/commands` - Process user commands like `/help`, `/clear`, `/personality`, etc.
- `/skill-name` - Invoke installed skills directly (e.g., `/axolotl`, `/gif-search`) - `/skill-name` - Invoke installed skills directly (e.g., `/axolotl`, `/gif-search`)

View File

@@ -65,6 +65,10 @@ hermes -w -q "Fix issue #123" # Single query in worktree
The welcome banner shows your model, terminal backend, working directory, available tools, and installed skills at a glance. The welcome banner shows your model, terminal backend, working directory, available tools, and installed skills at a glance.
### Session Resume Display
When resuming a previous session (`hermes -c` or `hermes --resume <id>`), a "Previous Conversation" panel appears between the banner and the input prompt, showing a compact recap of the conversation history. See [Sessions — Conversation Recap on Resume](sessions.md#conversation-recap-on-resume) for details and configuration.
## Keybindings ## Keybindings
| Key | Action | | Key | Action |

View File

@@ -468,6 +468,7 @@ display:
tool_progress: all # off | new | all | verbose tool_progress: all # off | new | all | verbose
personality: "kawaii" # Default personality for the CLI personality: "kawaii" # Default personality for the CLI
compact: false # Compact output mode (less whitespace) compact: false # Compact output mode (less whitespace)
resume_display: full # full (show previous messages on resume) | minimal (one-liner only)
``` ```
| Mode | What you see | | Mode | What you see |

View File

@@ -84,6 +84,35 @@ hermes chat --resume 20250305_091523_a1b2c3d4
Session IDs are shown when you exit a CLI session, and can be found with `hermes sessions list`. Session IDs are shown when you exit a CLI session, and can be found with `hermes sessions list`.
### Conversation Recap on Resume
When you resume a session, Hermes displays a compact recap of the previous conversation in a styled panel before the input prompt:
```text
╭─────────────────────────── Previous Conversation ────────────────────────────╮
│ ● You: What is Python? │
│ ◆ Hermes: Python is a high-level programming language. │
│ ● You: How do I install it? │
│ ◆ Hermes: [3 tool calls: web_search, web_extract, terminal] │
│ ◆ Hermes: You can download Python from python.org... │
╰──────────────────────────────────────────────────────────────────────────────╯
```
The recap:
- Shows **user messages** (gold `●`) and **assistant responses** (green `◆`)
- **Truncates** long messages (300 chars for user, 200 chars / 3 lines for assistant)
- **Collapses tool calls** to a count with tool names (e.g., `[3 tool calls: terminal, web_search]`)
- **Hides** system messages, tool results, and internal reasoning
- **Caps** at the last 10 exchanges with a "... N earlier messages ..." indicator
- Uses **dim styling** to distinguish from the active conversation
To disable the recap and keep the minimal one-liner behavior, set in `~/.hermes/config.yaml`:
```yaml
display:
resume_display: minimal # default: full
```
:::tip :::tip
Session IDs follow the format `YYYYMMDD_HHMMSS_<8-char-hex>`, e.g. `20250305_091523_a1b2c3d4`. You can resume by ID or by title — both work with `-c` and `-r`. Session IDs follow the format `YYYYMMDD_HHMMSS_<8-char-hex>`, e.g. `20250305_091523_a1b2c3d4`. You can resume by ID or by title — both work with `-c` and `-r`.
::: :::