#6363·opensre

[FEATURE] Unify slash-command submenu UX

Author: muddlebeeCreated Sep 22, 2026Updated Sep 23, 2026
Labelsenhancementpending triagecliux

Problem statement

The slash-command tray is being refreshed in #6359, but the submenus opened by commands such as /model still look and behave like a different interface.

The current /model screen illustrates the problem:

[1] /model
  Select Model and Effort
  /model

    1. show
    2. set
    3. restore
    4. toolcall
  ❯ 5. done

  ↑↓ Navigate • Enter/1-9 Select • Esc cancel
  • /model appears twice.
  • show, set, and toolcall expose command syntax rather than explaining the action.
  • The title promises model and effort selection, but this menu does not contain an effort selector.
  • Selection, borders, and spacing do not match the new slash tray.
  • Most existing menus use the same picker, but labels, current-state indicators, and back navigation differ.
  • Long choice lists are not presented as a bounded scrolling viewport.

Goal: one menu system, three menu types—action menus, setting pickers, and resource pickers. Share the visual language, not identical behavior for every kind of interaction.

Proposed solution

1. Which commands should follow the pattern?

Commands Current state Proposed UX
/model show / set / restore / toolcall; nested provider/model selection. Title mentions effort, but no effort selector exists here. Current configuration summary, descriptive actions, consistent nested navigation.
/integrations Menu labels repeat full commands, including <service> placeholders. “View integrations”, “Verify connections”, “View details”, “Set up integration”, “Remove integration”. Pick the service in the next step.
/mcp list / connect / disconnect; server picker for disconnect. “Connected servers”, “Connect server”, “Disconnect server”, with the same selection and confirmation styling.
/history show / clear / off / on / retention; separate numeric retention menu. Show persistence state first; use “View history”, “Pause recording”, “Resume recording”, “Retention limit”, “Clear saved history”.
/trust, /verbose Repeating on / off / done menus without a current-state summary. Small setting pickers with current value marked and consequences explained.
/theme Already selects and marks the current theme. Keep that behavior; adopt the shared frame, selection styling, and spacing.
/resume Recent sessions packed into fixed-width labels. Session name as the primary label; timestamp and short ID as secondary information.
/loops show Loop ID and name in a simple picker. Same resource-picker layout as /resume; retain the existing report view.

The current implementations are in:

2. Action menus

For /model, /integrations, /mcp, and /history: show context first, followed by actions written in plain language. A trailing › means the action opens a child screen.

Proposed /model layout:

╭─ Model ───────────────────────────────────────╮
│ <provider> · <current model>                   │
│ Effort: <current effort>                      │
│                                              │
│ › Change model                            ›  │
│   Change reasoning effort                 ›  │
│   Configure tool-call model               ›  │
│   View configuration                         │
│   Restore provider defaults               ›  │
│                                              │
│ ↑↓ move   Enter select   Esc close            │
╰──────────────────────────────────────────────╯

Adding effort here is an intentional enhancement, not existing behavior. It must reuse /effort’s setting and capability checks—not introduce a second setting. Unsupported providers should explain that the setting has no effect. Existing account-managed restrictions must remain in force.

Nested navigation:

/model
  ├─ Change model
  │    └─ Provider
  │         └─ Reasoning model
  │              └─ Tool-call model, where applicable
  ├─ Change reasoning effort
  ├─ Configure tool-call model
  ├─ View configuration
  └─ Restore provider defaults

Enter → open the selected step / apply a final selection
Esc   → return one level, preserving the preceding selection
Esc at the root → close and return to the composer

Child screens use a breadcrumb such as Model › Change model › Provider. They replace the preceding menu rather than stacking repeated menu blocks in the transcript.

Proposed /integrations layout:

╭─ Integrations ────────────────────────────────╮
│                                              │
│ › View integrations                          │
│   Verify connections                         │
│   View details                            ›  │
│   Set up integration                      ›  │
│   Remove integration                      ›  │
│                                              │
│ ↑↓ move   Enter select   Esc close            │
╰──────────────────────────────────────────────╯
Remove integration → Choose service → Confirm removal
                         ↑                 │
                         └──── Esc ────────┘

Confirmation defaults to Cancel, never Remove.

3. Setting pickers

For /theme, /trust, /verbose, and eventually bare /effort and /auto:

  • Mark the active value separately from the focused row.
  • Start focus on the current value.
  • Explain the selected option in one line.
  • Apply on Enter; navigation alone changes nothing.
  • Close with a concise success message.

Illustrative theme picker, after moving focus away from the saved theme:

