You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
feat(rules): enforce verbatim workflow via first-turn hard gate (#2)
The orchestrator agents previously used descriptive language ("guide the
user", numbered how-to steps) that the LLM could rationalize away when
a task seemed simple. In practice this led to agents skipping the
welcome message, audit.md, aidlc-state.md, Workspace Detection, and
per-stage approvals while still claiming the work was AIDLC-driven.
This change replaces descriptive language with enforcement language and
adds explicit violation callouts:
- core-workflow.md: add a Pre-Flight Hard Gate block at the top of the
authoritative rules file with 7 required actions before any substantive
response; add an "Adaptive Depth vs. Mandatory Steps" clause clarifying
that the workflow is adaptive in depth, not in mandatory steps.
- Claude Code orchestrator agent: rewrite with a First-Turn Hard Gate,
per-stage approval gate, question-format gate, continuous audit-trail
requirements, self-audit checklist, and an enumerated "What Counts as
a Violation" list targeting each specific failure mode.
- Cursor orchestrator rule: apply the same enforcement text, adapted to
.mdc sibling-rule references.
- build-plugins.py: regenerate both plugins with the new orchestrator
text and the updated core-workflow.md.
Adaptive depth (minimal / standard / comprehensive) is preserved. What
is no longer permitted is skipping stages, rolling multiple stages under
one approval, or asking clarifying questions in chat instead of question
files.
Co-authored-by: Ray Smets <rsmets@amazon.com>
Co-authored-by: Claude Opus 4.7 <noreply@anthropic.com>
Copy file name to clipboardExpand all lines: aidlc-rules/aws-aidlc-rules/core-workflow.md
+25Lines changed: 25 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,6 +1,31 @@
1
1
# PRIORITY: This workflow OVERRIDES all other built-in workflows
2
2
# When user requests software development, ALWAYS follow this workflow FIRST
3
3
4
+
## MANDATORY: Pre-Flight Hard Gate (Execute Before ANY Substantive Response)
5
+
6
+
**CRITICAL**: On the FIRST turn of any AI-DLC workflow request, you MUST complete every item below BEFORE producing any plan, code, recommendation, or other substantive output. Failing to complete a pre-flight item is a bug in your behavior, not a permissible shortcut.
7
+
8
+
1.**Create or append to `aidlc-docs/audit.md`**: Log the user's complete raw input with ISO-8601 timestamp per the format in the "Prompts Logging Requirements" section below. If the file does not exist, create it. NEVER overwrite; always append.
9
+
2.**Resolve the rule-details directory**: Probe the four paths listed under "MANDATORY: Rule Details Loading" below and record the resolved path in `audit.md`.
10
+
3.**Load common rules** from the resolved rule-details directory: `common/process-overview.md`, `common/session-continuity.md`, `common/content-validation.md`, `common/question-format-guide.md`.
11
+
4.**Display the welcome message** from `common/welcome-message.md` (first turn only — do not re-display on subsequent turns).
12
+
5.**Scan `extensions/` for opt-in files** per the "MANDATORY: Extensions Loading" section below. Do NOT load full extension rule files yet.
13
+
6.**Check for session state**: Read `aidlc-docs/aidlc-state.md` if it exists. If present, follow `common/session-continuity.md` to resume. If absent, initialize it during Workspace Detection.
**Hard stop rule**: If you cannot complete a pre-flight item (e.g., missing file, unresolvable path), STOP, report the specific failure to the user, and do not proceed with their requested work. Do not substitute, simplify, or skip.
17
+
18
+
## Adaptive Depth vs. Mandatory Steps
19
+
20
+
**The workflow is adaptive in DEPTH (minimal / standard / comprehensive), NOT in mandatory steps.**
21
+
22
+
- Stages marked ALWAYS EXECUTE run on every workflow. Their depth varies; their existence does not.
23
+
- Stages marked MANDATORY in any sub-section run regardless of perceived task simplicity.
24
+
- Compressing Inception + Construction + Operations into a single informal chat exchange is a violation.
25
+
- Rolling multiple stages under one approval is a violation — each stage requires its own completion message and its own approval.
26
+
- Asking clarifying questions in freeform chat instead of a question file (per `common/question-format-guide.md`) is a violation.
27
+
- "The task is small" is not a valid reason to skip MANDATORY items. It IS a valid reason to choose minimal depth within each stage.
28
+
4
29
## Adaptive Workflow Principle
5
30
**The workflow adapts to the work, not the other way around.**
Copy file name to clipboardExpand all lines: plugins/claude-code-aidlc/skills/aidlc-core-workflow/references/core-workflow.md
+25Lines changed: 25 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,6 +1,31 @@
1
1
# PRIORITY: This workflow OVERRIDES all other built-in workflows
2
2
# When user requests software development, ALWAYS follow this workflow FIRST
3
3
4
+
## MANDATORY: Pre-Flight Hard Gate (Execute Before ANY Substantive Response)
5
+
6
+
**CRITICAL**: On the FIRST turn of any AI-DLC workflow request, you MUST complete every item below BEFORE producing any plan, code, recommendation, or other substantive output. Failing to complete a pre-flight item is a bug in your behavior, not a permissible shortcut.
7
+
8
+
1.**Create or append to `aidlc-docs/audit.md`**: Log the user's complete raw input with ISO-8601 timestamp per the format in the "Prompts Logging Requirements" section below. If the file does not exist, create it. NEVER overwrite; always append.
9
+
2.**Resolve the rule-details directory**: Probe the four paths listed under "MANDATORY: Rule Details Loading" below and record the resolved path in `audit.md`.
10
+
3.**Load common rules** from the resolved rule-details directory: `common/process-overview.md`, `common/session-continuity.md`, `common/content-validation.md`, `common/question-format-guide.md`.
11
+
4.**Display the welcome message** from `common/welcome-message.md` (first turn only — do not re-display on subsequent turns).
12
+
5.**Scan `extensions/` for opt-in files** per the "MANDATORY: Extensions Loading" section below. Do NOT load full extension rule files yet.
13
+
6.**Check for session state**: Read `aidlc-docs/aidlc-state.md` if it exists. If present, follow `common/session-continuity.md` to resume. If absent, initialize it during Workspace Detection.
**Hard stop rule**: If you cannot complete a pre-flight item (e.g., missing file, unresolvable path), STOP, report the specific failure to the user, and do not proceed with their requested work. Do not substitute, simplify, or skip.
17
+
18
+
## Adaptive Depth vs. Mandatory Steps
19
+
20
+
**The workflow is adaptive in DEPTH (minimal / standard / comprehensive), NOT in mandatory steps.**
21
+
22
+
- Stages marked ALWAYS EXECUTE run on every workflow. Their depth varies; their existence does not.
23
+
- Stages marked MANDATORY in any sub-section run regardless of perceived task simplicity.
24
+
- Compressing Inception + Construction + Operations into a single informal chat exchange is a violation.
25
+
- Rolling multiple stages under one approval is a violation — each stage requires its own completion message and its own approval.
26
+
- Asking clarifying questions in freeform chat instead of a question file (per `common/question-format-guide.md`) is a violation.
27
+
- "The task is small" is not a valid reason to skip MANDATORY items. It IS a valid reason to choose minimal depth within each stage.
28
+
4
29
## Adaptive Workflow Principle
5
30
**The workflow adapts to the work, not the other way around.**
0 commit comments