AI Agent Architecture

Herdr Crash Course: Run AI Agents in Persistent Terminals

Direct Answer

Herdr gives coding agents a persistent terminal workspace rather than replacing the agents themselves. It groups projects into spaces, tabs, and panes; detects supported agent CLIs; shows whether each agent is working, blocked, idle, or done; and lets the user detach without killing the underlying terminal processes.

That makes it useful when one project needs an implementer, reviewer, development server, test runner, and log stream at the same time. Run Herdr locally for organized sessions that survive closing the client. Run the server on a VPS when the work must continue after the local computer is offline.

The key distinction: Herdr is the terminal and session control layer. Claude Code, Codex, Tau, Pi, OpenCode, and other CLIs remain the workers inside it.

Watch the Herdr Crash Course

Credit and evidence note: the walkthrough comes from Alejandro AO's Herdr Crash Course, published on 27 August 2026. Product behavior and commands were cross-checked against the current Herdr documentation and public repository.

What Herdr Actually Does

A normal terminal window owns the interactive view of the processes started inside it. A terminal multiplexer inserts a server-managed session layer between the visible client and those processes. The client can disappear and reconnect later while the server keeps the pseudo-terminals alive.

Herdr adapts that old and durable idea to agent-heavy development. Its official documentation describes a background server that owns the terminals and a client that attaches to them. Herdr detects supported coding agents, reads pane state, groups work by project, and exposes the same control surface through its CLI and local socket API.

LayerResponsibilityWhat it does not do
Herdr serverOwns sessions, terminals, layout, and runtime stateChoose the model or write the code
Herdr clientRenders and controls the current workspaceNeed to remain attached
Agent CLIPlans, edits, runs tools, and reports progressOrganize every neighboring process
Project toolsServe apps, run tests, stream logs, build artifactsCoordinate agent sessions by themselves

Spaces, Tabs, and Panes

Alejandro recommends one space per project. Inside a space, each tab can represent a durable process or role: implementation, review, development server, tests, database, or logs. A tab can then split into multiple panes when two related processes need to stay visible together.

This hierarchy prevents a common multi-agent failure: five anonymous terminals with no clear ownership. Name the role and the finish line. Keep the application server separate from the agent changing it. Give reviewers their own pane and branch or worktree so inspection does not collide with implementation.

Herdr objectRecommended meaningExampleBoundary
SpaceOne repository or productCustomer dashboardShared project context
TabOne role or long-lived processImplementer, reviewer, dev serverClear responsibility
PaneOne closely related subprocessAgent beside test outputVisible local coordination
Named sessionIndependent Herdr server stateClient work and side projectSeparate runtime state

Agent Detection Reduces Status Hunting

When Alejandro starts Pi or Tau, Herdr detects the process and adds it to the agent list. The interface changes status as the agent works and can notify the user when it finishes or needs attention. The official product page describes working, blocked, idle, and done states.

This is coordination visibility, not proof of quality. “Done” means the process reached a state Herdr recognizes. It does not mean tests passed, the diff is correct, or the task satisfies the ticket. Pair status tracking with an explicit completion contract: changed files, commands run, test results, unresolved risks, and a reviewer decision.

What Persists, and What Does Not

Detach with ctrl+b q and run herdr later to reattach. While the Herdr server remains alive, panes, shells, agents, tests, servers, and commands keep running. Closing the terminal client does not terminate those server-owned processes.

A full server stop or machine restart is different. Herdr restores the saved layout, directories, and focus, but arbitrary processes are gone. Supported agents may resume their own conversation sessions through native integration references. Optional pane-history replay can restore recent screen contents, not the original process.

EventProcesses continueLayout returnsWhat to expect
Detach clientYesYesStrongest persistence path
Close terminal appYes, while Herdr server and host stay activeYesReattach later
Computer sleeps or powers offNo local executionAfter restartUse a VPS for continuity
Server restartNoYesAgents resume only when their integration supports it

