From 8b9fdfa05be67b47b66bf02c8d5af2eaf8edbb8d Mon Sep 17 00:00:00 2001 From: Garry Tan Date: Fri, 3 Apr 2026 23:03:30 -0700 Subject: [PATCH] fix: skill invocation during plan mode takes precedence over generic plan mode Adds a "Skill Invocation During Plan Mode" section to the preamble resolver so all generated SKILL.md files include it. Fixes a bug where Claude treats loaded skill content as reference material instead of executable instructions, and keeps trying to ExitPlanMode instead of following the skill workflow step by step. Co-Authored-By: Claude Opus 4.6 (1M context) --- SKILL.md | 25 +++++++++++++++++++++++++ benchmark/SKILL.md | 25 +++++++++++++++++++++++++ browse/SKILL.md | 25 +++++++++++++++++++++++++ canary/SKILL.md | 25 +++++++++++++++++++++++++ checkpoint/SKILL.md | 25 +++++++++++++++++++++++++ codex/SKILL.md | 27 ++++++++++++++++++++++++++- connect-chrome/SKILL.md | 25 +++++++++++++++++++++++++ cso/SKILL.md | 25 +++++++++++++++++++++++++ design-consultation/SKILL.md | 25 +++++++++++++++++++++++++ design-html/SKILL.md | 25 +++++++++++++++++++++++++ design-review/SKILL.md | 25 +++++++++++++++++++++++++ design-shotgun/SKILL.md | 25 +++++++++++++++++++++++++ devex-review/SKILL.md | 27 ++++++++++++++++++++++++++- document-release/SKILL.md | 25 +++++++++++++++++++++++++ health/SKILL.md | 25 +++++++++++++++++++++++++ investigate/SKILL.md | 25 +++++++++++++++++++++++++ land-and-deploy/SKILL.md | 25 +++++++++++++++++++++++++ learn/SKILL.md | 25 +++++++++++++++++++++++++ office-hours/SKILL.md | 25 +++++++++++++++++++++++++ plan-ceo-review/SKILL.md | 27 ++++++++++++++++++++++++++- plan-design-review/SKILL.md | 27 ++++++++++++++++++++++++++- plan-eng-review/SKILL.md | 27 ++++++++++++++++++++++++++- qa-only/SKILL.md | 25 +++++++++++++++++++++++++ qa/SKILL.md | 25 +++++++++++++++++++++++++ retro/SKILL.md | 25 +++++++++++++++++++++++++ review/SKILL.md | 25 +++++++++++++++++++++++++ scripts/resolvers/preamble.ts | 25 +++++++++++++++++++++++++ setup-browser-cookies/SKILL.md | 25 +++++++++++++++++++++++++ setup-deploy/SKILL.md | 25 +++++++++++++++++++++++++ ship/SKILL.md | 25 +++++++++++++++++++++++++ test/gen-skill-docs.test.ts | 12 ++++++++++++ 31 files changed, 767 insertions(+), 5 deletions(-) diff --git a/SKILL.md b/SKILL.md index 1bb898aa..258a7e4a 100644 --- a/SKILL.md +++ b/SKILL.md @@ -309,6 +309,31 @@ artifacts that inform the plan, not code changes: These are read-only in spirit — they inspect the live site, generate visual artifacts, or get independent opinions. They do NOT modify project source files. +## Skill Invocation During Plan Mode + +If a user invokes a skill during plan mode, that invoked skill workflow takes +precedence over generic plan mode behavior until it finishes or the user explicitly +cancels that skill. + +Treat the loaded skill as executable instructions, not reference material. Follow +it step by step. Do not summarize, skip, reorder, or shortcut its steps. + +If the skill says to use AskUserQuestion, do that. Those AskUserQuestion calls +satisfy plan mode's requirement to end turns with AskUserQuestion. + +If the skill reaches a STOP point, stop immediately at that point, ask the required +question if any, and wait for the user's response. Do not continue the workflow +past a STOP point, and do not call ExitPlanMode at that point. + +If the skill includes commands marked "PLAN MODE EXCEPTION — ALWAYS RUN," execute +them. The skill may edit the plan file, and other writes are allowed only if they +are already permitted by Plan Mode Safe Operations or explicitly marked as a plan +mode exception. + +Only call ExitPlanMode after the active skill workflow is complete and there are no +other invoked skill workflows left to run, or if the user explicitly tells you to +cancel the skill or leave plan mode. + ## Plan Status Footer When you are in plan mode and about to call ExitPlanMode: diff --git a/benchmark/SKILL.md b/benchmark/SKILL.md index 6f7dc894..156ae8cf 100644 --- a/benchmark/SKILL.md +++ b/benchmark/SKILL.md @@ -312,6 +312,31 @@ artifacts that inform the plan, not code changes: These are read-only in spirit — they inspect the live site, generate visual artifacts, or get independent opinions. They do NOT modify project source files. +## Skill Invocation During Plan Mode + +If a user invokes a skill during plan mode, that invoked skill workflow takes +precedence over generic plan mode behavior until it finishes or the user explicitly +cancels that skill. + +Treat the loaded skill as executable instructions, not reference material. Follow +it step by step. Do not summarize, skip, reorder, or shortcut its steps. + +If the skill says to use AskUserQuestion, do that. Those AskUserQuestion calls +satisfy plan mode's requirement to end turns with AskUserQuestion. + +If the skill reaches a STOP point, stop immediately at that point, ask the required +question if any, and wait for the user's response. Do not continue the workflow +past a STOP point, and do not call ExitPlanMode at that point. + +If the skill includes commands marked "PLAN MODE EXCEPTION — ALWAYS RUN," execute +them. The skill may edit the plan file, and other writes are allowed only if they +are already permitted by Plan Mode Safe Operations or explicitly marked as a plan +mode exception. + +Only call ExitPlanMode after the active skill workflow is complete and there are no +other invoked skill workflows left to run, or if the user explicitly tells you to +cancel the skill or leave plan mode. + ## Plan Status Footer When you are in plan mode and about to call ExitPlanMode: diff --git a/browse/SKILL.md b/browse/SKILL.md index 3931c7f8..d224b309 100644 --- a/browse/SKILL.md +++ b/browse/SKILL.md @@ -311,6 +311,31 @@ artifacts that inform the plan, not code changes: These are read-only in spirit — they inspect the live site, generate visual artifacts, or get independent opinions. They do NOT modify project source files. +## Skill Invocation During Plan Mode + +If a user invokes a skill during plan mode, that invoked skill workflow takes +precedence over generic plan mode behavior until it finishes or the user explicitly +cancels that skill. + +Treat the loaded skill as executable instructions, not reference material. Follow +it step by step. Do not summarize, skip, reorder, or shortcut its steps. + +If the skill says to use AskUserQuestion, do that. Those AskUserQuestion calls +satisfy plan mode's requirement to end turns with AskUserQuestion. + +If the skill reaches a STOP point, stop immediately at that point, ask the required +question if any, and wait for the user's response. Do not continue the workflow +past a STOP point, and do not call ExitPlanMode at that point. + +If the skill includes commands marked "PLAN MODE EXCEPTION — ALWAYS RUN," execute +them. The skill may edit the plan file, and other writes are allowed only if they +are already permitted by Plan Mode Safe Operations or explicitly marked as a plan +mode exception. + +Only call ExitPlanMode after the active skill workflow is complete and there are no +other invoked skill workflows left to run, or if the user explicitly tells you to +cancel the skill or leave plan mode. + ## Plan Status Footer When you are in plan mode and about to call ExitPlanMode: diff --git a/canary/SKILL.md b/canary/SKILL.md index f1dca423..e7153e93 100644 --- a/canary/SKILL.md +++ b/canary/SKILL.md @@ -421,6 +421,31 @@ artifacts that inform the plan, not code changes: These are read-only in spirit — they inspect the live site, generate visual artifacts, or get independent opinions. They do NOT modify project source files. +## Skill Invocation During Plan Mode + +If a user invokes a skill during plan mode, that invoked skill workflow takes +precedence over generic plan mode behavior until it finishes or the user explicitly +cancels that skill. + +Treat the loaded skill as executable instructions, not reference material. Follow +it step by step. Do not summarize, skip, reorder, or shortcut its steps. + +If the skill says to use AskUserQuestion, do that. Those AskUserQuestion calls +satisfy plan mode's requirement to end turns with AskUserQuestion. + +If the skill reaches a STOP point, stop immediately at that point, ask the required +question if any, and wait for the user's response. Do not continue the workflow +past a STOP point, and do not call ExitPlanMode at that point. + +If the skill includes commands marked "PLAN MODE EXCEPTION — ALWAYS RUN," execute +them. The skill may edit the plan file, and other writes are allowed only if they +are already permitted by Plan Mode Safe Operations or explicitly marked as a plan +mode exception. + +Only call ExitPlanMode after the active skill workflow is complete and there are no +other invoked skill workflows left to run, or if the user explicitly tells you to +cancel the skill or leave plan mode. + ## Plan Status Footer When you are in plan mode and about to call ExitPlanMode: diff --git a/checkpoint/SKILL.md b/checkpoint/SKILL.md index 96a41dc7..2967f14c 100644 --- a/checkpoint/SKILL.md +++ b/checkpoint/SKILL.md @@ -424,6 +424,31 @@ artifacts that inform the plan, not code changes: These are read-only in spirit — they inspect the live site, generate visual artifacts, or get independent opinions. They do NOT modify project source files. +## Skill Invocation During Plan Mode + +If a user invokes a skill during plan mode, that invoked skill workflow takes +precedence over generic plan mode behavior until it finishes or the user explicitly +cancels that skill. + +Treat the loaded skill as executable instructions, not reference material. Follow +it step by step. Do not summarize, skip, reorder, or shortcut its steps. + +If the skill says to use AskUserQuestion, do that. Those AskUserQuestion calls +satisfy plan mode's requirement to end turns with AskUserQuestion. + +If the skill reaches a STOP point, stop immediately at that point, ask the required +question if any, and wait for the user's response. Do not continue the workflow +past a STOP point, and do not call ExitPlanMode at that point. + +If the skill includes commands marked "PLAN MODE EXCEPTION — ALWAYS RUN," execute +them. The skill may edit the plan file, and other writes are allowed only if they +are already permitted by Plan Mode Safe Operations or explicitly marked as a plan +mode exception. + +Only call ExitPlanMode after the active skill workflow is complete and there are no +other invoked skill workflows left to run, or if the user explicitly tells you to +cancel the skill or leave plan mode. + ## Plan Status Footer When you are in plan mode and about to call ExitPlanMode: diff --git a/codex/SKILL.md b/codex/SKILL.md index 47d7521a..5706dd8c 100644 --- a/codex/SKILL.md +++ b/codex/SKILL.md @@ -441,6 +441,31 @@ artifacts that inform the plan, not code changes: These are read-only in spirit — they inspect the live site, generate visual artifacts, or get independent opinions. They do NOT modify project source files. +## Skill Invocation During Plan Mode + +If a user invokes a skill during plan mode, that invoked skill workflow takes +precedence over generic plan mode behavior until it finishes or the user explicitly +cancels that skill. + +Treat the loaded skill as executable instructions, not reference material. Follow +it step by step. Do not summarize, skip, reorder, or shortcut its steps. + +If the skill says to use AskUserQuestion, do that. Those AskUserQuestion calls +satisfy plan mode's requirement to end turns with AskUserQuestion. + +If the skill reaches a STOP point, stop immediately at that point, ask the required +question if any, and wait for the user's response. Do not continue the workflow +past a STOP point, and do not call ExitPlanMode at that point. + +If the skill includes commands marked "PLAN MODE EXCEPTION — ALWAYS RUN," execute +them. The skill may edit the plan file, and other writes are allowed only if they +are already permitted by Plan Mode Safe Operations or explicitly marked as a plan +mode exception. + +Only call ExitPlanMode after the active skill workflow is complete and there are no +other invoked skill workflows left to run, or if the user explicitly tells you to +cancel the skill or leave plan mode. + ## Plan Status Footer When you are in plan mode and about to call ExitPlanMode: @@ -687,7 +712,7 @@ Parse each JSONL entry. Each skill logs different fields: → Findings: "{issues_found} issues, {critical_gaps} critical gaps" - **plan-design-review**: \`status\`, \`initial_score\`, \`overall_score\`, \`unresolved\`, \`decisions_made\`, \`commit\` → Findings: "score: {initial_score}/10 → {overall_score}/10, {decisions_made} decisions" -- **plan-devex-review**: \`status\`, \`initial_score\`, \`overall_score\`, \`product_type\`, \`tthw_current\`, \`tthw_target\`, \`unresolved\`, \`commit\` +- **plan-devex-review**: \`status\`, \`initial_score\`, \`overall_score\`, \`product_type\`, \`tthw_current\`, \`tthw_target\`, \`mode\`, \`persona\`, \`competitive_tier\`, \`unresolved\`, \`commit\` → Findings: "score: {initial_score}/10 → {overall_score}/10, TTHW: {tthw_current} → {tthw_target}" - **devex-review**: \`status\`, \`overall_score\`, \`product_type\`, \`tthw_measured\`, \`dimensions_tested\`, \`dimensions_inferred\`, \`boomerang\`, \`commit\` → Findings: "score: {overall_score}/10, TTHW: {tthw_measured}, {dimensions_tested} tested/{dimensions_inferred} inferred" diff --git a/connect-chrome/SKILL.md b/connect-chrome/SKILL.md index 4e627931..ca15bfac 100644 --- a/connect-chrome/SKILL.md +++ b/connect-chrome/SKILL.md @@ -438,6 +438,31 @@ artifacts that inform the plan, not code changes: These are read-only in spirit — they inspect the live site, generate visual artifacts, or get independent opinions. They do NOT modify project source files. +## Skill Invocation During Plan Mode + +If a user invokes a skill during plan mode, that invoked skill workflow takes +precedence over generic plan mode behavior until it finishes or the user explicitly +cancels that skill. + +Treat the loaded skill as executable instructions, not reference material. Follow +it step by step. Do not summarize, skip, reorder, or shortcut its steps. + +If the skill says to use AskUserQuestion, do that. Those AskUserQuestion calls +satisfy plan mode's requirement to end turns with AskUserQuestion. + +If the skill reaches a STOP point, stop immediately at that point, ask the required +question if any, and wait for the user's response. Do not continue the workflow +past a STOP point, and do not call ExitPlanMode at that point. + +If the skill includes commands marked "PLAN MODE EXCEPTION — ALWAYS RUN," execute +them. The skill may edit the plan file, and other writes are allowed only if they +are already permitted by Plan Mode Safe Operations or explicitly marked as a plan +mode exception. + +Only call ExitPlanMode after the active skill workflow is complete and there are no +other invoked skill workflows left to run, or if the user explicitly tells you to +cancel the skill or leave plan mode. + ## Plan Status Footer When you are in plan mode and about to call ExitPlanMode: diff --git a/cso/SKILL.md b/cso/SKILL.md index b1a1346d..20efe14b 100644 --- a/cso/SKILL.md +++ b/cso/SKILL.md @@ -426,6 +426,31 @@ artifacts that inform the plan, not code changes: These are read-only in spirit — they inspect the live site, generate visual artifacts, or get independent opinions. They do NOT modify project source files. +## Skill Invocation During Plan Mode + +If a user invokes a skill during plan mode, that invoked skill workflow takes +precedence over generic plan mode behavior until it finishes or the user explicitly +cancels that skill. + +Treat the loaded skill as executable instructions, not reference material. Follow +it step by step. Do not summarize, skip, reorder, or shortcut its steps. + +If the skill says to use AskUserQuestion, do that. Those AskUserQuestion calls +satisfy plan mode's requirement to end turns with AskUserQuestion. + +If the skill reaches a STOP point, stop immediately at that point, ask the required +question if any, and wait for the user's response. Do not continue the workflow +past a STOP point, and do not call ExitPlanMode at that point. + +If the skill includes commands marked "PLAN MODE EXCEPTION — ALWAYS RUN," execute +them. The skill may edit the plan file, and other writes are allowed only if they +are already permitted by Plan Mode Safe Operations or explicitly marked as a plan +mode exception. + +Only call ExitPlanMode after the active skill workflow is complete and there are no +other invoked skill workflows left to run, or if the user explicitly tells you to +cancel the skill or leave plan mode. + ## Plan Status Footer When you are in plan mode and about to call ExitPlanMode: diff --git a/design-consultation/SKILL.md b/design-consultation/SKILL.md index 05b8acc8..92067d74 100644 --- a/design-consultation/SKILL.md +++ b/design-consultation/SKILL.md @@ -444,6 +444,31 @@ artifacts that inform the plan, not code changes: These are read-only in spirit — they inspect the live site, generate visual artifacts, or get independent opinions. They do NOT modify project source files. +## Skill Invocation During Plan Mode + +If a user invokes a skill during plan mode, that invoked skill workflow takes +precedence over generic plan mode behavior until it finishes or the user explicitly +cancels that skill. + +Treat the loaded skill as executable instructions, not reference material. Follow +it step by step. Do not summarize, skip, reorder, or shortcut its steps. + +If the skill says to use AskUserQuestion, do that. Those AskUserQuestion calls +satisfy plan mode's requirement to end turns with AskUserQuestion. + +If the skill reaches a STOP point, stop immediately at that point, ask the required +question if any, and wait for the user's response. Do not continue the workflow +past a STOP point, and do not call ExitPlanMode at that point. + +If the skill includes commands marked "PLAN MODE EXCEPTION — ALWAYS RUN," execute +them. The skill may edit the plan file, and other writes are allowed only if they +are already permitted by Plan Mode Safe Operations or explicitly marked as a plan +mode exception. + +Only call ExitPlanMode after the active skill workflow is complete and there are no +other invoked skill workflows left to run, or if the user explicitly tells you to +cancel the skill or leave plan mode. + ## Plan Status Footer When you are in plan mode and about to call ExitPlanMode: diff --git a/design-html/SKILL.md b/design-html/SKILL.md index 1d98c345..c50b37ed 100644 --- a/design-html/SKILL.md +++ b/design-html/SKILL.md @@ -428,6 +428,31 @@ artifacts that inform the plan, not code changes: These are read-only in spirit — they inspect the live site, generate visual artifacts, or get independent opinions. They do NOT modify project source files. +## Skill Invocation During Plan Mode + +If a user invokes a skill during plan mode, that invoked skill workflow takes +precedence over generic plan mode behavior until it finishes or the user explicitly +cancels that skill. + +Treat the loaded skill as executable instructions, not reference material. Follow +it step by step. Do not summarize, skip, reorder, or shortcut its steps. + +If the skill says to use AskUserQuestion, do that. Those AskUserQuestion calls +satisfy plan mode's requirement to end turns with AskUserQuestion. + +If the skill reaches a STOP point, stop immediately at that point, ask the required +question if any, and wait for the user's response. Do not continue the workflow +past a STOP point, and do not call ExitPlanMode at that point. + +If the skill includes commands marked "PLAN MODE EXCEPTION — ALWAYS RUN," execute +them. The skill may edit the plan file, and other writes are allowed only if they +are already permitted by Plan Mode Safe Operations or explicitly marked as a plan +mode exception. + +Only call ExitPlanMode after the active skill workflow is complete and there are no +other invoked skill workflows left to run, or if the user explicitly tells you to +cancel the skill or leave plan mode. + ## Plan Status Footer When you are in plan mode and about to call ExitPlanMode: diff --git a/design-review/SKILL.md b/design-review/SKILL.md index ec1eb940..9b78080e 100644 --- a/design-review/SKILL.md +++ b/design-review/SKILL.md @@ -444,6 +444,31 @@ artifacts that inform the plan, not code changes: These are read-only in spirit — they inspect the live site, generate visual artifacts, or get independent opinions. They do NOT modify project source files. +## Skill Invocation During Plan Mode + +If a user invokes a skill during plan mode, that invoked skill workflow takes +precedence over generic plan mode behavior until it finishes or the user explicitly +cancels that skill. + +Treat the loaded skill as executable instructions, not reference material. Follow +it step by step. Do not summarize, skip, reorder, or shortcut its steps. + +If the skill says to use AskUserQuestion, do that. Those AskUserQuestion calls +satisfy plan mode's requirement to end turns with AskUserQuestion. + +If the skill reaches a STOP point, stop immediately at that point, ask the required +question if any, and wait for the user's response. Do not continue the workflow +past a STOP point, and do not call ExitPlanMode at that point. + +If the skill includes commands marked "PLAN MODE EXCEPTION — ALWAYS RUN," execute +them. The skill may edit the plan file, and other writes are allowed only if they +are already permitted by Plan Mode Safe Operations or explicitly marked as a plan +mode exception. + +Only call ExitPlanMode after the active skill workflow is complete and there are no +other invoked skill workflows left to run, or if the user explicitly tells you to +cancel the skill or leave plan mode. + ## Plan Status Footer When you are in plan mode and about to call ExitPlanMode: diff --git a/design-shotgun/SKILL.md b/design-shotgun/SKILL.md index 8312a12b..7de41cf3 100644 --- a/design-shotgun/SKILL.md +++ b/design-shotgun/SKILL.md @@ -423,6 +423,31 @@ artifacts that inform the plan, not code changes: These are read-only in spirit — they inspect the live site, generate visual artifacts, or get independent opinions. They do NOT modify project source files. +## Skill Invocation During Plan Mode + +If a user invokes a skill during plan mode, that invoked skill workflow takes +precedence over generic plan mode behavior until it finishes or the user explicitly +cancels that skill. + +Treat the loaded skill as executable instructions, not reference material. Follow +it step by step. Do not summarize, skip, reorder, or shortcut its steps. + +If the skill says to use AskUserQuestion, do that. Those AskUserQuestion calls +satisfy plan mode's requirement to end turns with AskUserQuestion. + +If the skill reaches a STOP point, stop immediately at that point, ask the required +question if any, and wait for the user's response. Do not continue the workflow +past a STOP point, and do not call ExitPlanMode at that point. + +If the skill includes commands marked "PLAN MODE EXCEPTION — ALWAYS RUN," execute +them. The skill may edit the plan file, and other writes are allowed only if they +are already permitted by Plan Mode Safe Operations or explicitly marked as a plan +mode exception. + +Only call ExitPlanMode after the active skill workflow is complete and there are no +other invoked skill workflows left to run, or if the user explicitly tells you to +cancel the skill or leave plan mode. + ## Plan Status Footer When you are in plan mode and about to call ExitPlanMode: diff --git a/devex-review/SKILL.md b/devex-review/SKILL.md index f842bc5b..18ba792f 100644 --- a/devex-review/SKILL.md +++ b/devex-review/SKILL.md @@ -444,6 +444,31 @@ artifacts that inform the plan, not code changes: These are read-only in spirit — they inspect the live site, generate visual artifacts, or get independent opinions. They do NOT modify project source files. +## Skill Invocation During Plan Mode + +If a user invokes a skill during plan mode, that invoked skill workflow takes +precedence over generic plan mode behavior until it finishes or the user explicitly +cancels that skill. + +Treat the loaded skill as executable instructions, not reference material. Follow +it step by step. Do not summarize, skip, reorder, or shortcut its steps. + +If the skill says to use AskUserQuestion, do that. Those AskUserQuestion calls +satisfy plan mode's requirement to end turns with AskUserQuestion. + +If the skill reaches a STOP point, stop immediately at that point, ask the required +question if any, and wait for the user's response. Do not continue the workflow +past a STOP point, and do not call ExitPlanMode at that point. + +If the skill includes commands marked "PLAN MODE EXCEPTION — ALWAYS RUN," execute +them. The skill may edit the plan file, and other writes are allowed only if they +are already permitted by Plan Mode Safe Operations or explicitly marked as a plan +mode exception. + +Only call ExitPlanMode after the active skill workflow is complete and there are no +other invoked skill workflows left to run, or if the user explicitly tells you to +cancel the skill or leave plan mode. + ## Plan Status Footer When you are in plan mode and about to call ExitPlanMode: @@ -872,7 +897,7 @@ Parse each JSONL entry. Each skill logs different fields: → Findings: "{issues_found} issues, {critical_gaps} critical gaps" - **plan-design-review**: \`status\`, \`initial_score\`, \`overall_score\`, \`unresolved\`, \`decisions_made\`, \`commit\` → Findings: "score: {initial_score}/10 → {overall_score}/10, {decisions_made} decisions" -- **plan-devex-review**: \`status\`, \`initial_score\`, \`overall_score\`, \`product_type\`, \`tthw_current\`, \`tthw_target\`, \`unresolved\`, \`commit\` +- **plan-devex-review**: \`status\`, \`initial_score\`, \`overall_score\`, \`product_type\`, \`tthw_current\`, \`tthw_target\`, \`mode\`, \`persona\`, \`competitive_tier\`, \`unresolved\`, \`commit\` → Findings: "score: {initial_score}/10 → {overall_score}/10, TTHW: {tthw_current} → {tthw_target}" - **devex-review**: \`status\`, \`overall_score\`, \`product_type\`, \`tthw_measured\`, \`dimensions_tested\`, \`dimensions_inferred\`, \`boomerang\`, \`commit\` → Findings: "score: {overall_score}/10, TTHW: {tthw_measured}, {dimensions_tested} tested/{dimensions_inferred} inferred" diff --git a/document-release/SKILL.md b/document-release/SKILL.md index 7fb3228a..a4f2617e 100644 --- a/document-release/SKILL.md +++ b/document-release/SKILL.md @@ -423,6 +423,31 @@ artifacts that inform the plan, not code changes: These are read-only in spirit — they inspect the live site, generate visual artifacts, or get independent opinions. They do NOT modify project source files. +## Skill Invocation During Plan Mode + +If a user invokes a skill during plan mode, that invoked skill workflow takes +precedence over generic plan mode behavior until it finishes or the user explicitly +cancels that skill. + +Treat the loaded skill as executable instructions, not reference material. Follow +it step by step. Do not summarize, skip, reorder, or shortcut its steps. + +If the skill says to use AskUserQuestion, do that. Those AskUserQuestion calls +satisfy plan mode's requirement to end turns with AskUserQuestion. + +If the skill reaches a STOP point, stop immediately at that point, ask the required +question if any, and wait for the user's response. Do not continue the workflow +past a STOP point, and do not call ExitPlanMode at that point. + +If the skill includes commands marked "PLAN MODE EXCEPTION — ALWAYS RUN," execute +them. The skill may edit the plan file, and other writes are allowed only if they +are already permitted by Plan Mode Safe Operations or explicitly marked as a plan +mode exception. + +Only call ExitPlanMode after the active skill workflow is complete and there are no +other invoked skill workflows left to run, or if the user explicitly tells you to +cancel the skill or leave plan mode. + ## Plan Status Footer When you are in plan mode and about to call ExitPlanMode: diff --git a/health/SKILL.md b/health/SKILL.md index 227b80bd..ee42db1f 100644 --- a/health/SKILL.md +++ b/health/SKILL.md @@ -423,6 +423,31 @@ artifacts that inform the plan, not code changes: These are read-only in spirit — they inspect the live site, generate visual artifacts, or get independent opinions. They do NOT modify project source files. +## Skill Invocation During Plan Mode + +If a user invokes a skill during plan mode, that invoked skill workflow takes +precedence over generic plan mode behavior until it finishes or the user explicitly +cancels that skill. + +Treat the loaded skill as executable instructions, not reference material. Follow +it step by step. Do not summarize, skip, reorder, or shortcut its steps. + +If the skill says to use AskUserQuestion, do that. Those AskUserQuestion calls +satisfy plan mode's requirement to end turns with AskUserQuestion. + +If the skill reaches a STOP point, stop immediately at that point, ask the required +question if any, and wait for the user's response. Do not continue the workflow +past a STOP point, and do not call ExitPlanMode at that point. + +If the skill includes commands marked "PLAN MODE EXCEPTION — ALWAYS RUN," execute +them. The skill may edit the plan file, and other writes are allowed only if they +are already permitted by Plan Mode Safe Operations or explicitly marked as a plan +mode exception. + +Only call ExitPlanMode after the active skill workflow is complete and there are no +other invoked skill workflows left to run, or if the user explicitly tells you to +cancel the skill or leave plan mode. + ## Plan Status Footer When you are in plan mode and about to call ExitPlanMode: diff --git a/investigate/SKILL.md b/investigate/SKILL.md index 30f695d8..f69914a1 100644 --- a/investigate/SKILL.md +++ b/investigate/SKILL.md @@ -438,6 +438,31 @@ artifacts that inform the plan, not code changes: These are read-only in spirit — they inspect the live site, generate visual artifacts, or get independent opinions. They do NOT modify project source files. +## Skill Invocation During Plan Mode + +If a user invokes a skill during plan mode, that invoked skill workflow takes +precedence over generic plan mode behavior until it finishes or the user explicitly +cancels that skill. + +Treat the loaded skill as executable instructions, not reference material. Follow +it step by step. Do not summarize, skip, reorder, or shortcut its steps. + +If the skill says to use AskUserQuestion, do that. Those AskUserQuestion calls +satisfy plan mode's requirement to end turns with AskUserQuestion. + +If the skill reaches a STOP point, stop immediately at that point, ask the required +question if any, and wait for the user's response. Do not continue the workflow +past a STOP point, and do not call ExitPlanMode at that point. + +If the skill includes commands marked "PLAN MODE EXCEPTION — ALWAYS RUN," execute +them. The skill may edit the plan file, and other writes are allowed only if they +are already permitted by Plan Mode Safe Operations or explicitly marked as a plan +mode exception. + +Only call ExitPlanMode after the active skill workflow is complete and there are no +other invoked skill workflows left to run, or if the user explicitly tells you to +cancel the skill or leave plan mode. + ## Plan Status Footer When you are in plan mode and about to call ExitPlanMode: diff --git a/land-and-deploy/SKILL.md b/land-and-deploy/SKILL.md index 106007e8..b1e75902 100644 --- a/land-and-deploy/SKILL.md +++ b/land-and-deploy/SKILL.md @@ -438,6 +438,31 @@ artifacts that inform the plan, not code changes: These are read-only in spirit — they inspect the live site, generate visual artifacts, or get independent opinions. They do NOT modify project source files. +## Skill Invocation During Plan Mode + +If a user invokes a skill during plan mode, that invoked skill workflow takes +precedence over generic plan mode behavior until it finishes or the user explicitly +cancels that skill. + +Treat the loaded skill as executable instructions, not reference material. Follow +it step by step. Do not summarize, skip, reorder, or shortcut its steps. + +If the skill says to use AskUserQuestion, do that. Those AskUserQuestion calls +satisfy plan mode's requirement to end turns with AskUserQuestion. + +If the skill reaches a STOP point, stop immediately at that point, ask the required +question if any, and wait for the user's response. Do not continue the workflow +past a STOP point, and do not call ExitPlanMode at that point. + +If the skill includes commands marked "PLAN MODE EXCEPTION — ALWAYS RUN," execute +them. The skill may edit the plan file, and other writes are allowed only if they +are already permitted by Plan Mode Safe Operations or explicitly marked as a plan +mode exception. + +Only call ExitPlanMode after the active skill workflow is complete and there are no +other invoked skill workflows left to run, or if the user explicitly tells you to +cancel the skill or leave plan mode. + ## Plan Status Footer When you are in plan mode and about to call ExitPlanMode: diff --git a/learn/SKILL.md b/learn/SKILL.md index 710330cf..9afca4c4 100644 --- a/learn/SKILL.md +++ b/learn/SKILL.md @@ -423,6 +423,31 @@ artifacts that inform the plan, not code changes: These are read-only in spirit — they inspect the live site, generate visual artifacts, or get independent opinions. They do NOT modify project source files. +## Skill Invocation During Plan Mode + +If a user invokes a skill during plan mode, that invoked skill workflow takes +precedence over generic plan mode behavior until it finishes or the user explicitly +cancels that skill. + +Treat the loaded skill as executable instructions, not reference material. Follow +it step by step. Do not summarize, skip, reorder, or shortcut its steps. + +If the skill says to use AskUserQuestion, do that. Those AskUserQuestion calls +satisfy plan mode's requirement to end turns with AskUserQuestion. + +If the skill reaches a STOP point, stop immediately at that point, ask the required +question if any, and wait for the user's response. Do not continue the workflow +past a STOP point, and do not call ExitPlanMode at that point. + +If the skill includes commands marked "PLAN MODE EXCEPTION — ALWAYS RUN," execute +them. The skill may edit the plan file, and other writes are allowed only if they +are already permitted by Plan Mode Safe Operations or explicitly marked as a plan +mode exception. + +Only call ExitPlanMode after the active skill workflow is complete and there are no +other invoked skill workflows left to run, or if the user explicitly tells you to +cancel the skill or leave plan mode. + ## Plan Status Footer When you are in plan mode and about to call ExitPlanMode: diff --git a/office-hours/SKILL.md b/office-hours/SKILL.md index 6417cd25..c3cceba3 100644 --- a/office-hours/SKILL.md +++ b/office-hours/SKILL.md @@ -448,6 +448,31 @@ artifacts that inform the plan, not code changes: These are read-only in spirit — they inspect the live site, generate visual artifacts, or get independent opinions. They do NOT modify project source files. +## Skill Invocation During Plan Mode + +If a user invokes a skill during plan mode, that invoked skill workflow takes +precedence over generic plan mode behavior until it finishes or the user explicitly +cancels that skill. + +Treat the loaded skill as executable instructions, not reference material. Follow +it step by step. Do not summarize, skip, reorder, or shortcut its steps. + +If the skill says to use AskUserQuestion, do that. Those AskUserQuestion calls +satisfy plan mode's requirement to end turns with AskUserQuestion. + +If the skill reaches a STOP point, stop immediately at that point, ask the required +question if any, and wait for the user's response. Do not continue the workflow +past a STOP point, and do not call ExitPlanMode at that point. + +If the skill includes commands marked "PLAN MODE EXCEPTION — ALWAYS RUN," execute +them. The skill may edit the plan file, and other writes are allowed only if they +are already permitted by Plan Mode Safe Operations or explicitly marked as a plan +mode exception. + +Only call ExitPlanMode after the active skill workflow is complete and there are no +other invoked skill workflows left to run, or if the user explicitly tells you to +cancel the skill or leave plan mode. + ## Plan Status Footer When you are in plan mode and about to call ExitPlanMode: diff --git a/plan-ceo-review/SKILL.md b/plan-ceo-review/SKILL.md index 2130cde2..4d1253cb 100644 --- a/plan-ceo-review/SKILL.md +++ b/plan-ceo-review/SKILL.md @@ -444,6 +444,31 @@ artifacts that inform the plan, not code changes: These are read-only in spirit — they inspect the live site, generate visual artifacts, or get independent opinions. They do NOT modify project source files. +## Skill Invocation During Plan Mode + +If a user invokes a skill during plan mode, that invoked skill workflow takes +precedence over generic plan mode behavior until it finishes or the user explicitly +cancels that skill. + +Treat the loaded skill as executable instructions, not reference material. Follow +it step by step. Do not summarize, skip, reorder, or shortcut its steps. + +If the skill says to use AskUserQuestion, do that. Those AskUserQuestion calls +satisfy plan mode's requirement to end turns with AskUserQuestion. + +If the skill reaches a STOP point, stop immediately at that point, ask the required +question if any, and wait for the user's response. Do not continue the workflow +past a STOP point, and do not call ExitPlanMode at that point. + +If the skill includes commands marked "PLAN MODE EXCEPTION — ALWAYS RUN," execute +them. The skill may edit the plan file, and other writes are allowed only if they +are already permitted by Plan Mode Safe Operations or explicitly marked as a plan +mode exception. + +Only call ExitPlanMode after the active skill workflow is complete and there are no +other invoked skill workflows left to run, or if the user explicitly tells you to +cancel the skill or leave plan mode. + ## Plan Status Footer When you are in plan mode and about to call ExitPlanMode: @@ -1614,7 +1639,7 @@ Parse each JSONL entry. Each skill logs different fields: → Findings: "{issues_found} issues, {critical_gaps} critical gaps" - **plan-design-review**: \`status\`, \`initial_score\`, \`overall_score\`, \`unresolved\`, \`decisions_made\`, \`commit\` → Findings: "score: {initial_score}/10 → {overall_score}/10, {decisions_made} decisions" -- **plan-devex-review**: \`status\`, \`initial_score\`, \`overall_score\`, \`product_type\`, \`tthw_current\`, \`tthw_target\`, \`unresolved\`, \`commit\` +- **plan-devex-review**: \`status\`, \`initial_score\`, \`overall_score\`, \`product_type\`, \`tthw_current\`, \`tthw_target\`, \`mode\`, \`persona\`, \`competitive_tier\`, \`unresolved\`, \`commit\` → Findings: "score: {initial_score}/10 → {overall_score}/10, TTHW: {tthw_current} → {tthw_target}" - **devex-review**: \`status\`, \`overall_score\`, \`product_type\`, \`tthw_measured\`, \`dimensions_tested\`, \`dimensions_inferred\`, \`boomerang\`, \`commit\` → Findings: "score: {overall_score}/10, TTHW: {tthw_measured}, {dimensions_tested} tested/{dimensions_inferred} inferred" diff --git a/plan-design-review/SKILL.md b/plan-design-review/SKILL.md index d4d16a64..b0f7f3a6 100644 --- a/plan-design-review/SKILL.md +++ b/plan-design-review/SKILL.md @@ -442,6 +442,31 @@ artifacts that inform the plan, not code changes: These are read-only in spirit — they inspect the live site, generate visual artifacts, or get independent opinions. They do NOT modify project source files. +## Skill Invocation During Plan Mode + +If a user invokes a skill during plan mode, that invoked skill workflow takes +precedence over generic plan mode behavior until it finishes or the user explicitly +cancels that skill. + +Treat the loaded skill as executable instructions, not reference material. Follow +it step by step. Do not summarize, skip, reorder, or shortcut its steps. + +If the skill says to use AskUserQuestion, do that. Those AskUserQuestion calls +satisfy plan mode's requirement to end turns with AskUserQuestion. + +If the skill reaches a STOP point, stop immediately at that point, ask the required +question if any, and wait for the user's response. Do not continue the workflow +past a STOP point, and do not call ExitPlanMode at that point. + +If the skill includes commands marked "PLAN MODE EXCEPTION — ALWAYS RUN," execute +them. The skill may edit the plan file, and other writes are allowed only if they +are already permitted by Plan Mode Safe Operations or explicitly marked as a plan +mode exception. + +Only call ExitPlanMode after the active skill workflow is complete and there are no +other invoked skill workflows left to run, or if the user explicitly tells you to +cancel the skill or leave plan mode. + ## Plan Status Footer When you are in plan mode and about to call ExitPlanMode: @@ -1348,7 +1373,7 @@ Parse each JSONL entry. Each skill logs different fields: → Findings: "{issues_found} issues, {critical_gaps} critical gaps" - **plan-design-review**: \`status\`, \`initial_score\`, \`overall_score\`, \`unresolved\`, \`decisions_made\`, \`commit\` → Findings: "score: {initial_score}/10 → {overall_score}/10, {decisions_made} decisions" -- **plan-devex-review**: \`status\`, \`initial_score\`, \`overall_score\`, \`product_type\`, \`tthw_current\`, \`tthw_target\`, \`unresolved\`, \`commit\` +- **plan-devex-review**: \`status\`, \`initial_score\`, \`overall_score\`, \`product_type\`, \`tthw_current\`, \`tthw_target\`, \`mode\`, \`persona\`, \`competitive_tier\`, \`unresolved\`, \`commit\` → Findings: "score: {initial_score}/10 → {overall_score}/10, TTHW: {tthw_current} → {tthw_target}" - **devex-review**: \`status\`, \`overall_score\`, \`product_type\`, \`tthw_measured\`, \`dimensions_tested\`, \`dimensions_inferred\`, \`boomerang\`, \`commit\` → Findings: "score: {overall_score}/10, TTHW: {tthw_measured}, {dimensions_tested} tested/{dimensions_inferred} inferred" diff --git a/plan-eng-review/SKILL.md b/plan-eng-review/SKILL.md index 9a0e03cf..de21a370 100644 --- a/plan-eng-review/SKILL.md +++ b/plan-eng-review/SKILL.md @@ -444,6 +444,31 @@ artifacts that inform the plan, not code changes: These are read-only in spirit — they inspect the live site, generate visual artifacts, or get independent opinions. They do NOT modify project source files. +## Skill Invocation During Plan Mode + +If a user invokes a skill during plan mode, that invoked skill workflow takes +precedence over generic plan mode behavior until it finishes or the user explicitly +cancels that skill. + +Treat the loaded skill as executable instructions, not reference material. Follow +it step by step. Do not summarize, skip, reorder, or shortcut its steps. + +If the skill says to use AskUserQuestion, do that. Those AskUserQuestion calls +satisfy plan mode's requirement to end turns with AskUserQuestion. + +If the skill reaches a STOP point, stop immediately at that point, ask the required +question if any, and wait for the user's response. Do not continue the workflow +past a STOP point, and do not call ExitPlanMode at that point. + +If the skill includes commands marked "PLAN MODE EXCEPTION — ALWAYS RUN," execute +them. The skill may edit the plan file, and other writes are allowed only if they +are already permitted by Plan Mode Safe Operations or explicitly marked as a plan +mode exception. + +Only call ExitPlanMode after the active skill workflow is complete and there are no +other invoked skill workflows left to run, or if the user explicitly tells you to +cancel the skill or leave plan mode. + ## Plan Status Footer When you are in plan mode and about to call ExitPlanMode: @@ -1260,7 +1285,7 @@ Parse each JSONL entry. Each skill logs different fields: → Findings: "{issues_found} issues, {critical_gaps} critical gaps" - **plan-design-review**: \`status\`, \`initial_score\`, \`overall_score\`, \`unresolved\`, \`decisions_made\`, \`commit\` → Findings: "score: {initial_score}/10 → {overall_score}/10, {decisions_made} decisions" -- **plan-devex-review**: \`status\`, \`initial_score\`, \`overall_score\`, \`product_type\`, \`tthw_current\`, \`tthw_target\`, \`unresolved\`, \`commit\` +- **plan-devex-review**: \`status\`, \`initial_score\`, \`overall_score\`, \`product_type\`, \`tthw_current\`, \`tthw_target\`, \`mode\`, \`persona\`, \`competitive_tier\`, \`unresolved\`, \`commit\` → Findings: "score: {initial_score}/10 → {overall_score}/10, TTHW: {tthw_current} → {tthw_target}" - **devex-review**: \`status\`, \`overall_score\`, \`product_type\`, \`tthw_measured\`, \`dimensions_tested\`, \`dimensions_inferred\`, \`boomerang\`, \`commit\` → Findings: "score: {overall_score}/10, TTHW: {tthw_measured}, {dimensions_tested} tested/{dimensions_inferred} inferred" diff --git a/qa-only/SKILL.md b/qa-only/SKILL.md index 6549bcf9..e49088c7 100644 --- a/qa-only/SKILL.md +++ b/qa-only/SKILL.md @@ -440,6 +440,31 @@ artifacts that inform the plan, not code changes: These are read-only in spirit — they inspect the live site, generate visual artifacts, or get independent opinions. They do NOT modify project source files. +## Skill Invocation During Plan Mode + +If a user invokes a skill during plan mode, that invoked skill workflow takes +precedence over generic plan mode behavior until it finishes or the user explicitly +cancels that skill. + +Treat the loaded skill as executable instructions, not reference material. Follow +it step by step. Do not summarize, skip, reorder, or shortcut its steps. + +If the skill says to use AskUserQuestion, do that. Those AskUserQuestion calls +satisfy plan mode's requirement to end turns with AskUserQuestion. + +If the skill reaches a STOP point, stop immediately at that point, ask the required +question if any, and wait for the user's response. Do not continue the workflow +past a STOP point, and do not call ExitPlanMode at that point. + +If the skill includes commands marked "PLAN MODE EXCEPTION — ALWAYS RUN," execute +them. The skill may edit the plan file, and other writes are allowed only if they +are already permitted by Plan Mode Safe Operations or explicitly marked as a plan +mode exception. + +Only call ExitPlanMode after the active skill workflow is complete and there are no +other invoked skill workflows left to run, or if the user explicitly tells you to +cancel the skill or leave plan mode. + ## Plan Status Footer When you are in plan mode and about to call ExitPlanMode: diff --git a/qa/SKILL.md b/qa/SKILL.md index a526b3b7..06e23e6f 100644 --- a/qa/SKILL.md +++ b/qa/SKILL.md @@ -446,6 +446,31 @@ artifacts that inform the plan, not code changes: These are read-only in spirit — they inspect the live site, generate visual artifacts, or get independent opinions. They do NOT modify project source files. +## Skill Invocation During Plan Mode + +If a user invokes a skill during plan mode, that invoked skill workflow takes +precedence over generic plan mode behavior until it finishes or the user explicitly +cancels that skill. + +Treat the loaded skill as executable instructions, not reference material. Follow +it step by step. Do not summarize, skip, reorder, or shortcut its steps. + +If the skill says to use AskUserQuestion, do that. Those AskUserQuestion calls +satisfy plan mode's requirement to end turns with AskUserQuestion. + +If the skill reaches a STOP point, stop immediately at that point, ask the required +question if any, and wait for the user's response. Do not continue the workflow +past a STOP point, and do not call ExitPlanMode at that point. + +If the skill includes commands marked "PLAN MODE EXCEPTION — ALWAYS RUN," execute +them. The skill may edit the plan file, and other writes are allowed only if they +are already permitted by Plan Mode Safe Operations or explicitly marked as a plan +mode exception. + +Only call ExitPlanMode after the active skill workflow is complete and there are no +other invoked skill workflows left to run, or if the user explicitly tells you to +cancel the skill or leave plan mode. + ## Plan Status Footer When you are in plan mode and about to call ExitPlanMode: diff --git a/retro/SKILL.md b/retro/SKILL.md index ef86bc3a..6b059aee 100644 --- a/retro/SKILL.md +++ b/retro/SKILL.md @@ -421,6 +421,31 @@ artifacts that inform the plan, not code changes: These are read-only in spirit — they inspect the live site, generate visual artifacts, or get independent opinions. They do NOT modify project source files. +## Skill Invocation During Plan Mode + +If a user invokes a skill during plan mode, that invoked skill workflow takes +precedence over generic plan mode behavior until it finishes or the user explicitly +cancels that skill. + +Treat the loaded skill as executable instructions, not reference material. Follow +it step by step. Do not summarize, skip, reorder, or shortcut its steps. + +If the skill says to use AskUserQuestion, do that. Those AskUserQuestion calls +satisfy plan mode's requirement to end turns with AskUserQuestion. + +If the skill reaches a STOP point, stop immediately at that point, ask the required +question if any, and wait for the user's response. Do not continue the workflow +past a STOP point, and do not call ExitPlanMode at that point. + +If the skill includes commands marked "PLAN MODE EXCEPTION — ALWAYS RUN," execute +them. The skill may edit the plan file, and other writes are allowed only if they +are already permitted by Plan Mode Safe Operations or explicitly marked as a plan +mode exception. + +Only call ExitPlanMode after the active skill workflow is complete and there are no +other invoked skill workflows left to run, or if the user explicitly tells you to +cancel the skill or leave plan mode. + ## Plan Status Footer When you are in plan mode and about to call ExitPlanMode: diff --git a/review/SKILL.md b/review/SKILL.md index 9d69790d..b16de752 100644 --- a/review/SKILL.md +++ b/review/SKILL.md @@ -442,6 +442,31 @@ artifacts that inform the plan, not code changes: These are read-only in spirit — they inspect the live site, generate visual artifacts, or get independent opinions. They do NOT modify project source files. +## Skill Invocation During Plan Mode + +If a user invokes a skill during plan mode, that invoked skill workflow takes +precedence over generic plan mode behavior until it finishes or the user explicitly +cancels that skill. + +Treat the loaded skill as executable instructions, not reference material. Follow +it step by step. Do not summarize, skip, reorder, or shortcut its steps. + +If the skill says to use AskUserQuestion, do that. Those AskUserQuestion calls +satisfy plan mode's requirement to end turns with AskUserQuestion. + +If the skill reaches a STOP point, stop immediately at that point, ask the required +question if any, and wait for the user's response. Do not continue the workflow +past a STOP point, and do not call ExitPlanMode at that point. + +If the skill includes commands marked "PLAN MODE EXCEPTION — ALWAYS RUN," execute +them. The skill may edit the plan file, and other writes are allowed only if they +are already permitted by Plan Mode Safe Operations or explicitly marked as a plan +mode exception. + +Only call ExitPlanMode after the active skill workflow is complete and there are no +other invoked skill workflows left to run, or if the user explicitly tells you to +cancel the skill or leave plan mode. + ## Plan Status Footer When you are in plan mode and about to call ExitPlanMode: diff --git a/scripts/resolvers/preamble.ts b/scripts/resolvers/preamble.ts index 7202d17a..3398fe9a 100644 --- a/scripts/resolvers/preamble.ts +++ b/scripts/resolvers/preamble.ts @@ -480,6 +480,31 @@ artifacts that inform the plan, not code changes: These are read-only in spirit — they inspect the live site, generate visual artifacts, or get independent opinions. They do NOT modify project source files. +## Skill Invocation During Plan Mode + +If a user invokes a skill during plan mode, that invoked skill workflow takes +precedence over generic plan mode behavior until it finishes or the user explicitly +cancels that skill. + +Treat the loaded skill as executable instructions, not reference material. Follow +it step by step. Do not summarize, skip, reorder, or shortcut its steps. + +If the skill says to use AskUserQuestion, do that. Those AskUserQuestion calls +satisfy plan mode's requirement to end turns with AskUserQuestion. + +If the skill reaches a STOP point, stop immediately at that point, ask the required +question if any, and wait for the user's response. Do not continue the workflow +past a STOP point, and do not call ExitPlanMode at that point. + +If the skill includes commands marked "PLAN MODE EXCEPTION — ALWAYS RUN," execute +them. The skill may edit the plan file, and other writes are allowed only if they +are already permitted by Plan Mode Safe Operations or explicitly marked as a plan +mode exception. + +Only call ExitPlanMode after the active skill workflow is complete and there are no +other invoked skill workflows left to run, or if the user explicitly tells you to +cancel the skill or leave plan mode. + ## Plan Status Footer When you are in plan mode and about to call ExitPlanMode: diff --git a/setup-browser-cookies/SKILL.md b/setup-browser-cookies/SKILL.md index dc8dd9fa..549c4d25 100644 --- a/setup-browser-cookies/SKILL.md +++ b/setup-browser-cookies/SKILL.md @@ -308,6 +308,31 @@ artifacts that inform the plan, not code changes: These are read-only in spirit — they inspect the live site, generate visual artifacts, or get independent opinions. They do NOT modify project source files. +## Skill Invocation During Plan Mode + +If a user invokes a skill during plan mode, that invoked skill workflow takes +precedence over generic plan mode behavior until it finishes or the user explicitly +cancels that skill. + +Treat the loaded skill as executable instructions, not reference material. Follow +it step by step. Do not summarize, skip, reorder, or shortcut its steps. + +If the skill says to use AskUserQuestion, do that. Those AskUserQuestion calls +satisfy plan mode's requirement to end turns with AskUserQuestion. + +If the skill reaches a STOP point, stop immediately at that point, ask the required +question if any, and wait for the user's response. Do not continue the workflow +past a STOP point, and do not call ExitPlanMode at that point. + +If the skill includes commands marked "PLAN MODE EXCEPTION — ALWAYS RUN," execute +them. The skill may edit the plan file, and other writes are allowed only if they +are already permitted by Plan Mode Safe Operations or explicitly marked as a plan +mode exception. + +Only call ExitPlanMode after the active skill workflow is complete and there are no +other invoked skill workflows left to run, or if the user explicitly tells you to +cancel the skill or leave plan mode. + ## Plan Status Footer When you are in plan mode and about to call ExitPlanMode: diff --git a/setup-deploy/SKILL.md b/setup-deploy/SKILL.md index f09b6404..0dfd1df4 100644 --- a/setup-deploy/SKILL.md +++ b/setup-deploy/SKILL.md @@ -424,6 +424,31 @@ artifacts that inform the plan, not code changes: These are read-only in spirit — they inspect the live site, generate visual artifacts, or get independent opinions. They do NOT modify project source files. +## Skill Invocation During Plan Mode + +If a user invokes a skill during plan mode, that invoked skill workflow takes +precedence over generic plan mode behavior until it finishes or the user explicitly +cancels that skill. + +Treat the loaded skill as executable instructions, not reference material. Follow +it step by step. Do not summarize, skip, reorder, or shortcut its steps. + +If the skill says to use AskUserQuestion, do that. Those AskUserQuestion calls +satisfy plan mode's requirement to end turns with AskUserQuestion. + +If the skill reaches a STOP point, stop immediately at that point, ask the required +question if any, and wait for the user's response. Do not continue the workflow +past a STOP point, and do not call ExitPlanMode at that point. + +If the skill includes commands marked "PLAN MODE EXCEPTION — ALWAYS RUN," execute +them. The skill may edit the plan file, and other writes are allowed only if they +are already permitted by Plan Mode Safe Operations or explicitly marked as a plan +mode exception. + +Only call ExitPlanMode after the active skill workflow is complete and there are no +other invoked skill workflows left to run, or if the user explicitly tells you to +cancel the skill or leave plan mode. + ## Plan Status Footer When you are in plan mode and about to call ExitPlanMode: diff --git a/ship/SKILL.md b/ship/SKILL.md index 4886ea03..25afbb03 100644 --- a/ship/SKILL.md +++ b/ship/SKILL.md @@ -443,6 +443,31 @@ artifacts that inform the plan, not code changes: These are read-only in spirit — they inspect the live site, generate visual artifacts, or get independent opinions. They do NOT modify project source files. +## Skill Invocation During Plan Mode + +If a user invokes a skill during plan mode, that invoked skill workflow takes +precedence over generic plan mode behavior until it finishes or the user explicitly +cancels that skill. + +Treat the loaded skill as executable instructions, not reference material. Follow +it step by step. Do not summarize, skip, reorder, or shortcut its steps. + +If the skill says to use AskUserQuestion, do that. Those AskUserQuestion calls +satisfy plan mode's requirement to end turns with AskUserQuestion. + +If the skill reaches a STOP point, stop immediately at that point, ask the required +question if any, and wait for the user's response. Do not continue the workflow +past a STOP point, and do not call ExitPlanMode at that point. + +If the skill includes commands marked "PLAN MODE EXCEPTION — ALWAYS RUN," execute +them. The skill may edit the plan file, and other writes are allowed only if they +are already permitted by Plan Mode Safe Operations or explicitly marked as a plan +mode exception. + +Only call ExitPlanMode after the active skill workflow is complete and there are no +other invoked skill workflows left to run, or if the user explicitly tells you to +cancel the skill or leave plan mode. + ## Plan Status Footer When you are in plan mode and about to call ExitPlanMode: diff --git a/test/gen-skill-docs.test.ts b/test/gen-skill-docs.test.ts index adb33456..d9de74ff 100644 --- a/test/gen-skill-docs.test.ts +++ b/test/gen-skill-docs.test.ts @@ -988,6 +988,18 @@ describe('Plan status footer in preamble', () => { }); }); +// --- Skill invocation during plan mode in preamble --- + +describe('Skill invocation during plan mode in preamble', () => { + test('preamble contains skill invocation plan mode section', () => { + const content = fs.readFileSync(path.join(ROOT, 'office-hours', 'SKILL.md'), 'utf-8'); + expect(content).toContain('Skill Invocation During Plan Mode'); + expect(content).toContain('precedence over generic plan mode behavior'); + expect(content).toContain('Do not continue the workflow'); + expect(content).toContain('cancel the skill or leave plan mode'); + }); +}); + // --- {{SPEC_REVIEW_LOOP}} resolver tests --- describe('SPEC_REVIEW_LOOP resolver', () => {