scip-query 0.19.4 → 0.19.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (400) hide show
  1. package/CHANGELOG.md +75 -1
  2. package/README.md +242 -49
  3. package/dist/augment-vue-worker.js +1 -1
  4. package/dist/{chunk-2YU7I3QO.js → chunk-24QNP7MN.js} +2 -2
  5. package/dist/{chunk-CNKAGUPL.js → chunk-26X7KCJR.js} +2 -2
  6. package/dist/{chunk-GPBBJ5Y4.js → chunk-273W2U4Y.js} +3 -3
  7. package/dist/{chunk-7GXM52MI.js → chunk-2CVXCGL4.js} +2 -2
  8. package/dist/{chunk-ABMYA4TN.js → chunk-2EZSOTSY.js} +2 -2
  9. package/dist/{chunk-HKEHS2AS.js → chunk-2GSQR6YA.js} +2 -2
  10. package/dist/{chunk-FECYOO5O.js → chunk-2OXVAGGT.js} +2 -2
  11. package/dist/chunk-2ZOCHAL2.js +8 -0
  12. package/dist/{chunk-QGXBRIM5.js → chunk-336DC5NJ.js} +2 -2
  13. package/dist/chunk-35SQLYCQ.js +2 -0
  14. package/dist/{chunk-VXQNNXJE.js → chunk-3OIKRYU5.js} +2 -2
  15. package/dist/{chunk-52ZYCAEO.js → chunk-47X75ZKH.js} +2 -2
  16. package/dist/{chunk-NPKYOIFM.js → chunk-4CGVLUDP.js} +2 -2
  17. package/dist/chunk-4RI4BJGT.js +8 -0
  18. package/dist/{chunk-P2PC2WGR.js → chunk-52HQTTPB.js} +2 -2
  19. package/dist/{chunk-YNRNA5LK.js → chunk-5OC3HWP5.js} +2 -2
  20. package/dist/{chunk-STOL2BTL.js → chunk-6XFC7PQ5.js} +2 -2
  21. package/dist/{chunk-J77UIT3I.js → chunk-6XHTISLI.js} +2 -2
  22. package/dist/chunk-6YTSKJJ3.js +2 -0
  23. package/dist/{chunk-BTEE5NZQ.js → chunk-7E3TH5ZN.js} +2 -2
  24. package/dist/{chunk-X6D5IC6I.js → chunk-7LABSJSR.js} +2 -2
  25. package/dist/chunk-7Q6VYYCH.js +2 -0
  26. package/dist/{chunk-FWUUZTIO.js → chunk-A43URCQ3.js} +2 -2
  27. package/dist/chunk-A63U2W3P.js +3 -0
  28. package/dist/{chunk-3MJ5YA4Y.js → chunk-ADFSIJP2.js} +2 -2
  29. package/dist/chunk-AOLE4DYM.js +6 -0
  30. package/dist/chunk-APMMR5Y2.js +2 -0
  31. package/dist/chunk-B5MHCHP3.js +107 -0
  32. package/dist/{chunk-4RSI5EMG.js → chunk-CSTYYXKC.js} +2 -2
  33. package/dist/{chunk-25LPM4DG.js → chunk-CYJM7CYF.js} +2 -2
  34. package/dist/{chunk-S44IULR6.js → chunk-DD5BOU5I.js} +2 -2
  35. package/dist/{chunk-YGAGTIDK.js → chunk-DGMCFMPG.js} +7 -7
  36. package/dist/{chunk-UOAV44HR.js → chunk-E2ZXPB7J.js} +2 -2
  37. package/dist/{chunk-IZKFSVBV.js → chunk-EVOC5I5I.js} +2 -2
  38. package/dist/{chunk-XTX6QHOF.js → chunk-F42A3AKG.js} +2 -2
  39. package/dist/{chunk-Q4IIEGXJ.js → chunk-FHCTEANE.js} +2 -2
  40. package/dist/{chunk-3SVWW4PN.js → chunk-FKGN4A4E.js} +2 -2
  41. package/dist/{chunk-IG7N5ZIK.js → chunk-FQTPPXNA.js} +2 -2
  42. package/dist/{chunk-F6O7AAC3.js → chunk-G4UQL4CP.js} +2 -2
  43. package/dist/chunk-GA64UPMI.js +6 -0
  44. package/dist/{chunk-ZXJYMGD3.js → chunk-GK3GRUJX.js} +2 -2
  45. package/dist/chunk-HEBAY673.js +2 -0
  46. package/dist/chunk-HELS7KFF.js +2 -0
  47. package/dist/{chunk-B5NLK2B3.js → chunk-IPDCSB6N.js} +2 -2
  48. package/dist/{chunk-M7MTH5NR.js → chunk-IYAOX36F.js} +2 -2
  49. package/dist/{chunk-YVVCVR2L.js → chunk-J7VT2CRB.js} +2 -2
  50. package/dist/{chunk-4333ETTV.js → chunk-JELJLXEE.js} +2 -2
  51. package/dist/{chunk-LBMJEAEW.js → chunk-JERWGHQT.js} +2 -2
  52. package/dist/chunk-JJJCO4QC.js +945 -0
  53. package/dist/{chunk-6E7UTQY7.js → chunk-JZNLMHWY.js} +2 -2
  54. package/dist/{chunk-R4FQGQ4X.js → chunk-K42M2KWT.js} +2 -2
  55. package/dist/{chunk-H7UKLTWJ.js → chunk-KLVJABXA.js} +2 -2
  56. package/dist/chunk-KP4KBDVF.js +3 -0
  57. package/dist/{chunk-RV2FQIX3.js → chunk-LMFVTUW2.js} +2 -2
  58. package/dist/chunk-LRTP3DKL.js +3 -0
  59. package/dist/{chunk-U6WNH5GC.js → chunk-MGBJHRFB.js} +2 -2
  60. package/dist/{chunk-QDV6RDCP.js → chunk-MLGTCX56.js} +2 -2
  61. package/dist/{chunk-54HA4ZXH.js → chunk-N3SE646F.js} +2 -2
  62. package/dist/{chunk-KP6XRY5Z.js → chunk-NBRUH7OE.js} +2 -2
  63. package/dist/{chunk-M7AIS73L.js → chunk-NN4ZIRPK.js} +2 -2
  64. package/dist/{chunk-I5RJM53C.js → chunk-NQLSSVOB.js} +2 -2
  65. package/dist/{chunk-4SALD7RU.js → chunk-OBKDTVZ3.js} +2 -2
  66. package/dist/{chunk-GBQ5NYPR.js → chunk-OHWZKLVA.js} +6 -6
  67. package/dist/{chunk-6NSFJYRC.js → chunk-OP3MTFJR.js} +2 -2
  68. package/dist/{chunk-EOOJGLDU.js → chunk-OQ2A4G2G.js} +2 -2
  69. package/dist/{chunk-DLWR3NUU.js → chunk-P6HBYNBE.js} +2 -2
  70. package/dist/{chunk-QVWS2VWZ.js → chunk-PC44K7RF.js} +2 -2
  71. package/dist/{chunk-A2EZV2UM.js → chunk-QBYYWGAT.js} +2 -2
  72. package/dist/{chunk-QRGV2F7L.js → chunk-QHKUY4FW.js} +2 -2
  73. package/dist/chunk-QHRL4LKM.js +2 -0
  74. package/dist/{chunk-I5AWSI2G.js → chunk-QQWOFXNW.js} +2 -2
  75. package/dist/{chunk-WQTAC523.js → chunk-RBFFD4V2.js} +2 -2
  76. package/dist/{chunk-SOAT6NLA.js → chunk-RJHCPSZ7.js} +2 -2
  77. package/dist/{chunk-VGRICIQI.js → chunk-RWRLUZ6U.js} +2 -2
  78. package/dist/{chunk-4T3LTWUS.js → chunk-S2GP3CU3.js} +2 -2
  79. package/dist/{chunk-HEXVUYFQ.js → chunk-SHKZ7OVJ.js} +2 -2
  80. package/dist/{chunk-NSS46APD.js → chunk-TFUU5MQQ.js} +2 -2
  81. package/dist/{chunk-IUFDSKGG.js → chunk-TYQ76QHQ.js} +2 -2
  82. package/dist/{chunk-NRCXJDHL.js → chunk-U5CNPPTZ.js} +2 -2
  83. package/dist/{chunk-MITTUCEH.js → chunk-UQK5CRUK.js} +2 -2
  84. package/dist/{chunk-XLTP42QA.js → chunk-UUJBLG6J.js} +2 -2
  85. package/dist/chunk-UXP636P5.js +144 -0
  86. package/dist/{chunk-64RFXJT5.js → chunk-VEVBIAOJ.js} +6 -6
  87. package/dist/chunk-VKRQDBW5.js +9 -0
  88. package/dist/{chunk-C7NIYIQ4.js → chunk-VOQFGC2W.js} +4 -4
  89. package/dist/{chunk-DZ74OMG6.js → chunk-VP542C25.js} +2 -2
  90. package/dist/{chunk-Q3AFUTGB.js → chunk-WMXRRBII.js} +2 -2
  91. package/dist/{chunk-ZGZUZ7XE.js → chunk-WXAAURU7.js} +2 -2
  92. package/dist/chunk-X3NLZHPA.js +20 -0
  93. package/dist/{chunk-WER3B7MI.js → chunk-XF3KLXN3.js} +2 -2
  94. package/dist/{chunk-NH5ALKPW.js → chunk-XVJ3V7LM.js} +2 -2
  95. package/dist/{chunk-4XTA5OMB.js → chunk-YGQN3XGZ.js} +2 -2
  96. package/dist/{chunk-CFMXJPHH.js → chunk-YHXBD52M.js} +2 -2
  97. package/dist/{chunk-7B3UPBVA.js → chunk-YLVE3SXZ.js} +2 -2
  98. package/dist/{chunk-YIJ7ZAA4.js → chunk-YTUD45PU.js} +2 -2
  99. package/dist/{chunk-VTKGCT3V.js → chunk-YWB2EBNB.js} +2 -2
  100. package/dist/{chunk-UKZBVX4U.js → chunk-Z2LHPIOM.js} +2 -2
  101. package/dist/chunk-Z5QQPJ3U.js +30 -0
  102. package/dist/{chunk-NZL2DBT7.js → chunk-ZLJLE6LK.js} +2 -2
  103. package/dist/{chunk-XYADIZHU.js → chunk-ZTTISZ7J.js} +2 -2
  104. package/dist/cli.js +3 -3
  105. package/dist/command-descriptors-SJDZ7QGR.js +617 -0
  106. package/dist/{config-types-D20KuvvZ.d.ts → config-types-BWQ5xPGI.d.ts} +4 -0
  107. package/dist/{db-G_II8yXU.d.ts → db-B0r1o7Vt.d.ts} +18 -1
  108. package/dist/direct-navigation-HTKOZEOM.js +3 -0
  109. package/dist/{health-oblXYgkF.d.ts → health-CFnlCiTz.d.ts} +1 -1
  110. package/dist/index.d.ts +2 -2
  111. package/dist/index.js +1 -1
  112. package/dist/postinstall.js +1 -1
  113. package/dist/queries/affected.d.ts +2 -2
  114. package/dist/queries/affected.js +1 -1
  115. package/dist/queries/architecture.d.ts +2 -2
  116. package/dist/queries/architecture.js +1 -1
  117. package/dist/queries/bottlenecks.d.ts +2 -2
  118. package/dist/queries/bottlenecks.js +1 -1
  119. package/dist/queries/by-kind.d.ts +2 -2
  120. package/dist/queries/by-kind.js +1 -1
  121. package/dist/queries/call-graph.d.ts +2 -2
  122. package/dist/queries/call-graph.js +1 -1
  123. package/dist/queries/change-surface.d.ts +2 -2
  124. package/dist/queries/change-surface.js +1 -1
  125. package/dist/queries/cleanup-plan.d.ts +2 -2
  126. package/dist/queries/cleanup-plan.js +1 -1
  127. package/dist/queries/co-change.d.ts +2 -2
  128. package/dist/queries/co-change.js +1 -1
  129. package/dist/queries/code.d.ts +2 -2
  130. package/dist/queries/code.js +1 -1
  131. package/dist/queries/complexity-hotspots.d.ts +2 -2
  132. package/dist/queries/complexity-hotspots.js +1 -1
  133. package/dist/queries/complexity.d.ts +2 -2
  134. package/dist/queries/complexity.js +1 -1
  135. package/dist/queries/convergence.d.ts +2 -2
  136. package/dist/queries/convergence.js +1 -1
  137. package/dist/queries/coupling.d.ts +2 -2
  138. package/dist/queries/coupling.js +1 -1
  139. package/dist/queries/cycles.d.ts +2 -2
  140. package/dist/queries/cycles.js +1 -1
  141. package/dist/queries/dataflow.d.ts +2 -2
  142. package/dist/queries/dataflow.js +1 -1
  143. package/dist/queries/dead.d.ts +2 -2
  144. package/dist/queries/dead.js +1 -1
  145. package/dist/queries/decorative-checkers.d.ts +3 -3
  146. package/dist/queries/decorative-checkers.js +1 -1
  147. package/dist/queries/deep-chains.d.ts +2 -2
  148. package/dist/queries/deep-chains.js +1 -1
  149. package/dist/queries/deps.d.ts +2 -2
  150. package/dist/queries/deps.js +1 -1
  151. package/dist/queries/diff-gate.d.ts +30 -2
  152. package/dist/queries/diff-gate.js +1 -1
  153. package/dist/queries/diff-impact.d.ts +2 -2
  154. package/dist/queries/diff-impact.js +1 -1
  155. package/dist/queries/doc-drift.d.ts +2 -2
  156. package/dist/queries/doc-drift.js +1 -1
  157. package/dist/queries/drift.d.ts +2 -2
  158. package/dist/queries/drift.js +1 -1
  159. package/dist/queries/duplicate-bodies.d.ts +2 -2
  160. package/dist/queries/duplicate-bodies.js +1 -1
  161. package/dist/queries/extract-candidates.d.ts +2 -2
  162. package/dist/queries/extract-candidates.js +1 -1
  163. package/dist/queries/fan.d.ts +2 -2
  164. package/dist/queries/fan.js +1 -1
  165. package/dist/queries/files.d.ts +2 -2
  166. package/dist/queries/health.d.ts +3 -3
  167. package/dist/queries/health.js +1 -1
  168. package/dist/queries/hierarchy.d.ts +2 -2
  169. package/dist/queries/hierarchy.js +1 -1
  170. package/dist/queries/hotspots.d.ts +2 -2
  171. package/dist/queries/hotspots.js +1 -1
  172. package/dist/queries/imports.d.ts +2 -2
  173. package/dist/queries/imports.js +1 -1
  174. package/dist/queries/incomplete-migration.d.ts +2 -2
  175. package/dist/queries/incomplete-migration.js +1 -1
  176. package/dist/queries/index.d.ts +17 -3
  177. package/dist/queries/index.js +1 -1
  178. package/dist/queries/isolated.d.ts +2 -2
  179. package/dist/queries/isolated.js +1 -1
  180. package/dist/queries/locality-candidates.d.ts +2 -2
  181. package/dist/queries/locality-candidates.js +1 -1
  182. package/dist/queries/members.d.ts +2 -2
  183. package/dist/queries/members.js +1 -1
  184. package/dist/queries/methods.d.ts +2 -2
  185. package/dist/queries/methods.js +1 -1
  186. package/dist/queries/not-implemented.d.ts +3 -3
  187. package/dist/queries/not-implemented.js +1 -1
  188. package/dist/queries/outline.d.ts +2 -2
  189. package/dist/queries/outline.js +1 -1
  190. package/dist/queries/passthrough-candidates.d.ts +2 -2
  191. package/dist/queries/passthrough-candidates.js +1 -1
  192. package/dist/queries/plan-context.d.ts +2 -2
  193. package/dist/queries/plan-context.js +1 -1
  194. package/dist/queries/react-component-duplicates.d.ts +2 -2
  195. package/dist/queries/react-component-duplicates.js +1 -1
  196. package/dist/queries/react-hook-candidates.d.ts +2 -2
  197. package/dist/queries/react-hook-candidates.js +1 -1
  198. package/dist/queries/react-large-component-pressure.d.ts +2 -2
  199. package/dist/queries/react-large-component-pressure.js +1 -1
  200. package/dist/queries/recent-duplicates.d.ts +2 -2
  201. package/dist/queries/recent-duplicates.js +1 -1
  202. package/dist/queries/redundant-reexports.d.ts +2 -2
  203. package/dist/queries/redundant-reexports.js +1 -1
  204. package/dist/queries/refs.d.ts +2 -2
  205. package/dist/queries/refs.js +1 -1
  206. package/dist/queries/self-audit.d.ts +2 -2
  207. package/dist/queries/self-audit.js +1 -1
  208. package/dist/queries/similar-chains.d.ts +2 -2
  209. package/dist/queries/similar-chains.js +1 -1
  210. package/dist/queries/similar-files.d.ts +2 -2
  211. package/dist/queries/similar-files.js +1 -1
  212. package/dist/queries/similar-signatures.d.ts +2 -2
  213. package/dist/queries/similar-signatures.js +1 -1
  214. package/dist/queries/similar.d.ts +2 -2
  215. package/dist/queries/similar.js +1 -1
  216. package/dist/queries/slice.d.ts +2 -2
  217. package/dist/queries/slice.js +1 -1
  218. package/dist/queries/stale-abstractions.d.ts +2 -2
  219. package/dist/queries/stale-abstractions.js +1 -1
  220. package/dist/queries/stats.d.ts +2 -2
  221. package/dist/queries/stats.js +1 -1
  222. package/dist/queries/surface.d.ts +2 -2
  223. package/dist/queries/surface.js +1 -1
  224. package/dist/queries/symbols.d.ts +2 -2
  225. package/dist/queries/symbols.js +1 -1
  226. package/dist/queries/system.d.ts +2 -2
  227. package/dist/queries/system.js +1 -1
  228. package/dist/queries/test-quality.d.ts +2 -2
  229. package/dist/queries/test-quality.js +1 -1
  230. package/dist/queries/trace.d.ts +2 -2
  231. package/dist/queries/trace.js +1 -1
  232. package/dist/queries/twin-ab.d.ts +3 -3
  233. package/dist/queries/twin-ab.js +1 -1
  234. package/dist/queries/twin-drift.d.ts +2 -2
  235. package/dist/queries/twin-drift.js +1 -1
  236. package/dist/queries/unused-imports.d.ts +2 -2
  237. package/dist/queries/unused-imports.js +1 -1
  238. package/dist/queries/unused-params.d.ts +2 -2
  239. package/dist/queries/unused-params.js +1 -1
  240. package/dist/queries/vue-component-duplicates.d.ts +2 -2
  241. package/dist/queries/vue-component-duplicates.js +1 -1
  242. package/dist/queries/vue-composable-candidates.d.ts +2 -2
  243. package/dist/queries/vue-composable-candidates.js +1 -1
  244. package/dist/queries/vue-large-view-pressure.d.ts +2 -2
  245. package/dist/queries/vue-large-view-pressure.js +1 -1
  246. package/dist/queries/wrapper-candidates.d.ts +2 -2
  247. package/dist/queries/wrapper-candidates.js +1 -1
  248. package/dist/reindex-worker.js +23 -24
  249. package/dist/reindex.d.ts +10 -4
  250. package/dist/reindex.js +33 -38
  251. package/dist/runtime.d.ts +167 -11
  252. package/dist/runtime.js +3 -2
  253. package/dist/rust-semantic-session-server.js +1 -1
  254. package/dist/rust-semantic-session-worker.js +1 -1
  255. package/dist/rust-semantic-worker.js +1 -1
  256. package/dist/{scip-cli-kRpaexVJ.d.ts → scip-cli-DCvnlZCu.d.ts} +5 -1
  257. package/dist/watch-server.js +5 -5
  258. package/docs/AGENT_GUIDE.md +1 -1
  259. package/docs/AI_FAILURE_MODES.md +18 -18
  260. package/docs/API_EVOLUTION.md +71 -0
  261. package/docs/CLI_JSON_OUTPUT.md +83 -0
  262. package/docs/COMMAND_REFERENCE.md +10 -8
  263. package/docs/COMMITTED_RECORD_COMPATIBILITY.md +117 -0
  264. package/docs/CONFIGURATION_WRITE_SAFETY.md +130 -0
  265. package/docs/DETECTOR_GUIDE.md +47 -47
  266. package/docs/DURABILITY.md +103 -0
  267. package/docs/INDEX_GENERATIONS.md +121 -0
  268. package/docs/LOCK_PROTOCOL.md +133 -0
  269. package/docs/MAILBOX_LIFECYCLE.md +197 -0
  270. package/docs/REINDEX_METADATA_COMPATIBILITY.md +84 -0
  271. package/docs/RUST_DURABLE_SESSION_PROTOCOL.md +126 -0
  272. package/docs/TELEMETRY_RETENTION.md +72 -0
  273. package/docs/TIME_SEMANTICS.md +77 -0
  274. package/docs/WATCH_REFRESH_REQUESTS.md +110 -0
  275. package/docs/WINDOWS_SIDECAR_RELEASE.md +298 -0
  276. package/docs/analyzer-validation-ledger.md +24 -23
  277. package/docs/schemas/cli-json-envelope.schema.json +53 -0
  278. package/docs/schemas/npm-release-state.schema.json +146 -0
  279. package/docs/schemas/outcome-event-record.schema.json +39 -0
  280. package/docs/schemas/project-config.schema.json +247 -0
  281. package/docs/schemas/suppression-record.schema.json +31 -0
  282. package/docs/schemas/windows-sidecar-provenance.schema.json +137 -0
  283. package/package.json +15 -5
  284. package/scripts/build-scip-windows.mjs +180 -61
  285. package/scripts/scip-windows-provenance.mjs +364 -0
  286. package/scripts/verify-scip-windows.mjs +29 -0
  287. package/skills/_shared/SKILL.md +91 -242
  288. package/skills/_shared/agents/openai.yaml +1 -1
  289. package/skills/_shared/references/agent-contract-catalog.md +105 -0
  290. package/skills/_shared/references/command-catalog.md +118 -0
  291. package/skills/_shared/references/detector-precision-and-diffgate.md +59 -0
  292. package/skills/_shared/references/evidence-and-dead-code.md +25 -0
  293. package/skills/scip-audit/SKILL.md +76 -0
  294. package/skills/scip-audit/agents/openai.yaml +4 -0
  295. package/skills/scip-audit/references/claims.md +98 -0
  296. package/skills/scip-audit/references/cleanup.md +101 -0
  297. package/skills/scip-audit/references/directory.md +222 -0
  298. package/skills/scip-audit/references/frontend.md +130 -0
  299. package/skills/scip-audit/references/integrity.md +154 -0
  300. package/skills/scip-audit/references/maintainability.md +162 -0
  301. package/skills/scip-audit/references/twin-drift.md +104 -0
  302. package/skills/scip-diagnose/SKILL.md +52 -0
  303. package/skills/scip-diagnose/agents/openai.yaml +4 -0
  304. package/skills/scip-diagnose/references/debug.md +117 -0
  305. package/skills/{scip-probe-reachability/SKILL.md → scip-diagnose/references/probe-reachability.md} +12 -27
  306. package/skills/scip-diagnose/references/root-cause.md +145 -0
  307. package/skills/scip-diagnose/references/triage.md +119 -0
  308. package/skills/scip-explore/SKILL.md +53 -84
  309. package/skills/scip-explore/agents/openai.yaml +2 -2
  310. package/skills/scip-explore/references/diagrams.md +40 -0
  311. package/skills/scip-explore/references/language-playbook.md +49 -0
  312. package/skills/scip-improve/SKILL.md +56 -0
  313. package/skills/scip-improve/agents/openai.yaml +4 -0
  314. package/skills/scip-improve/references/cleanup-batches.md +53 -0
  315. package/skills/scip-improve/references/directory-moves.md +53 -0
  316. package/skills/scip-improve/references/doc-reconcile.md +30 -0
  317. package/skills/scip-improve/references/frontend-extraction.md +39 -0
  318. package/skills/scip-improve/references/maintainability-mechanism.md +43 -0
  319. package/skills/scip-improve/references/twin-drift.md +35 -0
  320. package/skills/scip-plan/SKILL.md +68 -0
  321. package/skills/scip-plan/agents/openai.yaml +4 -0
  322. package/skills/scip-plan/references/api-impact.md +19 -0
  323. package/skills/scip-plan/references/conductor.md +41 -0
  324. package/skills/scip-plan/references/high-assurance.md +43 -0
  325. package/skills/scip-plan/references/hyper-optimization.md +50 -0
  326. package/skills/scip-plan/references/tla-model.md +88 -0
  327. package/skills/scip-query/SKILL.md +52 -97
  328. package/skills/scip-query/agents/openai.yaml +2 -2
  329. package/skills/scip-setup/SKILL.md +65 -176
  330. package/skills/scip-setup/agents/openai.yaml +3 -3
  331. package/skills/scip-setup/references/bootstrap-workflow.md +120 -0
  332. package/skills/scip-setup/references/language-verification.md +61 -0
  333. package/skills/scip-setup/references/lifecycle-commands.md +119 -0
  334. package/skills/scip-setup/references/per-repo-triage.md +24 -0
  335. package/skills/scip-verify/SKILL.md +123 -70
  336. package/skills/scip-verify/agents/openai.yaml +2 -2
  337. package/skills/scip-verify/references/calibrate-detectors.md +170 -0
  338. package/dist/chunk-2CTX5CMX.js +0 -4
  339. package/dist/chunk-2Y373BDD.js +0 -2
  340. package/dist/chunk-C2QSK7E7.js +0 -2
  341. package/dist/chunk-D4U5Q3FT.js +0 -7
  342. package/dist/chunk-K2ERX4UT.js +0 -3
  343. package/dist/chunk-KHE7J5ZN.js +0 -3
  344. package/dist/chunk-L7SPDE73.js +0 -84
  345. package/dist/chunk-LHMNRHGV.js +0 -3
  346. package/dist/chunk-LM72NQ7T.js +0 -3
  347. package/dist/chunk-MSWVMDAH.js +0 -122
  348. package/dist/chunk-NH7WNNQC.js +0 -20
  349. package/dist/chunk-OMPZHGHO.js +0 -2
  350. package/dist/chunk-SVLTAG5O.js +0 -927
  351. package/dist/chunk-U7DSEKOM.js +0 -30
  352. package/dist/chunk-V27BEQJN.js +0 -7
  353. package/dist/chunk-VMNZB6WI.js +0 -4
  354. package/dist/chunk-XBN5VO53.js +0 -2
  355. package/dist/chunk-ZAIILQNP.js +0 -5
  356. package/dist/command-descriptors-MFU4BCJ7.js +0 -612
  357. package/dist/direct-navigation-MRMQFIRB.js +0 -3
  358. package/skills/scip-api-impact/SKILL.md +0 -139
  359. package/skills/scip-api-impact/agents/openai.yaml +0 -4
  360. package/skills/scip-calibrate/SKILL.md +0 -131
  361. package/skills/scip-calibrate/agents/openai.yaml +0 -4
  362. package/skills/scip-claim-audit/SKILL.md +0 -106
  363. package/skills/scip-claim-audit/agents/openai.yaml +0 -4
  364. package/skills/scip-cleanup-audit/SKILL.md +0 -126
  365. package/skills/scip-cleanup-audit/agents/openai.yaml +0 -4
  366. package/skills/scip-cleanup-improve/SKILL.md +0 -84
  367. package/skills/scip-cleanup-improve/agents/openai.yaml +0 -4
  368. package/skills/scip-concrete-plan/SKILL.md +0 -262
  369. package/skills/scip-concrete-plan/agents/openai.yaml +0 -4
  370. package/skills/scip-conductor/SKILL.md +0 -133
  371. package/skills/scip-conductor/agents/openai.yaml +0 -4
  372. package/skills/scip-debug/SKILL.md +0 -130
  373. package/skills/scip-debug/agents/openai.yaml +0 -4
  374. package/skills/scip-diagram/SKILL.md +0 -110
  375. package/skills/scip-diagram/agents/openai.yaml +0 -4
  376. package/skills/scip-directory-architecture/SKILL.md +0 -254
  377. package/skills/scip-directory-architecture/agents/openai.yaml +0 -4
  378. package/skills/scip-doc-reconcile/SKILL.md +0 -89
  379. package/skills/scip-doc-reconcile/agents/openai.yaml +0 -4
  380. package/skills/scip-hyper-optimization/SKILL.md +0 -156
  381. package/skills/scip-hyper-optimization/agents/openai.yaml +0 -4
  382. package/skills/scip-integrity-audit/SKILL.md +0 -152
  383. package/skills/scip-integrity-audit/agents/openai.yaml +0 -4
  384. package/skills/scip-language-playbook/SKILL.md +0 -106
  385. package/skills/scip-language-playbook/agents/openai.yaml +0 -4
  386. package/skills/scip-maintainability/SKILL.md +0 -158
  387. package/skills/scip-maintainability/agents/openai.yaml +0 -4
  388. package/skills/scip-probe-reachability/agents/openai.yaml +0 -4
  389. package/skills/scip-react-maintainability/SKILL.md +0 -101
  390. package/skills/scip-react-maintainability/agents/openai.yaml +0 -4
  391. package/skills/scip-root-cause/SKILL.md +0 -150
  392. package/skills/scip-root-cause/agents/openai.yaml +0 -4
  393. package/skills/scip-tla-model-system/SKILL.md +0 -148
  394. package/skills/scip-tla-model-system/agents/openai.yaml +0 -4
  395. package/skills/scip-triage-issue/SKILL.md +0 -126
  396. package/skills/scip-triage-issue/agents/openai.yaml +0 -4
  397. package/skills/scip-twin-drift/SKILL.md +0 -107
  398. package/skills/scip-twin-drift/agents/openai.yaml +0 -4
  399. package/skills/scip-vue-maintainability/SKILL.md +0 -107
  400. package/skills/scip-vue-maintainability/agents/openai.yaml +0 -4
