Logo vun Herdr

Herdr

CommunautéitBeléift
davidondrej
herdr

Operate and coordinate AI agents running inside Herdr in Ghostty. Use when the user says "Use the Herdr skill," mentions Herdr, or asks to inspect, message, wait for, or coordinate agents in a Herdr workspace. Herdr-specific; do not use for cmux or ordinary terminal sessions.

Iwwersiicht

Editeurdavidondrej
Repositoryskills
Skill-Nummherdr
Stären
4.1K
Forks
599
Matgeliwwert Fichieren
Nëmmen Instruktiounen
LizenzMIT
Linken
  • Instruktiounen am Markdown-Format

    Eng SKILL.md-Datei, déi de Modell bei Bedarf luet, soudatt nëmmen Token ufalen, wann eng Ufro tatsächlech dozou passt.

  • Funktionéiert mat all LLM

    KI-Skills si reng Markdown, keen ubidderspezifesche Code. Dofir funktionéiert dëse Skill mat GPT, Claude, Gemini, Grok oder engem lokale Modell.

  • Alles an den Instruktiounen

    Alles, wat de Modell brauch, steet an den Instruktiounen — keng zousätzlech Dateien ze synchroniséieren.

  • Open Source

    Vum davidondrej op GitHub verëffentlecht. Liest de Quelltext, ier Dir de Skill installéiert.

Installatioun

Installéiert de KI-Skill Herdr an TypingMind, fir e mat all LLM ze benotzen, oder füügt en an en anere KI-Agent an, deen SKILL.md liest.

1

An TypingMind installéieren

TypingMind installéiert e Skill direkt aus sengem GitHub-Dossier — dobäi gëtt SKILL.md gelies, d'Ressourcedateie gi gebëndelt an d'Resultat gëtt lokal gespäichert.

  1. Maacht d'App op a gitt op Plugins → Skills.
  2. Wielt „Vun GitHub installéieren“.
  3. Pecht d'URL vum Skill-Dossier hei drënner an a bestätegt.
    https://github.com/davidondrej/skills/tree/main/skills/agent-orchestration/herdr
  4. Aktivéiert de Skill an all Chat, an deem Dir e benotze wëllt.
Plugins → Skills → Skill afügen → Vu GitHub-URL, pecht dann d'URL vum Dossier an a klickt op Weider.
2

An engem anere KI-Agent installéieren

All KI-Agent, deen d'Format Agent Skills liest, kann dëse Skill benotzen — kopéiert den Dossier an de Skill-Verzeechnes vun deem KI-Agent.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/davidondrej/skills.git /tmp/skills
mkdir -p .claude/skills
cp -r /tmp/skills/skills/agent-orchestration/herdr .claude/skills/herdr
Start Claude Code nom Kopéieren nei, fir datt den neie Skill erkannt gëtt.

An TypingMind benotzen

Aktivéiert Herdr an engem Chat vun TypingMind, an de Modell iwwerhëlt de Rescht. Den Numm an d'Beschreiwung stinn am System-Prompt. Soubal eng Ufro dozou passt, luet de Modell déi komplett Instruktioune selwer — Dir musst de Skill ni manuell opruffen, an et fale keng Token un, bis en tatsächlech benotzt gëtt.

De Modell luet Herdr automatesch, soubal eng Ufro dozou passt.

Funktionéiert mat all KI-Modell

KI-Skills si reng Markdown-Instruktiounen amplaz vun ubidderspezifeschem Code. Dofir ass Herdr net un de Modell gebonnen, fir deen de Skill geschriwwe gouf. Installéiert en eemol an TypingMind a benotzt e mat GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama oder engem lokale Modell, deen Dir selwer bedreift — alles mat Ären eegenen API-Keys.

  • Gëtt nëmme gelueden, wann et néideg ass

    De System-Prompt enthält nëmmen den Numm an d'Beschreiwung. D'Instruktioune gi bei der éischter passender Ufro gelueden, soudatt en onbenotzte Skill näischt kascht.

  • De Modell am lafende Chat wiesselen

    Well de Skill aus Instruktiounen amplaz vu Code besteet, funktionéiert en och no engem Modellwiessel — den nächste Modell liest déi selwecht SKILL.md-Datei.

Skill-Instruktiounen

