The Hive Mesh is the sovereign agent communication backbone. Built on NATS with TLS mutual auth, it connects all E5 agents into a unified task-execution network.

Architecture

Sandbox (Hermie/Queen) ──TLS──► MC NATS :4222 ──► MC Worker
    ▲                                │                  │
    └──────── hive.results ◄──────────┴──── hive.tasks ──┘
  • NATS v2.10.24 — TLS required, JetStream enabled
  • PostgreSQL 16 — Agent registry in CEREBRO (5 tables, 5 views)
  • Systemd — Auto-restarting workers, always-on
  • Star topology — Queen at center, 7 depth-1 workers

Scaling Model

DepthAgentsCapacity
0 (Queen)1orchestrates
1 (Direct)7active workers
2 (Sub-workers)13available slots
3 (Recursive)39theoretical
Total60max mesh

Protocol

  1. Queen dispatches task to hive.tasks.{agent}.{action}
  2. Worker subscribed to hive.tasks.> receives task
  3. Worker executes and publishes result to hive.results.{worker_id}
  4. Queen collects result, records in CEREBRO
  5. All assignments tracked in assignments table

Security

  • TLS mutual auth — Server + client certificates
  • Account-based access — queen / worker roles
  • No idle agents — Every agent has an assignment at all times