Pane-history replay is off by default because terminal output can contain secrets, prompts, tokens, and command results. If enabled, treat the Herdr session directory like sensitive shell history.

Why Multiplexers Use a Prefix Key

The terminal, multiplexer, and agent may all want the same keyboard shortcut. Herdr resolves that collision with a prefix. Press ctrl+b first, then the next key is interpreted as a Herdr command. Without the prefix, input goes to the process inside the active pane.

In the tutorial, ctrl+b c creates a tab, ctrl+b s opens settings, ctrl+b ? shows shortcuts, and ctrl+b q detaches. Mouse controls are available while those bindings become familiar. This is a sensible onboarding path: begin with visible menus, then learn only the shortcuts used repeatedly.

Remote Mode Moves the Work to a VPS

For uninterrupted work, install Herdr and the agent tools on a remote Linux or macOS host. The simplest route is to SSH into the host and run Herdr there. The more integrated route is herdr --remote workbox, where workbox is an SSH host alias.

In remote mode, the local Herdr process acts as a thin client. It connects over SSH, starts or attaches to the remote Herdr server, and streams the interface to the local terminal. Agent processes, tests, servers, repositories, and credentials live on the remote host. The client can disconnect while that host continues running.

Not literally zero latency: the local client avoids some overhead and keeps local keybindings and desktop integration, but every remote interaction still crosses the network. Expect responsiveness to depend on round-trip time, bandwidth, server load, and SSH stability.

Herdr uses normal OpenSSH authentication. Verify ssh workbox before debugging Herdr. The current documentation supports Linux, macOS, and Windows clients connecting to Linux or macOS remote hosts; Windows is not supported as the remote host.

ModeWhere UI runsWhere agents runBest for
Local herdrLocal computerLocal computerDaily development and fast setup
SSH then herdrRemote host, streamed through terminalRemote hostSimple tmux-style access
herdr --remoteLocal thin clientRemote hostPersistent agents with local controls

Let an Agent Operate the Multiplexer

Herdr exposes CLI and socket APIs for inspecting and controlling the session. Its official reusable skill teaches an agent to inspect spaces, tabs, panes, and neighboring agents; split panes; run commands without stealing focus; read output; wait for servers or tests; and start helper agents.

The skill includes a useful ownership check. If HERDR_ENV=1 is not present, the agent should stop because it is not running inside a Herdr-managed pane. That prevents an agent outside the environment from blindly attempting session-control commands.

The current documented global installation command is:

npx skills add herdrdev/herdr --skill herdr -g

A release-matched copy can also be printed with herdr --skill. Install the skill at project scope instead of globally when only one repository should receive those instructions.

Alejandro demonstrates Tau creating a new Herdr session, starting Pi inside it, and prompting that agent to return “hello world.” The demonstration proves the control path. It does not yet prove robust multi-agent planning, conflict resolution, or review quality.

Where Tau Fits

Tau is a separate open-source terminal coding agent maintained under Hugging Face. Its repository describes a small, readable Python agent with file, edit, shell, session, skill, and provider abstractions. It supports hosted providers and custom OpenAI-compatible endpoints, including local models.

Herdr hosts and observes the terminal process; Tau performs the coding work. The same relationship applies to Codex, Claude Code, Pi, OpenCode, and other supported CLIs. This separation is valuable because the session layer can remain stable while teams change models and agent harnesses.

The Remote Agent Security Checklist

A persistent VPS with repositories, model credentials, deployment tokens, and agents that can run shell commands is a consequential environment. Convenience should come with narrower authority, not a permanent bypass.

  • Use SSH keys with a passphrase and an agent rather than password login.
  • Create a non-root user and restrict inbound network access.
  • Keep each client or project in a separate directory, branch, and credential scope.
  • Do not expose development servers publicly unless authentication and firewall rules require it.
  • Give agents test, staging, and read-only credentials before production credentials.
  • Keep destructive commands, deployments, purchases, and messages behind human approval.
  • Patch the host, Herdr, agent CLIs, and dependencies on a deliberate schedule.
  • Review session history, logs, backups, costs, and processes that continue after detachment.