Dëst ass den Inhalt vu SKILL.md, deen de Modell luet. Liest e virun der Installatioun — e Skill besteet aus Instruktiounen, déi Äre Modell befollegt.

Herdr

Herdr is terminal orchestration, not native agent-to-agent communication or shared memory. Agents call the herdr CLI, which controls panes through Herdr's local socket. This works across Pi, Codex, Claude Code, Cursor CLI, and other terminal agents. Native integrations only improve detection, status accuracy, and session restoration.

Preconditions

The controlling agent must run inside Herdr in Ghostty. Verify access and workspace scope:

bash
test "${HERDR_ENV:-}" = "1"
test -n "${HERDR_WORKSPACE_ID:-}"

If either fails, do not pretend to access other agents; tell the user the agent must be launched inside Herdr.

One-time installation:

bash
npx skills add ogulcancelik/herdr --skill herdr -g

CLI workflow

bash
# Discover pane IDs in this workspace; never guess them
herdr pane list --workspace "$HERDR_WORKSPACE_ID"

# Read the target's recent context
herdr pane read <pane-id> --source recent-unwrapped --lines 120

# Send a prompt and press Enter
herdr pane run <pane-id> "Check the failing tests and report back."

# Wait for completion; use idle instead if that integration reports idle
herdr wait agent-status <pane-id> --status done --timeout 120000

# Read the result
herdr pane read <pane-id> --source recent-unwrapped --lines 120

Stay inside the current workspace. Read before messaging; for inspection-only requests, send nothing. After messaging, wait for done, idle, or blocked, then read the output again. Never assume the prompt was acted on.

Do not close, rename, move, resize, or reconfigure panes you did not create. Do not create or close panes unless the user explicitly asks. “Use the Herdr skill” means execute these CLI operations, not merely explain them.

Sharp edges (empirically verified)

Hard-won facts from driving herdr in production. Trust these over intuition.

Sessions & targeting

  • Always append --session <name> to every command. The HERDR_SESSION env var alone silently falls back to whatever server is already running.
  • Destructive ops only via herdr session stop <name> / herdr session delete <name> (explicit positional name). Never herdr server stop — it acts on whatever server is ambient.
  • Target shape is <session>:<pane-id>; the pane id itself contains a colon (w1:p2). Split on the FIRST colon only.
  • A bare CLI call does not auto-start a server. Start headless with herdr server --session <name>.
  • Every herdr-managed process gets HERDR_ENV=1 and HERDR_PANE_ID. Inside nested tmux, $TMUX wins — treat that pane as tmux.

Sending input

  • pane send-text types but does NOT submit — follow with pane send-keys <pane> enter. pane run = text + Enter in one call.
  • pane run is reliable into a shell prompt, but TUI agent composers (Claude Code, Cursor CLI) treat its text+Enter burst as a paste and swallow the Enter — text sits typed but unsubmitted. To message a TUI agent: send-text, sleep ~1s, then a separate send-keys <pane> enter.
  • C0 control bytes (e.g. ASCII 0x1f) are consumed as terminal control actions and can erase already-typed text. For invisible markers use U+2063 INVISIBLE SEPARATOR — it travels as text.
  • Slash commands open an autocomplete popup; the first Enter may only close the popup or fill an argument placeholder, not submit. escape dismisses the popup and keeps the text.
  • Never verify a submit by "pane content changed". Confirm via native agent status flipping to working/blocked after Enter.

Reading panes

  • pane read --lines N returns COMPLETELY EMPTY output when N is smaller than the pane's viewport height. Always request >=200 lines and trim locally (tail -n N).
  • pane get .cwd is frozen at pane creation. Use .foreground_cwd for the live working directory.
  • pane read --format ansi preserves styling. Ghost/placeholder composer text (rotating suggestions, hints) renders dim (SGR-2) or dark truecolor; real typed input renders normal. This is the only reliable way to tell an empty composer from a human draft.

Agent state

  • herdr agent get <pane> reports working/idle/done/blocked/unknown — native detection, better than regex-guessing.
  • Known gap: status reads idle during a long-running foreground tool call (the model finished its turn; the tool is still grinding). Corroborate an idle verdict with pane text (busy banners like "esc to interrupt") before treating a pane as free or stale.
  • Blocking waits exist: herdr agent wait <pane> --status <s> --timeout MS and herdr wait output <pane> --match <text>.
  • Push events over the socket (protocol >=16): pane.agent_status_changed, pane.output_matched. Use as the fast path; keep polling as the backstop.
  • Any script can register itself as an agent via pane report-agent and report idle/working/blocked.

