add-parser

Adds specification parsers while preserving shared scenario semantics and source locations.

Updated Aug 14, 2026
One-click install
npx skills add https://github.com/Cratis/Synopsis --skill add-parser-cratis
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: add-parser
Source: https://github.com/Cratis/Synopsis/tree/main/.cratis/ai/skills/add-parser
Command: npx skills add https://github.com/Cratis/Synopsis --skill add-parser-cratis

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Extending a specification discovery tool with a new parser risks breaking shared scenario semantics, losing source locations, or crashing on malformed input. This Skill provides a disciplined workflow for adding or extending parsers safely. ## Core Features & Use Cases - Test-Driven Parser Development: Start with a failing Cratis-style specification using the smallest representative source before implementing parser logic. - Semantic Preservation: Maintain the shared BehaviorScenario semantics and accurate source locations across all parsers. - Resilient Error Handling: Keep malformed-input handling local so a bad file returns a diagnostic instead of failing the entire discovery run. - Use Case: When adding support for a new test framework's specification format, follow this workflow to write the failing spec first, implement the parser, register the extension only when false positives are safely rejected, then verify with dotnet test, a Release build, and a generated sample HTML report. ## Quick Start Add a new specification parser for the target format following the add-parser workflow, starting with a failing specification and ending with a verified Release build.

Frequently Asked Questions about add-parser

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

FAQPage Schema
How do I add a new specification parser to a .NET project?▼

Start by writing a failing Cratis-style specification with the smallest representative source input. Then implement the parser to preserve shared BehaviorScenario semantics and source locations, and verify with dotnet test and a Release build.

How should a parser handle malformed specification files?▼

Keep malformed-input handling local to the parser and return a diagnostic rather than throwing. This prevents one bad file from failing the entire discovery run across the repository.

When should a new file extension be registered for discovery?▼

Register the new extension in discovery only when the parser can safely reject false positives. Registering too early risks misinterpreting unrelated files as specifications.

Why must parsers preserve source locations?▼

Source locations link each behavior statement back to its evidence in the originating specification file. Losing them breaks traceability in the generated behavior documentation.

How do I verify a new parser works correctly?▼

Run dotnet test to confirm all specifications pass, perform a Release build, and generate the Samples/Bookshop/synopsis.html output for visual inspection of the parsed scenarios.