contract-validation

Validate OMT agent inputs and outputs against contracts/*.json rules.

2|Updated Oct 16, 2025
One-click install
npx skills add https://github.com/musingfox/cc-plugins --skill contract-validation-musingfox
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: contract-validation
Source: https://github.com/musingfox/cc-plugins/tree/main/omt/skills/contract-validation
Command: npx skills add https://github.com/musingfox/cc-plugins --skill contract-validation-musingfox

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

Activated when an OMT agent starts or finishes execution, when debugging a failed agent run, or when verifying workflow-state.json updates. Validates input/output contracts using the Contract-First pattern defined in contracts/*.json and lib/contract-validator.ts.

Core Features & Use Cases

  • Contract loading and validation against contracts/*.json to verify inputs and outputs.
  • Integration with lib/contract-validator.ts to perform automated checks during execution and debugging.
  • Automatic updates to workflow-state.json to reflect validation results and aid monitoring.
  • Supports end-to-end scenarios across the OMT pipeline and governance.

Quick Start

Enable the contract-validation skill to automatically validate agent contracts during execution and update the workflow state.

Frequently Asked Questions about contract-validation

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

FAQPage Schema
What is contract-first validation for agent workflows?

Contract validation prevents violations by verifying agent inputs and outputs against predefined rules during execution start, finish, or debugging phases, recording results in workflow-state.json to support governance and traceability.

How do I validate agent inputs and outputs against a contract file?

You validate inputs and outputs by loading definitions from contracts/*.json and applying rule checks through lib/contract-validator.ts, which automatically verifies data before and after agent execution and updates workflow-state.json with results.

How does contract validation work when debugging a failed agent run?

During debugging, the validation mechanism leverages lib/contract-validator.ts to perform automated checks against contracts/*.json, verifying previous inputs and outputs to identify where the contract violation occurred within the workflow-state.json updates.

Can I use contract validation for OMT pipeline governance and monitoring?

Yes, you can use it for governance and monitoring. The validation process automatically records results in workflow-state.json, providing traceability and supporting end-to-end governance scenarios across the entire OMT pipeline.

Do I need JSON contract files to enforce workflow validation?

Yes, you need JSON contract files. The validation mechanism relies on definitions stored in the contracts/*.json directory to load the required rules and verify that agent inputs and outputs comply with the contract-first pattern.

When should I not use automated contract validation in my workflow?

You should avoid automated contract validation when your workflow lacks defined contracts in contracts/*.json, or when your agents operate outside the OMT pipeline, as the validation mechanism specifically depends on lib/contract-validator.ts and workflow-state.json integration.