Expand description
The agent’s identity variables in its spawn environment, beyond what
input.rs’s split_agent_identity_env and carry_agent_uid_env set.
The server wins on identity (SPEC_FORK_SLUG_MIGRATION_2026_10_22.md
P0.3): when the agent’s row has a slug, AGENTMUX_AGENT_ID,
MUXBUS_AGENT_ID and the git identity AgentMux derived from the id come
from that slug, whatever a persisted cmd:env says. cmd:env is a
launch-time snapshot, so after a rename it names the old id, and the agent
would keep answering to it. AGENTMUX_AGENT_SLUG is set the same way
(split_agent_identity_env), and GH_CONFIG_DIR follows the slug
(gh_guard). An agent with no row or no slug keeps its cmd:env values.
Functions§
- block_
agent_ slug - The definition’s slug for the agent on
block_id, if its row has one. For an env built from the agent’s storedcmd:envoutside a spawn, so it skips the token mint and key ensure a spawn’s lookup does. A store error reads as no slug. - carry_
block_ slug_ identity_ env - [
carry_slug_identity_env] for the agent onblock_id; nothing for a block with no row slug. - pty_
child_ identity_ env - The identity an agent’s PtyShell child carries, as its
cmd:env, from the agent’s env after [carry_slug_identity_env]: its slug and git identity, so a commit typed there is the agent’s. Deliberately notAGENTMUX_AGENT_IDorMUXBUS_AGENT_ID: those are the agent’s address, and an interactive shell exportingAGENTMUX_AGENT_IDreports it through its shell integration (OSC 16162E), which registers that pane as the agent for message delivery (termagent.ts), beside the agent’s own pane.