agentleFS
cedaniel200cedaniel200/atlas-template/.agents/skills/gherkin-specs/SKILL.md

gherkin-specs

Skill3 starsChanged 23 days agoMITView on GitHub

Use when writing or editing OpenSpec specs — guides Gherkin-style GIVEN/WHEN/THEN scenarios in the domain's business language.

1 other project uses a version of this.

Adopted by

Most recently taken up by

The file

We split this skill into the rules it gives an agent

6 rules. About 0 are common, 6 are distinctive, and 0 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈6

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 0

    Very specific

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

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Write domain specifications using Gherkin-style scenarios.

    line 11
  2. Distinctive:

    Do NOT use for implementation details, technical design, or test code.

    line 20
  3. Distinctive:

    Domain language: use the business terms defined in AGENTS.md.

    line 38
  4. Distinctive:

    No implementation terms: avoid class names, layers, endpoints or data structures.

    line 39
  5. Distinctive:

    One behavior per scenario: do not test several variants in the same scenario.

    line 40
  6. Distinctive:

    GIVEN is mandatory: every scenario needs an explicit initial state.

    line 41

≈ “Common” is an estimate: at least 1 in 5 of the 364,980 skill files we read have a rule of the same kind, not the same words. “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

Gherkin Specs

Overview

Write domain specifications using Gherkin-style scenarios. Each scenario describes one behavior from the user's perspective, using the domain's business language.

When to Use

  • During the propose phase, when writing specs/
  • Editing existing specs in openspec/specs/<capability>/spec.md
  • Adding scenarios for edge cases or new requirements

Do NOT use for implementation details, technical design, or test code. Specs describe WHAT the system does, not HOW.

Format

### Requirement: <name>
<Business description in domain language>

#### Scenario: <name>
- **GIVEN** <precondition / initial state>
- **WHEN** <action / trigger>
- **THEN** <expected outcome>
- **AND** <additional outcomes> (optional)

Conventions

  • Domain language: use the business terms defined in AGENTS.md; do not introduce synonyms.
  • No implementation terms: avoid class names, layers, endpoints or data structures.
  • One behavior per scenario: do not test several variants in the same scenario.
  • GIVEN is mandatory: every scenario needs an explicit initial state.
  • Independence: scenarios do not depend on each other; each sets its own GIVEN.
  • Business, not UI: describe intent, not clicks or screens.

Examples

The identifiers in angle brackets are placeholders. Replace them with the project's domain terms.

Requirement: Register <entity> with a unique identifier

The system allows registering an <entity> with a unique identifier.

Scenario: Successful registration

  • GIVEN a valid identifier that does not exist in the system
  • WHEN an <entity> is registered with its mandatory data
  • THEN the <entity> is created with the provided data
  • AND the corresponding domain event is published

Scenario: Duplicate identifier rejected

  • GIVEN an existing <entity> with identifier X
  • WHEN another <entity> is registered with the same identifier X
  • THEN the system rejects the operation with a duplicate error

Requirement: Register <lifecycle event>

The system allows recording a <lifecycle event> for an existing <entity>.

Scenario: Successful lifecycle transition

  • GIVEN an <entity> in a state that allows the transition
  • WHEN the <lifecycle event> is registered with its data
  • THEN the <entity> moves to the new state
  • AND the state change is visible in subsequent queries

Scenario: Invalid transition rejected

  • GIVEN an <entity> in a state that does not allow the transition
  • WHEN the <lifecycle event> is registered
  • THEN the system rejects the operation with an invalid-state error

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.