@@ -0,0 +1,71 @@
1
+ # Public TypeScript API evolution
2
+
3
+ The public TypeScript API is the compiler-visible declaration surface
4
+ reachable through `scip-query` package export paths. Its essential property is
5
+ that downstream programs can depend on it without importing this repository's
6
+ internal files.
7
+
8
+ Every built declaration path is recorded in
9
+ `docs/api/scip-query.api.json`. The report includes exported names, declaration
10
+ kinds and signatures, generic and parameter syntax, return types, and the
11
+ shared declaration chunks that carry referenced public types. Generation
12
+ normalizes formatting, comments, named import/export order, path separators,
13
+ and tsup chunk hashes so the review shows semantic declaration changes rather
14
+ than build noise.
15
+
16
+ ## Contributor workflow
17
+
18
+ Build and compare the current declarations:
19
+
20
+ ```bash
21
+ npm run api:check
22
+ ```
23
+
24
+ The check fails closed when a declaration target is absent, the committed
25
+ manifest is malformed, its acceptance record is missing, or any declaration
26
+ changes. Review every reported path and downstream use. Then accept the change
27
+ with one classification:
28
+
29
+ ```bash
30
+ npm run api:update -- \
31
+ --classification additive \
32
+ --reason "Add an optional result field for evidence provenance."
33
+ ```
34
+
35
+ The classifications are:
36
+
37
+ - `additive`: an old consumer remains valid, such as a new export or an
38
+ optional result field;
39
+ - `compatible-correction`: the declaration report changes to correct a
40
+ contract that did not describe usable runtime behavior, with the reasoning
41
+ recorded for review;
42
+ - `breaking`: an old consumer may stop compiling or acquire a different
43
+ meaning.
44
+
45
+ The checker automatically identifies additions and removals. It treats changed
46
+ signatures and referenced shared declarations conservatively. A human may
47
+ classify uncertain drift as a compatible correction or breaking change, but
48
+ cannot accept a known or uncertain change as additive without resolving the
49
+ evidence.
50
+
51
+ `api:update` writes a content-addressed record under
52
+ `docs/api/changes/`. The record binds the old and new manifest digests, package
53
+ version, automatic result, chosen classification, reason, and exact change
54
+ list. Do not edit the generated manifest or an acceptance record by hand.
55
+
56
+ ## Compatibility policy
57
+
58
+ - Keep a deprecated export or adapter for at least one minor release before
59
+ removal when a feasible compatibility path exists.
60
+ - Add optional fields instead of making old consumers construct new required
61
+ state.
62
+ - Treat parameter optionality, union membership, generic constraints, and
63
+ discriminated-union members as contract changes even when runtime tests pass.
64
+ - Preserve the compile fixture in
65
+ `tests/fixtures/public-api-consumer/`. It represents a previously written
66
+ downstream program and must compile against the newly built package.
67
+ - The two-package release coordinator runs lint, whose gate includes
68
+ `api:check`, before packing either artifact or reading registry state. Direct
69
+ `npm publish` is refused by `prepublishOnly`; it is not an alternate API
70
+ compatibility path. A declaration change is not accepted merely because
71
+ its implementation tests pass.
@@ -0,0 +1,83 @@
1
+ # CLI JSON output contract
2
+
3
+ A CLI JSON envelope is the public transport record printed by a scip-query
4
+ command when a caller selects `--json`. Its real-world units are the JSON
5
+ objects read by agents, shell scripts, CI jobs, and other programs. It is a
6
+ versioned message format distinguished by one stable outer shape that names
7
+ its producer, command, and result contract while leaving the command-specific
8
+ payload under `result`.
9
+
10
+ The current envelope is schema version 1:
11
+
12
+ ```json
13
+ {
14
+ "kind": "scip-query-result",
15
+ "schemaVersion": 1,
16
+ "producer": { "name": "scip-query", "version": "0.19.6" },
17
+ "command": "refs",
18
+ "resultSchemaVersion": 1,
19
+ "evidence": "graph-fact",
20
+ "args": ["login"],
21
+ "options": { "json": true, "compact": true },
22
+ "result": {},
23
+ "coverage": {}
24
+ }
25
+ ```
26
+
27
+ `schemaVersion` governs the outer transport record. `resultSchemaVersion`
28
+ governs the payload selected by `command`; it can advance without changing
29
+ the transport version. `producer.version` is the installed package version
30
+ that emitted the record. `kind` prevents a consumer from mistaking another
31
+ JSON protocol for a CLI result.
32
+
33
+ The machine-readable schema is
34
+ [`schemas/cli-json-envelope.schema.json`](schemas/cli-json-envelope.schema.json).
35
+ The public `scip-query/runtime` export provides
36
+ `decodeCliJsonEnvelope()` and `requireCompatibleCliJsonEnvelope()` for
37
+ consumers that want the repository's compatibility policy rather than a
38
+ hand-written field check.
39
+
40
+ ## Compatibility policy
41
+
42
+ The decoder accepts:
43
+
44
+ | Input | Meaning | Consumer action |
45
+ | ------------------------------------------------------------------- | --------------------------------------------- | -------------------------------------------------------------- |
46
+ | Unversioned legacy envelope | The public shape emitted before schema v1 | Read as supported legacy v0; plan migration |
47
+ | `kind: "scip-query-result"`, `schemaVersion: 1` | Current transport contract | Read the named result schema |
48
+ | A supported envelope with an unknown command `resultSchemaVersion` | A command payload this consumer does not know | Reject that payload without changing unrelated command schemas |
49
+ | A higher or otherwise unsupported positive envelope `schemaVersion` | An outer contract this consumer does not know | Reject with producer/version context |
50
+ | Missing required identity or transport fields | A malformed or different message | Reject with the failed boundary |
51
+
52
+ Consumers must ignore unknown fields. Additive fields can therefore ship in a
53
+ minor release. A field removal, type change, meaning change, or previously
54
+ optional field becoming required needs a new relevant schema version.
55
+ Deprecated aliases remain available for a documented compatibility window;
56
+ removing one requires a major contract transition.
57
+
58
+ The committed v0 and v1 fixtures in `tests/fixtures/` prove that the newest
59
+ decoder reads both generations. The v1 fixture also contains an unknown
60
+ additive field so tests prove tolerant reads rather than exact-key coupling.
61
+
62
+ ## Other JSON protocols
63
+
64
+ The hidden `__health-phase` and `__diff-impact-batch` commands are
65
+ same-package child-process messages, not public `--json` responses. They use
66
+ the independently versioned `scip-query-isolated-analysis` protocol and are
67
+ validated for protocol name, schema version, producer, command, and result
68
+ before the parent accepts them.
69
+
70
+ The `hook-context`, `hook-pretool`, and `hook-stop` outputs implement the
71
+ Codex or Claude host's hook schema. Those hosts are the protocol owners, so
72
+ scip-query must not add its CLI envelope fields to their messages. The hook
73
+ event discriminator supplied by the host contract identifies those records.
74
+
75
+ ## Evolution checklist
76
+
77
+ 1. Keep existing fields and meanings when making an additive change.
78
+ 2. Bump `resultSchemaVersion` when one command's payload breaks compatibility.
79
+ 3. Bump `schemaVersion` when the shared outer record breaks compatibility.
80
+ 4. Keep a fixture for the previous supported generation and teach the decoder
81
+ whether to migrate or reject it.
82
+ 5. Update the JSON Schema, this guide, the command reference, and compatibility
83
+ tests in the same change.
@@ -4,6 +4,8 @@
4
4
 
