fix(delegate-task): literal negative-clause kills self-task FP (0.2.0->0.2.1)

«создать задачу себе» false-positive-fired delegate-task instead of
using-tasks (5/5 trials, found by delegate-task-test-trigger). Root cause:
the self-task phrase shares the stem «создать задачу» with the positive
trigger «создать задачу на агента», and the abstract "Does NOT apply when
doing the work yourself" carve-out cannot beat a literal stem-match under
the using-superpowers 1%-rule.

Fix: make the negative literal + routed. Description now lists
«создать задачу себе» / «task for myself» / «поставить себе задачу»
-> using-tasks; body "Ne primenyaetsya" gains a self-assigned bullet plus a
disambiguator («на агента»/«агенту»/«в проект X» = delegate; «себе» = own
board). PATCH bump 0.2.0 -> 0.2.1.

Verification (fresh-context subagents, simulated available-skills registry,
no hint): positives 5/5 -> delegate-task (no regression); negative
«создать задачу себе на завтра» 4/5 -> using-tasks (was 0/5). The 1
residual miss reasoned correctly but tripped on an eval-harness artifact
(prompt forced skill-name-before-reasoning), not description ambiguity.

Wiki: concept page delegate-task-negative-trigger-fp.md + index/log.
Board: [delegate-task-description-fp-fix] -> done.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
2026-06-09 12:40:38 +03:00
parent 731ed420ee
commit 8b22d16c20
5 changed files with 73 additions and 16 deletions

View File

@@ -524,26 +524,19 @@ False-positive check (не должны активировать): «созда
--- ---
## 🔵 [delegate-task-description-fp-fix] — Устранить false-positive активацию `delegate-task` на «создать задачу себе» (self-assigned task). ## 🟢 [delegate-task-description-fp-fix] — Устранить false-positive активацию `delegate-task` на «создать задачу себе» (self-assigned task).
**Находка** (`delegate-task-test-trigger`, 2026-06-09, 5/5 trials): фраза «создать задачу себе [на завтра]» консистентно фаерит `delegate-task` вместо `using-tasks`. Триггер `«создать задачу на агента»` матчится по стему «создать задачу»; негатив-клауза "Does NOT apply when doing the work yourself" слишком абстрактна — субагенты распознавали «себе» в reasoning, но всё равно ставили delegate-task FIRST под 1%-rule. **Находка** (`delegate-task-test-trigger`, 2026-06-09, 5/5 trials): фраза «создать задачу себе [на завтра]» консистентно фаерит `delegate-task` вместо `using-tasks`. Триггер `«создать задачу на агента»` матчится по стему «создать задачу»; негатив-клауза "Does NOT apply when doing the work yourself" слишком абстрактна — субагенты распознавали «себе» в reasoning, но всё равно ставили delegate-task FIRST под 1%-rule.
**Варианты фикса** (один, не меню — рекомендация): добавить «создать задачу себе» / «task for myself» в явный negative-список description (`Does NOT apply ... or for self-assigned tasks on the current board (→ using-tasks)`). Делает дизамбигуатор literal, не абстрактным. Bump PATCH. NB: правка description → нужен re-install + (если меняется триггер-семантика) проверка hermes/mapping. **TDD:** N/A (markdown/description). Верификация = повторный clean-context trigger-прогон.
**TDD:** N/A (markdown/description). Верификация = повторный clean-context trigger-прогон на «создать задачу себе» (ожидание: →using-tasks) + регресс на 5 positive (должны остаться →delegate-task).
**Weight:** needs-claude **Weight:** needs-claude
**Status:** blocked **Status:** done
**Where I stopped:** delivery push failed (diverged) — needs manual reconcile: u have unmerged files. **Where I stopped:** Shipped 2026-06-09. `skills/delegate-task/SKILL.md` 0.2.0→0.2.1 (PATCH). Description negative-clause сделана literal+routed: «создать задачу себе» / «task for myself» / «поставить себе задачу» → using-tasks; body "Не применяется" получил self-assigned буллет + дизамбигуатор («на агента»/«агенту»/«в проект X» = делегирование; «себе»/«myself» = своя доска). Верификация — fresh-context субагенты, симулированный available-skills registry (новое описание + конкуренты using-tasks/using-projects-meta/setup-tasks/session-handoff), без подсказки об ожидаемом ответе: **positives 5/5** (все 5 делегирующих фраз → delegate-task, регресса нет), **negative «создать задачу себе на завтра» 4/5 → using-tasks** (было 0/5 до фикса). Единственный остаточный miss reasoned правильно («себе»→using-tasks), но споткнулся об eval-артефакт (промпт форсил имя скила в первой строке ДО reasoning), не об неоднозначность описания. Concept page `.wiki/concepts/delegate-task-negative-trigger-fp.md` + index/log обновлены. NB: re-install (`~/.claude/skills/`) и hermes/mapping не трогал — install это отдельная baseline-таска (для PATCH достаточно reload-plugins), а правка только negative-clause не меняет tool-touching семантику (mapping mode остаётся pending).
hint: Fix them up in the work tree, and then use 'git add/rm <file>' **Next action:** (none — kept until merged). Optional follow-up: разблокировать `delegate-task-review` (его smoke-test включает этот negative-кейс).
hint: as appropriate to mark resolution and make a commit.
fatal: Exiting because of an unresolved conflict.
**Next action:** Отредактировать `skills/delegate-task/SKILL.md` description: добавить self-assigned-task в negative-clause; bump PATCH (0.2.0→0.2.1); re-run trigger-прогон для верификации (negative «создать задачу себе»→using-tasks, 5 positive без регресса).
**Branch:** n/a **Branch:** n/a
**Owner:** DESKTOP-NSEF0UK:claude-opus:11140
**Claim token:** 5c8b170d-1a5a-41c4-9044-9f7b07ec042f
**Claim expires at:** 2026-06-09T09:49:04.571Z
<!-- created-by: DESKTOP-NSEF0UK:claude-opus:11140 / from: delegate-task-test-trigger finding / 2026-06-09 --> <!-- created-by: DESKTOP-NSEF0UK:claude-opus:11140 / from: delegate-task-test-trigger finding / 2026-06-09 -->
<!-- closed-by: DESKTOP-NSEF0UK:claude-opus:11140 / 2026-06-09 / 0.2.0→0.2.1 PATCH; literal negative-clause; verified pos 5/5 + neg 4/5 (was 0/5); 1 residual miss = eval-harness artifact -->
--- ---

