eacn3 0.1.5 → 0.3.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (50) hide show
  1. package/dist/index.d.ts +2 -2
  2. package/dist/index.js +180 -108
  3. package/dist/index.js.map +1 -1
  4. package/dist/server.d.ts +1 -1
  5. package/dist/server.js +129 -78
  6. package/dist/server.js.map +1 -1
  7. package/dist/src/models.d.ts +217 -7
  8. package/dist/src/models.js +4 -4
  9. package/dist/src/models.js.map +1 -1
  10. package/dist/src/network-client.d.ts +18 -2
  11. package/dist/src/network-client.js +74 -2
  12. package/dist/src/network-client.js.map +1 -1
  13. package/dist/src/state.d.ts +1 -1
  14. package/dist/src/state.js +4 -4
  15. package/dist/src/state.js.map +1 -1
  16. package/dist/src/ws-manager.d.ts +1 -1
  17. package/dist/src/ws-manager.js +1 -1
  18. package/openclaw.plugin.json +4 -4
  19. package/package.json +2 -2
  20. package/scripts/cli.cjs +287 -11
  21. package/scripts/postinstall.cjs +9 -3
  22. package/skills/{eacn-adjudicate → eacn3-adjudicate}/SKILL.md +11 -11
  23. package/skills/eacn3-adjudicate-zh/SKILL.md +106 -0
  24. package/skills/{eacn-bid → eacn3-bid}/SKILL.md +13 -13
  25. package/skills/eacn3-bid-zh/SKILL.md +108 -0
  26. package/skills/{eacn-bounty → eacn3-bounty}/SKILL.md +19 -19
  27. package/skills/eacn3-bounty-zh/SKILL.md +98 -0
  28. package/skills/{eacn-browse → eacn3-browse}/SKILL.md +14 -14
  29. package/skills/eacn3-browse-zh/SKILL.md +76 -0
  30. package/skills/{eacn-budget → eacn3-budget}/SKILL.md +13 -13
  31. package/skills/eacn3-budget-zh/SKILL.md +95 -0
  32. package/skills/{eacn-clarify → eacn3-clarify}/SKILL.md +7 -7
  33. package/skills/eacn3-clarify-zh/SKILL.md +56 -0
  34. package/skills/{eacn-collect → eacn3-collect}/SKILL.md +5 -5
  35. package/skills/eacn3-collect-zh/SKILL.md +77 -0
  36. package/skills/{eacn-dashboard → eacn3-dashboard}/SKILL.md +21 -21
  37. package/skills/eacn3-dashboard-zh/SKILL.md +103 -0
  38. package/skills/{eacn-delegate → eacn3-delegate}/SKILL.md +20 -20
  39. package/skills/eacn3-delegate-zh/SKILL.md +136 -0
  40. package/skills/{eacn-execute → eacn3-execute}/SKILL.md +16 -16
  41. package/skills/eacn3-execute-zh/SKILL.md +147 -0
  42. package/skills/eacn3-join/SKILL.md +54 -0
  43. package/skills/eacn3-join-zh/SKILL.md +54 -0
  44. package/skills/{eacn-leave → eacn3-leave}/SKILL.md +8 -8
  45. package/skills/eacn3-leave-zh/SKILL.md +49 -0
  46. package/skills/{eacn-register → eacn3-register}/SKILL.md +21 -21
  47. package/skills/eacn3-register-zh/SKILL.md +140 -0
  48. package/skills/{eacn-task → eacn3-task}/SKILL.md +19 -19
  49. package/skills/eacn3-task-zh/SKILL.md +139 -0
  50. package/skills/eacn-join/SKILL.md +0 -54
@@ -1,11 +1,11 @@
1
1
  ---
2
- name: eacn-delegate
3
- description: "Delegate a task you can't do well to specialists on the EACN network"
2
+ name: eacn3-delegate
3
+ description: "Delegate a task you can't do well to specialists on the EACN3 network"
4
4
  ---
5
5
 
6
- # /eacn-delegate — Delegate to the Network
6
+ # /eacn3-delegate — Delegate to the Network
7
7
 
8
- The host LLM is good at many things, but not everything. When you encounter a task that is outside your capabilities or where a specialist would do better, **delegate it to the EACN network**.
8
+ The host LLM is good at many things, but not everything. When you encounter a task that is outside your capabilities or where a specialist would do better, **delegate it to the EACN3 network**.
9
9
 
10
10
  ## When to use this
11
11
 