5
5
  This syntax summary is generated from the CLI command descriptors. Keep workflow guidance hand-authored, but keep command syntax, descriptions, and option flags descriptor-owned.
6
6
 
7
+ Commands with `--json` emit the versioned public envelope documented in [CLI JSON output contract](CLI_JSON_OUTPUT.md).
8
+
7
9
  ### Indexing
8
10
 
9
11
  | Command | Description | Options |
@@ -24,11 +26,11 @@ This syntax summary is generated from the CLI command descriptors. Keep workflow
24
26
  |---|---|---|
25
27
  | `files <pattern>` | Find files matching a pattern | `--json` |
26
28
  | `methods <className>` | List methods of a class (with line ranges) | `--json` |
27
- | `refs <symbol>` | Find all files referencing a symbol | `--full`<br>`--json` |
28
- | `trace <symbol>` | Trace a symbol: definition + all references | `--full`<br>`--json` |
29
+ | `refs <symbol>` | Find all files referencing a symbol | `--full`<br>`-n, --limit <n>`<br>`--cursor <cursor>`<br>`--json`<br>`--compact` |
30
+ | `trace <symbol>` | Trace a symbol: definition + all references | `--full`<br>`--compact`<br>`--json` |
29
31
  | `deps <file>` | Files this file depends on (internal) | `--json` |
