@agentxm/client-core 0.1.6 → 0.3.1

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 (500) hide show
  1. package/dist/src/unstable/agents/coding-agent.d.ts +1 -1
  2. package/dist/src/unstable/agents/coding-agent.d.ts.map +1 -1
  3. package/dist/src/unstable/agents/coding-agent.js +1 -1
  4. package/dist/src/unstable/agents/coding-agent.js.map +1 -1
  5. package/dist/src/unstable/auth/auth-client.d.ts +1 -1
  6. package/dist/src/unstable/auth/auth-client.d.ts.map +1 -1
  7. package/dist/src/unstable/auth/auth-client.js +1 -1
  8. package/dist/src/unstable/auth/auth-client.js.map +1 -1
  9. package/dist/src/unstable/auth/credential-store.d.ts +1 -1
  10. package/dist/src/unstable/auth/credential-store.d.ts.map +1 -1
  11. package/dist/src/unstable/auth/credential-store.js +1 -1
  12. package/dist/src/unstable/auth/credential-store.js.map +1 -1
  13. package/dist/src/unstable/auth/device-login.d.ts +1 -1
  14. package/dist/src/unstable/auth/device-login.d.ts.map +1 -1
  15. package/dist/src/unstable/auth/device-login.js +1 -1
  16. package/dist/src/unstable/auth/device-login.js.map +1 -1
  17. package/dist/src/unstable/auth/guard-interaction.d.ts +1 -1
  18. package/dist/src/unstable/auth/guard-interaction.d.ts.map +1 -1
  19. package/dist/src/unstable/auth/guard-interaction.js +1 -1
  20. package/dist/src/unstable/auth/guard-interaction.js.map +1 -1
  21. package/dist/src/unstable/auth/login-interaction.d.ts +1 -1
  22. package/dist/src/unstable/auth/login-interaction.d.ts.map +1 -1
  23. package/dist/src/unstable/auth/login-interaction.js +1 -1
  24. package/dist/src/unstable/auth/login-interaction.js.map +1 -1
  25. package/dist/src/unstable/auth/registry-url.d.ts +1 -1
  26. package/dist/src/unstable/auth/registry-url.d.ts.map +1 -1
  27. package/dist/src/unstable/auth/registry-url.js +1 -1
  28. package/dist/src/unstable/auth/registry-url.js.map +1 -1
  29. package/dist/src/unstable/auth/schema.d.ts +3 -3
  30. package/dist/src/unstable/cli-flags/verbosity.d.ts +1 -1
  31. package/dist/src/unstable/cli-flags/verbosity.d.ts.map +1 -1
  32. package/dist/src/unstable/cli-flags/verbosity.js +1 -1
  33. package/dist/src/unstable/cli-flags/verbosity.js.map +1 -1
  34. package/dist/src/unstable/cli-renderer/cli-renderer.d.ts +1 -1
  35. package/dist/src/unstable/cli-renderer/cli-renderer.d.ts.map +1 -1
  36. package/dist/src/unstable/cli-renderer/cli-renderer.js +1 -1
  37. package/dist/src/unstable/cli-renderer/cli-renderer.js.map +1 -1
  38. package/dist/src/unstable/cli-runtime/command-argv.d.ts +1 -1
  39. package/dist/src/unstable/cli-runtime/command-argv.d.ts.map +1 -1
  40. package/dist/src/unstable/cli-runtime/command-argv.js +1 -1
  41. package/dist/src/unstable/cli-runtime/command-argv.js.map +1 -1
  42. package/dist/src/unstable/cli-runtime/graceful-shutdown.js +1 -1
  43. package/dist/src/unstable/cli-runtime/graceful-shutdown.js.map +1 -1
  44. package/dist/src/unstable/cli-runtime/telemetry.d.ts +1 -1
  45. package/dist/src/unstable/cli-runtime/telemetry.d.ts.map +1 -1
  46. package/dist/src/unstable/cli-runtime/telemetry.js +1 -1
  47. package/dist/src/unstable/cli-runtime/telemetry.js.map +1 -1
  48. package/dist/src/unstable/commands/manager.d.ts +1 -1
  49. package/dist/src/unstable/commands/manager.d.ts.map +1 -1
  50. package/dist/src/unstable/commands/manager.js +1 -1
  51. package/dist/src/unstable/commands/manager.js.map +1 -1
  52. package/dist/src/unstable/commands/operations/disable.d.ts +2 -2
  53. package/dist/src/unstable/commands/operations/disable.d.ts.map +1 -1
  54. package/dist/src/unstable/commands/operations/enable.d.ts +2 -2
  55. package/dist/src/unstable/commands/operations/enable.d.ts.map +1 -1
  56. package/dist/src/unstable/commands/operations/install.d.ts +1 -1
  57. package/dist/src/unstable/commands/operations/install.d.ts.map +1 -1
  58. package/dist/src/unstable/commands/operations/new-command.d.ts +2 -2
  59. package/dist/src/unstable/commands/operations/new-command.d.ts.map +1 -1
  60. package/dist/src/unstable/commands/operations/publish.d.ts +1 -1
  61. package/dist/src/unstable/commands/operations/publish.d.ts.map +1 -1
  62. package/dist/src/unstable/commands/operations/uninstall.d.ts +1 -1
  63. package/dist/src/unstable/commands/operations/uninstall.d.ts.map +1 -1
  64. package/dist/src/unstable/date-time.d.ts +2 -2
  65. package/dist/src/unstable/date-time.d.ts.map +1 -1
  66. package/dist/src/unstable/extensions/operations.d.ts +1 -1
  67. package/dist/src/unstable/extensions/operations.d.ts.map +1 -1
  68. package/dist/src/unstable/install-meta/install-meta.d.ts +1 -1
  69. package/dist/src/unstable/install-meta/install-meta.d.ts.map +1 -1
  70. package/dist/src/unstable/install-meta/install-meta.js +1 -1
  71. package/dist/src/unstable/install-meta/install-meta.js.map +1 -1
  72. package/dist/src/unstable/install-method/install-method.d.ts +1 -1
  73. package/dist/src/unstable/install-method/install-method.d.ts.map +1 -1
  74. package/dist/src/unstable/install-method/install-method.js +1 -1
  75. package/dist/src/unstable/install-method/install-method.js.map +1 -1
  76. package/dist/src/unstable/lint/catalog/index.d.ts +39 -0
  77. package/dist/src/unstable/lint/catalog/index.d.ts.map +1 -0
  78. package/dist/src/unstable/lint/catalog/index.js +49 -0
  79. package/dist/src/unstable/lint/catalog/index.js.map +1 -0
  80. package/dist/src/unstable/lint/catalog/pack/manifest-keys-recognized.d.ts +31 -0
  81. package/dist/src/unstable/lint/catalog/pack/manifest-keys-recognized.d.ts.map +1 -0
  82. package/dist/src/unstable/lint/catalog/pack/manifest-keys-recognized.js +41 -0
  83. package/dist/src/unstable/lint/catalog/pack/manifest-keys-recognized.js.map +1 -0
  84. package/dist/src/unstable/lint/catalog/pack/manifest-present.d.ts +18 -0
  85. package/dist/src/unstable/lint/catalog/pack/manifest-present.d.ts.map +1 -0
  86. package/dist/src/unstable/lint/catalog/pack/manifest-present.js +41 -0
  87. package/dist/src/unstable/lint/catalog/pack/manifest-present.js.map +1 -0
  88. package/dist/src/unstable/lint/catalog/pack/manifest-schema-valid.d.ts +26 -0
  89. package/dist/src/unstable/lint/catalog/pack/manifest-schema-valid.d.ts.map +1 -0
  90. package/dist/src/unstable/lint/catalog/pack/manifest-schema-valid.js +34 -0
  91. package/dist/src/unstable/lint/catalog/pack/manifest-schema-valid.js.map +1 -0
  92. package/dist/src/unstable/lint/catalog/pack-accessor/contexts.d.ts +61 -0
  93. package/dist/src/unstable/lint/catalog/pack-accessor/contexts.d.ts.map +1 -0
  94. package/dist/src/unstable/lint/catalog/pack-accessor/contexts.js +46 -0
  95. package/dist/src/unstable/lint/catalog/pack-accessor/contexts.js.map +1 -0
  96. package/dist/src/unstable/lint/catalog/pack-accessor/platform.d.ts +53 -0
  97. package/dist/src/unstable/lint/catalog/pack-accessor/platform.d.ts.map +1 -0
  98. package/dist/src/unstable/lint/catalog/pack-accessor/platform.js +90 -0
  99. package/dist/src/unstable/lint/catalog/pack-accessor/platform.js.map +1 -0
  100. package/dist/src/unstable/lint/catalog/pack-accessor/vft.d.ts +60 -0
  101. package/dist/src/unstable/lint/catalog/pack-accessor/vft.d.ts.map +1 -0
  102. package/dist/src/unstable/lint/catalog/pack-accessor/vft.js +85 -0
  103. package/dist/src/unstable/lint/catalog/pack-accessor/vft.js.map +1 -0
  104. package/dist/src/unstable/lint/catalog/pack.d.ts +37 -0
  105. package/dist/src/unstable/lint/catalog/pack.d.ts.map +1 -0
  106. package/dist/src/unstable/lint/catalog/pack.js +47 -0
  107. package/dist/src/unstable/lint/catalog/pack.js.map +1 -0
  108. package/dist/src/unstable/lint/catalog/shared/schema-rule.d.ts +59 -0
  109. package/dist/src/unstable/lint/catalog/shared/schema-rule.d.ts.map +1 -0
  110. package/dist/src/unstable/lint/catalog/shared/schema-rule.js +99 -0
  111. package/dist/src/unstable/lint/catalog/shared/schema-rule.js.map +1 -0
  112. package/dist/src/unstable/lint/catalog/skill/frontmatter-parseable.d.ts +31 -0
  113. package/dist/src/unstable/lint/catalog/skill/frontmatter-parseable.d.ts.map +1 -0
  114. package/dist/src/unstable/lint/catalog/skill/frontmatter-parseable.js +151 -0
  115. package/dist/src/unstable/lint/catalog/skill/frontmatter-parseable.js.map +1 -0
  116. package/dist/src/unstable/lint/catalog/skill/manifest-keys-recognized.d.ts +26 -0
  117. package/dist/src/unstable/lint/catalog/skill/manifest-keys-recognized.d.ts.map +1 -0
  118. package/dist/src/unstable/lint/catalog/skill/manifest-keys-recognized.js +41 -0
  119. package/dist/src/unstable/lint/catalog/skill/manifest-keys-recognized.js.map +1 -0
  120. package/dist/src/unstable/lint/catalog/skill/manifest-present.d.ts +18 -0
  121. package/dist/src/unstable/lint/catalog/skill/manifest-present.d.ts.map +1 -0
  122. package/dist/src/unstable/lint/catalog/skill/manifest-present.js +46 -0
  123. package/dist/src/unstable/lint/catalog/skill/manifest-present.js.map +1 -0
  124. package/dist/src/unstable/lint/catalog/skill/manifest-schema-valid.d.ts +22 -0
  125. package/dist/src/unstable/lint/catalog/skill/manifest-schema-valid.d.ts.map +1 -0
  126. package/dist/src/unstable/lint/catalog/skill/manifest-schema-valid.js +37 -0
  127. package/dist/src/unstable/lint/catalog/skill/manifest-schema-valid.js.map +1 -0
  128. package/dist/src/unstable/lint/catalog/skill/skill-md-present.d.ts +17 -0
  129. package/dist/src/unstable/lint/catalog/skill/skill-md-present.d.ts.map +1 -0
  130. package/dist/src/unstable/lint/catalog/skill/skill-md-present.js +38 -0
  131. package/dist/src/unstable/lint/catalog/skill/skill-md-present.js.map +1 -0
  132. package/dist/src/unstable/lint/catalog/skill-accessor/contexts.d.ts +65 -0
  133. package/dist/src/unstable/lint/catalog/skill-accessor/contexts.d.ts.map +1 -0
  134. package/dist/src/unstable/lint/catalog/skill-accessor/contexts.js +50 -0
  135. package/dist/src/unstable/lint/catalog/skill-accessor/contexts.js.map +1 -0
  136. package/dist/src/unstable/lint/catalog/skill-accessor/platform.d.ts +52 -0
  137. package/dist/src/unstable/lint/catalog/skill-accessor/platform.d.ts.map +1 -0
  138. package/dist/src/unstable/lint/catalog/skill-accessor/platform.js +89 -0
  139. package/dist/src/unstable/lint/catalog/skill-accessor/platform.js.map +1 -0
  140. package/dist/src/unstable/lint/catalog/skill-accessor/vft.d.ts +58 -0
  141. package/dist/src/unstable/lint/catalog/skill-accessor/vft.d.ts.map +1 -0
  142. package/dist/src/unstable/lint/catalog/skill-accessor/vft.js +83 -0
  143. package/dist/src/unstable/lint/catalog/skill-accessor/vft.js.map +1 -0
  144. package/dist/src/unstable/lint/catalog/skill.d.ts +38 -0
  145. package/dist/src/unstable/lint/catalog/skill.d.ts.map +1 -0
  146. package/dist/src/unstable/lint/catalog/skill.js +52 -0
  147. package/dist/src/unstable/lint/catalog/skill.js.map +1 -0
  148. package/dist/src/unstable/lint/catalog/workspace/agents-detected-declared.d.ts +23 -0
  149. package/dist/src/unstable/lint/catalog/workspace/agents-detected-declared.d.ts.map +1 -0
  150. package/dist/src/unstable/lint/catalog/workspace/agents-detected-declared.js +75 -0
  151. package/dist/src/unstable/lint/catalog/workspace/agents-detected-declared.js.map +1 -0
  152. package/dist/src/unstable/lint/catalog/workspace/agents-recognized.d.ts +23 -0
  153. package/dist/src/unstable/lint/catalog/workspace/agents-recognized.d.ts.map +1 -0
  154. package/dist/src/unstable/lint/catalog/workspace/agents-recognized.js +76 -0
  155. package/dist/src/unstable/lint/catalog/workspace/agents-recognized.js.map +1 -0
  156. package/dist/src/unstable/lint/catalog/workspace/helpers/empty.d.ts +18 -0
  157. package/dist/src/unstable/lint/catalog/workspace/helpers/empty.d.ts.map +1 -0
  158. package/dist/src/unstable/lint/catalog/workspace/helpers/empty.js +16 -0
  159. package/dist/src/unstable/lint/catalog/workspace/helpers/empty.js.map +1 -0
  160. package/dist/src/unstable/lint/catalog/workspace/helpers/install-ops.d.ts +133 -0
  161. package/dist/src/unstable/lint/catalog/workspace/helpers/install-ops.d.ts.map +1 -0
  162. package/dist/src/unstable/lint/catalog/workspace/helpers/install-ops.js +149 -0
  163. package/dist/src/unstable/lint/catalog/workspace/helpers/install-ops.js.map +1 -0
  164. package/dist/src/unstable/lint/catalog/workspace/helpers/registry-source.d.ts +25 -0
  165. package/dist/src/unstable/lint/catalog/workspace/helpers/registry-source.d.ts.map +1 -0
  166. package/dist/src/unstable/lint/catalog/workspace/helpers/registry-source.js +30 -0
  167. package/dist/src/unstable/lint/catalog/workspace/helpers/registry-source.js.map +1 -0
  168. package/dist/src/unstable/lint/catalog/workspace/initialized.d.ts +22 -0
  169. package/dist/src/unstable/lint/catalog/workspace/initialized.d.ts.map +1 -0
  170. package/dist/src/unstable/lint/catalog/workspace/initialized.js +55 -0
  171. package/dist/src/unstable/lint/catalog/workspace/initialized.js.map +1 -0
  172. package/dist/src/unstable/lint/catalog/workspace/lockfile-valid.d.ts +33 -0
  173. package/dist/src/unstable/lint/catalog/workspace/lockfile-valid.d.ts.map +1 -0
  174. package/dist/src/unstable/lint/catalog/workspace/lockfile-valid.js +125 -0
  175. package/dist/src/unstable/lint/catalog/workspace/lockfile-valid.js.map +1 -0
  176. package/dist/src/unstable/lint/catalog/workspace/packs-declarations-valid.d.ts +19 -0
  177. package/dist/src/unstable/lint/catalog/workspace/packs-declarations-valid.d.ts.map +1 -0
  178. package/dist/src/unstable/lint/catalog/workspace/packs-declarations-valid.js +145 -0
  179. package/dist/src/unstable/lint/catalog/workspace/packs-declarations-valid.js.map +1 -0
  180. package/dist/src/unstable/lint/catalog/workspace/packs-dependencies-resolved.d.ts +17 -0
  181. package/dist/src/unstable/lint/catalog/workspace/packs-dependencies-resolved.d.ts.map +1 -0
  182. package/dist/src/unstable/lint/catalog/workspace/packs-dependencies-resolved.js +107 -0
  183. package/dist/src/unstable/lint/catalog/workspace/packs-dependencies-resolved.js.map +1 -0
  184. package/dist/src/unstable/lint/catalog/workspace/packs-members-retained.d.ts +22 -0
  185. package/dist/src/unstable/lint/catalog/workspace/packs-members-retained.d.ts.map +1 -0
  186. package/dist/src/unstable/lint/catalog/workspace/packs-members-retained.js +163 -0
  187. package/dist/src/unstable/lint/catalog/workspace/packs-members-retained.js.map +1 -0
  188. package/dist/src/unstable/lint/catalog/workspace/settings-schema-valid.d.ts +28 -0
  189. package/dist/src/unstable/lint/catalog/workspace/settings-schema-valid.d.ts.map +1 -0
  190. package/dist/src/unstable/lint/catalog/workspace/settings-schema-valid.js +67 -0
  191. package/dist/src/unstable/lint/catalog/workspace/settings-schema-valid.js.map +1 -0
  192. package/dist/src/unstable/lint/catalog/workspace/skills-artifacts-clean.d.ts +30 -0
  193. package/dist/src/unstable/lint/catalog/workspace/skills-artifacts-clean.d.ts.map +1 -0
  194. package/dist/src/unstable/lint/catalog/workspace/skills-artifacts-clean.js +232 -0
  195. package/dist/src/unstable/lint/catalog/workspace/skills-artifacts-clean.js.map +1 -0
  196. package/dist/src/unstable/lint/catalog/workspace/skills-artifacts-correct.d.ts +26 -0
  197. package/dist/src/unstable/lint/catalog/workspace/skills-artifacts-correct.d.ts.map +1 -0
  198. package/dist/src/unstable/lint/catalog/workspace/skills-artifacts-correct.js +129 -0
  199. package/dist/src/unstable/lint/catalog/workspace/skills-artifacts-correct.js.map +1 -0
  200. package/dist/src/unstable/lint/catalog/workspace/skills-declarations-valid.d.ts +26 -0
  201. package/dist/src/unstable/lint/catalog/workspace/skills-declarations-valid.d.ts.map +1 -0
  202. package/dist/src/unstable/lint/catalog/workspace/skills-declarations-valid.js +151 -0
  203. package/dist/src/unstable/lint/catalog/workspace/skills-declarations-valid.js.map +1 -0
  204. package/dist/src/unstable/lint/catalog/workspace/skills-integrity-valid.d.ts +29 -0
  205. package/dist/src/unstable/lint/catalog/workspace/skills-integrity-valid.d.ts.map +1 -0
  206. package/dist/src/unstable/lint/catalog/workspace/skills-integrity-valid.js +149 -0
  207. package/dist/src/unstable/lint/catalog/workspace/skills-integrity-valid.js.map +1 -0
  208. package/dist/src/unstable/lint/catalog/workspace/skills-lockfile-aligned.d.ts +29 -0
  209. package/dist/src/unstable/lint/catalog/workspace/skills-lockfile-aligned.d.ts.map +1 -0
  210. package/dist/src/unstable/lint/catalog/workspace/skills-lockfile-aligned.js +242 -0
  211. package/dist/src/unstable/lint/catalog/workspace/skills-lockfile-aligned.js.map +1 -0
  212. package/dist/src/unstable/lint/catalog/workspace-accessor/contexts.d.ts +141 -0
  213. package/dist/src/unstable/lint/catalog/workspace-accessor/contexts.d.ts.map +1 -0
  214. package/dist/src/unstable/lint/catalog/workspace-accessor/contexts.js +123 -0
  215. package/dist/src/unstable/lint/catalog/workspace-accessor/contexts.js.map +1 -0
  216. package/dist/src/unstable/lint/catalog/workspace-accessor/interpret-ops.d.ts +38 -0
  217. package/dist/src/unstable/lint/catalog/workspace-accessor/interpret-ops.d.ts.map +1 -0
  218. package/dist/src/unstable/lint/catalog/workspace-accessor/interpret-ops.js +311 -0
  219. package/dist/src/unstable/lint/catalog/workspace-accessor/interpret-ops.js.map +1 -0
  220. package/dist/src/unstable/lint/catalog/workspace-accessor/platform.d.ts +60 -0
  221. package/dist/src/unstable/lint/catalog/workspace-accessor/platform.d.ts.map +1 -0
  222. package/dist/src/unstable/lint/catalog/workspace-accessor/platform.js +201 -0
  223. package/dist/src/unstable/lint/catalog/workspace-accessor/platform.js.map +1 -0
  224. package/dist/src/unstable/lint/catalog/workspace-accessor/test-state.d.ts +65 -0
  225. package/dist/src/unstable/lint/catalog/workspace-accessor/test-state.d.ts.map +1 -0
  226. package/dist/src/unstable/lint/catalog/workspace-accessor/test-state.js +95 -0
  227. package/dist/src/unstable/lint/catalog/workspace-accessor/test-state.js.map +1 -0
  228. package/dist/src/unstable/lint/catalog/workspace.d.ts +47 -0
  229. package/dist/src/unstable/lint/catalog/workspace.d.ts.map +1 -0
  230. package/dist/src/unstable/lint/catalog/workspace.js +80 -0
  231. package/dist/src/unstable/lint/catalog/workspace.js.map +1 -0
  232. package/dist/src/unstable/lint/cli.d.ts +297 -0
  233. package/dist/src/unstable/lint/cli.d.ts.map +1 -0
  234. package/dist/src/unstable/lint/cli.js +388 -0
  235. package/dist/src/unstable/lint/cli.js.map +1 -0
  236. package/dist/src/unstable/lint/compose-path.d.ts +27 -0
  237. package/dist/src/unstable/lint/compose-path.d.ts.map +1 -0
  238. package/dist/src/unstable/lint/compose-path.js +61 -0
  239. package/dist/src/unstable/lint/compose-path.js.map +1 -0
  240. package/dist/src/unstable/lint/config.d.ts +103 -0
  241. package/dist/src/unstable/lint/config.d.ts.map +1 -0
  242. package/dist/src/unstable/lint/config.js +137 -0
  243. package/dist/src/unstable/lint/config.js.map +1 -0
  244. package/dist/src/unstable/lint/context.d.ts +265 -0
  245. package/dist/src/unstable/lint/context.d.ts.map +1 -0
  246. package/dist/src/unstable/lint/context.js +21 -0
  247. package/dist/src/unstable/lint/context.js.map +1 -0
  248. package/dist/src/unstable/lint/evaluate.d.ts +68 -0
  249. package/dist/src/unstable/lint/evaluate.d.ts.map +1 -0
  250. package/dist/src/unstable/lint/evaluate.js +147 -0
  251. package/dist/src/unstable/lint/evaluate.js.map +1 -0
  252. package/dist/src/unstable/lint/index.d.ts +28 -0
  253. package/dist/src/unstable/lint/index.d.ts.map +1 -0
  254. package/dist/src/unstable/lint/index.js +35 -0
  255. package/dist/src/unstable/lint/index.js.map +1 -0
  256. package/dist/src/unstable/lint/issues-to-findings.d.ts +35 -0
  257. package/dist/src/unstable/lint/issues-to-findings.d.ts.map +1 -0
  258. package/dist/src/unstable/lint/issues-to-findings.js +97 -0
  259. package/dist/src/unstable/lint/issues-to-findings.js.map +1 -0
  260. package/dist/src/unstable/lint/rule.d.ts +139 -0
  261. package/dist/src/unstable/lint/rule.d.ts.map +1 -0
  262. package/dist/src/unstable/lint/rule.js +25 -0
  263. package/dist/src/unstable/lint/rule.js.map +1 -0
  264. package/dist/src/unstable/lockfile/schema.d.ts +404 -404
  265. package/dist/src/unstable/mcp-servers/manager.d.ts +1 -1
  266. package/dist/src/unstable/mcp-servers/manager.d.ts.map +1 -1
  267. package/dist/src/unstable/mcp-servers/manager.js +1 -1
  268. package/dist/src/unstable/mcp-servers/manager.js.map +1 -1
  269. package/dist/src/unstable/mcp-servers/operations/install.d.ts +1 -1
  270. package/dist/src/unstable/mcp-servers/operations/install.d.ts.map +1 -1
  271. package/dist/src/unstable/mcp-servers/operations/publish.d.ts +1 -1
  272. package/dist/src/unstable/mcp-servers/operations/publish.d.ts.map +1 -1
  273. package/dist/src/unstable/mcp-servers/operations/uninstall.d.ts +1 -1
  274. package/dist/src/unstable/mcp-servers/operations/uninstall.d.ts.map +1 -1
  275. package/dist/src/unstable/packs/manager.d.ts +1 -1
  276. package/dist/src/unstable/packs/manager.d.ts.map +1 -1
  277. package/dist/src/unstable/packs/manager.js +1 -1
  278. package/dist/src/unstable/packs/manager.js.map +1 -1
  279. package/dist/src/unstable/packs/operations/add-to-pack.d.ts +2 -2
  280. package/dist/src/unstable/packs/operations/add-to-pack.d.ts.map +1 -1
  281. package/dist/src/unstable/packs/operations/install.d.ts +2 -2
  282. package/dist/src/unstable/packs/operations/install.d.ts.map +1 -1
  283. package/dist/src/unstable/packs/operations/install.js +41 -0
  284. package/dist/src/unstable/packs/operations/install.js.map +1 -1
  285. package/dist/src/unstable/packs/operations/new-pack.d.ts +2 -2
  286. package/dist/src/unstable/packs/operations/new-pack.d.ts.map +1 -1
  287. package/dist/src/unstable/packs/operations/publish.d.ts +2 -2
  288. package/dist/src/unstable/packs/operations/publish.d.ts.map +1 -1
  289. package/dist/src/unstable/packs/operations/publish.js +1 -0
  290. package/dist/src/unstable/packs/operations/publish.js.map +1 -1
  291. package/dist/src/unstable/packs/operations/remove-from-pack.d.ts +2 -2
  292. package/dist/src/unstable/packs/operations/remove-from-pack.d.ts.map +1 -1
  293. package/dist/src/unstable/packs/operations/uninstall.d.ts +2 -2
  294. package/dist/src/unstable/packs/operations/uninstall.d.ts.map +1 -1
  295. package/dist/src/unstable/packs/operations/unpack.d.ts +2 -2
  296. package/dist/src/unstable/packs/operations/unpack.d.ts.map +1 -1
  297. package/dist/src/unstable/{workspace → plan}/apply-plan.d.ts +9 -0
  298. package/dist/src/unstable/plan/apply-plan.d.ts.map +1 -0
  299. package/dist/src/unstable/{workspace → plan}/apply-plan.js +10 -1
  300. package/dist/src/unstable/plan/apply-plan.js.map +1 -0
  301. package/dist/src/unstable/plan/index.d.ts +24 -0
  302. package/dist/src/unstable/plan/index.d.ts.map +1 -0
  303. package/dist/src/unstable/plan/index.js +28 -0
  304. package/dist/src/unstable/plan/index.js.map +1 -0
  305. package/dist/src/unstable/{workspace → plan}/plan.d.ts +6 -0
  306. package/dist/src/unstable/plan/plan.d.ts.map +1 -0
  307. package/dist/src/unstable/{workspace → plan}/plan.js +6 -0
  308. package/dist/src/unstable/plan/plan.js.map +1 -0
  309. package/dist/src/unstable/{workspace → plan}/resolve-plan.d.ts +30 -2
  310. package/dist/src/unstable/plan/resolve-plan.d.ts.map +1 -0
  311. package/dist/src/unstable/{workspace → plan}/resolve-plan.js +37 -6
  312. package/dist/src/unstable/plan/resolve-plan.js.map +1 -0
  313. package/dist/src/unstable/publish/manifest-policy.d.ts +8 -8
  314. package/dist/src/unstable/registry/__generated__/registry-client.d.ts +675 -518
  315. package/dist/src/unstable/registry/__generated__/registry-client.d.ts.map +1 -1
  316. package/dist/src/unstable/registry/__generated__/registry-client.js +546 -396
  317. package/dist/src/unstable/registry/__generated__/registry-client.js.map +1 -1
  318. package/dist/src/unstable/registry/remote-client.d.ts.map +1 -1
  319. package/dist/src/unstable/registry/remote-client.js +123 -18
  320. package/dist/src/unstable/registry/remote-client.js.map +1 -1
  321. package/dist/src/unstable/registry/schema.d.ts +2 -2
  322. package/dist/src/unstable/settings/index.d.ts +2 -0
  323. package/dist/src/unstable/settings/index.d.ts.map +1 -1
  324. package/dist/src/unstable/settings/index.js +1 -0
  325. package/dist/src/unstable/settings/index.js.map +1 -1
  326. package/dist/src/unstable/settings/schema.d.ts +3 -0
  327. package/dist/src/unstable/settings/schema.d.ts.map +1 -1
  328. package/dist/src/unstable/settings/schema.js +3 -0
  329. package/dist/src/unstable/settings/schema.js.map +1 -1
  330. package/dist/src/unstable/settings/settings.d.ts +10 -0
  331. package/dist/src/unstable/settings/settings.d.ts.map +1 -1
  332. package/dist/src/unstable/skills/manager.d.ts +1 -1
  333. package/dist/src/unstable/skills/manager.d.ts.map +1 -1
  334. package/dist/src/unstable/skills/manager.js +2 -2
  335. package/dist/src/unstable/skills/manager.js.map +1 -1
  336. package/dist/src/unstable/skills/materialization.js +1 -1
  337. package/dist/src/unstable/skills/materialization.js.map +1 -1
  338. package/dist/src/unstable/skills/operations/copy.d.ts +2 -2
  339. package/dist/src/unstable/skills/operations/copy.d.ts.map +1 -1
  340. package/dist/src/unstable/skills/operations/disable.d.ts +2 -2
  341. package/dist/src/unstable/skills/operations/disable.d.ts.map +1 -1
  342. package/dist/src/unstable/skills/operations/enable.d.ts +2 -2
  343. package/dist/src/unstable/skills/operations/enable.d.ts.map +1 -1
  344. package/dist/src/unstable/skills/operations/install.d.ts +2 -2
  345. package/dist/src/unstable/skills/operations/install.d.ts.map +1 -1
  346. package/dist/src/unstable/skills/operations/install.js +1 -1
  347. package/dist/src/unstable/skills/operations/install.js.map +1 -1
  348. package/dist/src/unstable/skills/operations/new-skill.d.ts +2 -2
  349. package/dist/src/unstable/skills/operations/new-skill.d.ts.map +1 -1
  350. package/dist/src/unstable/skills/operations/publish.d.ts +2 -2
  351. package/dist/src/unstable/skills/operations/publish.d.ts.map +1 -1
  352. package/dist/src/unstable/skills/operations/rename.d.ts +2 -2
  353. package/dist/src/unstable/skills/operations/rename.d.ts.map +1 -1
  354. package/dist/src/unstable/skills/operations/uninstall.d.ts +2 -2
  355. package/dist/src/unstable/skills/operations/uninstall.d.ts.map +1 -1
  356. package/dist/src/unstable/skills/operations/uninstall.js +1 -1
  357. package/dist/src/unstable/skills/operations/uninstall.js.map +1 -1
  358. package/dist/src/unstable/source-resolution/service.d.ts +1 -1
  359. package/dist/src/unstable/source-resolution/service.d.ts.map +1 -1
  360. package/dist/src/unstable/source-resolution/service.js +1 -1
  361. package/dist/src/unstable/source-resolution/service.js.map +1 -1
  362. package/dist/src/unstable/sources/types.d.ts +29 -29
  363. package/dist/src/unstable/sources/types.d.ts.map +1 -1
  364. package/dist/src/unstable/subagents/manager.d.ts +1 -1
  365. package/dist/src/unstable/subagents/manager.d.ts.map +1 -1
  366. package/dist/src/unstable/subagents/manager.js +4 -4
  367. package/dist/src/unstable/subagents/manager.js.map +1 -1
  368. package/dist/src/unstable/subagents/manifest-schema.js +2 -2
  369. package/dist/src/unstable/subagents/manifest-schema.js.map +1 -1
  370. package/dist/src/unstable/subagents/operations/disable.d.ts +2 -2
  371. package/dist/src/unstable/subagents/operations/disable.d.ts.map +1 -1
  372. package/dist/src/unstable/subagents/operations/enable.d.ts +2 -2
  373. package/dist/src/unstable/subagents/operations/enable.d.ts.map +1 -1
  374. package/dist/src/unstable/subagents/operations/publish.d.ts +2 -2
  375. package/dist/src/unstable/subagents/operations/publish.d.ts.map +1 -1
  376. package/dist/src/unstable/telemetry/__generated__/telemetry-client.d.ts +20 -12
  377. package/dist/src/unstable/telemetry/__generated__/telemetry-client.d.ts.map +1 -1
  378. package/dist/src/unstable/telemetry/__generated__/telemetry-client.js +11 -3
  379. package/dist/src/unstable/telemetry/__generated__/telemetry-client.js.map +1 -1
  380. package/dist/src/unstable/telemetry/client.d.ts +1 -1
  381. package/dist/src/unstable/telemetry/client.d.ts.map +1 -1
  382. package/dist/src/unstable/telemetry/client.js +1 -1
  383. package/dist/src/unstable/telemetry/client.js.map +1 -1
  384. package/dist/src/unstable/update-check/update-check.d.ts +1 -1
  385. package/dist/src/unstable/update-check/update-check.d.ts.map +1 -1
  386. package/dist/src/unstable/update-check/update-check.js +1 -1
  387. package/dist/src/unstable/update-check/update-check.js.map +1 -1
  388. package/dist/src/unstable/utils/fs-helpers.d.ts +7 -6
  389. package/dist/src/unstable/utils/fs-helpers.d.ts.map +1 -1
  390. package/dist/src/unstable/utils/fs-helpers.js +9 -9
  391. package/dist/src/unstable/utils/fs-helpers.js.map +1 -1
  392. package/dist/src/unstable/workflows/install-command/workflow.d.ts +1 -1
  393. package/dist/src/unstable/workflows/install-command/workflow.d.ts.map +1 -1
  394. package/dist/src/unstable/workflows/install-command/workflow.js +1 -1
  395. package/dist/src/unstable/workflows/install-command/workflow.js.map +1 -1
  396. package/dist/src/unstable/workflows/uninstall-command/workflow.d.ts +1 -1
  397. package/dist/src/unstable/workflows/uninstall-command/workflow.d.ts.map +1 -1
  398. package/dist/src/unstable/workflows/uninstall-command/workflow.js +1 -1
  399. package/dist/src/unstable/workflows/uninstall-command/workflow.js.map +1 -1
  400. package/dist/src/unstable/workspace/augment-plan.d.ts +1 -1
  401. package/dist/src/unstable/workspace/augment-plan.d.ts.map +1 -1
  402. package/dist/src/unstable/workspace/display-plan.d.ts +1 -1
  403. package/dist/src/unstable/workspace/display-plan.d.ts.map +1 -1
  404. package/dist/src/unstable/workspace/display-plan.js +1 -1
  405. package/dist/src/unstable/workspace/display-plan.js.map +1 -1
  406. package/dist/src/unstable/workspace/index.d.ts +1 -5
  407. package/dist/src/unstable/workspace/index.d.ts.map +1 -1
  408. package/dist/src/unstable/workspace/index.js +5 -7
  409. package/dist/src/unstable/workspace/index.js.map +1 -1
  410. package/dist/src/unstable/workspace/initialization-interaction.d.ts +1 -1
  411. package/dist/src/unstable/workspace/initialization-interaction.d.ts.map +1 -1
  412. package/dist/src/unstable/workspace/initialization-interaction.js +1 -1
  413. package/dist/src/unstable/workspace/initialization-interaction.js.map +1 -1
  414. package/dist/src/unstable/workspace/initialization.d.ts +15 -0
  415. package/dist/src/unstable/workspace/initialization.d.ts.map +1 -1
  416. package/dist/src/unstable/workspace/initialization.js +2 -2
  417. package/dist/src/unstable/workspace/initialization.js.map +1 -1
  418. package/dist/src/unstable/workspace/paths.d.ts +4 -21
  419. package/dist/src/unstable/workspace/paths.d.ts.map +1 -1
  420. package/dist/src/unstable/workspace/paths.js +19 -8
  421. package/dist/src/unstable/workspace/paths.js.map +1 -1
  422. package/dist/src/unstable/workspace/reconciliation.d.ts +1 -1
  423. package/dist/src/unstable/workspace/reconciliation.d.ts.map +1 -1
  424. package/dist/src/unstable/workspace/resolve-plan-interaction.d.ts +1 -1
  425. package/dist/src/unstable/workspace/resolve-plan-interaction.d.ts.map +1 -1
  426. package/dist/src/unstable/workspace/resolve-plan-interaction.js +1 -1
  427. package/dist/src/unstable/workspace/resolve-plan-interaction.js.map +1 -1
  428. package/dist/src/unstable/workspace/scan-plan-readiness.d.ts +1 -1
  429. package/dist/src/unstable/workspace/scan-plan-readiness.d.ts.map +1 -1
  430. package/dist/src/unstable/workspace/service-interface.d.ts +3 -1
  431. package/dist/src/unstable/workspace/service-interface.d.ts.map +1 -1
  432. package/dist/src/unstable/workspace/service-interface.js +1 -1
  433. package/dist/src/unstable/workspace/service-interface.js.map +1 -1
  434. package/dist/src/unstable/workspace/service.js +1 -1
  435. package/dist/src/unstable/workspace/service.js.map +1 -1
  436. package/dist/src/unstable/workspace/settings-validation/types.d.ts +11 -1
  437. package/dist/src/unstable/workspace/settings-validation/types.d.ts.map +1 -1
  438. package/dist/src/unstable/workspace/version-currency/check-currency.d.ts +41 -0
  439. package/dist/src/unstable/workspace/version-currency/check-currency.d.ts.map +1 -0
  440. package/dist/src/unstable/workspace/version-currency/check-currency.js +50 -0
  441. package/dist/src/unstable/workspace/version-currency/check-currency.js.map +1 -0
  442. package/dist/src/unstable/workspace/version-currency/collectors.d.ts +55 -0
  443. package/dist/src/unstable/workspace/version-currency/collectors.d.ts.map +1 -0
  444. package/dist/src/unstable/workspace/version-currency/collectors.js +127 -0
  445. package/dist/src/unstable/workspace/version-currency/collectors.js.map +1 -0
  446. package/dist/src/unstable/workspace/version-currency/index.d.ts +11 -0
  447. package/dist/src/unstable/workspace/version-currency/index.d.ts.map +1 -0
  448. package/dist/src/unstable/workspace/version-currency/index.js +11 -0
  449. package/dist/src/unstable/workspace/version-currency/index.js.map +1 -0
  450. package/dist/src/unstable/workspace/version-currency/test-stubs.d.ts +5 -0
  451. package/dist/src/unstable/workspace/version-currency/test-stubs.d.ts.map +1 -0
  452. package/dist/src/unstable/workspace/version-currency/test-stubs.js +31 -0
  453. package/dist/src/unstable/workspace/version-currency/test-stubs.js.map +1 -0
  454. package/package.json +14 -6
  455. package/dist/src/unstable/workspace/apply-plan.d.ts.map +0 -1
  456. package/dist/src/unstable/workspace/apply-plan.js.map +0 -1
  457. package/dist/src/unstable/workspace/doctor/check-def.d.ts +0 -29
  458. package/dist/src/unstable/workspace/doctor/check-def.d.ts.map +0 -1
  459. package/dist/src/unstable/workspace/doctor/check-def.js +0 -17
  460. package/dist/src/unstable/workspace/doctor/check-def.js.map +0 -1
  461. package/dist/src/unstable/workspace/doctor/checks/agents-configured.d.ts +0 -5
  462. package/dist/src/unstable/workspace/doctor/checks/agents-configured.d.ts.map +0 -1
  463. package/dist/src/unstable/workspace/doctor/checks/agents-configured.js +0 -170
  464. package/dist/src/unstable/workspace/doctor/checks/agents-configured.js.map +0 -1
  465. package/dist/src/unstable/workspace/doctor/checks/extensions-installed.d.ts +0 -5
  466. package/dist/src/unstable/workspace/doctor/checks/extensions-installed.d.ts.map +0 -1
  467. package/dist/src/unstable/workspace/doctor/checks/extensions-installed.js +0 -472
  468. package/dist/src/unstable/workspace/doctor/checks/extensions-installed.js.map +0 -1
  469. package/dist/src/unstable/workspace/doctor/checks/workspace-ready.d.ts +0 -5
  470. package/dist/src/unstable/workspace/doctor/checks/workspace-ready.d.ts.map +0 -1
  471. package/dist/src/unstable/workspace/doctor/checks/workspace-ready.js +0 -201
  472. package/dist/src/unstable/workspace/doctor/checks/workspace-ready.js.map +0 -1
  473. package/dist/src/unstable/workspace/doctor/diagnose.d.ts +0 -49
  474. package/dist/src/unstable/workspace/doctor/diagnose.d.ts.map +0 -1
  475. package/dist/src/unstable/workspace/doctor/diagnose.js +0 -65
  476. package/dist/src/unstable/workspace/doctor/diagnose.js.map +0 -1
  477. package/dist/src/unstable/workspace/doctor/index.d.ts +0 -8
  478. package/dist/src/unstable/workspace/doctor/index.d.ts.map +0 -1
  479. package/dist/src/unstable/workspace/doctor/index.js +0 -6
  480. package/dist/src/unstable/workspace/doctor/index.js.map +0 -1
  481. package/dist/src/unstable/workspace/doctor/rollup.d.ts +0 -4
  482. package/dist/src/unstable/workspace/doctor/rollup.d.ts.map +0 -1
  483. package/dist/src/unstable/workspace/doctor/rollup.js +0 -28
  484. package/dist/src/unstable/workspace/doctor/rollup.js.map +0 -1
  485. package/dist/src/unstable/workspace/doctor/runner.d.ts +0 -6
  486. package/dist/src/unstable/workspace/doctor/runner.d.ts.map +0 -1
  487. package/dist/src/unstable/workspace/doctor/runner.js +0 -179
  488. package/dist/src/unstable/workspace/doctor/runner.js.map +0 -1
  489. package/dist/src/unstable/workspace/doctor/types.d.ts +0 -125
  490. package/dist/src/unstable/workspace/doctor/types.d.ts.map +0 -1
  491. package/dist/src/unstable/workspace/doctor/types.js +0 -58
  492. package/dist/src/unstable/workspace/doctor/types.js.map +0 -1
  493. package/dist/src/unstable/workspace/plan.d.ts.map +0 -1
  494. package/dist/src/unstable/workspace/plan.js.map +0 -1
  495. package/dist/src/unstable/workspace/resolve-plan.d.ts.map +0 -1
  496. package/dist/src/unstable/workspace/resolve-plan.js.map +0 -1
  497. package/dist/src/unstable/workspace/sync.d.ts +0 -17
  498. package/dist/src/unstable/workspace/sync.d.ts.map +0 -1
  499. package/dist/src/unstable/workspace/sync.js +0 -142
  500. package/dist/src/unstable/workspace/sync.js.map +0 -1
