spec-first (sunrain520) — Prompts
Excerpt 1 — using-spec-first SKILL.md (verbatim excerpt)
---
name: using-spec-first
description: "Use before substantial work in a spec-first project, and when users ask what spec-first workflow or command to run next."
---
# Using Spec-First
`using-spec-first` is the standalone meta skill and entry governor for `spec-first` in this repository. It decides whether the current request should enter a public `spec-first` workflow before the agent changes state.
## Contract Summary
| Field | Contract |
| --- | --- |
| When to use | Before substantial work in a `spec-first` repo, and when the user asks what `spec-first` workflow or command to run next. |
| When not to use | Lightweight factual answers, narrow code-location questions, or work already governed by an active public workflow. |
| Artifacts | None. `using-spec-first` does not create plans, task packs, review reports, or durable knowledge. |
| Failure modes | Ambiguous WHAT/HOW, unclear target repo, stale or missing runtime guidance, or a request that names an impossible/unsafe route. Ask one narrow question or route to the repair workflow instead of guessing. |
Prompting technique: Contract-table format. Rather than prose instructions, the skill opens with a machine-readable contract table defining inputs, outputs, when-to-use, when-not-to-use, and failure modes. This reduces ambiguity about the skill's scope.
Excerpt 2 — Core philosophy boundary (from CLAUDE.md verbatim)
## 核心哲学 (Core Philosophy)
必须始终保持:
- **Light contract**:contract 必须轻量、明确、可维护。
- **Explicit boundaries**:明确 source-of-truth、generated runtime、provider、artifact、consumer 边界。
- **Scripts prepare, LLM decides**:脚本产出确定性事实,LLM 做语义判断。
核心 workflow 链路:
Codebase -> Graph -> Spec -> Plan -> Tasks -> Code -> Review -> Knowledge
Prompting technique: Bilingual Iron Law. The core philosophy is written in Chinese (the author's primary language) which may make it less likely to be inadvertently overridden by English-language reasoning. The "Scripts prepare, LLM decides" axiom explicitly separates deterministic operations from semantic judgment.
Excerpt 3 — Scope guard from using-spec-first (verbatim)
### What Counts as Substantial Work
Treat these as substantial work:
- modifying code, docs, config, or generated runtime assets
- starting implementation, debugging, review, planning, setup, update, bootstrap, optimization, or context-capture workflows
- making architectural, prompt, workflow, governance, or contract decisions
These are not substantial work:
- lightweight factual answers
- brief explanations with no workflow leverage
- quick questions where `spec-first` provides no meaningful routing benefit
Prompting technique: Explicit scope boundary with positive/negative examples. Defining what is NOT substantial work is as important as what is — this prevents the governor from over-triggering on trivial queries.