Multiplexer overview
Castellan ships an in-tree PTY multiplexer with a HerdR-shaped NDJSON socket API. One binary (castellan) serves daily-driver pane farms without an external herdr binary.
Architecture
castellan herd server → castellan-multiplexer (Unix socket)
│
├── pane.spawn / pane.attach (PTY proxy)
├── events.subscribe / events.wait
└── pane.report_agent (hook protocol)
Pane agent status feeds the pressure field: agent_status observations can deposit pheromones that boost scheduler wake on the herdr zone.
Quick start
castellan herd server # background socket
castellan swarm-demo # scheduler-led multi-pane demo
castellan herd attach # interactive session
Attach modes
| Mode | Command | Use |
|---|---|---|
| Poll | castellan herd status | Headless CI, scripts |
| Proxy | castellan herd attach | Daily-driver TTY |