by ogulcancelik
agent multiplexer that lives in your terminal.
# Add to your Claude Code skills
git clone https://github.com/ogulcancelik/herdrGuides for using ai agents skills like herdr.
Herdr is a terminal multiplexer and runtime for coding agents. It organizes terminals into workspaces, tabs, and panes, detects agent identity and status, and exposes the running session through the herdr CLI.
Before issuing any control command, check that this agent is running inside a Herdr-managed pane:
test "${HERDR_ENV:-}" = 1
If the check fails, say that you are not running inside Herdr and stop. Do not inspect or control the focused Herdr session from outside Herdr.
When the check passes, the herdr binary in PATH talks to the running session. Use it to inspect neighboring work, create isolated terminal contexts, start agents and commands, read their output, and wait for state changes.
The installed binary is the authority for command syntax. Begin with:
herdr --help
Then print the relevant command group by running it without a subcommand:
herdr pane
herdr workspace
herdr worktree
herdr tab
herdr wait
herdr terminal
herdr notification
herdr integration
herdr session
Do not run bare herdr for discovery; it launches or attaches the TUI. Do not probe a mutating nested command by omitting arguments; some commands, including herdr workspace create, are valid with defaults and will execute. Use the command-group output above instead.
Most control commands print JSON. Read identifiers and state from those responses instead of predicting either one.
Public IDs are short stable handles:
w1w1:t1w1:p1term_...The encoded suffix can contain letters and can grow beyond one character. Treat every ID as an opaque string.
Closed tab and pane IDs are not reused and do not retarget later resources. A pane moved into another workspace receives a new public pane ID. Re-read create, split, move, list, or get responses after mutations; never construct an ID from a workspace or display number.
Herdr injects the caller's stable context into every managed pane:
printf '%s\n' "$HERDR_WORKSPACE_ID" "$HERDR_TAB_ID" "$HERDR_PANE_ID"
Prefer --current when a pane command should target the calling pane. Omitting a target can use the UI-focused pane, which may belong to the user or another client.
Discover live state with:
herdr workspace list
herdr tab list --workspace "$HERDR_WORKSPACE_ID"
herdr pane current --current
herdr pane list --workspace "$HERDR_WORKSPACE_ID"
An agent runs inside a pane. Use the pane ID as the control target for agents, shells, servers, tests, and logs. This keeps spawning, input, reads, waits, and cleanup on one stable control surface.
Use workspace and tab commands for organization. Use worktree commands only when you intentionally want Herdr to create, open, or remove a Git checkout.
Pane records expose agent, agent_status, and native session metadata when available. Agent status is idle, working, blocked, done, or unknown.
idle and done are the same underlying semantic state with different attention state:
idle: the agent is waiting and its result is considered seen.done: the agent finished and its result has not been seen.An agent that first opens at its prompt reports idle, including in a background pane. After a working or blocked agent completes, it reports done when its tab or workspace is in the background. It reports idle when it completes in the active tab while the foreground client is focused. If the foreground client is explicitly unfocused, completion can become done even in the active tab.
Focusing a pane, switching to its tab, or regaining outer terminal focus marks the visible tab as seen, so done becomes idle. Switching away does not turn an existing idle status into done; done is created by a later completion while the pane is unseen. With no foreground client, a new completion in the globally active tab is treated as seen while completions in background tabs still become done.
Default to a sibling pane in the current tab and current working directory. Do not create a workspace, tab, worktree, or different cwd unless the user explicitly requests that topology or location.
Honor a direction requested by the user. Otherwise inspect the caller pane's current rectangle:
herdr pane layout --pane "$HERDR_PANE_ID"
Split a wide pane to the right and a narrow or tall pane down. Avoid repeated same-direction splits that would create unusably narrow columns or short rows. Keep the user's focus in the calling pane:
herdr pane split --current --direction right --no-focus
Replace right with down when the layout calls for it.
Read result.pane.pane_id from the JSON response. Give the pane a useful label, then start the requested agent by running only its normal executable so its interactive TUI opens:
herdr pane rename <returned-pane-id> "reviewer"
herdr pane run <returned-pane-id> "codex"
Use the executable that belongs to the requested agent:
codexclaudepiopencodeompDo not pass the task as an argv prompt by default. Do not add non-interactive flags. Only change the normal interactive launch when the user explicitly asks for a different launch mode or command.
Inspect the pane after launch. If agent_status is not yet idle, wait for the idle transition. Once it is idle, submit the task with pane run:
herdr pane get <returned-pane-id>
herdr wait agent-status <returned-pane-id> --status idle --timeout 30000
herdr pane run <returned-pane-id> "Review the current diff and report only actionable findings."
Status waits match the current status immediately or wait for a future matching transition.
pane run sends the text and Enter together. Use it for initial prompts and follow-ups instead of coordinating send-text and send-keys separately.
For normal background work, wait for the agent to start working. If the pane remains in a background tab or workspace, wait for done before reading its transcript:
herdr wait agent-status <returned-pane-id> --status working --timeout 30000
herdr wait agent-status <returned-pane-id> --status done --timeout 120000
herdr pane read <returned-pane-id> --source recent-unwrapped --lines 120
If the user is watching that tab, completion reports idle instead, so wait for idle. Always treat either idle or done as completed when inspecting pane get; the difference is whether the result has been seen.
If a wait times out, inspect herdr pane get <returned-pane-id> and pane read before deciding what to do. A blocked agent needs input; an unknown pane may not yet contain a detected or integrated agent.
Submit follow-ups the same way:
herdr pane run <returned-pane-id> "Now check the failing test."
Split the calling pane using the same geometry rule without moving the user's focus:
herdr pane split --current --direction right --no-focus
Read the new pane_id from the JSON response, then run and inspect the command:
herdr pane run <returned-pane-id> "just test"
herdr wait output <returned-pane-id> --match "test result" --timeout 120000
herdr pane read <returned-pane-id> --source recent-unwrapped --lines 120
Inspect existing output before waiting for future output. A wait timeout exits with status 1.
Use the read source that matches the task:
visible: the current rendered viewportrecent: recent scrollback as rendered, including soft wrapsrecent-unwrapped: recent scrollback with soft wraps joined; prefer it for logs and transcriptsdetection: the bottom-buffer snapshot used by agent detectionUse --format ansi when colors and terminal styling are evidence. Otherwise use text.
If the user explicitly asks for another tab, workspace, or worktree, discover that command group and use returned IDs. Do not infer a larger topology from a request to start an agent or command.
--no-focus for background work unless the user asked to switch context.--current or an explicit ID. Do not rely on another client's focused pane.herdr server stop from an active session unless the user explicitly intends to stop the server and its pane processes.Last scanned: 5/10/2026
{
"issues": [],
"status": "PASSED",
"scannedAt": "2026-05-10T06:33:05.628Z",
"semgrepRan": false,
"npmAuditRan": true,
"pipAuditRan": true
}https://github.com/user-attachments/assets/043ec09f-4bdd-41d5-aee0-8fda6b83e267
agent multiplexer that lives in your terminal.
curl -fsSL https://herdr.dev/install.sh | sh
or brew install herdr · mise use -g herdr · windows beta: powershell -ExecutionPolicy Bypass -c "irm https://herdr.dev/install.ps1 | iex" · binaries
then start it where the work lives:
herdr
run your agents, split panes, walk away. ctrl+b q detaches, herdr reattaches. quick start →
everything lives at herdr.dev/docs: quick start · concepts · supported agents · keyboard · configuration · session state · remote · integrations · plugins · socket api
herdr is built full-time, in the open. sponsoring directly funds development, stability, and the path to a real agent runtime.
→ become a sponsor · enterprise / partnership: hey@herdr.dev · see SPONSORS.md for tiers. thank you 🐑
if you are an ai agent helping with this repository, read AGENTS.md before making changes and read CONTRIBUTING.md before opening issues or PRs.
git clone https://github.com/ogulcancelik/herdr
cd herdr
cargo build --release
just test # unit tests
just check # formatting, tests, and maintenance checks
Herdr is dual-licensed:
Contact: hey@herdr.dev
herdr is an open-source ai agents skill for AI coding assistants such as Claude Code, Codex CLI, and ChatGPT, built by ogulcancelik. agent multiplexer that lives in your terminal. It has 16,927 GitHub stars.
Yes. herdr passed SkillsLLM's automated security scan — a dependency vulnerability audit plus prompt-injection heuristics — with no high-severity issues. You can read the full report in the Security Report section on this page.
Clone the repository with "git clone https://github.com/ogulcancelik/herdr" and add it to your Claude Code skills directory (see the Installation section above). herdr ships a SKILL.md manifest, so compatible agents can discover and load it automatically.
herdr is primarily written in Rust. It is open-source under ogulcancelik on GitHub, so you can review or fork the full source.
Yes. SkillsLLM lists many other AI Agents skills you can browse and compare side by side. Open the AI Agents category from the badge at the top of this page, or use the Related Skills and comparison links further down to weigh herdr against similar tools.
No comments yet. Be the first to share your thoughts!