Workspace / tab lifecycle

  • NO label uniqueness anywhere: workspaces and tabs can share labels. Do your own duplicate checks; find-by-label adopts the first match. An unlabeled workspace displays its cwd basename as its label — a real collision hazard (once caused an adapter to kill a live agent pane it wrongly adopted).
  • workspace create seeds one default tab labeled 1. Closing a workspace's LAST tab deletes the workspace. Closing a tab's only pane closes the tab.
  • --no-focus is respected on workspace/tab create, except the very first workspace in an empty session (always focuses). pane split --no-focus still shrinks the host tab's viewport — the flag governs focus, not geometry.
  • Workspace/tab/pane IDs and labels survive a server restart within a named session. The processes and agent registrations do NOT — panes return as husks (fresh shell, agent get reports agent_not_found). Close-and-replace husks; don't treat them as live duplicates.

Misc

  • tput cols inside a script launched via pane run reports a stale default (80). Never trust it for layout math.
  • For risky experiments use an isolated named session (never default), and re-check herdr session list --json immediately before any stop/delete.
  • herdr integration install <harness> (claude, codex, cursor, pi, ...) enables native status detection per agent. herdr notification show <title> fires a desktop-style alert.

Launching agents in new panes (when the user asks)

ALWAYS launch agents with auto-approval — a worker in an unattended pane stalls forever on a y/n prompt nobody answers:

  • Cursor CLI: cursor-agent --yolo "task" (alias for --force)
  • Codex CLI: codex --yolo "task"
  • Claude Code: claude --dangerously-skip-permissions "task"

This is safe only because David's global-agent-guardrails deny-list hook is installed across all agents. First-run trust dialogs may still appear despite these flags — peek the pane after launch. herdr integration install <cursor|codex|claude> (once each) enables native agent-status detection.

NEVER verify a launch with sleep N && pane read — that is a non-herdr antipattern. Use the native waits: herdr agent wait <pane> --status working --timeout MS (agent picked up the task) or herdr wait output <pane> --match <text>, then read the pane.

Cursor CLI specifics

