@zxyycom/vibe-check 0.0.2 → 0.0.3

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 (670) hide show
  1. package/README.md +36 -5
  2. package/dist/esm/check/check.mjs +4 -0
  3. package/dist/esm/check/check.mjs.map +1 -1
  4. package/dist/esm/check/flag-enablement.mjs +32 -0
  5. package/dist/esm/check/flag-enablement.mjs.map +1 -0
  6. package/dist/esm/check/handoff-provider-identity.mjs +18 -0
  7. package/dist/esm/check/handoff-provider-identity.mjs.map +1 -0
  8. package/dist/esm/check/inherited-collection.mjs +1 -1
  9. package/dist/esm/check/inherited-collection.mjs.map +1 -1
  10. package/dist/esm/check/project-changes.mjs +2 -0
  11. package/dist/esm/check/project-changes.mjs.map +1 -0
  12. package/dist/esm/check/project-context.mjs +2 -0
  13. package/dist/esm/check/project-context.mjs.map +1 -0
  14. package/dist/esm/check-settlement/facts.mjs.map +1 -1
  15. package/dist/esm/check-settlement/record-store.mjs +1 -1
  16. package/dist/esm/check-settlement/record-store.mjs.map +1 -1
  17. package/dist/esm/data-boundary/canonical-data.mjs +36 -7
  18. package/dist/esm/data-boundary/canonical-data.mjs.map +1 -1
  19. package/dist/esm/data-boundary/canonical-json.mjs.map +1 -1
  20. package/dist/esm/data-boundary/closed-values.mjs +28 -4
  21. package/dist/esm/data-boundary/closed-values.mjs.map +1 -1
  22. package/dist/esm/{package-checks/project-files → data-boundary}/config-glob.mjs +3 -3
  23. package/dist/esm/data-boundary/config-glob.mjs.map +1 -0
  24. package/dist/esm/data-boundary/project-path.mjs +19 -0
  25. package/dist/esm/data-boundary/project-path.mjs.map +1 -0
  26. package/dist/esm/index.mjs +12 -5
  27. package/dist/esm/index.mjs.map +1 -1
  28. package/dist/esm/machine-output/v4/atomic-publication.mjs +4 -1
  29. package/dist/esm/machine-output/v4/atomic-publication.mjs.map +1 -1
  30. package/dist/esm/package-checks/check-authoring.mjs +69 -0
  31. package/dist/esm/package-checks/check-authoring.mjs.map +1 -0
  32. package/dist/esm/package-checks/code-quality-findings/finding-waiver-authoring.mjs.map +1 -1
  33. package/dist/esm/package-checks/code-quality-findings/finding-waiver-evidence.mjs.map +1 -1
  34. package/dist/esm/package-checks/command-check/command-check.mjs +55 -0
  35. package/dist/esm/package-checks/command-check/command-check.mjs.map +1 -0
  36. package/dist/esm/package-checks/command-check/contract.mjs +2 -0
  37. package/dist/esm/package-checks/command-check/contract.mjs.map +1 -0
  38. package/dist/esm/package-checks/command-check/execution.mjs +134 -0
  39. package/dist/esm/package-checks/command-check/execution.mjs.map +1 -0
  40. package/dist/esm/package-checks/command-check/options.mjs +284 -0
  41. package/dist/esm/package-checks/command-check/options.mjs.map +1 -0
  42. package/dist/esm/package-checks/command-check/transcript.mjs +26 -0
  43. package/dist/esm/package-checks/command-check/transcript.mjs.map +1 -0
  44. package/dist/esm/package-checks/duplicate-detection/default-check.mjs +9 -11
  45. package/dist/esm/package-checks/duplicate-detection/default-check.mjs.map +1 -1
  46. package/dist/esm/package-checks/duplicate-detection/execution.mjs +2 -4
  47. package/dist/esm/package-checks/duplicate-detection/execution.mjs.map +1 -1
  48. package/dist/esm/package-checks/duplicate-detection/finding-messages.mjs +1 -1
  49. package/dist/esm/package-checks/duplicate-detection/finding-messages.mjs.map +1 -1
  50. package/dist/esm/package-checks/duplicate-detection/jscpd/availability.mjs +1 -1
  51. package/dist/esm/package-checks/duplicate-detection/jscpd/availability.mjs.map +1 -1
  52. package/dist/esm/package-checks/duplicate-detection/options.mjs.map +1 -1
  53. package/dist/esm/package-checks/duplicate-detection/records.mjs.map +1 -1
  54. package/dist/esm/package-checks/file-metrics/constructor.mjs +9 -11
  55. package/dist/esm/package-checks/file-metrics/constructor.mjs.map +1 -1
  56. package/dist/esm/package-checks/file-metrics/execution.mjs +2 -4
  57. package/dist/esm/package-checks/file-metrics/execution.mjs.map +1 -1
  58. package/dist/esm/package-checks/file-metrics/finding-messages.mjs +1 -1
  59. package/dist/esm/package-checks/file-metrics/finding-messages.mjs.map +1 -1
  60. package/dist/esm/package-checks/file-metrics/options.mjs.map +1 -1
  61. package/dist/esm/package-checks/file-metrics/records.mjs.map +1 -1
  62. package/dist/esm/package-checks/file-metrics/scc/availability.mjs +1 -1
  63. package/dist/esm/package-checks/file-metrics/scc/availability.mjs.map +1 -1
  64. package/dist/esm/package-checks/file-metrics/scc/batch-planner.mjs +38 -0
  65. package/dist/esm/package-checks/file-metrics/scc/batch-planner.mjs.map +1 -0
  66. package/dist/esm/package-checks/file-metrics/scc/logical-scan-resources.mjs +35 -0
  67. package/dist/esm/package-checks/file-metrics/scc/logical-scan-resources.mjs.map +1 -0
  68. package/dist/esm/package-checks/file-metrics/scc/scanner.mjs +102 -29
  69. package/dist/esm/package-checks/file-metrics/scc/scanner.mjs.map +1 -1
  70. package/dist/esm/package-checks/function-metrics/analysis.mjs +7 -2
  71. package/dist/esm/package-checks/function-metrics/analysis.mjs.map +1 -1
  72. package/dist/esm/package-checks/function-metrics/analyzer/analysis-model.mjs +1 -1
  73. package/dist/esm/package-checks/function-metrics/analyzer/analysis-model.mjs.map +1 -1
  74. package/dist/esm/package-checks/function-metrics/analyzer/extensions/lizardcomplextags.mjs +1 -3
  75. package/dist/esm/package-checks/function-metrics/analyzer/extensions/lizardcomplextags.mjs.map +1 -1
  76. package/dist/esm/package-checks/function-metrics/analyzer/extensions/protocol.mjs.map +1 -1
  77. package/dist/esm/package-checks/function-metrics/analyzer/pipeline.mjs +3 -2
  78. package/dist/esm/package-checks/function-metrics/analyzer/pipeline.mjs.map +1 -1
  79. package/dist/esm/package-checks/function-metrics/analyzer/readers/erlang.mjs +6 -6
  80. package/dist/esm/package-checks/function-metrics/analyzer/readers/erlang.mjs.map +1 -1
  81. package/dist/esm/package-checks/function-metrics/analyzer/readers/fortran.mjs +1 -1
  82. package/dist/esm/package-checks/function-metrics/analyzer/readers/fortran.mjs.map +1 -1
  83. package/dist/esm/package-checks/function-metrics/analyzer/readers/objc.mjs +9 -3
  84. package/dist/esm/package-checks/function-metrics/analyzer/readers/objc.mjs.map +1 -1
  85. package/dist/esm/package-checks/function-metrics/analyzer/readers/php-states.mjs +12 -7
  86. package/dist/esm/package-checks/function-metrics/analyzer/readers/php-states.mjs.map +1 -1
  87. package/dist/esm/package-checks/function-metrics/analyzer/readers/plsql.mjs +6 -6
  88. package/dist/esm/package-checks/function-metrics/analyzer/readers/plsql.mjs.map +1 -1
  89. package/dist/esm/package-checks/function-metrics/analyzer/readers/python.mjs +5 -3
  90. package/dist/esm/package-checks/function-metrics/analyzer/readers/python.mjs.map +1 -1
  91. package/dist/esm/package-checks/function-metrics/analyzer/readers/r.mjs +2 -0
  92. package/dist/esm/package-checks/function-metrics/analyzer/readers/r.mjs.map +1 -1
  93. package/dist/esm/package-checks/function-metrics/analyzer/readers/ttcn.mjs +9 -3
  94. package/dist/esm/package-checks/function-metrics/analyzer/readers/ttcn.mjs.map +1 -1
  95. package/dist/esm/package-checks/function-metrics/analyzer/readers/typescript.mjs +9 -3
  96. package/dist/esm/package-checks/function-metrics/analyzer/readers/typescript.mjs.map +1 -1
  97. package/dist/esm/package-checks/function-metrics/analyzer/readers/zig.mjs +3 -1
  98. package/dist/esm/package-checks/function-metrics/analyzer/readers/zig.mjs.map +1 -1
  99. package/dist/esm/package-checks/function-metrics/analyzer/shared/code-reader.mjs +3 -1
  100. package/dist/esm/package-checks/function-metrics/analyzer/shared/code-reader.mjs.map +1 -1
  101. package/dist/esm/package-checks/function-metrics/analyzer/shared/js-style-regex.mjs +12 -5
  102. package/dist/esm/package-checks/function-metrics/analyzer/shared/js-style-regex.mjs.map +1 -1
  103. package/dist/esm/package-checks/function-metrics/analyzer-worker-port.mjs +20 -8
  104. package/dist/esm/package-checks/function-metrics/analyzer-worker-port.mjs.map +1 -1
  105. package/dist/esm/package-checks/function-metrics/constructor.mjs +9 -11
  106. package/dist/esm/package-checks/function-metrics/constructor.mjs.map +1 -1
  107. package/dist/esm/package-checks/function-metrics/execution.mjs +2 -4
  108. package/dist/esm/package-checks/function-metrics/execution.mjs.map +1 -1
  109. package/dist/esm/package-checks/function-metrics/finding-messages.mjs +1 -1
  110. package/dist/esm/package-checks/function-metrics/finding-messages.mjs.map +1 -1
  111. package/dist/esm/package-checks/function-metrics/measurement.mjs +3 -1
  112. package/dist/esm/package-checks/function-metrics/measurement.mjs.map +1 -1
  113. package/dist/esm/package-checks/function-metrics/options.mjs.map +1 -1
  114. package/dist/esm/package-checks/function-metrics/records.mjs.map +1 -1
  115. package/dist/esm/package-checks/host-environment/git.mjs +11 -0
  116. package/dist/esm/package-checks/host-environment/git.mjs.map +1 -1
  117. package/dist/esm/package-checks/host-environment/path.mjs +1 -17
  118. package/dist/esm/package-checks/host-environment/path.mjs.map +1 -1
  119. package/dist/esm/package-checks/host-environment/process/contract.mjs.map +1 -1
  120. package/dist/esm/package-checks/host-environment/process/result.mjs +43 -17
  121. package/dist/esm/package-checks/host-environment/process/result.mjs.map +1 -1
  122. package/dist/esm/package-checks/host-environment/process/runner.mjs +7 -5
  123. package/dist/esm/package-checks/host-environment/process/runner.mjs.map +1 -1
  124. package/dist/esm/package-checks/json-schema-validation/default-check.mjs +9 -11
  125. package/dist/esm/package-checks/json-schema-validation/default-check.mjs.map +1 -1
  126. package/dist/esm/package-checks/json-schema-validation/options.mjs.map +1 -1
  127. package/dist/esm/package-checks/json-schema-validation/reference-resolver.mjs +6 -2
  128. package/dist/esm/package-checks/json-schema-validation/reference-resolver.mjs.map +1 -1
  129. package/dist/esm/package-checks/json-schema-validation/schema-policy.mjs +11 -3
  130. package/dist/esm/package-checks/json-schema-validation/schema-policy.mjs.map +1 -1
  131. package/dist/esm/package-checks/json-validation/default-check.mjs +9 -11
  132. package/dist/esm/package-checks/json-validation/default-check.mjs.map +1 -1
  133. package/dist/esm/package-checks/json-validation/options.mjs.map +1 -1
  134. package/dist/esm/package-checks/local-cache-options.mjs +28 -0
  135. package/dist/esm/package-checks/local-cache-options.mjs.map +1 -0
  136. package/dist/esm/package-checks/maintenance-reminders/maintenance-reminders.mjs +37 -45
  137. package/dist/esm/package-checks/maintenance-reminders/maintenance-reminders.mjs.map +1 -1
  138. package/dist/esm/package-checks/maintenance-reminders/maintenance-support.mjs +3 -1
  139. package/dist/esm/package-checks/maintenance-reminders/maintenance-support.mjs.map +1 -1
  140. package/dist/esm/package-checks/markdown-link-validation/default-check.mjs +19 -33
  141. package/dist/esm/package-checks/markdown-link-validation/default-check.mjs.map +1 -1
  142. package/dist/esm/package-checks/markdown-link-validation/execution.mjs +1 -1
  143. package/dist/esm/package-checks/markdown-link-validation/execution.mjs.map +1 -1
  144. package/dist/esm/package-checks/markdown-link-validation/finding-messages.mjs +1 -1
  145. package/dist/esm/package-checks/markdown-link-validation/finding-messages.mjs.map +1 -1
  146. package/dist/esm/package-checks/markdown-link-validation/markdown-parser.mjs +1 -3
  147. package/dist/esm/package-checks/markdown-link-validation/markdown-parser.mjs.map +1 -1
  148. package/dist/esm/package-checks/markdown-link-validation/options-resolution.mjs +3 -18
  149. package/dist/esm/package-checks/markdown-link-validation/options-resolution.mjs.map +1 -1
  150. package/dist/esm/package-checks/markdown-link-validation/options-validation.mjs +2 -14
  151. package/dist/esm/package-checks/markdown-link-validation/options-validation.mjs.map +1 -1
  152. package/dist/esm/package-checks/markdown-link-validation/options.mjs.map +1 -1
  153. package/dist/esm/package-checks/markdown-link-validation/parse-facts-cache-payload.mjs +4 -5
  154. package/dist/esm/package-checks/markdown-link-validation/parse-facts-cache-payload.mjs.map +1 -1
  155. package/dist/esm/package-checks/markdown-lint/adapter.mjs +125 -0
  156. package/dist/esm/package-checks/markdown-lint/adapter.mjs.map +1 -0
  157. package/dist/esm/package-checks/markdown-lint/default-check.mjs +37 -0
  158. package/dist/esm/package-checks/markdown-lint/default-check.mjs.map +1 -0
  159. package/dist/esm/package-checks/markdown-lint/execution.mjs +202 -0
  160. package/dist/esm/package-checks/markdown-lint/execution.mjs.map +1 -0
  161. package/dist/esm/package-checks/markdown-lint/final-data.mjs +16 -0
  162. package/dist/esm/package-checks/markdown-lint/final-data.mjs.map +1 -0
  163. package/dist/esm/package-checks/markdown-lint/finding-messages.mjs +72 -0
  164. package/dist/esm/package-checks/markdown-lint/finding-messages.mjs.map +1 -0
  165. package/dist/esm/package-checks/markdown-lint/finding-waiver-identity.mjs +41 -0
  166. package/dist/esm/package-checks/markdown-lint/finding-waiver-identity.mjs.map +1 -0
  167. package/dist/esm/package-checks/markdown-lint/findings-cache.mjs +110 -0
  168. package/dist/esm/package-checks/markdown-lint/findings-cache.mjs.map +1 -0
  169. package/dist/esm/package-checks/markdown-lint/options-resolution.mjs +74 -0
  170. package/dist/esm/package-checks/markdown-lint/options-resolution.mjs.map +1 -0
  171. package/dist/esm/package-checks/markdown-lint/options-validation.mjs +41 -0
  172. package/dist/esm/package-checks/markdown-lint/options-validation.mjs.map +1 -0
  173. package/dist/esm/package-checks/markdown-lint/options.mjs +13 -0
  174. package/dist/esm/package-checks/markdown-lint/options.mjs.map +1 -0
  175. package/dist/esm/package-checks/markdown-lint/records.mjs +65 -0
  176. package/dist/esm/package-checks/markdown-lint/records.mjs.map +1 -0
  177. package/dist/esm/package-checks/markdown-lint/unavailable-reasons.mjs +14 -0
  178. package/dist/esm/package-checks/markdown-lint/unavailable-reasons.mjs.map +1 -0
  179. package/dist/esm/package-checks/project-files/collection.mjs +23 -19
  180. package/dist/esm/package-checks/project-files/collection.mjs.map +1 -1
  181. package/dist/esm/package-checks/project-files/configuration.mjs +1 -1
  182. package/dist/esm/package-checks/project-files/configuration.mjs.map +1 -1
  183. package/dist/esm/package-checks/project-files/gitlink-revision.mjs +2 -5
  184. package/dist/esm/package-checks/project-files/gitlink-revision.mjs.map +1 -1
  185. package/dist/esm/package-checks/project-files/gitlink-worktree.mjs +22 -6
  186. package/dist/esm/package-checks/project-files/gitlink-worktree.mjs.map +1 -1
  187. package/dist/esm/package-checks/project-files/public-collection.mjs +1 -1
  188. package/dist/esm/package-checks/project-files/public-collection.mjs.map +1 -1
  189. package/dist/esm/package-checks/project-files/revision-paths.mjs +3 -3
  190. package/dist/esm/package-checks/project-files/revision-paths.mjs.map +1 -1
  191. package/dist/esm/package-checks/project-files/revision-worktree-files.mjs +11 -15
  192. package/dist/esm/package-checks/project-files/revision-worktree-files.mjs.map +1 -1
  193. package/dist/esm/package-checks/secret-detection/default-check.mjs +9 -11
  194. package/dist/esm/package-checks/secret-detection/default-check.mjs.map +1 -1
  195. package/dist/esm/package-checks/secret-detection/execution.mjs +2 -2
  196. package/dist/esm/package-checks/secret-detection/execution.mjs.map +1 -1
  197. package/dist/esm/package-checks/secret-detection/input-preparation.mjs +46 -7
  198. package/dist/esm/package-checks/secret-detection/input-preparation.mjs.map +1 -1
  199. package/dist/esm/package-checks/secret-detection/options.mjs.map +1 -1
  200. package/dist/esm/package-checks/secret-detection/records.mjs.map +1 -1
  201. package/dist/esm/package-checks/secret-detection/secretlint/adapter.mjs +3 -4
  202. package/dist/esm/package-checks/secret-detection/secretlint/adapter.mjs.map +1 -1
  203. package/dist/esm/package-tools/admission-policy/define-admission-policy.mjs +10 -0
  204. package/dist/esm/package-tools/admission-policy/define-admission-policy.mjs.map +1 -0
  205. package/dist/esm/{cache → package-tools/cache}/cache-json-by-key.mjs +13 -14
  206. package/dist/esm/package-tools/cache/cache-json-by-key.mjs.map +1 -0
  207. package/dist/esm/package-tools/finding-presentation/finding-presentation.mjs.map +1 -0
  208. package/dist/esm/{finding-waivers → package-tools/finding-waivers}/reconciliation.mjs +14 -5
  209. package/dist/esm/package-tools/finding-waivers/reconciliation.mjs.map +1 -0
  210. package/dist/esm/package-tools/learned-critical-path/critical-path-ranking.mjs.map +1 -0
  211. package/dist/esm/package-tools/learned-critical-path/duration-model/bounded-history.mjs.map +1 -0
  212. package/dist/esm/{learned-critical-path → package-tools/learned-critical-path}/duration-model/prediction.mjs +2 -2
  213. package/dist/esm/package-tools/learned-critical-path/duration-model/prediction.mjs.map +1 -0
  214. package/dist/esm/{learned-critical-path → package-tools/learned-critical-path}/duration-model/preparation.mjs +4 -2
  215. package/dist/esm/package-tools/learned-critical-path/duration-model/preparation.mjs.map +1 -0
  216. package/dist/esm/package-tools/learned-critical-path/duration-model/recording.mjs.map +1 -0
  217. package/dist/esm/{learned-critical-path → package-tools/learned-critical-path}/duration-model/storage.mjs +8 -8
  218. package/dist/esm/package-tools/learned-critical-path/duration-model/storage.mjs.map +1 -0
  219. package/dist/esm/{learned-critical-path → package-tools/learned-critical-path}/selection-layers.mjs +1 -2
  220. package/dist/esm/package-tools/learned-critical-path/selection-layers.mjs.map +1 -0
  221. package/dist/esm/package-tools/learned-critical-path/static-decision.mjs.map +1 -0
  222. package/dist/esm/{learned-critical-path → package-tools/learned-critical-path}/strategy.mjs +3 -3
  223. package/dist/esm/package-tools/learned-critical-path/strategy.mjs.map +1 -0
  224. package/dist/esm/project-definition/check-tree/authoring.mjs +8 -5
  225. package/dist/esm/project-definition/check-tree/authoring.mjs.map +1 -1
  226. package/dist/esm/project-definition/check-tree/check-fields-authoring.mjs +79 -66
  227. package/dist/esm/project-definition/check-tree/check-fields-authoring.mjs.map +1 -1
  228. package/dist/esm/project-definition/check-tree/flag-conditions.mjs +71 -0
  229. package/dist/esm/project-definition/check-tree/flag-conditions.mjs.map +1 -0
  230. package/dist/esm/project-definition/check-tree/materialization.mjs +13 -8
  231. package/dist/esm/project-definition/check-tree/materialization.mjs.map +1 -1
  232. package/dist/esm/project-definition/check-tree/resolution.mjs +7 -6
  233. package/dist/esm/project-definition/check-tree/resolution.mjs.map +1 -1
  234. package/dist/esm/project-definition/declarative-snapshot.mjs +2 -1
  235. package/dist/esm/project-definition/declarative-snapshot.mjs.map +1 -1
  236. package/dist/esm/project-definition/project-changes.mjs +70 -0
  237. package/dist/esm/project-definition/project-changes.mjs.map +1 -0
  238. package/dist/esm/project-definition/project-definition-validation.mjs +40 -8
  239. package/dist/esm/project-definition/project-definition-validation.mjs.map +1 -1
  240. package/dist/esm/project-definition/project-definition.mjs +22 -15
  241. package/dist/esm/project-definition/project-definition.mjs.map +1 -1
  242. package/dist/esm/project-definition/scheduler-policy.mjs.map +1 -1
  243. package/dist/esm/project-run/admission-strategy-provider/custom-strategy-preparation.mjs +9 -6
  244. package/dist/esm/project-run/admission-strategy-provider/custom-strategy-preparation.mjs.map +1 -1
  245. package/dist/esm/project-run/admission-strategy-provider/prepared-admission-strategy.mjs.map +1 -1
  246. package/dist/esm/project-run/aggregation.mjs +42 -59
  247. package/dist/esm/project-run/aggregation.mjs.map +1 -1
  248. package/dist/esm/project-run/changes/git.mjs +161 -0
  249. package/dist/esm/project-run/changes/git.mjs.map +1 -0
  250. package/dist/esm/project-run/check-execution/admitted-check-execution.mjs +41 -0
  251. package/dist/esm/project-run/check-execution/admitted-check-execution.mjs.map +1 -0
  252. package/dist/esm/project-run/check-execution/callback.mjs +3 -2
  253. package/dist/esm/project-run/check-execution/callback.mjs.map +1 -1
  254. package/dist/esm/project-run/check-execution/dependencies.mjs +80 -5
  255. package/dist/esm/project-run/check-execution/dependencies.mjs.map +1 -1
  256. package/dist/esm/project-run/check-execution/execution-finalization.mjs +5 -3
  257. package/dist/esm/project-run/check-execution/execution-finalization.mjs.map +1 -1
  258. package/dist/esm/project-run/check-execution/execution-settlement.mjs +37 -16
  259. package/dist/esm/project-run/check-execution/execution-settlement.mjs.map +1 -1
  260. package/dist/esm/project-run/check-execution/flag-controls.mjs +15 -7
  261. package/dist/esm/project-run/check-execution/flag-controls.mjs.map +1 -1
  262. package/dist/esm/project-run/check-execution/lifecycle.mjs.map +1 -1
  263. package/dist/esm/project-run/check-execution/{preflight-result.mjs → preparation-result.mjs} +24 -24
  264. package/dist/esm/project-run/check-execution/preparation-result.mjs.map +1 -0
  265. package/dist/esm/project-run/check-execution/{preflight.mjs → preparation.mjs} +52 -52
  266. package/dist/esm/project-run/check-execution/preparation.mjs.map +1 -0
  267. package/dist/esm/project-run/check-execution/ready-check-execution.mjs +71 -0
  268. package/dist/esm/project-run/check-execution/ready-check-execution.mjs.map +1 -0
  269. package/dist/esm/project-run/check-execution/resolved-checks.mjs +27 -164
  270. package/dist/esm/project-run/check-execution/resolved-checks.mjs.map +1 -1
  271. package/dist/esm/project-run/check-execution/scheduled-check-run.mjs +79 -0
  272. package/dist/esm/project-run/check-execution/scheduled-check-run.mjs.map +1 -0
  273. package/dist/esm/project-run/check-execution/terminal-result.mjs +70 -25
  274. package/dist/esm/project-run/check-execution/terminal-result.mjs.map +1 -1
  275. package/dist/esm/project-run/completion/completion.mjs +18 -1
  276. package/dist/esm/project-run/completion/completion.mjs.map +1 -1
  277. package/dist/esm/project-run/controls/contract.mjs.map +1 -1
  278. package/dist/esm/project-run/controls/validation.mjs +7 -54
  279. package/dist/esm/project-run/controls/validation.mjs.map +1 -1
  280. package/dist/esm/project-run/diagnostic-logging/diagnostic-detail-rendering.mjs +3 -3
  281. package/dist/esm/project-run/diagnostic-logging/diagnostic-detail-rendering.mjs.map +1 -1
  282. package/dist/esm/project-run/diagnostic-logging/observation-rendering.mjs +1 -1
  283. package/dist/esm/project-run/diagnostic-logging/observation-rendering.mjs.map +1 -1
  284. package/dist/esm/project-run/invocation/candidate.mjs +17 -13
  285. package/dist/esm/project-run/invocation/candidate.mjs.map +1 -1
  286. package/dist/esm/project-run/invocation/candidates.mjs +26 -0
  287. package/dist/esm/project-run/invocation/candidates.mjs.map +1 -0
  288. package/dist/esm/project-run/invocation/creation.mjs +7 -3
  289. package/dist/esm/project-run/invocation/creation.mjs.map +1 -1
  290. package/dist/esm/project-run/invocation/execution.mjs +98 -0
  291. package/dist/esm/project-run/invocation/execution.mjs.map +1 -0
  292. package/dist/esm/project-run/invocation/run.mjs +13 -112
  293. package/dist/esm/project-run/invocation/run.mjs.map +1 -1
  294. package/dist/esm/project-run/invocation/scheduler.mjs +13 -6
  295. package/dist/esm/project-run/invocation/scheduler.mjs.map +1 -1
  296. package/dist/esm/project-run/outputs/status.mjs +12 -12
  297. package/dist/esm/project-run/outputs/status.mjs.map +1 -1
  298. package/dist/esm/project-run/progress-rendering/presentation.mjs +31 -11
  299. package/dist/esm/project-run/progress-rendering/presentation.mjs.map +1 -1
  300. package/dist/esm/project-run/progress-rendering/renderer-formatting.mjs +11 -4
  301. package/dist/esm/project-run/progress-rendering/renderer-formatting.mjs.map +1 -1
  302. package/dist/esm/project-run/progress-rendering/renderer-lifecycle.mjs +20 -6
  303. package/dist/esm/project-run/progress-rendering/renderer-lifecycle.mjs.map +1 -1
  304. package/dist/esm/project-run/progress-rendering/renderer.mjs +6 -2
  305. package/dist/esm/project-run/progress-rendering/renderer.mjs.map +1 -1
  306. package/dist/esm/project-run/project-context.mjs +2 -1
  307. package/dist/esm/project-run/project-context.mjs.map +1 -1
  308. package/dist/esm/project-run/result.mjs +2 -2
  309. package/dist/esm/project-run/result.mjs.map +1 -1
  310. package/dist/esm/project-run/run.mjs.map +1 -1
  311. package/dist/esm/project-run/task-scheduler/admission-core/compiled-graph-lookup.mjs +45 -0
  312. package/dist/esm/project-run/task-scheduler/admission-core/compiled-graph-lookup.mjs.map +1 -0
  313. package/dist/esm/project-run/task-scheduler/admission-core/compiled-graph.mjs +9 -4
  314. package/dist/esm/project-run/task-scheduler/admission-core/compiled-graph.mjs.map +1 -1
  315. package/dist/esm/project-run/task-scheduler/admission-core/selection-query.mjs +3 -5
  316. package/dist/esm/project-run/task-scheduler/admission-core/selection-query.mjs.map +1 -1
  317. package/dist/esm/project-run/task-scheduler/admission-core/selection-seed.mjs +25 -8
  318. package/dist/esm/project-run/task-scheduler/admission-core/selection-seed.mjs.map +1 -1
  319. package/dist/esm/project-run/task-scheduler/admission-core/selection-transition.mjs +8 -8
  320. package/dist/esm/project-run/task-scheduler/admission-core/selection-transition.mjs.map +1 -1
  321. package/dist/esm/project-run/task-scheduler/execution-state.mjs.map +1 -1
  322. package/dist/esm/project-run/task-scheduler/measurement/diagnostics.mjs +8 -4
  323. package/dist/esm/project-run/task-scheduler/measurement/diagnostics.mjs.map +1 -1
  324. package/dist/esm/project-run/task-scheduler/measurement/timing.mjs +12 -6
  325. package/dist/esm/project-run/task-scheduler/measurement/timing.mjs.map +1 -1
  326. package/dist/esm/project-run/task-scheduler/scheduler-observation.mjs +3 -1
  327. package/dist/esm/project-run/task-scheduler/scheduler-observation.mjs.map +1 -1
  328. package/dist/esm/project-run/task-scheduler/scheduler-terminal-measurement.mjs +17 -17
  329. package/dist/esm/project-run/task-scheduler/scheduler-terminal-measurement.mjs.map +1 -1
  330. package/dist/esm/project-run/task-scheduler/scheduler.mjs +18 -6
  331. package/dist/esm/project-run/task-scheduler/scheduler.mjs.map +1 -1
  332. package/docs/api-mechanics.md +147 -28
  333. package/docs/changelog.md +145 -2
  334. package/docs/checks/duplicate-detection.md +22 -3
  335. package/docs/checks/file-metrics.md +25 -6
  336. package/docs/checks/function-metrics.md +21 -2
  337. package/docs/checks/json-schema-validation.md +25 -4
  338. package/docs/checks/json-validation.md +24 -5
  339. package/docs/checks/maintenance-reminders.md +30 -6
  340. package/docs/checks/markdown-link-validation.md +24 -4
  341. package/docs/checks/markdown-lint.md +167 -0
  342. package/docs/checks/secret-detection.md +31 -7
  343. package/docs/examples/artifacts/mixed-outcomes/definition.ts +10 -10
  344. package/docs/guides/building-project-gate.md +706 -0
  345. package/docs/guides/callbacks.md +81 -22
  346. package/docs/guides/check-dependencies.md +41 -10
  347. package/docs/guides/collecting-project-files.md +7 -7
  348. package/docs/guides/command-check.md +155 -0
  349. package/docs/guides/data-boundaries.md +140 -0
  350. package/docs/guides/extending-check-lifecycle.md +77 -25
  351. package/docs/guides/finding-waivers.md +43 -1
  352. package/docs/guides/learned-scheduling.md +1 -1
  353. package/docs/guides/run-outputs.md +35 -9
  354. package/docs/guides/scheduling.md +15 -15
  355. package/docs/output.md +6 -5
  356. package/package.json +2 -1
  357. package/src/check/check.ts +332 -92
  358. package/src/check/flag-enablement.ts +76 -0
  359. package/src/check/handoff-provider-identity.ts +34 -0
  360. package/src/check/inherited-collection.ts +1 -1
  361. package/src/check/project-changes.ts +14 -0
  362. package/src/check/project-context.ts +11 -0
  363. package/src/check-settlement/facts.ts +1 -1
  364. package/src/check-settlement/record-store.ts +1 -1
  365. package/src/data-boundary/canonical-data.ts +36 -9
  366. package/src/data-boundary/canonical-json.ts +18 -1
  367. package/src/data-boundary/closed-values.ts +26 -6
  368. package/src/data-boundary/config-glob.ts +17 -0
  369. package/src/data-boundary/project-path.ts +21 -0
  370. package/src/index.ts +72 -11
  371. package/src/machine-output/v4/atomic-publication.ts +3 -1
  372. package/src/package-checks/check-authoring.ts +136 -0
  373. package/src/package-checks/code-quality-findings/finding-waiver-authoring.ts +1 -1
  374. package/src/package-checks/code-quality-findings/finding-waiver-evidence.ts +1 -1
  375. package/src/package-checks/command-check/command-check.ts +152 -0
  376. package/src/package-checks/command-check/contract.ts +168 -0
  377. package/src/package-checks/command-check/execution.ts +211 -0
  378. package/src/package-checks/command-check/options.ts +331 -0
  379. package/src/package-checks/command-check/transcript.ts +35 -0
  380. package/src/package-checks/duplicate-detection/default-check.ts +37 -6
  381. package/src/package-checks/duplicate-detection/execution.ts +2 -4
  382. package/src/package-checks/duplicate-detection/finding-messages.ts +2 -2
  383. package/src/package-checks/duplicate-detection/jscpd/availability.ts +1 -1
  384. package/src/package-checks/duplicate-detection/options.ts +6 -3
  385. package/src/package-checks/duplicate-detection/records.ts +1 -1
  386. package/src/package-checks/file-metrics/constructor.ts +29 -6
  387. package/src/package-checks/file-metrics/execution.ts +2 -4
  388. package/src/package-checks/file-metrics/finding-messages.ts +1 -1
  389. package/src/package-checks/file-metrics/options.ts +6 -3
  390. package/src/package-checks/file-metrics/records.ts +1 -1
  391. package/src/package-checks/file-metrics/scc/availability.ts +1 -1
  392. package/src/package-checks/file-metrics/scc/batch-planner.ts +56 -0
  393. package/src/package-checks/file-metrics/scc/logical-scan-resources.ts +59 -0
  394. package/src/package-checks/file-metrics/scc/scanner.ts +134 -32
  395. package/src/package-checks/function-metrics/analysis.ts +7 -2
  396. package/src/package-checks/function-metrics/analyzer/analysis-model.ts +1 -1
  397. package/src/package-checks/function-metrics/analyzer/extension-output.ts +14 -6
  398. package/src/package-checks/function-metrics/analyzer/extensions/lizardcomplextags.ts +1 -3
  399. package/src/package-checks/function-metrics/analyzer/extensions/protocol.ts +3 -3
  400. package/src/package-checks/function-metrics/analyzer/pipeline.ts +4 -2
  401. package/src/package-checks/function-metrics/analyzer/readers/erlang.ts +6 -6
  402. package/src/package-checks/function-metrics/analyzer/readers/fortran.ts +1 -1
  403. package/src/package-checks/function-metrics/analyzer/readers/objc.ts +9 -3
  404. package/src/package-checks/function-metrics/analyzer/readers/php-states.ts +14 -7
  405. package/src/package-checks/function-metrics/analyzer/readers/plsql.ts +8 -4
  406. package/src/package-checks/function-metrics/analyzer/readers/python.ts +4 -3
  407. package/src/package-checks/function-metrics/analyzer/readers/r.ts +2 -1
  408. package/src/package-checks/function-metrics/analyzer/readers/ttcn.ts +9 -3
  409. package/src/package-checks/function-metrics/analyzer/readers/typescript.ts +9 -3
  410. package/src/package-checks/function-metrics/analyzer/readers/zig.ts +2 -1
  411. package/src/package-checks/function-metrics/analyzer/shared/code-reader.ts +3 -1
  412. package/src/package-checks/function-metrics/analyzer/shared/js-style-regex.ts +10 -5
  413. package/src/package-checks/function-metrics/analyzer-worker-port.ts +20 -6
  414. package/src/package-checks/function-metrics/constructor.ts +30 -7
  415. package/src/package-checks/function-metrics/execution.ts +2 -4
  416. package/src/package-checks/function-metrics/finding-messages.ts +2 -2
  417. package/src/package-checks/function-metrics/measurement.ts +3 -1
  418. package/src/package-checks/function-metrics/options.ts +6 -3
  419. package/src/package-checks/function-metrics/records.ts +1 -1
  420. package/src/package-checks/host-environment/git.ts +11 -0
  421. package/src/package-checks/host-environment/path.ts +1 -20
  422. package/src/package-checks/host-environment/process/contract.ts +17 -9
  423. package/src/package-checks/host-environment/process/result.ts +48 -20
  424. package/src/package-checks/host-environment/process/runner.ts +8 -4
  425. package/src/package-checks/json-schema-validation/default-check.ts +38 -5
  426. package/src/package-checks/json-schema-validation/options.ts +4 -1
  427. package/src/package-checks/json-schema-validation/reference-resolver.ts +6 -2
  428. package/src/package-checks/json-schema-validation/schema-policy.ts +10 -5
  429. package/src/package-checks/json-validation/default-check.ts +27 -6
  430. package/src/package-checks/json-validation/options.ts +4 -1
  431. package/src/package-checks/local-cache-options.ts +40 -0
  432. package/src/package-checks/maintenance-reminders/maintenance-reminders.ts +89 -9
  433. package/src/package-checks/maintenance-reminders/maintenance-support.ts +3 -3
  434. package/src/package-checks/markdown-link-validation/default-check.ts +48 -5
  435. package/src/package-checks/markdown-link-validation/execution.ts +1 -1
  436. package/src/package-checks/markdown-link-validation/finding-messages.ts +1 -1
  437. package/src/package-checks/markdown-link-validation/markdown-parser.ts +1 -5
  438. package/src/package-checks/markdown-link-validation/options-resolution.ts +2 -19
  439. package/src/package-checks/markdown-link-validation/options-validation.ts +2 -17
  440. package/src/package-checks/markdown-link-validation/options.ts +6 -7
  441. package/src/package-checks/markdown-link-validation/parse-facts-cache-payload.ts +4 -5
  442. package/src/package-checks/markdown-lint/adapter.ts +167 -0
  443. package/src/package-checks/markdown-lint/default-check.ts +92 -0
  444. package/src/package-checks/markdown-lint/execution.ts +266 -0
  445. package/src/package-checks/markdown-lint/final-data.ts +33 -0
  446. package/src/package-checks/markdown-lint/finding-messages.ts +87 -0
  447. package/src/package-checks/markdown-lint/finding-waiver-identity.ts +54 -0
  448. package/src/package-checks/markdown-lint/findings-cache.ts +141 -0
  449. package/src/package-checks/markdown-lint/options-resolution.ts +102 -0
  450. package/src/package-checks/markdown-lint/options-validation.ts +50 -0
  451. package/src/package-checks/markdown-lint/options.ts +82 -0
  452. package/src/package-checks/markdown-lint/records.ts +132 -0
  453. package/src/package-checks/markdown-lint/unavailable-reasons.ts +33 -0
  454. package/src/package-checks/project-files/collection.ts +38 -22
  455. package/src/package-checks/project-files/config-glob.ts +1 -17
  456. package/src/package-checks/project-files/configuration.ts +1 -1
  457. package/src/package-checks/project-files/gitlink-revision.ts +4 -6
  458. package/src/package-checks/project-files/gitlink-worktree.ts +35 -7
  459. package/src/package-checks/project-files/public-collection.ts +1 -1
  460. package/src/package-checks/project-files/revision-paths.ts +3 -3
  461. package/src/package-checks/project-files/revision-worktree-files.ts +16 -16
  462. package/src/package-checks/secret-detection/default-check.ts +29 -6
  463. package/src/package-checks/secret-detection/execution.ts +2 -2
  464. package/src/package-checks/secret-detection/input-preparation.ts +64 -7
  465. package/src/package-checks/secret-detection/options.ts +5 -2
  466. package/src/package-checks/secret-detection/records.ts +1 -1
  467. package/src/package-checks/secret-detection/secretlint/adapter.ts +3 -4
  468. package/src/package-tools/admission-policy/define-admission-policy.ts +54 -0
  469. package/src/{cache → package-tools/cache}/cache-json-by-key.ts +13 -17
  470. package/src/{check → package-tools/finding-presentation}/finding-presentation.ts +3 -1
  471. package/src/{finding-waivers → package-tools/finding-waivers}/reconciliation.ts +16 -8
  472. package/src/{learned-critical-path → package-tools/learned-critical-path}/duration-model/prediction.ts +5 -2
  473. package/src/{learned-critical-path → package-tools/learned-critical-path}/duration-model/preparation.ts +5 -3
  474. package/src/{learned-critical-path → package-tools/learned-critical-path}/duration-model/recording.ts +5 -4
  475. package/src/{learned-critical-path → package-tools/learned-critical-path}/duration-model/storage.ts +9 -10
  476. package/src/{learned-critical-path → package-tools/learned-critical-path}/selection-layers.ts +2 -3
  477. package/src/{learned-critical-path → package-tools/learned-critical-path}/static-decision.ts +1 -1
  478. package/src/{learned-critical-path → package-tools/learned-critical-path}/strategy.ts +7 -4
  479. package/src/project-definition/check-tree/authoring.ts +15 -8
  480. package/src/project-definition/check-tree/check-fields-authoring.ts +106 -91
  481. package/src/project-definition/check-tree/flag-conditions.ts +99 -0
  482. package/src/project-definition/check-tree/materialization.ts +12 -8
  483. package/src/project-definition/check-tree/resolution.ts +13 -15
  484. package/src/project-definition/declarative-snapshot.ts +9 -2
  485. package/src/project-definition/project-changes.ts +112 -0
  486. package/src/project-definition/project-definition-validation.ts +58 -10
  487. package/src/project-definition/project-definition.ts +41 -68
  488. package/src/project-definition/scheduler-policy.ts +6 -3
  489. package/src/project-run/admission-strategy-provider/custom-strategy-preparation.ts +11 -8
  490. package/src/project-run/admission-strategy-provider/prepared-admission-strategy.ts +2 -2
  491. package/src/project-run/aggregation.ts +51 -74
  492. package/src/project-run/changes/git.ts +206 -0
  493. package/src/project-run/check-execution/admitted-check-execution.ts +62 -0
  494. package/src/project-run/check-execution/callback.ts +3 -2
  495. package/src/project-run/check-execution/dependencies.ts +120 -6
  496. package/src/project-run/check-execution/execution-finalization.ts +6 -4
  497. package/src/project-run/check-execution/execution-settlement.ts +88 -29
  498. package/src/project-run/check-execution/flag-controls.ts +22 -8
  499. package/src/project-run/check-execution/lifecycle.ts +14 -6
  500. package/src/project-run/check-execution/{preflight-result.ts → preparation-result.ts} +34 -32
  501. package/src/project-run/check-execution/{preflight.ts → preparation.ts} +92 -84
  502. package/src/project-run/check-execution/ready-check-execution.ts +97 -0
  503. package/src/project-run/check-execution/resolved-checks.ts +40 -219
  504. package/src/project-run/check-execution/scheduled-check-run.ts +119 -0
  505. package/src/project-run/check-execution/terminal-result.ts +108 -29
  506. package/src/project-run/completion/completion.ts +17 -3
  507. package/src/project-run/controls/contract.ts +6 -16
  508. package/src/project-run/controls/validation.ts +7 -60
  509. package/src/project-run/diagnostic-logging/diagnostic-detail-rendering.ts +1 -2
  510. package/src/project-run/diagnostic-logging/observation-rendering.ts +1 -1
  511. package/src/project-run/invocation/candidate.ts +28 -15
  512. package/src/project-run/invocation/candidates.ts +56 -0
  513. package/src/project-run/invocation/creation.ts +7 -3
  514. package/src/project-run/invocation/execution.ts +136 -0
  515. package/src/project-run/invocation/run.ts +15 -179
  516. package/src/project-run/invocation/scheduler.ts +13 -6
  517. package/src/project-run/outputs/status.ts +15 -15
  518. package/src/project-run/progress-rendering/presentation.ts +35 -13
  519. package/src/project-run/progress-rendering/renderer-formatting.ts +20 -7
  520. package/src/project-run/progress-rendering/renderer-lifecycle.ts +23 -6
  521. package/src/project-run/progress-rendering/renderer.ts +10 -4
  522. package/src/project-run/project-context.ts +8 -4
  523. package/src/project-run/result.ts +5 -5
  524. package/src/project-run/run.ts +1 -1
  525. package/src/project-run/task-scheduler/admission-core/compiled-graph-lookup.ts +71 -0
  526. package/src/project-run/task-scheduler/admission-core/compiled-graph.ts +9 -4
  527. package/src/project-run/task-scheduler/admission-core/selection-query.ts +6 -4
  528. package/src/project-run/task-scheduler/admission-core/selection-seed.ts +36 -6
  529. package/src/project-run/task-scheduler/admission-core/selection-transition.ts +17 -8
  530. package/src/project-run/task-scheduler/execution-state.ts +4 -4
  531. package/src/project-run/task-scheduler/measurement/diagnostics.ts +10 -4
  532. package/src/project-run/task-scheduler/measurement/timing.ts +13 -5
  533. package/src/project-run/task-scheduler/scheduler-observation.ts +3 -1
  534. package/src/project-run/task-scheduler/scheduler-terminal-measurement.ts +24 -22
  535. package/src/project-run/task-scheduler/scheduler.ts +23 -6
  536. package/types/check/check.d.ts +178 -67
  537. package/types/check/flag-enablement.d.ts +42 -0
  538. package/types/check/handoff-provider-identity.d.ts +12 -0
  539. package/types/check/project-changes.d.ts +13 -0
  540. package/types/check/project-context.d.ts +10 -0
  541. package/types/check-settlement/facts.d.ts +1 -1
  542. package/types/data-boundary/canonical-data.d.ts +28 -5
  543. package/types/data-boundary/canonical-json.d.ts +18 -1
  544. package/types/data-boundary/closed-values.d.ts +17 -1
  545. package/types/data-boundary/config-glob.d.ts +5 -0
  546. package/types/data-boundary/project-path.d.ts +4 -0
  547. package/types/index.d.ts +27 -11
  548. package/types/package-checks/check-authoring.d.ts +45 -0
  549. package/types/package-checks/code-quality-findings/finding-waiver-authoring.d.ts +1 -1
  550. package/types/package-checks/code-quality-findings/finding-waiver-evidence.d.ts +1 -1
  551. package/types/package-checks/command-check/command-check.d.ts +48 -0
  552. package/types/package-checks/command-check/contract.d.ts +108 -0
  553. package/types/package-checks/command-check/execution.d.ts +7 -0
  554. package/types/package-checks/command-check/options.d.ts +11 -0
  555. package/types/package-checks/command-check/transcript.d.ts +8 -0
  556. package/types/package-checks/duplicate-detection/default-check.d.ts +5 -2
  557. package/types/package-checks/duplicate-detection/finding-messages.d.ts +1 -1
  558. package/types/package-checks/duplicate-detection/options.d.ts +4 -3
  559. package/types/package-checks/duplicate-detection/records.d.ts +1 -1
  560. package/types/package-checks/file-metrics/constructor.d.ts +5 -2
  561. package/types/package-checks/file-metrics/options.d.ts +4 -3
  562. package/types/package-checks/file-metrics/records.d.ts +1 -1
  563. package/types/package-checks/file-metrics/scc/batch-planner.d.ts +18 -0
  564. package/types/package-checks/file-metrics/scc/logical-scan-resources.d.ts +14 -0
  565. package/types/package-checks/function-metrics/analyzer/extensions/protocol.d.ts +3 -3
  566. package/types/package-checks/function-metrics/constructor.d.ts +5 -2
  567. package/types/package-checks/function-metrics/finding-messages.d.ts +1 -1
  568. package/types/package-checks/function-metrics/options.d.ts +4 -3
  569. package/types/package-checks/function-metrics/records.d.ts +1 -1
  570. package/types/package-checks/host-environment/git.d.ts +2 -0
  571. package/types/package-checks/host-environment/path.d.ts +1 -3
  572. package/types/package-checks/host-environment/process/contract.d.ts +17 -9
  573. package/types/package-checks/json-schema-validation/default-check.d.ts +4 -1
  574. package/types/package-checks/json-schema-validation/options.d.ts +2 -1
  575. package/types/package-checks/json-validation/default-check.d.ts +4 -1
  576. package/types/package-checks/json-validation/options.d.ts +2 -1
  577. package/types/package-checks/local-cache-options.d.ts +9 -0
  578. package/types/package-checks/maintenance-reminders/maintenance-reminders.d.ts +11 -2
  579. package/types/package-checks/markdown-link-validation/default-check.d.ts +4 -1
  580. package/types/package-checks/markdown-link-validation/options.d.ts +4 -7
  581. package/types/package-checks/markdown-lint/adapter.d.ts +10 -0
  582. package/types/package-checks/markdown-lint/default-check.d.ts +37 -0
  583. package/types/package-checks/markdown-lint/execution.d.ts +24 -0
  584. package/types/package-checks/markdown-lint/final-data.d.ts +8 -0
  585. package/types/package-checks/markdown-lint/finding-messages.d.ts +6 -0
  586. package/types/package-checks/markdown-lint/finding-waiver-identity.d.ts +3 -0
  587. package/types/package-checks/markdown-lint/findings-cache.d.ts +17 -0
  588. package/types/package-checks/markdown-lint/options-resolution.d.ts +3 -0
  589. package/types/package-checks/markdown-lint/options-validation.d.ts +2 -0
  590. package/types/package-checks/markdown-lint/options.d.ts +65 -0
  591. package/types/package-checks/markdown-lint/records.d.ts +39 -0
  592. package/types/package-checks/markdown-lint/unavailable-reasons.d.ts +3 -0
  593. package/types/package-checks/secret-detection/default-check.d.ts +4 -1
  594. package/types/package-checks/secret-detection/options.d.ts +3 -2
  595. package/types/package-tools/admission-policy/define-admission-policy.d.ts +26 -0
  596. package/types/{check → package-tools/finding-presentation}/finding-presentation.d.ts +3 -1
  597. package/types/{finding-waivers → package-tools/finding-waivers}/reconciliation.d.ts +3 -3
  598. package/types/{learned-critical-path → package-tools/learned-critical-path}/duration-model/prediction.d.ts +2 -2
  599. package/types/{learned-critical-path → package-tools/learned-critical-path}/duration-model/preparation.d.ts +1 -1
  600. package/types/{learned-critical-path → package-tools/learned-critical-path}/duration-model/recording.d.ts +1 -1
  601. package/types/{learned-critical-path → package-tools/learned-critical-path}/selection-layers.d.ts +1 -1
  602. package/types/{learned-critical-path → package-tools/learned-critical-path}/static-decision.d.ts +1 -1
  603. package/types/{learned-critical-path → package-tools/learned-critical-path}/strategy.d.ts +1 -1
  604. package/types/project-definition/check-tree/authoring.d.ts +5 -3
  605. package/types/project-definition/check-tree/check-fields-authoring.d.ts +12 -7
  606. package/types/project-definition/check-tree/flag-conditions.d.ts +5 -0
  607. package/types/project-definition/check-tree/resolution.d.ts +6 -4
  608. package/types/project-definition/declarative-snapshot.d.ts +4 -1
  609. package/types/project-definition/project-changes.d.ts +30 -0
  610. package/types/project-definition/project-definition.d.ts +15 -30
  611. package/types/project-definition/scheduler-policy.d.ts +3 -3
  612. package/types/project-run/admission-strategy-provider/prepared-admission-strategy.d.ts +2 -2
  613. package/types/project-run/aggregation.d.ts +8 -6
  614. package/types/project-run/changes/git.d.ts +14 -0
  615. package/types/project-run/check-execution/admitted-check-execution.d.ts +18 -0
  616. package/types/project-run/check-execution/dependencies.d.ts +3 -0
  617. package/types/project-run/check-execution/execution-finalization.d.ts +1 -1
  618. package/types/project-run/check-execution/execution-settlement.d.ts +15 -7
  619. package/types/project-run/check-execution/flag-controls.d.ts +1 -1
  620. package/types/project-run/check-execution/lifecycle.d.ts +9 -5
  621. package/types/project-run/check-execution/{preflight-result.d.ts → preparation-result.d.ts} +3 -3
  622. package/types/project-run/check-execution/{preflight.d.ts → preparation.d.ts} +10 -9
  623. package/types/project-run/check-execution/ready-check-execution.d.ts +18 -0
  624. package/types/project-run/check-execution/resolved-checks.d.ts +12 -13
  625. package/types/project-run/check-execution/scheduled-check-run.d.ts +10 -0
  626. package/types/project-run/check-execution/terminal-result.d.ts +13 -1
  627. package/types/project-run/completion/completion.d.ts +3 -1
  628. package/types/project-run/controls/contract.d.ts +6 -16
  629. package/types/project-run/invocation/candidates.d.ts +8 -0
  630. package/types/project-run/invocation/execution.d.ts +5 -0
  631. package/types/project-run/invocation/run.d.ts +2 -2
  632. package/types/project-run/outputs/status.d.ts +4 -4
  633. package/types/project-run/progress-rendering/presentation.d.ts +4 -3
  634. package/types/project-run/progress-rendering/renderer-formatting.d.ts +5 -2
  635. package/types/project-run/progress-rendering/renderer-lifecycle.d.ts +2 -0
  636. package/types/project-run/progress-rendering/renderer.d.ts +4 -2
  637. package/types/project-run/project-context.d.ts +3 -3
  638. package/types/project-run/result.d.ts +3 -3
  639. package/types/project-run/run.d.ts +1 -1
  640. package/types/project-run/task-scheduler/admission-core/compiled-graph-lookup.d.ts +10 -0
  641. package/types/project-run/task-scheduler/execution-state.d.ts +4 -4
  642. package/types/project-run/task-scheduler/measurement/diagnostics.d.ts +2 -2
  643. package/types/project-run/task-scheduler/scheduler-terminal-measurement.d.ts +1 -1
  644. package/dist/esm/cache/cache-json-by-key.mjs.map +0 -1
  645. package/dist/esm/check/finding-presentation.mjs.map +0 -1
  646. package/dist/esm/finding-waivers/reconciliation.mjs.map +0 -1
  647. package/dist/esm/learned-critical-path/duration-model/bounded-history.mjs.map +0 -1
  648. package/dist/esm/learned-critical-path/duration-model/prediction.mjs.map +0 -1
  649. package/dist/esm/learned-critical-path/duration-model/preparation.mjs.map +0 -1
  650. package/dist/esm/learned-critical-path/duration-model/recording.mjs.map +0 -1
  651. package/dist/esm/learned-critical-path/duration-model/storage.mjs.map +0 -1
  652. package/dist/esm/learned-critical-path/selection-layers.mjs.map +0 -1
  653. package/dist/esm/learned-critical-path/static-decision.mjs.map +0 -1
  654. package/dist/esm/learned-critical-path/strategy.mjs.map +0 -1
  655. package/dist/esm/package-checks/project-files/config-glob.mjs.map +0 -1
  656. package/dist/esm/project-run/check-execution/preflight-result.mjs.map +0 -1
  657. package/dist/esm/project-run/check-execution/preflight.mjs.map +0 -1
  658. package/dist/esm/project-run/task-scheduler/critical-path-ranking.mjs.map +0 -1
  659. package/types/package-checks/project-files/config-glob.d.ts +0 -5
  660. /package/dist/esm/{check → package-tools/finding-presentation}/finding-presentation.mjs +0 -0
  661. /package/dist/esm/{project-run/task-scheduler → package-tools/learned-critical-path}/critical-path-ranking.mjs +0 -0
  662. /package/dist/esm/{learned-critical-path → package-tools/learned-critical-path}/duration-model/bounded-history.mjs +0 -0
  663. /package/dist/esm/{learned-critical-path → package-tools/learned-critical-path}/duration-model/recording.mjs +0 -0
  664. /package/dist/esm/{learned-critical-path → package-tools/learned-critical-path}/static-decision.mjs +0 -0
  665. /package/src/{project-run/task-scheduler → package-tools/learned-critical-path}/critical-path-ranking.ts +0 -0
  666. /package/src/{learned-critical-path → package-tools/learned-critical-path}/duration-model/bounded-history.ts +0 -0
  667. /package/types/{cache → package-tools/cache}/cache-json-by-key.d.ts +0 -0
  668. /package/types/{project-run/task-scheduler → package-tools/learned-critical-path}/critical-path-ranking.d.ts +0 -0
  669. /package/types/{learned-critical-path → package-tools/learned-critical-path}/duration-model/bounded-history.d.ts +0 -0
  670. /package/types/{learned-critical-path → package-tools/learned-critical-path}/duration-model/storage.d.ts +0 -0
