agentleFS
MaicololiverasMaicololiveras/praxisgenai-agent-orchestrator/skills/sdd-spec/SKILL.md

sdd-spec

Skill1 starsChanged 8 months agoMITView on GitHub

Write specifications with requirements and scenarios (delta specs for changes). Trigger: When the orchestrator launches you to write or update specs for a change.

6 other projects use a version of this, 1 of them edited.

Adopted by

Most recently taken up by

Used with

Projects with it also use sdd-plan.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • felipefontouraSkill

    sdd-plan

    Cognitive SDD skill for creating or updating optional PLAN.md from captured ideas or project goals. Use when the conversation calls for roadmap, personas, feature mapping, phases, dependencies, and open decisions before requirements, even without an explicit command. Do not use for feature-level requirements or coding.

    Also in 3 projects that use this

The file

Show its rules and text

We split this skill into the rules it gives an agent

21 rules. 0 are common, 10 are distinctive, and 11 are very specific to this project.

  • 0

    Common

    Most of the 4 edited versions we read keep these.

  • 10

    Distinctive

    This author's own choices. Worth a look.

  • 11

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Read and follow skills/_shared/persistence-contract.md for mode resolution rules.

    line 24
  2. Very specific:

    If mode is engram:

    line 26
  3. Distinctive:

    If specs span multiple domains, concatenate into a single artifact with domain headers.

    line 32
  4. Very specific:

    If mode is openspec: Read and follow skills/_shared/openspec-convention.md.

    line 47
  5. Very specific:

    If mode is hybrid: Follow BOTH conventions — persist to Engram (single concatenated artifact) AND write domain files to filesystem.

    line 48
  6. Very specific:

    If mode is none: Return result only.

    line 49
  7. Very specific:

    If engram not available or not found: read .atl/skill-registry.md from the project root

    line 58
  8. Distinctive:

    If neither exists: proceed without skills (not an error)

    line 59
  9. Very specific:

    If openspec/specs/{domain}/spec.md exists, read it to understand CURRENT behavior.

    line 69
  10. Distinctive:

    Create specs inside the change folder:

    line 73
  11. Distinctive:

    If this is a completely new domain, create a FULL spec (not a delta):

    line 131
  12. Very specific:

    If mode is openspec or hybrid: the file was already written in Step 4.

    line 168
  13. Very specific:

    If mode is hybrid: also call mem_save as above (write to BOTH backends).

    line 170
  14. Distinctive:

    If you skip this step, the next phase (sdd-tasks) will NOT be able to find your specs and the pipeline BREAKS.

    line 172
  15. Very specific:

    ALWAYS use Given/When/Then format for scenarios

    line 199
  16. Distinctive:

    ALWAYS use RFC 2119 keywords (MUST, SHALL, SHOULD, MAY) for requirement strength

    line 200
  17. Very specific:

    If existing specs exist, write DELTA specs (ADDED/MODIFIED/REMOVED sections)

    line 201
  18. Distinctive:

    If NO existing specs exist for the domain, write a FULL spec

    line 202
  19. Distinctive:

    Every requirement MUST have at least ONE scenario

    line 203
  20. Distinctive:

    Keep scenarios TESTABLE — someone should be able to write an automated test from each one

    line 205
  21. Distinctive:

    DO NOT include implementation details in specs — specs describe WHAT, not HOW

    line 206

“Common” is measured: kept by at least 6 in 10 of the 4 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Purpose

You are a sub-agent responsible for writing SPECIFICATIONS. You take the proposal and produce delta specs — structured requirements and scenarios that describe what's being ADDED, MODIFIED, or REMOVED from the system's behavior.

What You Receive

From the orchestrator:

  • Change name
  • Artifact store mode (engram | openspec | hybrid | none)

Execution and Persistence Contract

Read and follow skills/_shared/persistence-contract.md for mode resolution rules.

  • If mode is engram:

    Read dependencies (two-step — search returns truncated previews):

    1. mem_search(query: "sdd/{change-name}/proposal", project: "{project}") → get observation ID
    2. mem_get_observation(id: {id from step 1}) → full proposal content (REQUIRED)

    If specs span multiple domains, concatenate into a single artifact with domain headers.

    Save your artifact:

    mem_save(
      title: "sdd/{change-name}/spec",
      topic_key: "sdd/{change-name}/spec",
      type: "architecture",
      project: "{project}",
      content: "{your full spec markdown — all domains concatenated}"
    )

    topic_key enables upserts — saving again updates, not duplicates.

    (See skills/_shared/engram-convention.md for full naming conventions.)

  • If mode is openspec: Read and follow skills/_shared/openspec-convention.md.
  • If mode is hybrid: Follow BOTH conventions — persist to Engram (single concatenated artifact) AND write domain files to filesystem.
  • If mode is none: Return result only. Never create or modify project files.

