diff --git a/Commands.md b/Commands.md new file mode 100644 index 0000000..f1c2f07 --- /dev/null +++ b/Commands.md @@ -0,0 +1,49 @@ +# Commands and menus + +What each slash command of the TUI shows, and what it says where there is no screen for a menu +(`lembas run "/name"`, a prompt sent over the link, which the web UI shows as a reply). + +## One menu + +Every picker is the one component, `src/tui/components/dialog.tsx`, so they look and answer to +keys alike: + +- a title, and optionally a few lines about what the menu is for; +- **type to filter** (shown when a list is long, or always where finding is the point); +- rows under **section headings**, a **mark** for a row's state (`●` on, `○` off or asks, `…` + busy, `⚠` needs attention, `✗` failed or denied — `src/tui/notices.ts`); +- a line or three **about the highlighted row** under the list (a tool's whole description); +- **↑↓** move, **PgUp/PgDn** a screen, **Home/End**, **Enter** chooses, **Esc** closes — or goes + **back** in a menu opened from another, and the footer says which; +- the footer names the keys, and where the cursor is in a list longer than the window (`7/200`); +- an empty list says what to do about it; nothing is wider than the terminal (60 columns work). + +A menu's rows never carry letter shortcuts when it filters: what can be done to a row is a row +of the menu Enter opens. + +## Lines the program says + +`·` something happened · `✓` done · `⚠` needs attention · `✗` failed (`src/tui/notices.ts`, +used by the transcript and by `lembas run`). A warning sign always means there is something to +look at. An MCP server that connects says nothing; the status bar counts them (`MCP 2`, +`MCP 1/2`). + +## The commands + +| Command | Shows | Without a menu | +|---|---|---| +| `/help` | **menu**: every command under a heading, found by typing; Enter runs it or puts it in the box; the keys | — | +| `/status` | **menu**: server and login, model, session, project and trust, MCP servers, the terminal (copying, pasting images); Enter opens what changes a row | a list | +| `/mcp [server]` | **menu**: servers by where they come from, with state; a server's actions, tools (searchable, with each one's permission rule, changeable), prompts, last error | a list; `/mcp ` its tools | +| `/permissions` | **menu**: the rules in force by where they were made; change, add, remove | a list | +| `/agents` | **menu** of the subagents; `/agents ` describes one, ` ` hands it a task, `new ` writes a starter | a list | +| `/model`, `/effort`, `/mode`, `/theme`, `/icons`, `/personality` | **menu** of the choices, the current one marked | — | +| `/settings [key [value [scope]]]` | **menu** of every setting with its value and where it is set; then the values; then the scope | — | +| `/sessions` (`/resume`), `/search `, `/plans`, `/checkpoints`, `/branch`, `/skills`, `/memory`, `/jobs`, `/schedule` | **menu** of the things; Enter opens or uses one, a named key deletes or stops where the footer says so | — | +| `/team` | **menu** for the size; the tree and the room as text | text | +| `/login`, `/logout`, `/release`, `/commit` | a **menu** where there is a choice to make, else lines | — | +| `/context`, `/usage`, `/voice`, `/terminal`, `/kb`, `/tasks`, `/decisions`, `/prototype`, `/diff` | a short report as text (a diff as a diff) | — | +| `/new`, `/delete`, `/rename`, `/copy`, `/undo`, `/redo`, `/compact`, `/continue`, `/plan`, `/review`, `/init`, `/changelog`, `/decide`, `/checkpoint`, `/skill`, `/speak`, `/remote`, `/trust`, `/reload`, `/quit` | do the thing and say so in a line | `/compact`, `/undo`, `/plan`, `/review`, `/init`, `/changelog`, `/continue` work over the link | + +A custom command (`.agent/commands`, `~/.config/lembas/commands`) or a skill named like one of +these is not a command: the built-in wins, and the skill is reached as `/skill `. diff --git a/Home.md b/Home.md index 86f19d3..2605ae7 100644 --- a/Home.md +++ b/Home.md @@ -33,6 +33,7 @@ website: | [Working notes](Working-notes) | **Read first.** The rules the project is built on and why, building, testing and releasing, and the lessons from bugs that shipped looking correct — kept as rules. | | [Architecture](Architecture) | The layout of `src/`: the app wiring, the engine loop, providers, tools, permissions, the session store, the TUI, the ACP agent, hub, share and link, updates and signing, the service. | | [Harness parity](Harness-parity) | The harness design shared with LLeMbas: every concept mapped to its file in both projects, and where they still differ. | +| [Commands and menus](Commands) | What every slash command shows — which are menus, on the one menu component, and what each says where there is no menu; the marks a line or a row carries. | | [Configuration](Configuration) | For developers: how configuration is loaded, layered, trusted and validated, and what to touch when adding a key. | ## Where it comes from