specflow

Validate YAML contract files and run vitest suites to block contract violations.

7|1|Updated Feb 9, 2026
One-click install
npx skills add https://github.com/fall-development-rob/corp_finance --skill specflow-fall-development-rob
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: specflow
Source: https://github.com/fall-development-rob/corp_finance/tree/main/.claude/skills/specflow
Command: npx skills add https://github.com/fall-development-rob/corp_finance --skill specflow-fall-development-rob

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Specflow prevents requirement drift and inadvertent policy violations by turning written requirements into executable contracts that block merges when rules are broken. It removes ambiguity between specs and implementation by validating code against YAML-defined forbidden and required patterns and by running contract suites as part of development and CI.

Core Features & Use Cases

  • Contract generation: Create contract YAML from requirement IDs and embed forbidden/required regex patterns and scopes.
  • Automated tests & CI gating: Generate and run contract tests that scan source code and tools, failing builds and blocking PRs on violations.
  • Drift detection & governance: Detect documentation and module drift (tool counts, agent coverage, ADR gaps) and enforce non_negotiable rules with a human override protocol.
  • Use case: In a multi-agent CFA codebase, use Specflow to ensure agents and MCP tools adhere to Zod schemas, avoid direct math in agent prompts, and maintain route/prompt coverage without silent regressions.

Quick Start

Verify all contracts and report any violations across the repository by running the specflow verification workflow.

Frequently Asked Questions about specflow

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

FAQPage Schema
How do I enforce specification-driven contracts to prevent requirement drift in a codebase?

To prevent requirement drift, specification-driven contracts validate code against YAML-defined forbidden and required regex patterns and run vitest contract suites to block PRs when rules are broken. This removes ambiguity between specs and implementation during development and CI.

What is contract testing for MCP toolchains and multi-agent codebases?

Contract testing for MCP toolchains and multi-agent codebases validates agent prompts, tool schemas, and architecture constraints to ensure agents adhere to Zod schemas and maintain route coverage. It executes automated checks to block silent regressions across tool counts and agent behaviors.

How do I detect documentation drift and architecture gaps during continuous integration?

Detect documentation drift and architecture gaps during CI by running automated contract verification workflows that check for module drift, agent coverage, and ADR gaps. The workflow reports violations across the repository and fails builds when documentation misaligns with code.

Can I use vitest to run contract suites that block merges on policy violations?

Yes, vitest executes generated contract suites that scan source code and tools to block merges on policy violations. The tests enforce non_negotiable rules and require explicit human overrides for any exceptions, ensuring strict governance over the codebase.

Does contract YAML support non_negotiable rules with a human override protocol?

Contract YAML supports non_negotiable rules by defining strict forbidden and required regex patterns that block builds automatically. It includes a human override protocol that requires explicit approval to bypass these constraints when exceptions are necessary.

What's the best way to validate agent prompts and tool schemas against Zod schemas?

The best way to validate agent prompts and tool schemas against Zod schemas is applying specification-driven contracts that scan for forbidden patterns like direct math in prompts. This ensures multi-agent CFA projects maintain route and prompt coverage without silent regressions.