Where Agents Run¶
Your laptop terminal is where you talk to an agent — it doesn't have to be where the agent lives. Research tasks outlast coffee breaks, lectures, and laptop batteries; decouple the agent's lifetime from yours.
tmux: the minimum viable upgrade¶
tmux keeps terminal sessions alive on the machine, independent of your connection to it.
tmux new -s agent # start a named session
claude # run the agent inside it
# … later: detach with Ctrl-b d, close laptop, go to lunch …
tmux attach -t agent # reattach — the agent kept working
This matters more than it sounds: it changes your relationship with the agent from "pair programming" to "delegation." You check in on it like you'd check in on a long-running job.
On the cluster¶
Everything works the same over SSH — and that's the point. Start tmux on a login node, run Claude Code there, and the agent has direct access to your data, your batch system, and your environment modules:
> Submit the parameter scan in scan/ as a slurm array job, monitor it,
> and when all jobs finish, collect the results into one parquet file
> and plot the summary. Warn me if more than 5% of jobs fail.
The agent writes the sbatch script, submits it, polls squeue, and handles
the bookkeeping you'd normally do by hand at 11 pm.
Cluster etiquette
An agent will happily do anything you'd do at the shell — including
things your admins would frown at. Tell it the rules
(login-node policy, scratch paths, partition names) in a CLAUDE.md
file at the project root. See Skills & MCP.
Remote control¶
You can also flip the arrangement: agent on a machine, you on a phone. Claude Code supports driving a running session remotely (web and mobile), so the agent grinding on the cluster can ask you a question while you're on the bus, and you can answer it.
The pattern to remember:
Conversations are sessions, sessions live on machines, and you choose the machine to match the work — local for iteration, cluster for data and compute, background for anything measured in hours.