# 10xGraph > 10xGraph is an open-source Python framework for production multi-agent AI. You write the agent, and 10xGraph generates the production server around it: authentication, scoped access control, owner-only threads, rate limits, and Docker and Kubernetes deployment. Memory has two tiers, with hot data in a Redis cache and cold data in PostgreSQL. MIT licensed, made by 10xScale. Formerly named Agentflow. Current version: 0.9.2. Install: `pip install 10xgraph 10xgraph-api`. Source: https://github.com/10xGraph/10xGraph ## Build guides - [Build a production-grade ReAct agent in Python](https://10xgraph.com/build/production-react-agent.md): A support agent that looks up and refunds orders, served as an API with JWT auth, per-user rate limits, Postgres memory, tests and Docker files. ## Get started - [Introduction](https://10xgraph.com/docs/index.md): What 10xGraph is, what it generates for you, and where to start. An open-source Python framework for production multi-agent AI. - [Get Started](https://10xgraph.com/docs/get-started.md): 10xGraph turns a Python agent into a production server and keeps it correct when a run crashes mid-tool. Start here for install, first agent and client. - [Installation](https://10xgraph.com/docs/get-started/installation.md): Install 10xGraph and the API server with pip on Python 3.12 or newer, add provider extras and a checkpointer, verify the CLI, and install the TypeScript client. - [Quickstart](https://10xgraph.com/docs/get-started/first-agent.md): Install 10xGraph, build a support agent in Python, serve it with the API server, then call it with curl and the TypeScript client. - [Project structure](https://10xgraph.com/docs/get-started/project-structure.md): The files that 10xgraph init --template production generates, what each one does, and what every key in the generated 10xgraph.json controls. ## Beginner path - [Beginner Path](https://10xgraph.com/docs/beginner.md): A seven-step beginner path for 10xGraph: build a Python agent with a tool and memory, serve it over an HTTP API, and call it from TypeScript. - [Mental Model](https://10xgraph.com/docs/beginner/mental-model.md): Understand the four core concepts in 10xGraph before writing any code. - [Your First Agent](https://10xgraph.com/docs/beginner/your-first-agent.md): Build and run a minimal 10xGraph graph that calls a real language model. - [Add a Tool](https://10xgraph.com/docs/beginner/add-a-tool.md): Give your agent a callable function with ToolNode and conditional routing. - [Add Memory](https://10xgraph.com/docs/beginner/add-memory.md): Add memory to a 10xGraph agent by compiling the graph with InMemoryCheckpointer, so conversation state persists across calls on the same thread. - [Run with the API](https://10xgraph.com/docs/beginner/run-with-api.md): Run your 10xGraph agent as an HTTP API: scaffold a project with 10xgraph init, start the server with 10xgraph api, and call your agent over HTTP. - [Test with the Playground](https://10xgraph.com/docs/beginner/test-with-playground.md): Use agentflow play to open the hosted playground and inspect your agent in a browser UI. - [Call from TypeScript](https://10xgraph.com/docs/beginner/call-from-typescript.md): Use AgentFlowClient to call your running agent API from a TypeScript application. ## Concepts - [The Big Picture](https://10xgraph.com/docs/concepts.md): How 10xGraph fits together: a Python graph engine, a generated production server and a typed TypeScript client, plus the core execution model. - [Architecture](https://10xgraph.com/docs/concepts/architecture.md): An overview of how 10xGraph packages fit together and how requests flow from client to graph. - [StateGraph](https://10xgraph.com/docs/concepts/state-graph.md): How StateGraph models an agent as nodes, edges and shared state, how compile() produces a runnable graph, and when to use invoke or stream. - [Agents and Tools](https://10xgraph.com/docs/concepts/agents-and-tools.md): How Agent wraps a language model, how ToolNode dispatches tool calls, and all constructor options. - [State and Messages](https://10xgraph.com/docs/concepts/state-and-messages.md): AgentState fields, Message structure, all content block types, ToolResult, and the add_messages reducer. - [Prebuilt Agents and Tools](https://10xgraph.com/docs/concepts/prebuilt-agents-and-tools.md): Ready-made 10xGraph graph patterns, common tools, and handoff helpers. - [Callbacks and Command](https://10xgraph.com/docs/concepts/callbacks-and-command.md): Hook into invocations, validate inputs, recover from errors, and route from inside nodes. - [Dependency Injection](https://10xgraph.com/docs/concepts/dependency-injection.md): Injectable parameters, injectq service containers, and how to wire custom services into 10xGraph nodes and tools. - [Memory: hot and cold](https://10xgraph.com/docs/concepts/memory.md): How PgCheckpointer keeps thread state in a Redis hot cache and PostgreSQL durable history, what is written when, and how the long-term store fits in. - [Replay-safe tools](https://10xgraph.com/docs/concepts/replay-safe-tools.md): Replay-safe tools let a resumed 10xGraph run skip tool calls that already finished, so a crash does not charge a card or send an email twice. - [Checkpointing and Threads](https://10xgraph.com/docs/concepts/checkpointing-and-threads.md): How checkpointers save and restore conversation state across calls using thread IDs. - [Memory and Store](https://10xgraph.com/docs/concepts/memory-and-store.md): How long-term memory works in 10xGraph — memory_tool, retrieval modes, MemoryIntegration, and MemoryConfig. - [Serving Agents](https://10xgraph.com/docs/concepts/serving-agents.md): How 10xgraph.json wires a compiled graph to the API server, plus authentication, authorization, and publisher configuration for production. - [Connecting Clients](https://10xgraph.com/docs/concepts/connecting-clients.md): How the 10xgraph-client TypeScript SDK connects browser and Node.js apps to a 10xGraph API over REST, SSE, and WebSockets. - [Streaming](https://10xgraph.com/docs/concepts/streaming.md): How invoke, stream, and astream work; StreamChunk fields; ResponseGranularity; and how to consume SSE in TypeScript. - [Remote Tools](https://10xgraph.com/docs/concepts/remote-tools.md): How 10xGraph lets a Python graph request tools that execute in a TypeScript client or browser. - [Media and Files](https://10xgraph.com/docs/concepts/media-and-files.md): How to build multimodal messages with images, audio, video, and documents using MediaRef, content blocks, and media stores. - [Production Runtime](https://10xgraph.com/docs/concepts/production-runtime.md): How 10xGraph serves agents in production, including async execution, publisher adapters, and multi-worker deployments. - [Security and Validators](https://10xgraph.com/docs/concepts/security-and-validators.md): How input validators and PromptInjectionValidator work in 10xGraph, what the production template enables, and why they reduce prompt-injection risk. - [Context, IDs, and Background Tasks](https://10xgraph.com/docs/concepts/context-id-background.md): How 10xGraph trims model context with MessageContextManager, generates thread and run IDs, and tracks background tasks with BackgroundTaskManager. - [Extensibility](https://10xgraph.com/docs/concepts/extensibility.md): The abstract base classes — BaseCheckpointer, BaseStore, BaseAuth, BasePublisher, and more — used to extend 10xGraph's storage, auth, and event layers. ## Prebuilt - [Prebuilt agents and tools](https://10xgraph.com/docs/prebuild.md): Prebuilt 10xGraph agents (ReAct, RAG, supervisor, swarm, plan-act-reflect, structured output, audio) and tools you can use as they are or extend. - [ReactAgent](https://10xgraph.com/docs/prebuild/agents/react-agent.md): ReactAgent runs the ReAct MAIN/TOOL loop, executing tool calls in parallel until the LLM returns a final answer. - [PlanActReflectAgent](https://10xgraph.com/docs/prebuild/agents/plan-act-reflect-agent.md): PlanActReflectAgent loops through PLAN, ACT, and REFLECT nodes, critiquing its own output before deciding to iterate or stop. - [SwarmAgent](https://10xgraph.com/docs/prebuild/agents/swarm-agent.md): SwarmAgent lets peer agents hand off control directly via transfer_to_X tools, with no central supervisor coordinating routing. - [SupervisorTeamAgent](https://10xgraph.com/docs/prebuild/agents/supervisor-team-agent.md): SupervisorTeamAgent routes work through a SUPERVISOR node to specialist worker agents, generating its routing prompt from the worker registry. - [RAGAgent](https://10xgraph.com/docs/prebuild/agents/rag-agent.md): RAGAgent retrieves documents with vector search, optionally reranks with CohereReranker or CrossEncoderReranker, then synthesizes an answer. - [StructuredOutputAgent](https://10xgraph.com/docs/prebuild/agents/structured-output-agent.md): StructuredOutputAgent validates LLM output against a Pydantic schema and auto-repairs invalid JSON through a GENERATE/REPAIR loop. - [AudioAgent](https://10xgraph.com/docs/prebuild/agents/audio-agent.md): AudioAgent wraps a Gemini Live LiveAgent for realtime audio-to-audio sessions, driven via arealtime() or realtime(). - [Web Tools](https://10xgraph.com/docs/prebuild/tools/web-tools.md): fetch_url, google_web_search, and vertex_ai_search — prebuilt tools for fetching web pages and running grounded searches. - [File Tools](https://10xgraph.com/docs/prebuild/tools/file-tools.md): file_read, file_write, and file_search — workspace-scoped prebuilt tools for reading, writing, and searching files. - [Memory Tools](https://10xgraph.com/docs/prebuild/tools/memory-tools.md): memory_tool, user_memory_tool, and agent_memory_tool give an agent long-term memory to store, search, update, and delete facts. - [Calculator Tool](https://10xgraph.com/docs/prebuild/tools/calculator.md): safe_calculator evaluates arithmetic expressions with Python's ast module, safely exposing math to an LLM without code execution. - [Handoff Tools](https://10xgraph.com/docs/prebuild/tools/handoff.md): create_handoff_tool and is_handoff_tool build and detect transfer_to_X tools used to route control between agents in a swarm. ## How-to guides - [How to build a graph](https://10xgraph.com/docs/how-to/python/build-a-graph.md): Step-by-step guide to constructing, compiling, and executing a StateGraph with Agent and ToolNode nodes. - [How to configure Agent](https://10xgraph.com/docs/how-to/python/configure-agent.md): Reference for the Agent constructor, including model, provider, system_prompt, tool_node, reasoning_config, retry_config, fallback_models, and output_schema. - [How to use the @tool decorator](https://10xgraph.com/docs/how-to/python/use-tool-decorator.md): Guide to marking Python functions as tools with name, description, tags, provider, capabilities, and metadata using the @tool decorator. - [How to use custom state](https://10xgraph.com/docs/how-to/python/use-custom-state.md): Guide to subclassing AgentState to add application-specific fields and understanding context reducers. - [How to set up checkpointing](https://10xgraph.com/docs/how-to/python/set-up-checkpointing.md): Set up checkpointing: InMemoryCheckpointer for development, SqliteCheckpointer for client agents, and PgCheckpointer (Redis and Postgres) for production. - [How to stream graph responses](https://10xgraph.com/docs/how-to/python/stream-graph.md): Guide to streaming token-by-token output from a compiled graph using astream(), StreamChunk format, ResponseGranularity, and interrupt patterns. - [How to pause a graph for human input with interrupt()](https://10xgraph.com/docs/how-to/python/add-human-approval.md): Use interrupt() inside a node or tool to stop a graph for an approval, a correction, or a choice, then resume it with the answer. - [How to write custom nodes](https://10xgraph.com/docs/how-to/python/use-custom-nodes.md): Write graph nodes as plain Python functions without the Agent class. Covers state and config auto-injection, InjectQ service injection, and return types. - [Choosing the right abstraction](https://10xgraph.com/docs/how-to/python/choose-the-right-abstraction.md): When to use prebuilt agents, the Agent class in a custom graph, or plain function nodes. - [How to use the memory store](https://10xgraph.com/docs/how-to/python/use-memory-store.md): Guide to using QdrantStore and Mem0Store for long-term vector memory, factory helpers, and enabling agent-level memory with MemoryConfig. - [How to use prebuilt agents](https://10xgraph.com/docs/how-to/python/use-prebuilt-agents.md): Guide to ReactAgent, PlanActReflectAgent, StructuredOutputAgent, SupervisorTeamAgent, SwarmAgent, and RAGAgent as compiled graph factories. - [How to use prebuilt tools](https://10xgraph.com/docs/how-to/python/use-prebuilt-tools.md): Use the prebuilt tools in tenxgraph.prebuilt.tools: fetch_url, file tools, safe_calculator, web search, memory tools, and create_handoff_tool. - [How to use publishers](https://10xgraph.com/docs/how-to/python/use-publishers.md): Emit structured events during graph execution with ConsolePublisher, RedisPublisher, KafkaPublisher, RabbitMQPublisher, CompositePublisher, and OtelPublisher. - [How to send traces to Logfire and LangSmith](https://10xgraph.com/docs/how-to/python/send-traces-to-logfire-langsmith.md): Send 10xGraph graph, node, LLM, and tool spans to Pydantic Logfire or LangSmith over OpenTelemetry using Python helpers, publishers, or 10xgraph.json. - [How to use dependency injection](https://10xgraph.com/docs/how-to/python/use-dependency-injection.md): Guide to using InjectQ for binding services and injecting them into node functions, tool functions, and agents via Inject[T] parameter defaults. - [How to use MCP tools](https://10xgraph.com/docs/how-to/python/use-mcp.md): Connect 10xGraph agents to MCP servers with fastmcp.Client over local stdio or HTTP, and pass user context through to the MCP tools. - [How to give an agent skills](https://10xgraph.com/docs/how-to/python/use-skills.md): Add Agent Skills (SKILL.md folders with scripts, references and assets) to an 10xGraph Agent, validate them, and observe when the model uses them. - [Manage conversation context](https://10xgraph.com/docs/how-to/python/use-context-manager.md): How to keep the message history within your LLM's context window using BaseContextManager and MessageContextManager. - [Protect against prompt injection](https://10xgraph.com/docs/how-to/python/protect-against-prompt-injection.md): How to use CallbackManager and PromptInjectionValidator to guard your agent against prompt injection, jailbreak, and other OWASP LLM01:2025 attacks. - [Emit Tool Progress Updates](https://10xgraph.com/docs/how-to/python/emit-tool-progress.md): Learn how to send live progress, errors, and status updates from tools during streaming execution. - [Run work in the background](https://10xgraph.com/docs/how-to/python/run-background-tasks.md): How to fire-and-forget async tasks from inside a node without blocking the graph using BackgroundTaskManager. - [Change the ID strategy](https://10xgraph.com/docs/how-to/python/configure-id-generator.md): How to control the format of thread IDs and run IDs generated by the framework using BaseIDGenerator. - [Route between agents with handoff](https://10xgraph.com/docs/how-to/python/handoff-between-agents.md): How to use create_handoff_tool and Command to transfer control between agents in a multi-agent graph. - [How to build a realtime audio agent](https://10xgraph.com/docs/how-to/python/use-realtime-audio.md): Build a live audio-to-audio agent with AudioAgent and Gemini Live: arealtime sessions, LiveInputQueue, image input, reconnection, and the WebSocket bridge. - [Production](https://10xgraph.com/docs/how-to/production.md): Deploy, configure and secure the 10xGraph API server in production: endpoints, config, auth, rate limiting, storage and environment variables. - [10xgraph.json in production](https://10xgraph.com/docs/how-to/production/agentflow-json.md): The 10xgraph.json fields that matter in production: values to set for auth, persistence, and rate limiting, and defaults that are unsafe under real traffic. - [Environment Variables](https://10xgraph.com/docs/how-to/production/environment-variables.md): Every environment variable the 10xGraph server reads: auth, CORS, logging, security headers, Snowflake IDs, OpenTelemetry, and media storage. - [Auth and Authorization](https://10xgraph.com/docs/how-to/production/auth-and-authorization.md): Production guidance for securing an 10xGraph API with JWT auth, custom auth backends, and permission checks. - [Checkpointing](https://10xgraph.com/docs/how-to/production/checkpointing.md): How to choose, configure, and troubleshoot checkpointers for development and production 10xGraph deployments. - [Multimodal and Vision](https://10xgraph.com/docs/how-to/production/multimodal-and-vision.md): Send images, audio, and documents to a 10xGraph agent over the API. Covers file upload, file_id rewriting, text extraction, and MEDIA_* environment variables. - [Logging and Metrics](https://10xgraph.com/docs/how-to/production/logging-and-metrics.md): Enable structured JSON logging with run correlation and secret redaction, and export 10xGraph counters and timers to OpenTelemetry. - [Deployment](https://10xgraph.com/docs/how-to/production/deployment.md): Production deployment guidance for 10xGraph APIs, including containers, runtime settings, shared persistence, and release checks. - [Deploy on Kubernetes](https://10xgraph.com/docs/how-to/production/kubernetes.md): Generate a Kubernetes Deployment and Service with 10xgraph build --k8s, and set grace periods, probes, and scaling so rolling deploys never cut off a run. - [Backup and restore](https://10xgraph.com/docs/how-to/production/backup-and-restore.md): What 10xGraph persists, how to back up the Postgres tables that hold threads and state, and how to restore or roll back a running deployment safely. - [Production Troubleshooting](https://10xgraph.com/docs/how-to/production/troubleshooting.md): A production-first troubleshooting guide for common 10xGraph deployment, runtime, and connectivity issues. - [API & CLI Overview](https://10xgraph.com/docs/how-to/api-cli.md): Overview of the 10xGraph CLI commands. Install, scaffold, serve, test, evaluate, and deploy agents from the terminal. - [Initialize a Project](https://10xgraph.com/docs/how-to/api-cli/initialize-project.md): Scaffold a new 10xGraph project with the 10xgraph init command, and see what it generates and which files to edit first. - [Run the API Server](https://10xgraph.com/docs/how-to/api-cli/run-api-server.md): Start the 10xGraph API server with 10xgraph api for local development and for production, including the host, port, and 10xgraph.json settings. - [Open the Playground](https://10xgraph.com/docs/how-to/api-cli/open-playground.md): How to use 10xgraph play to start the API and open the hosted playground. - [Configure 10xgraph.json](https://10xgraph.com/docs/how-to/api-cli/configure-agentflow-json.md): Task guide for setting the common 10xgraph.json keys, wiring a checkpointer, store and auth, and keeping separate configs per environment. - [Add JWT authentication](https://10xgraph.com/docs/how-to/api-cli/add-auth.md): Turn on JWT auth in 10xgraph.json, send bearer tokens, read the user in tools, and restrict each thread to its owner. Includes a custom BaseAuth option. - [Configure Rate Limiting](https://10xgraph.com/docs/how-to/api-cli/configure-rate-limiting.md): How to enable and configure the built-in sliding-window rate limiter in the 10xGraph API. - [Deploy with Docker and Kubernetes](https://10xgraph.com/docs/how-to/api-cli/generate-docker-files.md): Generate a Dockerfile, docker-compose.yml and Kubernetes manifest with 10xgraph build, then ship them with a production environment checklist. - [Install Skills](https://10xgraph.com/docs/how-to/api-cli/install-skills.md): Use 10xgraph skills to install bundled coding-agent skills for Codex, Claude, and GitHub Copilot, and validate them against the Agent Skills spec. - [Run Tests](https://10xgraph.com/docs/how-to/api-cli/run-tests.md): How to run your 10xGraph project's test suite using 10xgraph test. Covers coverage, thresholds, keyword filters, and 10xgraph.json configuration. - [Run Evaluations](https://10xgraph.com/docs/how-to/api-cli/run-evals.md): Run agent evaluations with 10xgraph eval. Covers parallel runs, user simulation, EvalPresets, reports, thresholds, and 10xgraph.json configuration. - [Create and configure the client](https://10xgraph.com/docs/how-to/client/create-client.md): Step-by-step guide to installing, instantiating, and verifying AgentFlowClient. - [How to invoke the agent](https://10xgraph.com/docs/how-to/client/invoke-agent.md): Step-by-step guide to calling client.invoke() and handling the response. - [How to stream responses](https://10xgraph.com/docs/how-to/client/stream-responses.md): Step-by-step guide to using client.stream() for real-time token-by-token output. - [How to manage threads](https://10xgraph.com/docs/how-to/client/manage-threads.md): Step-by-step guide to listing, inspecting, updating, and deleting conversation threads and messages. - [How to use the memory API](https://10xgraph.com/docs/how-to/client/use-memory-api.md): Step-by-step guide to storing, searching, and managing long-term memories with AgentFlowClient. - [How to upload files](https://10xgraph.com/docs/how-to/client/upload-files.md): Step-by-step guide to uploading images, audio, and documents and using them in multimodal messages. - [How to send images and documents](https://10xgraph.com/docs/how-to/client/send-images-and-documents.md): Send images, PDFs, and other media to an agent from TypeScript with uploadFile, Message.withImage, Message.withFile, and Message.multimodal. - [How to build a realtime audio session](https://10xgraph.com/docs/how-to/client/realtime-audio.md): Step-by-step guide to capturing microphone audio, streaming it to a live agent with client.realtime(), and playing the agent's PCM16 reply back in the browser. - [Register remote tools](https://10xgraph.com/docs/how-to/client/register-remote-tools.md): Declare trusted remote-tool schemas and register browser-side handlers. - [How to use graph utilities](https://10xgraph.com/docs/how-to/client/graph-utilities.md): Use graph(), graphTools(), graphStateSchema(), observability(), stopGraph(), and fixGraph() on the TypeScript client to inspect and control graphs. ## Testing and QA - [Testing & QA](https://10xgraph.com/docs/qa.md): How to test and evaluate 10xGraph agents: mocked unit tests with TestAgent and QuickTest, and scored evaluation sets and simulated users with the eval command. - [Unit Testing](https://10xgraph.com/docs/qa/unit-test.md): How to unit-test 10xGraph agents without LLM API calls using TestAgent, QuickTest, MockToolRegistry, and the agentflow test CLI command. - [Evaluation](https://10xgraph.com/docs/qa/evaluation.md): Evaluate 10xGraph agents with eval sets, criteria presets, user simulation and parallel runs, then run them in CI with the 10xgraph eval command. - [Building Eval Sets](https://10xgraph.com/docs/qa/evaluation/eval-set.md): How to build evaluation datasets with EvalSetBuilder — single-turn cases, multi-turn conversations, tool call assertions, and loading from files. - [Evaluation Criteria](https://10xgraph.com/docs/qa/evaluation/criteria.md): The 10xGraph evaluation criteria: tool and node matching, ROUGE, semantic response, LLM-as-judge, rubrics, factual accuracy, hallucination, and safety. - [Eval Presets & Configuration](https://10xgraph.com/docs/qa/evaluation/presets.md): Ready-made EvalPresets (tool_usage, response_quality, conversation_flow, comprehensive, safety_check, quick_check) and how to build a custom EvalConfig. - [Evaluation Reports](https://10xgraph.com/docs/qa/evaluation/reports.md): How 10xGraph evaluation reports work — HTML dashboard, JSON output, JUnit XML for CI, ReporterConfig, and how to interpret results. - [User Simulation](https://10xgraph.com/docs/qa/evaluation/user-simulation.md): Test agents with the 10xGraph user simulator and goal-driven conversations using get_scenarios(), UserSimulator, BatchSimulator, and SimulationGoalsCriterion. ## Tutorials - [Tutorials](https://10xgraph.com/docs/tutorials.md): Step-by-step 10xGraph tutorials built from the repository examples, covering agents, tools, streaming, MCP, memory, multi-agent handoff, testing and evaluation. - [Agent Class Pattern](https://10xgraph.com/docs/tutorials/from-examples/agent-class.md): Build a weather-aware assistant using the Agent class, ToolNode, and conditional routing in a StateGraph. - [Custom State](https://10xgraph.com/docs/tutorials/from-examples/custom-state.md): Extend AgentState with domain-specific fields and learn how partial state updates work at invoke time. - [Google GenAI Adapter](https://10xgraph.com/docs/tutorials/from-examples/google-genai.md): Use the GoogleGenAIConverter to integrate raw google-genai SDK calls into 10xGraph's message format, including streaming. - [Tool Decorator](https://10xgraph.com/docs/tutorials/from-examples/tool-decorator.md): Use the @tool decorator to attach metadata, tags, and capabilities to Python functions before registering them with a ToolNode. - [ReAct Agent](https://10xgraph.com/docs/tutorials/from-examples/react-agent.md): Build a persistent ReAct agent with an InMemoryCheckpointer, injectable tool parameters, and custom state. - [ReAct Agent with Validation](https://10xgraph.com/docs/tutorials/from-examples/react-agent-validation.md): Add input validators — prompt-injection guard, content safety, and custom business rules — to a ReAct agent using CallbackManager. - [React Streaming](https://10xgraph.com/docs/tutorials/from-examples/react-streaming.md): Stream graph responses token-by-token using astream with ResponseGranularity, and understand the difference between invoke and stream. - [Stop Stream](https://10xgraph.com/docs/tutorials/from-examples/stop-stream.md): Gracefully stop a running 10xGraph stream from the caller by using app.stop(config). - [Dependency Injection](https://10xgraph.com/docs/tutorials/from-examples/dependency-injection.md): Use InjectQ with 10xGraph to inject shared services such as checkpointers, stores, callbacks, and app-specific dependencies into graph nodes and tools. - [MCP Server](https://10xgraph.com/docs/tutorials/from-examples/mcp-server.md): Expose tools over Model Context Protocol using FastMCP so 10xGraph and other MCP clients can call them remotely. - [MCP Client](https://10xgraph.com/docs/tutorials/from-examples/mcp-client.md): Connect to MCP servers with FastMCP Client, list remote tools, inspect metadata, and invoke tools directly. - [MCP ReAct Agent](https://10xgraph.com/docs/tutorials/from-examples/mcp-react-agent.md): Connect 10xGraph ToolNode to MCP servers so a ReAct graph can call remote tools as part of normal agent execution. - [GitHub MCP](https://10xgraph.com/docs/tutorials/from-examples/github-mcp.md): Use a remote GitHub MCP server from 10xGraph so an agent can list commits and download repository files such as README.md through MCP tools. - [Memory](https://10xgraph.com/docs/tutorials/from-examples/memory.md): Give a 10xGraph agent long-term memory with Agent(memory=MemoryConfig(...)), backed by QdrantStore or a Mem0 store, scoped per user. - [Multimodal](https://10xgraph.com/docs/tutorials/from-examples/multimodal.md): Send images, audio, video, and documents to 10xGraph using media blocks, MediaRef, a media store, and multimodal model configuration. - [Multiagent](https://10xgraph.com/docs/tutorials/from-examples/multiagent.md): Route work between multiple specialized nodes in a single 10xGraph graph using conditional edges and a coordinator-style main node. - [Handoff](https://10xgraph.com/docs/tutorials/from-examples/handoff.md): Build a multi-agent 10xGraph graph where specialized agents transfer control to each other using handoff tools. - [Skills](https://10xgraph.com/docs/tutorials/from-examples/skills.md): Build a 10xGraph graph that loads Agent Skills (SKILL.md) on demand and combines them with normal tools. - [Testing](https://10xgraph.com/docs/tutorials/from-examples/testing.md): Use QuickTest to write low-boilerplate, deterministic tests for 10xGraph graphs without hitting a live model. - [Evaluation](https://10xgraph.com/docs/tutorials/from-examples/evaluation.md): Use 10xGraph's evaluation framework to score tool use, response quality, trajectories, simulation goals, and reporting workflows. - [Graceful Shutdown](https://10xgraph.com/docs/tutorials/from-examples/graceful-shutdown.md): Build a long-running 10xGraph service that handles SIGINT and SIGTERM cleanly, protects initialization and cleanup, and closes graph resources safely. ## Reference - [API reference](https://10xgraph.com/docs/reference.md): Reference for 10xGraph: the Python library, the REST and WebSocket API, the CLI and 10xgraph.json configuration, and the typed TypeScript client. - [Graph](https://10xgraph.com/docs/reference/python/graph.md): StateGraph, CompiledGraph, START, END — the core execution engine of 10xGraph. - [Agent](https://10xgraph.com/docs/reference/python/agent.md): The Agent class — a smart node that handles LLM calls, tool use, memory, skills, and retries. - [LLM Utilities](https://10xgraph.com/docs/reference/python/llm.md): call_llm, create_llm_client, detect_provider, and the default LLM timeout controls exported from tenxgraph.core.llm. - [Skills](https://10xgraph.com/docs/reference/python/skills.md): SkillConfig, SkillMeta and SkillsRegistry — load Agent Skills (agentskills.io) into an Agent and let the model activate them on demand. - [State](https://10xgraph.com/docs/reference/python/state.md): AgentState, custom state, reducers, and the add_messages pattern for 10xGraph. - [Messages](https://10xgraph.com/docs/reference/python/messages.md): Message, ContentBlock types, MediaRef, TokenUsages — the wire format for all agent communication. - [Tools](https://10xgraph.com/docs/reference/python/tools.md): ToolNode — the unified tool registry and executor for local functions, MCP, Composio, and LangChain tools. - [StreamEmitter](https://10xgraph.com/docs/reference/python/stream-emitter.md): Emit live progress, errors, and status updates from tools during streaming execution. - [Checkpointers](https://10xgraph.com/docs/reference/python/checkpointers.md): BaseCheckpointer, InMemoryCheckpointer, PgCheckpointer, SqliteCheckpointer — state persistence for conversation threads. - [Memory stores](https://10xgraph.com/docs/reference/python/memory-stores.md): BaseStore, QdrantStore, Mem0Store — long-term semantic memory for agents. - [Media](https://10xgraph.com/docs/reference/python/media.md): MediaOffloadPolicy, ensure_media_offloaded, BaseMediaStore, MediaRefResolver — handling large binary content in agent messages. - [Publishers](https://10xgraph.com/docs/reference/python/publishers.md): Reference for ConsolePublisher, RedisPublisher, KafkaPublisher, RabbitMQPublisher, OtelPublisher, LogfirePublisher, and LangsmithPublisher event publishers. - [Realtime](https://10xgraph.com/docs/reference/python/realtime.md): API reference for realtime audio-to-audio, including LiveInputQueue, RealtimeConfig, VADConfig, ReconnectConfig, AudioAgent, and the WebSocket bridge protocol. - [Testing](https://10xgraph.com/docs/reference/python/testing.md): TestAgent, QuickTest, TestResult, MockMCPClient — test 10xGraph graphs without making LLM API calls. - [Evaluation](https://10xgraph.com/docs/reference/python/evaluation.md): AgentEvaluator, EvalSet, EvalCase, EvalConfig, EvalReport and TrajectoryCollector — how a scored evaluation run is wired together. - [Evaluation criteria](https://10xgraph.com/docs/reference/python/evaluation-criteria.md): Constructor signatures, defaults and scoring behaviour for every built-in evaluation criterion class in tenxgraph.qa.evaluation.criteria. - [Evaluation harness](https://10xgraph.com/docs/reference/python/evaluation-harness.md): EvaluationRunner, ReporterManager, ExecutionResult and the pytest helpers for writing 10xGraph eval tests, with real signatures and defaults. - [Context Manager](https://10xgraph.com/docs/reference/python/context-manager.md): BaseContextManager and MessageContextManager — trim and bound the agent's message history before each LLM call. - [Callback Manager](https://10xgraph.com/docs/reference/python/callback-manager.md): CallbackManager, BeforeInvokeCallback, AfterInvokeCallback, OnErrorCallback, BaseValidator, PromptInjectionValidator — hook into every LLM, tool, and MCP - [Lifecycle Callbacks](https://10xgraph.com/docs/reference/python/lifecycle-callbacks.md): GraphLifecycleHook, GraphLifecycleContext — hook into graph-level events (start, end, error, interrupt, resume, checkpoint, state update). - [Background Task Manager](https://10xgraph.com/docs/reference/python/background-tasks.md): BackgroundTaskManager — launch and track asyncio tasks from node functions without blocking the graph response. - [ID Generator](https://10xgraph.com/docs/reference/python/id-generator.md): BaseIDGenerator and built-in implementations — control the format of thread IDs, run IDs, and other identifiers generated by the framework. - [Command & Handoff](https://10xgraph.com/docs/reference/python/command-handoff.md): Command and create_handoff_tool — control graph routing from inside nodes and transfer execution between agents. - [Conventions and permissions](https://10xgraph.com/docs/reference/rest-api/conventions.md): The 10xGraph REST API response envelope, HTTP and WebSocket authentication, the endpoint permission table, and the HTTP status codes the server returns. - [Graph endpoints](https://10xgraph.com/docs/reference/rest-api/graph.md): Reference for the 10xGraph REST endpoints that invoke, stream, stop, and inspect a graph, with request bodies, responses, and auth requirements. - [Live WebSocket endpoints](https://10xgraph.com/docs/reference/rest-api/live.md): Reference for the WS /v1/graph/live WebSocket endpoint that bridges audio to a realtime AudioAgent (Gemini Live): init frame, binary and JSON frames, auth. - [Thread endpoints](https://10xgraph.com/docs/reference/rest-api/threads.md): Reference for the 10xGraph REST endpoints that read and write thread state and messages, with request fields, responses, and auth requirements. - [Memory store endpoints](https://10xgraph.com/docs/reference/rest-api/memory-store.md): Reference for /v1/store — storing, searching, listing, updating, deleting, and forgetting memories through the 10xGraph API server. - [File upload endpoints](https://10xgraph.com/docs/reference/rest-api/files.md): Reference for the 10xGraph REST endpoints that upload files and retrieve them, with request fields, responses, and authentication requirements. - [Observability endpoints](https://10xgraph.com/docs/reference/rest-api/observability.md): Reference for the GET /v1/observability/{thread_id} endpoint that reconstructs a run trace with spans, events, and token usage. - [Eval endpoints](https://10xgraph.com/docs/reference/rest-api/evals.md): Reference for the eval run listing and detail endpoints that serve 10xgraph eval reports over HTTP, including their public, unauthenticated status. - [Health check endpoint](https://10xgraph.com/docs/reference/rest-api/ping.md): GET /ping is the unauthenticated health check of the 10xGraph API server, used for Kubernetes probes, Docker HEALTHCHECK and load balancers. - [CLI reference](https://10xgraph.com/docs/reference/api-cli/commands.md): Every 10xGraph CLI command with its purpose, usage line, options and defaults: init, api, play, dev, build, eval, test, skills, audit, config, demo and version. - [10xgraph.json reference](https://10xgraph.com/docs/reference/api-cli/configuration.md): Every 10xgraph.json key the server and CLI read, with types, defaults and examples, the rate_limit sub-keys, and the environment variables the API server uses. - [Authentication](https://10xgraph.com/docs/reference/api-cli/auth.md): How to configure JWT auth or a custom auth backend for the 10xGraph API. - [Rate Limiting](https://10xgraph.com/docs/reference/api-cli/rate-limiting.md): Complete reference for the rate_limit block in 10xgraph.json: the backends, limits, and every option for throttling requests to the 10xGraph API server. - [Environment Variables](https://10xgraph.com/docs/reference/api-cli/environment.md): Reference for every environment variable the 10xGraph API server recognizes, grouped by area such as auth, CORS, logging, and Snowflake ID settings. - [Thread Name Generator](https://10xgraph.com/docs/reference/api-cli/thread-name-generator.md): 10xGraph can optionally generate user-friendly thread names for new conversation threads. - [ID Generator](https://10xgraph.com/docs/reference/api-cli/id-generator.md): 10xGraph uses ID generators to create unique identifiers for threads, messages, and other persisted records. - [AgentFlowClient](https://10xgraph.com/docs/reference/client/agentflow-client.md): Complete reference for the AgentFlowClient class — the main entry point for calling 10xGraph from TypeScript or JavaScript. - [Graph control](https://10xgraph.com/docs/reference/client/graph.md): Reference for graph-control methods on the TypeScript client: ping, graph, graphTools, observability, graphStateSchema, stopGraph, fixGraph, and setup. - [Message](https://10xgraph.com/docs/reference/client/message.md): Reference for the Message class and all content block types in the 10xGraph TypeScript client. - [invoke()](https://10xgraph.com/docs/reference/client/invoke.md): Reference for the AgentFlowClient.invoke() method — send messages and receive the final state. - [stream()](https://10xgraph.com/docs/reference/client/stream.md): Reference for the AgentFlowClient.stream() method — receive real-time streaming chunks from the agent. - [realtime()](https://10xgraph.com/docs/reference/client/realtime.md): Reference for the AgentFlowClient.realtime() method and the RealtimeSession class — a transport-only audio-to-audio client for the /v1/graph/live WebSocket. - [Threads](https://10xgraph.com/docs/reference/client/threads.md): Reference for all thread, state, and message methods on AgentFlowClient. - [Memory](https://10xgraph.com/docs/reference/client/memory.md): Reference for all memory store methods on AgentFlowClient, store, search, list, update, and delete memories. - [Files](https://10xgraph.com/docs/reference/client/files.md): Reference for file upload and media access methods on AgentFlowClient. - [Auth](https://10xgraph.com/docs/reference/client/auth.md): Reference for all authentication options available in AgentFlowClient. ## Troubleshooting - [Troubleshooting](https://10xgraph.com/docs/troubleshooting.md): Find the right 10xGraph troubleshooting page by symptom: install failures, provider keys, server startup, client connections, playground and error codes. - [Installation Troubleshooting](https://10xgraph.com/docs/troubleshooting/installation.md): Symptoms, causes, and fixes for common 10xGraph installation and environment setup issues. - [API Server Troubleshooting](https://10xgraph.com/docs/troubleshooting/api-server.md): Symptoms, causes, and fixes for common 10xGraph API server startup and runtime issues. - [Client Troubleshooting](https://10xgraph.com/docs/troubleshooting/client.md): Symptoms, causes, and fixes for common 10xGraph TypeScript and HTTP client integration issues. - [Playground Troubleshooting](https://10xgraph.com/docs/troubleshooting/playground.md): Symptoms, causes, and fixes for hosted playground connection issues when using agentflow play. - [Error Codes Reference](https://10xgraph.com/docs/troubleshooting/error-codes.md): Complete reference for all 10xGraph error codes, exception hierarchy, and structured error responses. ## Learn more - [AI Agent Use Cases: Build with 10xGraph](https://10xgraph.com/docs/use-cases.md): Reference architectures for customer support, data extraction, coding, research and RAG agents built with 10xGraph, with the tools and failure modes of each. - [Build a Customer Support AI Agent in Python](https://10xgraph.com/docs/use-cases/customer-support-agent.md): Reference architecture for a production customer support AI agent in Python. Intent routing, ticket lookup, refund tools, and human handoff with 10xGraph. - [Build a Data Extraction AI Agent in Python](https://10xgraph.com/docs/use-cases/data-extraction-agent.md): How to build a structured data extraction AI agent in Python. Pull entities, fields, and relationships from unstructured text with 10xGraph + Pydantic. - [Build a Coding AI Agent in Python](https://10xgraph.com/docs/use-cases/coding-agent.md): How to build a coding AI agent in Python. Code generation, file editing, test running, and the real-world tools production coding agents need. - [Build a Research AI Agent in Python](https://10xgraph.com/docs/use-cases/research-agent.md): How to build a research AI agent in Python. Web search, source verification, synthesis, and citations. With 10xGraph code and production guardrails. - [Build a RAG AI Agent in Python: Done Right](https://10xgraph.com/docs/use-cases/rag-agent.md): How to build a RAG AI agent in Python that scales beyond chat-with-your-PDFs. Hybrid retrieval, reranking, citations, and 10xGraph code. - [10xGraph Integrations: FastAPI, Next.js, Postgres](https://10xgraph.com/docs/integrations.md): Guides for using 10xGraph with FastAPI, Next.js, CopilotKit and Postgres, plus the storage, messaging and tracing backends the core library supports. - [10xGraph with FastAPI: Embed an Agent in Your App](https://10xgraph.com/docs/integrations/agentflow-with-fastapi.md): How to embed an 10xGraph agent in your existing FastAPI service. Mount the runtime, add custom routes, share auth, and stream responses. - [10xGraph with Next.js: Build a Streaming Agent Frontend](https://10xgraph.com/docs/integrations/agentflow-with-nextjs.md): How to call a 10xGraph Python agent from a Next.js frontend with streaming, auth, and typed responses. Server actions, route handlers, and 10xGraph. - [10xGraph with CopilotKit: Serve Your Agent over AG-UI](https://10xgraph.com/docs/integrations/agentflow-with-copilotkit.md): Turn on the AG-UI endpoint in the 10xGraph API server and connect a CopilotKit frontend, with streaming chat, tool calls, frontend tools, and shared state. - [10xGraph with Postgres: Durable Agent Threads](https://10xgraph.com/docs/integrations/agentflow-with-postgres.md): How to wire 10xGraph's PgCheckpointer to a Postgres + Redis backend for durable agent threads. Setup, schema, sizing, and operational patterns. - [Providers](https://10xgraph.com/docs/providers.md): 10xGraph supports OpenAI, Google (Gemini, Vertex AI) and Anthropic (direct, Vertex AI, Bedrock), plus any OpenAI-compatible endpoint, via one Agent interface. - [OpenAI](https://10xgraph.com/docs/providers/openai.md): Configure the OpenAI provider in 10xGraph to run GPT and reasoning models, including the install extra, API key, and model settings. - [Google](https://10xgraph.com/docs/providers/google.md): Configure the Google provider to run Gemini models via Google AI Studio or Vertex AI. - [Anthropic](https://10xgraph.com/docs/providers/anthropic.md): Configure the Anthropic provider to run Claude models via the Claude API, Google Cloud Vertex AI, or Amazon Bedrock. - [Skills](https://10xgraph.com/docs/skills.md): Install the bundled 10xGraph skill for Codex, Claude or GitHub Copilot so your coding assistant knows the framework, or give your own agents skills. - [10xGraph vs LangGraph, CrewAI, AutoGen: Compared](https://10xgraph.com/docs/compare.md): Sourced comparisons of 10xGraph with LangGraph, CrewAI, AutoGen, LlamaIndex Agents and Google ADK, led by the production layer each framework includes. - [10xGraph vs LangGraph: Production Python Alternative](https://10xgraph.com/docs/compare/agentflow-vs-langgraph.md): 10xGraph vs LangGraph compared on the production layer, with sources. Auth, thread isolation, replay-safe tools, versioned writes, timeouts, and deploy files. - [10xGraph vs CrewAI: Graphs vs Role-Based Crews](https://10xgraph.com/docs/compare/agentflow-vs-crewai.md): 10xGraph vs CrewAI compared with sources. Production server, auth, thread isolation, replay-safe tools and timeouts, plus where CrewAI is the better pick. - [10xGraph vs Microsoft AutoGen: Python Compared](https://10xgraph.com/docs/compare/agentflow-vs-autogen.md): 10xGraph vs Microsoft AutoGen compared with sources. AutoGen is in maintenance mode, so this covers the production layer and what Microsoft recommends instead. - [10xGraph vs LlamaIndex Agents: Runtime vs RAG](https://10xgraph.com/docs/compare/agentflow-vs-llamaindex-agents.md): 10xGraph vs LlamaIndex Agents compared with sources: server, auth, thread isolation, replay-safe tools, and using LlamaIndex retrieval inside 10xGraph. - [10xGraph vs Google ADK: Open-Source Alternative](https://10xgraph.com/docs/compare/agentflow-vs-google-adk.md): 10xGraph vs Google ADK compared with sources: API server, auth, thread isolation, replay-safe tools, sessions, and where ADK is the better pick. ## Glossary - [AI Agent Glossary](https://10xgraph.com/docs/glossary.md): Plain definitions of AI agent terms, from ReAct agents and state graphs to MCP, RAG, durable execution and idempotent tool calls, with Python examples. - [What Is an AI Agent? Definition and Python Guide (2026)](https://10xgraph.com/docs/glossary/what-is-an-ai-agent.md): An AI agent is a program that uses an LLM to perceive input, reason, and act in a loop until a goal is met. Learn the patterns and build one in Python. - [What Is a ReAct Agent? Python Guide with Code Examples](https://10xgraph.com/docs/glossary/what-is-a-react-agent.md): A ReAct agent alternates reasoning and acting: it calls tools, observes the results, and reasons again. Learn how it works and build one in Python. - [What Is Multi-Agent Orchestration? Python Guide](https://10xgraph.com/docs/glossary/what-is-multi-agent-orchestration.md): Multi-agent orchestration coordinates several AI agents toward one goal using explicit handoffs and control flow. See the patterns with Python examples. - [What Is a State Graph? AI Agent Architecture Guide](https://10xgraph.com/docs/glossary/what-is-a-state-graph.md): A state graph models AI agent workflows as nodes (processing steps) and edges that move state between them. See how it works with Python examples. - [What Is Agent Memory? Types and Python Implementation](https://10xgraph.com/docs/glossary/what-is-agent-memory.md): Agent memory is how an AI agent stores and retrieves information across turns, sessions, and restarts. See the three memory types and Python code. - [What Is the Model Context Protocol (MCP)? Guide for AI Agents](https://10xgraph.com/docs/glossary/what-is-model-context-protocol.md): The Model Context Protocol (MCP) is an open standard that connects AI agents to external tools and data through one interface. Learn how to use it in Python. - [What Is RAG (Retrieval-Augmented Generation)? Python Guide](https://10xgraph.com/docs/glossary/what-is-retrieval-augmented-generation.md): RAG (Retrieval-Augmented Generation) has an agent retrieve relevant documents before it answers. Learn how it works and build a RAG agent in Python. - [What Is AI Agent Streaming? SSE Guide for Python](https://10xgraph.com/docs/glossary/what-is-agent-streaming.md): AI agent streaming sends responses token-by-token to a frontend over SSE instead of waiting for the full reply. Learn how it works in Python. - [What Is Durable Execution for AI Agents?](https://10xgraph.com/docs/glossary/what-is-durable-execution.md): Durable execution saves a run's progress so it resumes after a crash instead of restarting. See what it covers for AI agents and how 10xGraph implements it. - [What Is an Idempotent Tool Call?](https://10xgraph.com/docs/glossary/what-is-an-idempotent-tool-call.md): An idempotent tool call has the same effect whether it runs once or many times. See why agents need it, how idempotency keys work and how 10xGraph helps. ## Project - [Project and releases](https://10xgraph.com/docs/project.md): How 10xGraph is run: MIT license, maintained by 10xScale, with a changelog, roadmap, security reporting, support channels and a contributing guide. - [Upgrade to 1.0](https://10xgraph.com/docs/project/upgrade-to-1.0.md): Migration guide from 10xGraph 0.8 and 0.9 to 1.0, covering the four breaking changes and the new defaults that change runtime behaviour. - [Roadmap and known gaps](https://10xgraph.com/docs/project/roadmap.md): What 10xGraph does not do yet, which surfaces are incomplete, and where dated release planning actually lives. - [Security policy](https://10xgraph.com/docs/project/security.md): How to report a vulnerability in 10xGraph, what response to expect, which versions receive fixes, and which behaviours are by design rather than bugs. - [Getting help](https://10xgraph.com/docs/project/support.md): Where to ask questions, how to file a good bug report for 10xGraph, and what information to collect before you do. - [Contributing](https://10xgraph.com/docs/project/contributing.md): How to contribute to 10xGraph and to these docs, including the local setup, the writing conventions, and the checks that must pass before a pull request merges. ## Blog - [Agentflow is now 10xGraph](https://10xgraph.com/blog/introducing-10xgraph.md): Agentflow is now 10xGraph. Why we renamed it, what the framework is, what stays the same in your code, what changes in package names, and the honest gaps. - [Your agent charged the card twice: making tool calls replay-safe](https://10xgraph.com/blog/your-agent-charged-the-card-twice.md): Why a crash mid-node re-runs tools that already fired, why the usual fixes fall short, and how 10xGraph's tool ledger and versioned writes close the gap. - [Hot and cold agent memory: why 10xGraph puts Redis in front of Postgres](https://10xgraph.com/blog/hot-and-cold-agent-memory.md): How PgCheckpointer splits agent state between a Redis hot cache and versioned Postgres history, keeps them consistent, and behaves when either one fails. ## Optional - [Full content](https://10xgraph.com/llms-full.txt): every doc and post in one file - [Changelog](https://10xgraph.com/changelog): release notes for every published version