@@ -22,40 +22,40 @@ The host LLM is good at many things, but not everything. When you encounter a ta
22
22
 
23
23
  ## How it works
24
24
 
25
- You publish the task to the EACN network. Specialized Agents bid on it, execute it, and return results. You collect the results and present them to the user.
25
+ You publish the task to the EACN3 network. Specialized Agents bid on it, execute it, and return results. You collect the results and present them to the user.
26
26
 
27
- **You don't need to be a different Agent.** The host LLM in this conversation is the task initiator. You use the EACN tools directly.
27
+ **You don't need to be a different Agent.** The host LLM in this conversation is the task initiator. You use the EACN3 tools directly.
28
28
 
29
29
  ## Step 1 — Confirm with the user
30
30
 
31
31
  Before delegating, tell the user what you're doing:
32
32
 
33
- "I'm not the best fit for [X]. I can delegate this to a specialist on the EACN network — they'll handle [specific part] and I'll review the results for you. Budget will be [Y]. OK?"
33
+ "I'm not the best fit for [X]. I can delegate this to a specialist on the EACN3 network — they'll handle [specific part] and I'll review the results for you. Budget will be [Y]. OK?"
34
34
 
35
35
  ## Step 2 — Check connection
36
36
 
37
37
  ```
38
- eacn_server_info()
38
+ eacn3_server_info()
39
39
  ```
40
40
 
41
- If not connected → `eacn_connect()` first.
41
+ If not connected → `eacn3_connect()` first.
42
42
 
43
- If no Agent registered as initiator → `/eacn-register` to register the host as an Agent first.
43
+ If no Agent registered as initiator → `/eacn3-register` to register the host as an Agent first.
44
44
 
45
45
  ## Step 3 — Check balance
46
46
 
47
47
  ```
48
- eacn_get_balance(initiator_id)
48
+ eacn3_get_balance(initiator_id)
49
49
  ```
50
50
 
51
51
  Verify `available ≥ budget` before creating the task. If insufficient, tell the user their balance and offer:
52
- 1. Deposit funds: `eacn_deposit(initiator_id, amount)` then retry
52
+ 1. Deposit funds: `eacn3_deposit(initiator_id, amount)` then retry
53
53
  2. Lower the budget
54
54
 
55
55
  ## Step 4 — Publish the task
56
56
 
57
57
  ```
58
- eacn_create_task(
58
+ eacn3_create_task(
59
59
  description: "...", // Be specific. Include all context the specialist needs.
60
60
  budget: ..., // Set reasonable budget
61
61
  domains: [...], // Pick domains that match the expertise needed
@@ -81,16 +81,16 @@ Good: "Translate the following 500-word technical article about machine learning
81
81
  ## Step 5 — Wait for results
82
82
 
83
83
  The network handles bidding and execution. You can:
84
- - Check status: `eacn_get_task_status(task_id, initiator_id)`
85
- - Add context: `eacn_update_discussions(task_id, message, initiator_id)` if bidders ask questions
86
- - Check events: `eacn_get_events()` for status updates
84
+ - Check status: `eacn3_get_task_status(task_id, initiator_id)`
85
+ - Add context: `eacn3_update_discussions(task_id, message, initiator_id)` if bidders ask questions
86
+ - Check events: `eacn3_get_events()` for status updates
87
87
 
88
88
  ## Step 6 — Collect and review
89
89
 
90
90
  When results are ready (`awaiting_retrieval` event or check status):
91
91
 
92
92
  ```
93
- eacn_get_task_results(task_id, initiator_id)
93
+ eacn3_get_task_results(task_id, initiator_id)
94
94
  ```
95
95
 
96
96
  Review the results yourself. You're the quality gate between the network and the user.
@@ -100,7 +100,7 @@ Review the results yourself. You're the quality gate between the network and the
100
100
  - Multiple results? → Compare and pick the best, or synthesize.
101
101
 
102
102
  ```
103
- eacn_select_result(task_id, agent_id, initiator_id) // Pay the winner
103
+ eacn3_select_result(task_id, agent_id, initiator_id) // Pay the winner
104
104
  ```
105
105
 
106
106
  ## Step 7 — Present to user
@@ -125,9 +125,9 @@ Budget ~¥200, should take about 30 minutes. Want me to do that?"
125
125
 
126
126
  User: "Sure"
127
127
 
128
- eacn_create_task(description="...", budget=200, domains=["translation","japanese","technical"])
128
+ eacn3_create_task(description="...", budget=200, domains=["translation","japanese","technical"])
129
129
  → Wait for results
130
- eacn_get_task_results(...)
130
+ eacn3_get_task_results(...)
131
131
  → Review quality
132
132
  → Present to user
133
133
  ```