The real binary is cursor-agent (agent is an alias/new docs name — don't rely on it in scripts). David's shorthand cur = cursor-agent --yolo: fine to type into an interactive pane, but use the full binary in scripts — aliases don't expand there. Launch into an existing pane:

bash
herdr pane run <pane-id> "cd <worktree> && cursor-agent --model gpt-5.3-codex-high --yolo 'fix the failing tests'"
  • Interactive: cursor-agent "task" (or no arg for empty session). Headless: cursor-agent -p "task" --output-format text|json|stream-json.
  • Permissions: --force runs commands without per-command approval (alias --yolo); --sandbox enabled|disabled. Auth for scripts: CURSOR_API_KEY env var.
  • Model: --model <slug> at launch, /model in-session. Enumerate with cursor-agent --list-models — slugs are version/account-dependent, never hardcode from memory.
  • Reasoning effort: there is NO --effort flag — effort is baked into the slug suffix: -low / -medium / -high / -xhigh (e.g. gpt-5.3-codex-xhigh, claude-opus-4-8-thinking-high). -fast is speed, not effort. Bracket syntax model[effort=high] shown in --help is NOT actually supported — always use full slugs.
  • Known bug (mid-2026): some CLI builds silently drop the reasoning suffix passed via --model and fall back to default effort. Verify with /model after launch; --disable-auto-update keeps a working build stable.
  • Resume: cursor-agent resume (latest), --resume <chatId>, cursor-agent ls to list.

Prompt patterns

  • Inspect: “Use the Herdr skill. Inspect every agent in this workspace, read its recent output, and summarize its task and status. Do not send anything.”
  • Ask: “Use Herdr to find the testing agent, read its context, ask whether the test suite passes, wait for its response, and report back.”
  • Coordinate: “Act as lead agent. Inspect all agents, share missing context, prevent duplicate work, wait for results, and give me one combined summary.”

Direct shortcuts

Most defaults use the Ctrl+B prefix. Prefer direct Ctrl+Alt shortcuts, which rarely conflict. Add to ~/.config/herdr/config.toml:

toml
[keys]
new_workspace = "ctrl+alt+n"
workspace_picker = "ctrl+alt+w"
goto = "ctrl+alt+g"
new_tab = "ctrl+alt+c"

Apply changes:

bash
herdr server reload-config

To keep prefixed shortcuts but change the prefix, set prefix = "ctrl+a" under [keys].

Heefeg gestallte Froen

Wat mécht de KI-Skill Herdr?

Operate and coordinate AI agents running inside Herdr in Ghostty. Use when the user says "Use the Herdr skill," mentions Herdr, or asks to inspect, message, wait for, or coordinate agents in a Herdr workspace. Herdr-specific; do not use for cmux or ordinary terminal sessions.

Firwat Herdr op TypingMind benotzen?

Well Dir en eemol installéiert a mat all Modell benotze kënnt. Herdr besteet aus einfachem Markdown amplaz vun ubidderspezifeschem Code. Dee selwechte Skill funktionéiert also mat GPT-5, Claude, Gemini, Grok oder engem lokale Modell – an Dir kënnt de Modell matzen am Chat wiesselen, ouni datt de Skill ophält ze funktionéieren. TypingMind benotzt Är eegen API-Schlësselen, sou datt Dir d'Ubidder direkt bezuelt amplaz vun engem Abonnement pro Benotzerplaz. Är Skills a Chats bleiwen an Ärem eegene Späicher.

Wéi installéieren ech Herdr an TypingMind?

Maacht an TypingMind Plugins → Skills → Vu GitHub installéieren op a setzt https://github.com/davidondrej/skills/tree/main/skills/agent-orchestration/herdr an. TypingMind liest d'Datei SKILL.md an installéiert de Skill, deen Dir pro Chat aktivéiere kënnt.

Wéi eng KI-Modeller kënnen Herdr benotzen?

All Modell, deen Dir an TypingMind verbënnt. KI-Skills sinn einfach Markdown-Instruktiounen an net ubidderspezifesche Code. Dofir kënne GPT, Claude, Gemini, Grok a lokal Modeller dëse Skill lueden, wann eng Ufro dozou passt.

Wéi vill KI-Modeller kann ech mat Herdr benotzen?

Esou vill Dir wëllt. Soulaang e Modell Skills ënnerstëtzt, kënnt Dir Herdr domat benotzen – GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama a méi – alles op TypingMind mat Ären eegenen API-Schlësselen.

Ass de KI-Skill Herdr gratis?

Jo. De Skill gëtt vum davidondrej ënner der Lizenz MIT op GitHub publizéiert. Dir bezuelt nëmmen Ären eegene KI-Ubidder fir d'Token, déi Dir benotzt.

Wat si KI-Skills?

E KI-Skill ass e weiderverwendbaart Pak vun Instruktiounen, dat engem KI-Modell bäibréngt, wéi en eng bestëmmt Aufgab erfëllt. E follegt dem oppenen Agent Skills-Format: eng Datei SKILL.md mat engem Numm an enger Beschreiwung, plus all Scripten, Virlagen oder Referenzdateien, déi de Modell eventuell brauch. De Modell liest d'Instruktiounen eréischt, wann Är Ufro zum Skill passt. En installéierte Skill kascht also näischt, bis e benotzt gëtt.

Wéi ënnerscheede sech KI-Skills vu Plugins oder MCP-Serveren?

E Plugin oder MCP-Server gëtt engem Modell nei Tools, déi en opruffe kann – Code, deen iergendwou leeft an e Resultat zeréckgëtt. E KI-Skill gëtt dem Modell dogéint Wëssen an eng Virgoensweis: wéi en eng Aufgab ugeet, wéi eng Schrëtt en nokënnt a wéi eng gutt Ausgab ausgesäit. Skills bestinn aus einfachem Markdown, brauche kee Server, keen API-Schlëssel a keng Lafzäitëmfeld a funktionéiere mat all Modell.

All weisen

Elo Ären eegene KI-Workspace ariichten

Abonnéiert Iech op eisen Newsletter, fir iwwer nei Funktiounen an zukünfteg Gewënnspiller informéiert ze ginn 👇