feat(delegate-task): session_break authoring field [v0.2.2]
Add the authoring side of the `session_break` marker whose consumer side shipped in using-tasks v1.2.0. At delegation time the author can now mark a task so that, after it closes, an autonomous runner pauses instead of chaining the next task. - Pre-flight gate 5->6 questions: new Q (item 5, after notify) — "Session-break после этой задачи? (domain-switch / milestone / heavy infra)". Yes -> set session_break in body; no -> omit (default unchanged). - Template trailer gains optional `[**session_break:** true | "<hint>"]` with inline comment (same lowercase frontmatter key using-tasks reads). - Usage-guidance block: three set-it cases + tie to using-tasks Task-completion step 6 / SESSION BOUNDARY line. - What-NOT-to-do bullet: don't set it routinely (real-boundary marker, not a default). - Wiki concept page concepts/delegate-task-session-break.md (links using-tasks-session-break) + index + log. PATCH bump: additive optional field + one pre-flight question, no existing behaviour changed. Markdown policy artifact — no test surface (TDD N/A). Closes [session-break-delegate-task]. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
46
.wiki/concepts/delegate-task-session-break.md
Normal file
46
.wiki/concepts/delegate-task-session-break.md
Normal file
@@ -0,0 +1,46 @@
|
||||
---
|
||||
title: delegate-task session_break field
|
||||
type: concept
|
||||
tags: [delegate-task, using-tasks, autonomous-runner, session-boundary]
|
||||
updated: 2026-06-09
|
||||
---
|
||||
|
||||
# delegate-task `session_break` field
|
||||
|
||||
`delegate-task` v0.2.2 adds an optional `session_break` field to the task-body template, plus
|
||||
a sixth pre-flight question. This is the **authoring** side of the marker whose **consumer**
|
||||
side lives in `using-tasks` — see [[using-tasks-session-break]].
|
||||
|
||||
## Problem
|
||||
|
||||
`using-tasks` v1.2.0 can stop an autonomous runner after a task closes (instead of chaining
|
||||
`tasks_claim_next`) **iff** the closed task carries a `session_break` marker. But nothing in the
|
||||
delegation flow prompted the author to set it — so the capability sat unused unless someone
|
||||
hand-edited the task body. The marker has to be *placed at delegation time* to be useful.
|
||||
|
||||
## Design
|
||||
|
||||
- **Pre-flight Q6** (after Q5 `notify`): *"Session-break после этой задачи? — нужен ли разрыв
|
||||
сессии после её закрытия (domain-switch, milestone, heavy infra)?"* If yes → set
|
||||
`session_break` in the task body; if no → omit it (default unchanged).
|
||||
- **Template field** (optional, in the trailer next to `weight` / `notify` / `allow_upgrade`):
|
||||
`session_break: true | "<следующий трек / hint>"` with an inline comment pointing at the
|
||||
`using-tasks` stop behaviour. `session_break` (lowercase, underscore) is the same frontmatter
|
||||
key `using-tasks` reads.
|
||||
- **Value:** `true` (next track = "см. STATUS.md") or a hint string naming the next track.
|
||||
|
||||
## When to set it (three cases)
|
||||
|
||||
1. **Смена домена / репо** — the task ends one track before an unrelated one begins.
|
||||
2. **Milestone-задача** — the last sub-task in a feature's group.
|
||||
3. **Тяжёлая инфра-задача** — shared checkout, migrations, deploy — where it's sane to stop and
|
||||
inspect state before continuing.
|
||||
|
||||
Not a default: setting it routinely would make `using-tasks` tear the session after every
|
||||
close. It is a marker of a *real* boundary, an authoring choice — same rationale as the
|
||||
consumer-side "marker not heuristic" argument in [[using-tasks-session-break]].
|
||||
|
||||
## Versioning
|
||||
|
||||
PATCH bump (0.2.1 → 0.2.2): additive optional field + one extra pre-flight question, no existing
|
||||
behaviour changed. (The version target was fixed by the delegating task.)
|
||||
@@ -42,6 +42,7 @@ Catalog of all wiki pages. One line per page, organized by type. Updated on ever
|
||||
- [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)
|
||||
- [using-tasks-session-break.md](concepts/using-tasks-session-break.md) — `using-tasks` v1.2.0 `session_break` marker: task-author-set boolean/string flag; after a task closes 🟢, before `tasks_claim_next`, an autonomous agent prints the verbatim SESSION BOUNDARY line and stops instead of chaining the next task. Absent → unchanged
|
||||
- [delegate-task-session-break.md](concepts/delegate-task-session-break.md) — `delegate-task` v0.2.2 — authoring side of the `session_break` marker (consumer = [[using-tasks-session-break]]): pre-flight Q6 + optional template field `session_break: true | "<hint>"`; three set-it cases (domain-switch / milestone / heavy infra); not a default
|
||||
- [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
|
||||
|
||||
@@ -67,4 +67,5 @@ Parseable: `grep "^## \[" .wiki/log.md | tail -20`.
|
||||
## [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.
|
||||
## [2026-06-09] decision | delegate-task-session-break — `delegate-task` 0.2.1→0.2.2 (PATCH): authoring side of the `session_break` marker (consumer = using-tasks v1.2.0). Added pre-flight Q6 (after notify): "Session-break после этой задачи? (domain-switch / milestone / heavy infra)"; if yes → set optional template field `session_break: true | "<hint>"` (trailer, next to weight/notify/allow_upgrade; same lowercase frontmatter key using-tasks reads). Usage guidance lists three set-it cases; What-NOT-to-do bullet warns against setting it routinely (it's a real-boundary marker, not a default). Wiki concept page concepts/delegate-task-session-break.md + index. Pairs with using-tasks-session-break.
|
||||
## [2026-06-09] decision | using-tasks-session-break — `using-tasks` 1.1.0→1.2.0 (MINOR): added the `session_break` marker. Task author sets `session_break: true | "<hint>"` in task frontmatter (mirrored as `**Session break:**` on the local board); after the task closes 🟢, before `tasks_claim_next`, an autonomous agent prints the verbatim line `🔚 SESSION BOUNDARY — [slug] закрыта. Рекомендую завершить текущую сессию. Следующий трек: [value | "см. STATUS.md"]` and stops instead of chaining the next task. Absent → behaviour unchanged. Enforced in Task completion step 6 + Rules bullet + format docs. Marker not heuristic: the stop-point is an authoring choice, not a runner guess.
|
||||
|
||||
Reference in New Issue
Block a user