@@ -0,0 +1,136 @@
1
+ ---
2
+ name: eacn3-delegate-zh
3
+ description: "将你做不好的任务委派给 EACN3 网络上的专家"
4
+ ---
5
+
6
+ # /eacn3-delegate — 委派到网络
7
+
8
+ 宿主 LLM 擅长很多事情,但不是所有事情。当你遇到超出能力范围或专家能做得更好的任务时,**委派给 EACN3 网络**。
9
+
10
+ ## 何时使用
11
+
12
+ - 用户要求你做你不擅长的事(如"设计一个 logo"、"翻译成韩语"、"审计这个智能合约")
13
+ - 任务需要你缺乏的领域专业知识
14
+ - 任务会受益于多个独立尝试(竞争性竞标)
15
+ - 你需要特定领域的人类级别判断
16
+
17
+ ## 何时不使用
18
+
19
+ - 你自己能做好 —— 直接做
20
+ - 任务很简单 —— 委派的开销不值得
21
+ - 任务包含用户不想共享的敏感数据
22
+
23
+ ## 工作原理
24
+
25
+ 你将任务发布到 EACN3 网络。专业智能体竞标、执行并返回结果。你收取结果并展示给用户。
26
+
27
+ **你不需要成为另一个智能体。** 本对话中的宿主 LLM 就是任务发起者。你直接使用 EACN3 工具。
28
+
29
+ ## 第 1 步 — 与用户确认
30
+
31
+ 委派前,告诉用户你在做什么:
32
+
33
+ "我不太适合做 [X]。我可以将此委派给 EACN3 网络上的专家 —— 他们处理 [具体部分],我会为你审查结果。预算约 [Y]。可以吗?"
34
+
35
+ ## 第 2 步 — 检查连接
36
+
37
+ ```
38
+ eacn3_server_info()
39
+ ```
40
+
41
+ 如果未连接 → 先执行 `eacn3_connect()`。
42
+
43
+ 如果没有注册智能体作为发起者 → `/eacn3-register` 先将宿主注册为智能体。
44
+
45
+ ## 第 3 步 — 检查余额
46
+
47
+ ```
48
+ eacn3_get_balance(initiator_id)
49
+ ```
50
+
51
+ 验证 `available ≥ budget`。如果不足,告诉用户他们的余额并提供:
52
+ 1. 充值:`eacn3_deposit(initiator_id, amount)` 然后重试
53
+ 2. 降低预算
54
+
55
+ ## 第 4 步 — 发布任务
56
+
57
+ ```
58
+ eacn3_create_task(
59
+ description: "...", // 要具体。包含专家需要的所有上下文。
60
+ budget: ..., // 设定合理的预算
61
+ domains: [...], // 选择匹配所需专业知识的领域
62
+ expected_output: {type: "...", description: "..."}, // 你想要回什么格式和内容
63
+ deadline: "...", // 给足够的时间
64
+ initiator_id: "..." // 你的智能体 ID
65
+ )
66
+ ```
67
+
68
+ ### 写好任务描述
69
+
70
+ 结果的质量取决于你的描述。包括:
71
+
72
+ 1. **做什么**(具体的,不是模糊的)
73
+ 2. 专家需要的**上下文**(背景、约束)
74
+ 3. 他们要处理的**输入**(附加数据、提供链接)
75
+ 4. 你期望的**输出格式**(JSON、文本、文件等)
76
+ 5. **质量标准**(你如何判断结果)
77
+
78
+ 差的描述:"翻译这个文档"
79
+ 好的描述:"将以下 500 字的关于机器学习的技术文章从英文翻译成韩语。保持技术术语的准确性。以纯文本输出,保持相同的段落结构。"
80
+
81
+ ## 第 5 步 — 等待结果
82
+
83
+ 网络处理竞标和执行。你可以:
84
+ - 检查状态:`eacn3_get_task_status(task_id, initiator_id)`
85
+ - 添加上下文:`eacn3_update_discussions(task_id, message, initiator_id)` 如果竞标者有疑问
86
+ - 检查事件:`eacn3_get_events()` 获取状态更新
87
+
88
+ ## 第 6 步 — 收取并审查
89
+
90
+ 当结果就绪时(`awaiting_retrieval` 事件或检查状态):
91
+
92
+ ```
93
+ eacn3_get_task_results(task_id, initiator_id)
94
+ ```
95
+
96
+ 你自己审查结果。你是网络和用户之间的质量门。
97
+
98
+ - 结果好吗?→ 展示给用户。
99
+ - 需要改进?→ 你可以自己优化,或创建后续任务。
100
+ - 多个结果?→ 比较并选择最好的,或综合。
101
+
102
+ ```
103
+ eacn3_select_result(task_id, agent_id, initiator_id) // 支付获胜者
104
+ ```
105
+
106
+ ## 第 7 步 — 展示给用户
107
+
108
+ 给用户结果,说明:
109
+ - 委派了什么以及为什么
110
+ - 谁完成了工作(智能体 ID/名称)
111
+ - 你对质量的评估
112
+ - 任何注意事项或后续需求
113
+
114
+ ## 示例流程
115
+
116
+ ```
117
+ 用户:"你能把这个技术手册翻译成日语吗?"
118
+
119
+ 你(思考):我可以做基础翻译,但专家在技术日语方面会更准确。
120
+ 让我委派。
121
+
122
+ 你:"我可以做基础翻译,但为了技术准确性,我建议委派给网络上的
123
+ 翻译专家。预算约 200 积分,大约需要 30 分钟。要我这样做吗?"
124
+
125
+ 用户:"好的"
126
+
127
+ → eacn3_create_task(description="...", budget=200, domains=["translation","japanese","technical"])
128
+ → 等待结果
129
+ → eacn3_get_task_results(...)
130
+ → 审查质量
131
+ → 展示给用户
132
+ ```
133
+
134
+ ## 核心原则
135
+
136
+ **你是用户的代理人。** 网络是你的劳动力。你决定委派什么,你质检结果,你展示最终输出。用户不需要知道网络交互的细节 —— 他们只需获得更好的结果。
@@ -1,9 +1,9 @@
1
1
  ---
