Interactive mode is the main environment of daily work, and mastering it comes down to three things: turn control, input editing and quick prefixes. A turn is one run of the agent; you need to be able not only to start it but to stop it in time. Esc interrupts the current response or tool while keeping the work already done, and closes an open dialog - it is the main tool of intervention when the agent has gone the wrong way.
The other turn-control keys are worth learning as a reflex. Ctrl+C interrupts the work, and on empty input clears the line; a second press ends the process. A double Esc on empty input opens rewind, and while typing clears the draft, saving it to history. Shift+Tab switches the available permission modes, Alt+P changes the model without losing the draft, Alt+T toggles extended thinking if the model allows it, Alt+O toggles fast mode. Background tasks go to the background with Ctrl+B.
Input editing follows the familiar readline logic: moving to the start and end of the line, deleting to the edge or the previous word, searching history, undoing an edit. The prompt can be opened in an external editor via $EDITOR, the draft hidden and restored, a past input found. Multiline input is typed with a backslash and Enter, Ctrl+J or Shift+Enter in supporting terminals; in VS Code, Cursor and some others you first run /terminal-setup.
It helps to gather the key combinations into a table once, so as not to keep them in your head but to return as needed. Below is a map of turn control and input editing: interruption, rewind, switching mode and model, basic editing. You return to it while your hand has not yet learned the reflexes: it is Esc and Shift+Tab, not a session restart, that are the right reaction when the agent goes wrong.
| Combination | What it does |
|---|---|
| Esc | Interrupt response/tool keeping work; close a dialog |
| Ctrl+C | Interrupt; on empty input clear the line, repeat - exit |
| Esc Esc | On empty input - rewind; while typing - clear draft to history |
| Shift+Tab | Switch permission modes |
| Alt+P / Alt+T / Alt+O | Model / extended thinking / fast mode |
| Ctrl+B | Send Bash tasks and agents to the background |
|---|
| Ctrl+O | Transcript viewer with full tool calls |
|---|
Quick prefixes at the start of a line set the input mode. A slash invokes a command or a skill. An exclamation mark enables shell mode: the command runs and its output is added to the session - but shell mode does not bypass permissions and the sandbox, it merely lets a human explicitly run a command and put the result into the conversation. An at sign starts autocomplete of a file, an MCP resource or a subagent, and a question mark on an empty line shows the shortcut help.
For diagnostics and reading there are separate means. Ctrl+O opens the transcript viewer with full tool calls - it, not the shortened view, is what you use when you need to understand what the agent actually did. The /focus command removes visual noise but does not change the model's context, and /tui fullscreen enables a full-screen render with stable scrolling. Focus mode is handy for reading, but taking tools apart needs the full transcript.
Vim mode is enabled via /config in the Editor mode section and is finely tunable. A two-character sequence for leaving insert mode is set via vimInsertModeRemaps - for example, jj to Escape. An important safety detail: such key remaps are allowed only in user or managed settings, and project settings cannot override your keys. This is protection from a repository that could otherwise change the behavior of your input.
The typical interactive failures are about attention control. Waiting for the agent to stop on its own instead of interrupting it with Esc the moment it goes wrong. Restarting the session instead of a rewind with a double Esc, losing context. And relying on the focus view during diagnostics without opening the full transcript, where the real tool calls are visible. Master interruption, rewind and mode switching as a reflex - and the interactive mode becomes controllable rather than a stream you can only watch.
// Vim mode and leaving INSERT - only in user/managed settings
{
"editorMode": "vim",
"vimInsertModeRemaps": { "jj": "<Esc>" }
}
// project settings CANNOT remap your keys