A pi extension that spawns subagents as separate pi sessions in tmux windows.
- tmux
- Run pi inside tmux
pi install git:github.com/johan/forkOr try without installing:
pi -e git:github.com/johan/forkThe LLM gets one tool: spawn. Calling it opens a new tmux window running pi with the given task and returns immediately. When the child finishes, its final message is sent back over a Unix socket and delivered as a notification that triggers a new turn.
Use tmux keybindings (Ctrl+B n/p/1-9, etc.) to navigate between windows.
If you take over a subagent's tmux window (by typing or pressing Esc), it stays alive as a regular interactive pi session — it won't send results back.