Purpose-Built for Agentic Scale
The Database Behind Every AI Agent
TiDB provides the transactional speed, unified data access, and elastic scale AI agents need to reason, act, and iterate in real time.
Expand instantly to match demand, then scale to zero when idle
- Autoscaling adapts to agent workloads automatically, from zero to peak
- Instant branching creates isolated environments in milliseconds
- Compute and storage scale independently, no capacity planning required
Query vectors, transactions, and analytics in a single call
- Join vector similarity results directly against transactional data
- One engine replaces your vector store, warehouse, and transaction layer
- No ETL, no middleware, fewer systems to build and maintain
-- One query. Vectors + transactions.
-- No separate vector DB needed.
SELECT
a.agent_id, a.goal, a.status,
m_top.relevance
FROM agent_tasks a
JOIN (
SELECT id,
vec_cosine_distance(
embedding, '[0.12, 0.85, ...]'
) AS relevance
FROM memory_store
ORDER BY vec_cosine_distance(
embedding, '[0.12, 0.85, ...]')
LIMIT 100
) m_top ON a.context_id = m_top.id
WHERE a.status = 'active'
ORDER BY m_top.relevance
LIMIT 10;
Give every agent action a reliable, up-to-date view of the data
- Agent state stays ACID-consistent from one workflow step to the next
- Concurrent agents always read identical state, no matter which node they hit
- Multi-step workflows survive failover without losing progress or replaying actions
-- Agent step 3: update, then read back.
-- The read ALWAYS reflects the write.
BEGIN;
UPDATE agent_state SET
step = 3,
plan = JSON_SET(plan,
'$.next_action', 'execute')
WHERE agent_id = 'a-7f3e'
AND step = 2; -- compare-and-swap
-- Immediate read: no stale state.
SELECT step, plan->>>'$.next_action'
FROM agent_state
WHERE agent_id = 'a-7f3e';
-- Returns: step=3, next_action='execute'
-- Even across distributed nodes.
COMMIT;
Run concurrent AI agents without interference or compromise
- Each agent gets dedicated throughput that other workloads can’t touch
- Tenant-scoped data separation keeps every agent’s state private
- No shared resources, cross-tenant contention, or coordination overhead
Build with the tools and syntax your agents and developers already know
- Standard SQL means agents and developers start productive on day one
- MCP, pytidb, LangChain, and LlamaIndex integrations out of the box
- Online DDLs and zero-downtime schema changes so shipping never stops
// Connect any AI agent to TiDB
// via the MCP server.
{
"mcpServers": {
"TiDB Cloud": {
"command": "npx",
"args": [
"-y", "mcp-remote",
"https://tidb.link/mcp"
]
}
}
}
// Now your agent can:
// "Create a branch from prod"
// "Run SELECT * FROM agents"
// "Show me slow queries"
Elastic Scale
Unified Engine
Consistent State
Agent Autonomy
Developer Ready
Expand instantly to match demand, then scale to zero when idle
- Autoscaling adapts to agent workloads automatically, from zero to peak
- Instant branching creates isolated environments in milliseconds
- Compute and storage scale independently, no capacity planning required
Query vectors, transactions, and analytics in a single call
- Join vector similarity results directly against transactional data
- One engine replaces your vector store, warehouse, and transaction layer
- No ETL, no middleware, fewer systems to build and maintain
-- One query. Vectors + transactions.
-- No separate vector DB needed.
SELECT
a.agent_id, a.goal, a.status,
m_top.relevance
FROM agent_tasks a
JOIN (
SELECT id,
vec_cosine_distance(
embedding, '[0.12, 0.85, ...]'
) AS relevance
FROM memory_store
ORDER BY vec_cosine_distance(
embedding, '[0.12, 0.85, ...]')
LIMIT 100
) m_top ON a.context_id = m_top.id
WHERE a.status = 'active'
ORDER BY m_top.relevance
LIMIT 10;
Give every agent action a reliable, up-to-date view of the data
- Agent state stays ACID-consistent from one workflow step to the next
- Concurrent agents always read identical state, no matter which node they hit
- Multi-step workflows survive failover without losing progress or replaying actions
-- Agent step 3: update, then read back.
-- The read ALWAYS reflects the write.
BEGIN;
UPDATE agent_state SET
step = 3,
plan = JSON_SET(plan,
'$.next_action', 'execute')
WHERE agent_id = 'a-7f3e'
AND step = 2; -- compare-and-swap
-- Immediate read: no stale state.
SELECT step, plan->>>'$.next_action'
FROM agent_state
WHERE agent_id = 'a-7f3e';
-- Returns: step=3, next_action='execute'
-- Even across distributed nodes.
COMMIT;
Run concurrent AI agents without interference or compromise
- Each agent gets dedicated throughput that other workloads can’t touch
- Tenant-scoped data separation keeps every agent’s state private
- No shared resources, cross-tenant contention, or coordination overhead
Build with the tools and syntax your agents and developers already know
- Standard SQL means agents and developers start productive on day one
- MCP, pytidb, LangChain, and LlamaIndex integrations out of the box
- Online DDLs and zero-downtime schema changes so shipping never stops
// Connect any AI agent to TiDB
// via the MCP server.
{
"mcpServers": {
"TiDB Cloud": {
"command": "npx",
"args": [
"-y", "mcp-remote",
"https://tidb.link/mcp"
]
}
}
}
// Now your agent can:
// "Create a branch from prod"
// "Run SELECT * FROM agents"
// "Show me slow queries"