30
32
  | `rdeps <file>` | Files that depend on this file/module | `--json` |
31
- | `system <module>` | Full module map: files, symbols, deps in/out | `--json` |
33
+ | `system <module>` | Full module map: files, symbols, deps in/out | `--compact`<br>`--json` |
32
34
  | `surface <module>` | What symbols consumers actually use from this module | `--json` |
33
35
  | `imports <file>` | What symbols does this file import? | `--full`<br>`--json` |
34
36
  | `imported-by <symbol>` | Which files import this symbol? | `--json` |
@@ -73,7 +75,7 @@ This syntax summary is generated from the CLI command descriptors. Keep workflow
73
75
  | `redundant-reexports` | Find barrel re-exports that nobody imports through | `-s, --scope <path>`<br>`-n, --limit <n>`<br>`--full`<br>`--json` |
74
76
  | `duplicate-bodies` | Find exact duplicate small-body candidates across files | `-s, --scope <path>`<br>`--max-loc <n>`<br>`--min-loc <n>`<br>`-n, --limit <n>`<br>`--full`<br>`--json` |
75
77
  | `twin-drift` | Twin drift candidates: same-name (or near-name) functions across files with diverged bodies | `-s, --scope <path>`<br>`--min-similarity <n>`<br>`--include-homonyms`<br>`-n, --limit <n>`<br>`--full`<br>`--json` |
