Token导航 LogoToken导航TokenDH.com
研究检索需要联网github未标认证来源可访问许可证需确认审计通过

specification-first规格第一

Agent Skill

specification-first 用于查找、检索和筛选相关信息,适合在 Codex、Claude、Cursor、Gemini CLI 中需要根据关键词、任务场景或来源线索快速定位候选结果时使用。可结合来源仓库、安装命令和原始 README 继续核验具体用法。安装前建议确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写。

总安装

294

周安装

12

GitHub Stars

25

下载量

94
CodexClaudeCursorGemini CLI

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

GitHub

来源数

2

许可证

unknown

最后核验

2026-05-01

来源状态

来源可访问

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:specification-first(规格第一)
来源仓库:https://github.com/noobygains/godmode
仓库路径:skills/specification-first
安装命令:
npx skills add https://github.com/noobygains/godmode --skill specification-first
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 npx skills 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

skills.shnpx skills
npx skills add https://github.com/noobygains/godmode --skill specification-first

简介

specification-first 用于查找、检索和筛选相关信息,适合在 Codex、Claude、Cursor、Gemini CLI 中需要根据关键词、任务场景或来源线索快速定位候选结果时使用。

  • 它可辅助 Agent 从文档、代码库或知识库中提取匹配内容,并按相关性排序返回。
  • 通过 npx skills add 命令从指定仓库安装,具体用法需结合原始 README 进一步确认。
  • 安装前建议核实权限范围、维护状态,以及是否会触发联网、命令执行或文件读写操作。
  • 适用宿主包括 Codex、Claude、Cursor、Gemini CLI,接入前应确认版本、权限和运行环境要求。

SKILL.md

Specification First

Overview

Author the specification before the implementation. The specification is the source of truth. Code is generated to satisfy the specification, never the reverse.

Core principle: A behavior specification defines WHAT the system does. Code implements HOW. Without a specification, you are guessing.

No exceptions. No workarounds. No shortcuts.

The Prime Directive

NO IMPLEMENTATION WITHOUT A SPECIFICATION FIRST

If you have not produced a specification defining inputs, outputs, edge cases, and acceptance criteria, you are not authorized to write code. This is not optional. This is not excessive. This prevents the leading cause of AI-generated code failures: building the wrong thing.

When to Use

Mandatory when:

  • Developing a new feature or module
  • Creating an API endpoint
  • Constructing a data pipeline
  • Building any system with defined inputs and outputs
  • The user says "build me X" or "create Y"

Exceptions (confirm with the human):

  • Configuration changes
  • Single-line defect fixes with unambiguous behavior
  • Documentation updates

The Entry Protocol

BEFORE writing any implementation code:

1. IDENTIFY: What are the inputs?
2. DEFINE: What are the expected outputs?
3. CONSTRAIN: What are the boundaries and limitations?
4. EDGE: What happens at the edges? (empty, null, maximum, concurrent)
5. ACCEPT: What criteria demonstrate correctness?
6. WRITE: Produce the specification document
7. APPROVE: Obtain user confirmation
8. ONLY THEN: Implement

Omit any step = building the wrong thing

Specification Document Template

# [Feature Name] Specification

## Purpose
[Single sentence: what this does and why it exists]

## Inputs
| Input | Type | Required | Constraints | Default |
|-------|------|----------|-------------|---------|
| [name] | [type] | [yes/no] | [validation rules] | [default] |

## Outputs
| Scenario | Output | Shape |
|----------|--------|-------|
| Success | [what is returned] | [type/structure] |
| Invalid input | [error response] | [error shape] |
| Not found | [404 response] | [error shape] |

## Behavior

### Standard Path
1. [Step-by-step behavior for normal usage]
2. [Include state mutations, side effects]

### Edge Cases
| Case | Input | Expected Behavior |
|------|-------|-------------------|
| Empty input | "" | Return validation error |
| Maximum length | 10000 chars | Truncate to 5000 |
| Concurrent access | 2 simultaneous requests | Serialize second request |
| [case] | [input] | [behavior] |

## Acceptance Criteria
- [ ] [Criterion 1 - testable, specific]
- [ ] [Criterion 2 - testable, specific]
- [ ] [Criterion 3 - testable, specific]