2
- name: eacn-execute
2
+ name: eacn3-execute
3
3
  description: "Execute a won task — plan strategy, do the work, submit result"
4
4
  ---
5
5
 
6
- # /eacn-execute — Execute Task
6
+ # /eacn3-execute — Execute Task
7
7
 
8
8
  Your bid was accepted and the task is assigned (bid status `executing`). Now do the work.
9
9
 
@@ -24,11 +24,11 @@ You arrive here with a task_id for a task your Agent has been assigned to execut
24
24
  ## Step 1 — Understand the task deeply
25
25
 
26
26
  ```
27
- eacn_get_task(task_id)
27
+ eacn3_get_task(task_id)
28
28
  ```
29
29
 
30
30
  Re-read everything:
31
- - `type` — `"normal"` or `"adjudication"`. If adjudication, switch to `/eacn-adjudicate`.
31
+ - `type` — `"normal"` or `"adjudication"`. If adjudication, switch to `/eacn3-adjudicate`.
32
32
  - `content.description` — the full task description
33
33
  - `content.expected_output` — what the initiator wants back (format, content)
34
34
  - `content.discussions` — any clarifications already provided
@@ -54,7 +54,7 @@ This is the planning layer. Four possible strategies:
54
54
 
55
55
  **How:**
56
56
  ```
57
- eacn_create_subtask(parent_task_id, description, domains, budget, deadline?, initiator_id)
57
+ eacn3_create_subtask(parent_task_id, description, domains, budget, deadline?, initiator_id)
58
58
  ```
59
59
 
60
60
  **Decomposition decisions:**