@@ -5,6 +5,28 @@
5
5
  `jsonSchemaValidation(options?)` 构造普通 Check,使用显式 schema registry 与 instance bindings 验证 JSON instances。
6
6
  先声明 schema 与 binding;无参调用不发现 schema,并结算为 `not-applicable / no-bindings`。
7
7
 
8
+ ## 构造器项目声明
9
+
10
+ `jsonSchemaValidation` 有三类 overload:
11
+ `jsonSchemaValidation(options?: JsonSchemaValidationOptions<"json-schema-validation">)` 保留默认 literal;
12
+ `jsonSchemaValidation<Id>(options: JsonSchemaValidationOptions<Id> & { checkId: Id })` 保留 custom literal;
13
+ 已宽化为 `JsonSchemaValidationOptions` 的变量返回 `string` identity。默认 `checkId` 是 `json-schema-validation`,默认 `displayName` 是 `JSON Schema validation`;`files`、
14
+ `maximumBytes`、`schemaIdentity`、`referenceResolution`、`schemas` 与 `bindings` 仍是本 Check 的领域 options。
15
+
16
+ 例如,将 API schema 校验声明为只在 API 变更时选择的独立 Check:
17
+
18
+ ```ts
19
+ const apiSchema = jsonSchemaValidation({
20
+ checkId: "api-schema",
21
+ enabledByFlags: { when: "api-changed" },
22
+ schemas: [{ id: "urn:example:api", path: "schema/api.json" }],
23
+ bindings: [{ id: "api", instancePath: "fixtures/api.json", schemaId: "urn:example:api" }]
24
+ });
25
+ ```
26
+
27
+ 返回值仍是原生 typed Check。项目声明字段不会进入 `.options` 或执行时的 `context.options`;
28
+ 完整字段集合、投影和校验边界见[API 机制](../api-mechanics.md#随包-check-的构造器项目声明)。
29
+
8
30
  ## 最小用法
9
31
 
10
32
  示例保留终端进度,不写 machine files。
@@ -32,8 +54,7 @@ if (result.kind !== "completed" || outcome?.status !== "passed") {
32
54
  }
33
55
  ```
34
56
 
35
- 本例只接受 `completed` Run 中的 `passed` Check,否则退出非零。若需接受 `not-applicable` 或聚合多个 Check,
36
- 显式配置并读取 [`checkAggregation`](../api-mechanics.md#runcontrols-与-check-aggregation);`run(...)` 返回本身不表示通过。
57
+ 本例只接受 `completed` Run 中的 `passed` Check,否则退出非零。多个有效 Check 的调用级结论可读取默认严格 `aggregate`;需要不同领域解释时,提供同步 [`checkAggregation`](../api-mechanics.md#runcontrols-与-check-aggregation) 函数。`run(...)` 返回本身不表示通过。
37
58
 
38
59
  ## 参数与默认配置
39
60
 
@@ -103,7 +124,7 @@ fragment 的精确 HTTPS origin;`pathPrefix` 最长 256 字符,从 `/` 开
103
124
 
104
125
  ## 工作原理
105
126
 
106
- constructor 补齐并冻结 closed options;获 Scheduler admission 后先 preflight,再建立 selected path set、加载 registry、
127
+ constructor 补齐并冻结 closed options;获 Scheduler admission 后先 preparation,再建立 selected path set、加载 registry、
107
128
  按 identity policy 编译并验证 bindings。selected set 外的声明路径形成 `out-of-scope` issue,不扩大读取范围。
108
129
  schema document、compile 与 instance issues 均形成 Records。
109
130
 
@@ -181,7 +202,7 @@ binding 数量为零时结算为 `not-applicable / no-bindings`。`unavailable.r
181
202
 
182
203
  任一 `unavailable` 分支都不提供 final data;此前已经接受的 issue Records 继续保留。
183
204
 
184
- 通用 preflight 语法见 [options preflight 与 execution](../api-mechanics.md#options-preflight-与-execution)。
205
+ 通用 preparation 语法见 [options preparation 与 execution](../api-mechanics.md#options-preparation-与-execution)。
185
206
 
186
207
  ## I/O 与安全边界
187
208
 
@@ -5,6 +5,26 @@
5
5
  `jsonValidation(options?)` 构造普通 Check,严格验证所选小写 `.json` 文档的完整性,报告 syntax error、duplicate key
6
6
  与 incomplete document。
7
7
 
8
+ ## 构造器项目声明
9
+
10
+ `jsonValidation` 有三类 overload:`jsonValidation(options?: JsonValidationOptions<"json-validation">)`
11
+ 保留默认 literal;`jsonValidation<Id>(options: JsonValidationOptions<Id> & { checkId: Id })` 保留 custom literal;
12
+ 已宽化为 `JsonValidationOptions` 的变量返回 `string` identity。默认 `checkId` 是 `json-validation`,默认 `displayName` 是 `JSON validation`;`files` 与
13
+ `maximumBytes` 仍是本 Check 的领域 options。
14
+
15
+ 例如,用明确的项目 identity 和展示名只检查配置文件:
16
+
17
+ ```ts
18
+ const configJson = jsonValidation({
19
+ checkId: "config-json",
20
+ displayName: "Configuration JSON",
21
+ files: { include: ["config/**/*.json"] }
22
+ });
23
+ ```
24
+
25
+ 返回值仍是原生 typed Check。项目声明字段不会进入 `.options` 或执行时的 `context.options`;
26
+ 完整字段集合、投影和校验边界见[API 机制](../api-mechanics.md#随包-check-的构造器项目声明)。
27
+
8
28
  ## 最小用法
9
29
 
10
30
  示例保留终端进度,不写 machine files。
@@ -26,8 +46,7 @@ if (result.kind !== "completed" || outcome?.status !== "passed") {
26
46
  }
27
47
  ```
28
48
 
29
- 本例只接受 `completed` Run 中的 `passed` Check,否则退出非零。若需接受 `not-applicable` 或聚合多个 Check,
30
- 显式配置并读取 [`checkAggregation`](../api-mechanics.md#runcontrols-与-check-aggregation);`run(...)` 返回本身不表示通过。
49
+ 本例只接受 `completed` Run 中的 `passed` Check,否则退出非零。多个有效 Check 的调用级结论可读取默认严格 `aggregate`;需要不同领域解释时,提供同步 [`checkAggregation`](../api-mechanics.md#runcontrols-与-check-aggregation) 函数。`run(...)` 返回本身不表示通过。
31
50
 
32
51
  ## 参数与默认配置
33
52
 
@@ -63,7 +82,7 @@ const configJsonValidation = jsonValidation({
63
82
 
64
83
  ## 工作原理
65
84
 
66
- constructor 补齐并冻结 closed options,获 Scheduler admission 后先 preflight,再按本页 suffix 规则完整分类输入。
85
+ constructor 补齐并冻结 closed options,获 Scheduler admission 后先 preparation,再按本页 suffix 规则完整分类输入。
67
86
  每个 rejected path 先发布 Record;accepted path 才读取、解析,无效文档另发 Record。
68
87
 
69
88
  strict-document boundary 先按 byte length 应用 `maximumBytes`,再依次区分 BOM、fatal UTF-8、strict JSON grammar 与 decoded
@@ -132,8 +151,8 @@ Records 与 warning 的 `passed` 结算。`unavailable.reason.code` 只使用以
132
151
  | `execution-cancelled` | invocation signal 在可观察工作边界取消本 Check | 检查调用方取消原因,不把结果解释为 clean validation |
133
152
 
134
153
  后续文件导致 `unavailable` 时,分类阶段的 rejected-input Records 与先前已接受的 invalid-file Records 均保留,但本 Check
135
- 不提供 final data;对应 rejection warning 也随 terminal error message 一起保留。通用 preflight 语法见
136
- [options preflight 与 execution](../api-mechanics.md#options-preflight-与-execution)。
154
+ 不提供 final data;对应 rejection warning 也随 terminal error message 一起保留。通用 preparation 语法见
155
+ [options preparation 与 execution](../api-mechanics.md#options-preparation-与-execution)。
137
156
 
138
157
  ## I/O 与安全边界
139
158
 
@@ -4,6 +4,32 @@
4
4
 
5
5
  `maintenanceReminders(entries)` 创建固定 ID 为 `maintenance-reminders` 的 Check,用 Git first-parent history 提醒定期复核。
6
6
 
7
+ ## 构造器项目声明
8
+
9
+ `maintenanceReminders` 保留 `maintenanceReminders(entries)`,并为 object input 提供三类 overload:
10
+ `MaintenanceRemindersInput<"maintenance-reminders">` 保留默认 literal;带必填
11
+ `{ checkId: Id }` 的 `MaintenanceRemindersInput<Id>` 保留 custom literal;宽化为
12
+ `MaintenanceRemindersInput` 的变量返回 `string` identity。默认 `checkId` 是 `maintenance-reminders`,默认
13
+ `displayName` 是 `Maintenance reminders`;`entries` 是唯一领域 policy,object input 的其余顶层字段用于项目声明。
14
+
15
+ 例如,为需要单独选择的提醒设置 identity 与 flag 条件:
16
+
17
+ ```ts
18
+ const dependencyReview = maintenanceReminders({
19
+ checkId: "dependency-review",
20
+ enabledByFlags: { when: "dependencies-changed" },
21
+ entries: [{
22
+ id: "dependencies",
23
+ baseCommit: "0123456789abcdef0123456789abcdef01234567",
24
+ limits: { commits: 40 },
25
+ message: "Review dependency updates."
26
+ }]
27
+ });
28
+ ```
29
+
30
+ 两种调用形式都返回原生 typed Check。项目声明字段不会进入 `.options` 或执行时的 `context.options`;
31
+ 完整字段集合、投影和校验边界见[API 机制](../api-mechanics.md#随包-check-的构造器项目声明)。
32
+
7
33
  ## 最小用法
8
34
 
9
35
  示例保留终端进度,不写 machine files。
@@ -35,8 +61,7 @@ if (result.kind !== "completed" || outcome?.status !== "passed") {
35
61
  将占位 commit ID 换成项目 first-parent history 中的真实复核 commit;不存在的基线产生条目 `unavailable`。
36
62
  示例使用 `enforcing`,会因到期或不可测量失败;默认 `advisory` 只提醒。
37
63
 
38
- 本例只接受 `completed` Run 中的 `passed` Check,否则退出非零。若需接受 `not-applicable` 或聚合多个 Check,
39
- 显式配置并读取 [`checkAggregation`](../api-mechanics.md#runcontrols-与-check-aggregation);`run(...)` 返回本身不表示通过。
64
+ 本例只接受 `completed` Run 中的 `passed` Check,否则退出非零。多个有效 Check 的调用级结论可读取默认严格 `aggregate`;需要不同领域解释时,提供同步 [`checkAggregation`](../api-mechanics.md#runcontrols-与-check-aggregation) 函数。`run(...)` 返回本身不表示通过。
40
65
 
41
66
  ## 参数与默认配置
42
67
 
@@ -62,7 +87,7 @@ ReadonlyArray<{
62
87
  - `mode` 省略时为 `advisory`;`enforcing` 使到期或不可测量的条目令所属 Check 失败。
63
88
 
64
89
  constructor 把输入固定为完整 options `{ entries, git: { executable: "git" } }`。所属 Check 获 Scheduler admission 后,其 task-local
65
- preflight 在自身 execution 前验证 unknown、sparse、duplicate 或 malformed entries;失败时当前 Check 以
90
+ preparation 在自身 execution 前验证 unknown、sparse、duplicate 或 malformed entries;失败时当前 Check 以
66
91
  `unavailable / invalid-options` 结算。
67
92
 
68
93
  ## 工作原理
@@ -157,7 +182,7 @@ Git/历史测量的普通失败会保留完整 final data,并把受影响条
157
182
  每个 whole-Check `unavailable` 都携带与 `reason.code` 相同 code 的 error message,并指出应恢复 options、检查取消原因或
158
183
  检查 package/runtime integrity。entry-level `unavailable` 仍按上一节保留 final data 与项目编写的提醒正文。
159
184
 
160
- 通用 preflight 语法见 [options preflight 与 execution](../api-mechanics.md#options-preflight-与-execution)。
185
+ 通用 preparation 语法见 [options preparation 与 execution](../api-mechanics.md#options-preparation-与-execution)。
161
186
 
162
187
  ## I/O 与安全边界
163
188
 
@@ -166,5 +191,4 @@ request 数为零,baseline 更新由维护者提交。
166
191
 
167
192
  ## 适用边界
168
193
 
169
- 该 Check 适用于按 commit count 或 changed-line count 提醒维护复核。是否把 `enforcing` failure 转为调用级阻断,
170
- 由 `RunControls.checkAggregation` policy 决定。
194
+ 该 Check 适用于按 commit count 或 changed-line count 提醒维护复核。有效的 `enforcing` failure 会使默认严格 `aggregate` 为 `failed`;调用方负责把该调用级结论映射为自己的阻断或退出行为。只有需要不同领域解释时,才提供 `RunControls.checkAggregation` 同步函数。
@@ -4,6 +4,27 @@
4
4
 
5
5
  `markdownLinkValidation(options?)` 构造普通 Check,离线验证所选 Markdown 中的本机链接、图片目标与标题锚点。
6
6
 
7
+ ## 构造器项目声明
8
+
9
+ `markdownLinkValidation` 有三类 overload:
10
+ `markdownLinkValidation(options?: MarkdownLinkValidationOptions<"markdown-link-validation">)` 保留默认 literal;
11
+ `markdownLinkValidation<Id>(options: MarkdownLinkValidationOptions<Id> & { checkId: Id })` 保留 custom literal;
12
+ 已宽化为 `MarkdownLinkValidationOptions` 的变量返回 `string` identity。默认 `checkId` 是 `markdown-link-validation`,默认 `displayName` 是 `Markdown link validation`;`files`、
13
+ `findingPolicy`、target policy、`cache` 与 `limits` 仍是本 Check 的领域 options。
14
+
15
+ 例如,让文档链接检查观察生成文档并使用独立 identity:
16
+
17
+ ```ts
18
+ const docsLinks = markdownLinkValidation({
19
+ checkId: "documentation-links",
20
+ observes: ["generate-docs"],
21
+ files: { include: ["docs/**/*.md"] }
22
+ });
23
+ ```
24
+
25
+ 返回值仍是原生 typed Check。项目声明字段不会进入 `.options` 或执行时的 `context.options`;
26
+ 完整字段集合、投影和校验边界见[API 机制](../api-mechanics.md#随包-check-的构造器项目声明)。
27
+
7
28
  ## 最小用法
8
29
 
9
30
  示例保留终端进度,不写 machine files。
@@ -27,8 +48,7 @@ if (result.kind !== "completed" || outcome?.status !== "passed") {
27
48
 
28
49
  示例显式使用 `findingPolicy: "blocking"`,让普通链接 Finding 导致失败;默认 `non-blocking` 只警告,不因 Finding 退出非零。
29
50
 
30
- 本例只接受 `completed` Run 中的 `passed` Check,否则退出非零。若需接受 `not-applicable` 或聚合多个 Check,
31
- 显式配置并读取 [`checkAggregation`](../api-mechanics.md#runcontrols-与-check-aggregation);`run(...)` 返回本身不表示通过。
51
+ 本例只接受 `completed` Run 中的 `passed` Check,否则退出非零。多个有效 Check 的调用级结论可读取默认严格 `aggregate`;需要不同领域解释时,提供同步 [`checkAggregation`](../api-mechanics.md#runcontrols-与-check-aggregation) 函数。`run(...)` 返回本身不表示通过。
32
52
 
33
53
  ## 参数与默认配置
34
54
 
@@ -203,8 +223,8 @@ selected path 数量为零时结算为 `not-applicable / no-eligible-input`。se
203
223
  | `cancelled` | invocation signal 取消本 Check;不要把结果解释为 clean validation。 |
204
224
 
205
225
  这些边界不发布 partial link-finding Records,也不提供 final data;若 selected classification 已完成,已发布的
206
- rejected-input Records 与对应 warning 仍保留。通用 preflight 语法见
207
- [options preflight 与 execution](../api-mechanics.md#options-preflight-与-execution)。
226
+ rejected-input Records 与对应 warning 仍保留。通用 preparation 语法见
227
+ [options preparation 与 execution](../api-mechanics.md#options-preparation-与-execution)。
208
228
 
209
229
  ## I/O 与安全边界
210
230
 
@@ -0,0 +1,167 @@
1
+ # `markdownLint`
2
+
3
+ ## 用途与组合
4
+
5
+ `markdownLint(options?)` 是 package 提供的 ordinary Check,用于检查已选择 Markdown source 的结构和明确内容缺陷。它的公共契约由本页完整定义;`files` 的共同选择语义见[选择与收集项目文件](../guides/collecting-project-files.md)。
6
+
7
+ 它与 [`markdownLinkValidation`](./markdown-link-validation.md) 分工互补:`markdownLint` 检查本页列出的结构与内容规则;`markdownLinkValidation` 检查本地 link target 与 anchor 完整性。需要两类 evidence 时,将两个 Check 一起放入 `checks`;`link-fragments` 默认不启用,避免默认产生与链接 Check 重复的 same-document anchor evidence。
8
+
9
+ ## 构造器项目声明
10
+
11
+ `markdownLint` 有三类 overload:`markdownLint(options?: MarkdownLintOptions<"markdown-lint">)` 保留默认 literal;
12
+ `markdownLint<Id>(options: MarkdownLintOptions<Id> & { checkId: Id })` 保留 custom literal;已宽化为
13
+ `MarkdownLintOptions` 的变量返回 `string` identity。默认 `checkId` 是 `markdown-lint`,默认 `displayName` 是 `Markdown lint`。
14
+ `files`、`findingPolicy`、`findingWaivers`、`rules`、`limits` 与 `cache` 是本 Check 的领域 options,不属于项目展示字段。
15
+
16
+ 例如,为文档 lint 声明项目展示和进度呈现策略:
17
+
18
+ ```ts
19
+ const documentationLint = markdownLint({
20
+ checkId: "documentation-lint",
21
+ displayName: "Documentation lint",
22
+ omitQuietPassedRow: true,
23
+ files: { include: ["docs/**/*.md"] }
24
+ });
25
+ ```
26
+
27
+ 返回值仍是原生 typed Check。项目声明字段不会进入 `.options` 或执行时的 `context.options`;
28
+ 完整字段集合、投影和校验边界见[API 机制](../api-mechanics.md#随包-check-的构造器项目声明)。
29
+
30
+ ## 参数与默认配置
31
+
32
+ `markdownLint` 只接受以下闭合 options。未知字段、未知或重复规则、空规则数组,以及不是正安全整数或超过上限的 limit,会在构造 Check 时以 `TypeError` 拒绝。
33
+
34
+ | 字段 | 默认值 | 契约 |
35
+ | --- | --- | --- |
36
+ | `files` | 选择大小写不敏感的 `.md` 与 `.markdown` 路径 | 通过 project-file selection 指定本次 source 范围。|
37
+ | `findingPolicy` | `"non-blocking"` | lint Finding 保留为 evidence;设为 `"blocking"` 时,有未豁免 lint Finding 的 Check 结算为 `failed`。|
38
+ | `findingWaivers` | `[]` | 带非空理由的精确 Finding 例外;完整 lint 后对账,不删除 Finding。见下方精确豁免边界。|
39
+ | `rules` | 下表八项默认规则 | 省略时使用默认集;提供非空数组时完整替换默认集。数组只可含下表九个名称,resolved 顺序固定为 Product catalog 顺序。|
40
+ | `limits.maxMarkdownBytes` | `1_048_576`,最大 `16_777_216` | 单个 source 的 UTF-8 字节上限。|
41
+ | `limits.maxFindings` | `10_000`,最大 `100_000` | 整次 execution 可形成的 lint Finding 上限。|
42
+ | `cache` | `{ enabled: false }` | 显式启用时为 `{ enabled: true, directory }`;directory 必须是调用方拥有的绝对路径。见下方缓存边界。|
43
+
44
+ ### 规则 catalog
45
+
46
+ | Public rule | 默认启用 | 报告的缺陷 |
47
+ | --- | --- | --- |
48
+ | `heading-increment` | 是 | 标题层级一次增加超过一级。|
49
+ | `no-reversed-links` | 是 | 反向 `()[]` link 语法。|
50
+ | `no-missing-space-atx` | 是 | ATX heading marker 后缺少空格。|
51
+ | `fenced-code-language` | 是 | fenced code block 缺少语言。|
52
+ | `no-empty-links` | 是 | link destination 或 fragment 为空。|
53
+ | `no-alt-text` | 是 | Markdown image 缺少 alt text。|
54
+ | `link-fragments` | 否;仅显式选择 | same-document fragment 未匹配标题。|
55
+ | `reference-links-images` | 是 | full/collapsed reference link 或 image 缺少 definition。|
56
+ | `table-column-count` | 是 | GFM pipe table 的行列数不一致。|
57
+
58
+ backend 规则名、preset、rule object、rule 参数、parser plugin 和自动修复不是公共配置。
59
+
60
+ ## 工作原理
61
+
62
+ 每次 execution 只收集一次 `files` 选中的路径并稳定排序。选中但后缀不是 `.md` 或 `.markdown` 的路径不会读取内容,而是各发布一条 non-blocking `input-rejected / unsupported-file-type` Record。accepted source 必须位于 project root 内、是 regular file、可作为 UTF-8 读取且不超过 `maxMarkdownBytes`;Check 按路径顺序逐文件执行,并在文件前后响应取消。
63
+
64
+ 私有 adapter 使用随包固定的 `markdownlint@0.41.1` Promise `strings` API,只接收已读取的 source text,不接收项目路径或文件系统权限。inline config 固定禁用;文件开头的 YAML、TOML 和 JSON front matter 受支持。pipe table、HTML comment 与未支持扩展的识别以该固定 backend 版本的实际行为为准,不承诺与任意 Markdown renderer 等价。
65
+
66
+ ### 逐文件 findings 缓存
67
+
68
+ 缓存默认关闭,不访问缓存目录。显式启用后,每次 execution 仍完成以下工作:
69
+
70
+ 1. 按当前 `files` 选择路径,确认每份 source 位于 project root 内、符合大小限制,并读取、解码当前 UTF-8 内容。
71
+ 2. 对未变化的 source 复用已验证的逐文件 findings;内容、所选规则或 backend 版本变化时重新 lint。缓存身份还包含 source path 与内部 adapter 契约版本。
72
+ 3. 根据本次完整遍历结算 Finding 总量限制、记录顺序、Finding policy、Records、消息与终态。缓存命中不复用 Check outcome。
73
+
74
+ 只有成功计算的 findings 可写入缓存。损坏或不可用的缓存会重新计算,不会被视为空结果;取消、source 读取失败、backend 失败及超限仍按原有终态结算。adapter 的规则配置或 finding 解释变化时,维护者必须提升内部缓存契约版本。
75
+
76
+ 缓存目录由调用方指定,保存由 source 派生的 findings 和 identity 摘要,不保存原文。调用方应使用可信、可删除的绝对目录并管理容量;该目录不提供防篡改、机密性或自动清理保证。
77
+
78
+ ### 精确 Finding waiver
79
+
80
+ `findingWaivers` 是闭合的 `{ identity, reason }` 数组;每项 identity 只包含公开 `lint-finding` Record data 的 `path`、`rule`、`range`。复核一条 Finding 后,完整复制这三个字段并填写非空 reason,不解析 Record ID,也不要自动把全部新 Finding 转成 waiver。[配置示例](../guides/finding-waivers.md#为-markdown-lint-声明精确例外)展示同一 authoring。
81
+
82
+ - `path` 是规范 project-relative `/` 路径,不解释 glob;`rule` 必须是本页 catalog 中的公共规则名。
83
+ - `range` 只含 `start`、`end`,两者只含正安全整数 `line`、`column`;两端同行,end column 不小于 start column。使用完整的一基 UTF-16 range,包括 end-exclusive 的 end;point range 的两端相等。
84
+ - 类型为 `MarkdownLintFindingIdentity` 与 `MarkdownLintFindingWaiver`。未知字段、非法位置、空 reason、重复 identity、稀疏数组或 accessor 配置在构造 Check 时以 `TypeError` 拒绝;合法配置被独立、递归冻结地快照。
85
+
86
+ 每次完成全部 source traversal 后,Check 使用[通用 reconciliation](../guides/finding-waivers.md#identity-与-audit)按完整 identity 对账:
87
+
88
+ | 匹配次数 | Finding 与 audit | 结算影响 |
89
+ | --- | --- | --- |
90
+ | 恰好一条 | 原 Finding 保留原 id、位置与规则,增加 `waiver: { reason }`,并发布 `finding-waived` 信息消息。 | 该 Finding 不再阻断。 |
91
+ | 零条 | 发布 `finding-waiver-audit / unused` Record 与 warning。 | 不豁免其它 Finding;audit 本身不阻断。 |
92
+ | 多条 | 发布 `finding-waiver-audit / overmatched` Record 与 warning,所有匹配 Finding 均保留。 | 所有匹配 Finding 继续接受原 findingPolicy 判断。 |
93
+
94
+ audit Record data 包含 `kind: "finding-waiver-audit"`、`identity`、`reason`、`matchCount` 与 `status: "unused" | "overmatched"`,其类型为 `MarkdownLintFindingWaiverAuditRecordData`。不为 applied 另发 audit Record,因为原 Finding 上已有 waiver evidence。
95
+
96
+ 完全相同位置、规则和路径的多条 Finding 不会按 ordinal 任挑一条豁免;不同 end range 则是不同 identity。编辑导致路径或位置漂移时,旧 waiver 会变为 unused,应人工更新或删除。reason 会进入公开 Records 和消息,不得包含秘密或敏感原文。
97
+
98
+ waiver 不改变文件选择、规则、source 读取、`maxFindings` 或缓存 facts:所有原始 Finding 仍计入上限,每次 cache hit 后也按当前 waiver 重新结算。rejected input、source/backend 失败、超限和取消不可豁免;没有 selected path 时继续 N/A,不对账;无法取得完整 lint 时不发布 partial lint 或 waiver audit。省略或传入空数组保持既有输出。
99
+
100
+ ## I/O 与安全边界
101
+
102
+ Check 不读取 backend 配置文件,不访问网络,不读取 project root 外的 source;默认不写入项目,显式启用缓存时只写调用方指定的缓存目录。调用方通过 `files` 决定 source 范围。
103
+
104
+ ## 效果与结果
105
+
106
+ 成功 execution 的 lint Record 为:
107
+
108
+ ```ts
109
+ {
110
+ kind: "lint-finding",
111
+ path,
112
+ rule,
113
+ range: { start: { line, column }, end: { line, column } }
114
+ }
115
+ ```
116
+
117
+ 应用精确 waiver 的 lint Record 还包含 `waiver: { reason }`;未豁免时不增加该字段。unused/overmatched audit 见上节,`MarkdownLintRecordData` 同时覆盖 lint、input-rejected 和 waiver-audit 三种 Record。
118
+
119
+ `path` 是 project-relative path。`range` 使用一基 UTF-16 line/column,end 是同一行 end-exclusive position;backend 未提供 range 时使用该行 column 1 的 point range。普通 lint 诊断消息只包含 Product-owned path、position、public rule 与固定摘要,不泄漏 backend message、context、source、fix、URL 或异常;waiver 消息另含调用方显式提供的 reason,其公开边界见上方精确豁免说明。
120
+
121
+ 成功 execution 的 final data 为 `{ sourceFileCount, findingCount, rejectedInputCount }`:`sourceFileCount` 是成功 lint 的 accepted source 数量;`findingCount` 是全部 lint Findings(包括已豁免项)与 rejected inputs 的合计,因而不小于 `rejectedInputCount`。audit 不计入 findingCount,该计数不代表阻断数;通过 lint Record 上的 waiver evidence 区分已豁免项。
122
+
123
+ 用返回 Check 的 `check.parseData(value)` 或 package root 的 `parseMarkdownLintData(value)` 验证 `passed` / `failed` outcome 的 final data。两者返回 `MarkdownLintFinalData`;Record 和不可用原因可分别用 `MarkdownLintRecordData` 与 `MarkdownLintUnavailableReason` 标注,authoring / resolved options types 是 `MarkdownLintOptions` 与 `ResolvedMarkdownLintOptions`。parser 要求完整且无额外字段、计数为非负安全整数,并验证 `findingCount >= rejectedInputCount`;不匹配时抛出 `TypeError`。`not-applicable` 与 `unavailable` 不提供可解析的 final data。
124
+
125
+ | 条件 | 结算 | 发布内容 |
126
+ | --- | --- | --- |
127
+ | 没有 selected path | `not-applicable / no-eligible-input` | 不发布 final data。|
128
+ | 全部 selected path 被后缀资格拒绝 | `passed` | rejected-input Records、可能的 unused waiver audit、warning 和 final data。|
129
+ | 无 lint Finding | `passed` | final data,以及已配置但未命中的 waiver audit。|
130
+ | 有 lint Finding 且 `findingPolicy: "non-blocking"` | `passed` | 全部 lint Records、waiver evidence/audit、消息和 final data。|
131
+ | 有未豁免 lint Finding 且 `findingPolicy: "blocking"` | `failed` | 全部 lint Records、waiver evidence/audit、消息和 final data。|
132
+ | 全部 lint Finding 已豁免 | `passed` | 全部 lint Records 及 waiver evidence、消息和 final data。|
133
+ | root、source、limit、backend、协议或取消阻止完整结果 | `unavailable` | 不发布 final data 或 partial lint Findings;已完成资格分类的 rejected-input Records 与 warning 保留。|
134
+
135
+ ## `not-applicable` 与 `unavailable`
136
+
137
+ `unavailable` 的稳定 reason code 是 `invalid-options`、`project-root-unavailable`、`source-unavailable`、`source-too-large`、`finding-limit-exceeded`、`backend-failed`、`backend-protocol-invalid` 或 `cancelled`。其中 `source-unavailable` 包含 selection、containment、读取或 UTF-8 decode 无法完成的情形。
138
+
139
+ ## 最小用法
140
+
141
+ ```ts
142
+ import { defineConfig, markdownLint, run } from "@zxyycom/vibe-check";
143
+
144
+ const check = markdownLint({ findingPolicy: "blocking" });
145
+ const definition = defineConfig({
146
+ checks: [check],
147
+ outputs: {
148
+ diagnosticLogging: { enabled: false },
149
+ machinePublication: { enabled: false },
150
+ progressRendering: { enabled: false }
151
+ }
152
+ });
153
+
154
+ const result = await run(definition);
155
+ if (result.kind !== "completed") throw new Error(`Run did not complete: ${result.kind}`);
156
+ const outcome = result.snapshot.checks.find(({ checkId }) => checkId === check.checkId)?.outcome;
157
+ if (outcome?.status !== "passed" && outcome?.status !== "not-applicable") {
158
+ throw new Error(`Markdown lint did not pass: ${outcome?.status ?? "no outcome"}`);
159
+ }
160
+ if (outcome.status === "not-applicable") console.warn("No Markdown input selected; no lint evidence.");
161
+ ```
162
+
163
+ 本例对 blocking Finding 和其它 Check 失败退出非零;`not-applicable` 仅表示没有可检查的 Markdown,不是 lint 通过的证据。默认严格 `aggregate` 会把有效的 `not-applicable` 结论为 `failed`,调用方可将其映射为 Gate 失败;需要不同领域解释时才提供同步 `checkAggregation` 函数。仅有 `RunResult.kind === "completed"` 不代表 Check 通过。
164
+
165
+ ## 适用边界
166
+
167
+ 本 Check 的 package 默认仍为 advisory,缓存默认关闭。Project Gate 以独立的 `markdown-lint` identity 使用八项默认规则、完整 `docs/**/*.md` 与 `changes/**/*.md` corpus,以及 non-blocking Finding policy。required 在 Markdown 文档或其实现输入变更时运行;`--materials`、`--quality`、`--all` 可强制运行。Gate 显式使用 `.cache/vibe-check/markdown-lint-findings/` 复用逐文件 findings,不缩小检查范围或改变 consumer 默认值;独立的 Markdown link validation 仍负责链接目标完整性。
@@ -4,6 +4,26 @@
4
4
 
5
5
  `secretDetection({ files })` 是随包 ordinary Check,发现高置信 PEM private-key material。它不是全面 credential protection,也不验证 secret 有效性。
6
6
 
7
+ ## 构造器项目声明
8
+
9
+ `secretDetection` 有三类 overload:`secretDetection(options: SecretDetectionOptions<"secret-detection">)`
10
+ 保留默认 literal;`secretDetection<Id>(options: SecretDetectionOptions<Id> & { checkId: Id })` 保留 custom literal;
11
+ 已宽化为 `SecretDetectionOptions` 的变量返回 `string` identity。默认 `checkId` 是 `secret-detection`,默认 `displayName` 是 `Secret detection`;必填 `files` 以及
12
+ `maximumFileBytes`、`maximumTotalBytes`、`maximumFileCount` 与 `findingWaivers` 仍是本 Check 的领域 options。
13
+
14
+ 例如,按变化选择一个只覆盖部署配置的独立 secret Check:
15
+
16
+ ```ts
17
+ const deploymentSecrets = secretDetection({
18
+ checkId: "deployment-secrets",
19
+ enabledByFlags: { when: "deployment-changed" },
20
+ files: { source: "filesystem", include: ["deploy/**/*"], exclude: [] }
21
+ });
22
+ ```
23
+
24
+ 返回值仍是原生 typed Check。项目声明字段不会进入 `.options` 或执行时的 `context.options`;
25
+ 完整字段集合、投影和校验边界见[API 机制](../api-mechanics.md#随包-check-的构造器项目声明)。
26
+
7
27
  ## 最小用法
8
28
 
9
29
  示例保留终端进度,不写 machine files。
@@ -27,8 +47,7 @@ if (result.kind !== "completed" || outcome?.status !== "passed") {
27
47
  }
28
48
  ```
29
49
 
30
- 本例只接受 `completed` Run 中的 `passed` Check,否则退出非零。若需接受 `not-applicable` 或聚合多个 Check,
31
- 显式配置并读取 [`checkAggregation`](../api-mechanics.md#runcontrols-与-check-aggregation);`run(...)` 返回本身不表示通过。
50
+ 本例只接受 `completed` Run 中的 `passed` Check,否则退出非零。多个有效 Check 的调用级结论可读取默认严格 `aggregate`;需要不同领域解释时,提供同步 [`checkAggregation`](../api-mechanics.md#runcontrols-与-check-aggregation) 函数。`run(...)` 返回本身不表示通过。
32
51
 
33
52
  ## 参数与默认配置
34
53
 
@@ -51,8 +70,10 @@ options 不接受 arbitrary regex、command、baseline、detector allowlist 或
51
70
  ## 工作原理
52
71
 
53
72
  1. 按显式 `files` 收集 exact project-relative paths,先应用文件数限制。
54
- 2. 在本仓库验证的 POSIX Node runtime 中,以 `O_NOFOLLOW` 打开 final leaf;在同一 descriptor 上检查 regular-file、size,
55
- 并在单文件/剩余总预算内分块读取。未满足安全读取条件的路径不获 detector coverage。
73
+ 2. 在受支持 POSIX runtime 中,先用 `lstat` 取得 final leaf 的 regular-file 身份,再以 `O_NOFOLLOW` 打开 descriptor,
74
+ 并要求 descriptor 的 device/inode 身份与路径身份一致。随后在同一 descriptor 上检查 size,并在单文件/剩余总预算内
75
+ 分块读取。symlink、无可靠文件身份或身份在打开前变化的路径不获 detector coverage。Windows 分支会以 read-only flag
76
+ 尝试同一身份握手,避免仅因平台缺少 `O_NOFOLLOW` 就预先拒绝普通文件;这是 portability optimization,不扩展受支持平台契约。
56
77
  3. 成功读取后检查 NUL 与 fatal UTF-8,只有 approved text 交给 private adapter;它不接收 project root,也不重新枚举文件。
57
78
 
58
79
  adapter 固定使用 [Secretlint v13.0.5](https://github.com/secretlint/secretlint/releases/tag/v13.0.5) 中 MIT-licensed 的
@@ -112,7 +133,8 @@ const check = secretDetection({
112
133
 
113
134
  - NUL、invalid UTF-8、单文件/总 bytes/文件数超限是 deterministic `coverage-gap`,使 Check `failed`。
114
135
  成功 descriptor read 的 raw bytes 先消耗总预算,即使随后成为 non-text gap。
115
- - symlink、非 regular file、read/change failure 或 runtime 不支持 `O_NOFOLLOW` descriptor open:`source-unavailable`。
136
+ - symlink、非 regular file、无法取得可靠 device/inode 身份、open 前身份变化、POSIX 不支持 `O_NOFOLLOW` 或 read/change
137
+ failure:`source-unavailable`。
116
138
  - whole-Check `unavailable` 的 closed reasons 为 `invalid-options`、`scan-input-unavailable`、`source-unavailable`、
117
139
  `detector-unavailable`、`detector-protocol-failed`、`execution-cancelled`。它们附同 code 的 error message,无 final data 或 partial result。
118
140
 
@@ -121,8 +143,10 @@ const check = secretDetection({
121
143
  I/O 只限 files 选择的 local paths;无 command、network、history、environment、home、binary 或 remote secret-manager I/O。
122
144
  raw detector material 不进入 result、Record、message、machine output、cache、log 或 error。
123
145
 
124
- POSIX no-follow 只绑定 final leaf;Node 没有 portable `openat`/dirfd traversal,无法保证中间目录或已打开 inode 不被恶意并发替换。
125
- 需要该隔离级别时,调用方须使用 OS-level sandbox。
146
+ 这些检查只绑定 final leaf;Node 没有 portable `openat`/dirfd traversal,无法保证中间目录不被恶意并发替换,也无法排除
147
+ 已打开 inode 的同长度并发写入。Windows portability branch 未经本次原生 Windows 文件系统验证;路径若在 `lstat` 后被换为
148
+ redirection,底层 open 可能取得目标 descriptor,但身份不匹配时不会读取或交给 detector。需要已承诺的 POSIX 边界之外的
149
+ 平台保证或更强隔离时,调用方须自行验证目标 runtime,并使用 OS-level sandbox。
126
150
 
127
151
  ## 适用边界
128
152
 
@@ -12,7 +12,7 @@ const packageManifest = jsonValidation({
12
12
  files: { include: ["package.json"] }
13
13
  });
14
14
 
15
- // 一个 typed provider:preflight 用 fallback 准备 invocation-local options。
15
+ // 一个 typed provider:preparation 用 fallback 准备 invocation-local options。
16
16
  const releaseInputs = defineCheck({
17
17
  checkId: "example-release-inputs",
18
18
  displayName: "Example release inputs",
@@ -29,7 +29,7 @@ const releaseInputs = defineCheck({
29
29
  }
30
30
  return { files: [...files], version: 1 };
31
31
  },
32
- preflight(options) {
32
+ prepare(options) {
33
33
  if (options.files.length > 0) {
34
34
  return { status: "success", preparedOptions: options };
35
35
  }
@@ -47,8 +47,8 @@ const releaseInputs = defineCheck({
47
47
  ]
48
48
  };
49
49
  },
50
- visibility: "attention",
51
- execution({ options, signal }) {
50
+ omitQuietPassedRow: true,
51
+ execute({ options, signal }) {
52
52
  if (signal.aborted) {
53
53
  return { status: "unavailable", reason: { code: "execution-cancelled" } };
54
54
  }
@@ -65,8 +65,8 @@ const releasePolicy = defineCheck({
65
65
  displayName: "Example release policy",
66
66
  observes: inherit({ add: [releaseInputs.checkId] }),
67
67
  options: { minimumFileCount: 2 },
68
- visibility: "attention",
69
- execution({ dependencies, options, records }) {
68
+ omitQuietPassedRow: true,
69
+ execute({ dependencies, options, records }) {
70
70
  const manifestRead = dependencies.get(packageManifest.checkId);
71
71
  if (!manifestRead.ok) {
72
72
  return {
@@ -145,18 +145,18 @@ const optionalDocumentation = defineCheck({
145
145
  checkId: "example-optional-documentation",
146
146
  displayName: "Example optional documentation",
147
147
  options: { enabled: false },
148
- execution: ({ options }) =>
148
+ execute: ({ options }) =>
149
149
  options.enabled
150
150
  ? { status: "passed", data: { reviewed: true } }
151
151
  : { status: "not-applicable", reason: { code: "documentation-disabled" } }
152
152
  });
153
153
 
154
- // block preflight 只阻止本 Check 的 execution,并将其结算为 unavailable;不相关的 Check 仍可并行。
154
+ // block preparation 只阻止本 Check 的 execution,并将其结算为 unavailable;不相关的 Check 仍可并行。
155
155
  const externalReview = defineCheck({
156
156
  checkId: "example-external-review",
157
157
  displayName: "Example external review",
158
158
  options: { serviceConfigured: false },
159
- preflight(options) {
159
+ prepare(options) {
160
160
  if (options.serviceConfigured) {
161
161
  return { status: "success", preparedOptions: options };
162
162
  }
@@ -173,7 +173,7 @@ const externalReview = defineCheck({
173
173
  ]
174
174
  };
175
175
  },
176
- execution: () => ({ status: "passed", data: { reviewed: true } })
176
+ execute: () => ({ status: "passed", data: { reviewed: true } })
177
177
  });
178
178
 
179
179
  // 组织节点自身不产生 outcome;children 继承 packageManifest observation 和并行预算。