Summary
Task completion and projection rendering use two different functions to produce SUMMARY.md content. They produce structurally different output for the same data.
The Two Paths
-
At completion time: renderSummaryMarkdown() in complete-task.ts:45-114 — renders rich markdown from params, stores result in full_summary_md DB column.
-
At projection time: renderSummaryContent() in workflow-projections.ts:147-210 — renders from DB row fields when regenerating projections.
These produce different frontmatter fields, different section ordering, and different formatting.
Impact
- Delete a SUMMARY.md and regenerate it via
renderSummaryProjection() → you get a different file than the original
- Undermines the architectural claim that projections are purely derived views from DB state
- Makes it impossible to verify projection integrity by regenerating and comparing
Fix
Option A: Always use the full_summary_md stored in the DB when rendering projections. The projection renderer should just emit what was stored, not re-derive it.
Option B: Remove full_summary_md from the DB entirely and make renderSummaryContent() the single source of truth. Complete-task would call the same function.
Option A is simpler and preserves the richer formatting from completion time.
Files
src/resources/extensions/gsd/tools/complete-task.ts — lines 45-114 (renderSummaryMarkdown)
src/resources/extensions/gsd/workflow-projections.ts — lines 147-210 (renderSummaryContent)
Summary
Task completion and projection rendering use two different functions to produce SUMMARY.md content. They produce structurally different output for the same data.
The Two Paths
At completion time:
renderSummaryMarkdown()incomplete-task.ts:45-114— renders rich markdown fromparams, stores result infull_summary_mdDB column.At projection time:
renderSummaryContent()inworkflow-projections.ts:147-210— renders from DB row fields when regenerating projections.These produce different frontmatter fields, different section ordering, and different formatting.
Impact
renderSummaryProjection()→ you get a different file than the originalFix
Option A: Always use the
full_summary_mdstored in the DB when rendering projections. The projection renderer should just emit what was stored, not re-derive it.Option B: Remove
full_summary_mdfrom the DB entirely and makerenderSummaryContent()the single source of truth. Complete-task would call the same function.Option A is simpler and preserves the richer formatting from completion time.
Files
src/resources/extensions/gsd/tools/complete-task.ts— lines 45-114 (renderSummaryMarkdown)src/resources/extensions/gsd/workflow-projections.ts— lines 147-210 (renderSummaryContent)