reverse-spec

Analyze repository code and external sources to generate a spec/ directory.

Updated Feb 20, 2026
One-click install
npx skills add https://github.com/sergseven/agent-dev --skill reverse-spec-sergseven
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: reverse-spec
Source: https://github.com/sergseven/agent-dev/tree/main/suites/reverse-spec/skills/reverse-spec
Command: npx skills add https://github.com/sergseven/agent-dev --skill reverse-spec-sergseven

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Onboards an existing repository into the Specification-Driven Development workflow by analyzing code and external knowledge sources in bounded-context chunks, then generating a full spec/ directory that is precise enough to reimplement the system from scratch; resumable after interruption.

Core Features & Use Cases

  • Automates repository onboarding into the SDD workflow by chunking analysis and generating spec directories.
  • Supports external research integration and stateful progress for long-running migrations.
  • Produces a complete spec/ directory (features, API, architecture) suitable for reimplementation.

Quick Start

Run the reverse-spec skill on a repository to generate its spec/ directory and enable resumable progress.

Frequently Asked Questions about reverse-spec

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I generate specifications from an existing codebase for onboarding?

Repository onboarding into specification-driven development works by analyzing code and external knowledge sources in bounded-context chunks. It generates a full spec/ directory covering features, API, and architecture suitable for reimplementation.

What is specification-driven development for auditing a legacy repository?

Specification-driven development for auditing extracts formal specs by analyzing code and external knowledge sources. It generates a comprehensive spec/ directory mapping features, API, and architecture to ensure complete system understanding during handover or auditing.

How do I resume codebase analysis after an interruption?

You can resume codebase analysis after an interruption because the workflow persists progress to a state file at spec/.reverse-spec-state.json. This stateful pipeline enables resumable multi-phase execution without losing prior code analysis data.

Do I need a root SKILL.md file to start reverse engineering code into specs?

Yes, you need a root SKILL.md file with a defined name and description to start reverse engineering code into specs. The workflow leverages this file, alongside optional sub-skills and prompts, to guide the codebase discovery process.

Can I integrate external research sources during codebase spec generation?

Yes, you can integrate external research sources during codebase spec generation. The workflow supports external research integration to enrich the code analysis and produce a more accurate and complete spec/ directory for reimplementation.

What are the limitations of automating repository onboarding into a spec directory?

Limitations of automating repository onboarding include the strict requirement for a root SKILL.md file and potential interruptions during long-running migrations. Complex codebases require extensive multi-phase execution, though progress remains resumable via a state file.