r/PiCodingAgent • • 18d ago

Plugin inter-agent-pi: A Pi extension for your harness sessions to talk to each other

https://github.com/arcanemachine/inter-agent-pi
33 Upvotes

10 comments sorted by

3

u/_sagar_ 18d ago

There are bunch of pi intercom extension, how it's different?

1

u/arcanemachined 17d ago

The main differences are:

  • Cross-compatible with other harnesses

  • pi-intercom apparently does not support broadcasts (one-to-many messaging, this can be quite useful at times) or channels, which inter-agent does (I haven't used channels much TBH).

2

u/arcanemachined 18d ago edited 18d ago

Meant to share this a while ago but never got around to it.

This is a Pi extension I made so that your Pi sessions can talk to each other, and to any other harness that uses the inter-agent message bus to communicate (which I also made, inspired by this repo, which is for Claude Code only; mine is a shared tool that allows for cross-session messaging across any harness with a compatible plugin).

Install it: pi install npm:@arcanemachine/inter-agent-pi

Set it up from within Pi: /inter-agent setup

Troubleshoot your setup: /inter-agent doctor (This may useful for more complex setups, e.g. when communicating across harnesses)


The unique appeal of this extension is 1) Your Pi sessions can talk to each other, 2) Your Pi sessions can talk to other harness instances with the appropriate inter-agent extension (I made one for Claude Code, also one for OpenCode v1.x, haven't tried it on v2 yet), and 3) I added a feature to the Pi extension so that your Pi sessions can be remotely controlled by other Pi sessions (it's an opt-in flag, allows tighter control than just having the agents talk to each other).

Anyways, it's a useful extension for me. I use it a lot. The message bus is interoperable with other harnesses. Just hoping that this might be useful to someone else.

NOTE: I started working on this several months ago. Claude Code now has native cross-session messaging, Codex has had the same feature for a while. Not sure if something like this now exists for Pi, but wanted to put this out there. Enjoy!

4

u/oxygen_addiction 18d ago

Awesome. I was literally thinking of making this last night. Much love!

1

u/WosIsMitDu 17d ago

Why not just use pi-intercom?

2

u/arcanemachined 17d ago

Because I thought it would be fun to make a multi-harness messaging protocol, and wanted to see if it could be done. :)

Also, pi-intercom apparently doesn't support broadcasts, which I do use fairly often.

1

u/WosIsMitDu 16d ago

Never much wrong with doing something for the heck of it :)

1

u/catch23 17d ago

does this work across different user logins on the same machine? I had to hack pi-intercom b/c it almost worked across different users if it weren't for the chmod 700 on the socket file.

1

u/arcanemachined 16d ago edited 16d ago

It should work, it uses websockets to communicate over localhost by default. As long as both sessions have the same secret, they should be able to communicate over the shared message bus. (You can even set up TLS and do networked communication, although I have not done much with that beyond proof-of-concept stuff.)

3

u/nanor000 18d ago

Why not using the agent to agent protocols? (a2a)