View File

@@ -0,0 +1,59 @@
---
title: delegate-task — literal negative triggers beat abstract carve-outs
type: concept
updated: 2026-06-09
---
# delegate-task — literal negative triggers beat abstract carve-outs
## Symptom
`delegate-task` v0.2.0 false-positive-fired on **«создать задачу себе»** (create a task
for myself) — a self-assigned task that should route to `using-tasks`, not to cross-agent
delegation. The `delegate-task-test-trigger` run measured it at **5/5 trials** consistently
wrong (→ `delegate-task`).
## Root cause
The positive trigger list contained **«создать задачу на агента»**. A self-task phrase
**«создать задачу себе»** shares the stem **«создать задачу»**, so it literal-matched the
positive trigger. The negative clause was abstract — *"Does NOT apply when doing the work
yourself"* — and an abstract carve-out does **not** beat a literal stem-match under the
`using-superpowers` 1%-rule. Clean-context subagents *recognized* the «себе» exception in
their reasoning, yet still invoked `delegate-task` FIRST because the literal match outweighed
the abstract exclusion.
## Fix (v0.2.0 → v0.2.1, PATCH)
Make the negative **literal and routed**, so it competes head-on with the positive at the
same surface level:
> Does NOT apply to self-assigned tasks on your own board (**«создать задачу себе»**,
> **«task for myself»**, **«поставить себе задачу»** → using-tasks), to work you do
> yourself, or to workshop-internal tasks.
Plus a body disambiguator in the "Не применяется" section:
**«на агента» / «агенту» / «в проект X» = делегирование; «себе» / «myself» = своя доска.**
## Verification
Re-ran the `delegate-task-test-trigger` methodology (fresh-context subagents, simulated
available-skills registry with the new description + competitors `using-tasks` /
`using-projects-meta` / `setup-tasks` / `session-handoff`, no hint about the expected
answer):
- **Positives 5/5** — «создать задачу на агента», «поставить задачу агенту», «delegate task
to the books project», «делегировать таску», «tasks_create для проекта X» → all
`delegate-task`. No regression from the literal negative.
- **Negative «создать задачу себе на завтра» 4/5 → `using-tasks`** (was 0/5 before the fix).
The single residual miss reasoned correctly («себе» → using-tasks) but was tripped by an
eval-harness artifact (the prompt forced a skill name on line 1 *before* reasoning),
not by ambiguity in the description.
## Reusable principle
When a skill's positive triggers contain a phrase whose **stem** also appears in a sibling
skill's domain, an abstract "does NOT apply when…" clause is too weak. Put the **exact
colliding negative phrase** in the description with an explicit **→ <sibling-skill>** route.
Literal beats abstract under the 1%-rule. See also [[tdd-criteria-design]] for another
"make the bright line literal, not a judgement call" pattern.

