Surfaces

W1 CLI

No editor, no app, no Electron. One binary, your project, and the same runtime the desktop app uses.

Install#

npm i -g @w1-lab/cli@latest
w1 login

w1 login opens the hosted W1 sign-in page in your browser and stores the session in ~/.w1/auth.json — the same protected location the desktop app uses. You never paste a credential into the terminal, and the desktop app does not need to be installed for this to work.

Commands#

w1 [project]                  start an interactive W1 session
w1 --prompt "inspect this"    run one turn and exit
w1 --image screenshot.png     attach an image to the first turn
w1 --session THREAD_ID        resume a durable W1 thread
w1 --yolo                     allow all tools without permission prompts
w1 login                      sign in or create an account, in the browser
w1 auth status                show the shared W1 session status
w1 logout                     revoke and remove the shared W1 session
w1 doctor [project]           check filesystem, Git, session, runtime, backend and TTY health

Inside an interactive session:

/image PATH   attach an image to the next turn
/clear        start a new thread
/help         show commands
/exit         quit

Access in the terminal#

The CLI keeps W1's normal approval boundary by default. Two flags change it, for that invocation only:

FlagEffect
--full-accessRun without approval prompts.
--yoloThe memorable alias for the same thing, which additionally auto-accepts any defensive approval request that reaches the terminal.

Neither flag lifts the floor — the command denylist and workspace confinement still apply. See Permissions and access.

Reading the terminal#

Every turn shows an activity state immediately, so you are never looking at a silent cursor wondering whether anything is happening:

  • Thinking… — waiting on the model.
  • Working… — a tool is running.

The state clears before narration, answers, approval prompts and questions. Reasoning text stays hidden unless you pass --verbose.

w1 doctor#

When something is wrong, w1 doctor is the fastest way to find out which thing is wrong. It separates the failure classes that look identical from the outside:

  • the filesystem and the project folder
  • Git state
  • your signed-in session
  • the runtime itself
  • reachability of the W1 backend
  • whether the terminal is a real TTY

The CLI bypasses Electron, renderer state, VS Code webviews and extension-host lifecycle entirely — which makes it the right tool for diagnosing a desktop problem, because anything that still fails here is not a UI problem. It cannot bypass a W1 backend outage, a DNS or TLS failure, or an expired account session, and doctor tells you which of those you have.

Differences from the app#

CLIDesktop and VS Code
Browser toolsNot offered — a terminal has no browser to driveAvailable
ApprovalsTerminal promptsApproval cards
ThreadsDurable; resume with --sessionDurable
Everything elseThe same engine, tools, memory, rewind and permissions
note

A surface never advertises a tool it cannot host.

The browser tools are removed from the CLI's tool set before the model is ever asked, rather than being offered and then failing.

Something wrong or missing on this page? Tell us