Skip to content
Muxen
Docs · Agent sessions

On your machines

Agent sessions

Run Claude Code, Codex or a shell on any of your machines, and come back to it whenever you like.

An agent session is a terminal on one of your machines running an AI agent or your shell. It lives on that machine, not in the app: close Muxen, sleep your laptop or lose the network, and it keeps working. Open it again and you see its screen as it is now, with its recent scrollback.

A Claude Code session called Checkout fix on the machine Forge, with the sidebar listing each machine's sessions. A Claude Code session called Checkout fix on the machine Forge, with the sidebar listing each machine's sessions.
A Claude Code session on Forge. The sidebar lists each machine’s sessions under it.

The agents

Muxen starts any of these, when they’re installed on the machine:

  • Claude Code (claude)
  • Codex (codex)
  • OpenCode (opencode)
  • Gemini CLI (gemini)
  • Amp (amp)
  • Pi (pi)
  • Shell: your login shell, for anything else.

Muxen finds which ones each machine has. They start in your login shell, in the folder you pick, so nvm, fnm, asdf and each CLI’s own sign-in work as they do in your terminal.

Start one

Click New session (⌘T), or right-click a machine in the sidebar. Pick:

  1. The machine. VMs and containers are listed under the machine they run in. New VM makes a Linux one for this session; see VMs on your machines.
  2. The agent. The ones installed there say so.
  3. The folder. Recent folders and checkouts on that machine are suggested, and you can browse its folders as you type.
  4. A first message (optional, not for Shell): what the agent should work on. Started from a GitHub issue or pull request, it’s filled in for you.
The New session dialog: machines, with a container and a VM under the machines they run in, the agents with which are installed, and recent folders. The New session dialog: machines, with a container and a VM under the machines they run in, the agents with which are installed, and recent folders.
Agents that aren’t installed on the machine are dimmed.

It keeps running

Sessions are kept by Muxen’s agent on the machine (~/.muxen/bin/muxen-agent), the way tmux keeps them. Muxen only attaches to them. Closing the app detaches; the session goes on until you end it.

Restarting the machine ends its sessions, as it would with tmux.

Each machine lists its sessions under it. A spinner means the agent is working. A dot means it finished or is waiting for you (a question, a permission to approve), and it goes away when you open the session. Overview shows the same across all your machines.

The terminal

  • Everything you type goes to the agent: Esc, Ctrl-C, Tab, the arrows, and Option- or Shift-Enter for a new line. ⌘C copies a selection and ⌘V pastes.
  • ⌘D splits the terminal to the right and ⇧⌘D below it: a new shell on the same machine, in the same folder. ⌥⌘← and ⌥⌘→ move between panes. Each pane is a session of its own, and splits come back when you reopen Muxen.
  • Desktop in a session’s header shows the machine’s screen beside the terminal, to check what the agent did. See Desktops.

Open in your editor

The </> button in a session’s header lists the editors on this computer (Zed, Cursor, VS Code) and opens the session’s folder in the one you pick, over ssh. The one you choose in Settings › General › Editor comes first. From a terminal, muxen edit beacon:~/code/api does the same.

Rename, restart, end

  • Rename: right-click the session. The name is kept on the machine, so every Muxen that looks at it sees it.
  • Restart starts an exited session again, in the same folder.
  • End stops it for good.

On Windows

On a Windows PC a session runs in PowerShell (PowerShell 7 when it’s installed) and keeps running there like anywhere else. See Windows.

From a terminal and from other agents

Your AI agents can start sessions, read their screens, see what an agent is asking and answer it. The MCP tools are session_start, session_read, session_question, session_answer, session_send and session_stop; the CLI has the same:

muxen session start beacon claude --cwd ~/code/api --prompt "fix the failing test"
muxen session read beacon/claude-3f9a      # what’s on its screen
muxen session question beacon/claude-3f9a  # what it’s asking, and the options
muxen session answer beacon/claude-3f9a 1  # pick one
muxen session attach beacon/claude-3f9a    # open it in this terminal

See MCP for your agents and The command line.