@myclaw163/clawclaw-cli 0.8.28 → 0.8.29
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.
- package/docs/custom-modules/examples/task-reminder.ts +1 -1
- package/docs/custom-modules/reminders.md +5 -5
- package/package.json +1 -1
- package/skills/clawclaw/SKILL.md +1 -1
- package/skills/clawclaw/references/CUSTOM-REMINDER-DEVELOPMENT.md +5 -5
- package/src/sdk/perception-plugin/reminder-rules.ts +2 -2
|
@@ -10,7 +10,7 @@ export default class TaskReminder extends ClawclawReminder {
|
|
|
10
10
|
topic: 'tasks',
|
|
11
11
|
consumes: ['task_started', 'task_progress', 'task_assigned', 'task_completed', 'task_interrupted', 'task_sabotaged',
|
|
12
12
|
'emergency_started', 'emergency_resolved', 'emergency_interrupted'],
|
|
13
|
-
config: { started: 'state_only', progress: 'state_only', added: '
|
|
13
|
+
config: { started: 'state_only', progress: 'state_only', added: 'silent', completed: 'silent', interrupted: 'wake', sabotaged: 'wake', removed: 'silent', updated: 'silent' },
|
|
14
14
|
} as const;
|
|
15
15
|
|
|
16
16
|
update(input: ReminderInput) {
|
|
@@ -46,7 +46,7 @@ export default class TaskReminder extends ClawclawReminder {
|
|
|
46
46
|
topic: 'tasks',
|
|
47
47
|
consumes: ['task_started', 'task_progress', 'task_assigned', 'task_completed', 'task_interrupted', 'task_sabotaged',
|
|
48
48
|
'emergency_started', 'emergency_resolved', 'emergency_interrupted'],
|
|
49
|
-
config: { started: 'state_only', progress: 'state_only', added: '
|
|
49
|
+
config: { started: 'state_only', progress: 'state_only', added: 'silent', completed: 'silent', interrupted: 'wake', sabotaged: 'wake', removed: 'silent', updated: 'silent' },
|
|
50
50
|
} as const;
|
|
51
51
|
|
|
52
52
|
update(input: ReminderInput) {
|
|
@@ -93,11 +93,11 @@ evaluateReminder(topic: 'tasks', input: ReminderInput): ReminderResult
|
|
|
93
93
|
|---|---|---|
|
|
94
94
|
| started | 开始任务 | state_only |
|
|
95
95
|
| progress | 后端任务进度事件 | state_only |
|
|
96
|
-
| added | 新分配或列表新增任务 |
|
|
97
|
-
| completed | 后端完成,或列表状态明确变成 completed |
|
|
96
|
+
| added | 新分配或列表新增任务 | silent |
|
|
97
|
+
| completed | 后端完成,或列表状态明确变成 completed | silent |
|
|
98
98
|
| interrupted | 后端明确的任务中断 | wake |
|
|
99
99
|
| sabotaged | 后端 task_sabotaged,即破坏任务完成 | wake |
|
|
100
|
-
| removed | 列表移除、原因没有被对应事实解释 |
|
|
100
|
+
| removed | 列表移除、原因没有被对应事实解释 | silent |
|
|
101
101
|
| updated | 其他状态或信息变化 | silent |
|
|
102
102
|
|
|
103
103
|
工具逐条处理,不对整包变化取最高提醒等级:
|
|
@@ -108,7 +108,7 @@ evaluateReminder(topic: 'tasks', input: ReminderInput): ReminderResult
|
|
|
108
108
|
4. 独立变化分别处理。A 完成不能吞掉同帧 B 开始、C 新增。完成提醒中也不夹带下一任务或整个列表,避免绕过 added 的配置。
|
|
109
109
|
5. 列表消失只说明不再列出,不推断完成。明确对应紧急任务生命周期的新增/移除由固定紧急事件表达,避免重复。
|
|
110
110
|
|
|
111
|
-
例如 A 完成(
|
|
111
|
+
例如 A 完成(silent)、B 开始(state_only)、C 新增(silent),输出两条不唤醒的提醒事件:A 完成和 C 新增都可搭便车。B 没有提醒事件,但 CCL 的当前 State 包含三项变化。
|
|
112
112
|
|
|
113
113
|
不需要保存历史的默认算法不使用私有 state。去重、时间窗口、合并、按任务/位置/当前行为筛选等复杂规则,可以自己编写。未提供的配置由工具补默认值;未知参数或非法 mode 抛错。
|
|
114
114
|
|
package/package.json
CHANGED
package/skills/clawclaw/SKILL.md
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: clawclaw
|
|
3
3
|
description: 默认官方 ClawClaw/龙虾杀 gameplay skill,通过 clawclaw-cli/ccl/myclaw 开始或继续普通匹配、创建或加入好友房,以及进入模拟训练或木桩训练。Use when the user asks to play/start/join/continue a ClawClaw match, friend room, or training room, including “玩一局”“开一局”“再来一局”“玩龙虾杀”“玩 ClawClaw”“玩 myclaw”“创建房间”“加入房间”“好友房”“房间码”“训练一下”“模拟训练”“木桩测试”. If another Hub/local/custom ClawClaw gameplay skill is available, prefer that skill and do not load this official fallback.
|
|
4
|
-
version: 4.8.
|
|
4
|
+
version: 4.8.105
|
|
5
5
|
---
|
|
6
6
|
|
|
7
7
|
# 龙虾杀(ClawClaw)
|
|
@@ -46,7 +46,7 @@ export default class TaskReminder extends ClawclawReminder {
|
|
|
46
46
|
topic: 'tasks',
|
|
47
47
|
consumes: ['task_started', 'task_progress', 'task_assigned', 'task_completed', 'task_interrupted', 'task_sabotaged',
|
|
48
48
|
'emergency_started', 'emergency_resolved', 'emergency_interrupted'],
|
|
49
|
-
config: { started: 'state_only', progress: 'state_only', added: '
|
|
49
|
+
config: { started: 'state_only', progress: 'state_only', added: 'silent', completed: 'silent', interrupted: 'wake', sabotaged: 'wake', removed: 'silent', updated: 'silent' },
|
|
50
50
|
} as const;
|
|
51
51
|
|
|
52
52
|
update(input: ReminderInput) {
|
|
@@ -93,11 +93,11 @@ evaluateReminder(topic: 'tasks', input: ReminderInput): ReminderResult
|
|
|
93
93
|
|---|---|---|
|
|
94
94
|
| started | 开始任务 | state_only |
|
|
95
95
|
| progress | 后端任务进度事件 | state_only |
|
|
96
|
-
| added | 新分配或列表新增任务 |
|
|
97
|
-
| completed | 后端完成,或列表状态明确变成 completed |
|
|
96
|
+
| added | 新分配或列表新增任务 | silent |
|
|
97
|
+
| completed | 后端完成,或列表状态明确变成 completed | silent |
|
|
98
98
|
| interrupted | 后端明确的任务中断 | wake |
|
|
99
99
|
| sabotaged | 后端 task_sabotaged,即破坏任务完成 | wake |
|
|
100
|
-
| removed | 列表移除、原因没有被对应事实解释 |
|
|
100
|
+
| removed | 列表移除、原因没有被对应事实解释 | silent |
|
|
101
101
|
| updated | 其他状态或信息变化 | silent |
|
|
102
102
|
|
|
103
103
|
工具逐条处理,不对整包变化取最高提醒等级:
|
|
@@ -108,7 +108,7 @@ evaluateReminder(topic: 'tasks', input: ReminderInput): ReminderResult
|
|
|
108
108
|
4. 独立变化分别处理。A 完成不能吞掉同帧 B 开始、C 新增。完成提醒中也不夹带下一任务或整个列表,避免绕过 added 的配置。
|
|
109
109
|
5. 列表消失只说明不再列出,不推断完成。明确对应紧急任务生命周期的新增/移除由固定紧急事件表达,避免重复。
|
|
110
110
|
|
|
111
|
-
例如 A 完成(
|
|
111
|
+
例如 A 完成(silent)、B 开始(state_only)、C 新增(silent),输出两条不唤醒的提醒事件:A 完成和 C 新增都可搭便车。B 没有提醒事件,但 CCL 的当前 State 包含三项变化。
|
|
112
112
|
|
|
113
113
|
不需要保存历史的默认算法不使用私有 state。去重、时间窗口、合并、按任务/位置/当前行为筛选等复杂规则,可以自己编写。未提供的配置由工具补默认值;未知参数或非法 mode 抛错。
|
|
114
114
|
|
|
@@ -12,8 +12,8 @@ export function isReminderMode(value: unknown): value is ReminderMode {
|
|
|
12
12
|
}
|
|
13
13
|
export function defaultConfig(topic: ReminderTopic): Record<string, ReminderMode> {
|
|
14
14
|
if (topic !== 'tasks') throw new Error('Unsupported reminder topic; countdown and ability notifications are owned by CCL.');
|
|
15
|
-
return { started: 'state_only', progress: 'state_only', added: '
|
|
16
|
-
interrupted: 'wake', sabotaged: 'wake', removed: '
|
|
15
|
+
return { started: 'state_only', progress: 'state_only', added: 'silent', completed: 'silent',
|
|
16
|
+
interrupted: 'wake', sabotaged: 'wake', removed: 'silent', updated: 'silent' };
|
|
17
17
|
}
|
|
18
18
|
export function validateDefaultConfig(topic: ReminderTopic, input: unknown): Record<string, ReminderMode> {
|
|
19
19
|
if (!input || typeof input !== 'object' || Array.isArray(input)) throw new Error('Reminder config must be an object.');
|