Spring AI Alibaba Agent Framework is an agent development framework centered around the design philosophy of ReactAgent, enabling developers to build agents with core capabilities such as automatic Context Engineering and Human In The Loop interaction.
For scenarios requiring more complex process control, Agent Framework offers built-in workflows like SequentialAgent, ParallelAgent, RoutingAgent, and LoopAgent based on its Graph Runtime. Developers can also flexibly orchestrate more complex workflows using the Graph API.
-
ReactAgent: Build intelligent agents with reasoning and acting capabilities, following the ReAct (Reasoning + Acting) paradigm for iterative problem-solving.
-
Multi-Agent Orchestration: Compose multiple agents with built-in patterns including
SequentialAgent,ParallelAgent,LlmRoutingAgent, andLoopAgentfor complex task execution. -
Context Engineering: Built-in best practices for context engineering policies to improve agent reliability and performance, including human-in-the-loop, context compaction, context editing, model & tool call limit, tool retry, planning, dynamic tool selection.
-
Graph-based Workflow: Graph based workflow runtime and api for conditional routing, nested graphs, parallel execution, and state management. Export workflows to PlantUML and Mermaid formats.
-
A2A Support: Agent-to-Agent communication support with Nacos integration, enabling distributed agent coordination and collaboration across services.
-
Rich Model, Tool and MCP Support: Leveraging core concepts of Spring AI, supports multiple LLM providers (DashScope, OpenAI, etc.), tool calling, and Model Context Protocol (MCP).
- Requires JDK 17+.
- Choose your LLM provider and get the API-KEY.
There's a ChatBot example provided by the community at examples/chatbot.
- Download the code.
git clone https://github.com/alibaba/spring-ai-alibaba.git
cd examples/chatbot- Start the ChatBot.
mvn spring-boot:run- Chat with ChatBot.
Open the browser and visit http://localhost:8080/chatui/index.html to chat with the ChatBot.
- Add dependencies.
<dependencies>
<dependency>
<groupId>com.alibaba.cloud.ai</groupId>
<artifactId>spring-ai-alibaba-agent-framework</artifactId>
<version>1.1.0.0-M5</version>
</dependency>
<!-- Assume you are going to use DashScope Model. Refer to docs for how to choose model.-->
<dependency>
<groupId>com.alibaba.cloud.ai</groupId>
<artifactId>spring-ai-alibaba-starter-dashscope</artifactId>
<version>1.1.0.0-M5</version>
</dependency>
</dependencies>- Create ChatBot agent
ReactAgent chatBotAgent =
ReactAgent.builder()
.name("SAA")
.model(chatModel)
.instruction(INSTRUCTION)
.enableLogging(true)
.tools(
executeShellCommand,
executePythonCode,
viewTextFile
)
.build();
AssistantMessage message = writerAgent.call("斐波那契数列的第6个数是?");- Overview - High level overview of the framework
- Quick Start - Get started with a simple agent
- Agent Framework Tutorials - Step by step tutorials
- Use Graph API to Build Complex Workflows - In-depth user guide for building multi-agent and workflows
- Spring AI Basics - Ai Application basic concepts, including ChatModel, MCP, Tool, Messages, etc.
This project consists of three core components:
-
Agent Framework: A ReactAgent-based development framework designed for building intelligent agents with built-in context engineering best practices. For scenarios requiring more complex flow control, the Agent Framework leverages the underlying Graph runtime to provide orchestration capabilities, supporting SequentialAgent, ParallelAgent, LoopAgent, RoutingAgent, and more. Developers can also use the Graph API to flexibly orchestrate their own workflows.
-
Graph: The underlying runtime for Agent Framework. We recommend developers to use Agent Framework but it's totally fine to use the Graph API directly. Graph is a low-level workflow and multi-agent orchestration framework that enables developers to implement complex application orchestration. Inspired by LangGraph, it features a rich set of prebuilt nodes and simplified Graph State definitions, making it easier to integrate with low-code platforms and implement popular multi-agent patterns.
-
Spring Boot Starters: Starters integrating Agent Framework with Nacos to provide A2A and dynamic config features.
| Repository | Description | ⭐ |
|---|---|---|
| Spring AI Alibaba Graph | A low-level orchestration framework and runtime for building, managing, and deploying long-running, stateful agents. | |
| Spring AI Alibaba Admin | Local visualization toolkit for the development of agent applications, supporting project management, runtime visualization, tracing, and agent evaluation. | |
| Spring AI Extensions | Extended implementations for Spring AI core concepts, including DashScopeChatModel, MCP registry, etc. | |
| Spring AI Alibaba Examples | Spring AI Alibaba Examples. | |
| JManus | A Java implementation of Manus built with Spring AI Alibaba, currently used in many applications within Alibaba Group. | |
| DataAgent | A natural language to SQL project based on Spring AI Alibaba, enabling you to query databases directly with natural language without writing complex SQL. | |
| DeepResearch | Deep Research implemented based on spring-ai-alibaba-graph. |
- Dingtalk Group (钉钉群), search
130240015687and join. - WeChat Group (微信公众号), scan the QR code below and follow us.
Made with ❤️ by the Spring AI Alibaba Team