View File

@@ -41,6 +41,7 @@ Catalog of all wiki pages. One line per page, organized by type. Updated on ever
- [project-bootstrap-meta-isolation.md](concepts/project-bootstrap-meta-isolation.md) — project-bootstrap@1.11.0 — Step 1 ships meta-isolation block in `.gitignore` (`!.claude/`, `!.tasks/`, `!.wiki/`, ...) so own greenfield/upgrade projects re-enable agent meta-paths against global `core.excludesFile` cutter. Marker-based append-only on existing files; smoke-tested with negative control - [project-bootstrap-meta-isolation.md](concepts/project-bootstrap-meta-isolation.md) — project-bootstrap@1.11.0 — Step 1 ships meta-isolation block in `.gitignore` (`!.claude/`, `!.tasks/`, `!.wiki/`, ...) so own greenfield/upgrade projects re-enable agent meta-paths against global `core.excludesFile` cutter. Marker-based append-only on existing files; smoke-tested with negative control
- [interns-grep-audit-design](concepts/interns-grep-audit-design.md) — interns-grep-audit-design - [interns-grep-audit-design](concepts/interns-grep-audit-design.md) — interns-grep-audit-design
- [session-handoff-skill-design.md](concepts/session-handoff-skill-design.md) — design rationale for the `session-handoff` skill (sliding overwrite into `.tasks/NEXT_SESSION.md`, phrase whitelist + substantive-commit heuristic, optional PostToolUse hook for harness-side determinism, orient+ask default, project scope, cluster 7/7 closure) - [session-handoff-skill-design.md](concepts/session-handoff-skill-design.md) — design rationale for the `session-handoff` skill (sliding overwrite into `.tasks/NEXT_SESSION.md`, phrase whitelist + substantive-commit heuristic, optional PostToolUse hook for harness-side determinism, orient+ask default, project scope, cluster 7/7 closure)
- [delegate-task-negative-trigger-fp.md](concepts/delegate-task-negative-trigger-fp.md) — `delegate-task` v0.2.1 FP fix: «создать задачу себе» stem-matched the «создать задачу на агента» positive trigger; abstract "does NOT apply when doing the work yourself" carve-out loses to literal stem-match under the 1%-rule → made the negative literal + routed (→ using-tasks). Verified pos 5/5, neg 4/5 (was 0/5)
## Packages ## Packages

View File

