Skip to content

Commit 5d6d29d

Browse files
add gradio quickstart (#100)
1 parent 0a082b0 commit 5d6d29d

File tree

2 files changed

+45
-2
lines changed

2 files changed

+45
-2
lines changed

docs/en/notes/guide/agent/DataFlow-AgentPipelineOrchestration.md

Lines changed: 21 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -166,4 +166,24 @@ class TextMinHashDeduplicator(OperatorABC):
166166
return [output_key]
167167
```
168168

169-
Users can personalize configuration by modifying the parameters in `ChatAgentRequest`.
169+
Users can personalize configuration by modifying the parameters in `ChatAgentRequest`.
170+
171+
172+
### 6. Experience DataFlow-Agent via Gradio
173+
174+
#### Startup Methods
175+
176+
##### Method 1: Direct Startup
177+
After installing the `dataflow` package, directly start the Gradio frontend and backend using `dataflow webui agent`. The default port is 7862.
178+
179+
##### Method 2: Separate Frontend and Backend Startup
180+
181+
- Start the frontend:
182+
```bash
183+
python test/test_agent_fronted_gradio.py
184+
```
185+
186+
- Start the backend:
187+
```bash
188+
python test/test_dataflow_agent_with_ui.py
189+
```

docs/zh/notes/guide/agent/DataFlow-AgentPipelineOrchestration.md

Lines changed: 24 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -172,4 +172,27 @@ class TextMinHashDeduplicator(OperatorABC):
172172
return [output_key]
173173
```
174174

175-
用户可通过修改`ChatAgentRequest`中参数实现个性化配置。
175+
用户可通过修改`ChatAgentRequest`中参数实现个性化配置。
176+
177+
178+
### 6. 通过Gradio体验DataFlow-Agent
179+
#### 启动方式
180+
##### 方式一:直接启动
181+
安装好`dataflow`包之后,通过 `dataflow webui agent` 直接启动 Gradio 前后端,默认端口为 7862。
182+
##### 方式二:前后端分离启动
183+
- 启动前端:
184+
``` bash
185+
python test/test_agent_fronted_gradio.py
186+
```
187+
188+
- 启动后端:
189+
190+
``` bash
191+
python test/test_dataflow_agent_with_ui.py
192+
```
193+
194+
195+
196+
197+
198+

0 commit comments

Comments
 (0)