PactSpec is an open protocol. Contributions are welcome.
- Fork the repo and create a branch from
main - Make your changes — code, docs, benchmarks, conformance tests
- Run tests —
npx tsx --test src/lib/*.test.ts - Run type check —
npx tsc --noEmit - Submit a PR against
main
- Benchmark suites — domain-specific test suites with known correct answers. See
benchmarks/for examples. If you have domain expertise (medical coding, legal, security, etc.), your benchmarks are especially valuable. - Framework integrations — LangChain, CrewAI, AutoGen, or any orchestrator that could query the PactSpec registry.
- Bug fixes — especially in the validator, CLI, or API routes.
- Conformance tests — expand
conformance/valid/andconformance/invalid/to cover edge cases. - Documentation — improve guides, fix typos, add examples.
Benchmarks are JSON files in benchmarks/. Each benchmark should include:
sourcefield:synthetic,peer-reviewed,industry-standard, orcommunitysourceDescription: honest description of where the test data comes fromsourceUrl: link to the authoritative source (if applicable)
If your benchmark uses data from peer-reviewed sources, include the citation. If it's synthetic, say so.
The registry at pactspec.dev is a database, not a file. To publish or update an agent:
- Use the CLI:
pactspec publish agent.json --agent-id your-org - Use the web form: https://pactspec.dev/publish
- Use the SDK:
@pactspec/registermiddleware or@pactspec/sdk
Agent owners can update their own specs by republishing with the same spec_id. There is no manual approval process for publishing.
- TypeScript for all web and CLI code
- No unnecessary dependencies
- Tests for security-critical code
- Don't add comments explaining obvious code
Open an issue: https://github.com/Grumpy254/pactspec/issues