@@ -65,3 +65,5 @@ Parseable: `grep "^## \[" .wiki/log.md | tail -20`.
## [2026-05-25] decision | install-cross-platform — `install.{ps1,sh}` paired-script parity contract documented; `--prune` / `-Prune` flag rationale (combined-with-install, global-scan ignores names filter, default-off, print-and-delete no prompt); shipped in commit `6cf0e98` with `[skip-tdd: wrapper]` carve-out + smoke-test evidence; closes 2/3 of `[install-ps1]` acceptance (the doc + flag), `dist/`-prune analogue deferred to `build` scripts ## [2026-05-25] decision | install-cross-platform — `install.{ps1,sh}` paired-script parity contract documented; `--prune` / `-Prune` flag rationale (combined-with-install, global-scan ignores names filter, default-off, print-and-delete no prompt); shipped in commit `6cf0e98` with `[skip-tdd: wrapper]` carve-out + smoke-test evidence; closes 2/3 of `[install-ps1]` acceptance (the doc + flag), `dist/`-prune analogue deferred to `build` scripts
## [2026-05-25] decision | install-cross-platform extended to build scripts — `build.{ps1,sh}` get the symmetric `--prune` / `-Prune` flag (removes `dist/<name>.skill` where `<name>` is not in `skills/`). Bash delegation to `powershell.exe -File build.ps1` does NOT forward the flag — bash runs prune itself against the shared `dist/`. Both paths smoke-tested with fake stale .skill files against real dist/. Closes `[install-ps1-build-prune-followup]`. ## [2026-05-25] decision | install-cross-platform extended to build scripts — `build.{ps1,sh}` get the symmetric `--prune` / `-Prune` flag (removes `dist/<name>.skill` where `<name>` is not in `skills/`). Bash delegation to `powershell.exe -File build.ps1` does NOT forward the flag — bash runs prune itself against the shared `dist/`. Both paths smoke-tested with fake stale .skill files against real dist/. Closes `[install-ps1-build-prune-followup]`.
## [2026-06-09] decision | delegate-task-negative-trigger-fp — `delegate-task` 0.2.0→0.2.1 (PATCH): fixed 5/5-consistent false-positive on «создать задачу себе». Root cause: self-task phrase shares stem «создать задачу» with the «создать задачу на агента» positive trigger; the abstract "Does NOT apply when doing the work yourself" carve-out can't beat a literal stem-match under the 1%-rule. Fix: made the negative literal + routed («создать задачу себе» / «task for myself» / «поставить себе задачу» → using-tasks) in description + body disambiguator («на агента»/«агенту» = delegate; «себе» = own board). Re-verified via fresh-context subagent trigger run: positives 5/5 (no regression), negative 4/5 → using-tasks (was 0/5); the 1 residual miss was an eval-harness artifact (forced skill-name-before-reasoning), not description ambiguity. Concept page written; reusable principle = put the exact colliding negative phrase with an explicit →sibling route, literal beats abstract.

View File

@@ -1,12 +1,13 @@
--- ---
name: delegate-task name: delegate-task
version: 0.2.0 version: 0.2.1
description: > description: >
Use when delegating a task to another agent or project via Use when delegating a task to another agent or project via
mcp__projects-meta__tasks_create. Triggers: «делегировать таску», mcp__projects-meta__tasks_create. Triggers: «делегировать таску»,
«delegate task», «создать задачу на агента», «поставить задачу агенту», «delegate task», «создать задачу на агента», «поставить задачу агенту»,
«tasks_create для». Does NOT apply when doing the work yourself or for «tasks_create для». Does NOT apply to self-assigned tasks on your own
workshop-internal tasks. board («создать задачу себе», «task for myself», «поставить себе задачу»
→ using-tasks), to work you do yourself, or to workshop-internal tasks.
--- ---
# delegate-task # delegate-task
@@ -21,6 +22,7 @@ description: >
**Не применяется:** **Не применяется:**
- Работа которую выполняешь сам в текущей сессии. - Работа которую выполняешь сам в текущей сессии.
- Self-assigned таски на своей доске («создать задачу себе», «task for myself», «поставить себе задачу») → `using-tasks`, не делегирование. Дизамбигуатор: «на агента»/«агенту»/«в проект X» = делегирование; «себе»/«myself» = своя доска.
- Workshop-internal таски (`.workshop/.tasks/` — workshop-meta, не делегирование). - Workshop-internal таски (`.workshop/.tasks/` — workshop-meta, не делегирование).
- `tasks_create` с `target=agenda` (cross-project agenda — не делегирование агенту). - `tasks_create` с `target=agenda` (cross-project agenda — не делегирование агенту).