Skip to main content

Cortex documentation

Cortex runs stateful AI agents on Convex. Your application supplies verified identity, submits user input and renders retained output. The backend owns inference, tools, the executable transcript and asynchronous memory.

These docs describe the upcoming 0.39.0 SDK, CLI and AI SDK integration. Package publication is a separate release step. Before publication, use matching locally built package archives; installation examples that select a registry version apply once that version is available. Application templates use an independent version channel.

Build an application​

  1. Install the backend into a new or existing Convex host.
  2. Configure identity, grants and a published Agent.
  3. Connect the TypeScript runtime client, or use AI SDK 7 with React.
  4. Observe response, memory and graph status independently; reconnect to the retained run.

Understand the runtime​

TopicStart here
Agent, Workflow and Gateway ownershipSystem overview
Canonical history and tracked editsConversation history
Pending context and consistencyMemory orchestration
Every model call and its budgetModel policy
Private files and durable generationAssets and media
Verified identity and revocationAuthentication
Optional Neo4j and Memgraph projectionGraph integration

The lower-level SDK reference remains available for explicit memory APIs and server administration. Ordinary applications use the remote runtime path. The Python SDK is archived; this runtime has a TypeScript client.