76
- | `twin-ab <symbolA> <symbolB>` | Generate a behavioral A/B scaffold comparing two same-concept twins (scip-integrity-audit drill 5) — a ready-to-fill vitest file, not an auto-executor | `--out <path>`<br>`--force`<br>`--json` |
78
+ | `twin-ab <symbolA> <symbolB>` | Generate a behavioral A/B scaffold comparing two same-concept twins (scip-audit integrity scenario) — a ready-to-fill vitest file, not an auto-executor | `--out <path>`<br>`--force`<br>`--json` |
77
79
  | `not-implemented` | Reachable placeholder stub candidates (throw-stub, TODO+return-default, empty body) — production callers can actually reach these; an unreachable stub is dead's job, not this one's | `-s, --scope <path>`<br>`-n, --limit <n>`<br>`--full`<br>`--json` |
78
80
  | `decorative-checkers` | Decorative checker candidates: validate*/verify*/check*/assert*/is*/has* callables with no reachable failure exit anywhere in their body | `-s, --scope <path>`<br>`-n, --limit <n>`<br>`--full`<br>`--json` |
79
81
  | `test-quality` | Test-quality candidates: assertion-free it/test bodies, a skipped-test ledger with git-blame age, and mock-echo tests that assert the same literal they stubbed into a mock | `-s, --scope <path>`<br>`-n, --limit <n>`<br>`--rot-days <n>`<br>`--full`<br>`--json` |
@@ -100,7 +102,7 @@ This syntax summary is generated from the CLI command descriptors. Keep workflow
100
102
  | `affected <symbol>` | Transitive closure of symbols that could break if this symbol changes | `--max-depth <n>`<br>`-s, --scope <path>`<br>`--json` |
101
103
  | `change-surface <file>` | Pre-change briefing: exports, consumers, and blast-radius risk | `--full`<br>`--json` |
102
104
  | `co-change [file]` | Files that change together in git history without a dependency edge — hidden coupling candidates | `--min-together <n>`<br>`-n, --limit <n>`<br>`--all`<br>`--full`<br>`--json` |
103
- | `diff-gate` | Gate the current diff: architecture regressions plus echo, migration, coordination, doc-drift, unused-param, and new-dead candidates; exit 1 on blocking findings | `--base <ref>`<br>`--min-together <n>`<br>`--max-echo-checks <n>`<br>`--max-helpers <n>`<br>`--baseline`<br>`--full`<br>`--skip <check>`<br>`--hook`<br>`--json` |
105
+ | `diff-gate` | Gate the current diff: architecture regressions plus echo, migration, coordination, doc-drift, unused-param, and new-dead candidates; exit 1 on blocking findings | `--base <ref>`<br>`--min-together <n>`<br>`--max-echo-checks <n>`<br>`--max-helpers <n>`<br>`--baseline`<br>`--full`<br>`--skip <check>`<br>`--hook`<br>`--json`<br>`--compact` |
104
106
  | `incomplete-migration` | Partially-completed extraction candidates: new helpers in the diff wired into some sites while similar un-migrated sites remain | `--base <ref>`<br>`--min-containment <n>`<br>`--max-helpers <n>`<br>`-n, --limit <n>`<br>`--full`<br>`--json` |
105
107
  | `diff-impact` | Compute changed symbols and downstream consumers from current git diff | `--base <ref>`<br>`--json` |
106
108
 
@@ -114,7 +116,7 @@ This syntax summary is generated from the CLI command descriptors. Keep workflow
114
116
 
115
117
  | Command | Description | Options |
116
118
  |---|---|---|
117
- | `plan-context <target>` | Pre-edit planning context for a symbol, file, or module | `--impact-depth <n>`<br>`--slice-depth <n>`<br>`-s, --scope <path>`<br>`-n, --limit <n>`<br>`--full`<br>`--json` |
119
+ | `plan-context <target>` | Pre-edit planning context for a symbol, file, or module | `--impact-depth <n>`<br>`--slice-depth <n>`<br>`-s, --scope <path>`<br>`-n, --limit <n>`<br>`--full`<br>`--json`<br>`--compact` |
118
120
 
119
121
  ### Health
120
122
 
@@ -130,14 +132,14 @@ This syntax summary is generated from the CLI command descriptors. Keep workflow
130
132
  |---|---|---|
131
133
  | `bench` | Benchmark indexing and command runtimes for this repository | `--json`<br>`--cold-index`<br>`--include-heavy`<br>`--command <cmd>`<br>`--timeout-ms <n>`<br>`--progress`<br>`--profile`<br>`--profile-out <path>` |
132
134
  | `work-audit <profile>` | Rank exact repeated computations in a profiling JSONL file by measured avoidable time | `--top <n>`<br>`--json` |
133
- | `install-skills` | Install skills (_shared, scip-query, scip-setup, scip-calibrate, scip-cleanup-audit, scip-cleanup-improve, scip-integrity-audit, scip-twin-drift, scip-claim-audit, scip-probe-reachability, scip-hyper-optimization, scip-api-impact, scip-concrete-plan, scip-conductor, scip-debug, scip-explore, scip-root-cause, scip-triage-issue, scip-diagram, scip-doc-reconcile, scip-directory-architecture, scip-maintainability, scip-react-maintainability, scip-vue-maintainability, scip-verify, scip-language-playbook, scip-tla-model-system) into Claude Code, Codex, and shared agent roots | - |
135
+ | `install-skills` | Install skills (_shared, scip-query, scip-setup, scip-explore, scip-plan, scip-diagnose, scip-audit, scip-improve, scip-verify) into Claude Code, Codex, and shared agent roots | - |
134
136
  | `setup-hooks` | Install or refresh project-local Codex and Claude Code lifecycle hooks | `--shared`<br>`--remove`<br>`--force`<br>`--json` |
135
137
  | `check-deps` | Check whether scip-query and the detected language indexers are actually runnable | - |
136
138
  | `capabilities` | Report which evidence and verification capabilities are available in this project | `--matrix`<br>`--json` |