╭─ Theme ──────────────────────────────────────╮
│ Current: <saved theme>                       │
│                                              │
│   <saved theme>                       current │
│ › <another theme>                            │
│   <third theme>                              │
│                                              │
│ Enter applies and saves. Esc leaves unchanged.│
│ ↑↓ move   Enter select   Esc close            │
╰──────────────────────────────────────────────╯

For /trust, explicitly explain that enabling it skips approval prompts. Do not present it as an unexplained “on”. Preserve the existing persistence/session scope of each setting; the UI must not silently change what gets saved.

4. Resource pickers

For models/providers, integrations, MCP servers, sessions, and loops:

  • Primary name plus secondary metadata—not manually padded strings.
  • Bounded scrolling with a position counter.
  • Preserve selection when returning from a child screen.
  • Narrow terminals move details beneath the selected row.
  • Empty states explain the next action.

Illustrative session picker:

╭─ Resume session ──────────────────── 2 / 10 ─╮
│   Investigate deploy failure                 │
│ › Review service latency                     │
│   Check integration setup                    │
│                                              │
│ <selected session timestamp> · <short ID>     │
│                                              │
│ ↑↓ move   Enter resume   Esc close            │
╰──────────────────────────────────────────────╯

Search can follow later. It needs deliberate handling so typing does not conflict with numeric shortcuts or custom model-ID input.

5. Shared interaction rules

  1. Match the new slash tray’s theme, rounded border, tinted selection, and chevron. Reuse semantic theme tokens.
  2. Use one heading; show breadcrumbs only when nested.
  3. Esc goes back one level; at the root, it closes. Audit the current model cancellation paths, which are inconsistent.
  4. Keep numeric shortcuts, with hints showing the actual available range. Only advertise keys that work on that screen.
  5. Confirm destructive actions separately, defaulting to cancel.
  6. Keep menus inline, not fullscreen. Preserve the surrounding transcript and return cleanly to the composer.
  7. Preserve direct slash commands and non-TTY behavior.
  8. Keep keyboard focus distinct from the active/saved value. Moving focus is not an application of the setting.
  9. Adapt to narrow and short terminals: never wrap a painted row into uncounted terminal lines, and keep the focused choice visible.
  10. Escape user-controlled labels and restore terminal/input state after selection, cancellation, or failure.

6. Separate PR scope and rollout

This work belongs in a separate PR from #6359.

Feature scope: shared menu presentation plus the existing menus listed above, with /model as the reference flow.

Initial draft slice: opt-in shared panel, /model, and /theme, with real-terminal evidence. The draft is a reviewable starting point, not completion of the whole feature.

Subsequent slices: integrations/MCP, history, trust/verbose, resume, and loop-result pickers. Complete the model navigation and effort enhancement as explicit behavior changes with regression coverage.

Defer / keep distinct:

  • Bare /auto and /effort becoming interactive: today they print status/usage. Adding an effort action inside /model does not require changing those direct-command contracts.
  • /help: it has a distinct expandable browser; share styling, not navigation semantics.
  • /choose and sign-in: they also use the shared picker, but their workflows must remain unchanged.
  • CLI-backed account/auth/setup wizards and commands that already work well as reports.
  • Search/filtering and a terminal-framework rewrite.

Important implementation constraint: make the new presentation opt-in initially. A blanket picker rewrite would also alter agent questions and sign-in screens. Keep the shared renderer free of model/provider business logic; command handlers own their actions and capability checks.

7. Acceptance criteria

  • /model and its child pickers use the reference presentation with clear action labels and truthful current configuration.
  • Model navigation returns exactly one step on Esc and preserves the prior choice without applying a change.
  • The model effort action reuses the existing effort setting and provider support checks.
  • /integrations, /mcp, /history, /trust, /verbose, /theme, /resume, and /loops show adopt the appropriate menu type.
  • Active values remain distinguishable from focus; selection changes only on explicit activation.
  • Long lists scroll within a bounded viewport; narrow/short terminals keep focus and essential controls usable.
  • Destructive actions clearly name their target and default to cancellation.
  • Direct slash syntax, non-TTY behavior, account-managed restrictions, and setting persistence remain intact.
  • Agent-question, multi-select/custom-answer, and sign-in flows retain their interaction contracts.
  • Tests cover clipping/control stripping, focus/current-state distinction, navigation, cancellation without mutation, and legacy picker behavior.
  • Real PTY evidence covers wide/narrow/short terminals, nested menus, numeric/arrow/Enter/Esc input, resizing, and returning to the composer without stray terminal bytes.
  • Required local validation, CI, and automated reviews pass for each PR update.