sdk/HANDOVER-PARITY-DOCS.md
Status: The deliverables described below are implemented in sdk/src/query/QUERY-HANDLERS.md (sections Golden parity: coverage and exceptions and CJS command surface vs SDK registry). Use that file as the canonical registry + parity reference; this handover remains useful for issue #2302 scope and parent #2007 links.
Paste this document (or @sdk/HANDOVER-PARITY-DOCS.md) at the start of a new chat so work continues without re-auditing issue scope.
gsd-tools.cjs and createRegistry() is not expected or not attempted, and why (stubs, structural-only tests, environment-dependent fields, ordering, etc.). Map this to #2007 / #2302 expectations: no undocumented gap.gsd-tools.cjs surface (top-level command or documented cluster) → registered in SDK vs permanent CLI-only vs alias / naming difference, with a one-line justification where not registered.D:\Repos\get-shit-done (PBR backport); adjust path if different machine.feat/sdk-phase3-query-layer — confirm with git branch before editing.gsd-build/get-shit-done.sdk/src/query/QUERY-HANDLERS.md — Registry conventions, partial “not registered” list (graphify, from-gsd2), CLI name differences (summary-extract vs summary.extract, scaffold vs phase.scaffold), intel.update (CJS JSON parity; refresh via agent), skill-manifest --write / mutation events, docs-init golden note (agent install fields), stateExtractField rule.sdk/src/golden/golden.integration.test.ts — Source of truth for which commands are golden-tested and how (full equality vs subset vs normalized existing_docs vs omitted fields; init.quick strips clock-derived keys via init-golden-normalize.ts).sdk/src/golden/capture.ts — captureGsdToolsOutput() spawns get-shit-done/bin/gsd-tools.cjs.docs/CLI-TOOLS.md — User-facing CLI reference; should link to the parity exceptions + matrix (or host a short summary with pointer to sdk/).Add or extend a dedicated section (prefer QUERY-HANDLERS.md under a heading like "Golden parity: coverage and exceptions", or a new sdk/PARITY.md if the team wants less churn in QUERY-HANDLERS — pick one canonical location and link from the other).
Cover at least:
| Category | Examples to document |
|---|---|
| Full JSON parity | Commands where tests use toEqual on sdkResult.data vs CJS stdout JSON. |
| Structural / field subset | Tests that compare only selected keys (e.g. frontmatter.get, find-phase — SDK subset vs CJS). Full parity for roadmap.analyze, init.* (except init.quick volatile keys), etc. — see QUERY-HANDLERS.md matrix. |
| Normalized comparison | e.g. docs-init: existing_docs sorted by path; agents_installed / missing_agents omitted between subprocess vs in-process. |
| CLI parity without in-process refresh | intel.update — JSON matches CJS intel.cjs (spawn hint or disabled); refresh is agent-driven. |
| Conditional behavior | skill-manifest: writes only with --write; not in QUERY_MUTATION_COMMANDS. |
| Environment / time | current-timestamp: structure and format, not same instant. |
| Not in golden suite | Commands registered but not (yet) covered — list as coverage gap or out of scope for golden with rationale. |
Build the table by diffing get-shit-done/bin/gsd-tools.cjs switch (command) top-level cases against createRegistry() registrations in sdk/src/query/index.ts.
Already documented as product-out-of-scope for registry: graphify, from-gsd2 / gsd2-import.
Already documented as naming/alias differences (registered, different string): summary-extract ↔ summary.extract; top-level scaffold ↔ phase.scaffold.
Matrix columns (suggested):
Optional: footnote that detect-custom-files skips multi-repo root resolution in CJS (SKIP_ROOT_RESOLUTION) — behavior is documented in CLI; matrix can mention if relevant.
| Path | Role |
|---|---|
sdk/src/query/QUERY-HANDLERS.md | Primary home for exceptions + matrix, or link hub. |
sdk/PARITY.md | Optional dedicated file if QUERY-HANDLERS becomes too long. |
docs/CLI-TOOLS.md | Short “Parity & registry” subsection with links into sdk/ docs. |
sdk/HANDOVER-GOLDEN-PARITY.md | Optional one-line pointer to new parity doc section when done. |
GSDTools → registry) — separate #2302 work.@deprecated headers to gsd-tools.cjs — separate task.npm run build in sdk/ only if TypeScript-adjacent files were touched.gsd-tools top-level commands are not registered and why?” from one table.Created for handoff to “parity exceptions + CJS-only matrix” session. Update when the canonical doc location or golden coverage changes.