137
139
  | `capability-matrix` | Deprecated alias for capabilities --matrix | `--json` |
138
140
  | `init` | Create a .scipquery.json config file for this project | - |
139
141
  | `config-validate` | Validate .scipquery.json, including structured suppressions and declared coupling groups | `--json` |
140
- | `suppress <id>` | Record an accepted finding as a file under .scipquery/suppressions/ with a required reason | `--reason <text>`<br>`--check <check>`<br>`--file <path>`<br>`--expires-at <iso>`<br>`--json` |
142
+ | `suppress <id>` | Record an accepted finding as a file under .scipquery/suppressions/ with a required reason | `--reason <text>`<br>`--check <check>`<br>`--file <path>`<br>`--expires-at <iso>`<br>`--replace <revision>`<br>`--json` |
141
143
  | `effectiveness` | Per-check effectiveness from the committed outcome ledger: caught, comparison-verified fixes, suppressed, unverified disappearances, and precision | `--since <window>`<br>`--check <check>`<br>`--json` |
142
144
  | `doctor` | Diagnose config, index freshness, dependency readiness, and project capabilities | `--json` |
143
145
  | `setup` | Bootstrap this project: enable automatic indexing, install agent skills, refresh the index, verify capabilities, and report health | `--guided`<br>`--yes`<br>`--git-hook`<br>`--no-hooks`<br>`--no-skills`<br>`--no-parsers`<br>`--no-health`<br>`--dossier-dir <path>`<br>`--json` |
@@ -0,0 +1,117 @@
1
+ # Committed record compatibility
2
+
3
+ scip-query stores two kinds of team-shared records in Git:
4
+
5
+ - `.scipquery/suppressions/*.json` contains accepted detector-policy
6
+ decisions.
7
+ - `.scipquery/events/*.json` contains immutable finding-transition
8
+ observations used by `effectiveness` and cross-HEAD repair verification.
9
+
10
+ A committed record is a repository-owned JSON fact or policy whose value
11
+ comes from surviving clones and branches. Unlike a local cache row, it cannot
12
+ be silently dropped and rebuilt when a reader does not understand it.
13
+
14
+ ## Compatibility states
15
+
16
+ Every JSON candidate is classified exactly once:
17
+
18
+ | State | Meaning | Included in conclusions? |
19
+ | -------------------- | ----------------------------------------------------------------- | ------------------------ |
20
+ | `legacy` | A supported unversioned record from an earlier scip-query release | Yes |
21
+ | `current` | A record matching the current discriminator and schema | Yes |
22
+ | `unsupported-older` | A versioned record older than the supported overlap window | No |
23
+ | `unsupported-future` | A record written by a newer incompatible schema | No |
24
+ | `malformed` | Invalid JSON, fields, discriminator, metadata, or stable identity | No |
25
+
26
+ `complete` is true only when every candidate is `legacy` or `current`.
27
+ Readers return accepted records together with `total`, `accepted`, `omitted`,
28
+ the per-state counts, and path-specific issues. A subset may still support a
29
+ conservative result, but it must not be represented as complete.
30
+
31
+ ## Current suppression records
32
+
33
+ New records conform to
34
+ [`schemas/suppression-record.schema.json`](schemas/suppression-record.schema.json).
35
+ They carry:
36
+
37
+ - `kind: "scip-query-suppression"`;
38
+ - `schemaVersion: 1`;
39
+ - the stable `suppressionIdentity`;
40
+ - producer name/version and creation/update timestamps;
41
+ - the existing suppression target and reason fields.
42
+
43
+ The discriminator is additive within suppression v1. Older v1 readers permit
44
+ unknown properties, so they continue to read newly written records. Current
45
+ readers also accept v1 records written before the discriminator was added and
46
+ unversioned legacy records. The filename remains the conflict domain:
47
+ different suppression identities merge as different paths, while policy
48
+ changes to one identity require revision-aware replacement.
49
+
50
+ If a future or malformed suppression is omitted, it cannot waive a finding.
51
+ `diff-gate` keeps the matching finding unsuppressed and reports incomplete
52
+ suppression coverage in JSON, human output, and Stop-hook feedback.
53
+
54
+ ## Current outcome-event records
55
+
56
+ New records conform to
57
+ [`schemas/outcome-event-record.schema.json`](schemas/outcome-event-record.schema.json).
58
+ They retain all semantic event fields at the root and add:
59
+
60
+ - `kind: "scip-query-outcome-event"`;
61
+ - `schemaVersion: 1`;
62
+ - `eventIdentity`, the JSON tuple of check, finding ID, transition, and
63
+ observed commit;
64
+ - producer name/version.
65
+
66
+ Keeping semantic fields at the root lets the immediately prior permissive
67
+ reader consume new records. Current readers accept both these v1 records and
68
+ the existing unversioned event files.
69
+
70
+ The immutable filename is still a timestamp plus a hash of the complete
71
+ record bytes. Deduplication does not use that path or producer metadata; it
72
+ uses the semantic `eventIdentity`. If legacy and current records describe the
73
+ same fact, stronger comparison evidence wins and then the earliest timestamp
74
+ wins, as before.
75
+
76
+ ## Partial history is conservative
77
+
78
+ `effectiveness --json` includes
79
+ `recordCompatibility.outcomeEvents`. Human output prints the same incomplete
80
+ coverage counts before any metrics. Metrics use only accepted records and are
81
+ therefore explicitly partial when `complete` is false.
82
+
83
+ Cross-HEAD repair verification needs complete committed history to establish
84
+ the prior lifecycle anchor. If any event candidate is incompatible, scip-query
85
+ retains every missing local-ledger finding and defers resolution. An omitted
86
+ record can therefore delay a verified fix, but it cannot manufacture one.
87
+
88
+ ## Legacy JSONL migration
89
+
90
+ `.scipquery/ledger/events.jsonl` remains readable during the overlap window.
91
+ On the next event append:
92
+
93
+ 1. every non-empty line is classified;
94
+ 2. compatible lines are copied to independent current event files;
95
+ 3. new observations are appended normally;
96
+ 4. the legacy ledger and its `merge=union` attribute are removed only if
97
+ every line was compatible.
98
+
99
+ If even one line is unsupported or malformed, the original ledger stays
100
+ byte-for-byte present and the append reports a warning. Repeating the append
101
+ is safe: exclusive content-addressed event creation makes already-copied rows
102
+ idempotent. Upgrade scip-query or repair the named malformed line before
103
+ removing the legacy ledger.
104
+
105
+ ## Merge and rollback rules
106
+
107
+ - Commit suppression and event files with the code or documentation change
108
+ that produced them.
109
+ - Do not rewrite all legacy files just to make compatibility counters
110
+ “current.” Read overlap is the migration mechanism.
111
+ - Resolve a same-suppression-path conflict by reviewing both policy decisions;
112
+ never choose a side mechanically.
113
+ - Independent event files should normally keep both sides of a merge.
114
+ - Do not delete an unsupported record to make a warning disappear. Use a
115
+ reader that supports it, or deliberately migrate it with verified tooling.
116
+ - Rolling back to the immediately prior release remains safe because new
117
+ metadata is additive and prior readers ignore unknown fields.
@@ -0,0 +1,130 @@
1
+ # Configuration and setup write safety
2
+
3
+ scip-query updates files that people and other agents may edit at the same
4
+ time: `.scipquery.json`, provider hook JSON, `.git/info/exclude`,
5
+ `AGENTS.md`, `CLAUDE.md`, structured suppression records, and an owned
6
+ pre-commit hook. A conflict-aware writer is a file updater that transforms one
7
+ identified revision and refuses to claim success if an independent revision
8
+ wins before commit. Its defining behavior is preservation: it either applies
9
+ its narrow change to the newest valid input or leaves the newest input
10
+ untouched and reports why.
11
+
12
+ ## Revision and commit protocol
13
+
14
+ Every participating writer:
15
+
16
+ 1. acquires a short, token-owned process lock beside the target;
17
+ 2. reads a stable snapshot and records its SHA-256 hash plus file identity;
18
+ 3. computes only the domain change it owns;
19
+ 4. rereads the target immediately before commit;
20
+ 5. retries the merge when the revision changed and retry is safe, or reports a
21
+ conflict when it is not;
22
+ 6. stages and flushes complete bytes, atomically publishes them, and flushes
23
+ the parent directory where the platform exposes that operation.
24
+
25
+ The lock serializes scip-query processes. Editors do not need to participate:
26
+ their byte or identity change is detected by the optimistic revision check.
27
+ The lock record is token-owned and carries process identity, so a live owner
28
+ cannot be displaced and a dead owner can be reclaimed by the shared process
29
+ lock protocol.
30
+
31
+ First creation uses a flushed staging inode plus an exclusive public hard
32
+ link. This is stronger than `exists` followed by replacement: only one creator
33
+ can publish, and a reader sees no public file until every byte is present.
34
+
35
+ ## JSON merge rules
36
+
37
+ Project setup rereads the latest valid object and changes only the requested
38
+ field. Unknown current and future fields survive. A three-way check compares
39
+ the caller's observed value, the latest value, and the requested value:
40
+
41
+ - an unrelated latest edit is preserved and the owned field is updated;
42
+ - the requested value already present is idempotent;
43
+ - a different latest value for the same field is an explicit stale-field
44
+ conflict.
45
+
46
+ Hook setup rereads the latest valid provider object on every bounded retry,
47
+ removes only scip-query-owned hook entries, and merges the current owned hook
48
+ groups. Unknown top-level fields and non-scip hook entries survive installation
49
+ and removal.
50
+
51
+ Malformed latest JSON is never repaired by replacement because doing so could
52
+ erase information the writer cannot classify. The command reports the parse
53
+ failure and leaves the exact bytes in place.
54
+
55
+ ### Project-config format boundary
56
+
57
+ The project configuration is a durable policy record whose `schemaVersion`
58
+ determines the meaning of its other fields. Current writers publish version 2
59
+ and include a `$schema` URI reference to
60
+ `docs/schemas/project-config.schema.json` in the installed package.
61
+ Unversioned files and explicit `schemaVersion: 1` files have the same readable
62
+ legacy meaning. They are migrated in memory and written as version 2 only when
63
+ `init` creates a file or a setup action enters an authorized mutation path.
64
+
65
+ The schema migration is part of the no-op decision. If the requested field is
66
+ already correct but the durable record is legacy or lacks its editor-schema
67
+ hint, the writer still publishes a current record and reports `changed: true`.
68
+ Unknown root and nested fields survive because migration begins from the
69
+ latest complete object and removes only the owned legacy discriminator.
70
+
71
+ A non-integer discriminator, non-object top level, invalid `$schema` hint, or
72
+ unsupported older/future version fails before options are exposed to runtime
73
+ consumers. The loader names the supported legacy/current versions. A setup
74
+ writer applies the same decoder to its latest stable snapshot and leaves
75
+ rejected bytes byte-for-byte unchanged, so upgrading the CLI—not a blind
76
+ rewrite—is the recovery path for a future version.
77
+
78
+ ## Suppression policy rules
79
+
80
+ A suppression identity is the stable finding ID, or the deterministic hash of
81
+ a check-and-file target when no finding ID exists. It is a policy conflict
82
+ domain: decisions for different identities occupy different files, while two
83
+ decisions for the same identity must be reconciled.
84
+
85
+ The first decision uses exclusive durable creation. An identical replay
86
+ returns the existing revision without rewriting metadata. A different reason,
87
+ expiry, check, or file requires `--replace <revision>`, where the revision is
88
+ the full SHA-256 hash reported when the existing decision was rejected or
89
+ created. Replacement succeeds only if those exact reviewed bytes still occupy
90
+ the path. A stale token, a malformed record, an unsupported future schema, or
91
+ an edit at the commit boundary leaves the latest bytes untouched.
92
+
93
+ New records use suppression schema version 1 and include the
94
+ `scip-query-suppression` discriminator, their stable identity, and the
95
+ `scip-query` writer version. Unversioned legacy records and v1 records written
96
+ before the discriminator was added remain readable. They remain byte-for-byte
97
+ unchanged on an idempotent replay and are upgraded only by an explicit
98
+ compare-and-replace policy change. Incompatible files are counted and reported
99
+ by `diff-gate`; they never authorize a suppression. See
100
+ [`COMMITTED_RECORD_COMPATIBILITY.md`](COMMITTED_RECORD_COMPATIBILITY.md).
101
+
102
+ ## Managed text rules
103
+
104
+ Agent guidance changes only the text between the exact
105
+ `scip-query:agent-setup` markers. Text before and after the block is preserved.
106
+ Missing markers permit first installation, but incomplete, duplicated, or
107
+ reordered markers are a conflict because the intended ownership boundary is
108
+ ambiguous.
109
+
110
+ Managed Markdown and owned pre-commit operations use a strict final revision
111
+ check rather than silently recomputing across an intervening edit. The command
112
+ reports the expected and latest revision hashes and does not write.
113
+ `.git/info/exclude` can safely retry because its exact owned marker block is
114
+ recomputed from the newest text.
115
+
116
+ ## Recovery
117
+
118
+ When a command reports a conflict:
119
+
120
+ 1. open the named file and preserve the latest independent edit;
121
+ 2. repair malformed JSON or marker structure deliberately, if reported;
122
+ 3. for a suppression policy change, review the latest decision and rerun
123
+ `suppress` with the reported `--replace <revision>`;
124
+ 4. for setup/configuration, rerun the command so it reads the new revision.
125
+
126
+ Do not delete a live `.scip-query-write.lock`. If its owner crashed, the next
127
+ writer reclaims it only after the shared lock protocol proves the recorded
128
+ process identity is no longer live. A crash before publication leaves the
129
+ previous target intact; a failed first publication leaves no partial public
130
+ file.
@@ -13,20 +13,20 @@ maps these to the agent behaviors that create the problems.)
13
13
  Same disease — structure built for a future that never came — detected at
