acpmux, agent pane: the person's own acpmux send says the machine it ran on

Merged
TE
1mo ago
+118-6

Leo (relayed by claude-sr2, 2026-10-24): "presumably also, like ACPMUX send, we should be able to, like, just have that with, like, a human involved too, right? But I don't know how we would, you know, fingerprint or whatever attribute that differently, or if it would even be that big of a deal at all."

This follows #24939, which gave agents their chip. Now a person's own acpmux send from a terminal renders as the person, with one quiet line under the bubble naming the machine: "you · via CLI on big-red".

What tells the person from an agent (it doesn't need to be bulletproof; a wrong guess only changes a label). It's an agent if either of these holds:

  • it runs inside an acpmux session (the caller token, inherited by every process the agent spawns);
  • it names an agent (--from, or ACPMUX_FROM, which reach now sets from the caller's session, leo-workspace#1007).

Otherwise it's the person.

How it works.

  • The CLI sends _meta.acpmux.cliHost (the short hostname) only in the person's case.
  • The daemon checks that it looks like a host name, then records it on the prompt's client (acpmux-cli#…@big-red, or acpmux-peer#…@big-red through a peer). It never goes in provenance, so withdraw, the digest and queueing all still treat the prompt as the person's.
  • The pane reads the host from the client (cliHost) and draws the line with the new string transcript.viaCli (21 locales, needs_review).

Tests.

  • prompt_provenance::the_persons_own_cli_send_records_the_machine_it_ran_on: local and peer sends, an agent's named send (no host), and a value that isn't a host name (dropped).
  • cli::sender and incomingMessage.test.ts (cliHost).
  • Gallery: agent-pane.remote-sender#person-cli.

On huge-blue: hub_integration prompt_* passes 11 of 11, peer_integration 32 of 32, lib cli 153; clippy is clean, bun tests and the typecheck pass.

Agent session: big-red

🤖 Generated with Claude Code


View with [code]smith Autofix with [code]smith
Need help on this PR? Tag @codesmith-bot with what you need.