What to Do

Step 1: Load Skill Registry

Do this FIRST, before any other work.

  1. Try engram first: mem_search(query: "skill-registry", project: "{project}") → if found, mem_get_observation(id) for the full registry
  2. If engram not available or not found: read .atl/skill-registry.md from the project root
  3. If neither exists: proceed without skills (not an error)

From the registry, identify and read any skills whose triggers match your task. Also read any project convention files listed in the registry.

Step 2: Identify Affected Domains

From the proposal's "Affected Areas", determine which spec domains are touched. Group changes by domain (e.g., auth/, payments/, ui/).

Step 3: Read Existing Specs

If openspec/specs/{domain}/spec.md exists, read it to understand CURRENT behavior. Your delta specs describe CHANGES to this behavior.

Step 4: Write Delta Specs

Create specs inside the change folder:

openspec/changes/{change-name}/
├── proposal.md              ← (already exists)
└── specs/
    └── {domain}/
        └── spec.md          ← Delta spec

Delta Spec Format

# Delta for {Domain}

## ADDED Requirements

### Requirement: {Requirement Name}

{Description using RFC 2119 keywords: MUST, SHALL, SHOULD, MAY}

The system {MUST/SHALL/SHOULD} {do something specific}.

#### Scenario: {Happy path scenario}

- GIVEN {precondition}
- WHEN {action}
- THEN {expected outcome}
- AND {additional outcome, if any}

#### Scenario: {Edge case scenario}

- GIVEN {precondition}
- WHEN {action}
- THEN {expected outcome}

## MODIFIED Requirements

### Requirement: {Existing Requirement Name}

{New description — replaces the existing one}
(Previously: {what it was before})

#### Scenario: {Updated scenario}

- GIVEN {updated precondition}
- WHEN {updated action}
- THEN {updated outcome}

## REMOVED Requirements

### Requirement: {Requirement Being Removed}

(Reason: {why this requirement is being deprecated/removed})

For NEW Specs (No Existing Spec)

If this is a completely new domain, create a FULL spec (not a delta):

# {Domain} Specification

## Purpose

{High-level description of this spec's domain.}

## Requirements

### Requirement: {Name}

The system {MUST/SHALL/SHOULD} {behavior}.

#### Scenario: {Name}

- GIVEN {precondition}
- WHEN {action}
- THEN {outcome}

Step 5: Persist Artifact

This step is MANDATORY — do NOT skip it.

If mode is engram:

mem_save(
  title: "sdd/{change-name}/spec",
  topic_key: "sdd/{change-name}/spec",
  type: "architecture",
  project: "{project}",
  content: "{your full spec markdown from Step 4 — all domains concatenated}"
)

If mode is openspec or hybrid: the file was already written in Step 4.

If mode is hybrid: also call mem_save as above (write to BOTH backends).

If you skip this step, the next phase (sdd-tasks) will NOT be able to find your specs and the pipeline BREAKS.

Step 6: Return Summary

Return to the orchestrator:

## Specs Created

**Change**: {change-name}

### Specs Written
| Domain | Type | Requirements | Scenarios |
|--------|------|-------------|-----------|
| {domain} | Delta/New | {N added, M modified, K removed} | {total scenarios} |

### Coverage
- Happy paths: {covered/missing}
- Edge cases: {covered/missing}
- Error states: {covered/missing}

### Next Step
Ready for design (sdd-design). If design already exists, ready for tasks (sdd-tasks).

Rules

  • ALWAYS use Given/When/Then format for scenarios
  • ALWAYS use RFC 2119 keywords (MUST, SHALL, SHOULD, MAY) for requirement strength
  • If existing specs exist, write DELTA specs (ADDED/MODIFIED/REMOVED sections)
  • If NO existing specs exist for the domain, write a FULL spec
  • Every requirement MUST have at least ONE scenario
  • Include both happy path AND edge case scenarios
  • Keep scenarios TESTABLE — someone should be able to write an automated test from each one
  • DO NOT include implementation details in specs — specs describe WHAT, not HOW
  • Apply any rules.specs from openspec/config.yaml
  • Return a structured envelope with: status, executive_summary, detailed_report (optional), artifacts, next_recommended, and risks

RFC 2119 Keywords Quick Reference

KeywordMeaning
MUST / SHALLAbsolute requirement
MUST NOT / SHALL NOTAbsolute prohibition
SHOULDRecommended, but exceptions may exist with justification
SHOULD NOTNot recommended, but may be acceptable with justification
MAYOptional

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.