# 04 Spec

> Generate or refine a project spec from a free-form human request, an existing PRD, or reviewer findings. Use when the user says "draft spec", "spec for X", "refine the spec", "generate spec from prd", "/spec", or when an orchestrator needs a normalized contract before planning. Do NOT use for writing source code, drafting a full PRD, or modifying a validated and locked spec.

- **Type:** Skill
- **Install:** `agentstack add skill-ai-driven-dev-framework-04-spec`
- **Verified:** Yes — security-reviewed for prompt injection and unsafe behavior
- **Seller:** [ai-driven-dev](https://agentstack.voostack.com/s/ai-driven-dev)
- **Installs:** 0
- **Category:** [Agent Skills](https://agentstack.voostack.com/c/agent-skills)
- **Latest version:** 0.1.0
- **License:** MIT
- **Upstream author:** [ai-driven-dev](https://github.com/ai-driven-dev)
- **Source:** https://github.com/ai-driven-dev/framework/tree/main/plugins/aidd-pm/skills/04-spec
- **Website:** https://www.ai-driven-dev.fr/

## Install

```sh
agentstack add skill-ai-driven-dev-framework-04-spec
```

Requires the [AgentStack CLI](https://agentstack.voostack.com/docs/cli). Works with Claude Code, Cursor, and any MCP-compatible agent.

## About

# Spec

Generates or refines the immutable contract between human intent and downstream agents.

## Available actions

| #   | Action    | Role                                                              | Input                                  |
| --- | --------- | ----------------------------------------------------------------- | -------------------------------------- |
| 01  | `build`   | Create a fresh spec from a free-form request or an existing PRD    | request or prd_path, feature_name      |
| 02  | `refine`  | Rewrite an existing spec to address reviewer findings              | existing_spec, findings                |

## Default flow

Non-sequential. The router dispatches based on inputs:

- `existing_spec` and `findings` present -> `refine`
- `request` or `prd_path` present -> `build`

## Transversal rules

- Never invent missing information. Mark every gap as `TBD: ` instead of guessing.
- If the request is too vague to draft a useful spec, return early and ask the user to brainstorm the request first; do not fabricate intent.
- Never modify a spec that has been validated and locked.
- The spec is the contract; it is immutable once validated.
- Keep the spec readable: clear section headers, bulleted criteria, explicit non-goals.
- Never include implementation detail (libraries, patterns, file layout); those belong to the plan.
- Do not self-validate. The caller spawns a reviewer with `@assets/spec-validator.yml`; findings come back through the `refine` action for the next iteration.

## References

- None.

## Assets

- `@assets/spec-template.md`: canonical structure of a spec.
- `@assets/spec-validator.yml`: checklist used by the reviewer to validate a spec.

## External data

- None.

## Source & license

This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.

- **Author:** [ai-driven-dev](https://github.com/ai-driven-dev)
- **Source:** [ai-driven-dev/framework](https://github.com/ai-driven-dev/framework)
- **License:** MIT
- **Homepage:** https://www.ai-driven-dev.fr/

Install and usage instructions live in the source repository linked above.

## Pricing

- **Free** — Free

## Security capabilities

Automated source analysis of v0.1.0 — what this tool can access:

- **Network access:** no
- **Filesystem access:** no
- **Shell / process execution:** no
- **Environment & secrets:** no
- **Dynamic code execution:** no

*"Yes" means the capability is present in the source — more access means more to trust, not that it is unsafe.*


## Versions

- **0.1.0** — security scan: passed — Imported from the upstream source.

## Links

- Listing page: https://agentstack.voostack.com/l/skill-ai-driven-dev-framework-04-spec
- Seller: https://agentstack.voostack.com/s/ai-driven-dev
- Browse the marketplace: https://agentstack.voostack.com/browse

---
Listed on AgentStack — the marketplace for AI agent skills and MCP servers. Every listing is security-reviewed. Creators keep 70%.