Persistence also changes failure handling. Long-running agents need time limits, budget limits, observable checkpoints, and a way to stop the entire session. The official CLI includes session listing and stopping commands; use them as operational controls, not only cleanup.

A Practical First-Hour Rollout

  1. Install and inspect. Use the official method for the operating system, verify the binary, and read the release-matched documentation before executing a remote installer in a sensitive environment.
  2. Create one project space. Add three tabs: implementer, tests, and development server. Name them clearly.
  3. Test detachment. Start a harmless timed command, detach with ctrl+b q, reattach, and confirm the process remained alive.
  4. Test completion state. Run one supported agent, observe its status, and verify that a notification corresponds to the actual task state.
  5. Define done. Require each agent to report its diff, tests, unresolved risks, and next approval.
  6. Add remote only if needed. Harden a small VPS, verify SSH, install the same tools, and repeat the harmless test through herdr --remote.
  7. Install the skill last. Let an agent inspect and create a disposable pane before allowing it to launch real work.
Good first automation: ask one agent to create a sibling pane, run the project's test command there, wait for completion, read the output, and summarize failures without editing any files.

Video Chapters

TimeTopicTimeTopic
00:00Introduction08:59Settings, themes, and notifications
01:20Installing Herdr and quick tour10:34Detach and reattach locally
02:43Spaces, tabs, and panes11:14Herdr on a VPS
03:37Agent detection and tracking12:03Remote thin-client mode
05:37Agents survive client detachment13:16Controlling Herdr with an agent
06:20What a terminal multiplexer is14:11Tau and local models
07:28How prefix keys work16:21Outro

Verdict

Herdr makes a familiar systems idea legible for the agent era. It gives each project a durable terminal home, shows which worker needs attention, and lets humans or agents control the same session through explicit interfaces.

The real gain is not maximum agent count. It is reduced coordination friction. A small team can separate implementation, review, tests, and servers while keeping ownership visible. A VPS extends that setup beyond one laptop, provided the host and credentials are treated as production infrastructure.

Start with one project, three clearly named tabs, and one review gate. Add remote execution only when local persistence is insufficient, and add agent-driven orchestration only after the manual session model is reliable.

Sources and Links

This article uses the primary video's official YouTube publication date of 27 August 2026 and was researched and published on 6 September 2026. Commands and behavior reflect the documentation available on that date. Herdr and Tau are actively developed, so verify current release notes before installation.

Common questions

What is Herdr?
Herdr is a terminal multiplexer and background server designed around coding-agent workflows. It keeps terminals grouped into spaces, tabs, and panes, detects supported agents, and lets users detach and reattach.
Do agents keep running when I close my laptop?
They keep running when the Herdr client or terminal closes while the Herdr server and computer remain active. If the local machine sleeps, restarts, or powers off, arbitrary local processes do not continue. A VPS or another always-on host provides true off-device continuity.
What does herdr --remote do?
It runs the Herdr client locally, connects over SSH, and attaches to a Herdr server on a remote Linux or macOS host. Commands and agents run on that host while the local client renders and controls the session.
Can an AI agent control Herdr?
Yes. Herdr exposes CLI and socket APIs and publishes an official reusable skill. The skill can inspect panes, start helper agents, read output, and wait for work, but it stops if HERDR_ENV=1 is absent.
How is Tau related to Herdr?
Tau is a separate open-source terminal coding agent from Hugging Face. It supports local and hosted model providers and can run inside Herdr like other agent CLIs.
Share
X LinkedIn Reddit
Build Yours

Want a system
like this one?

Book a free 30-minute call. We map your situation, identify the highest-impact automation, and figure out if we are a fit.

Book Free 30-min Call