[Feature]: Add artifact, optional, and handoffs to the command manifest schema
Maintainer antworten meist innerhalb von 1 Tag
Dieses Issue hat noch niemand übernommen.
Bewertung
- Schwierigkeit
- 4/5
- Geschätzter Aufwand
- 3-5 Tage
- Anfängerfreundlichkeit
- 64/100
Rechercherichtung
Beginne mit src/specify_cli/extensions/init.py und src/specify_cli/presets/init.py, untersuche anschließend relative_extension_path_violation in src/specify_cli/_utils.py und die Forge-Integration. Vergleiche das vorhandene Command-Frontmatter in templates/commands/plan.md mit den Manifestmodellen und ermittle das normalisierte Handoff-Mapping. Als erledigt gilt, wenn Validierung, Vorrangregeln, abwärtskompatibles Schema-Verhalten, das Forge-Stripping und die Dokumentation durch Implementierungsverifikation abgedeckt sind.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Beschreibung
Problem Statement
ExtensionCommand and preset command entries model fields such as type, name, file, description, and strategy, but do not expose artifact (the repo-relative output path a command produces), optional (whether a flow can skip it), or handoffs (declarative follow-on commands).
handoffs currently lives in command frontmatter and is stripped by several markdown integrations, including Forge. This forces downstream consumers such as wizard UIs, flow runners, and pipeline visualizers to re-parse markdown frontmatter and prevents these semantics from being consistently available through the command manifest model.
Proposed Solution
Add optional artifact, optional, and handoffs fields to extension and preset command manifest entries:
commands:
- name: speckit.plan
file: commands/speckit.plan.md
description: "..."
artifact: specs/{feature}/plan.md
optional: false
handoffs:
- to: speckit.tasks
when: "plan.status == 'done'"
message: "Ready to break plan into tasks"
Parse command frontmatter during manifest loading and merge its handoffs into the command entry when the manifest does not declare them. If both sources provide handoffs, the manifest value takes precedence.
Keep handoffs in the in-memory model, while continuing to strip it on the Forge export path. Define how the existing frontmatter shape (label, agent, prompt, send) maps to or coexists with the manifest shape (to, when, message). In other words, add handoffs to the normalized in-memory command model and JSON output. Accept an explicit manifest declaration as an optional override, but derive it from command frontmatter when absent. Authors should not need to duplicate handoffs in both files.
Alternatives Considered
- Leave
handoffsfrontmatter-only and require consumers to parse it. Rejected because downstream consumers would duplicate parsing. - Derive
artifactfrom the command file. Rejected because a command may produce multiple artifacts or none. - Bump
schema_versionwithout a compatibility strategy. Current validators use exact-version matching, so a bump would reject existing manifests. Prefer an additive change under the current version unless compatibility policy is deliberately changed.
Component
Specify CLI (initialization, commands)
AI Agent (if applicable)
Not applicable
Use Cases
- A wizard renders a Spec-Driven Development pipeline graph by walking
handoffsedges without opening markdown files. - A flow runner shows a skip action for commands with
optional: trueand refuses to auto-skip mandatory commands. - An audit joins a command's
artifactpath to files in the repository.
Acceptance Criteria
- Extension and preset command schemas accept optional
artifact(string),optional(bool, defaultfalse), andhandoffs(list of{to, when?, message?}). - The manifest loader merges command-file frontmatter
handoffswhen the manifest does not declare its own value. - Manifest-declared
handoffstakes precedence over frontmatter. - Forge export continues to strip
handoffsfrom exported frontmatter. -
artifactis validated as repo-relative;handoffs[].toresolves to a known command;optionalis validated as a boolean. - The schema-version decision is recorded, with backward-compatible behavior for existing manifests.
- Valid and malformed manifest entries, frontmatter merge precedence, and Forge stripping are covered by the implementation verification.
- The manifest schema and
handoffssemantics are documented in the relevant existing documentation.
Additional Context
Impacts preset info --json / extension info --json, which are tracked separately.
Relevant implementation locations include src/specify_cli/extensions/__init__.py, src/specify_cli/presets/__init__.py, src/specify_cli/_utils.py::relative_extension_path_violation, and src/specify_cli/integrations/forge/__init__.py. Existing command frontmatter examples include templates/commands/plan.md.
- Vorherrschende Sprache
- Python
- Sterne
- 138k
- Forks
- 12.4k
- Ø Merge
- 2 T. 7 Std.
- Gemergte PRs (30 T.)
- 158
Entwicklungsumgebung
Erste Schritte
- Lesen Sie das ganze Issue und danach den Beitragsleitfaden des Projekts.
- Schreiben Sie ins Issue, dass Sie es übernehmen — das erspart doppelte Arbeit.
- Forken Sie das Repository und arbeiten Sie in einem Branch.
- Öffnen Sie einen Pull Request, der die Issue-Nummer nennt.
Mehr aus github/spec-kit
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 68/100
Maintainer antworten meist innerhalb von 1 Tag
-
Windows: Copilot integration hardcodes `copilot.cmd`, breaking installs that ship `copilot.exe`Offenbug-assess severity-medium triage-nice-to-have
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 88/100
github/spec-kit#4755 · 1 Kommentar ·
Maintainer antworten meist innerhalb von 1 Tag
-
triage-nice-to-have
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 88/100
Maintainer antworten meist innerhalb von 1 Tag
-
[Feature]: 给 slug 添加默认值Offenenhancement needs-triage triage-can-wait
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 65/100
github/spec-kit#4627 · 3 Kommentare ·
Maintainer antworten meist innerhalb von 1 Tag
-
needs-triage triage-nice-to-have
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 72/100
github/spec-kit#4527 · 1 Kommentar ·
Maintainer antworten meist innerhalb von 1 Tag
Alle Issues in github/spec-kit
Ähnliche Issues
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 76/100
PedestrianDynamics/pyFDS-Evac#199 ·
Maintainer antworten meist innerhalb von 1 Tag
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 65/100
521xueweihan/HelloGitHub#3790 ·
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 78/100
sandialabs/atlas-ui-3#978 ·
Maintainer antworten meist innerhalb von 1 Tag
-
area: tests perceived difficulty: 2
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 72/100
Nitjsefnie-Harness-Commons/daedalus#1255 ·
Maintainer antworten meist innerhalb von 1 Tag
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 86/100
EleutherAI/lm-evaluation-harness#4256 ·
Maintainer antworten meist innerhalb von 1 Tag