14
14
  four different altitudes:
15
15
 
16
- | Command | Altitude | What it measures | The fix |
17
- |---|---|---|---|
18
- | `unused-params` | **parameter** | Trailing parameters no body ever uses. TS/JS only, trailing-run only — removals that are type-safe by construction. `_`-prefixed and externally-published signatures are exempt. | Delete the parameters and their call-site arguments. |
19
- | `passthrough-candidates` | **function (fan-out view)** | Functions with exactly **one callee** and a small body — they just forward arguments to the real implementation. | Inline it: call the target directly. |
20
- | `wrapper-candidates` | **function (fan-in view)** | Symbols with exactly **one caller** — indirection that provides no reuse. Strongest when the sole caller is itself widely used. | Fold the body into the caller. |
21
- | `stale-abstractions` | **type** | Classes, interfaces, and type aliases with 0–1 *real* cross-file consumers (barrel re-exports don't count as consumers). Single-implementation interfaces, misplaced types. | De-abstract: replace the interface with the concrete thing, or move the type to its one consumer. |
16
+ | Command | Altitude | What it measures | The fix |
17
+ | ------------------------ | --------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------- |
18
+ | `unused-params` | **parameter** | Trailing parameters no body ever uses. TS/JS only, trailing-run only — removals that are type-safe by construction. `_`-prefixed and externally-published signatures are exempt. | Delete the parameters and their call-site arguments. |
19
+ | `passthrough-candidates` | **function (fan-out view)** | Functions with exactly **one callee** and a small body — they just forward arguments to the real implementation. | Inline it: call the target directly. |
20
+ | `wrapper-candidates` | **function (fan-in view)** | Symbols with exactly **one caller** — indirection that provides no reuse. Strongest when the sole caller is itself widely used. | Fold the body into the caller. |
21
+ | `stale-abstractions` | **type** | Classes, interfaces, and type aliases with 0–1 _real_ cross-file consumers (barrel re-exports don't count as consumers). Single-implementation interfaces, misplaced types. | De-abstract: replace the interface with the concrete thing, or move the type to its one consumer. |
22
22
 
23
23
  How to keep them straight:
24
24
 
25
25
  - `passthrough` looks **down** (what does this function call? one thing) —
26
26
  `wrapper` looks **up** (who calls this function? one caller). A function can
27
27
  be both: a one-line forwarder with a single caller is the purest bloat.
28
- - `unused-params` is *inside* a signature; the other three are *about whole
29
- symbols*.
28
+ - `unused-params` is _inside_ a signature; the other three are _about whole
29
+ symbols_.
30
30
  - `stale-abstractions` is the only one about **types**, not behavior. Note its
31
31
  confidence ranking: a single-consumer `class` is usually deliberate
32
32
  encapsulation (low), a single-consumer `interface` is worth questioning
@@ -35,17 +35,17 @@ How to keep them straight:
35
35
  ## Cluster 2 — "This already exists" (the similarity family)
36
36
 
37
37
  All of these find duplication, but at different granularities and with
38
- different evidence — and two of them add *direction*:
39
-
40
- | Command | Granularity | Evidence | Question it answers |
41
- |---|---|---|---|
42
- | `similar <symbol>` | function | callee-fingerprint cosine (TF-IDF), source-token fallback | "What else does roughly what this function does?" |
43
- | `similar-signatures` | function | normalized parameter + return types | "What has the same *shape*, regardless of body?" |
44
- | `similar-files` | file | Jaccard on import/dependency profiles | "Which files are copy-paste variants of each other?" |
45
- | `similar-chains` | pipeline | edit distance on infrastructure-filtered dependency chains | "Which end-to-end flows are parallel re-implementations?" |
46
- | `recent-duplicates` | callable/frontend unit + **git age** | callable, React, and Vue similarity + file-add history | "Which side is the established original, which is the fresh echo?" (ECHO = new copies old; TWIN = both new) |
47
- | `incomplete-migration` | function + **git diff** | callee *containment* vs new-in-diff helpers | "I just extracted a helper — which call sites still have the logic inline and were never migrated?" |
48
- | `convergence <a> <b>` | a known pair | shared/unique callees | "I already know these two overlap — give me the merge prescription." |
38
+ different evidence — and two of them add _direction_:
39
+
40
+ | Command | Granularity | Evidence | Question it answers |
41
+ | ---------------------- | ------------------------------------ | ---------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------- |
42
+ | `similar <symbol>` | function | callee-fingerprint cosine (TF-IDF), source-token fallback | "What else does roughly what this function does?" |
43
+ | `similar-signatures` | function | normalized parameter + return types | "What has the same _shape_, regardless of body?" |
44
+ | `similar-files` | file | Jaccard on import/dependency profiles | "Which files are copy-paste variants of each other?" |
45
+ | `similar-chains` | pipeline | edit distance on infrastructure-filtered dependency chains | "Which end-to-end flows are parallel re-implementations?" |
46
+ | `recent-duplicates` | callable/frontend unit + **git age** | callable, React, and Vue similarity + file-add history | "Which side is the established original, which is the fresh echo?" (ECHO = new copies old; TWIN = both new) |
47
+ | `incomplete-migration` | function + **git diff** | callee _containment_ vs new-in-diff helpers | "I just extracted a helper — which call sites still have the logic inline and were never migrated?" |
48
+ | `convergence <a> <b>` | a known pair | shared/unique callees | "I already know these two overlap — give me the merge prescription." |
49
49
 
50
50
  How to keep them straight:
51
51
 
@@ -56,13 +56,13 @@ How to keep them straight:
56
56
  which copy to delete. Run it after agent sessions. It covers generic callables,
57
57
  React component structure, React hook behavior, Vue template structure, and
58
58
  Vue composable-like behavior.
59
- - `incomplete-migration` is the **inverse of an echo**: the *new* code is the
60
- canonical one (the helper you just extracted), and the *established* code is
59
+ - `incomplete-migration` is the **inverse of an echo**: the _new_ code is the
60
+ canonical one (the helper you just extracted), and the _established_ code is
61
61
  what should disappear. It also scores by containment, not symmetric
62
- similarity, because an un-migrated site holds the helper's logic *plus* its
62
+ similarity, because an un-migrated site holds the helper's logic _plus_ its
63
63
  own — cosine under-scores exactly those.
64
64
  - `extract-candidates` is the **before** picture: seams inside one big
65
- function that *should* become a helper. `incomplete-migration` is the
65
+ function that _should_ become a helper. `incomplete-migration` is the
66
66
  **after** picture: you made the helper but didn't finish moving everyone
67
67
  onto it.
68
68
 
@@ -71,11 +71,11 @@ How to keep them straight:
71
71
  Three detectors share the word "drift" or the concept; they watch different
72
72
  gaps:
73
73
 
74
- | Command | Watches the gap between | Evidence |
75
- |---|---|---|
76
- | `drift` | a file and its **siblings/declared architecture** | reference graph: unused imports, project-owned forbidden boundary edges, "no sibling imports this" deviations |
77
- | `doc-drift` | **docs** and the code they describe | doc file-citations + doc↔code co-change history; flags broken references and staleness scores |
78
- | `co-change` | two **files** with an invisible contract | git history: pairs that change together with no dependency edge |
74
+ | Command | Watches the gap between | Evidence |
75
+ | ----------- | ------------------------------------------------- | ------------------------------------------------------------------------------------------------------------- |
76
+ | `drift` | a file and its **siblings/declared architecture** | reference graph: unused imports, project-owned forbidden boundary edges, "no sibling imports this" deviations |
77
+ | `doc-drift` | **docs** and the code they describe | doc file-citations + doc↔code co-change history; flags broken references and staleness scores |
78
+ | `co-change` | two **files** with an invisible contract | git history: pairs that change together with no dependency edge |
79
79
 
80
80
  How to keep them straight: `drift` is structural and intra-code, `doc-drift`
81
81
  is prose-vs-code, `co-change` is code-vs-code where the connection exists only
@@ -92,7 +92,7 @@ coverage, reciprocity, and connected-group signals.
92
92
  | `co-change-partner` | Historically coupled files that usually change together but are missing from this diff. | Default diff gate. |
93
93
  | `twin-partner` | A changed symbol has a same-(near-)name twin (identical or already-divergent) elsewhere that this diff left untouched. | Default diff gate. Advisory: findings print but never cause a nonzero exit by themselves. |
94
94
  | `coverage-contract` | A configured `coverageContracts` entry (.scipquery.json) drifted: its declared key set no longer matches its ground-truth source. | Default diff gate, only when either side of a configured contract changed. |
95
- | `architecture` | A declared architecture boundary rule has a violation absent from the committed health baseline. | Default diff gate when closed dependency rows, requireCompletePolicy, requireAcyclic, requireResolvedBoundaries, requireMinimalPolicy, maxBoundaryFanOut, global maxBoundaryFiles, per-boundary maxFiles, or testPaths are configured and a baseline exists. |
95
+ | `architecture` | A declared architecture boundary rule has a violation absent from the committed health baseline. | Default diff gate when closed dependency rows, requireCompletePolicy, requireAcyclic, requireResolvedBoundaries, requireMinimalPolicy, maxBoundaryFanOut/maxBoundaryFiles, or testPaths are configured and a baseline exists. |
96
96
  | `doc-reference` | Docs that cite changed files and may need a matching update. Dated snapshot docs (docs.snapshotPaths) are excluded by policy. | Default diff gate. Advisory (21.2) for bare file-mention citations; blocking when the citation has a line anchor or the cited file was deleted/renamed. |
97
97
  | `unused-params` | Fresh trailing parameters or options that no changed body uses. | Default diff gate. |
98
98
  | `new-dead` | Changed production symbols with zero indexed consumers. | Default diff gate. |
@@ -103,11 +103,11 @@ Baseline identities use `detector:file:shortName`. File or symbol renames can le
103
103
 
104
104
  ## Cluster 4 — "Nothing uses this" (the deadness family)
105
105
 
106
- | Command | Scope | Question |
107
- |---|---|---|
108
- | `dead` | symbols | "What has zero consumers?" (evidence-ranked, entrypoint-aware) |
109
- | `isolated` | callables | "What is fully disconnected — no callers *and* no callees?" |
110
- | `cleanup-plan` | the cascade | "If I delete the dead stuff, what *becomes* dead next — and will my compiler vouch for the whole batch?" (`--verify`) |
106
+ | Command | Scope | Question |
107
+ | -------------- | ----------- | --------------------------------------------------------------------------------------------------------------------- |
108
+ | `dead` | symbols | "What has zero consumers?" (evidence-ranked, entrypoint-aware) |
109
+ | `isolated` | callables | "What is fully disconnected — no callers _and_ no callees?" |
110
+ | `cleanup-plan` | the cascade | "If I delete the dead stuff, what _becomes_ dead next — and will my compiler vouch for the whole batch?" (`--verify`) |
111
111
 
112
112
  `dead` finds candidates; `isolated` finds the most extreme subset;
113
113
  `cleanup-plan --verify` turns candidates into a compiler-proven deletion plan.
@@ -118,21 +118,21 @@ Don't hand-delete from `dead` output when `cleanup-plan` can prove it.
118
118
  ## After-the-change check matrix
119
119
 
120
120
  The reflex to build (and the one the `scip-query` router skill teaches
121
- agents): match the check to what the change *did*. `diff-gate` runs the
121
+ agents): match the check to what the change _did_. `diff-gate` runs the
122
122
  broad sweep on every diff; these are the targeted follow-ups.
123
123
 
124
- | You just... | Run |
125
- |---|---|
126
- | Extracted a helper / created an abstraction | `scip-query incomplete-migration` — did every site migrate? |
127
- | Wrote a brand-new helper or module | `scip-query similar <it>` and `scip-query recent-duplicates` — did it already exist? |
128
- | Added parameters, options, or config flags | `scip-query unused-params` — does anything use them yet? |
129
- | Added a forwarding/wrapper layer | `scip-query wrapper-candidates` and `scip-query passthrough-candidates` — does it earn its indirection? |
130
- | Added an interface, base class, or type alias | `scip-query stale-abstractions` — does it have more than one real consumer? |
131
- | Changed a schema, contract, config, or generated file | `scip-query co-change <file>` — who historically moves with it? |
132
- | Changed code that docs describe | `scip-query doc-drift` — which docs now lie? |
133
- | Deleted code | `scip-query cleanup-plan --verify` — what else just became dead, and does the compiler agree? |
134
- | Anything at all, before saying "done" | `scip-query reindex && scip-query diff-gate` |
124
+ | You just... | Run |
125
+ | ----------------------------------------------------- | ------------------------------------------------------------------------------------------------------- |
126
+ | Extracted a helper / created an abstraction | `scip-query incomplete-migration` — did every site migrate? |
127
+ | Wrote a brand-new helper or module | `scip-query similar <it>` and `scip-query recent-duplicates` — did it already exist? |
128
+ | Added parameters, options, or config flags | `scip-query unused-params` — does anything use them yet? |
129
+ | Added a forwarding/wrapper layer | `scip-query wrapper-candidates` and `scip-query passthrough-candidates` — does it earn its indirection? |
130
+ | Added an interface, base class, or type alias | `scip-query stale-abstractions` — does it have more than one real consumer? |
131
+ | Changed a schema, contract, config, or generated file | `scip-query co-change <file>` — who historically moves with it? |
132
+ | Changed code that docs describe | `scip-query doc-drift` — which docs now lie? |
133
+ | Deleted code | `scip-query cleanup-plan --verify` — what else just became dead, and does the compiler agree? |
134
+ | Anything at all, before saying "done" | `scip-query reindex && scip-query diff-gate` |
135
135
 
136
136
  And before any non-trivial change: plan with `scip-query plan-context
137
- <target>` (or the `scip-concrete-plan` skill, which requires a scip-query citation
137
+ <target>` (or the `scip-plan` skill, which requires a scip-query citation
138
138
  for every claim in the plan).