Cosmonapse is an open protocol (Apache 2.0) for building distributed multi-agent and multi-model harnesses - a nervous system for autonomous AI agents. A working multi-agent system is about twenty lines of code, and the path from a local in-memory broker to NATS or Kafka is a single URL swap with zero changes to agent logic.
Highlights
- Designed a single Signal envelope contract so any two conforming components can interoperate - the protocol's one hard guarantee.
- Built a neuron factory that wraps any LLM provider (OpenAI, Anthropic, HuggingFace, Groq, Ollama) or plain async function behind one interface, with zero protocol knowledge required.
- Split responsibilities across Axon (agent-side) and Dendrite (synapse-side) so only one component ever touches the transport, enforced in code rather than convention.
- Made the transport swappable - MemorySynapse to NATS to Kafka - via a single connection URL.
- Shipped Python and TypeScript SDKs plus a cosmo CLI that boots a local broker and streams live Signal telemetry.
Stack
PythonTypeScriptKafkaNATSApache 2.0