Context
As part of Epic #11372 (Land ADR 0004), we are transitioning all resources/content/ items to the universal ordinal-100 chunking primitive. Currently, ReleaseSyncer.mjs writes flat markdown files directly into resources/content/release-notes/. This violates the universal architecture of ADR 0004.
The Problem
ReleaseSyncer does not use chunking. It writes directly to release-notes/ without chunk-N folders and does not update _index.json. To fully realize ADR 0004 Phase 1, release notes must be chunked identically to issues, PRs, and discussions. This ensures consumer uniformity and prevents folder density issues.
The Architectural Reality
The current ai/services/github-workflow/sync/ReleaseSyncer.mjs iterates over releases and writes <tagName>.md files directly using path.join. We need to rewire this to use contentPath.mjs for resolving paths (e.g. resources/content/release-notes/chunk-1/v1.0.0.md) and register each release in the _index.json map.
The Fix
- Rename
ReleaseSyncer.mjs to ReleaseNotesSyncer.mjs to match the canonical type: 'release-notes' naming.
- Update the write loop to use the universal
contentPath.mjs helper.
- Calculate the
itemIndex based on the chronological sort order of the releases (first release = index 0).
- Maintain the
_index.json registry during the sync.
Acceptance Criteria
Out of Scope
- Migrating existing flat release notes. This will be handled by the clean-slate migration task (Phase 1, Task 10).
- Modifying other syncers (already handled in Lane B).
Avoided Traps
- Using the release version string as an ID for chunk math. Instead, we use the chronological ordinal of the release (1st release is index 0, etc.) to calculate the
chunk-N folder, mirroring the itemIndex logic of issues.
Related
- Epic: #11372
- Authority: ADR 0004
Origin Session ID: 188acb85-b41e-435c-94ee-0cc9944d4c97
Context
As part of Epic #11372 (Land ADR 0004), we are transitioning all
resources/content/items to the universal ordinal-100 chunking primitive. Currently,ReleaseSyncer.mjswrites flat markdown files directly intoresources/content/release-notes/. This violates the universal architecture of ADR 0004.The Problem
ReleaseSyncerdoes not use chunking. It writes directly torelease-notes/withoutchunk-Nfolders and does not update_index.json. To fully realize ADR 0004 Phase 1, release notes must be chunked identically to issues, PRs, and discussions. This ensures consumer uniformity and prevents folder density issues.The Architectural Reality
The current
ai/services/github-workflow/sync/ReleaseSyncer.mjsiterates over releases and writes<tagName>.mdfiles directly usingpath.join. We need to rewire this to usecontentPath.mjsfor resolving paths (e.g.resources/content/release-notes/chunk-1/v1.0.0.md) and register each release in the_index.jsonmap.The Fix
ReleaseSyncer.mjstoReleaseNotesSyncer.mjsto match the canonicaltype: 'release-notes'naming.contentPath.mjshelper.itemIndexbased on the chronological sort order of the releases (first release = index 0)._index.jsonregistry during the sync.Acceptance Criteria
ReleaseSyncer.mjsrenamed toReleaseNotesSyncer.mjs.ReleaseNotesSyncer.mjsusescontentPathwithtype: 'release-notes'.ReleaseNotesSyncer.mjscalculates chronologicalitemIndexfor chunk math.ReleaseNotesSyncer.mjsupdates_index.jsonwith release mappings.release-notes/root directory.Out of Scope
Avoided Traps
chunk-Nfolder, mirroring theitemIndexlogic of issues.Related
Origin Session ID: 188acb85-b41e-435c-94ee-0cc9944d4c97