Files
Airtep/gig-poc/docs/DEMO.md
2026-04-01 14:19:25 +08:00

70 lines
1.9 KiB
Markdown
Raw Permalink Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# Demo 说明
## 一键启动
```bash
cd gig-poc
sh infrastructure/scripts/dev-up.sh
```
默认会自动完成:
- 启动容器并健康检查
- bootstrap 样本数据
- 闭环验收(抽取 -> 入库 -> 匹配 -> 解释)
- 导出 `docs/openapi.json`
- 可选压测并生成 `docs/CAPACITY_BASELINE.md``RUN_BASELINE_ON_UP=true`
## 演示步骤
1. 打开 `http://127.0.0.1:5173`
2. 在“岗位测试页”输入岗位文本并点击“抽取岗位”
3. 点击“入库并匹配工人”,观察 TopN 匹配与推荐原因
4. 在“工人测试页”输入工人文本并点击“抽取工人画像”
5. 点击“入库并匹配岗位”,观察 TopN 匹配与推荐原因
6. 打开“数据浏览页”查看已入库样本
7. 打开“系统状态页”查看健康状态,必要时重新执行 bootstrap
## 生产环境启动
```bash
cd gig-poc
sh infrastructure/scripts/prod-up.sh
```
## 生产环境停止
```bash
cd gig-poc
sh infrastructure/scripts/prod-down.sh
```
## OpenAPI 交接文件导出
```bash
cd gig-poc
sh infrastructure/scripts/export-openapi.sh
```
## OpenAPI 固化入库(离线)
```bash
cd gig-poc
sh infrastructure/scripts/freeze-openapi.sh
```
## 一键闭环验收(可单独执行)
```bash
cd gig-poc
sh infrastructure/scripts/acceptance-e2e.sh
```
## 容量基线压测(可单独执行)
```bash
cd gig-poc
sh infrastructure/scripts/load-baseline.sh
```
## 高并发演示建议
1. 同步匹配:调用 `POST /poc/match/workers` 观察实时结果。
2. 异步匹配削峰:调用 `POST /poc/match/workers/async` 获取 `task_id`
3. 轮询结果:调用 `GET /poc/match/queue/{task_id}` 直到 `status=done`
4. 打开 `GET /poc/ops/system/metrics` 观察缓存命中率、队列积压和限流熔断状态。
## 演示建议
- 先演示系统状态页,确认健康与 bootstrap 正常
- 再演示岗位找人、人找岗位两个闭环
- 最后展开 OpenAPI 文档讲接口交接方式