Skills DirectorySkills Directory
SkillsLearnSecurityCategoriesDocsBlogPro
Sign InSubmit Skill
Skills Directory

Security-tested agent skills for Claude, coding agents, and AI workflows.

Directory

  • Browse Skills
  • All Skills A–Z
  • Claude Skills
  • Claude Code Skills
  • Agent Skills
  • Categories
  • Authors
  • Submit a Skill

Learn

  • Learn Hub
  • Install Claude Skills
  • Write SKILL.md
  • Skills vs MCP
  • Directories Compared

Security

  • Security
  • Methodology
  • Secure Claude Skills
  • Security Badges
  • Chrome Extension
  • Skill Manager

Company

  • About
  • Community
  • Blog
  • API Docs
  • Advertise

2026 Skills Directory. All rights reserved.

ProTermsPrivacyRefunds
Back to skills

Review Lifecycle

ASecurity

Review a resource lifecycle document for completeness, consistency, spec alignment, and correctness of state transitions and invariants.

10 stars
0 votes
0 copies
0 views
Added 10/6/2026
documentationgoapi

Works with

api

Security Analysis

A100/100

Scanned 10/6/2026

$npx -y skills add tomzx/agents --skill review-lifecycle --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Review Lifecycle?

Add the live security badge to your README — it updates automatically with every re-scan.

