Skip to content

feat: enforce Pattern Schema v1 - #106

Merged
rajanbor merged 1 commit into
mainfrom
feature/pattern-schema-v1
Sep 13, 2026
Merged

rajanbor merged 1 commit into
mainfrom
feature/pattern-schema-v1

Conversation

@rajanbor

Copy link
Copy Markdown
Owner

Outcome

Adds the first enforced contract for MAP patterns and anti-patterns while validating all existing published content unchanged.

Changes

  • add strict Pattern Schema v1 with stable slash-form IDs, lifecycle, MAP Score, evidence, and typed relationships
  • retain legacy related as an explicit compatibility field
  • add complete pattern and anti-pattern examples plus four invalid fixtures
  • validate every repository pattern.yaml, directory identity, required files, duplicate IDs, and relationship targets
  • teach the dependency-free YAML reader folded and literal block strings used by pattern metadata
  • update human schema and pattern-contract documentation

Verification

  • node library/scripts/validate-schemas.ts (4 contracts)
  • node library/scripts/build-registry.ts --check (96 patterns)
  • pnpm lint
  • pnpm typecheck
  • pnpm test (141 tests)

Part of #103.

@rajanbor
rajanbor force-pushed the feature/pattern-schema-v1 branch from 7df456d to a60f303 Compare September 13, 2026 13:02
@rajanbor
rajanbor merged commit 5def1b5 into main Sep 13, 2026
2 checks passed
@rajanbor
rajanbor deleted the feature/pattern-schema-v1 branch September 13, 2026 13:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant