plank โ€บ User guide โ€บ Getting started

2. Getting started

Launching

plank              # interactive
plank --help       # every flag

plank picks its front end from your terminal, not from a flag:

Situation Front end
stdin and stdout are both a TTY the full-screen Ratatui TUI
either end is piped the plain line REPL
--non-interactive headless stdin protocol
-p "โ€ฆ" / --prompt "โ€ฆ" run one prompt, print the reply, exit

The TUI and the REPL support the same slash commands and the same tools. The TUI adds markdown rendering, syntax highlighting, mouse scrollback, the status bar, panels for /btw and questions, and the arcade.

Your first turn

Start plank in the project you want to work on:

cd ~/Code/my-project
plank

At startup plank gathers session context โ€” git status, the date, any AGENTS.md it finds โ€” and hands it to the model before your first message, so you can open with "why is the parser dropping the last token?" rather than explaining where you are.

Then type. A few things to know immediately:

It is not only for code

plank is built as a coding agent, but nothing about it is restricted to code. In practice it gets used for:

Short follow-ups work the way they do in a conversation: "what else", "keep going", "now one in Pascal", "summarize it here". You do not need to restate context that is already on screen.

Working directory

plank operates in the directory it was launched from. Tools resolve relative paths against it, the bash sandbox writes only inside it, and project-scoped config (./.plank/, ./.mcp.json) is read from it.

plank --chdir ~/Code/other-project

changes the working directory before starting. One caveat: project settings are read from the launch directory, so ./.plank/settings.json does not follow --chdir.

One-shot mode

plank -p "summarize what changed in the last three commits"

Runs a single prompt with all tools available, prints the reply, and exits. Works with hosted providers too:

plank --provider anthropic --model claude-sonnet-4-5 -p "review src/parser.rs"

Headless mode

--non-interactive disables the interactive UI and reads a line protocol from stdin โ€” the mode to drive plank from a script or another program. For driving the TUI from a test harness, see --ui-remote in Remote and hosted engines.

Leaving and coming back

Type /quit (or /exit, or Ctrl-D at an empty prompt). Your session is saved automatically.

plank /resume            # most recent session
plank /resume amused     # by name prefix

or from inside plank, /resume with no argument to pick from a list. A resumed session replays through the same renderer, so history comes back as markdown with thinking dimmed โ€” and plank restores the engine KV alongside the transcript, so it does not have to re-read the whole conversation before your first new message.

On the way out plank prints what the run cost:

Session stats  โ†“ 128,209 โ†‘ 8,269  ยท  12:20
  glm5.2          โ†“ 120,000 โ†‘ 7,900
  ds4 (local)     โ†“   8,209 โ†‘   369

Tokens in and out, and the wall clock. The per-engine breakdown appears only when more than one engine served the session โ€” which is the case worth reading, since it separates what a hosted provider billed you for from what ran on your own machine.

See Sessions for the full story.

Telling plank about your project

Two files change how every session in a directory starts:

See Context.

When something is ambiguous

The model can ask you rather than guess: the ask tool opens a multiple-choice panel (a numbered list in the REPL) and blocks until you pick. It degrades cleanly when there is nobody to ask.

If a task is risky, the model can enter plan mode โ€” read-only until it proposes a plan and you approve it. See Tools.


Next: The interface โ†’