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
fix(constitution): stop propagating guidance into templates (#3737) (#3790)
Issue #3737 asked the /constitution command to synchronize constitutional
guidance into every effective task/plan/spec template, including active
preset-provided replacements. This changes the fix's direction: rather than
teach the command to discover and edit more template layers, it removes the
template-propagation behavior entirely.
Why this is the correct fix:
- The governed templates do not embed constitutional content. plan-template
carries a runtime placeholder ("[Gates determined based on constitution
file]") and spec-template/tasks-template reference no principles at all.
- The consuming commands read .specify/memory/constitution.md at runtime and
derive their Constitution Check gates live (plan, tasks), and analyze is the
dedicated drift checker that validates spec/plan/tasks against the
constitution. Enforcement is therefore already automatic and always current.
- Statically editing template files fights the preset/override composition
system: a replace preset shadows an edited core template entirely, and a
hand-edited versioned preset file is clobbered on its next update. Presets and
extensions are formalized, versioned artifacts the command must not mutate.
So the original bug (constitution edits missing active preset templates) is
resolved by not propagating at all: the runtime read is the single source of
truth. The /constitution command is scoped to its own artifact — it drafts and
writes the constitution and reports a Sync Impact Report changelog, and no
longer reads, edits, or reports on plan/spec/tasks/preset/extension templates.
Refs #3737
Assisted-by: GitHub Copilot (model: Claude Opus 4.8, supervised)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Copilot-Session: 5b80589c-74e8-42e5-b2cb-7a7e0d69a964
Copy file name to clipboardExpand all lines: templates/commands/constitution.md
+10-18Lines changed: 10 additions & 18 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,5 +1,5 @@
1
1
---
2
-
description: Create or update the project constitution from interactive or provided principle inputs, ensuring all dependent templates stay in sync.
2
+
description: Create or update the project constitution from interactive or provided principle inputs.
3
3
handoffs:
4
4
- label: Build Specification
5
5
agent: speckit.specify
@@ -16,16 +16,16 @@ You **MUST** consider the user input before proceeding (if not empty).
16
16
17
17
## Scope Guard
18
18
19
-
This command's own work is limited to updating the project constitution and propagating
20
-
constitution-driven changes to the dependent artifacts identified in this command.
19
+
This command's own work is limited to updating the project constitution itself. Dependent templates
20
+
and commands read the constitution at runtime and are not modified here.
21
21
22
22
- Classify every part of the user input as either constitution content or a separate,
23
23
non-governance intent.
24
24
- If the input includes feature implementation, code generation, refactoring, building, or
25
25
deployment requests, you **MUST NOT** execute them. Extract them as deferred intents instead.
26
26
- You **MUST NOT** create, modify, or delete application source files, feature routes,
27
27
components, tests, deployment files, or other artifacts unrelated to the constitution
28
-
workflow and its required propagation.
28
+
workflow.
29
29
- If it is unclear whether an instruction is constitution content, ask for clarification before
30
30
making changes.
31
31
- After completing the constitution update, include a `Next Actions` section for each deferred
@@ -70,7 +70,7 @@ constitution-driven changes to the dependent artifacts identified in this comman
70
70
71
71
## Outline
72
72
73
-
You are updating the project constitution at `.specify/memory/constitution.md`. This file is a TEMPLATE containing placeholder tokens in square brackets (e.g. `[PROJECT_NAME]`, `[PRINCIPLE_1_NAME]`). Your job is to (a) collect/derive concrete values, (b) fill the template precisely, and (c) propagate any amendments across dependent artifacts.
73
+
You are updating the project constitution at `.specify/memory/constitution.md`. This file is a TEMPLATE containing placeholder tokens in square brackets (e.g. `[PROJECT_NAME]`, `[PRINCIPLE_1_NAME]`). Your job is to (a) collect/derive concrete values and (b) fill the template precisely.
74
74
75
75
**Note**: If `.specify/memory/constitution.md` does not exist yet, it should have been initialized from `.specify/templates/constitution-template.md` during project setup. If it's missing, copy the template first.
76
76
@@ -96,32 +96,24 @@ Follow this execution flow:
96
96
- Ensure each Principle section: succinct name line, paragraph (or bullet list) capturing non‑negotiable rules, explicit rationale if not obvious.
4. Consistency propagation checklist (convert prior checklist into active validations):
100
-
- Read `.specify/templates/plan-template.md` and ensure any "Constitution Check" or rules align with updated principles.
101
-
- Read `.specify/templates/spec-template.md` for scope/requirements alignment—update if constitution adds/removes mandatory sections or constraints.
102
-
- Read `.specify/templates/tasks-template.md` and ensure task categorization reflects new or removed principle-driven task types (e.g., observability, versioning, testing discipline).
103
-
- Read each installed Spec Kit command file for your agent (including this one) — named `speckit.*` or `speckit-*` (dot or hyphen depending on the agent), or laid out as `speckit-<name>/SKILL.md` for skills-based integrations, e.g. in `.github/agents/`, `.github/skills/`, `.claude/skills/`, or your agent's equivalent commands directory — to verify no outdated references (CLAUDE-only or other agent-specific names) remain when generic guidance is required.
104
-
- Read any runtime guidance docs (e.g., `README.md`, `docs/quickstart.md`, or agent-specific guidance files if present). Update references to principles changed.
105
-
106
-
5. Produce a Sync Impact Report (prepend as an HTML comment at top of the constitution file after update):
99
+
4. Produce a Sync Impact Report (prepend as an HTML comment at top of the constitution file after update):
107
100
- Version change: old → new
108
101
- List of modified principles (old title → new title if renamed)
0 commit comments