fix(team): use session-id instead of team-name in team_msg across all skills

Root cause: team_msg --team parameter maps directly to filesystem path
.workflow/.team/{value}/.msg/, so using team-name creates wrong directory.

Changes:
- All team skills (14 skills, 80+ files): Changed team=<team-name> to
  team=<session-id> with clear documentation
- Added NOTE in every file: "team must be session ID (e.g., TLS-xxx-date),
  NOT team name. Extract from Session: field in task description."
- CLI fallback examples updated: --team brainstorm -> --team <session-id>

Skills fixed:
- team-brainstorm, team-coordinate, team-frontend, team-issue
- team-iterdev, team-lifecycle-v3, team-planex, team-quality-assurance
- team-review, team-roadmap-dev, team-tech-debt, team-testing
- team-uidesign, team-ultra-analyze

Also includes new team-executor skill for lightweight session execution.
This commit is contained in:
catlog22
2026-02-27 18:48:39 +08:00
parent 3b92bfae8c
commit 8566e3af44
90 changed files with 2133 additions and 193 deletions

View File

@@ -55,7 +55,7 @@ for (const stageTask of pipelineTasks) {
if (!workerConfig) {
mcp__ccw-tools__team_msg({
operation: "log", team: teamName, from: "coordinator",
operation: "log", team: sessionId // MUST be session ID (e.g., RC-xxx-date), NOT team name, from: "coordinator",
to: "user", type: "error",
summary: `[coordinator] Unknown stage prefix: ${stagePrefix}, skipping`
})
@@ -66,7 +66,7 @@ for (const stageTask of pipelineTasks) {
TaskUpdate({ taskId: stageTask.id, status: 'in_progress' })
mcp__ccw-tools__team_msg({
operation: "log", team: teamName, from: "coordinator",
operation: "log", team: sessionId // MUST be session ID (e.g., RC-xxx-date), NOT team name, from: "coordinator",
to: workerConfig.role, type: "stage_transition",
summary: `[coordinator] Starting stage: ${stageTask.subject} -> ${workerConfig.role}`
})
@@ -86,7 +86,7 @@ for (const stageTask of pipelineTasks) {
if (action === 'skip') continue
} else {
mcp__ccw-tools__team_msg({
operation: "log", team: teamName, from: "coordinator",
operation: "log", team: sessionId // MUST be session ID (e.g., RC-xxx-date), NOT team name, from: "coordinator",
to: "user", type: "stage_transition",
summary: `[coordinator] Stage complete: ${stageTask.subject}`
})
@@ -96,7 +96,7 @@ for (const stageTask of pipelineTasks) {
if (stagePrefix === 'SCAN') {
const mem = JSON.parse(Read(`${sessionFolder}/shared-memory.json`))
if ((mem.findings_count || 0) === 0) {
mcp__ccw-tools__team_msg({ operation: "log", team: teamName, from: "coordinator",
mcp__ccw-tools__team_msg({ operation: "log", team: sessionId // MUST be session ID (e.g., RC-xxx-date), NOT team name, from: "coordinator",
to: "user", type: "pipeline_complete",
summary: `[coordinator] 0 findings. Code is clean. Skipping review/fix.` })
for (const r of pipelineTasks.slice(pipelineTasks.indexOf(stageTask) + 1))
@@ -163,7 +163,7 @@ function buildWorkerArgs(stageTask, workerConfig) {
```javascript
function handleStageFailure(stageTask, taskState, workerConfig, autoYes) {
if (autoYes) {
mcp__ccw-tools__team_msg({ operation: "log", team: teamName, from: "coordinator",
mcp__ccw-tools__team_msg({ operation: "log", team: sessionId // MUST be session ID (e.g., RC-xxx-date), NOT team name, from: "coordinator",
to: "user", type: "error",
summary: `[coordinator] [auto] ${stageTask.subject} incomplete, skipping` })
TaskUpdate({ taskId: stageTask.id, status: 'deleted' })
@@ -191,7 +191,7 @@ function handleStageFailure(stageTask, taskState, workerConfig, autoYes) {
TaskUpdate({ taskId: stageTask.id, status: 'deleted' })
return 'skip'
} else {
mcp__ccw-tools__team_msg({ operation: "log", team: teamName, from: "coordinator",
mcp__ccw-tools__team_msg({ operation: "log", team: sessionId // MUST be session ID (e.g., RC-xxx-date), NOT team name, from: "coordinator",
to: "user", type: "error",
summary: `[coordinator] User aborted at: ${stageTask.subject}` })
return 'abort'

View File

@@ -86,7 +86,7 @@ Before every SendMessage, log via `mcp__ccw-tools__team_msg`:
```
mcp__ccw-tools__team_msg({
operation: "log",
team: "team-review",
team: <session-id>, // MUST be session ID (e.g., RC-xxx-date), NOT team name. Extract from Session: field in task description.
from: "coordinator",
to: "user",
type: "dispatch_ready",
@@ -97,7 +97,7 @@ mcp__ccw-tools__team_msg({
**CLI fallback** (when MCP unavailable):
```
Bash("ccw team log --team team-review --from coordinator --to user --type dispatch_ready --summary \"[coordinator] Task chain created\" --json")
Bash("ccw team log --team <session-id> --from coordinator --to user --type dispatch_ready --summary \"[coordinator] Task chain created\" --json")
```
---

View File

@@ -67,7 +67,7 @@ Before every SendMessage, log via `mcp__ccw-tools__team_msg`:
```
mcp__ccw-tools__team_msg({
operation: "log",
team: "team-review",
team: <session-id>, // MUST be session ID (e.g., RC-xxx-date), NOT team name. Extract from Session: field in task description.
from: "fixer",
to: "coordinator",
type: "fix_complete",
@@ -79,7 +79,7 @@ mcp__ccw-tools__team_msg({
**CLI fallback** (when MCP unavailable):
```
Bash("ccw team log --team team-review --from fixer --to coordinator --type fix_complete --summary \"[fixer] Fix complete\" --ref <path> --json")
Bash("ccw team log --team <session-id> --from fixer --to coordinator --type fix_complete --summary \"[fixer] Fix complete\" --ref <path> --json")
```
---

View File

@@ -66,7 +66,7 @@ Before every SendMessage, log via `mcp__ccw-tools__team_msg`:
```
mcp__ccw-tools__team_msg({
operation: "log",
team: "team-review",
team: <session-id>, // MUST be session ID (e.g., RC-xxx-date), NOT team name. Extract from Session: field in task description.
from: "reviewer",
to: "coordinator",
type: "review_complete",
@@ -78,7 +78,7 @@ mcp__ccw-tools__team_msg({
**CLI fallback** (when MCP unavailable):
```
Bash("ccw team log --team team-review --from reviewer --to coordinator --type review_complete --summary \"[reviewer] Review complete\" --ref <path> --json")
Bash("ccw team log --team <session-id> --from reviewer --to coordinator --type review_complete --summary \"[reviewer] Review complete\" --ref <path> --json")
```
---

View File

@@ -67,7 +67,7 @@ Before every SendMessage, log via `mcp__ccw-tools__team_msg`:
```
mcp__ccw-tools__team_msg({
operation: "log",
team: "team-review",
team: <session-id>, // MUST be session ID (e.g., RC-xxx-date), NOT team name. Extract from Session: field in task description.
from: "scanner",
to: "coordinator",
type: "scan_complete",
@@ -79,7 +79,7 @@ mcp__ccw-tools__team_msg({
**CLI fallback** (when MCP unavailable):
```
Bash("ccw team log --team team-review --from scanner --to coordinator --type scan_complete --summary \"[scanner] Scan complete\" --ref <path> --json")
Bash("ccw team log --team <session-id> --from scanner --to coordinator --type scan_complete --summary \"[scanner] Scan complete\" --ref <path> --json")
```
---