@@ -0,0 +1,65 @@
1
+ /**
2
+ * In-memory `WorkspaceState` + accessor, used by fixture tests and the
3
+ * determinism harness (task 3c.19).
4
+ *
5
+ * Autofix `fix` methods return per-extension `Operation` intents (see
6
+ * `workspace/helpers/install-ops.ts`). The determinism harness applies those
7
+ * intents to a mutable `WorkspaceState` and re-runs the rule's `check` against
8
+ * a fresh `WorkspaceLintAccessor` backed by the updated state. The harness
9
+ * asserts zero findings from that rule post-apply — establishing the
10
+ * "apply(fix) + re-run(rule) === [] from that rule" determinism contract.
11
+ *
12
+ * The state model is intentionally minimal: just enough to satisfy the v1
13
+ * rule-body probes (settings, lockfile, exists, list, knownAgents,
14
+ * detectAgents, installedSkills, installedPacks). Fixtures declare their
15
+ * state in JSON; the harness applies `Operation` intents via a pure
16
+ * reducer.
17
+ *
18
+ * @experimental This API is unstable and may change without notice.
19
+ * @packageDocumentation
20
+ */
21
+ import type { LockfileDocument, PackRuleContext, SettingsDocument, SkillRuleContext, WorkspaceLintAccessor } from "../../context.js";
22
+ import type { AgentId } from "../../../agents/types.js";
23
+ /**
24
+ * Mutable workspace state exercised by fixtures and the determinism harness.
25
+ *
26
+ * All fields start empty. Tests populate only what their rule needs; the
27
+ * harness applies per-extension Operations through `applyIntent`.
28
+ *
29
+ * @experimental This API is unstable and may change without notice.
30
+ */
31
+ export interface WorkspaceState {
32
+ /** Raw parsed `.axm/settings.json` (or `undefined` for missing file). */
33
+ settings: SettingsDocument | undefined;
34
+ /** Raw parsed `.axm/axm-lock.yaml` (or `undefined` for missing file). */
35
+ lockfile: LockfileDocument | undefined;
36
+ /** Workspace-relative posix paths the accessor treats as existing. */
37
+ existingPaths: Set<string>;
38
+ /** Writable paths (subset of existingPaths). */
39
+ writablePaths: Set<string>;
40
+ /** Map of parent-directory-relative posix path → immediate child names. */
41
+ listings: Map<string, Array<string>>;
42
+ /** Detected agent ids for `detectAgents("project")` at the current moment. */
43
+ detectedProjectAgents: Set<AgentId>;
44
+ /** Installed skills (project scope). */
45
+ installedSkills: ReadonlyArray<SkillRuleContext>;
46
+ /** Installed packs (project scope). */
47
+ installedPacks: ReadonlyArray<PackRuleContext>;
48
+ }
49
+ /**
50
+ * Factory returning an empty `WorkspaceState`.
51
+ *
52
+ * @experimental This API is unstable and may change without notice.
53
+ */
54
+ export declare const emptyWorkspaceState: () => WorkspaceState;
55
+ /**
56
+ * Build a `WorkspaceLintAccessor` backed by a mutable `WorkspaceState`.
57
+ *
58
+ * Reads are immediate — no concurrency. Calls return whatever the state
59
+ * currently holds, so the determinism harness can mutate state between
60
+ * `check` + `fix` + `check` without rebuilding the accessor.
61
+ *
62
+ * @experimental This API is unstable and may change without notice.
63
+ */
64
+ export declare const makeStateBackedWorkspaceLintAccessor: (state: WorkspaceState) => WorkspaceLintAccessor;
65
+ //# sourceMappingURL=test-state.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"test-state.d.ts","sourceRoot":"","sources":["../../../../../../src/unstable/lint/catalog/workspace-accessor/test-state.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAIH,OAAO,KAAK,EAGV,gBAAgB,EAChB,eAAe,EACf,gBAAgB,EAChB,gBAAgB,EAChB,qBAAqB,EACtB,MAAM,kBAAkB,CAAC;AAC1B,OAAO,KAAK,EAAmB,OAAO,EAAE,MAAM,0BAA0B,CAAC;AAOzE;;;;;;;GAOG;AACH,MAAM,WAAW,cAAc;IAC7B,yEAAyE;IACzE,QAAQ,EAAE,gBAAgB,GAAG,SAAS,CAAC;IACvC,yEAAyE;IACzE,QAAQ,EAAE,gBAAgB,GAAG,SAAS,CAAC;IACvC,sEAAsE;IACtE,aAAa,EAAE,GAAG,CAAC,MAAM,CAAC,CAAC;IAC3B,gDAAgD;IAChD,aAAa,EAAE,GAAG,CAAC,MAAM,CAAC,CAAC;IAC3B,2EAA2E;IAC3E,QAAQ,EAAE,GAAG,CAAC,MAAM,EAAE,KAAK,CAAC,MAAM,CAAC,CAAC,CAAC;IACrC,8EAA8E;IAC9E,qBAAqB,EAAE,GAAG,CAAC,OAAO,CAAC,CAAC;IACpC,wCAAwC;IACxC,eAAe,EAAE,aAAa,CAAC,gBAAgB,CAAC,CAAC;IACjD,uCAAuC;IACvC,cAAc,EAAE,aAAa,CAAC,eAAe,CAAC,CAAC;CAChD;AAED;;;;GAIG;AACH,eAAO,MAAM,mBAAmB,QAAO,cASrC,CAAC;AAMH;;;;;;;;GAQG;AACH,eAAO,MAAM,oCAAoC,GAC/C,OAAO,cAAc,KACpB,qBA6CD,CAAC"}
@@ -0,0 +1,95 @@
1
+ /**
2
+ * In-memory `WorkspaceState` + accessor, used by fixture tests and the
3
+ * determinism harness (task 3c.19).
4
+ *
5
+ * Autofix `fix` methods return per-extension `Operation` intents (see
6
+ * `workspace/helpers/install-ops.ts`). The determinism harness applies those
7
+ * intents to a mutable `WorkspaceState` and re-runs the rule's `check` against
8
+ * a fresh `WorkspaceLintAccessor` backed by the updated state. The harness
9
+ * asserts zero findings from that rule post-apply — establishing the
10
+ * "apply(fix) + re-run(rule) === [] from that rule" determinism contract.
11
+ *
12
+ * The state model is intentionally minimal: just enough to satisfy the v1
13
+ * rule-body probes (settings, lockfile, exists, list, knownAgents,
14
+ * detectAgents, installedSkills, installedPacks). Fixtures declare their
15
+ * state in JSON; the harness applies `Operation` intents via a pure
16
+ * reducer.
17
+ *
18
+ * @experimental This API is unstable and may change without notice.
19
+ * @packageDocumentation
20
+ */
21
+ import * as Effect from "effect/Effect";
22
+ import * as Option from "effect/Option";
23
+ import { getAllAgents } from "../../../agents/registry.js";
24
+ /**
25
+ * Factory returning an empty `WorkspaceState`.
26
+ *
27
+ * @experimental This API is unstable and may change without notice.
28
+ */
29
+ export const emptyWorkspaceState = () => ({
30
+ settings: undefined,
31
+ lockfile: undefined,
32
+ existingPaths: new Set(),
33
+ writablePaths: new Set(),
34
+ listings: new Map(),
35
+ detectedProjectAgents: new Set(),
36
+ installedSkills: [],
37
+ installedPacks: [],
38
+ });
39
+ // -----------------------------------------------------------------------------
40
+ // Test accessor
41
+ // -----------------------------------------------------------------------------
42
+ /**
43
+ * Build a `WorkspaceLintAccessor` backed by a mutable `WorkspaceState`.
44
+ *
45
+ * Reads are immediate — no concurrency. Calls return whatever the state
46
+ * currently holds, so the determinism harness can mutate state between
47
+ * `check` + `fix` + `check` without rebuilding the accessor.
48
+ *
49
+ * @experimental This API is unstable and may change without notice.
50
+ */
51
+ export const makeStateBackedWorkspaceLintAccessor = (state) => ({
52
+ settings: Effect.suspend(() => state.settings === undefined
53
+ ? Effect.fail({
54
+ _tag: "SettingsReadError",
55
+ message: "settings.json is missing",
56
+ })
57
+ : Effect.succeed(state.settings)),
58
+ lockfile: Effect.suspend(() => Effect.succeed(state.lockfile === undefined ? Option.none() : Option.some(state.lockfile))),
59
+ installedSkills: Effect.suspend(() => Effect.succeed(state.installedSkills)),
60
+ installedPacks: Effect.suspend(() => Effect.succeed(state.installedPacks)),
61
+ knownAgents: Effect.sync(() => getAllAgents()),
62
+ detectAgents: (scope) => Effect.suspend(() => {
63
+ if (scope !== "project") {
64
+ const empty = [];
65
+ return Effect.succeed(empty);
66
+ }
67
+ const detections = [];
68
+ for (const id of state.detectedProjectAgents) {
69
+ detections.push({ id, markerPath: `detected:${id}` });
70
+ }
71
+ return Effect.succeed(detections);
72
+ }),
73
+ exists: (path) => Effect.suspend(() => Effect.succeed(state.existingPaths.has(normalizePath(path)))),
74
+ isWritable: (path) => Effect.suspend(() => Effect.succeed(state.writablePaths.has(normalizePath(path)))),
75
+ list: (path) => Effect.suspend(() => {
76
+ const normalized = normalizePath(path);
77
+ const listing = state.listings.get(normalized);
78
+ if (listing === undefined) {
79
+ return Effect.fail({
80
+ _tag: "FileAccessError",
81
+ path,
82
+ reason: "read-error",
83
+ message: `no listing for path ${path}`,
84
+ });
85
+ }
86
+ return Effect.succeed([...listing]);
87
+ }),
88
+ });
89
+ const normalizePath = (input) => {
90
+ if (input === "" || input === "." || input === "./") {
91
+ return "";
92
+ }
93
+ return input.replace(/\\/g, "/").replace(/^\.\//, "");
94
+ };
95
+ //# sourceMappingURL=test-state.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"test-state.js","sourceRoot":"","sources":["../../../../../../src/unstable/lint/catalog/workspace-accessor/test-state.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAEH,OAAO,KAAK,MAAM,MAAM,eAAe,CAAC;AACxC,OAAO,KAAK,MAAM,MAAM,eAAe,CAAC;AAWxC,OAAO,EAAE,YAAY,EAAE,MAAM,6BAA6B,CAAC;A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AC1B,OAAO,MAAM,CAAC,IAAI,CAAkB;gBAClC,IAAI,EAAE,iBAA0B;gBAChC,IAAI;gBACJ,MAAM,EAAE,YAAqB;gBAC7B,OAAO,EAAE,uBAAuB,IAAI,EAAE;aACvC,CAAC,CAAC;QACL,CAAC;QACD,OAAO,MAAM,CAAC,OAAO,CAAwB,CAAC,GAAG,OAAO,CAAC,CAAC,CAAC;IAC7D,CAAC,CAAC;CACL,CAAC,CAAC;AAEH,MAAM,aAAa,GAAG,CAAC,KAAa,EAAU,EAAE;IAC9C,IAAI,KAAK,KAAK,EAAE,IAAI,KAAK,KAAK,GAAG,IAAI,KAAK,KAAK,IAAI,EAAE,CAAC;QACpD,OAAO,EAAE,CAAC;IACZ,CAAC;IACD,OAAO,KAAK,CAAC,OAAO,CAAC,KAAK,EAAE,GAAG,CAAC,CAAC,OAAO,CAAC,OAAO,EAAE,EAAE,CAAC,CAAC;AACxD,CAAC,CAAC"}
@@ -0,0 +1,47 @@
1
+ /**
2
+ * `workspace/*` rule catalog — the v1 thirteen-rule set.
3
+ *
4
+ * Per `docs/design/lint-engine.md §10.workspace`, `axm lint` (locally only —
5
+ * never publish) runs exactly these rules against each workspace context:
6
+ *
7
+ * | ID | Severity | Autofix |
8
+ * | --------------------------------------- | -------- | ----------- |
9
+ * | `workspace/initialized` | error | — |
10
+ * | `workspace/settings-schema-valid` | error | — |
11
+ * | `workspace/lockfile-valid` | error | autofixing |
12
+ * | `workspace/agents-recognized` | error | — |
13
+ * | `workspace/agents-detected-declared` | warning | — |
14
+ * | `workspace/skills-declarations-valid` | error | — |
15
+ * | `workspace/skills-lockfile-aligned` | error | autofixing |
16
+ * | `workspace/skills-integrity-valid` | error | autofixing |
17
+ * | `workspace/skills-artifacts-correct` | error | autofixing |
18
+ * | `workspace/skills-artifacts-clean` | error | mixed |
19
+ * | `workspace/packs-declarations-valid` | error | — |
20
+ * | `workspace/packs-dependencies-resolved` | error | — |
21
+ * | `workspace/packs-members-retained` | warning | — |
22
+ *
23
+ * Autofix rides per-extension Operations only (§6). No `editFile`,
24
+ * `writeFile`, or `syncWorkspace()` reference — arms whose remediation can't
25
+ * be expressed in the 14-operation vocabulary ship as `AdvisoryFinding` with a
26
+ * CLI suggestion instead.
27
+ *
28
+ * Rule ids are **registered with the lint config allowlist at module-load
29
+ * time**, so importing this catalog extends the set of accepted
30
+ * `.axm/settings.json` `lint.rules` keys.
31
+ *
32
+ * @experimental This API is unstable and may change without notice.
33
+ * @packageDocumentation
34
+ */
35
+ import type { LintRule } from "../rule.js";
36
+ import type { WorkspaceRuleContext } from "../context.js";
37
+ /**
38
+ * Ordered v1 `workspace/*` rule catalog. Declaration order is the evaluation
39
+ * order within a single `evaluateContexts` call (deterministic ordering is
40
+ * test-observable; see `evaluate.ts`). The catalog groups foundation rules
41
+ * first, then the skills install family, then the packs install family — the
42
+ * same order the design doc tables list them in.
43
+ *
44
+ * @experimental This API is unstable and may change without notice.
45
+ */
46
+ export declare const workspaceRules: ReadonlyArray<LintRule<WorkspaceRuleContext>>;
47
+ //# sourceMappingURL=workspace.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"workspace.d.ts","sourceRoot":"","sources":["../../../../../src/unstable/lint/catalog/workspace.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAiCG;AAGH,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AAC3C,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,eAAe,CAAC;AAe1D;;;;;;;;GAQG;AACH,eAAO,MAAM,cAAc,EAAE,aAAa,CAAC,QAAQ,CAAC,oBAAoB,CAAC,CAiBxE,CAAC"}
@@ -0,0 +1,80 @@
1
+ /**
2
+ * `workspace/*` rule catalog — the v1 thirteen-rule set.
3
+ *
4
+ * Per `docs/design/lint-engine.md §10.workspace`, `axm lint` (locally only —
5
+ * never publish) runs exactly these rules against each workspace context:
6
+ *
7
+ * | ID | Severity | Autofix |
8
+ * | --------------------------------------- | -------- | ----------- |
9
+ * | `workspace/initialized` | error | — |
10
+ * | `workspace/settings-schema-valid` | error | — |
11
+ * | `workspace/lockfile-valid` | error | autofixing |
12
+ * | `workspace/agents-recognized` | error | — |
13
+ * | `workspace/agents-detected-declared` | warning | — |
14
+ * | `workspace/skills-declarations-valid` | error | — |
15
+ * | `workspace/skills-lockfile-aligned` | error | autofixing |
16
+ * | `workspace/skills-integrity-valid` | error | autofixing |
17
+ * | `workspace/skills-artifacts-correct` | error | autofixing |
18
+ * | `workspace/skills-artifacts-clean` | error | mixed |
19
+ * | `workspace/packs-declarations-valid` | error | — |
20
+ * | `workspace/packs-dependencies-resolved` | error | — |
21
+ * | `workspace/packs-members-retained` | warning | — |
22
+ *
23
+ * Autofix rides per-extension Operations only (§6). No `editFile`,
24
+ * `writeFile`, or `syncWorkspace()` reference — arms whose remediation can't
25
+ * be expressed in the 14-operation vocabulary ship as `AdvisoryFinding` with a
26
+ * CLI suggestion instead.
27
+ *
28
+ * Rule ids are **registered with the lint config allowlist at module-load
29
+ * time**, so importing this catalog extends the set of accepted
30
+ * `.axm/settings.json` `lint.rules` keys.
31
+ *
32
+ * @experimental This API is unstable and may change without notice.
33
+ * @packageDocumentation
34
+ */
35
+ import { registerLintRuleIds } from "../config.js";
36
+ import { initializedRule } from "./workspace/initialized.js";
37
+ import { settingsSchemaValidRule } from "./workspace/settings-schema-valid.js";
38
+ import { lockfileValidRule } from "./workspace/lockfile-valid.js";
39
+ import { agentsRecognizedRule } from "./workspace/agents-recognized.js";
40
+ import { agentsDetectedDeclaredRule } from "./workspace/agents-detected-declared.js";
41
+ import { skillsDeclarationsValidRule } from "./workspace/skills-declarations-valid.js";
42
+ import { skillsLockfileAlignedRule } from "./workspace/skills-lockfile-aligned.js";
43
+ import { skillsIntegrityValidRule } from "./workspace/skills-integrity-valid.js";
44
+ import { skillsArtifactsCorrectRule } from "./workspace/skills-artifacts-correct.js";
45
+ import { skillsArtifactsCleanRule } from "./workspace/skills-artifacts-clean.js";
46
+ import { packsDeclarationsValidRule } from "./workspace/packs-declarations-valid.js";
47
+ import { packsDependenciesResolvedRule } from "./workspace/packs-dependencies-resolved.js";
48
+ import { packsMembersRetainedRule } from "./workspace/packs-members-retained.js";
49
+ /**
50
+ * Ordered v1 `workspace/*` rule catalog. Declaration order is the evaluation
51
+ * order within a single `evaluateContexts` call (deterministic ordering is
52
+ * test-observable; see `evaluate.ts`). The catalog groups foundation rules
53
+ * first, then the skills install family, then the packs install family — the
54
+ * same order the design doc tables list them in.
55
+ *
56
+ * @experimental This API is unstable and may change without notice.
57
+ */
58
+ export const workspaceRules = [
59
+ // Foundation (type-agnostic workspace well-formedness).
60
+ initializedRule,
61
+ settingsSchemaValidRule,
62
+ lockfileValidRule,
63
+ agentsRecognizedRule,
64
+ agentsDetectedDeclaredRule,
65
+ // Skills install family (Settings ↔ Lockfile ↔ Disk).
66
+ skillsDeclarationsValidRule,
67
+ skillsLockfileAlignedRule,
68
+ skillsIntegrityValidRule,
69
+ skillsArtifactsCorrectRule,
70
+ skillsArtifactsCleanRule,
71
+ // Packs install family (Settings ↔ Lockfile).
72
+ packsDeclarationsValidRule,
73
+ packsDependenciesResolvedRule,
74
+ packsMembersRetainedRule,
75
+ ];
76
+ // Register ids into the `LintConfig.rules` allowlist. Module-load side effect:
77
+ // a consumer that imports this catalog (or the `catalog/index` barrel) enables
78
+ // `.axm/settings.json` `lint.rules` to reference any of the above rule ids.
79
+ registerLintRuleIds(workspaceRules.map((r) => r.id));
80
+ //# sourceMappingURL=workspace.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"workspace.js","sourceRoot":"","sources":["../../../../../src/unstable/lint/catalog/workspace.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAiCG;AAEH,OAAO,EAAE,mBAAmB,EAAE,MAAM,cAAc,CAAC;AAGnD,OAAO,EAAE,eAAe,EAAE,MAAM,4BAA4B,CAAC;AAC7D,OAAO,EAAE,uBAAuB,EAAE,MAAM,sCAAsC,CAAC;AAC/E,OAAO,EAAE,iBAAiB,EAAE,MAAM,+BAA+B,CAAC;AAClE,OAAO,EAAE,oBAAoB,EAAE,MAAM,kCAAkC,CAAC;AACxE,OAAO,EAAE,0BAA0B,EAAE,MAAM,yCAAyC,CAAC;AACrF,OAAO,EAAE,2BAA2B,EAAE,MAAM,0CAA0C,CAAC;AACvF,OAAO,EAAE,yBAAyB,EAAE,MAAM,wCAAwC,CAAC;AACnF,OAAO,EAAE,wBAAwB,EAAE,MAAM,uCAAuC,CAAC;AACjF,OAAO,EAAE,0BAA0B,EAAE,MAAM,yCAAyC,CAAC;AACrF,OAAO,EAAE,wBAAwB,EAAE,MAAM,uCAAuC,CAAC;AACjF,OAAO,EAAE,0BAA0B,EAAE,MAAM,yCAAyC,CAAC;AACrF,OAAO,EAAE,6BAA6B,EAAE,MAAM,4CAA4C,CAAC;AAC3F,OAAO,EAAE,wBAAwB,EAAE,MAAM,uCAAuC,CAAC;AAEjF;;;;;;;;GAQG;AACH,MAAM,CAAC,MAAM,cAAc,GAAkD;IAC3E,wDAAwD;IACxD,eAAe;IACf,uBAAuB;IACvB,iBAAiB;IACjB,oBAAoB;IACpB,0BAA0B;IAC1B,sDAAsD;IACtD,2BAA2B;IAC3B,yBAAyB;IACzB,wBAAwB;IACxB,0BAA0B;IAC1B,wBAAwB;IACxB,8CAA8C;IAC9C,0BAA0B;IAC1B,6BAA6B;IAC7B,wBAAwB;CACzB,CAAC;AAEF,+EAA+E;AAC/E,+EAA+E;AAC/E,4EAA4E;AAC5E,mBAAmB,CAAC,cAAc,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC"}
@@ -0,0 +1,297 @@
1
+ /**
2
+ * Lint runner — the reusable core of `axm lint`.
3
+ *
4
+ * The `axm lint` CLI command file is a thin surface over flag parsing and
5
+ * rendering; the logic that evaluates rule catalogs, renders findings, detects
6
+ * publish-gate drift, and (under `--fix`) composes the autofix plan lives in
7
+ * this module.
8
+ *
9
+ * Phase 5 entry points (see `openspec/changes/add-lint-engine/tasks.md`):
10
+ *
11
+ * - {@link evaluateAllCatalogs} — concurrent evaluation of the three
12
+ * v1 rule catalogs against pre-built contexts.
13
+ * - {@link summarizeEvaluations} — group, count, and derive the exit
14
+ * category from raw `Evaluated<*>` lists.
15
+ * - {@link detectPublishGateDrift} — compute whether the configured
16
+ * `LintConfig` weakens any `skill/*` / `pack/*` platform-default-`error`
17
+ * rule (task 5.7).
18
+ * - {@link renderFindingsText} — finding-first human renderer (task
19
+ * 5.6).
20
+ * - {@link toLintJsonDocument} — `--json` document shape (task 5.6).
21
+ * - {@link resolveLintExitCategory} — exit-code contract evaluator (task
22
+ * 5.9).
23
+ *
24
+ * Lint-intent → canonical `Operation` adapter composition happens in the CLI
25
+ * handler (`packages/cli/src/root/lint/handler.ts`), which re-resolves each
26
+ * intent's `source` via the `resolveConfigured*` helpers and hands the
27
+ * resulting canonical Operation to the per-extension plan-step builder. The
28
+ * runner here stays accessor-free.
29
+ *
30
+ * @experimental This API is unstable and may change without notice.
31
+ * @packageDocumentation
32
+ */
33
+ import * as Effect from "effect/Effect";
34
+ import type { LintConfig } from "./config.js";
35
+ import { platformCanonicalLintConfig } from "./config.js";
36
+ import type { Evaluated } from "./evaluate.js";
37
+ import type { PackRuleContext, SkillRuleContext, WorkspaceRuleContext } from "./context.js";
38
+ import type { AutofixingRule, LintFinding, Severity } from "./rule.js";
39
+ /**
40
+ * A single finding annotated with the context that produced it.
41
+ *
42
+ * `displayRoot` carries the context's rendering root; `path` is the
43
+ * pre-composed display path for the finding so consumers (text / JSON /
44
+ * summary logs) don't re-derive it.
45
+ *
46
+ * @experimental This API is unstable and may change without notice.
47
+ */
48
+ export interface RenderedFinding {
49
+ readonly group: "skill" | "pack" | "workspace";
50
+ readonly displayRoot: string;
51
+ readonly path: string;
52
+ readonly finding: LintFinding;
53
+ }
54
+ /**
55
+ * Per-group evaluation result. The raw `Evaluated<*>` list is retained so
56
+ * downstream consumers (render, JSON emitter, `collectFixOperations`) can
57
+ * walk evaluations without re-running rules.
58
+ *
59
+ * @experimental This API is unstable and may change without notice.
60
+ */
61
+ export interface GroupEvaluations {
62
+ readonly skills: ReadonlyArray<Evaluated<SkillRuleContext>>;
63
+ readonly packs: ReadonlyArray<Evaluated<PackRuleContext>>;
64
+ readonly workspace: ReadonlyArray<Evaluated<WorkspaceRuleContext>>;
65
+ }
66
+ /**
67
+ * Aggregate counts across all emitted findings.
68
+ *
69
+ * `total` === `errors + warnings + infos` — info findings participate in
70
+ * rendering and in the JSON envelope, but never influence exit code.
71
+ *
72
+ * @experimental This API is unstable and may change without notice.
73
+ */
74
+ export interface FindingCounts {
75
+ readonly total: number;
76
+ readonly errors: number;
77
+ readonly warnings: number;
78
+ readonly infos: number;
79
+ }
80
+ /**
81
+ * Possible exit-code categories for `axm lint`.
82
+ *
83
+ * - `"clean"` — zero findings, or only info-severity findings; zero exit.
84
+ * - `"warnings"` — at least one warning, no errors; non-zero only when
85
+ * `--strict` is set (see {@link resolveLintExitCategory}).
86
+ * - `"errors"` — at least one error; non-zero exit regardless of flags.
87
+ *
88
+ * @experimental This API is unstable and may change without notice.
89
+ */
90
+ export type LintExitCategory = "clean" | "warnings" | "errors";
91
+ /**
92
+ * Build the three v1 evaluation groups concurrently.
93
+ *
94
+ * The evaluator is a pure `Effect.Effect<ReadonlyArray<Evaluated<C>>>`; this
95
+ * helper simply hands the three catalogs to `Effect.all` with unbounded
96
+ * concurrency so catalog evaluations run in parallel but findings stay in
97
+ * stable catalog order inside each group.
98
+ *
99
+ * @experimental This API is unstable and may change without notice.
100
+ */
101
+ export declare const evaluateAllCatalogs: (args: {
102
+ readonly skillContexts: ReadonlyArray<SkillRuleContext>;
103
+ readonly packContexts: ReadonlyArray<PackRuleContext>;
104
+ readonly workspaceContext: WorkspaceRuleContext;
105
+ readonly config: LintConfig;
106
+ }) => Effect.Effect<GroupEvaluations>;
107
+ /**
108
+ * Flatten a {@link GroupEvaluations} triple into a single `RenderedFinding[]`
109
+ * in stable group-then-catalog order.
110
+ *
111
+ * @experimental This API is unstable and may change without notice.
112
+ */
113
+ export declare const collectRenderedFindings: (evaluations: GroupEvaluations) => ReadonlyArray<RenderedFinding>;
114
+ /**
115
+ * Count findings by severity across every group.
116
+ *
117
+ * @experimental This API is unstable and may change without notice.
118
+ */
119
+ export declare const countFindings: (findings: ReadonlyArray<RenderedFinding>) => FindingCounts;
120
+ /**
121
+ * Aggregated summary — counts + derived exit category — computed from a
122
+ * {@link GroupEvaluations} triple.
123
+ *
124
+ * @experimental This API is unstable and may change without notice.
125
+ */
126
+ export interface LintSummary {
127
+ readonly findings: ReadonlyArray<RenderedFinding>;
128
+ readonly counts: FindingCounts;
129
+ readonly exitCategory: LintExitCategory;
130
+ readonly driftBanner: ReadonlyArray<string>;
131
+ }
132
+ /**
133
+ * Derive a full {@link LintSummary} (findings, counts, exit category, drift
134
+ * banner rule ids) from raw evaluations + the configured severity overrides.
135
+ *
136
+ * @experimental This API is unstable and may change without notice.
137
+ */
138
+ export declare const summarizeEvaluations: (evaluations: GroupEvaluations, config: LintConfig) => LintSummary;
139
+ /**
140
+ * Translate a {@link LintExitCategory} + `--strict` into the exit-code
141
+ * policy.
142
+ *
143
+ * | Category | --strict=false | --strict=true |
144
+ * | ------------ | -------------- | ------------- |
145
+ * | `"clean"` | `0` | `0` |
146
+ * | `"warnings"` | `0` | non-zero |
147
+ * | `"errors"` | non-zero | non-zero |
148
+ *
149
+ * The return value is a discriminated enum; the CLI handler maps the `"fail"`
150
+ * branch to its platform exit-code primitive.
151
+ *
152
+ * @experimental This API is unstable and may change without notice.
153
+ */
154
+ export declare const resolveLintExitCategory: (args: {
155
+ readonly category: LintExitCategory;
156
+ readonly strict: boolean;
157
+ }) => "success" | "fail";
158
+ /**
159
+ * Identify every configured `lint.rules` entry that weakens a platform-canonical
160
+ * `error`-severity `skill/*` or `pack/*` rule.
161
+ *
162
+ * The publish gate runs the `skill/*` and `pack/*` catalogs against
163
+ * {@link platformCanonicalLintConfig}; any workspace override that lowers a
164
+ * rule in those namespaces from `error` to `off | info | warn` creates a
165
+ * publish-gate divergence the user should know about (they'll see `error`
166
+ * findings from the registry that don't appear locally).
167
+ *
168
+ * Workspace-only rule weakenings (`workspace/*`) do NOT trigger the banner —
169
+ * those never reach publish.
170
+ *
171
+ * Returns the rule ids that trigger the banner, in catalog order, so the
172
+ * renderer can produce stable deterministic output.
173
+ *
174
+ * @experimental This API is unstable and may change without notice.
175
+ */
176
+ export declare const detectPublishGateDrift: (config: LintConfig) => ReadonlyArray<string>;
177
+ /**
178
+ * Input for the human text renderer.
179
+ *
180
+ * The `fixSummary` slot is reserved for the trailing `--fix` summary line
181
+ * (populated after `applyPlan` completes). When `undefined`, no summary is
182
+ * rendered — the read-only `axm lint` run.
183
+ *
184
+ * @experimental This API is unstable and may change without notice.
185
+ */
186
+ export interface RenderFindingsArgs {
187
+ readonly summary: LintSummary;
188
+ readonly fixSummary?: FixSummary;
189
+ }
190
+ /**
191
+ * Outcome of a `--fix` run; used by the renderer and the JSON emitter.
192
+ *
193
+ * @experimental This API is unstable and may change without notice.
194
+ */
195
+ export interface FixSummary {
196
+ readonly attempted: number;
197
+ readonly applied: number;
198
+ readonly failed: number;
199
+ readonly warnings: ReadonlyArray<string>;
200
+ }
201
+ /**
202
+ * Render a finding-first human text report.
203
+ *
204
+ * Output shape (one line per entry, grouped first by context type then by
205
+ * severity within each group):
206
+ *
207
+ * DRIFT: The registry will still block publish on these rules:
208
+ * - skill/manifest-schema-valid
209
+ *
210
+ * WORKSPACE
211
+ * [error] workspace/lockfile-valid axm-lock.yaml is missing. ./axm-lock.yaml
212
+ * [warning] workspace/... ...
213
+ *
214
+ * SKILLS
215
+ * [error] ...
216
+ *
217
+ * Summary: 2 errors, 1 warning.
218
+ * Applied 3 fixes; 1 warning surfaced from applyPlan.
219
+ *
220
+ * @experimental This API is unstable and may change without notice.
221
+ */
222
+ export declare const renderFindingsText: (args: RenderFindingsArgs) => ReadonlyArray<string>;
223
+ /**
224
+ * JSON-renderable finding entry used by the `--json` document.
225
+ *
226
+ * @experimental This API is unstable and may change without notice.
227
+ */
228
+ export interface LintJsonFinding {
229
+ readonly group: "skill" | "pack" | "workspace";
230
+ readonly kind: "autofixable" | "advisory";
231
+ readonly ruleId: string;
232
+ readonly severity: Severity;
233
+ readonly message: string;
234
+ readonly displayRoot: string;
235
+ readonly path: string;
236
+ readonly location?: {
237
+ readonly file: string;
238
+ readonly line?: number;
239
+ readonly column?: number;
240
+ };
241
+ readonly suggestions: ReadonlyArray<string>;
242
+ }
243
+ /**
244
+ * JSON envelope shape returned under `axm lint --json`.
245
+ *
246
+ * Mirrors the design doc §9 envelope for the CLI and matches the registry
247
+ * publish failure envelope structure (`findings[]`, `displayRoot` per entry,
248
+ * per-finding `path` pre-composed). `--fix` runs add a `fix` summary block.
249
+ *
250
+ * @experimental This API is unstable and may change without notice.
251
+ */
252
+ export interface LintJsonDocument {
253
+ readonly findings: ReadonlyArray<LintJsonFinding>;
254
+ readonly summary: {
255
+ readonly total: number;
256
+ readonly errors: number;
257
+ readonly warnings: number;
258
+ readonly infos: number;
259
+ readonly exitCategory: LintExitCategory;
260
+ };
261
+ readonly driftBanner: ReadonlyArray<string>;
262
+ readonly fix?: {
263
+ readonly attempted: number;
264
+ readonly applied: number;
265
+ readonly failed: number;
266
+ readonly warnings: ReadonlyArray<string>;
267
+ };
268
+ }
269
+ /**
270
+ * Build the `--json` document from a {@link LintSummary} (+ optional fix
271
+ * summary).
272
+ *
273
+ * @experimental This API is unstable and may change without notice.
274
+ */
275
+ export declare const toLintJsonDocument: (args: {
276
+ readonly summary: LintSummary;
277
+ readonly fixSummary?: FixSummary;
278
+ }) => LintJsonDocument;
279
+ /**
280
+ * Walk workspace evaluations (the only v1 namespace that ships
281
+ * `AutofixingRule`s) and return the set of `(rule, finding, context)` triples
282
+ * the CLI handler can dispatch on to produce canonical Operations.
283
+ *
284
+ * The returned triples point at the already-evaluated `AutofixableFinding`
285
+ * values so the renderer and the fix pipeline share a single source of truth.
286
+ *
287
+ * @experimental This API is unstable and may change without notice.
288
+ */
289
+ export declare const collectAutofixableEntries: (evaluations: GroupEvaluations) => ReadonlyArray<{
290
+ readonly rule: AutofixingRule<WorkspaceRuleContext>;
291
+ readonly context: WorkspaceRuleContext;
292
+ readonly finding: LintFinding & {
293
+ readonly kind: "autofixable";
294
+ };
295
+ }>;
296
+ export { platformCanonicalLintConfig };
297
+ //# sourceMappingURL=cli.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"cli.d.ts","sourceRoot":"","sources":["../../../../src/unstable/lint/cli.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+BG;AAEH,OAAO,KAAK,MAAM,MAAM,eAAe,CAAC;AAExC,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AAC9C,OAAO,EAAE,2BAA2B,EAAE,MAAM,aAAa,CAAC;AAC1D,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,eAAe,CAAC;AAE/C,OAAO,KAAK,EAAE,eAAe,EAAE,gBAAgB,EAAE,oBAAoB,EAAE,MAAM,cAAc,CAAC;AAC5F,OAAO,KAAK,EAAE,cAAc,EAAE,WAAW,EAAE,QAAQ,EAAE,MAAM,WAAW,CAAC;AAOvE;;;;;;;;GAQG;AACH,MAAM,WAAW,eAAe;IAC9B,QAAQ,CAAC,KAAK,EAAE,OAAO,GAAG,MAAM,GAAG,WAAW,CAAC;IAC/C,QAAQ,CAAC,WAAW,EAAE,MAAM,CAAC;IAC7B,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,OAAO,EAAE,WAAW,CAAC;CAC/B;AAED;;;;;;GAMG;AACH,MAAM,WAAW,gBAAgB;IAC/B,QAAQ,CAAC,MAAM,EAAE,aAAa,CAAC,SAAS,CAAC,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