Inter‑Agent Communication (A2A Bridge)
Why A2A?
Inter‑operability. Lets agents written in Julia inter‑operate with agents hosted anywhere that speaks the open A2A (Agent‑to‑Agent) protocol.
Zero client code. External users send a plain HTTP request; the bridge translates it to the agent’s webhook and streams back the result.
Stateless scaling. All session state lives in the JuliaOS backend; the bridge is a thin, stateless proxy, so you can run as many
uvicorn
workers as you like behind a load‑balancer.
Core Components
HTTP Edge
uvicorn
+ Starlette (starlette.io)
Lightweight ASGI server; hot reload at container restart.
Route Mounting
A2AStarletteApplication
At startup, the bridge discovers RUNNING agents and mounts /{agent_id}/a2a
.
Executor
GenericExecutor
Parses text → JSON, invokes POST /agents/{id}/webhook
, streams the last log line.
Backend API
JuliaOSConnection
(Python SDK)
Auto‑generated client; same auth & RBAC rules as CLI/REST.
Request / Response Walk‑through
External caller posts (JSON) to
http://<bridge>/<agent_id>/a2a
.GenericExecutor hands the payload to the agent’s webhook via
httpx.AsyncClient
python-httpx.org.JuliaOS executes the chosen tool/strategy; each step is logged.
The bridge captures only the last log entry (convention: final answer) and streams it back as the A2A reply.
Last updated