Skip to content

Commit 775f429

Browse files
committed
feat: agent runner
1 parent 5efff9f commit 775f429

File tree

6 files changed

+110
-2
lines changed

6 files changed

+110
-2
lines changed

.vitepress/config.mjs

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -158,8 +158,9 @@ export default defineConfig({
158158
{ text: "MCP", link: "/mcp" },
159159
{ text: "网页搜索", link: "/websearch" },
160160
{ text: "知识库", link: "/knowledge-base" },
161-
{ text: "沙箱化代码执行器(beta)", link: "/code-interpreter" },
162161
{ text: "自定义规则", link: "/custom-rules" },
162+
{ text: "Agent 执行器", link: "/agent-runner" },
163+
{ text: "沙箱化代码执行器(beta)", link: "/code-interpreter" },
163164
],
164165
},
165166
{
@@ -366,8 +367,9 @@ export default defineConfig({
366367
{ text: "MCP", link: "/mcp" },
367368
{ text: "Web Search", link: "/websearch" },
368369
{ text: "Knowledge Base", link: "/knowledge-base" },
369-
{ text: "Sandboxed Code Interpreter (beta)", link: "/code-interpreter" },
370370
{ text: "Custom Rules", link: "/custom-rules" },
371+
{ text: "Agent Runner", link: "/agent-runner" },
372+
{ text: "Sandboxed Code Interpreter (beta)", link: "/code-interpreter" },
371373
],
372374
},
373375
{

en/use/agent-runner.md

Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
# Agent Runner
2+
3+
The Agent Runner is a component in AstrBot used to execute Agents.
4+
5+
Starting from version v4.7.0, we have migrated three providers—Dify, Coze, and Alibaba Cloud Bailian Application—to the Agent Runner layer, reducing some conflicts with AstrBot's existing features. Rest assured, if you upgrade from an older version to v4.7.0, you don't need to take any action as AstrBot will automatically migrate for you.
6+
7+
AstrBot currently has four built-in Agent Runners:
8+
9+
- AstrBot Built-in Agent Runner
10+
- Dify Agent Runner
11+
- Coze Agent Runner
12+
- Alibaba Cloud Bailian Application Agent Runner
13+
14+
By default, the AstrBot Built-in Agent Runner is the default runner.
15+
16+
## Why Abstract the Agent Runner
17+
18+
In earlier versions, platforms with "built-in Agent capabilities" like Dify, Coze, and Alibaba Cloud Bailian Application were integrated into AstrBot as regular Chat Providers. In practice, we found that they are fundamentally different from traditional Chat Providers that "only handle text completion". Forcing them into the same layer caused many design and usage conflicts. Therefore, starting from v4.7.0, we abstracted them into independent Agent Runners.
19+
20+
From an architectural perspective, you can understand it as:
21+
22+
- Chat Provider is responsible for "talking";
23+
- Agent Runner is responsible for "thinking + doing".
24+
25+
The Agent Runner calls the Chat Provider's interface and, based on the Chat Provider's response, performs multi-turn "perceive → plan → execute action → observe result → re-plan" loops.
26+
27+
A Chat Provider is essentially a `single-turn completion interface`, taking prompt + conversation history + tool list as input and outputting model responses (text, tool call instructions, etc.).
28+
29+
An Agent Runner is typically a `loop` that receives user intent, context, and environment state, makes plans based on strategy/model (Plan), selects and invokes tools (Act), reads results from the environment (Observe), understands the results again, updates internal state, decides the next action, and repeats this process until the task is completed or times out.
30+
31+
![image](/source/images/use/agent-runner/agent-arch.svg)
32+
33+
LLMOps platforms like Dify, Coze, and Bailian Application have this loop built-in. If you treat them as regular Chat Providers, it will conflict with AstrBot's built-in Agent Runner functionality.
34+
35+
## Usage
36+
37+
By default, the AstrBot Built-in Agent Runner is the default runner. Using the default runner can already meet most needs, and you can use AstrBot's MCP, knowledge base, web search, and other features.
38+
39+
If you need to use the capabilities of LLMOps platforms like Dify, Coze, or Bailian Application, you can create an Agent Runner and select the corresponding provider.
40+
41+
## Creating an Agent Runner
42+
43+
![image](/source/images/use/agent-runner/image-1.png)
44+
45+
In the WebUI, click "Model Provider" -> "Add Provider", select "Agent Runner", choose the LLMOps platform you want to connect to, and fill in the relevant information.
46+
47+
## Changing the Default Agent Runner
48+
49+
![image](/source/images/use/agent-runner/image.png)
50+
51+
In the WebUI, click "Configuration" -> "Agent Execution Method", change the runner type to the Agent Runner type you just created, then select `XX Agent Runner Provider ID` as the ID of the Agent Runner provider you just created, and click save.
Lines changed: 4 additions & 0 deletions
Loading
158 KB
Loading
131 KB
Loading

0 commit comments

Comments
 (0)