This document defines how Semantic Versioning (SemVer) is applied across the compartmentalized architecture:
- Core (
core/) - Platform (
orchestrator/) - Clients (
api/,vscode-extension/) - Contracts (
contracts/v1/)
After the refactor, component boundaries are explicit and independently evolvable. SemVer gives each boundary a predictable compatibility contract:
- MAJOR = backward-incompatible changes
- MINOR = backward-compatible feature additions
- PATCH = backward-compatible fixes
This reduces accidental breakage between Platform/Core and across client surfaces.
Canonical component versions live in:
versioning/compatibility.json→components- Optional push/release declaration metadata lives in:
versioning/compatibility.json→release_intent
The local validator (versioning/validate_semver.py) enforces parity between this file and version declarations in code/manifests.
Compatibility is currently enforced at major-version granularity.
| Consumer | Compatible with |
|---|---|
| Platform | Core major 2, Contracts v1 major 1 |
| API (REST API) | Platform major 2 |
| VS Code Extension | API major 2 |
Matrix source:
versioning/compatibility.json→compatibility
contracts/v1/__init__.pydefines__version__- Any breaking schema/adapter change requires MAJOR bump
core/__init__.pydefines__version__core/api.pyFastAPI appversionmust match Core version
orchestrator/__init__.pydefines__version__pyproject.toml[project].versionis aligned to Platform package version
api/__init__.pydefines__version__api/app.pyFastAPI appversionmust match API version
vscode-extension/package.jsonversion
Until CI is introduced, SemVer is enforced through local automation:
-
Release-intent guard
python versioning/check_release_intent.py- Detects changed component areas in outgoing commits and fails if
versioning/compatibility.jsonwas not updated. - In pre-push hooks,
.githooks/pre-pushrunspython versioning/check_release_intent.py --pre-pushso outgoing commit detection uses Git's pre-push ref payload (<local_sha>..<remote_sha>logic) instead of relying only on branch-tracking heuristics.
-
Validator script
python versioning/validate_semver.py- Checks SemVer format, cross-file parity, and compatibility matrix majors.
-
NPM shortcuts
npm run check:release-intentnpm run validate:semvernpm run release:check(runs both checks)
-
Git hook (pre-push)
- Hook file:
.githooks/pre-push - Install once per clone:
npm run hooks:install
- Hook file:
-
Release checklist
- See:
docs/technical/release-checklist.md
- See:
When pushing partial work (for example, an incomplete multi-step spec implementation),
declare intent in versioning/compatibility.json under release_intent.
Recommended shape:
"release_intent": {
"status": "wip",
"summary": "Short explanation of what is incomplete.",
"spec": "path/to/spec.md",
"implemented": ["completed parts"],
"pending": ["remaining parts"]
}Guidelines:
- Use
status: "wip"for non-release pushes. - Keep
implementedandpendingaligned with the source spec checklist. - Do not bump component versions while
statusiswip. - Before a real release, either remove the WIP declaration or update it to a release-ready state with fully completed scope.
When CI is added, reuse the exact local validator command:
npm run release:checkNo policy rewrite is required; CI becomes an execution environment for the same checks.