Skip to content

Commit 97dbbae

Browse files
Kasper Jungeclaude
authored andcommitted
docs: document dashboard keyboard shortcuts and history API endpoint so users discover Cmd+S saving and can query run history programmatically
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
1 parent d3010a6 commit 97dbbae

3 files changed

Lines changed: 69 additions & 0 deletions

File tree

docs/changelog.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,8 @@ All notable changes to ralphify are documented here.
2424
- **Contributor docs** — new `docs/contributing/` section with a codebase map, replacing the old `agent_docs/` directory.
2525
- **Iterations API endpoint**`GET /api/runs/{run_id}/iterations` returns persisted iteration data with per-check results, enabling History tab drill-downs and custom reporting.
2626
- **Persistent run history** — the dashboard stores run history, iterations, and check results in a SQLite database at `~/.ralph/ui.db` that survives across restarts.
27+
- **Keyboard shortcuts in dashboard** — press Cmd+S / Ctrl+S to save changes in primitive editors and create forms. Escape closes the New Run modal.
28+
- **History runs API endpoint**`GET /api/history/runs` returns all persisted runs from the SQLite store, enabling custom history queries and reporting.
2729

2830
### Fixed
2931

docs/dashboard.md

Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -255,6 +255,18 @@ open it and the overlay to close it. Controls and spacing tighten further below
255255
<figcaption>On phones, the sidebar collapses and the layout stacks vertically.</figcaption>
256256
</figure>
257257

258+
## Keyboard shortcuts
259+
260+
The dashboard supports keyboard shortcuts for common actions:
261+
262+
| Shortcut | Where | Action |
263+
|---|---|---|
264+
| <kbd>Cmd+S</kbd> / <kbd>Ctrl+S</kbd> | Primitive editor | Save changes to the current primitive |
265+
| <kbd>Cmd+S</kbd> / <kbd>Ctrl+S</kbd> | Create primitive form | Create the new primitive |
266+
| <kbd>Escape</kbd> | New Run modal | Close the modal |
267+
268+
The save shortcut works in both the edit and create views of the Configure tab — press <kbd>Cmd+S</kbd> (Mac) or <kbd>Ctrl+S</kbd> (Windows/Linux) instead of clicking the Save or Create button.
269+
258270
## REST API
259271

260272
The dashboard exposes a REST API you can use to script runs, manage primitives,
@@ -424,6 +436,49 @@ Each iteration includes:
424436
| `duration` | string\|null | Formatted duration (e.g. `"52.3s"`) |
425437
| `checks` | array\|null | Per-check results, or `null` if no checks ran |
426438

439+
#### List past runs (history)
440+
441+
Retrieve all persisted runs from the SQLite store — these survive dashboard
442+
restarts. This is what powers the History tab.
443+
444+
```bash
445+
curl http://127.0.0.1:8765/api/history/runs
446+
```
447+
448+
```json
449+
[
450+
{
451+
"run_id": "a1b2c3d4",
452+
"status": "completed",
453+
"command": "claude",
454+
"prompt_file": "PROMPT.md",
455+
"started_at": "2026-03-11T14:23:01",
456+
"stopped_at": "2026-03-11T14:35:12",
457+
"iterations": 5,
458+
"completed": 4,
459+
"failed": 1,
460+
"timed_out": 0
461+
}
462+
]
463+
```
464+
465+
Each run includes:
466+
467+
| Field | Type | Description |
468+
|--------------|--------------|------------------------------------------------|
469+
| `run_id` | string | Unique run identifier |
470+
| `status` | string | `"running"`, `"completed"`, `"stopped"`, etc. |
471+
| `command` | string | Agent command used |
472+
| `prompt_file`| string | Path to the prompt file |
473+
| `started_at` | string\|null | ISO 8601 start timestamp |
474+
| `stopped_at` | string\|null | ISO 8601 stop timestamp |
475+
| `iterations` | int | Total iterations executed |
476+
| `completed` | int | Iterations that succeeded |
477+
| `failed` | int | Iterations that failed |
478+
| `timed_out` | int | Iterations that timed out |
479+
480+
Runs are returned newest-first. Combine with the [iterations endpoint](#get-iterations-for-a-run) to drill into a specific run's details.
481+
427482
### Primitives
428483

429484
Primitive endpoints use a base64-encoded `project_dir` in the URL path. Encode

docs/quick-reference.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -227,6 +227,18 @@ Frontmatter `command` values are split with `shlex` and run **directly** (no she
227227

228228
---
229229

230+
## Dashboard keyboard shortcuts
231+
232+
| Shortcut | Where | Action |
233+
|---|---|---|
234+
| <kbd>Cmd+S</kbd> / <kbd>Ctrl+S</kbd> | Primitive editor | Save changes |
235+
| <kbd>Cmd+S</kbd> / <kbd>Ctrl+S</kbd> | Create primitive form | Create the primitive |
236+
| <kbd>Escape</kbd> | New Run modal | Close the modal |
237+
238+
See [Web Dashboard](dashboard.md#keyboard-shortcuts) for details.
239+
240+
---
241+
230242
## Prompt assembly order
231243

232244
Each iteration assembles the prompt in this order:

0 commit comments

Comments
 (0)