spec-miner

Extract undocumented functionality from codebases into EARS-formatted specifications.

10.9k|1.0k|Updated Oct 20, 2025
One-click install
npx skills add https://github.com/Jeffallan/claude-skills --skill spec-miner
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: spec-miner
Source: https://github.com/Jeffallan/claude-skills/tree/main/skills/spec-miner
Command: npx skills add https://github.com/Jeffallan/claude-skills --skill spec-miner

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill captures and documents undocumented or legacy systems using code evidence, enabling reliable specs and onboarding.

Core Features & Use Cases

  • Evidence-based spec: Gather observations with code locations.
  • EARS formatting: Produce structured requirements and acceptance criteria.
  • Documentation scaffolding: Create specs in a consistent template.

Quick Start

Generate a reverse-spec document for a legacy module using EARS templates.

Frequently Asked Questions about spec-miner

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

FAQPage Schema
How do I extract specifications from legacy code without documentation?

Specification extraction from legacy code uses automated code analysis to identify undocumented functionality by examining actual source files, collecting evidence of behavior, and producing structured EARS-formatted requirements. This grounds observations directly in code locations rather than assumptions.

Can I reverse engineer a codebase to create documentation?

Yes. Reverse engineering uses code analysis tools like grep and glob to search existing codebases, extract functional patterns, and document them with evidence-based specifications. The output is a reverse-spec document mapping features to their implementation locations.

What's the best way to onboard to an unfamiliar codebase quickly?

Generate a reverse-spec document from the codebase itself. Code analysis identifies key components, functions, and dependencies, then structures them as EARS-formatted requirements with code references, accelerating understanding without manual code review.

How do I document undocumented systems using code evidence?

Code evidence documentation involves analyzing the codebase with read, grep, and glob operations to locate functionality, then producing EARS-formatted requirements in a consistent template. All observations reference specific code locations to ensure accuracy.

Can I use reverse engineering to plan feature enhancements on legacy systems?

Yes. By extracting specifications from the existing codebase with code analysis, you map current functionality, dependencies, and behavior patterns. This evidence-based specification reveals integration points and constraints for planning new features without modifying untested systems.

What limitations should I know about extracting specs from code?

Code analysis captures implemented behavior but may miss undocumented edge cases, implicit assumptions, or design intent not visible in source. Always document uncertainties discovered during analysis and validate extracted specifications against actual system behavior.