Skip to content

Commit 172f10f

Browse files
committed
docs(skill): disambiguate Flashcat workspace spaces
1 parent 45677ff commit 172f10f

2 files changed

Lines changed: 29 additions & 0 deletions

File tree

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
package skilldoc
2+
3+
import (
4+
"os"
5+
"strings"
6+
"testing"
7+
)
8+
9+
func TestChannelCardDisambiguatesFlashcatWorkspace(t *testing.T) {
10+
body, err := os.ReadFile("../../skills/flashduty/reference/channel.md")
11+
if err != nil {
12+
t.Fatal(err)
13+
}
14+
text := string(body)
15+
for _, want := range []string{
16+
"协作空间",
17+
"Flashcat workspace",
18+
"灭火图",
19+
"firemap",
20+
"do not silently switch",
21+
} {
22+
if !strings.Contains(text, want) {
23+
t.Errorf("channel card must disambiguate Flashduty channel vs Flashcat workspace; missing %q", want)
24+
}
25+
}
26+
}

skills/flashduty/reference/channel.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,8 @@ Prereq: `SKILL.md` read. **SKILL.md + this card = full competence on channels
66

77
"协作空间 / 频道 / 渠道 / 告警分组 / 降噪 / 静默 / 抑制 / 丢弃 / 升级策略 / 告警收敛 / channel / collaboration space / escalation rule / silence / inhibit / drop rule" → **channel**, NOT `incident` (incidents live _inside_ a channel) or `alert` (alerts are routed _into_ a channel). **`协作空间` (collaboration space) IS the `channel` API noun** — a naive translation would be "频道", but Flashduty's product surfaces it as 协作空间. Key IDs: **`channel-id` (int)** from `channel list`; **`rule-id` (MongoDB ObjectID string)** from `escalate-rule-list`, `inhibit-rule-list`, `silence-rule-list`, `unsubscribe-rule-list`.
88

9+
**Flashcat workspace exception.** When the user asks whether a "空间" is healthy, red/green, or specifically mentions **灭火图 / firemap**, do not assume they mean a Flashduty channel. In that context, "空间" may be a **Flashcat workspace**, and the answer must come from the Flashcat/firemap surface rather than channel incident stats. If you first resolved a name as a Flashduty `channel-id` and later resolve the same visible name as a Flashcat `workspace-id`, **do not silently switch** — tell the user these are different objects and state which ID/surface each conclusion uses.
10+
911
## Intent → verb
1012

1113
| want | verb |
@@ -38,6 +40,7 @@ fduty channel create --channel-name "production-api" --team-id <team-id> \
3840
# → returns channel_id; use it below
3941

4042
# 3. add an escalation rule (all flags; layers is required via --data)
43+
# API field `person_ids` expects member IDs from `fduty member list`.
4144
fduty channel escalate-rule-create \
4245
--channel-id <channel-id> --rule-name "P1 on-call" --template-id <template-id> \
4346
--data '{"layers":[{"target":{"person_ids":[<member-id>],"by":{"critical":["voice","sms"],"warning":["feishu"]}},"notify_step":5,"max_times":3,"escalate_window":30}]}'

0 commit comments

Comments
 (0)