## Explicitly Excluded (YAGNI)
- [Feature intentionally omitted]
- [Optimization intentionally deferred]

Relationship with Test-First Development

digraph spec_test_flow {
    rankdir=LR;
    spec [label="Author Spec\n(this skill)", shape=box style=filled fillcolor=lightyellow];
    test [label="Write Failing Test\nfrom Spec Criteria", shape=box style=filled fillcolor="#ffcccc"];
    code [label="Write Minimal Code\nto Pass Test", shape=box style=filled fillcolor="#ccffcc"];
    verify [label="Verify Against\nSpec Criteria", shape=box style=filled fillcolor="#ccccff"];

    spec -> test [label="acceptance criteria\nbecome test cases"];
    test -> code [label="test-first cycle"];
    code -> verify [label="all criteria satisfied?"];
    verify -> spec [label="no - revise spec\nor implementation"];
}

Specification -> Tests -> Code -> Verify against Specification

The specification's acceptance criteria map directly to test cases. Each criterion generates at least one test. If you cannot derive a test from a criterion, the criterion is too vague -- refine the specification.

Specification Depth Levels

LevelWhen AppropriateScope
MinimalSimple feature, obvious behaviorPurpose + Inputs + Outputs + 3 acceptance criteria
StandardMost featuresFull template above
ExhaustiveComplex systems, public APIs, multi-tenantFull template + sequence diagrams + state machines + error taxonomy

Scale the specification to the complexity. A utility function warrants a minimal spec. An authentication system demands an exhaustive one.

Cognitive Traps

RationalizationTruth
"It is too simple to specify"Simple features harbor hidden edge cases. A specification takes 2 minutes.
"I will figure it out while coding"You will build the wrong thing and refactor three times.
"The user already described what they want"Users describe goals, not behavior. The specification bridges that gap.
"Test-first is sufficient; I do not need a spec"Test-first tells you WHAT to verify. The specification tells you WHAT to build. Both are necessary.
"Specifications slow me down"Specifications prevent building the wrong thing. That is faster in every measurable way.
"I will write the spec afterward"Specifications written after implementation rationalize what was built, not what should have been built.
"AI understands my intent"AI produces plausible code that may diverge from intent. The specification eliminates ambiguity.

Guardrails

Prohibited actions:

  • Starting implementation before specification approval
  • Writing tests without referencing specification criteria
  • Changing behavior without updating the specification
  • Shipping without verifying against acceptance criteria
  • Deferring edge cases ("we will handle those later")
  • Writing a specification after implementation is complete

Required actions:

  • Obtain specification approval before writing code
  • Map acceptance criteria to test cases one-to-one
  • Update the specification when requirements evolve
  • Verify all criteria pass before declaring completion
  • Include explicitly excluded features (what you are NOT building)

Integration

Workflow sequence:

  • godmode:intent-discovery -> produces design
  • godmode:specification-first -> produces specification from design
  • godmode:task-planning -> produces implementation plan from specification
  • godmode:test-first -> produces tests from specification criteria
  • godmode:completion-gate -> verifies against specification criteria

REQUIRED COMPANION SKILL: Invoke godmode:test-first when implementing

适合场景

01

用户想查找某类 Agent Skill 时

02

需要根据任务场景推荐可安装能力包时

03

需要对比不同来源的安装命令和来源信息时

能力概览

能力 1

按任务关键词查找相关 Skills

能力 2

展示可复制的安装命令

能力 3

保留来源站点、仓库和原始说明,方便继续核验

能力 4

展示第三方安全扫描或审计结果

安装后应在对应宿主中按原始 README 的触发条件使用;具体调用方式请以来源页面和 README 为准。

平台分布

Codex

32.84%
按下载量换算31

Claude

30.6%
按下载量换算29

Cursor

20.3%
按下载量换算19

Gemini CLI

8.88%
按下载量换算8

安全审计

Gen Agent Trust Hub

通过

Socket

通过

Snyk

通过

权限和风险

需要联网

该 Skill 可能需要联网访问来源站点、仓库或外部 API;具体网络访问范围需要结合源码和 README 复核。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。当前只有一个来源,正式发布前建议补源仓库或其他目录站核验。

来源信息

继续浏览同类 Skills