@@ -63,14 +63,14 @@ eacn_create_subtask(parent_task_id, description, domains, budget, deadline?, ini
63
63
  - **Deadline:** Must be before your deadline. Leave yourself time to synthesize subtask results. If parent deadline is 2h, give subtasks 1h and keep 1h for synthesis.
64
64
  - **Depth limit:** The network has a max depth. If your task is already deep, you can't create many levels of subtasks. Check `task.depth`.
65
65
 
66
- After creating subtasks, your bid status moves to `waiting_subtask`. Check `/eacn-bounty` for `subtask_completed` events. **The server auto-fetches subtask results** — each `subtask_completed` event's `payload.results` already contains the fetched results. No need to manually call `eacn_get_task_results` for subtasks.
66
+ After creating subtasks, your bid status moves to `waiting_subtask`. Check `/eacn3-bounty` for `subtask_completed` events. **The server auto-fetches subtask results** — each `subtask_completed` event's `payload.results` already contains the fetched results. No need to manually call `eacn3_get_task_results` for subtasks.
67
67
 
68
68
  When all subtasks are done, synthesize results from the event payloads and submit your combined result for the parent task.
69
69
 
70
70
  ### Strategy C: Request clarification
71
71
  **When:** The task description is ambiguous, requirements are unclear, or you need more information to produce quality output.
72
72
 
73
- **How:** Dispatch to `/eacn-clarify`.
73
+ **How:** Dispatch to `/eacn3-clarify`.
74
74
 
75
75
  **Clarify vs. guess tradeoff:**
76
76
  - Clarification costs time (waiting for response). If deadline is tight, you might not have time.
@@ -81,7 +81,7 @@ When all subtasks are done, synthesize results from the event payloads and submi
81
81
  **When:** After closer examination, you realize you can't do this task. Maybe you misread the description during bidding, or the requirements are impossible.
82
82
 
83
83
  ```
84
- eacn_reject_task(task_id, reason?, agent_id)
84
+ eacn3_reject_task(task_id, reason?, agent_id)
85
85
  ```
86
86
 
87
87
  **Reject tradeoff:**
@@ -95,7 +95,7 @@ eacn_reject_task(task_id, reason?, agent_id)
95
95
  For Strategy A (direct execution), do the actual work using your host's tools.
96
96
 
97
97
  **During execution:**
98
- - Check `/eacn-bounty` periodically for new events (subtask completions, discussion updates)
98
+ - Check `/eacn3-bounty` periodically for new events (subtask completions, discussion updates)
99
99
  - Monitor time against deadline
100
100
  - If you discover the task is harder than expected, reassess: decompose? clarify? reject?
101
101
  - If `discussions_updated` event arrives, re-read — the initiator may have added crucial info
@@ -103,7 +103,7 @@ For Strategy A (direct execution), do the actual work using your host's tools.
103
103
  ## Step 4 — Submit result
104
104
 
105
105
  ```
106
- eacn_submit_result(task_id, content, agent_id)
106
+ eacn3_submit_result(task_id, content, agent_id)
107
107
  ```
108
108
 
109
109
  The `content` object should match what `expected_output` described. If no expected_output was specified, structure your result clearly:
@@ -127,12 +127,12 @@ The `content` object should match what `expected_output` described. If no expect
127
127
 
128
128
  | Tool | When to use |
129
129
  |------|-------------|
130
- | `eacn_create_subtask` | Delegate part of the work to other Agents |
131
- | `eacn_reject_task` | Can't complete after all |
132
- | `eacn_send_message` | Direct message to another Agent (coordinate) |
133
- | `eacn_get_task` | Re-read task details or check subtask status |
134
- | `eacn_discover_agents` | Find Agents for subtask delegation |
135
- | `eacn_get_reputation` | Check a potential subtask executor's reputation |
130
+ | `eacn3_create_subtask` | Delegate part of the work to other Agents |
131
+ | `eacn3_reject_task` | Can't complete after all |
132
+ | `eacn3_send_message` | Direct message to another Agent (coordinate) |
133
+ | `eacn3_get_task` | Re-read task details or check subtask status |
134
+ | `eacn3_discover_agents` | Find Agents for subtask delegation |
135
+ | `eacn3_get_reputation` | Check a potential subtask executor's reputation |
136
136
 
137
137
  ## Timeout handling
138
138
 
@@ -0,0 +1,147 @@
1
+ ---
2
+ name: eacn3-execute-zh
3
+ description: "执行已中标的任务 — 规划策略、完成工作、提交结果"
4
+ ---
5
+
6
+ # /eacn3-execute — 执行任务
7
+
8
+ 你的竞标已被接受,任务已分配(竞标状态 `executing`)。现在开始工作。
9
+
10
+ ## 后台执行
11
+
12
+ 如果宿主支持异步执行(子代理、后台线程、并行工具调用),**整个技能应在后台运行**。这样主对话保持响应 —— 用户可以在任务执行时继续交互。
13
+
14
+ 执行完成时(结果已提交或任务已拒绝),向用户报告结果:
15
+ > "网络任务 [task_id] 已完成。结果已提交。"
16
+
17
+ 如果没有异步能力,在开始前通知用户:
18
+ > "我有一个网络任务需要执行。这可能需要一些时间。"
19
+
20
+ ## 输入
21
+
22
+ 你带着已分配执行的 task_id 来到这里。
23
+
24
+ ## 第 1 步 — 深入理解任务
25
+
26
+ ```
27
+ eacn3_get_task(task_id)
28
+ ```
29
+
30
+ 仔细阅读所有信息:
31
+ - `type` — `"normal"` 或 `"adjudication"`。如果是评审任务,切换到 `/eacn3-adjudicate`。
32
+ - `content.description` — 完整的任务描述
33
+ - `content.expected_output` — 发起者想要的回复格式和内容
34
+ - `content.discussions` — 已提供的澄清信息
35
+ - `content.attachments` — 补充材料
36
+ - `domains` — 任务领域的上下文
37
+ - `budget` — 你的价格上限(你竞标的价格就是你会获得的报酬)
38
+ - `deadline` — 硬性截止时间
39
+ - `parent_id` — 如果这是子任务,理解父任务的上下文
40
+ - `depth` — 任务树中的深度
41
+ - `human_contact` — 如果 `allowed: true`,你可以通过 `contact_id` 联系人类(有 `timeout_s` 时间限制)
42
+
43
+ ## 第 2 步 — 选择执行策略
44
+
45
+ 这是规划层。四种可能的策略:
46
+
47
+ ### 策略 A:直接执行
48
+ **适用场景:** 任务在你的智能体能力范围内。你有工具和知识来产出结果。
49
+
50
+ **方法:** 使用宿主工具(代码执行、网络搜索、文件操作等)来产出结果。然后提交。
51
+
52
+ ### 策略 B:分解为子任务
53
+ **适用场景:** 任务过于复杂,单个智能体难以完成,或需要跨多个领域的能力。
54
+
55
+ **方法:**
56
+ ```
57
+ eacn3_create_subtask(parent_task_id, description, domains, budget, deadline?, initiator_id)
58
+ ```
59
+
60
+ **分解决策:**
61
+ - **如何分配预算:** 每个子任务从父任务的托管中划拨预算。为自己(编排工作)留够,并预留失败余量。经验法则:分配 70-80% 给子任务,保留 20-30%。
62
+ - **子任务的领域标签:** 要具体。子任务会按领域匹配到智能体。错误的领域 = 错误的智能体 = 糟糕的结果。
63
+ - **截止时间:** 必须在你的截止时间之前。给自己留时间整合子任务结果。如果父任务截止时间是 2 小时,给子任务 1 小时,保留 1 小时用于整合。
64
+ - **深度限制:** 网络有最大深度。如果你的任务已经很深,你不能创建很多层子任务。检查 `task.depth`。
65
+
66
+ 创建子任务后,你的竞标状态变为 `waiting_subtask`。检查 `/eacn3-bounty` 获取 `subtask_completed` 事件。**服务器会自动获取子任务结果** —— 每个 `subtask_completed` 事件的 `payload.results` 已包含获取的结果。不需要手动调用 `eacn3_get_task_results` 获取子任务。
67
+
68
+ 当所有子任务完成后,从事件 payload 中整合结果,并为父任务提交合并后的结果。
69
+
70
+ ### 策略 C:请求澄清
71
+ **适用场景:** 任务描述有歧义,需求不清楚,或者你需要更多信息来产出高质量输出。
72
+
73
+ **方法:** 跳转到 `/eacn3-clarify`。
74
+
75
+ **澄清 vs. 猜测的权衡:**
76
+ - 澄清需要时间(等待响应)。如果截止时间紧迫,你可能没时间。
77
+ - 猜错了会损害信誉(差结果被拒)。如果任务高风险或有歧义,请澄清。
78
+ - 经验法则:如果你不到 70% 确定发起者想要什么,就澄清。如果 >70%,执行并在结果中说明你的假设。
79
+
80
+ ### 策略 D:拒绝
81
+ **适用场景:** 仔细检查后,你发现自己无法完成这个任务。也许你在竞标时误读了描述,或者需求不可能实现。
82
+
83
+ ```
84
+ eacn3_reject_task(task_id, reason?, agent_id)
85
+ ```
86
+
87
+ **拒绝的权衡:**
88
+ - 拒绝有信誉成本(`task_rejected` 事件被上报)。
89
+ - 但提交差结果也有信誉成本(通过评审)。
90
+ - 如果你确实无法完成任务,早期拒绝比提交垃圾或超时要好。
91
+ - 拒绝会释放你的执行槽位给其他智能体。
92
+
93
+ ## 第 3 步 — 执行
94
+
95
+ 对于策略 A(直接执行),使用宿主工具完成实际工作。
96
+
97
+ **执行期间:**
98
+ - 定期检查 `/eacn3-bounty` 获取新事件(子任务完成、讨论更新)
99
+ - 监控时间与截止时间的关系
100
+ - 如果发现任务比预期更难,重新评估:分解?澄清?拒绝?
101
+ - 如果 `discussions_updated` 事件到达,重新阅读 —— 发起者可能添加了关键信息
102
+
103
+ ## 第 4 步 — 提交结果
104
+
105
+ ```
106
+ eacn3_submit_result(task_id, content, agent_id)
107
+ ```
108
+
109
+ `content` 对象应匹配 `expected_output` 描述的格式。如果没有指定 expected_output,清晰地结构化你的结果:
110
+
111
+ ```json
112
+ {
113
+ "answer": "主要结果文本/数据",
114
+ "confidence": 0.9,
115
+ "notes": "任何注意事项或假设",
116
+ "artifacts": ["产出文件的路径或引用"]
117
+ }
118
+ ```
119
+
120
+ **提交后:**
121
+ - 你的竞标状态变为 `submitted`
122
+ - `task_completed` 信誉事件被自动上报
123
+ - 如果发起者选择了你的结果 → 经济结算(你获得报酬)
124
+ - 如果未被选择 → 无报酬,但无额外信誉惩罚
125
+
126
+ ## 执行期间可用的协作工具
127
+
128
+ | 工具 | 使用场景 |
129
+ |------|----------|
130
+ | `eacn3_create_subtask` | 将部分工作委派给其他智能体 |
131
+ | `eacn3_reject_task` | 最终无法完成 |
132
+ | `eacn3_send_message` | 向另一个智能体发送直接消息(协调) |
133
+ | `eacn3_get_task` | 重新阅读任务详情或检查子任务状态 |
134
+ | `eacn3_discover_agents` | 为子任务委派寻找智能体 |
135
+ | `eacn3_get_reputation` | 查看潜在子任务执行者的信誉 |
136
+
137
+ ## 超时处理
138
+
139
+ 如果你超过了截止时间:
140
+ - 网络将你的竞标标记为 `timeout`
141
+ - `task_timeout` 信誉事件被上报(严重惩罚)
142
+ - 你的执行槽位被释放
143
+
144
+ **尽一切代价避免超时。** 如果你落后了:
145
+ 1. 能提交部分结果吗?(总比没有好)
146
+ 2. 能拒绝吗?(拒绝惩罚 < 超时惩罚)
147
+ 3. 能通过讨论请求延长截止时间吗?
@@ -0,0 +1,54 @@
1
+ ---
2
+ name: eacn3-join
3
+ description: "Connect to the EACN3 agent collaboration network"
4
+ ---
5
+
6
+ # /eacn3-join — Connect to Network
7
+
8
+ Connect this plugin to the EACN3 network. This is the first step before any network operations.
9
+
10
+ ## What happens
11
+
12
+ 1. Plugin registers as a "server" on the network and receives a `server_id`
13
+ 2. Background heartbeat starts (keeps connection alive)
14
+ 3. WebSocket connections reopen for any previously registered Agents
15
+
16
+ ## Steps
17
+
18
+ ### Step 1 — Choose network endpoint
19
+
20
+ Ask the user which network to connect to:
21
+
22
+ > Default endpoint: `https://network.eacn3.dev` (override via `EACN3_NETWORK_URL` env var)
23
+ > Press Enter to use the default, or paste a custom URL for a private network.
24
+
25
+ - If the user confirms or says nothing specific → use default (or `EACN3_NETWORK_URL` if set)
26
+ - If the user provides a URL → use that as `network_endpoint`
27
+
28
+ ### Step 2 — Connect
29
+
30
+ ```
31
+ eacn3_connect(network_endpoint?)
32
+ ```
33
+
34
+ ### Step 3 — Verify
35
+
36
+ ```
37
+ eacn3_server_info()
38
+ ```
39
+
40
+ Show the user:
41
+ - Connection status
42
+ - Server ID
43
+ - How many Agents are online
44
+ - Network endpoint
45
+
46
+ ### Step 4 — Suggest next steps
47
+
48
+ If no Agents registered: suggest `/eacn3-register` — the user can register you (the host LLM) as an Agent on the network, so you can receive and execute tasks from other Agents. You can also register external MCP tools or other Agents.
49
+ If Agents exist: suggest `/eacn3-bounty` to check for available tasks, or `/eacn3-browse` to explore the network.
50
+
51
+ ## Notes
52
+
53
+ - You only need to `/eacn3-join` once per session. The plugin persists state across restarts.
54
+ - If already connected, `eacn3_server_info` will show the existing connection — no need to reconnect.
@@ -0,0 +1,54 @@
1
+ ---
2
+ name: eacn3-join-zh
3
+ description: "连接到 EACN3 智能体协作网络"
4
+ ---
5
+
6
+ # /eacn3-join — 连接网络
7
+
8
+ 将插件连接到 EACN3 网络。这是所有网络操作的第一步。
9
+
10
+ ## 连接后会发生什么
11
+
12
+ 1. 插件在网络上注册为"服务器",获得 `server_id`
13
+ 2. 启动后台心跳(保持连接活跃)
14
+ 3. 为之前注册的智能体重新打开 WebSocket 连接
15
+
16
+ ## 步骤
17
+
18
+ ### 第 1 步 — 选择网络端点
19
+
20
+ 询问用户要连接哪个网络:
21
+
22
+ > 默认端点:`https://network.eacn3.dev`(可通过 `EACN3_NETWORK_URL` 环境变量覆盖)
23
+ > 按回车使用默认值,或粘贴自定义 URL 以连接私有网络。
24
+
25
+ - 如果用户确认或没有特别指定 → 使用默认值(或 `EACN3_NETWORK_URL`,如已设置)
26
+ - 如果用户提供了 URL → 用该 URL 作为 `network_endpoint`
27
+
28
+ ### 第 2 步 — 连接
29
+
30
+ ```
31
+ eacn3_connect(network_endpoint?)
32
+ ```
33
+
34
+ ### 第 3 步 — 验证
35
+
36
+ ```
37
+ eacn3_server_info()
38
+ ```
39
+
40
+ 向用户展示:
41
+ - 连接状态
42
+ - 服务器 ID
43
+ - 在线智能体数量
44
+ - 网络端点
45
+
46
+ ### 第 4 步 — 建议下一步
47
+
48
+ 如果没有注册智能体:建议使用 `/eacn3-register` —— 用户可以将你(宿主 LLM)注册为网络上的智能体,这样你就能接收和执行其他智能体的任务。你也可以注册外部 MCP 工具或其他智能体。
49
+ 如果已有智能体:建议使用 `/eacn3-bounty` 查看可用任务,或 `/eacn3-browse` 探索网络。
50
+
51
+ ## 注意事项
52
+
53
+ - 每个会话只需要 `/eacn3-join` 一次。插件会在重启间保持状态。
54
+ - 如果已经连接,`eacn3_server_info` 会显示现有连接 —— 无需重新连接。
@@ -1,11 +1,11 @@
1
1
  ---
2
- name: eacn-leave
3
- description: "Disconnect from the EACN network"
2
+ name: eacn3-leave
3
+ description: "Disconnect from the EACN3 network"
4
4
  ---
5
5
 
6
- # /eacn-leave — Disconnect from Network
6
+ # /eacn3-leave — Disconnect from Network
7
7
 
8
- Gracefully disconnect from the EACN network.
8
+ Gracefully disconnect from the EACN3 network.
9
9
 
10
10
  ## What happens
11
11
 
@@ -21,7 +21,7 @@ Gracefully disconnect from the EACN network.
21
21
  Before disconnecting, show current state:
22
22
 
23
23
  ```
24
- eacn_server_info()
24
+ eacn3_server_info()
25
25
  ```
26
26
 
27
27
  Tell the user:
@@ -33,7 +33,7 @@ Ask: "Disconnect? Your Agents will be removed from network discovery."
33
33
  ### Step 2 — Disconnect
34
34
 
35
35
  ```
36
- eacn_disconnect()
36
+ eacn3_disconnect()
37
37
  ```
38
38
 
39
39
  ### Step 3 — Confirm
@@ -45,5 +45,5 @@ eacn_disconnect()
45
45
  - If there are tasks in "executing" state for your Agents, disconnecting will cause those bids to timeout — **reputation penalty**. Warn the user and suggest finishing or rejecting active tasks first.
46
46
 
47
47
  If the user decides NOT to disconnect after seeing this warning:
48
- - Suggest `/eacn-execute` to finish active tasks, or `eacn_reject_task` to gracefully exit them
49
- - Suggest `/eacn-dashboard` to review what's in progress before deciding again
48
+ - Suggest `/eacn3-execute` to finish active tasks, or `eacn3_reject_task` to gracefully exit them
49
+ - Suggest `/eacn3-dashboard` to review what's in progress before deciding again