Navigating the CLI
The Cosine CLI features an intuitive terminal-based user interface (TUI) with three main areas: the Sidebar Panel, the Timeline, and the Chat Input. This guide covers keyboard navigation, shortcuts, and how to move between different views.
Interface Overview
Section titled “Interface Overview”┌─────────────────────────────────────────────────────────────┐│ Sidebar Panel │ Timeline (Main Chat) ││ (Overview, │ ││ Terminals, │ User: How do I refactor this? ││ Agents, │ ││ Changes) │ Assistant: Here's the solution... ││ │ ┌─────────────────────────────┐ ││ │ │ Tool: code_edit │ ││ │ │ File: src/utils.ts │ ││ │ └─────────────────────────────┘ ││ │ │├───────────────────┴─────────────────────────────────────────┤│ [Ctrl+P] Tools │ [Shift+Tab] Mode: Auto > Type message │└─────────────────────────────────────────────────────────────┘The Three Main Views
Section titled “The Three Main Views”1. Sidebar Panel (Right Side)
Section titled “1. Sidebar Panel (Right Side)”The panel provides contextual information and tools across four tabs:
| Tab | Shortcut | Description |
|---|---|---|
| Overview | Ctrl+1 / Alt+1 | Repository structure and context files |
| Terminals | Ctrl+2 / Alt+2 | Active terminal sessions and output |
| Agents | Ctrl+3 / Alt+3 | Background agent tasks and subagents |
| Changes | Ctrl+4 / Alt+4 | Git diff and file changes |
Panel Controls:
Ctrl+/- Toggle panel visibility on/offCtrl+``(backtick) - Toggle focus between panel and chatTab/Shift+Tab- Cycle between sections (when panel is focused)Left/Right- Switch between panel tabs (when panel is focused)
2. Timeline (Center)
Section titled “2. Timeline (Center)”The timeline displays the conversation history, including:
- User messages
- Assistant responses
- Tool calls and their results
- Terminal output
- Plans and todo lists
- Reasoning blocks
3. Chat Input (Bottom)
Section titled “3. Chat Input (Bottom)”The text area where you type messages to the AI agent.
Timeline Navigation
Section titled “Timeline Navigation”The timeline supports powerful keyboard navigation for reviewing past conversations and copying content.
Navigating Between User Messages
Section titled “Navigating Between User Messages”When the timeline is focused, use these keys to jump between user messages:
| Key | Action |
|---|---|
↑ (Up) / k | Jump to previous user message |
↓ (Down) / j | Jump to next user message |
Space | Expand/collapse assistant response under selected user message |
y | Copy the assistant’s response to clipboard |
How it works:
- Press
Tabuntil the timeline is focused (or click in the timeline area) - Press
↑or↓to navigate between your past questions/prompts - The assistant’s response to that message is highlighted
- Press
yto copy the entire assistant response to your clipboard - Press
Spaceto expand or collapse the response for easier reading
Scrolling the Timeline
Section titled “Scrolling the Timeline”General scrolling works from any view:
| Key | Action |
|---|---|
PgUp / Ctrl+U | Scroll up one page |
PgDn / Ctrl+D | Scroll down one page |
Home | Jump to top of timeline |
End | Jump to bottom of timeline |
Pro tip: When your cursor is in the input box and it’s empty, the Up/Down arrows automatically scroll the timeline instead of moving the cursor.
Execution Block Navigation
Section titled “Execution Block Navigation”Execution blocks are groups of related activities (tool calls, terminal output, reasoning). You can navigate between them:
| Key | Action |
|---|---|
Shift+↑ | Select previous execution block |
Shift+↓ | Select next execution block |
Ctrl+O | Toggle expand/collapse selected execution block |
Section Navigation
Section titled “Section Navigation”Cycle between the main interface sections:
| Key | Action |
|---|---|
Tab | Move focus to next section (Input → Timeline → Panel → Input) |
Ctrl+Tab | Quickly focus the chat input from anywhere |
Common Actions
Section titled “Common Actions”Copy to Clipboard
Section titled “Copy to Clipboard”| Key | Action |
|---|---|
y | Copy selected assistant output (timeline focused) |
The copy action shows a brief visual confirmation when successful.
Expand/Collapse Content
Section titled “Expand/Collapse Content”| Key | Action |
|---|---|
Space | Expand assistant response under selected user message |
p | Toggle plan visibility |
Ctrl+O | Toggle execution block |
Tool Confirmation
Section titled “Tool Confirmation”When a tool requires confirmation:
| Key | Action |
|---|---|
y / Enter | Confirm and execute tool |
n / Esc | Reject tool execution |
Mode Switching
Section titled “Mode Switching”Switch between AI operation modes:
| Key | Action |
|---|---|
Shift+Tab | Cycle through modes: Normal → Auto → Plan → Swarm |
Modes explained:
- Normal: Ask for confirmation before each mutating action (default)
- Auto: Automatically execute all tools without confirmation
- Plan: Read-only planning — explore code and create a plan before executing
- Swarm: Multi-agent orchestration with parallel subagents
For a detailed explanation of each mode, see Modes.
Quick Reference: Essential Shortcuts
Section titled “Quick Reference: Essential Shortcuts”| Shortcut | Action |
|---|---|
Ctrl+C | Interrupt/cancel current agent run |
Esc | Cancel operation or close dialog |
Enter | Send message (when in input) |
Shift+Enter / Ctrl+J | New line in input (without sending) |
Ctrl+Tab | Focus chat input |
Ctrl+/ | Toggle sidebar panel |
Ctrl+P | Open tools/settings |
Ctrl+L | Open event log (debug mode) |
? | Open keyboard shortcuts help |
Tips for Efficient Navigation
Section titled “Tips for Efficient Navigation”- Quick copy workflow: Press
Tabto focus timeline,↑/↓to find the message,yto copy - Hide panel for focus: Use
Ctrl+/to hide the panel when you want more space for the conversation - Navigate while typing: Use
Ctrl+Tabto jump back to input from anywhere - Review tool results: Use
Shift+↑/Shift+↓to jump between execution blocks - Scroll hands-free: When not typing, Up/Down arrows scroll the timeline; when typing in empty input, they also scroll
See Also
Section titled “See Also”- CLI Overview - General CLI documentation
- Configuration - Customize keybindings and behavior
- Browser Automation - Using Chrome with the CLI