🎩 You're Invited:Meet the Socket team at Black Hat in Las Vegas, August 3-6.RSVP
Sign In

@colmbyrne/specflow

Package Overview
Dependencies
Maintainers
1
Versions
33
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@colmbyrne/specflow

Specs that enforce themselves. Contract tests, journey hooks, and agent orchestration for LLM-driven development.

Source
npmnpm
Version
0.1.11
Version published
Weekly downloads
44
Maintainers
1
Weekly downloads
 
Created
Source

Specflow

Specs that enforce themselves.

LLMs drift. You write a rule; three iterations later the model "helpfully" ignores it. Specflow turns your specs into contract tests that break the build when violated — so drift can't ship.

The Problem

// Your spec: "Service workers MUST NOT use localStorage"
// LLM adds this anyway after iteration 3:
const token = localStorage.getItem('auth') // No crash. Just drift.

LLMs don't read. They attend. Your spec competes with millions of training examples. You can't fix this with better prompts. You need a gate.

The Solution

Contract tests scan your source code for forbidden patterns. Break a rule → build fails. Journey tests run Playwright against your critical flows. If a journey doesn't pass, the feature isn't done.

Get Started

npx @colmbyrne/specflow init .

Creates CLAUDE.md, contracts, hooks, agents, and tests. Then fill in the Project Context section in CLAUDE.md (Repository, Board, CLI, Tech Stack).

Commands

npx @colmbyrne/specflow init .          # Set up Specflow (safe to re-run)
npx @colmbyrne/specflow verify          # Check installation (13 sections)
npx @colmbyrne/specflow update . --ci   # Update hooks + install CI workflows
npx @colmbyrne/specflow audit 500       # Audit issue #500 for compliance
npx @colmbyrne/specflow graph           # Validate contract cross-references

What You Get

LayerWhat it does
Contract testsYAML rules scan source for forbidden patterns — break a rule, build fails
Journey testsPlaywright tests for critical user flows — if a journey doesn't pass, the feature isn't done
HooksAuto-trigger tests on build/commit, catch violations on Write/Edit, reject commits without issue numbers
CI workflowsPR compliance gate + post-merge audit — no contract violations merge to main
30+ agentsOrchestrate wave execution, write contracts, audit boards, simulate specs

FAQ

Isn't this just more testing? No. Tests verify behaviour. Contracts verify architecture. "No localStorage in service workers" survives any refactor.

What if I don't have a perfect spec? Start with "document what works today." Your first contract can be: whatever we're doing now, don't break it.

Can LLMs actually follow contracts? Even if they don't, tests catch it. You don't need the LLM to behave. You need it to be checkable.

Detailed SetupManual paths, updating, SKILL.md
Agent Library30+ agents for wave execution
Contract SchemaYAML format for contracts
CI IntegrationGitHub Actions setup
npm@colmbyrne/specflow
IssuesBugs and ideas

FAQs

Package last updated on 02 Apr 2026

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts