1 pointby el1fe3 hours ago1 comment
  • el1fe3 hours ago
    Hey HN! I built Cogitator— an open-source, self-hosted AI agent runtime for TypeScript. Think of it as "Kubernetes for AI Agents."

    We just shipped native support for Google's A2A Protocol (Agent-to-Agent) v0.3 — implemented from scratch, zero external dependencies, ~1500 lines of code with 119 tests. As far as I know, this is the first TypeScript runtime with a native A2A implementation.

    What A2A enables: Your agents can talk to agents from other frameworks (LangChain, CrewAI, etc.) via a standardized JSON-RPC protocol. You expose an agent as an A2A server, and anyone can discover it via Agent Cards and send it tasks — with streaming support.

    The killer feature is asTool() — wrap any remote A2A agent as a local tool:

      const client = new A2AClient('https://research-agent.example.com');
      const remoteTool = client.asToolFromCard(await client.agentCard());
      const agent = new Agent({ tools: [remoteTool] });
    
    What else Cogitator does: 10+ LLM providers (OpenAI, Anthropic, Ollama, Google, Bedrock), DAG workflows with SAGA compensation, 7 swarm strategies, Memory/RAG with hybrid search, MCP protocol, Docker + WASM sandboxing, self-modifying agents, causal reasoning, and 5 server adapters (Express, Hono, Fastify, Koa, Next.js).

    Everything is TypeScript-native, self-hosted, no vendor lock-in. MIT licensed.

    npm (core): https://www.npmjs.com/package/@cogitator-ai/core npm (a2a): https://www.npmjs.com/package/@cogitator-ai/a2a

    Happy to answer any questions about the architecture or A2A implementation!