Security grade badge for Review Lifecycle
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/tomzx-review-lifecycle/badge)](https://www.skillsdirectory.com/skills/tomzx-review-lifecycle)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
Files
SKILL.md
---
name: review-lifecycle
description: Review a resource lifecycle document for completeness, consistency, spec alignment, and correctness of state transitions and invariants.
---

# Review Lifecycle

Audits a resource lifecycle document and reports findings across six categories: completeness, consistency, spec alignment, transition correctness, invariant soundness, and retention soundness.

## Prerequisites

- Apply the shared SDLC conventions in `skills/sdlc/references/shared.md`.
- If no argument is provided, locate the feature directory under `.sdlc/features/` whose frontmatter `issue` field references `$ISSUE_NUMBER`.
- `.sdlc/features/N-<slug>/lifecycle.md`, or a lifecycle document provided in context or as a file path
- `.sdlc/features/N-<slug>/specification.md` (for cross-referencing data models, API contracts, and sequences)
- `.sdlc/features/N-<slug>/requirements.md` (optional, for cross-referencing functional requirements that drive lifecycle behavior)

## Steps

1. Read the lifecycle document from `.sdlc/features/N-<slug>/lifecycle.md` if present, otherwise from context or as a file path.
2. Cross-reference against the specification and requirements if available.
3. Identify issues in each of the six categories below.
4. Report findings. Omit any category that has no findings.
5. Write the findings to `.sdlc/features/N-<slug>/review-lifecycle.md` with frontmatter `artifact: lifecycle`, `verdict` (`approved` if there are no blocking findings, `changes-requested` if the author must address findings, `rejected` for a fundamental flaw), and `reviewed_at: <ISO date>`, and the findings as the body, per `skills/sdlc/references/shared.md`. Record any unresolved open questions in the findings body. For any question that carries meaningful risk to the implementation, also invoke `/create-assumption` to record it formally.

## Review Checklist

### Completeness
- Does every resource identified in the specification's data models have a corresponding lifecycle entry (or an explicit decision to exclude it)?
- Does every state machine have a state diagram showing all states and transitions?
- Does every state have an entry condition, exit condition, and description?
- Does every transition have a trigger, actor, side effects, and guard conditions?
- Are all invariants documented, or is there an explicit statement that no invariants apply?
- Are retention and expiry policies documented for resources that are not permanent?

### Consistency
- Do the states and transitions match the API contracts in the specification (e.g., does `PATCH /orders/{id}/cancel` correspond to a `cancelled` state transition)?
- Are state names consistent with field names and enum values in the specification's data models?
- Are event names consistent with the telemetry plan's event taxonomy if one exists?
- Do the resources listed match the entities in the specification's data models?

### Spec Alignment
- Does every transition trace to a specification section, API endpoint, or sequence that causes it?
- Does every specification sequence that changes resource state have a corresponding transition documented here?
- Are guard conditions consistent with constraints described in the specification?
- Are side effects (notifications, cascading updates) consistent with the specification's sequences?

### Transition Correctness
- Are there unreachable states (states with no incoming transition)?
- Are there states with no exit transition that should have one (dead-end states)?
- Are there missing transitions that the specification implies but the lifecycle does not document?
- Can backward transitions occur, and if so, are their guard conditions and side effects documented?
- Are concurrent or racing transitions accounted for (e.g., two actors triggering conflicting transitions)?

### Invariant Soundness
- Is each invariant actually invariant (does it hold in every state, not just some)?
- Is the enforcement mechanism specific enough (which DB constraint, which validation, which application check)?
- Is the violation handling realistic (does it match what the API or system would actually do)?
- Are there implicit invariants the specification implies but the lifecycle does not state?

### Retention Soundness
- Is the retention period stated for resources that should not persist indefinitely?
- Is the expiry trigger specific (what starts the period: creation, deletion, last access)?
- Is the cleanup action stated and consistent with the specification (hard delete, archive, anonymize)?
- Are there resources that should have a retention policy but do not?

## Output Format

```markdown
## Completeness

<Findings or "No issues found.">

## Consistency

<Findings or "No issues found.">

## Spec Alignment

<Findings or "No issues found.">

## Transition Correctness

<Findings or "No issues found.">

## Invariant Soundness

<Findings or "No issues found.">

## Retention Soundness

<Findings or "No issues found.">
```

## Outcome

If `$OUTCOME_YAML` is set, emit your verdict there per `skills/sdlc/references/shared.md`:

| Verdict | When |
|---|---|
| `approved` | No blocking findings; the subject passes review |
| `changes-requested` | Findings the author must address before it passes |
| `rejected` | Fundamental flaw requiring rework or stopping |

In the same emission, list the findings file under `artifacts:` (`.sdlc/features/N-<slug>/review-lifecycle.md`).

## Example Usage

**Scenario 1: Unreachable state**
The lifecycle defines an `archived` state but no transition leads to it.
Report under Transition Correctness: state `archived` is unreachable, no incoming transition is documented.

**Scenario 2: Missing API correspondence**
The lifecycle documents a transition from `pending` to `shipped` but the specification defines no endpoint or sequence that triggers shipping directly from pending (it requires a `paid` state in between).
Report under Spec Alignment: transition `pending -> shipped` has no corresponding spec sequence; the spec requires `pending -> paid -> shipped`.

**Scenario 3: Invariant not actually invariant**
The invariant "total_amount must be positive" is documented, but the `refunded` state allows `total_amount = 0`.
Report under Invariant Soundness: the invariant does not hold in the `refunded` state, so it is not a true invariant.

**Scenario 4: Missing retention policy**
The lifecycle documents an `ApiKey` resource with `revoked` and `expired` states but no retention policy for how long revoked keys are kept.
Report under Retention Soundness: no retention policy for revoked keys, which may have compliance implications.

## Next Step

Once the findings verdict is `approved`, continue with `/create-mockups`.

Attribution

tomzxtomzx
View sourceSee grades on GitHubMore from tomzx →
SSkills DirectorySkills Directory

Ship a skill? Prove it's safe.

Free 120-pattern security scan, letter grade, and an embeddable README badge.

Submit a skill

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments (0)

No comments yet. Be the first to comment!

SSkills DirectorySkills Directory

Ship a skill? Prove it's safe.

Free 120-pattern security scan, letter grade, and an embeddable README badge.

Submit a skill

Related Skills

Context Fundamentals

Understand the components, mechanics, and constraints of context in agent systems. Use when designing agent architectures, debugging context-related failures, or optimizing context usage.

179001 votes

Architecture Diagram Creator

Create comprehensive HTML architecture diagrams with data flows, business context, and system architecture.

6661 votes

release-notes

Draft release notes and changelog entries from git history or merged PRs between two refs (tags/SHAs/branches), including breaking changes, migrations, and upgrade steps. Use when the user asks for release notes, changelog updates, or a GitHub Release draft.

1301 votes

docs-style-guide

Documentation style guide enforcer by @planetabhi. Applies and reviews the writing style guide when authoring or editing product documentation and tutorials. Use to check prose for voice, tense, word choice, inclusive language, formatting, code block, UI, Markdown, and number/date conventions.

11 votes

Docx

Use this skill whenever the user wants to create, read, edit, or manipulate Word documents (.docx files) or Word templates (.dotx files). Triggers include: any mention of 'Word doc', 'word document', '.docx', '.dotx', or requests to produce professional documents with formatting like tables of contents, headings, page numbers, or letterheads. Also use when extracting or reorganizing content from .docx or .dotx files, inserting or replacing images in documents, performing find-and-replace in W...

1798860 votes
View all in documentation →