Explyt CLI in herdr
herdr is a terminal multiplexer for AI agents: workspaces, tabs and panes, each running its own agent. Agents keep working even if you close the window. Explyt CLI is built on Pi, and herdr supports Pi, so Explyt CLI works in it.
Without the integration
Explyt CLI is a regular terminal program. Open a pane in herdr and run explyt in it: the agent works as in any other terminal, and the pane survives closing the window.
The integration below gives you more: herdr starts receiving the agent state from the agent itself instead of guessing it from what is drawn on the screen. This gives accurate idle, working and blocked statuses in the Agent sidebar, correct notifications, and waiting for the agent to finish from scripts and other agents.
How to connect the integration
-
Install the Pi integration with the herdr command:
herdr integration install piherdr writes the extension to
~/.pi/agent/extensions/herdr-agent-state.ts. On Windows,~is your home directory, for exampleC:\Users\<user name>. If thePI_CODING_AGENT_DIRvariable is set, the file appears in$PI_CODING_AGENT_DIR/extensions. The directory is created only if the Pi agent folder already exists. -
Check that the extension file appeared. Explyt CLI doesn't read the
~/.pi/agent/extensionsfolder itself, so you need to connect the extension with the--extensionflag:explyt --extension ~/.pi/agent/extensions/herdr-agent-state.tsYou can launch Explyt CLI this way by hand, and the next steps save you from typing the long command: you create a short
explyt-herdrcommand. -
Open your shell settings file and add a line with the short command name at the end.
bash: the
~/.bashrcfile:alias explyt-herdr='explyt --extension "$HOME/.pi/agent/extensions/herdr-agent-state.ts"'zsh (the default on macOS): the
~/.zshrcfile, same line:alias explyt-herdr='explyt --extension "$HOME/.pi/agent/extensions/herdr-agent-state.ts"'PowerShell (Windows): the profile that opens with
notepad $PROFILE. If the file doesn't exist, create it first withNew-Item -ItemType File -Force $PROFILE. In PowerShell an alias doesn't take arguments, so add a function instead:function explyt-herdr { explyt --extension "$HOME\.pi\agent\extensions\herdr-agent-state.ts" @args }If you set the
PI_CODING_AGENT_DIRvariable, replace$HOME/.pi/agentin the path with its value. -
Apply the changes: open a new pane in herdr or run
source ~/.bashrcin the current one (in zsh,source ~/.zshrc; in PowerShell,. $PROFILE). -
In a herdr pane, launch the agent with
explyt-herdrinstead ofexplyt. You can add anyexplytarguments after it, for example--continue.
Verify the setup
Run explyt-herdr in a pane and give the agent a task. While it works, the pane has the working status in the herdr sidebar, and idle when the agent finishes. The herdr agent explain <pane> command shows what exactly herdr detected for the pane.