DonArtkins

contract-sync

合同同步门禁会在评审前同步实现变更涉及的规范、上下文、工作流和进度记录,消除陈旧引用。涉及模式、路由、GraphQL 类型、环境变量、端口、令牌、枚举或 Docker 服务时适用。

DonArtkins 0 更新于 1个月前
GitHub

安装

npx skillscat add donartkins/griot/contract-sync

通过 SkillsCat registry 安装。

技能简介

合同同步门禁会在评审前同步实现变更涉及的规范、上下文、工作流和进度记录,消除陈旧引用。涉及模式、路由、GraphQL 类型、环境变量、端口、令牌、枚举或 Docker 服务时适用。

SKILL.md

Contract Synchronization Gate

Any implementation change that corrects or changes a contract must be reflected in the same branch across:

  1. The owning system's current feature spec (correct field names, real signatures, final enums).
  2. Every future spec in that system AND every dependent system's specs (fix stale references).
  3. Relevant context files: project-kit/context/*, <system>/project-kit/context/*.
  4. Root AGENTS.md when agent workflow or system boundaries change.
  5. progress-tracker.md of every affected system (session notes on what changed and why).

Contract Types

  • Backend: EF Core entities/relations, enum values, REST route signatures, GraphQL type/query/mutation names, auth token claims/endpoints, GRIOT_SERVICE_TOKEN behavior, Docker/Compose service names and ports.
  • Web/Mobile: route names, theme tokens, query cache shapes, auth store/cookie behavior.
  • Infra: compose service names/ports, container registry names, CI job names, env var matrix.
  • QA: suite names, coverage thresholds, test environment expectations.
  • AI/MCP: tool names, tool input/output JSON contract, agent/task ids, realtime stream shapes.

Procedure

  1. Before starting a feature, list every contract it touches.
  2. Implement.
  3. Diff against every file that references those contracts; update stale mentions in the same branch.
  4. Verify with grep: search the repo for the old contract name/signature and confirm zero stale hits.
  5. Commit the contract updates together with the feature — never on main separately.

A feature is not ready for review while later specs or context still describe stale contracts.