Agent Mesh runs on KiviDB

Redis's Agent Mesh, an open-source library (Apache-2.0) with an A2A task store and a resumable event stream for FastAPI, runs unchanged on KiviDB. Tested with Redis's own demos on KiviDB 1.2.0:...

Agent Mesh, Redis's open-source library (Apache-2.0), is for agents that hand work to each other and stream their progress: an A2A task store and a resumable event stream for FastAPI. It keeps everything in streams and JSON documents and relies on XADD ... IDMP, which KiviDB 1.2.0 supports (tested), so it runs on KiviDB unchanged. Point REDIS_URL at your database and nothing else changes.

Redis's library, your database

  • Written by Redis, used unchanged Redis's Agent Mesh is an open-source library (Apache-2.0) that runs in your own code. KiviDB did not write it and does not host it; we tested that it works on KiviDB.
  • An A2A task store Agents hand tasks to each other over the A2A protocol, and the task's state and every update are kept in the database, so a client can read the task back.
  • A resumable event stream For FastAPI: progress goes out as server-sent events read from a stream, so a client that drops can reconnect from its saved cursor.

Redis's own demos, unmodified

Tested with KiviDB 1.2.0, the Agent Mesh package 1.0.1 and a2a-sdk 1.2.3, unmodified apart from a shorter pause between steps.

  • A2A task store An agent produces 20 updates. The client reads five, disconnects, waits, then reconnects from its saved cursor. It received all 20, the task ended COMPLETED, and reading the task back returned the same state.
  • FastAPI event stream The same disconnect and resume: all 20 steps arrived in order, then the completed event.
  • Not tested yet A failover in the middle of a task, and sharded databases. Agent Mesh is in beta upstream too.

Write twice, keep one

  • XADD ... IDMP Agent Mesh relies on idempotent stream writes. KiviDB 1.2.0 supports them (tested): repeating an XADD with the same producer and idempotency id returns the first entry's id and adds nothing.
  • Safe retries This is what lets the task store retry a write after a timeout without the update appearing twice.
  • Nothing to enable Idempotent stream writes arrived in Redis 8.6.2 and in KiviDB 1.1.3. New databases run KiviDB 1.2.0.

Every requirement, built in

What Agent Mesh needsOn KiviDB
XADD ... IDMP (Redis 8.6.2 and later)KiviDB 1.1.3 and later
JSON.GET, JSON.SET, ...Built in
redis_version 8.6.2 or laterReports 8.10.0

The streams, kept for you

  • Managed streams and JSON KiviDB Cloud runs the database on AWS, Google Cloud or Azure: created in minutes, backed up and upgraded for you.
  • Kept on disk By default every write is appended to a log synced once a second, so a restarted node comes back with its tasks. Free-tier databases have no disk of their own, so use them to try it.
  • Automatic failover on Pro A Pro database runs a primary and one to three replicas in other zones. If the primary fails a replica is promoted and the hostname follows it. A failover in the middle of a task is not tested yet.
  • TLS Connect with rediss:// and the database's CA certificate, from Connectivity on the database's Overview tab.

Before you run it

  • Use the primary endpoint The task store writes to and reads from the primary. Give it a client connected to the database's main endpoint, not a replica.
  • Keys expire The task store sets a lifetime on every key it writes: seven days while a task is active, one day after it ends. Size the database for the tasks you keep in flight.
  • The demos Download a2a-demo.py and a2a-demo.html, or fastapi-sse-demo.py, from Redis's Agent Mesh quickstart. The docs page has the steps.

Redis's guide, and ours

Questions

What does it cost?

No extra charge beyond the database. Agent Mesh runs in your own code; its tasks and streams use the database's memory.

Did KiviDB write Agent Mesh?

No. Agent Mesh is Redis's open-source library (Apache-2.0). We ran Redis's own demos against KiviDB, unchanged, and report what we found.

Does it work on sharded databases?

Not tested yet. Use a database without shards.

Which KiviDB version do I need?

1.1.3 or later, for XADD ... IDMP. New databases run 1.2.0, which is what we tested.

Point REDIS_URL at KiviDB

Create a database, copy its endpoint, password and CA certificate from Connectivity on the Overview tab, and run Redis's demo against it.