docs(mcp): GUIDE/README 全面改教 arcrun_*,清掉死 u6u_ 工具名
死文件治理:GUIDE.md(25 處)與 README.md(21 處)仍在教 u6u_* 工具名, 含本 PR 已刪的 4 個 tool(deploy/execute/get/list_workflows),下個 CC 照著走會撞牆。 - 全部 u6u_* → 現役 arcrun_*(component/tag/gui 那批用新名) - 已刪 tool 改指現役:execute→run、deploy→push、get/list_workflows→crud 版 - 修正因換工具而失真的流程與參數:沙盒測試段改為 arcrun_validate_yaml(部署前 schema 驗證)→ arcrun_push_workflow(部署)→ arcrun_run_workflow(觸發,帶 api_key/name/input);get_workflow 參數 workflow_id→name - 順帶把兩處品牌 prose "u6u" 改 "Arcrun" - grep 確認兩檔零 u6u brand.ts:釐清 ARCRUN_TOOL_PREFIX 覆蓋僅內部 rebrand 過渡 / 測試鉤子, Workers runtime 無 process 全域基本不生效、勿當對外特性。 Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_015d5jDbuqT5Htwv3Q88XXKk
This commit is contained in:
+29
-25
@@ -53,40 +53,41 @@ Claude Code 進此資料夾就連對的 MCP。`acr init` 也會自動順帶跑
|
||||
|
||||
| Tool | 說明 |
|
||||
|------|------|
|
||||
| `u6u_get_component_guide` | **開發新零件前必須先呼叫。** 取得 TinyGo 開發指引,包含白名單 import、禁止行為、contract YAML 範例、本地測試指令。 |
|
||||
| `u6u_search_components` | 用自然語言語意搜尋零件庫。例如:「查詢 Google Sheets 資料」、「發送 LINE 訊息」。回傳零件清單含 canonical_id、描述、評分。 |
|
||||
| `u6u_get_component` | 取得指定零件的完整合約(input_schema、output_schema、gherkin_tests、評分統計等)。 |
|
||||
| `u6u_publish_component` | 提交 TinyGo WASM 零件。需提供 `contract`(合約物件)與 `wasm_base64`(編譯後的 .wasm base64)。Registry 自動執行沙盒驗收。 |
|
||||
| `arcrun_get_component_guide` | **開發新零件前必須先呼叫。** 取得 TinyGo 開發指引,包含白名單 import、禁止行為、contract YAML 範例、本地測試指令。 |
|
||||
| `arcrun_search_components` | 用自然語言語意搜尋零件庫。例如:「查詢 Google Sheets 資料」、「發送 LINE 訊息」。回傳零件清單含 canonical_id、描述、評分。 |
|
||||
| `arcrun_get_component` | 取得指定零件的完整合約(input_schema、output_schema、gherkin_tests、評分統計等)。 |
|
||||
| `arcrun_publish_component` | 提交 TinyGo WASM 零件。需提供 `contract`(合約物件)與 `wasm_base64`(編譯後的 .wasm base64)。Registry 自動執行沙盒驗收。 |
|
||||
|
||||
### 工作流執行
|
||||
|
||||
| Tool | 說明 |
|
||||
|------|------|
|
||||
| `u6u_execute_workflow` | 在沙盒中執行工作流。輸入 `triplets`(三元組陣列)與 `context`,用於部署前驗證。 |
|
||||
| `u6u_deploy_workflow` | 將工作流 YAML 部署至雲端引擎。輸入 `yaml_content`。 |
|
||||
| `arcrun_validate_yaml` | 部署前驗證工作流 YAML 的 schema。輸入 `yaml_content`。 |
|
||||
| `arcrun_push_workflow` | 將工作流 YAML 部署至雲端引擎。輸入 `api_key` 與 `yaml_content`。 |
|
||||
| `arcrun_run_workflow` | 觸發已部署的工作流執行。輸入 `api_key`、`name`,選填 `input`(帶進 trigger context)。 |
|
||||
|
||||
### 工作流管理
|
||||
|
||||
| Tool | 說明 |
|
||||
|------|------|
|
||||
| `u6u_list_workflows` | 列出已部署的工作流。可傳入選填的 `tag` 參數篩選。 |
|
||||
| `u6u_get_workflow` | 取得指定工作流的 metadata。輸入 `workflow_id`。 |
|
||||
| `arcrun_list_workflows` | 列出已部署的工作流。可傳入選填的 `tag` 參數篩選。 |
|
||||
| `arcrun_get_workflow` | 取得指定工作流的 metadata。輸入 `name`。 |
|
||||
|
||||
### 零件管理
|
||||
|
||||
| Tool | 說明 |
|
||||
|------|------|
|
||||
| `u6u_list_components` | 列出已發佈的零件。可傳入選填的 `tag` 參數篩選。 |
|
||||
| `arcrun_list_components` | 列出已發佈的零件。可傳入選填的 `tag` 參數篩選。 |
|
||||
|
||||
### Tag 管理
|
||||
|
||||
| Tool | 說明 |
|
||||
|------|------|
|
||||
| `u6u_create_tag` | 建立新 tag。輸入 `name`(必填)與 `description`(選填)。 |
|
||||
| `u6u_list_tags` | 列出當前命名空間下所有 tag。 |
|
||||
| `u6u_delete_tag` | 刪除指定 tag。輸入 `tag_name`。 |
|
||||
| `u6u_tag_resource` | 為工作流或零件加上 tag。輸入 `resource_type`、`resource_id`、`tag_name`。 |
|
||||
| `u6u_untag_resource` | 移除工作流或零件的 tag。 |
|
||||
| `arcrun_create_tag` | 建立新 tag。輸入 `name`(必填)與 `description`(選填)。 |
|
||||
| `arcrun_list_tags` | 列出當前命名空間下所有 tag。 |
|
||||
| `arcrun_delete_tag` | 刪除指定 tag。輸入 `tag_name`。 |
|
||||
| `arcrun_tag_resource` | 為工作流或零件加上 tag。輸入 `resource_type`、`resource_id`、`tag_name`。 |
|
||||
| `arcrun_untag_resource` | 移除工作流或零件的 tag。 |
|
||||
|
||||
---
|
||||
|
||||
@@ -97,7 +98,7 @@ Arcrun 的零件是 TinyGo 編譯的 `.wasm`,透過 stdin/stdout JSON 通訊
|
||||
### 步驟一:取得開發指引
|
||||
|
||||
```
|
||||
u6u_get_component_guide
|
||||
arcrun_get_component_guide
|
||||
```
|
||||
|
||||
指引包含:TinyGo 白名單 import、禁止行為、`component.contract.yaml` 完整範例、本地測試指令。
|
||||
@@ -105,7 +106,7 @@ u6u_get_component_guide
|
||||
### 步驟二:搜尋現有零件
|
||||
|
||||
```
|
||||
u6u_search_components("查詢 Google Sheets 資料")
|
||||
arcrun_search_components("查詢 Google Sheets 資料")
|
||||
```
|
||||
|
||||
若已有符合的零件,直接使用,不需要重新開發。
|
||||
@@ -137,7 +138,7 @@ echo '{"input_field":"value"}' | wasmtime my_component.wasm
|
||||
### 步驟四:提交零件
|
||||
|
||||
```
|
||||
u6u_publish_component(
|
||||
arcrun_publish_component(
|
||||
contract={...}, // component.contract.yaml 內容
|
||||
wasm_base64="..." // base64(my_component.wasm)
|
||||
)
|
||||
@@ -152,23 +153,26 @@ Registry 自動執行沙盒驗收(體積、syscall 掃描、Gherkin 測試)
|
||||
### 步驟一:搜尋零件
|
||||
|
||||
```
|
||||
u6u_search_components("查詢匯率")
|
||||
u6u_search_components("發送 Telegram 訊息")
|
||||
arcrun_search_components("查詢匯率")
|
||||
arcrun_search_components("發送 Telegram 訊息")
|
||||
```
|
||||
|
||||
### 步驟二:沙盒測試
|
||||
### 步驟二:部署前驗證
|
||||
|
||||
```
|
||||
u6u_execute_workflow(
|
||||
triplets=["system >> 查詢匯率 >> get-exchange-rate", ...],
|
||||
context={"currency_pair": "USD/TWD"}
|
||||
)
|
||||
arcrun_validate_yaml(yaml_content="...")
|
||||
```
|
||||
|
||||
### 步驟三:部署
|
||||
|
||||
```
|
||||
u6u_deploy_workflow(yaml_content="...")
|
||||
arcrun_push_workflow(api_key="ak_xxx", yaml_content="...")
|
||||
```
|
||||
|
||||
### 步驟四:觸發執行
|
||||
|
||||
```
|
||||
arcrun_run_workflow(api_key="ak_xxx", name="exchange-rate-notify", input={"currency_pair": "USD/TWD"})
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
Reference in New Issue
Block a user