@wildo-ai/dev-companion 1.1.2 → 1.1.4

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 (540) hide show
  1. package/dist/esm/.tsbuildinfo +1 -1
  2. package/dist/esm/__tests__/asset-noop.d.ts.map +1 -1
  3. package/dist/esm/__tests__/chdir-dogfood-app.setup.d.ts.map +1 -1
  4. package/dist/esm/__tests__/internal-test-view.d.ts.map +1 -1
  5. package/dist/esm/brand/models/logo-creative-brief.schemas.d.ts.map +1 -1
  6. package/dist/esm/brand/models/logo-generation.actors-system.definitions.d.ts.map +1 -1
  7. package/dist/esm/brand/models/logo-judge.actors-system.definitions.d.ts.map +1 -1
  8. package/dist/esm/brand/models/logo-judge.actors-system.definitions.js +9 -3
  9. package/dist/esm/brand/models/logo-judge.actors-system.definitions.js.map +1 -1
  10. package/dist/esm/brand/models/logo-judge.schemas.d.ts.map +1 -1
  11. package/dist/esm/brand/services/brand-accept.companion.service.d.ts +3 -24
  12. package/dist/esm/brand/services/brand-accept.companion.service.d.ts.map +1 -1
  13. package/dist/esm/brand/services/brand-accept.companion.service.js +10 -48
  14. package/dist/esm/brand/services/brand-accept.companion.service.js.map +1 -1
  15. package/dist/esm/brand/services/logo-deliberation.companion.service.d.ts.map +1 -1
  16. package/dist/esm/brand/services/logo-deliberation.companion.service.js +2 -8
  17. package/dist/esm/brand/services/logo-deliberation.companion.service.js.map +1 -1
  18. package/dist/esm/brand/services/logo-generation.companion.service.d.ts +6 -3
  19. package/dist/esm/brand/services/logo-generation.companion.service.d.ts.map +1 -1
  20. package/dist/esm/brand/services/logo-generation.companion.service.js +11 -12
  21. package/dist/esm/brand/services/logo-generation.companion.service.js.map +1 -1
  22. package/dist/esm/brand/utils/derived-brand-assets.d.ts +0 -1
  23. package/dist/esm/brand/utils/derived-brand-assets.d.ts.map +1 -1
  24. package/dist/esm/brand/utils/derived-brand-assets.js +1 -2
  25. package/dist/esm/brand/utils/derived-brand-assets.js.map +1 -1
  26. package/dist/esm/brand/utils/stage-brand-candidate.d.ts +7 -9
  27. package/dist/esm/brand/utils/stage-brand-candidate.d.ts.map +1 -1
  28. package/dist/esm/brand/utils/stage-brand-candidate.js +8 -11
  29. package/dist/esm/brand/utils/stage-brand-candidate.js.map +1 -1
  30. package/dist/esm/claude-cli/models/coding-agent-dispatch.models.d.ts +52 -2
  31. package/dist/esm/claude-cli/models/coding-agent-dispatch.models.d.ts.map +1 -1
  32. package/dist/esm/claude-cli/models/coding-agent-dispatch.models.js +45 -0
  33. package/dist/esm/claude-cli/models/coding-agent-dispatch.models.js.map +1 -1
  34. package/dist/esm/claude-cli/services/coding-agent-dispatch.companion.service.d.ts +45 -5
  35. package/dist/esm/claude-cli/services/coding-agent-dispatch.companion.service.d.ts.map +1 -1
  36. package/dist/esm/claude-cli/services/coding-agent-dispatch.companion.service.js +180 -9
  37. package/dist/esm/claude-cli/services/coding-agent-dispatch.companion.service.js.map +1 -1
  38. package/dist/esm/claude-cli/services/git-change-set.companion.service.d.ts +12 -22
  39. package/dist/esm/claude-cli/services/git-change-set.companion.service.d.ts.map +1 -1
  40. package/dist/esm/claude-cli/services/git-change-set.companion.service.js +151 -82
  41. package/dist/esm/claude-cli/services/git-change-set.companion.service.js.map +1 -1
  42. package/dist/esm/claude-cli/services/research-agent-dispatch.companion.service.d.ts +30 -4
  43. package/dist/esm/claude-cli/services/research-agent-dispatch.companion.service.d.ts.map +1 -1
  44. package/dist/esm/claude-cli/services/research-agent-dispatch.companion.service.js +30 -4
  45. package/dist/esm/claude-cli/services/research-agent-dispatch.companion.service.js.map +1 -1
  46. package/dist/esm/claude-cli/services/research-evidence-store.companion.d.ts +1 -1
  47. package/dist/esm/claude-cli/services/research-evidence-store.companion.d.ts.map +1 -1
  48. package/dist/esm/claude-cli/services/research-evidence-store.companion.js +1 -1
  49. package/dist/esm/claude-cli/services/research-evidence-store.companion.js.map +1 -1
  50. package/dist/esm/code-compliance-check/check-label-placeholder-contract.companion.d.ts.map +1 -1
  51. package/dist/esm/code-compliance-check/check-raw-feature-id-literals.companion.d.ts.map +1 -1
  52. package/dist/esm/companion-api/companion-api.schemas.d.ts +57 -57
  53. package/dist/esm/companion-api/companion-api.schemas.d.ts.map +1 -1
  54. package/dist/esm/companion-api/controllers/companion-i18n-api-contract.utils.d.ts.map +1 -1
  55. package/dist/esm/companion-api/controllers/companion-token-floor.policy.d.ts +90 -0
  56. package/dist/esm/companion-api/controllers/companion-token-floor.policy.d.ts.map +1 -0
  57. package/dist/esm/companion-api/controllers/companion-token-floor.policy.js +98 -0
  58. package/dist/esm/companion-api/controllers/companion-token-floor.policy.js.map +1 -0
  59. package/dist/esm/companion-api/controllers/companion.controller.d.ts +32 -5
  60. package/dist/esm/companion-api/controllers/companion.controller.d.ts.map +1 -1
  61. package/dist/esm/companion-api/controllers/companion.controller.js +126 -41
  62. package/dist/esm/companion-api/controllers/companion.controller.js.map +1 -1
  63. package/dist/esm/core/auth/companion-auth-floor.companion.service.d.ts +8 -1
  64. package/dist/esm/core/auth/companion-auth-floor.companion.service.d.ts.map +1 -1
  65. package/dist/esm/core/auth/companion-auth-floor.companion.service.js +8 -1
  66. package/dist/esm/core/auth/companion-auth-floor.companion.service.js.map +1 -1
  67. package/dist/esm/core/catalogs/catalog-context.factory.d.ts.map +1 -1
  68. package/dist/esm/core/catalogs/catalog-context.factory.models.d.ts.map +1 -1
  69. package/dist/esm/core/catalogs/schema-org/aggregate-offer-catalog-context.factory.d.ts.map +1 -1
  70. package/dist/esm/core/catalogs/schema-org/aggregate-rating-catalog-context.factory.d.ts.map +1 -1
  71. package/dist/esm/core/catalogs/schema-org/article-catalog-context.factory.d.ts.map +1 -1
  72. package/dist/esm/core/catalogs/schema-org/blog-posting-catalog-context.factory.d.ts.map +1 -1
  73. package/dist/esm/core/catalogs/schema-org/breadcrumb-list-catalog-context.factory.d.ts.map +1 -1
  74. package/dist/esm/core/catalogs/schema-org/faq-page-catalog-context.factory.d.ts.map +1 -1
  75. package/dist/esm/core/catalogs/schema-org/offer-catalog-context.factory.d.ts.map +1 -1
  76. package/dist/esm/core/catalogs/schema-org/organization-catalog-context.factory.d.ts.map +1 -1
  77. package/dist/esm/core/catalogs/schema-org/product-catalog-context.factory.d.ts.map +1 -1
  78. package/dist/esm/core/catalogs/schema-org/review-catalog-context.factory.d.ts.map +1 -1
  79. package/dist/esm/core/catalogs/schema-org/schema-org-catalog-boundary.shared.d.ts +34 -0
  80. package/dist/esm/core/catalogs/schema-org/schema-org-catalog-boundary.shared.d.ts.map +1 -0
  81. package/dist/esm/core/catalogs/schema-org/schema-org-catalog-boundary.shared.js +65 -0
  82. package/dist/esm/core/catalogs/schema-org/schema-org-catalog-boundary.shared.js.map +1 -0
  83. package/dist/esm/core/catalogs/schema-org/schema-org-catalog-context.shared.d.ts +11 -1
  84. package/dist/esm/core/catalogs/schema-org/schema-org-catalog-context.shared.d.ts.map +1 -1
  85. package/dist/esm/core/catalogs/schema-org/schema-org-catalog-context.shared.js.map +1 -1
  86. package/dist/esm/core/catalogs/schema-org/software-application-catalog-context.factory.d.ts.map +1 -1
  87. package/dist/esm/core/catalogs/schema-org/website-catalog-context.factory.d.ts.map +1 -1
  88. package/dist/esm/core/catalogs/structured-data-catalog-audit.service.d.ts.map +1 -1
  89. package/dist/esm/core/catalogs/structured-data-catalog-audit.service.js +10 -2
  90. package/dist/esm/core/catalogs/structured-data-catalog-audit.service.js.map +1 -1
  91. package/dist/esm/core/config/primary-language.companion.utils.d.ts.map +1 -1
  92. package/dist/esm/core/context/companion-context.d.ts.map +1 -1
  93. package/dist/esm/core/context/companion-package-loaders.companion.d.ts.map +1 -1
  94. package/dist/esm/core/inject/models/container.d.ts.map +1 -1
  95. package/dist/esm/core/inject/models/container.js +0 -7
  96. package/dist/esm/core/inject/models/container.js.map +1 -1
  97. package/dist/esm/core/inject/models/service-types.d.ts +0 -1
  98. package/dist/esm/core/inject/models/service-types.d.ts.map +1 -1
  99. package/dist/esm/core/inject/models/service-types.js +0 -1
  100. package/dist/esm/core/inject/models/service-types.js.map +1 -1
  101. package/dist/esm/core/introspection/behaviors/companion-introspection-behavior-definitions.d.ts.map +1 -1
  102. package/dist/esm/core/introspection/models/companion-introspection.models.d.ts.map +1 -1
  103. package/dist/esm/core/introspection/resources/creation-plane-dispatch.custom-impl.companion.service.d.ts.map +1 -1
  104. package/dist/esm/core/introspection/resources/creation-plane-dispatch.custom-impl.companion.service.js +8 -4
  105. package/dist/esm/core/introspection/resources/creation-plane-dispatch.custom-impl.companion.service.js.map +1 -1
  106. package/dist/esm/core/introspection/resources/creation-plane-projection.companion.service.d.ts.map +1 -1
  107. package/dist/esm/core/introspection/resources/creation-plane-projection.companion.service.js.map +1 -1
  108. package/dist/esm/core/introspection/resources/introspection-resource-notifier.companion.service.d.ts.map +1 -1
  109. package/dist/esm/core/introspection/resources/introspection-resource-source.companion.service.d.ts.map +1 -1
  110. package/dist/esm/core/introspection/services/companion-introspection-behavior-registry.companion.service.d.ts.map +1 -1
  111. package/dist/esm/core/introspection/services/companion-introspection.companion.service.d.ts.map +1 -1
  112. package/dist/esm/core/introspection/services/companion-introspection.companion.service.js +42 -1
  113. package/dist/esm/core/introspection/services/companion-introspection.companion.service.js.map +1 -1
  114. package/dist/esm/core/introspection/services/introspection-derivation-state.companion.service.d.ts.map +1 -1
  115. package/dist/esm/core/introspection/services/introspection-source-state.companion.service.d.ts.map +1 -1
  116. package/dist/esm/core/introspection/services/introspection-source-watcher.companion.service.d.ts.map +1 -1
  117. package/dist/esm/core/introspection/services/translation-placement.companion.service.d.ts.map +1 -1
  118. package/dist/esm/core/introspection/subprocess/application-domain-model.behavior.d.ts.map +1 -1
  119. package/dist/esm/core/introspection/subprocess/application-domain-model.behavior.js.map +1 -1
  120. package/dist/esm/core/introspection/subprocess/assertions.behavior.d.ts.map +1 -1
  121. package/dist/esm/core/introspection/subprocess/asset-noop-hooks.d.ts.map +1 -1
  122. package/dist/esm/core/introspection/subprocess/asset-noop-register.d.ts.map +1 -1
  123. package/dist/esm/core/introspection/subprocess/brand-prompt-renderer.d.ts.map +1 -1
  124. package/dist/esm/core/introspection/subprocess/chart-registration-refs.behavior.d.ts.map +1 -1
  125. package/dist/esm/core/introspection/subprocess/companion-introspection-behavior-handlers.d.ts.map +1 -1
  126. package/dist/esm/core/introspection/subprocess/companion-introspection-behavior-handlers.js +3 -2
  127. package/dist/esm/core/introspection/subprocess/companion-introspection-behavior-handlers.js.map +1 -1
  128. package/dist/esm/core/introspection/subprocess/companion-introspection-child.d.ts.map +1 -1
  129. package/dist/esm/core/introspection/subprocess/companion-introspection-module-exports.utils.d.ts.map +1 -1
  130. package/dist/esm/core/introspection/subprocess/compliance-primary-facts.behavior.d.ts +14 -5
  131. package/dist/esm/core/introspection/subprocess/compliance-primary-facts.behavior.d.ts.map +1 -1
  132. package/dist/esm/core/introspection/subprocess/compliance-primary-facts.behavior.js +14 -5
  133. package/dist/esm/core/introspection/subprocess/compliance-primary-facts.behavior.js.map +1 -1
  134. package/dist/esm/core/introspection/subprocess/definition-specifications.behavior.d.ts.map +1 -1
  135. package/dist/esm/core/introspection/subprocess/expert-persona-brief.renderer.d.ts.map +1 -1
  136. package/dist/esm/core/introspection/subprocess/family-aspects.behavior.d.ts.map +1 -1
  137. package/dist/esm/core/introspection/subprocess/family-aspects.behavior.js.map +1 -1
  138. package/dist/esm/core/introspection/subprocess/frontend-labels-needed-info.behavior.d.ts.map +1 -1
  139. package/dist/esm/core/introspection/subprocess/market-context-block.builder.d.ts.map +1 -1
  140. package/dist/esm/core/introspection/subprocess/market-prompt-renderer.d.ts.map +1 -1
  141. package/dist/esm/core/introspection/subprocess/openapi-generation-input.behavior.d.ts +38 -1
  142. package/dist/esm/core/introspection/subprocess/openapi-generation-input.behavior.d.ts.map +1 -1
  143. package/dist/esm/core/introspection/subprocess/openapi-generation-input.behavior.js +143 -19
  144. package/dist/esm/core/introspection/subprocess/openapi-generation-input.behavior.js.map +1 -1
  145. package/dist/esm/core/introspection/subprocess/specification-artifacts.behavior.d.ts.map +1 -1
  146. package/dist/esm/core/lock/wildo-saas-lock.companion.service.d.ts +23 -0
  147. package/dist/esm/core/lock/wildo-saas-lock.companion.service.d.ts.map +1 -1
  148. package/dist/esm/core/lock/wildo-saas-lock.companion.service.js +23 -0
  149. package/dist/esm/core/lock/wildo-saas-lock.companion.service.js.map +1 -1
  150. package/dist/esm/core/lock/wildo-saas-lock.models.d.ts.map +1 -1
  151. package/dist/esm/core/lock/wildo-saas-lock.schemas.d.ts +4 -4
  152. package/dist/esm/core/lock/wildo-saas-lock.schemas.d.ts.map +1 -1
  153. package/dist/esm/core/runtime/companion-startup-assembly.d.ts.map +1 -1
  154. package/dist/esm/core/runtime/companion-startup-assembly.js.map +1 -1
  155. package/dist/esm/core/runtime/dev-compile-quiet.companion.d.ts.map +1 -1
  156. package/dist/esm/core/runtime/models/companion-runtime.models.d.ts.map +1 -1
  157. package/dist/esm/core/runtime/services/start-companion-application.service.d.ts +16 -13
  158. package/dist/esm/core/runtime/services/start-companion-application.service.d.ts.map +1 -1
  159. package/dist/esm/core/runtime/services/start-companion-application.service.js +70 -45
  160. package/dist/esm/core/runtime/services/start-companion-application.service.js.map +1 -1
  161. package/dist/esm/core/runtime/utils/companion-local-signing-key.companion.d.ts.map +1 -1
  162. package/dist/esm/core/runtime/utils/companion-platform-config.companion.d.ts.map +1 -1
  163. package/dist/esm/core/runtime/utils/companion-platform-config.companion.js +9 -2
  164. package/dist/esm/core/runtime/utils/companion-platform-config.companion.js.map +1 -1
  165. package/dist/esm/core/runtime/utils/companion-workbench-topology.d.ts.map +1 -1
  166. package/dist/esm/core/runtime/utils/platform-core-domain-modules.companion.d.ts.map +1 -1
  167. package/dist/esm/core/specifications/chart-view-specification-context.factory.d.ts.map +1 -1
  168. package/dist/esm/core/specifications/composite-view-specification-context.factory.d.ts.map +1 -1
  169. package/dist/esm/core/specifications/cross-registry-rendering.shared.d.ts.map +1 -1
  170. package/dist/esm/core/specifications/execution-view-specification-context.factory.d.ts.map +1 -1
  171. package/dist/esm/core/specifications/feature-specification-context.factory.d.ts.map +1 -1
  172. package/dist/esm/core/specifications/flows-actors-view-specification-context.factory.d.ts.map +1 -1
  173. package/dist/esm/core/specifications/frontend-component-specification-context.factory.d.ts.map +1 -1
  174. package/dist/esm/core/specifications/full-custom-view-specification-context.factory.d.ts.map +1 -1
  175. package/dist/esm/core/specifications/guidance-flow-specification-context.factory.d.ts.map +1 -1
  176. package/dist/esm/core/specifications/milestone-specification-context.factory.d.ts.map +1 -1
  177. package/dist/esm/core/specifications/non-composite-view-specification-context.shared.d.ts.map +1 -1
  178. package/dist/esm/core/specifications/onboarding-element-rendering.shared.d.ts.map +1 -1
  179. package/dist/esm/core/specifications/onboarding-view-specification-context.factory.d.ts.map +1 -1
  180. package/dist/esm/core/specifications/product-specification-context.factory.d.ts.map +1 -1
  181. package/dist/esm/core/specifications/resource-specification-context.factory.d.ts.map +1 -1
  182. package/dist/esm/core/specifications/role-specification-context.factory.d.ts.map +1 -1
  183. package/dist/esm/core/specifications/specification-context-factory.d.ts.map +1 -1
  184. package/dist/esm/core/specifications/specification-context-factory.models.d.ts.map +1 -1
  185. package/dist/esm/core/specifications/specification-context-factory.shared.d.ts.map +1 -1
  186. package/dist/esm/core/specifications/system-email-template-specification-context.factory.d.ts.map +1 -1
  187. package/dist/esm/core/specifications/templates/composite-view/composite-view-all-information.template.d.ts.map +1 -1
  188. package/dist/esm/core/specifications/templates/composite-view/composite-view-custom-implementation-context.template.d.ts.map +1 -1
  189. package/dist/esm/core/specifications/templates/composite-view/composite-view-development-usage-context.template.d.ts.map +1 -1
  190. package/dist/esm/core/specifications/templates/composite-view/composite-view-translation-context.template.d.ts.map +1 -1
  191. package/dist/esm/core/specifications/templates/feature/feature-all-information.template.d.ts.map +1 -1
  192. package/dist/esm/core/specifications/templates/feature/feature-custom-implementation-context.template.d.ts.map +1 -1
  193. package/dist/esm/core/specifications/templates/feature/feature-development-usage-context.template.d.ts.map +1 -1
  194. package/dist/esm/core/specifications/templates/feature/feature-translation-context.template.d.ts.map +1 -1
  195. package/dist/esm/core/specifications/templates/frontend-component/frontend-component-all-information.template.d.ts.map +1 -1
  196. package/dist/esm/core/specifications/templates/frontend-component/frontend-component-custom-implementation-context.template.d.ts.map +1 -1
  197. package/dist/esm/core/specifications/templates/frontend-component/frontend-component-development-usage-context.template.d.ts.map +1 -1
  198. package/dist/esm/core/specifications/templates/frontend-component/frontend-component-translation-context.template.d.ts.map +1 -1
  199. package/dist/esm/core/specifications/templates/guidance-flow-specification/guidance-flow-all-information.template.d.ts.map +1 -1
  200. package/dist/esm/core/specifications/templates/guidance-flow-specification/guidance-flow-custom-implementation-context.template.d.ts.map +1 -1
  201. package/dist/esm/core/specifications/templates/guidance-flow-specification/guidance-flow-development-usage-context.template.d.ts.map +1 -1
  202. package/dist/esm/core/specifications/templates/guidance-flow-specification/guidance-flow-translation-context.template.d.ts.map +1 -1
  203. package/dist/esm/core/specifications/templates/milestone/milestone-all-information.template.d.ts.map +1 -1
  204. package/dist/esm/core/specifications/templates/milestone/milestone-custom-implementation-context.template.d.ts.map +1 -1
  205. package/dist/esm/core/specifications/templates/milestone/milestone-development-usage-context.template.d.ts.map +1 -1
  206. package/dist/esm/core/specifications/templates/milestone/milestone-translation-context.template.d.ts.map +1 -1
  207. package/dist/esm/core/specifications/templates/non-composite-view/non-composite-view-all-information.template.d.ts.map +1 -1
  208. package/dist/esm/core/specifications/templates/non-composite-view/non-composite-view-custom-implementation-context.template.d.ts.map +1 -1
  209. package/dist/esm/core/specifications/templates/non-composite-view/non-composite-view-development-usage-context.template.d.ts.map +1 -1
  210. package/dist/esm/core/specifications/templates/non-composite-view/non-composite-view-translation-context.template.d.ts.map +1 -1
  211. package/dist/esm/core/specifications/templates/onboarding-view-specification/onboarding-view-all-information.template.d.ts.map +1 -1
  212. package/dist/esm/core/specifications/templates/onboarding-view-specification/onboarding-view-custom-implementation-context.template.d.ts.map +1 -1
  213. package/dist/esm/core/specifications/templates/onboarding-view-specification/onboarding-view-development-usage-context.template.d.ts.map +1 -1
  214. package/dist/esm/core/specifications/templates/onboarding-view-specification/onboarding-view-translation-context.template.d.ts.map +1 -1
  215. package/dist/esm/core/specifications/templates/product/product-all-information.template.d.ts.map +1 -1
  216. package/dist/esm/core/specifications/templates/product/product-custom-implementation-context.template.d.ts.map +1 -1
  217. package/dist/esm/core/specifications/templates/product/product-development-usage-context.template.d.ts.map +1 -1
  218. package/dist/esm/core/specifications/templates/product/product-translation-context.template.d.ts.map +1 -1
  219. package/dist/esm/core/specifications/templates/resource/resource-all-information.template.d.ts.map +1 -1
  220. package/dist/esm/core/specifications/templates/resource/resource-custom-implementation-context.template.d.ts.map +1 -1
  221. package/dist/esm/core/specifications/templates/resource/resource-development-usage-context.template.d.ts.map +1 -1
  222. package/dist/esm/core/specifications/templates/resource/resource-translation-context.template.d.ts.map +1 -1
  223. package/dist/esm/core/specifications/templates/role/role-all-information.template.d.ts.map +1 -1
  224. package/dist/esm/core/specifications/templates/role/role-custom-implementation-context.template.d.ts.map +1 -1
  225. package/dist/esm/core/specifications/templates/role/role-development-usage-context.template.d.ts.map +1 -1
  226. package/dist/esm/core/specifications/templates/role/role-translation-context.template.d.ts.map +1 -1
  227. package/dist/esm/core/specifications/templates/system-email-template/system-email-template-all-information.template.d.ts.map +1 -1
  228. package/dist/esm/core/specifications/templates/system-email-template/system-email-template-custom-implementation-context.template.d.ts.map +1 -1
  229. package/dist/esm/core/specifications/templates/system-email-template/system-email-template-development-usage-context.template.d.ts.map +1 -1
  230. package/dist/esm/core/specifications/templates/system-email-template/system-email-template-translation-context.template.d.ts.map +1 -1
  231. package/dist/esm/core/specifications/validate-resource-field-completeness.d.ts.map +1 -1
  232. package/dist/esm/core/traceability/companion-agent-call-trace-sink.companion.service.d.ts.map +1 -1
  233. package/dist/esm/core/traceability/companion-agent-call-trace-sink.companion.service.js +4 -4
  234. package/dist/esm/core/traceability/companion-agent-call-trace-sink.companion.service.js.map +1 -1
  235. package/dist/esm/core/traceability/companion-traceability.models.d.ts.map +1 -1
  236. package/dist/esm/core/traceability/companion-traceability.service.d.ts.map +1 -1
  237. package/dist/esm/core/utils/atomic-write.utils.d.ts.map +1 -1
  238. package/dist/esm/deliberations/models/deliberation-agents.actors-system.definitions.d.ts.map +1 -1
  239. package/dist/esm/deliberations/models/deliberation-agents.actors-system.definitions.js +13 -3
  240. package/dist/esm/deliberations/models/deliberation-agents.actors-system.definitions.js.map +1 -1
  241. package/dist/esm/deliberations/services/deliberation.companion.service.d.ts.map +1 -1
  242. package/dist/esm/deliberations/services/deliberation.companion.service.js +0 -5
  243. package/dist/esm/deliberations/services/deliberation.companion.service.js.map +1 -1
  244. package/dist/esm/deliberations/services/structured-deliberation.companion.service.d.ts.map +1 -1
  245. package/dist/esm/deliberations/services/structured-deliberation.companion.service.js +0 -2
  246. package/dist/esm/deliberations/services/structured-deliberation.companion.service.js.map +1 -1
  247. package/dist/esm/deliberations/utils/load-committed-expert-agents.d.ts.map +1 -1
  248. package/dist/esm/email/models/email-template.actors-system.definitions.d.ts.map +1 -1
  249. package/dist/esm/email/models/email-template.actors-system.definitions.js +4 -2
  250. package/dist/esm/email/models/email-template.actors-system.definitions.js.map +1 -1
  251. package/dist/esm/email/services/email-spec-context-loader.companion.service.d.ts +1 -1
  252. package/dist/esm/email/services/email-spec-context-loader.companion.service.d.ts.map +1 -1
  253. package/dist/esm/email/services/email-spec-context-loader.companion.service.js +1 -1
  254. package/dist/esm/email/services/email-spec-context-loader.companion.service.js.map +1 -1
  255. package/dist/esm/email/services/email-template.companion.service.d.ts.map +1 -1
  256. package/dist/esm/email/services/email-template.companion.service.js +23 -1
  257. package/dist/esm/email/services/email-template.companion.service.js.map +1 -1
  258. package/dist/esm/email/utils/email-labels-file-source.utils.d.ts.map +1 -1
  259. package/dist/esm/email/utils/email-template-fs-discovery.utils.d.ts.map +1 -1
  260. package/dist/esm/executions/services/companion-executions.companion.service.d.ts.map +1 -1
  261. package/dist/esm/executions/services/companion-executions.companion.service.js +15 -2
  262. package/dist/esm/executions/services/companion-executions.companion.service.js.map +1 -1
  263. package/dist/esm/expert-personas/models/expert-persona-critique.actors-system.definitions.d.ts.map +1 -1
  264. package/dist/esm/expert-personas/models/expert-persona-critique.actors-system.definitions.js +7 -3
  265. package/dist/esm/expert-personas/models/expert-persona-critique.actors-system.definitions.js.map +1 -1
  266. package/dist/esm/expert-personas/models/expert-persona-derivation.actors-system.definitions.d.ts.map +1 -1
  267. package/dist/esm/expert-personas/models/expert-persona-derivation.actors-system.definitions.js +11 -5
  268. package/dist/esm/expert-personas/models/expert-persona-derivation.actors-system.definitions.js.map +1 -1
  269. package/dist/esm/expert-personas/models/expert-persona-derivation.schemas.d.ts.map +1 -1
  270. package/dist/esm/expert-personas/services/expert-persona.companion.service.d.ts +9 -24
  271. package/dist/esm/expert-personas/services/expert-persona.companion.service.d.ts.map +1 -1
  272. package/dist/esm/expert-personas/services/expert-persona.companion.service.js +11 -60
  273. package/dist/esm/expert-personas/services/expert-persona.companion.service.js.map +1 -1
  274. package/dist/esm/i18n/components/APPLICATION_LEVEL_ACTIVITY_BAR.en.d.ts.map +1 -1
  275. package/dist/esm/i18n/components/APPLICATION_LEVEL_COMMAND_MENU.en.d.ts.map +1 -1
  276. package/dist/esm/i18n/components/APPLICATION_LEVEL_CONTROL_PANEL.en.d.ts.map +1 -1
  277. package/dist/esm/i18n/components/APPLICATION_LEVEL_MENUBAR.en.d.ts.map +1 -1
  278. package/dist/esm/i18n/components/APPLICATION_LEVEL_NAVIGATION_BACK.en.d.ts.map +1 -1
  279. package/dist/esm/i18n/components/APPLICATION_LEVEL_NOTIFICATION_CENTER.en.d.ts.map +1 -1
  280. package/dist/esm/i18n/components/APPLICATION_LEVEL_QUICK_ACTION_BUTTON.en.d.ts.map +1 -1
  281. package/dist/esm/i18n/components/APPLICATION_LEVEL_QUICK_SWITCHER.en.d.ts.map +1 -1
  282. package/dist/esm/i18n/components/APPLICATION_LEVEL_SIDEBAR.en.d.ts.map +1 -1
  283. package/dist/esm/i18n/components/APPLICATION_LEVEL_STATUS_BAR.en.d.ts.map +1 -1
  284. package/dist/esm/i18n/components/APPLICATION_LEVEL_TOOLBAR.en.d.ts.map +1 -1
  285. package/dist/esm/i18n/components/APPLICATION_LEVEL_USER_DROPDOWN.en.d.ts.map +1 -1
  286. package/dist/esm/i18n/components/APPLICATION_LEVEL_UTILITY_PANEL.en.d.ts.map +1 -1
  287. package/dist/esm/i18n/components/APP_LAYOUTS_APPEARANCE_SETTINGS.en.d.ts.map +1 -1
  288. package/dist/esm/i18n/components/APP_LAYOUTS_BILLING_SETTINGS.en.d.ts.map +1 -1
  289. package/dist/esm/i18n/components/APP_LAYOUTS_ERROR_BOUNDARY.en.d.ts.map +1 -1
  290. package/dist/esm/i18n/components/APP_LAYOUTS_HOME.en.d.ts.map +1 -1
  291. package/dist/esm/i18n/components/APP_LAYOUTS_INVITATIONS_SETTINGS.en.d.ts.map +1 -1
  292. package/dist/esm/i18n/components/APP_LAYOUTS_MAIN_CONTAINER.en.d.ts.map +1 -1
  293. package/dist/esm/i18n/components/APP_LAYOUTS_ROUTER_ERROR_BOUNDARY.en.d.ts.map +1 -1
  294. package/dist/esm/i18n/components/APP_LAYOUTS_SECURITY_SETTINGS.en.d.ts.map +1 -1
  295. package/dist/esm/i18n/components/APP_LAYOUTS_SETTINGS_HUB.en.d.ts.map +1 -1
  296. package/dist/esm/i18n/components/HIGH_LEVEL_VIEWS_CHART.en.d.ts.map +1 -1
  297. package/dist/esm/i18n/components/HIGH_LEVEL_VIEWS_CHART_WIDGET.en.d.ts.map +1 -1
  298. package/dist/esm/i18n/components/HIGH_LEVEL_VIEWS_EXECUTION.en.d.ts.map +1 -1
  299. package/dist/esm/i18n/components/HIGH_LEVEL_VIEWS_FLOWS_ACTORS.en.d.ts.map +1 -1
  300. package/dist/esm/i18n/components/HIGH_LEVEL_VIEWS_NOT_FOUND.en.d.ts.map +1 -1
  301. package/dist/esm/i18n/components/LOW_LEVEL_ACTION_BAR.en.d.ts.map +1 -1
  302. package/dist/esm/i18n/components/LOW_LEVEL_AI_ACTOR.en.d.ts.map +1 -1
  303. package/dist/esm/i18n/components/LOW_LEVEL_AI_AGENT_CONFIG.en.d.ts.map +1 -1
  304. package/dist/esm/i18n/components/LOW_LEVEL_AI_APPROVAL.en.d.ts.map +1 -1
  305. package/dist/esm/i18n/components/LOW_LEVEL_AI_ARTIFACT.en.d.ts.map +1 -1
  306. package/dist/esm/i18n/components/LOW_LEVEL_AI_ARTIFACT_BROWSER.en.d.ts.map +1 -1
  307. package/dist/esm/i18n/components/LOW_LEVEL_AI_CHAIN_OF_THOUGHT.en.d.ts.map +1 -1
  308. package/dist/esm/i18n/components/LOW_LEVEL_AI_CODE_BLOCK.en.d.ts.map +1 -1
  309. package/dist/esm/i18n/components/LOW_LEVEL_AI_CONFIRMATION.en.d.ts.map +1 -1
  310. package/dist/esm/i18n/components/LOW_LEVEL_AI_CONTEXT.en.d.ts.map +1 -1
  311. package/dist/esm/i18n/components/LOW_LEVEL_AI_CONVERSATION.en.d.ts.map +1 -1
  312. package/dist/esm/i18n/components/LOW_LEVEL_AI_DECISION.en.d.ts.map +1 -1
  313. package/dist/esm/i18n/components/LOW_LEVEL_AI_EXECUTION_PLAN.en.d.ts.map +1 -1
  314. package/dist/esm/i18n/components/LOW_LEVEL_AI_EXECUTION_STREAM.en.d.ts.map +1 -1
  315. package/dist/esm/i18n/components/LOW_LEVEL_AI_FLOW_EXECUTION.en.d.ts.map +1 -1
  316. package/dist/esm/i18n/components/LOW_LEVEL_AI_FLOW_NODE.en.d.ts.map +1 -1
  317. package/dist/esm/i18n/components/LOW_LEVEL_AI_INLINE_CITATION.en.d.ts.map +1 -1
  318. package/dist/esm/i18n/components/LOW_LEVEL_AI_MESSAGE.en.d.ts.map +1 -1
  319. package/dist/esm/i18n/components/LOW_LEVEL_AI_MODEL_SELECTOR.en.d.ts.map +1 -1
  320. package/dist/esm/i18n/components/LOW_LEVEL_AI_OPEN_IN_CHAT.en.d.ts.map +1 -1
  321. package/dist/esm/i18n/components/LOW_LEVEL_AI_PLAN.en.d.ts.map +1 -1
  322. package/dist/esm/i18n/components/LOW_LEVEL_AI_PROMPT_INPUT.en.d.ts.map +1 -1
  323. package/dist/esm/i18n/components/LOW_LEVEL_AI_SYSTEM_CATALOG.en.d.ts.map +1 -1
  324. package/dist/esm/i18n/components/LOW_LEVEL_AI_TASK_DETAIL.en.d.ts.map +1 -1
  325. package/dist/esm/i18n/components/LOW_LEVEL_AI_TASK_MEMORY.en.d.ts.map +1 -1
  326. package/dist/esm/i18n/components/LOW_LEVEL_AI_WEB_PREVIEW.en.d.ts.map +1 -1
  327. package/dist/esm/i18n/components/LOW_LEVEL_BILLING_INVOICE_HISTORY.en.d.ts.map +1 -1
  328. package/dist/esm/i18n/components/LOW_LEVEL_BILLING_PORTAL_LINK.en.d.ts.map +1 -1
  329. package/dist/esm/i18n/components/LOW_LEVEL_BILLING_PRICING_TABLE.en.d.ts.map +1 -1
  330. package/dist/esm/i18n/components/LOW_LEVEL_BILLING_SUBSCRIPTION_STATUS.en.d.ts.map +1 -1
  331. package/dist/esm/i18n/components/LOW_LEVEL_BILLING_USAGE_DASHBOARD.en.d.ts.map +1 -1
  332. package/dist/esm/i18n/components/LOW_LEVEL_BREADCRUMB.en.d.ts.map +1 -1
  333. package/dist/esm/i18n/components/LOW_LEVEL_BUTTON.en.d.ts.map +1 -1
  334. package/dist/esm/i18n/components/LOW_LEVEL_CAROUSEL.en.d.ts.map +1 -1
  335. package/dist/esm/i18n/components/LOW_LEVEL_CELEBRATION_OVERLAY.en.d.ts.map +1 -1
  336. package/dist/esm/i18n/components/LOW_LEVEL_COLOR_INPUT.en.d.ts.map +1 -1
  337. package/dist/esm/i18n/components/LOW_LEVEL_COMMAND.en.d.ts.map +1 -1
  338. package/dist/esm/i18n/components/LOW_LEVEL_CONTENT_SECTION_CONTAINER.en.d.ts.map +1 -1
  339. package/dist/esm/i18n/components/LOW_LEVEL_DIALOG.en.d.ts.map +1 -1
  340. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_BIGDECIMAL.en.d.ts.map +1 -1
  341. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_BOOLEAN.en.d.ts.map +1 -1
  342. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_CODE.en.d.ts.map +1 -1
  343. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_DURATION.en.d.ts.map +1 -1
  344. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_FILE.en.d.ts.map +1 -1
  345. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_FILE_AUDIO.en.d.ts.map +1 -1
  346. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_FILE_DOCUMENT.en.d.ts.map +1 -1
  347. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_FILE_GALLERY.en.d.ts.map +1 -1
  348. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_FILE_IMAGE.en.d.ts.map +1 -1
  349. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_FILE_VIDEO.en.d.ts.map +1 -1
  350. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_MONEY.en.d.ts.map +1 -1
  351. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_PHONE.en.d.ts.map +1 -1
  352. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_RANGE_BIGDECIMAL.en.d.ts.map +1 -1
  353. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_RANGE_MONEY.en.d.ts.map +1 -1
  354. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_RANGE_NUMBER.en.d.ts.map +1 -1
  355. package/dist/esm/i18n/components/LOW_LEVEL_DRAWER.en.d.ts.map +1 -1
  356. package/dist/esm/i18n/components/LOW_LEVEL_ERROR_DISPLAY.en.d.ts.map +1 -1
  357. package/dist/esm/i18n/components/LOW_LEVEL_FEATURE_LOCK_BADGE.en.d.ts.map +1 -1
  358. package/dist/esm/i18n/components/LOW_LEVEL_FEATURE_UNAVAILABLE_PROMPT.en.d.ts.map +1 -1
  359. package/dist/esm/i18n/components/LOW_LEVEL_FILE_UPLOAD.en.d.ts.map +1 -1
  360. package/dist/esm/i18n/components/LOW_LEVEL_FORM_FIELD.en.d.ts.map +1 -1
  361. package/dist/esm/i18n/components/LOW_LEVEL_FORM_FIELD_BOOLEAN.en.d.ts.map +1 -1
  362. package/dist/esm/i18n/components/LOW_LEVEL_FORM_FIELD_CODE.en.d.ts.map +1 -1
  363. package/dist/esm/i18n/components/LOW_LEVEL_FORM_FIELD_FILE.en.d.ts.map +1 -1
  364. package/dist/esm/i18n/components/LOW_LEVEL_FORM_FIELD_PHONE.en.d.ts.map +1 -1
  365. package/dist/esm/i18n/components/LOW_LEVEL_FORM_FIELD_STRING.en.d.ts.map +1 -1
  366. package/dist/esm/i18n/components/LOW_LEVEL_FORM_MESSAGE.en.d.ts.map +1 -1
  367. package/dist/esm/i18n/components/LOW_LEVEL_IMAGE_CROP.en.d.ts.map +1 -1
  368. package/dist/esm/i18n/components/LOW_LEVEL_LOADING_OVERLAY.en.d.ts.map +1 -1
  369. package/dist/esm/i18n/components/LOW_LEVEL_LOADING_SPINNER.en.d.ts.map +1 -1
  370. package/dist/esm/i18n/components/LOW_LEVEL_OPERATIONS_CONFIRM_CRITICAL.en.d.ts.map +1 -1
  371. package/dist/esm/i18n/components/LOW_LEVEL_OVERLAY_CONTAINER.en.d.ts.map +1 -1
  372. package/dist/esm/i18n/components/LOW_LEVEL_PAGINATION.en.d.ts.map +1 -1
  373. package/dist/esm/i18n/components/LOW_LEVEL_SELECT_MULTIPLE.en.d.ts.map +1 -1
  374. package/dist/esm/i18n/components/LOW_LEVEL_SHEET.en.d.ts.map +1 -1
  375. package/dist/esm/i18n/components/LOW_LEVEL_SIDEBAR.en.d.ts.map +1 -1
  376. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_AUTH_CALLBACK.en.d.ts.map +1 -1
  377. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_ENROLLMENT_REQUIRED.en.d.ts.map +1 -1
  378. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_FILE_UPLOAD_GRANT.en.d.ts +39 -0
  379. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_FILE_UPLOAD_GRANT.en.d.ts.map +1 -0
  380. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_FILE_UPLOAD_GRANT.en.js +39 -0
  381. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_FILE_UPLOAD_GRANT.en.js.map +1 -0
  382. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_MAGIC_LINK_VERIFY.en.d.ts.map +1 -1
  383. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_MFA_CHALLENGE.en.d.ts.map +1 -1
  384. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_OAUTH_CONSENT.en.d.ts.map +1 -1
  385. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_OAUTH_LOGGED_OUT.en.d.ts.map +1 -1
  386. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_OAUTH_LOGOUT_CONFIRM.en.d.ts.map +1 -1
  387. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_ONE_OFF_SESSION.en.d.ts.map +1 -1
  388. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_TERMS.en.d.ts.map +1 -1
  389. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_USER_AUTH.en.d.ts.map +1 -1
  390. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_USER_CONFIRM_EMAIL.en.d.ts.map +1 -1
  391. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_USER_INVITATION.en.d.ts.map +1 -1
  392. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_USER_PASSWORD_LOST.en.d.ts.map +1 -1
  393. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_USER_REGISTER.en.d.ts.map +1 -1
  394. package/dist/esm/i18n/components/RESOURCES_FIELDS_RESOURCE_REFERENCE.en.d.ts.map +1 -1
  395. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_ACTION.en.d.ts.map +1 -1
  396. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_CONTAINER_NESTED.en.d.ts.map +1 -1
  397. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_CREATE.en.d.ts.map +1 -1
  398. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_DANGER_ZONE.en.d.ts.map +1 -1
  399. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_FILTERS.en.d.ts.map +1 -1
  400. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_HEADER.en.d.ts.map +1 -1
  401. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_LIST.en.d.ts.map +1 -1
  402. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_OPERATIONS_BULK.en.d.ts.map +1 -1
  403. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_OPERATIONS_ITEMS.en.d.ts.map +1 -1
  404. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_PAGINATION.en.d.ts.map +1 -1
  405. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_READ.en.d.ts.map +1 -1
  406. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_SEARCH.en.d.ts.map +1 -1
  407. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_UPDATE.en.d.ts.map +1 -1
  408. package/dist/esm/i18n/components/guidance_announcement.en.d.ts.map +1 -1
  409. package/dist/esm/i18n/components/guidance_banner.en.d.ts.map +1 -1
  410. package/dist/esm/i18n/components/guidance_card.en.d.ts.map +1 -1
  411. package/dist/esm/i18n/components/guidance_checklist.en.d.ts.map +1 -1
  412. package/dist/esm/i18n/components/guidance_checklist_item.en.d.ts.map +1 -1
  413. package/dist/esm/i18n/components/guidance_modal.en.d.ts.map +1 -1
  414. package/dist/esm/i18n/components/guidance_onboarding_view.en.d.ts.map +1 -1
  415. package/dist/esm/i18n/components/guidance_survey.en.d.ts.map +1 -1
  416. package/dist/esm/i18n/components/guidance_tooltip.en.d.ts.map +1 -1
  417. package/dist/esm/i18n/components/guidance_tour.en.d.ts.map +1 -1
  418. package/dist/esm/i18n/components/progression_achievement_badge.en.d.ts.map +1 -1
  419. package/dist/esm/i18n/components/progression_milestone_tracker.en.d.ts.map +1 -1
  420. package/dist/esm/i18n/composite_views/app.creation-board.en.d.ts.map +1 -1
  421. package/dist/esm/i18n/composite_views/app.domain-model.en.d.ts.map +1 -1
  422. package/dist/esm/i18n/index.d.ts.map +1 -1
  423. package/dist/esm/i18n/resources/wildoApplicationActorSystemExecutions.en.d.ts.map +1 -1
  424. package/dist/esm/i18n/resources/wildoApplicationActorTasks.en.d.ts.map +1 -1
  425. package/dist/esm/i18n/resources/wildoApplicationFlowSystemExecutions.en.d.ts.map +1 -1
  426. package/dist/esm/i18n/resources/workbenchBuildPlanTasks.en.d.ts.map +1 -1
  427. package/dist/esm/i18n/resources/workbenchDomainResources.en.d.ts.map +1 -1
  428. package/dist/esm/i18n/resources/workbenchPlaybooks.en.d.ts.map +1 -1
  429. package/dist/esm/i18n/resources/workbenchRunWriteRecords.en.d.ts.map +1 -1
  430. package/dist/esm/i18n/resources/workbenchSpecificationArtifacts.en.d.ts.map +1 -1
  431. package/dist/esm/i18n/resources/workbenchTraceSessions.en.d.ts.map +1 -1
  432. package/dist/esm/i18n/system_enums/market.en.d.ts.map +1 -1
  433. package/dist/esm/i18n-labelling/models/labelling-unit.models.d.ts +58 -0
  434. package/dist/esm/i18n-labelling/models/labelling-unit.models.d.ts.map +1 -1
  435. package/dist/esm/i18n-labelling/models/labelling-unit.models.js +35 -0
  436. package/dist/esm/i18n-labelling/models/labelling-unit.models.js.map +1 -1
  437. package/dist/esm/i18n-labelling/models/labelling.actors-system.definitions.d.ts.map +1 -1
  438. package/dist/esm/i18n-labelling/models/labelling.actors-system.definitions.js +8 -3
  439. package/dist/esm/i18n-labelling/models/labelling.actors-system.definitions.js.map +1 -1
  440. package/dist/esm/i18n-labelling/services/component-labels-bootstrap.companion.service.d.ts.map +1 -1
  441. package/dist/esm/i18n-labelling/services/labelling-planner.companion.service.d.ts +55 -1
  442. package/dist/esm/i18n-labelling/services/labelling-planner.companion.service.d.ts.map +1 -1
  443. package/dist/esm/i18n-labelling/services/labelling-planner.companion.service.js +178 -73
  444. package/dist/esm/i18n-labelling/services/labelling-planner.companion.service.js.map +1 -1
  445. package/dist/esm/i18n-labelling/services/labelling-spec-context-loader.companion.service.d.ts +3 -3
  446. package/dist/esm/i18n-labelling/services/labelling-spec-context-loader.companion.service.d.ts.map +1 -1
  447. package/dist/esm/i18n-labelling/services/labelling-spec-context-loader.companion.service.js +16 -5
  448. package/dist/esm/i18n-labelling/services/labelling-spec-context-loader.companion.service.js.map +1 -1
  449. package/dist/esm/i18n-labelling/services/labellize-orchestrator.companion.service.d.ts +35 -2
  450. package/dist/esm/i18n-labelling/services/labellize-orchestrator.companion.service.d.ts.map +1 -1
  451. package/dist/esm/i18n-labelling/services/labellize-orchestrator.companion.service.js +68 -29
  452. package/dist/esm/i18n-labelling/services/labellize-orchestrator.companion.service.js.map +1 -1
  453. package/dist/esm/i18n-labelling/services/translate-orchestrator.companion.service.d.ts.map +1 -1
  454. package/dist/esm/i18n-labelling/services/translate-orchestrator.companion.service.js +126 -35
  455. package/dist/esm/i18n-labelling/services/translate-orchestrator.companion.service.js.map +1 -1
  456. package/dist/esm/i18n-labelling/utils/frontend-derived-label-keys.utils.d.ts.map +1 -1
  457. package/dist/esm/i18n-labelling/utils/guidance-keys.utils.d.ts.map +1 -1
  458. package/dist/esm/i18n-labelling/utils/label-file-source.utils.d.ts.map +1 -1
  459. package/dist/esm/i18n-labelling/utils/label-placeholder-drift.utils.d.ts +143 -0
  460. package/dist/esm/i18n-labelling/utils/label-placeholder-drift.utils.d.ts.map +1 -0
  461. package/dist/esm/i18n-labelling/utils/label-placeholder-drift.utils.js +179 -0
  462. package/dist/esm/i18n-labelling/utils/label-placeholder-drift.utils.js.map +1 -0
  463. package/dist/esm/i18n-labelling/utils/orphan-label-artifacts.utils.d.ts +154 -0
  464. package/dist/esm/i18n-labelling/utils/orphan-label-artifacts.utils.d.ts.map +1 -0
  465. package/dist/esm/i18n-labelling/utils/orphan-label-artifacts.utils.js +174 -0
  466. package/dist/esm/i18n-labelling/utils/orphan-label-artifacts.utils.js.map +1 -0
  467. package/dist/esm/i18n-labelling/utils/per-unit-file.utils.d.ts.map +1 -1
  468. package/dist/esm/i18n-labelling/utils/role-lifecycle-keys.utils.d.ts.map +1 -1
  469. package/dist/esm/i18n-labelling/utils/schema-fields-extractor.utils.d.ts +104 -0
  470. package/dist/esm/i18n-labelling/utils/schema-fields-extractor.utils.d.ts.map +1 -1
  471. package/dist/esm/i18n-labelling/utils/schema-fields-extractor.utils.js +163 -18
  472. package/dist/esm/i18n-labelling/utils/schema-fields-extractor.utils.js.map +1 -1
  473. package/dist/esm/i18n-labelling/utils/structured-chunk-completion.utils.d.ts.map +1 -1
  474. package/dist/esm/i18n-labelling/utils/translate-locale-contract.utils.d.ts.map +1 -1
  475. package/dist/esm/index.d.ts.map +1 -1
  476. package/dist/esm/market/services/market-generation.companion.service.d.ts.map +1 -1
  477. package/dist/esm/meta-workflows/models/application-coding-agent.actors-system.definitions.d.ts.map +1 -1
  478. package/dist/esm/meta-workflows/models/application-coding-agent.actors-system.definitions.js +72 -0
  479. package/dist/esm/meta-workflows/models/application-coding-agent.actors-system.definitions.js.map +1 -1
  480. package/dist/esm/meta-workflows/models/application-research-agent.actors-system.definitions.d.ts.map +1 -1
  481. package/dist/esm/meta-workflows/models/application-research-agent.actors-system.definitions.js.map +1 -1
  482. package/dist/esm/meta-workflows/models/brief-adequacy.actors-system.definitions.d.ts +17 -4
  483. package/dist/esm/meta-workflows/models/brief-adequacy.actors-system.definitions.d.ts.map +1 -1
  484. package/dist/esm/meta-workflows/models/brief-adequacy.actors-system.definitions.js +25 -5
  485. package/dist/esm/meta-workflows/models/brief-adequacy.actors-system.definitions.js.map +1 -1
  486. package/dist/esm/meta-workflows/models/meta-workflows-lane.models.d.ts.map +1 -1
  487. package/dist/esm/meta-workflows/models/meta-workflows.actors-system.definitions.d.ts.map +1 -1
  488. package/dist/esm/meta-workflows/models/meta-workflows.actors-system.definitions.js +9 -4
  489. package/dist/esm/meta-workflows/models/meta-workflows.actors-system.definitions.js.map +1 -1
  490. package/dist/esm/meta-workflows/services/__tests__/application-build-task-coding.companion.test-fixtures.d.ts.map +1 -1
  491. package/dist/esm/meta-workflows/services/application-build-dispatch.companion.service.d.ts +3 -9
  492. package/dist/esm/meta-workflows/services/application-build-dispatch.companion.service.d.ts.map +1 -1
  493. package/dist/esm/meta-workflows/services/application-build-dispatch.companion.service.js +48 -28
  494. package/dist/esm/meta-workflows/services/application-build-dispatch.companion.service.js.map +1 -1
  495. package/dist/esm/meta-workflows/services/application-build-generation-step.companion.service.d.ts +83 -2
  496. package/dist/esm/meta-workflows/services/application-build-generation-step.companion.service.d.ts.map +1 -1
  497. package/dist/esm/meta-workflows/services/application-build-generation-step.companion.service.js +197 -4
  498. package/dist/esm/meta-workflows/services/application-build-generation-step.companion.service.js.map +1 -1
  499. package/dist/esm/meta-workflows/services/application-build-task-coding-policy.companion.service.d.ts.map +1 -1
  500. package/dist/esm/meta-workflows/services/execution-trace-read.companion.service.d.ts.map +1 -1
  501. package/dist/esm/meta-workflows/services/foundation-executor.companion.service.d.ts.map +1 -1
  502. package/dist/esm/meta-workflows/services/playbook-choreography-checkpoint.companion.service.d.ts.map +1 -1
  503. package/dist/esm/meta-workflows/services/playbook-execution-trace.companion.service.d.ts.map +1 -1
  504. package/dist/esm/meta-workflows/services/playbook-run-write-register.companion.service.d.ts.map +1 -1
  505. package/dist/esm/meta-workflows/services/playbook-run.companion.service.d.ts +37 -1
  506. package/dist/esm/meta-workflows/services/playbook-run.companion.service.d.ts.map +1 -1
  507. package/dist/esm/meta-workflows/services/playbook-run.companion.service.js +227 -15
  508. package/dist/esm/meta-workflows/services/playbook-run.companion.service.js.map +1 -1
  509. package/dist/esm/meta-workflows/services/playbook-suspended-run.companion.service.d.ts.map +1 -1
  510. package/dist/esm/technical-doc/services/technical-doc.companion.service.d.ts +117 -2
  511. package/dist/esm/technical-doc/services/technical-doc.companion.service.d.ts.map +1 -1
  512. package/dist/esm/technical-doc/services/technical-doc.companion.service.js +258 -69
  513. package/dist/esm/technical-doc/services/technical-doc.companion.service.js.map +1 -1
  514. package/dist/esm/technical-doc/services/technical-documentation-application-derivation.companion.service.d.ts +5 -1
  515. package/dist/esm/technical-doc/services/technical-documentation-application-derivation.companion.service.d.ts.map +1 -1
  516. package/dist/esm/technical-doc/services/technical-documentation-application-derivation.companion.service.js +142 -10
  517. package/dist/esm/technical-doc/services/technical-documentation-application-derivation.companion.service.js.map +1 -1
  518. package/dist/esm/technical-doc/services/technical-documentation-environment-identity.companion.service.d.ts.map +1 -1
  519. package/dist/esm/technical-doc/services/technical-documentation-pilot-assets.companion.service.d.ts.map +1 -1
  520. package/dist/esm/technical-doc/services/technical-documentation-pilot.companion.service.d.ts +2 -1
  521. package/dist/esm/technical-doc/services/technical-documentation-pilot.companion.service.d.ts.map +1 -1
  522. package/dist/esm/technical-doc/services/technical-documentation-pilot.companion.service.js +10 -2
  523. package/dist/esm/technical-doc/services/technical-documentation-pilot.companion.service.js.map +1 -1
  524. package/package.json +17 -17
  525. package/dist/esm/core/runtime/companion-startup-composition-fence.d.ts +0 -44
  526. package/dist/esm/core/runtime/companion-startup-composition-fence.d.ts.map +0 -1
  527. package/dist/esm/core/runtime/companion-startup-composition-fence.js +0 -85
  528. package/dist/esm/core/runtime/companion-startup-composition-fence.js.map +0 -1
  529. package/dist/esm/expert-personas/utils/canonical-json.d.ts +0 -25
  530. package/dist/esm/expert-personas/utils/canonical-json.d.ts.map +0 -1
  531. package/dist/esm/expert-personas/utils/canonical-json.js +0 -45
  532. package/dist/esm/expert-personas/utils/canonical-json.js.map +0 -1
  533. package/dist/esm/i18n/components/LOW_LEVEL_BILLING_PLAN_CHANGE_PREVIEW.en.d.ts +0 -19
  534. package/dist/esm/i18n/components/LOW_LEVEL_BILLING_PLAN_CHANGE_PREVIEW.en.d.ts.map +0 -1
  535. package/dist/esm/i18n/components/LOW_LEVEL_BILLING_PLAN_CHANGE_PREVIEW.en.js +0 -19
  536. package/dist/esm/i18n/components/LOW_LEVEL_BILLING_PLAN_CHANGE_PREVIEW.en.js.map +0 -1
  537. package/dist/esm/i18n/components/LOW_LEVEL_BILLING_PROMOTION_CODE_INPUT.en.d.ts +0 -17
  538. package/dist/esm/i18n/components/LOW_LEVEL_BILLING_PROMOTION_CODE_INPUT.en.d.ts.map +0 -1
  539. package/dist/esm/i18n/components/LOW_LEVEL_BILLING_PROMOTION_CODE_INPUT.en.js +0 -17
  540. package/dist/esm/i18n/components/LOW_LEVEL_BILLING_PROMOTION_CODE_INPUT.en.js.map +0 -1
@@ -1 +1 @@
1
- {"version":3,"file":"technical-documentation-application-derivation.companion.service.js","sourceRoot":"","sources":["../../../../../src/technical-doc/services/technical-documentation-application-derivation.companion.service.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AAEzC,OAAO,EAAE,gBAAgB,EAAE,MAAM,uBAAuB,CAAC;AACzD,OAAO,EACL,0DAA0D,EAC1D,+CAA+C,GAEhD,MAAM,yCAAyC,CAAC;AACjD,OAAO,EACL,+CAA+C,EAC/C,iDAAiD,EACjD,iDAAiD,EACjD,6BAA6B,EAC7B,2CAA2C,EAC3C,wCAAwC,EAExC,yDAAyD,GAI1D,MAAM,uDAAuD,CAAC;AAC/D,OAAO,EACL,6CAA6C,EAC7C,mDAAmD,EACnD,6CAA6C,EAC7C,mDAAmD,EACnD,2DAA2D,EAI3D,yCAAyC,EACzC,6CAA6C,EAC7C,6CAA6C,EA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,CAAC;IAEF,OAAO;QACL,IAAI,EAAE,+CAA+C,CAAC,cAAc;QACpE,UAAU,EAAE,wCAAwC,CAAC,sBAAsB;QAC3E,MAAM,EAAE,KAAK,KAAK,SAAS;YACzB,CAAC,CAAC,iDAAiD,CAAC,SAAS;YAC7D,CAAC,CAAC,iDAAiD,CAAC,MAAM;QAC5D,MAAM,EAAE,KAAK,KAAK,SAAS;YACzB,CAAC,CAAC,iDAAiD,CAAC,+BAA+B;YACnF,CAAC,CAAC,iDAAiD,CAAC,+BAA+B;QACrF,aAAa,EAAE,2CAA2C,CAAC,uBAAuB;QAClF,YAAY,EAAE,oCAAoC;QAClD,gBAAgB,EAAE,CAAC;QACnB,eAAe,EAAE,IAAI;QACrB,OAAO,EAAE,IAAI;QACb,WAAW,EAAE,IAAI;QACjB,UAAU;QACV,UAAU,EAAE,IAAI;KACjB,CAAC;AACJ,CAAC;AAED,SAAS,MAAM,CAAC,aAAqB;IACnC,OAAO,UAAU,UAAU,CAAC,QAAQ,CAAC,CAAC,MAAM,CAAC,aAAa,CAAC,CAAC,MAAM,CAAC,KAAK,CAAC,EAAE,CAAC;AAC9E,CAAC","sourcesContent":["import { createHash } from 'node:crypto';\n\nimport { CoreResourceType } from '@wildo-ai/saas-models';\nimport {\n ENGINE_DOCUMENTATION_OUTBOUND_WEBHOOK_SIGNATURE_SOURCE_REF,\n createEngineDocumentationSpecificationCatalogV1,\n type EngineDocumentationSpecificationCatalogV1,\n} from '@wildo-ai/saas-specifications/companion';\nimport {\n TechnicalDocumentationApplicabilityEvidenceAxis,\n TechnicalDocumentationApplicabilityEvidenceReason,\n TechnicalDocumentationApplicabilityEvidenceStatus,\n TechnicalDocumentationChannel,\n TechnicalDocumentationEvidenceAuthorityKind,\n TechnicalDocumentationEvidenceSubjectRef,\n canonicalizeTechnicalDocumentationJson,\n createTechnicalDocumentationEnvironmentEvidenceSnapshotV1,\n type TechnicalDocumentationAuthorizedBundleManifestV1,\n type TechnicalDocumentationEvidenceObservationV1,\n type TechnicalDocumentationPrivateDerivationManifestV1,\n} from '@wildo-ai/saas-specifications/technical-documentation';\nimport {\n createTechnicalDocumentationPrivateDerivation,\n loadApplicationConsumerDocumentationContentBundleV1,\n projectTechnicalDocumentationAuthorizedBundle,\n createApplicationOrganizationRolesDocumentationFact,\n createApplicationOrganizationUnitResourcesDocumentationFact,\n type ApplicationOrganizationRoleDocumentation,\n type ApplicationOrganizationUnitResourceDocumentation,\n type OperationProjection,\n projectApplicationConnectionDocumentation,\n projectApplicationAuthenticationDocumentation,\n projectApplicationAdministrationDocumentation,\n projectApplicationIntegrationDocumentation,\n type ApplicationConnectionServer,\n type ApplicationAuthenticationDocumentationSource,\n type ApplicationAdministrationActionSource,\n type ApplicationAdministrationDocumentationSource,\n type ApplicationIntegrationDocumentationSource,\n} from '@wildo-ai/saas-technical-doc/companion';\nimport { inject, injectable } from 'inversify';\n\nimport { COMPANION_SERVICE_TYPES } from '../../core/inject/models/service-types';\n\nimport type {\n TechnicalDocumentationEnvironmentIdentityCompanionService,\n TechnicalDocumentationEnvironmentIdentityInput,\n} from './technical-documentation-environment-identity.companion.service';\n\nconst APPLICATION_DOCUMENTATION_POLICY_REF = 'technical-documentation:policy/application-consumer-public-v1';\nconst APPLICATION_DOCUMENTATION_POLICY_VERSION = 1;\nconst OPERATION_PROJECTION_AUTHORITY_REF = 'technical-documentation:authority/derived-operation-projection';\nconst APPLICATION_STARTUP_CONFIGURATION_AUTHORITY_REF = 'technical-documentation:authority/final-application-startup-configuration';\nconst ENGINE_CONTENT_CATALOG_AUTHORITY_REF = 'technical-documentation:authority/engine-documentation-specification-catalog';\n\n/**\n * Identifies the deliberately small framework-content derivation implemented by this service. It\n * includes only narrow, source-owned application projections: resolved organization roles and\n * resources explicitly narrowed by units. Use cases and editorial overlays remain for the\n * unfinished app-creator flow.\n *\n * This was a sha256 over a hand-listed inventory of the projectors involved until 2026-08-27 —\n * a pin nothing compared, whose only reader-visible property was that it changed when someone\n * edited the list. `ref@version` says the same thing and can be looked up.\n */\nconst FRAMEWORK_DOCUMENTATION_DERIVATION_REF = 'technical-documentation:derivation/framework-content-v1';\nconst FRAMEWORK_DOCUMENTATION_DERIVATION_VERSION = 1;\nconst APPLICATION_DOCUMENTATION_BUNDLE_REF = 'technical-documentation:bundle/application-consumer-public';\n\n/**\n * These resource registrations prove that the application exposes an outbound\n * webhook configuration surface. This is framework capability introspection,\n * not application-authored documentation.\n */\nconst OUTBOUND_WEBHOOK_SURFACE_RESOURCE_IDENTIFIERS: readonly string[] = Object.freeze([\n CoreResourceType.APPLICATION_WEBHOOK_CONFIG,\n CoreResourceType.ORGANIZATION_WEBHOOK_CONFIG,\n]);\nconst ORGANIZATION_SIEM_EXPORT_RESOURCE_IDENTIFIERS: readonly string[] = Object.freeze([\n CoreResourceType.ORGANIZATION_SIEM_EXPORT_CONFIG,\n]);\nconst ORGANIZATION_SIEM_RECOVERY_RESOURCE_IDENTIFIERS: readonly string[] = Object.freeze([\n CoreResourceType.ORGANIZATION_SIEM_DELIVERY_DLQ,\n]);\nconst ORGANIZATION_BILLING_RESOURCE_IDENTIFIERS: readonly string[] = Object.freeze([\n CoreResourceType.ORGANIZATION_BILLING_ACCOUNTS,\n CoreResourceType.ORGANIZATION_SUBSCRIPTIONS,\n]);\n\n/**\n * The administrative matrix, joined from two things the derivation already has: the operations this\n * application admits, and its own role labels.\n *\n * Only ADMITTED operations are considered — the same inventory that gates every other page — so an\n * action this application does not publish never appears. Role identifiers are resolved to the\n * application's labels; an identifier with no label falls back to the identifier itself rather than\n * being dropped, because a reader is better served by an unfamiliar name than by a silently short\n * list. Repository-only and internal variants are excluded: they are not doors anyone can open.\n */\nfunction administrationSourceFromOperations(\n operations: readonly OperationProjection[],\n organizationRoles: readonly ApplicationOrganizationRoleDocumentation[],\n): ApplicationAdministrationDocumentationSource {\n const labelByRole = new Map(organizationRoles.map((role) => [role.role, role.label]));\n const collect = (resourceIdentifiers: readonly string[]): ApplicationAdministrationActionSource[] => {\n const seen = new Set<string>();\n const actions: ApplicationAdministrationActionSource[] = [];\n for (const operation of operations) {\n if (!resourceIdentifiers.includes(operation.resourceIdentifier)) continue;\n const action = operation.summary?.trim();\n if (action === undefined || action.length === 0 || seen.has(action)) continue;\n seen.add(action);\n actions.push({\n action,\n roleLabels: operation.roles.map((role) => labelByRole.get(role) ?? role),\n openToEveryMember: operation.roles.length === 0,\n });\n }\n return actions;\n };\n return {\n memberActions: collect([CoreResourceType.ORGANIZATION_MEMBERS]),\n organizationUnitActions: collect([CoreResourceType.ORGANIZATION_UNITS, CoreResourceType.ORGANIZATION_UNIT_MEMBERS]),\n };\n}\n\nexport interface TechnicalDocumentationApplicationDerivationInput extends TechnicalDocumentationEnvironmentIdentityInput {\n readonly operations: readonly OperationProjection[];\n readonly hasConfiguredMcpToolOperations: boolean;\n readonly hasConfiguredA2aSkills: boolean;\n readonly organizationRoles: readonly ApplicationOrganizationRoleDocumentation[];\n readonly organizationUnitAwareResources: readonly ApplicationOrganizationUnitResourceDocumentation[];\n /**\n * The application's own name and published base URLs. The agent surfaces are NOT passed\n * separately: they are read from the same two flags that gate the MCP and A2A pages, so an\n * address can never be printed for a surface whose pages this application does not publish.\n */\n readonly applicationName: string;\n readonly apiServers: readonly ApplicationConnectionServer[];\n /** Per-user-type sign-in policy, read from the application's own configuration. */\n readonly authentication: ApplicationAuthenticationDocumentationSource;\n /** The tools and events this application publishes, from the same walk that gates those pages. */\n readonly integration: ApplicationIntegrationDocumentationSource;\n}\n\nexport interface TechnicalDocumentationApplicationDerivationResult {\n readonly privateDerivation: TechnicalDocumentationPrivateDerivationManifestV1;\n readonly publicBundle: TechnicalDocumentationAuthorizedBundleManifestV1;\n}\n\n/**\n * Creates the public documentation bundle from engine-owned content and\n * framework introspection plus the resolved organization-role configuration.\n *\n * The resolved operation catalog contributes capability evidence, but accepted\n * application projections and family registries are not inputs. In particular,\n * this path does not select a resource, workflow, persona, recipe, or use case.\n */\n@injectable()\nexport class TechnicalDocumentationApplicationDerivationCompanionService {\n public constructor(\n @inject(COMPANION_SERVICE_TYPES.TechnicalDocumentationEnvironmentIdentityService)\n private readonly environmentIdentity: TechnicalDocumentationEnvironmentIdentityCompanionService,\n ) {}\n\n public async deriveAuthorizedBundles(\n input: TechnicalDocumentationApplicationDerivationInput,\n ): Promise<TechnicalDocumentationApplicationDerivationResult> {\n const derivationEnvironment = this.environmentIdentity.resolveDerivationEnvironment(input);\n const derivedAt = derivationEnvironment.derivedAt;\n\n const engineCatalog = createEngineDocumentationSpecificationCatalogV1();\n const environmentEvidenceSnapshot = createTechnicalDocumentationEnvironmentEvidenceSnapshotV1({\n schemaVersion: 1,\n environmentRef: derivationEnvironment.environmentRef,\n freshnessEvaluatedAt: derivedAt,\n observations: [\n configuredAgentSurfaceObservation(\n input.hasConfiguredMcpToolOperations,\n TechnicalDocumentationEvidenceSubjectRef.APPLICATION_MCP_TOOL_SURFACE,\n derivedAt,\n ),\n configuredAgentSurfaceObservation(\n input.hasConfiguredA2aSkills,\n TechnicalDocumentationEvidenceSubjectRef.APPLICATION_A2A_AGENT_SURFACE,\n derivedAt,\n ),\n outboundWebhookSurfaceObservation(input.operations, derivedAt),\n outboundWebhookSignatureContractObservation(engineCatalog, derivedAt),\n admittedResourceSurfaceObservation(\n input.operations,\n derivedAt,\n TechnicalDocumentationEvidenceSubjectRef.ORGANIZATION_SIEM_EXPORT,\n ORGANIZATION_SIEM_EXPORT_RESOURCE_IDENTIFIERS,\n ),\n admittedResourceSurfaceObservation(\n input.operations,\n derivedAt,\n TechnicalDocumentationEvidenceSubjectRef.ORGANIZATION_SIEM_DELIVERY_RECOVERY,\n ORGANIZATION_SIEM_RECOVERY_RESOURCE_IDENTIFIERS,\n ),\n admittedResourceSurfaceObservation(\n input.operations,\n derivedAt,\n TechnicalDocumentationEvidenceSubjectRef.ORGANIZATION_BILLING_ADMINISTRATION,\n ORGANIZATION_BILLING_RESOURCE_IDENTIFIERS,\n ),\n ],\n });\n const privateDerivation = createTechnicalDocumentationPrivateDerivation({\n engineContentBundle: loadApplicationConsumerDocumentationContentBundleV1(),\n environmentEvidenceSnapshot,\n engineSpecificationCatalog: engineCatalog,\n engineSpecificationCatalogIdentity: engineCatalog.identity,\n applicationOrganizationRolesFact: createApplicationOrganizationRolesDocumentationFact(input.organizationRoles),\n applicationOrganizationUnitResourcesFact: createApplicationOrganizationUnitResourcesDocumentationFact(\n input.organizationUnitAwareResources,\n ),\n applicationAuthenticationFact: projectApplicationAuthenticationDocumentation(input.authentication),\n applicationIntegrationFact: projectApplicationIntegrationDocumentation(input.integration),\n applicationAdministrationFact: projectApplicationAdministrationDocumentation(\n administrationSourceFromOperations(input.operations, input.organizationRoles),\n ),\n applicationConnectionFact: projectApplicationConnectionDocumentation({\n applicationName: input.applicationName,\n apiServers: input.apiServers,\n surfaces: {\n mcpToolServer: input.hasConfiguredMcpToolOperations,\n a2aAgent: input.hasConfiguredA2aSkills,\n },\n }),\n derivationRef: FRAMEWORK_DOCUMENTATION_DERIVATION_REF,\n derivationVersion: FRAMEWORK_DOCUMENTATION_DERIVATION_VERSION,\n derivedAt,\n });\n const publicBundle = projectTechnicalDocumentationAuthorizedBundle({\n privateDerivation,\n channel: TechnicalDocumentationChannel.PUBLIC_PORTAL,\n policyRef: APPLICATION_DOCUMENTATION_POLICY_REF,\n policyVersion: APPLICATION_DOCUMENTATION_POLICY_VERSION,\n bundleRef: APPLICATION_DOCUMENTATION_BUNDLE_REF,\n bundleVersion: APPLICATION_DOCUMENTATION_POLICY_VERSION,\n });\n\n return Object.freeze({ privateDerivation, publicBundle });\n }\n}\n\n/**\n * Records whether the application's final executable declaration contains a\n * usable integration surface. This is configuration evidence, not a health\n * claim: publication never pretends that a live MCP or A2A request was made.\n */\nfunction configuredAgentSurfaceObservation(\n configured: boolean,\n subjectRef: TechnicalDocumentationEvidenceSubjectRef.APPLICATION_MCP_TOOL_SURFACE\n | TechnicalDocumentationEvidenceSubjectRef.APPLICATION_A2A_AGENT_SURFACE,\n observedAt: string,\n): TechnicalDocumentationEvidenceObservationV1 {\n return {\n axis: TechnicalDocumentationApplicabilityEvidenceAxis.CONFIGURED_ACTIVATION,\n subjectRef,\n status: configured\n ? TechnicalDocumentationApplicabilityEvidenceStatus.PROVEN\n : TechnicalDocumentationApplicabilityEvidenceStatus.DISPROVEN,\n reason: configured\n ? TechnicalDocumentationApplicabilityEvidenceReason.AUTHORITATIVE_POSITIVE_EVIDENCE\n : TechnicalDocumentationApplicabilityEvidenceReason.AUTHORITATIVE_NEGATIVE_EVIDENCE,\n authorityKind: TechnicalDocumentationEvidenceAuthorityKind.CONFIGURATION,\n authorityRef: APPLICATION_STARTUP_CONFIGURATION_AUTHORITY_REF,\n authorityVersion: 1,\n runtimeScopeRef: null,\n hostRef: null,\n hasEvidence: true,\n observedAt,\n validUntil: null,\n };\n}\n\n/**\n * Proves a customer-facing documentation journey only when every resource that\n * makes that journey executable is present in the application's admitted API\n * projection. Framework registration alone is intentionally insufficient.\n */\nfunction admittedResourceSurfaceObservation(\n operations: readonly OperationProjection[],\n observedAt: string,\n subjectRef: TechnicalDocumentationEvidenceSubjectRef,\n requiredResourceIdentifiers: readonly string[],\n): TechnicalDocumentationEvidenceObservationV1 {\n const exposedResourceIdentifiers = [...new Set(operations.map((operation) => operation.resourceIdentifier))]\n .filter((resourceIdentifier) => requiredResourceIdentifiers.includes(resourceIdentifier))\n .sort();\n const required = [...requiredResourceIdentifiers].sort();\n const exposed = required.every((resourceIdentifier) => exposedResourceIdentifiers.includes(resourceIdentifier));\n\n return {\n axis: TechnicalDocumentationApplicabilityEvidenceAxis.EXPOSED_API_SURFACE,\n subjectRef,\n status: exposed ? TechnicalDocumentationApplicabilityEvidenceStatus.PROVEN : TechnicalDocumentationApplicabilityEvidenceStatus.DISPROVEN,\n reason: exposed\n ? TechnicalDocumentationApplicabilityEvidenceReason.AUTHORITATIVE_POSITIVE_EVIDENCE\n : TechnicalDocumentationApplicabilityEvidenceReason.AUTHORITATIVE_NEGATIVE_EVIDENCE,\n authorityKind: TechnicalDocumentationEvidenceAuthorityKind.MATERIALIZED_ARTIFACT,\n authorityRef: OPERATION_PROJECTION_AUTHORITY_REF,\n authorityVersion: 1,\n runtimeScopeRef: null,\n hostRef: null,\n hasEvidence: true,\n observedAt,\n validUntil: null,\n };\n}\n\n/**\n * Introspection evidence that the generated application exposes an outbound\n * webhook configuration surface. The operation list is a materialized\n * companion-export artifact, not an accepted application specification.\n */\nfunction outboundWebhookSurfaceObservation(\n operations: readonly OperationProjection[],\n observedAt: string,\n): TechnicalDocumentationEvidenceObservationV1 {\n const exposedResourceIdentifiers = [...new Set(\n operations\n .map((operation) => operation.resourceIdentifier)\n .filter((resourceIdentifier) => OUTBOUND_WEBHOOK_SURFACE_RESOURCE_IDENTIFIERS.includes(resourceIdentifier)),\n )].sort();\n const exposed = exposedResourceIdentifiers.length > 0;\n\n return {\n axis: TechnicalDocumentationApplicabilityEvidenceAxis.EXPOSED_API_SURFACE,\n subjectRef: TechnicalDocumentationEvidenceSubjectRef.OUTBOUND_M2M_DELIVERY,\n status: exposed\n ? TechnicalDocumentationApplicabilityEvidenceStatus.PROVEN\n : TechnicalDocumentationApplicabilityEvidenceStatus.DISPROVEN,\n reason: exposed\n ? TechnicalDocumentationApplicabilityEvidenceReason.AUTHORITATIVE_POSITIVE_EVIDENCE\n : TechnicalDocumentationApplicabilityEvidenceReason.AUTHORITATIVE_NEGATIVE_EVIDENCE,\n authorityKind: TechnicalDocumentationEvidenceAuthorityKind.MATERIALIZED_ARTIFACT,\n authorityRef: OPERATION_PROJECTION_AUTHORITY_REF,\n authorityVersion: 1,\n runtimeScopeRef: null,\n hostRef: null,\n hasEvidence: true,\n observedAt,\n validUntil: null,\n };\n}\n\n/** Engine-catalog evidence that the documented signature contract still exists. */\nexport function outboundWebhookSignatureContractObservation(\n catalog: EngineDocumentationSpecificationCatalogV1,\n observedAt: string,\n): TechnicalDocumentationEvidenceObservationV1 {\n const entry = catalog.identity.entries.find(\n (candidate) => candidate.sourceRef === ENGINE_DOCUMENTATION_OUTBOUND_WEBHOOK_SIGNATURE_SOURCE_REF,\n );\n\n return {\n axis: TechnicalDocumentationApplicabilityEvidenceAxis.ENGINE_SUPPORT,\n subjectRef: TechnicalDocumentationEvidenceSubjectRef.OUTBOUND_M2M_SIGNATURE,\n status: entry === undefined\n ? TechnicalDocumentationApplicabilityEvidenceStatus.DISPROVEN\n : TechnicalDocumentationApplicabilityEvidenceStatus.PROVEN,\n reason: entry === undefined\n ? TechnicalDocumentationApplicabilityEvidenceReason.AUTHORITATIVE_NEGATIVE_EVIDENCE\n : TechnicalDocumentationApplicabilityEvidenceReason.AUTHORITATIVE_POSITIVE_EVIDENCE,\n authorityKind: TechnicalDocumentationEvidenceAuthorityKind.ENGINE_CONTENT_REGISTRY,\n authorityRef: ENGINE_CONTENT_CATALOG_AUTHORITY_REF,\n authorityVersion: 1,\n runtimeScopeRef: null,\n hostRef: null,\n hasEvidence: true,\n observedAt,\n validUntil: null,\n };\n}\n\nfunction digest(canonicalJson: string): string {\n return `sha256:${createHash('sha256').update(canonicalJson).digest('hex')}`;\n}\n"]}
1
+ {"version":3,"file":"technical-documentation-application-derivation.companion.service.js","sourceRoot":"","sources":["../../../../src/technical-doc/services/technical-documentation-application-derivation.companion.service.ts"],"names":[],"mappings":";;;;;;;;;;;;AACA,OAAO,EAAE,gBAAgB,EAAE,MAAM,uBAAuB,CAAC;AACzD,OAAO,EACL,0DAA0D,EAC1D,+CAA+C,GAEhD,MAAM,yCAAyC,CAAC;AACjD,OAAO,EACL,+CAA+C,EAC/C,iDAAiD,EACjD,iDAAiD,EACjD,6BAA6B,EAC7B,2CAA2C,EAC3C,wCAAwC,EAExC,yDAAyD,GAI1D,MAAM,uDAAuD,CAAC;AAC/D,OAAO,EACL,6CAA6C,EAC7C,mDAAmD,EACnD,6CAA6C,EAC7C,mDAAmD,EACnD,2DAA2D,EAI3D,yCAAyC,EACzC,6CAA6C,EAC7C,6CAA6C,EAC7C,0CAA0C,EAC1C,qC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,IAAI;KACjB,CAAC;AACJ,CAAC","sourcesContent":["\nimport { CoreResourceType } from '@wildo-ai/saas-models';\nimport {\n ENGINE_DOCUMENTATION_OUTBOUND_WEBHOOK_SIGNATURE_SOURCE_REF,\n createEngineDocumentationSpecificationCatalogV1,\n type EngineDocumentationSpecificationCatalogV1,\n} from '@wildo-ai/saas-specifications/companion';\nimport {\n TechnicalDocumentationApplicabilityEvidenceAxis,\n TechnicalDocumentationApplicabilityEvidenceReason,\n TechnicalDocumentationApplicabilityEvidenceStatus,\n TechnicalDocumentationChannel,\n TechnicalDocumentationEvidenceAuthorityKind,\n TechnicalDocumentationEvidenceSubjectRef,\n canonicalizeTechnicalDocumentationJson,\n createTechnicalDocumentationEnvironmentEvidenceSnapshotV1,\n type TechnicalDocumentationAuthorizedBundleManifestV1,\n type TechnicalDocumentationEvidenceObservationV1,\n type TechnicalDocumentationPrivateDerivationManifestV1,\n} from '@wildo-ai/saas-specifications/technical-documentation';\nimport {\n createTechnicalDocumentationPrivateDerivation,\n loadApplicationConsumerDocumentationContentBundleV1,\n projectTechnicalDocumentationAuthorizedBundle,\n createApplicationOrganizationRolesDocumentationFact,\n createApplicationOrganizationUnitResourcesDocumentationFact,\n type ApplicationOrganizationRoleDocumentation,\n type ApplicationOrganizationUnitResourceDocumentation,\n type OperationProjection,\n projectApplicationConnectionDocumentation,\n projectApplicationAuthenticationDocumentation,\n projectApplicationAdministrationDocumentation,\n projectApplicationIntegrationDocumentation,\n projectApplicationDomainDocumentation,\n RESOURCE_RELATIONSHIP_CARDINALITY_MEANINGS,\n RESOURCE_RELATIONSHIP_NATURE_MEANINGS,\n ResourceRelationshipDocumentationCardinality,\n ResourceRelationshipDocumentationDeleteStrategy,\n type ApplicationDomainRelationshipSource,\n type ResourceRelationshipDocumentation,\n type ApplicationDomainDocumentationSource,\n type ApplicationDomainOperationSource,\n type ApplicationDomainResourceSource,\n type ResourceTag,\n type ApplicationConnectionServer,\n type ApplicationAuthenticationDocumentationSource,\n type ApplicationAdministrationActionSource,\n type ApplicationAdministrationDocumentationSource,\n type ApplicationIntegrationDocumentationSource,\n} from '@wildo-ai/saas-technical-doc/companion';\nimport { inject, injectable } from 'inversify';\n\nimport { COMPANION_SERVICE_TYPES } from '../../core/inject/models/service-types';\n\nimport type {\n TechnicalDocumentationEnvironmentIdentityCompanionService,\n TechnicalDocumentationEnvironmentIdentityInput,\n} from './technical-documentation-environment-identity.companion.service';\n\nconst APPLICATION_DOCUMENTATION_POLICY_REF = 'technical-documentation:policy/application-consumer-public-v1';\nconst APPLICATION_DOCUMENTATION_POLICY_VERSION = 1;\nconst OPERATION_PROJECTION_AUTHORITY_REF = 'technical-documentation:authority/derived-operation-projection';\nconst APPLICATION_STARTUP_CONFIGURATION_AUTHORITY_REF = 'technical-documentation:authority/final-application-startup-configuration';\nconst ENGINE_CONTENT_CATALOG_AUTHORITY_REF = 'technical-documentation:authority/engine-documentation-specification-catalog';\n\n/**\n * Identifies the deliberately small framework-content derivation implemented by this service. It\n * includes only narrow, source-owned application projections: resolved organization roles and\n * resources explicitly narrowed by units. Use cases and editorial overlays remain for the\n * unfinished app-creator flow.\n *\n * This was a sha256 over a hand-listed inventory of the projectors involved until 2026-08-27 —\n * a pin nothing compared, whose only reader-visible property was that it changed when someone\n * edited the list. `ref@version` says the same thing and can be looked up.\n */\nconst FRAMEWORK_DOCUMENTATION_DERIVATION_REF = 'technical-documentation:derivation/framework-content-v1';\nconst FRAMEWORK_DOCUMENTATION_DERIVATION_VERSION = 1;\nconst APPLICATION_DOCUMENTATION_BUNDLE_REF = 'technical-documentation:bundle/application-consumer-public';\n\n/**\n * These resource registrations prove that the application exposes an outbound\n * webhook configuration surface. This is framework capability introspection,\n * not application-authored documentation.\n */\nconst OUTBOUND_WEBHOOK_SURFACE_RESOURCE_IDENTIFIERS: readonly string[] = Object.freeze([\n CoreResourceType.APPLICATION_WEBHOOK_CONFIG,\n CoreResourceType.ORGANIZATION_WEBHOOK_CONFIG,\n]);\nconst ORGANIZATION_SIEM_EXPORT_RESOURCE_IDENTIFIERS: readonly string[] = Object.freeze([\n CoreResourceType.ORGANIZATION_SIEM_EXPORT_CONFIG,\n]);\nconst ORGANIZATION_SIEM_RECOVERY_RESOURCE_IDENTIFIERS: readonly string[] = Object.freeze([\n CoreResourceType.ORGANIZATION_SIEM_DELIVERY_DLQ,\n]);\n\n/**\n * The administrative matrix, joined from two things the derivation already has: the operations this\n * application admits, and its own role labels.\n *\n * Only ADMITTED operations are considered — the same inventory that gates every other page — so an\n * action this application does not publish never appears. Role identifiers are resolved to the\n * application's labels; an identifier with no label falls back to the identifier itself rather than\n * being dropped, because a reader is better served by an unfamiliar name than by a silently short\n * list. Repository-only and internal variants are excluded: they are not doors anyone can open.\n */\nfunction administrationSourceFromOperations(\n operations: readonly OperationProjection[],\n organizationRoles: readonly ApplicationOrganizationRoleDocumentation[],\n): ApplicationAdministrationDocumentationSource {\n const labelByRole = new Map(organizationRoles.map((role) => [role.role, role.label]));\n const collect = (resourceIdentifiers: readonly string[]): ApplicationAdministrationActionSource[] => {\n const seen = new Set<string>();\n const actions: ApplicationAdministrationActionSource[] = [];\n for (const operation of operations) {\n if (!resourceIdentifiers.includes(operation.resourceIdentifier)) continue;\n const action = operation.summary?.trim();\n if (action === undefined || action.length === 0 || seen.has(action)) continue;\n seen.add(action);\n actions.push({\n action,\n roleLabels: operation.roles.map((role) => labelByRole.get(role) ?? role),\n openToEveryMember: operation.roles.length === 0,\n });\n }\n return actions;\n };\n return {\n memberActions: collect([CoreResourceType.ORGANIZATION_MEMBERS]),\n organizationUnitActions: collect([CoreResourceType.ORGANIZATION_UNITS, CoreResourceType.ORGANIZATION_UNIT_MEMBERS]),\n };\n}\n\n/**\n * Turns one relationship row into something a customer can read, and refuses the part it cannot\n * resolve.\n *\n * `onParentDelete` is a CHILD-side policy (`childOperations.lifecycle.onParentDelete`) copied onto\n * both sides of the relationship, so the row alone does not say whether this resource is the parent\n * or the child. Cardinality settles it for a one-to-many — the ONE side is the parent, and the\n * foreign key sits on the many side — and settles nothing for one-to-one or many-to-many, which is\n * 51 of the rows carrying a policy on the dogfood application.\n *\n * Where it is unresolved the cascade is simply ABSENT, and the page says an empty cell means \"not\n * stated here\". Telling somebody their data survives a delete when it does not is the most\n * expensive sentence this documentation could carry; making them look it up is cheap.\n */\nfunction domainRelationshipFrom(relationship: ResourceRelationshipDocumentation): ApplicationDomainRelationshipSource {\n const many: readonly ResourceRelationshipDocumentationCardinality[] = [\n ResourceRelationshipDocumentationCardinality.MANY,\n ResourceRelationshipDocumentationCardinality.ONE_OR_MANY,\n ];\n const thisIsParent = relationship.resourceCardinality === ResourceRelationshipDocumentationCardinality.ONE\n && many.includes(relationship.relatedResourceCardinality);\n const thisIsChild = many.includes(relationship.resourceCardinality)\n && relationship.relatedResourceCardinality === ResourceRelationshipDocumentationCardinality.ONE;\n const policy = relationship.onParentDelete;\n const removes = policy?.strategy === ResourceRelationshipDocumentationDeleteStrategy.IMPERSONALIZE_AND_RETAIN\n ? 'kept but stripped of personal detail'\n : 'deleted';\n const cascade = policy?.enabled !== true\n ? undefined\n : thisIsParent\n ? `Deleting one of these leaves its \\`${relationship.relatedResourceName}\\` ${removes}`\n : thisIsChild\n ? `${removes === 'deleted' ? 'Deleted' : 'Kept but stripped of personal detail'} when its \\`${relationship.relatedResourceName}\\` is deleted`\n : undefined;\n\n return {\n relatedResourceIdentifier: relationship.relatedResourceName,\n relatedCardinalityWords: RESOURCE_RELATIONSHIP_CARDINALITY_MEANINGS[relationship.relatedResourceCardinality],\n natureWords: RESOURCE_RELATIONSHIP_NATURE_MEANINGS[relationship.nature],\n ...(relationship.foreignKeyField === undefined ? {} : { foreignKeyField: relationship.foreignKeyField }),\n ...(cascade === undefined ? {} : { cascade }),\n };\n}\n\n/**\n * The application's own domain, assembled from three sources it already accepted.\n *\n * Only APPLICATION-OWNED resources appear. That split is the whole reason this page does not\n * restate the rest of the site: a core resource such as `organizationMembers` already has pages\n * about administering it, while `todos` had none anywhere.\n *\n * Grouping comes from `apiReferenceResourceCategories`, which an application already declares for\n * its API reference and which the categoriser has already validated (every published resource\n * named exactly once, no unknown names). Reusing it means the documentation and the reference\n * group the product the same way, and an application that renames a category renames it in one\n * place.\n *\n * When an application declares no categories the resources land in a single group named after the\n * application. That is deliberately not an invented taxonomy: guessing at domain groupings from\n * resource names is exactly the kind of inference the quality contract forbids.\n */\nfunction domainSourceFromResourceTags(input: {\n readonly applicationName: string;\n readonly resourceTags: readonly ResourceTag[];\n readonly applicationOwnedResourceIdentifiers: readonly string[];\n readonly operations: readonly OperationProjection[];\n readonly organizationRoles: readonly ApplicationOrganizationRoleDocumentation[];\n}): ApplicationDomainDocumentationSource {\n const owned = new Set(input.applicationOwnedResourceIdentifiers);\n const labelByRole = new Map(input.organizationRoles.map((role) => [role.role, role.label]));\n const operationsFor = (resourceIdentifier: string): ApplicationDomainOperationSource[] => {\n const seen = new Set<string>();\n const projected: ApplicationDomainOperationSource[] = [];\n for (const operation of input.operations) {\n if (operation.resourceIdentifier !== resourceIdentifier) continue;\n // One row per operation identifier: variants differ by transport and qualifier, which a\n // reader deciding whether they may do something does not need and cannot act on.\n if (seen.has(operation.baseOperationIdentifier)) continue;\n seen.add(operation.baseOperationIdentifier);\n const summary = operation.summary?.trim();\n /*\n * The wire facts, when the projection resolved them. A page that says what a thing is and\n * who may change it, and then cannot say how to send the request, stops one step short of\n * useful — and the method, the path and one worked example are all already here.\n */\n const example = operation.examples?.find((candidate) => candidate.request !== undefined || candidate.response !== undefined);\n projected.push({\n operationIdentifier: operation.baseOperationIdentifier,\n ...(summary === undefined || summary.length === 0 ? {} : { summary }),\n roleLabels: operation.roles.map((role) => labelByRole.get(role) ?? role),\n openToEveryMember: operation.roles.length === 0,\n ...(operation.httpVerb === undefined ? {} : { httpMethod: String(operation.httpVerb).toUpperCase() }),\n ...(operation.path === undefined ? {} : { path: operation.path }),\n ...(example === undefined ? {} : {\n example: {\n title: example.title,\n ...(example.request === undefined ? {} : { request: example.request }),\n ...(example.response === undefined ? {} : { response: example.response }),\n },\n }),\n });\n }\n return projected;\n };\n\n const byCategoryId = new Map<string, { label: string; description?: string; resources: ApplicationDomainResourceSource[] }>();\n for (const tag of input.resourceTags) {\n if (!owned.has(tag.name)) continue;\n const categoryId = tag.category?.id ?? 'application-resources';\n const label = tag.category?.label ?? input.applicationName;\n const existing = byCategoryId.get(categoryId)\n ?? { label, ...(tag.category?.description === undefined ? {} : { description: tag.category.description }), resources: [] };\n /*\n * EVERY relationship, not only those to resources this application owns.\n *\n * The first cut filtered to owned resources so every row could be a link. Measured against\n * Wonder CRM, that was wrong: its `deal` relates to `organizations` and `users` and to none of\n * its own resources, so the filter left the section empty on a resource with two real\n * connections. The projection links a related resource that has a page and names one that does\n * not, which keeps the fact and loses only the hyperlink.\n */\n const relationships = (tag.relationships ?? [])\n .map(domainRelationshipFrom)\n .sort((left, right) => left.relatedResourceIdentifier.localeCompare(right.relatedResourceIdentifier, 'en-US'));\n existing.resources.push({\n resourceIdentifier: tag.name,\n ...(tag.description === undefined ? {} : { purpose: tag.description }),\n ...(tag.lifecycleRole === undefined ? {} : { lifecycleRole: tag.lifecycleRole }),\n operations: operationsFor(tag.name),\n ...(relationships.length === 0 ? {} : { relationships }),\n });\n byCategoryId.set(categoryId, existing);\n }\n\n return {\n applicationName: input.applicationName,\n categories: [...byCategoryId.entries()]\n .map(([id, category]) => ({ id, ...category }))\n .sort((left, right) => left.label.localeCompare(right.label, 'en-US')),\n };\n}\n\nexport interface TechnicalDocumentationApplicationDerivationInput extends TechnicalDocumentationEnvironmentIdentityInput {\n readonly operations: readonly OperationProjection[];\n readonly hasConfiguredMcpToolOperations: boolean;\n readonly hasConfiguredA2aSkills: boolean;\n readonly organizationRoles: readonly ApplicationOrganizationRoleDocumentation[];\n readonly organizationUnitAwareResources: readonly ApplicationOrganizationUnitResourceDocumentation[];\n /**\n * The application's own name and published base URLs. The agent surfaces are NOT passed\n * separately: they are read from the same two flags that gate the MCP and A2A pages, so an\n * address can never be printed for a surface whose pages this application does not publish.\n */\n readonly applicationName: string;\n readonly apiServers: readonly ApplicationConnectionServer[];\n /** Per-user-type sign-in policy, read from the application's own configuration. */\n readonly authentication: ApplicationAuthenticationDocumentationSource;\n /** The tools and events this application publishes, from the same walk that gates those pages. */\n readonly integration: ApplicationIntegrationDocumentationSource;\n /** Per-resource purpose and lifecycle prose, already grouped by the application's own categories. */\n readonly resourceTags: readonly ResourceTag[];\n /** Which of those resources are the application's own rather than the framework's. */\n readonly applicationOwnedResourceIdentifiers: readonly string[];\n}\n\nexport interface TechnicalDocumentationApplicationDerivationResult {\n readonly privateDerivation: TechnicalDocumentationPrivateDerivationManifestV1;\n readonly publicBundle: TechnicalDocumentationAuthorizedBundleManifestV1;\n}\n\n/**\n * Creates the public documentation bundle from engine-owned content and\n * framework introspection plus the resolved organization-role configuration.\n *\n * The resolved operation catalog contributes capability evidence, but accepted\n * application projections and family registries are not inputs. In particular,\n * this path does not select a resource, workflow, persona, recipe, or use case.\n */\n@injectable()\nexport class TechnicalDocumentationApplicationDerivationCompanionService {\n public constructor(\n @inject(COMPANION_SERVICE_TYPES.TechnicalDocumentationEnvironmentIdentityService)\n private readonly environmentIdentity: TechnicalDocumentationEnvironmentIdentityCompanionService,\n ) {}\n\n public async deriveAuthorizedBundles(\n input: TechnicalDocumentationApplicationDerivationInput,\n ): Promise<TechnicalDocumentationApplicationDerivationResult> {\n const derivationEnvironment = this.environmentIdentity.resolveDerivationEnvironment(input);\n const derivedAt = derivationEnvironment.derivedAt;\n\n const engineCatalog = createEngineDocumentationSpecificationCatalogV1();\n const environmentEvidenceSnapshot = createTechnicalDocumentationEnvironmentEvidenceSnapshotV1({\n schemaVersion: 1,\n environmentRef: derivationEnvironment.environmentRef,\n freshnessEvaluatedAt: derivedAt,\n observations: [\n configuredAgentSurfaceObservation(\n input.hasConfiguredMcpToolOperations,\n TechnicalDocumentationEvidenceSubjectRef.APPLICATION_MCP_TOOL_SURFACE,\n derivedAt,\n ),\n configuredAgentSurfaceObservation(\n input.hasConfiguredA2aSkills,\n TechnicalDocumentationEvidenceSubjectRef.APPLICATION_A2A_AGENT_SURFACE,\n derivedAt,\n ),\n outboundWebhookSurfaceObservation(input.operations, derivedAt),\n outboundWebhookSignatureContractObservation(engineCatalog, derivedAt),\n admittedResourceSurfaceObservation(\n input.operations,\n derivedAt,\n TechnicalDocumentationEvidenceSubjectRef.ORGANIZATION_SIEM_EXPORT,\n ORGANIZATION_SIEM_EXPORT_RESOURCE_IDENTIFIERS,\n ),\n admittedResourceSurfaceObservation(\n input.operations,\n derivedAt,\n TechnicalDocumentationEvidenceSubjectRef.ORGANIZATION_SIEM_DELIVERY_RECOVERY,\n ORGANIZATION_SIEM_RECOVERY_RESOURCE_IDENTIFIERS,\n ),\n ],\n });\n const privateDerivation = createTechnicalDocumentationPrivateDerivation({\n engineContentBundle: loadApplicationConsumerDocumentationContentBundleV1(),\n environmentEvidenceSnapshot,\n engineSpecificationCatalog: engineCatalog,\n engineSpecificationCatalogIdentity: engineCatalog.identity,\n applicationOrganizationRolesFact: createApplicationOrganizationRolesDocumentationFact(input.organizationRoles),\n applicationOrganizationUnitResourcesFact: createApplicationOrganizationUnitResourcesDocumentationFact(\n input.organizationUnitAwareResources,\n ),\n applicationAuthenticationFact: projectApplicationAuthenticationDocumentation(input.authentication),\n applicationIntegrationFact: projectApplicationIntegrationDocumentation(input.integration),\n applicationDomainFact: projectApplicationDomainDocumentation(domainSourceFromResourceTags({\n applicationName: input.applicationName,\n resourceTags: input.resourceTags,\n applicationOwnedResourceIdentifiers: input.applicationOwnedResourceIdentifiers,\n operations: input.operations,\n organizationRoles: input.organizationRoles,\n })),\n applicationAdministrationFact: projectApplicationAdministrationDocumentation(\n administrationSourceFromOperations(input.operations, input.organizationRoles),\n ),\n applicationConnectionFact: projectApplicationConnectionDocumentation({\n applicationName: input.applicationName,\n apiServers: input.apiServers,\n surfaces: {\n mcpToolServer: input.hasConfiguredMcpToolOperations,\n a2aAgent: input.hasConfiguredA2aSkills,\n },\n }),\n derivationRef: FRAMEWORK_DOCUMENTATION_DERIVATION_REF,\n derivationVersion: FRAMEWORK_DOCUMENTATION_DERIVATION_VERSION,\n derivedAt,\n });\n const publicBundle = projectTechnicalDocumentationAuthorizedBundle({\n privateDerivation,\n channel: TechnicalDocumentationChannel.PUBLIC_PORTAL,\n policyRef: APPLICATION_DOCUMENTATION_POLICY_REF,\n policyVersion: APPLICATION_DOCUMENTATION_POLICY_VERSION,\n bundleRef: APPLICATION_DOCUMENTATION_BUNDLE_REF,\n bundleVersion: APPLICATION_DOCUMENTATION_POLICY_VERSION,\n });\n\n return Object.freeze({ privateDerivation, publicBundle });\n }\n}\n\n/**\n * Records whether the application's final executable declaration contains a\n * usable integration surface. This is configuration evidence, not a health\n * claim: publication never pretends that a live MCP or A2A request was made.\n */\nfunction configuredAgentSurfaceObservation(\n configured: boolean,\n subjectRef: TechnicalDocumentationEvidenceSubjectRef.APPLICATION_MCP_TOOL_SURFACE\n | TechnicalDocumentationEvidenceSubjectRef.APPLICATION_A2A_AGENT_SURFACE,\n observedAt: string,\n): TechnicalDocumentationEvidenceObservationV1 {\n return {\n axis: TechnicalDocumentationApplicabilityEvidenceAxis.CONFIGURED_ACTIVATION,\n subjectRef,\n status: configured\n ? TechnicalDocumentationApplicabilityEvidenceStatus.PROVEN\n : TechnicalDocumentationApplicabilityEvidenceStatus.DISPROVEN,\n reason: configured\n ? TechnicalDocumentationApplicabilityEvidenceReason.AUTHORITATIVE_POSITIVE_EVIDENCE\n : TechnicalDocumentationApplicabilityEvidenceReason.AUTHORITATIVE_NEGATIVE_EVIDENCE,\n authorityKind: TechnicalDocumentationEvidenceAuthorityKind.CONFIGURATION,\n authorityRef: APPLICATION_STARTUP_CONFIGURATION_AUTHORITY_REF,\n authorityVersion: 1,\n runtimeScopeRef: null,\n hostRef: null,\n hasEvidence: true,\n observedAt,\n validUntil: null,\n };\n}\n\n/**\n * Proves a customer-facing documentation journey only when every resource that\n * makes that journey executable is present in the application's admitted API\n * projection. Framework registration alone is intentionally insufficient.\n */\nfunction admittedResourceSurfaceObservation(\n operations: readonly OperationProjection[],\n observedAt: string,\n subjectRef: TechnicalDocumentationEvidenceSubjectRef,\n requiredResourceIdentifiers: readonly string[],\n): TechnicalDocumentationEvidenceObservationV1 {\n const exposedResourceIdentifiers = [...new Set(operations.map((operation) => operation.resourceIdentifier))]\n .filter((resourceIdentifier) => requiredResourceIdentifiers.includes(resourceIdentifier))\n .sort();\n const required = [...requiredResourceIdentifiers].sort();\n const exposed = required.every((resourceIdentifier) => exposedResourceIdentifiers.includes(resourceIdentifier));\n\n return {\n axis: TechnicalDocumentationApplicabilityEvidenceAxis.EXPOSED_API_SURFACE,\n subjectRef,\n status: exposed ? TechnicalDocumentationApplicabilityEvidenceStatus.PROVEN : TechnicalDocumentationApplicabilityEvidenceStatus.DISPROVEN,\n reason: exposed\n ? TechnicalDocumentationApplicabilityEvidenceReason.AUTHORITATIVE_POSITIVE_EVIDENCE\n : TechnicalDocumentationApplicabilityEvidenceReason.AUTHORITATIVE_NEGATIVE_EVIDENCE,\n authorityKind: TechnicalDocumentationEvidenceAuthorityKind.MATERIALIZED_ARTIFACT,\n authorityRef: OPERATION_PROJECTION_AUTHORITY_REF,\n authorityVersion: 1,\n runtimeScopeRef: null,\n hostRef: null,\n hasEvidence: true,\n observedAt,\n validUntil: null,\n };\n}\n\n/**\n * Introspection evidence that the generated application exposes an outbound\n * webhook configuration surface. The operation list is a materialized\n * companion-export artifact, not an accepted application specification.\n */\nfunction outboundWebhookSurfaceObservation(\n operations: readonly OperationProjection[],\n observedAt: string,\n): TechnicalDocumentationEvidenceObservationV1 {\n const exposedResourceIdentifiers = [...new Set(\n operations\n .map((operation) => operation.resourceIdentifier)\n .filter((resourceIdentifier) => OUTBOUND_WEBHOOK_SURFACE_RESOURCE_IDENTIFIERS.includes(resourceIdentifier)),\n )].sort();\n const exposed = exposedResourceIdentifiers.length > 0;\n\n return {\n axis: TechnicalDocumentationApplicabilityEvidenceAxis.EXPOSED_API_SURFACE,\n subjectRef: TechnicalDocumentationEvidenceSubjectRef.OUTBOUND_M2M_DELIVERY,\n status: exposed\n ? TechnicalDocumentationApplicabilityEvidenceStatus.PROVEN\n : TechnicalDocumentationApplicabilityEvidenceStatus.DISPROVEN,\n reason: exposed\n ? TechnicalDocumentationApplicabilityEvidenceReason.AUTHORITATIVE_POSITIVE_EVIDENCE\n : TechnicalDocumentationApplicabilityEvidenceReason.AUTHORITATIVE_NEGATIVE_EVIDENCE,\n authorityKind: TechnicalDocumentationEvidenceAuthorityKind.MATERIALIZED_ARTIFACT,\n authorityRef: OPERATION_PROJECTION_AUTHORITY_REF,\n authorityVersion: 1,\n runtimeScopeRef: null,\n hostRef: null,\n hasEvidence: true,\n observedAt,\n validUntil: null,\n };\n}\n\n/** Engine-catalog evidence that the documented signature contract still exists. */\nexport function outboundWebhookSignatureContractObservation(\n catalog: EngineDocumentationSpecificationCatalogV1,\n observedAt: string,\n): TechnicalDocumentationEvidenceObservationV1 {\n const entry = catalog.identity.entries.find(\n (candidate) => candidate.sourceRef === ENGINE_DOCUMENTATION_OUTBOUND_WEBHOOK_SIGNATURE_SOURCE_REF,\n );\n\n return {\n axis: TechnicalDocumentationApplicabilityEvidenceAxis.ENGINE_SUPPORT,\n subjectRef: TechnicalDocumentationEvidenceSubjectRef.OUTBOUND_M2M_SIGNATURE,\n status: entry === undefined\n ? TechnicalDocumentationApplicabilityEvidenceStatus.DISPROVEN\n : TechnicalDocumentationApplicabilityEvidenceStatus.PROVEN,\n reason: entry === undefined\n ? TechnicalDocumentationApplicabilityEvidenceReason.AUTHORITATIVE_NEGATIVE_EVIDENCE\n : TechnicalDocumentationApplicabilityEvidenceReason.AUTHORITATIVE_POSITIVE_EVIDENCE,\n authorityKind: TechnicalDocumentationEvidenceAuthorityKind.ENGINE_CONTENT_REGISTRY,\n authorityRef: ENGINE_CONTENT_CATALOG_AUTHORITY_REF,\n authorityVersion: 1,\n runtimeScopeRef: null,\n hostRef: null,\n hasEvidence: true,\n observedAt,\n validUntil: null,\n };\n}\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"technical-documentation-environment-identity.companion.service.d.ts","sourceRoot":"","sources":["../../../../../src/technical-doc/services/technical-documentation-environment-identity.companion.service.ts"],"names":[],"mappings":"AAQA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,sCAAsC,CAAC;AAO7E,MAAM,WAAW,8CAA8C;IAC7D,2GAA2G;IAC3G,QAAQ,CAAC,iBAAiB,EAAE,MAAM,CAAC;CACpC;AAED,MAAM,WAAW,2CAA2C;IAC1D,QAAQ,CAAC,cAAc,EAAE,MAAM,CAAC;IAChC,kJAAkJ;IAClJ,QAAQ,CAAC,SAAS,EAAE,MAAM,CAAC;CAC5B;AAED,MAAM,WAAW,0CAA0C;IACzD,GAAG,IAAI,IAAI,CAAC;CACb;AAED,qBACa,4CAA6C,YAAW,0CAA0C;IACtG,GAAG,IAAI,IAAI;CAGnB;AAED;;;;;;;;;;;;;GAaG;AACH,qBACa,yDAAyD;IAOlE,OAAO,CAAC,QAAQ,CAAC,KAAK;IANxB,OAAO,CAAC,QAAQ,CAAC,gBAAgB,CAAmB;gBAIlD,gBAAgB,EAAE,gBAAgB,EAEjB,KAAK,GAAE,0CAA+F;IAKlH,4BAA4B,CACjC,KAAK,EAAE,8CAA8C,GACpD,2CAA2C;CAyB/C"}
1
+ {"version":3,"file":"technical-documentation-environment-identity.companion.service.d.ts","sourceRoot":"","sources":["../../../../src/technical-doc/services/technical-documentation-environment-identity.companion.service.ts"],"names":[],"mappings":"AAQA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,sCAAsC,CAAC;AAO7E,MAAM,WAAW,8CAA8C;IAC7D,2GAA2G;IAC3G,QAAQ,CAAC,iBAAiB,EAAE,MAAM,CAAC;CACpC;AAED,MAAM,WAAW,2CAA2C;IAC1D,QAAQ,CAAC,cAAc,EAAE,MAAM,CAAC;IAChC,kJAAkJ;IAClJ,QAAQ,CAAC,SAAS,EAAE,MAAM,CAAC;CAC5B;AAED,MAAM,WAAW,0CAA0C;IACzD,GAAG,IAAI,IAAI,CAAC;CACb;AAED,qBACa,4CAA6C,YAAW,0CAA0C;IACtG,GAAG,IAAI,IAAI;CAGnB;AAED;;;;;;;;;;;;;GAaG;AACH,qBACa,yDAAyD;IAOlE,OAAO,CAAC,QAAQ,CAAC,KAAK;IANxB,OAAO,CAAC,QAAQ,CAAC,gBAAgB,CAAmB;gBAIlD,gBAAgB,EAAE,gBAAgB,EAEjB,KAAK,GAAE,0CAA+F;IAKlH,4BAA4B,CACjC,KAAK,EAAE,8CAA8C,GACpD,2CAA2C;CAyB/C"}
@@ -1 +1 @@
1
- {"version":3,"file":"technical-documentation-pilot-assets.companion.service.d.ts","sourceRoot":"","sources":["../../../../../src/technical-doc/services/technical-documentation-pilot-assets.companion.service.ts"],"names":[],"mappings":"AAMA,OAAO,EAWL,KAAK,gDAAgD,EACrD,KAAK,mDAAmD,EAEzD,MAAM,uDAAuD,CAAC;AAe/D,MAAM,WAAW,gDAAgD;IAC/D,QAAQ,CAAC,mBAAmB,EAAE,mDAAmD,CAAC;IAClF,QAAQ,CAAC,gBAAgB,EAAE,WAAW,CAAC,MAAM,EAAE,UAAU,CAAC,CAAC;CAC5D;AAiCD,iKAAiK;AACjK,qBAAa,iDAAiD;IAC/C,OAAO,CAAC,KAAK,EAAE;QAC1B,QAAQ,CAAC,gBAAgB,EAAE,gDAAgD,CAAC;QAC5E,QAAQ,CAAC,UAAU,CAAC,EAAE,MAAM,CAAC;KAC9B,GAAG,OAAO,CAAC,gDAAgD,CAAC;CAsH9D"}
1
+ {"version":3,"file":"technical-documentation-pilot-assets.companion.service.d.ts","sourceRoot":"","sources":["../../../../src/technical-doc/services/technical-documentation-pilot-assets.companion.service.ts"],"names":[],"mappings":"AAMA,OAAO,EAWL,KAAK,gDAAgD,EACrD,KAAK,mDAAmD,EAEzD,MAAM,uDAAuD,CAAC;AAe/D,MAAM,WAAW,gDAAgD;IAC/D,QAAQ,CAAC,mBAAmB,EAAE,mDAAmD,CAAC;IAClF,QAAQ,CAAC,gBAAgB,EAAE,WAAW,CAAC,MAAM,EAAE,UAAU,CAAC,CAAC;CAC5D;AAiCD,iKAAiK;AACjK,qBAAa,iDAAiD;IAC/C,OAAO,CAAC,KAAK,EAAE;QAC1B,QAAQ,CAAC,gBAAgB,EAAE,gDAAgD,CAAC;QAC5E,QAAQ,CAAC,UAAU,CAAC,EAAE,MAAM,CAAC;KAC9B,GAAG,OAAO,CAAC,gDAAgD,CAAC;CAsH9D"}
@@ -59,7 +59,8 @@ export declare class TechnicalDocumentationPilotCompanionService {
59
59
  readonly refuseProvisionalAssets?: boolean;
60
60
  readonly forbiddenPublicSentinels: readonly string[];
61
61
  readonly budgets: TechnicalDocumentationOutputBudgets;
62
- readonly resolveApiReferenceTarget?: (target: TechnicalDocumentationApiReferenceTargetV1) => string;
62
+ /** Returns `null` when this application does not publish the target — the link degrades to plain text (#472). */
63
+ readonly resolveApiReferenceTarget?: (target: TechnicalDocumentationApiReferenceTargetV1) => string | null;
63
64
  readonly resolvedAt?: string;
64
65
  readonly publishedAt?: string;
65
66
  }): Promise<TechnicalDocumentationPilotOperationResult>;
@@ -1 +1 @@
1
- {"version":3,"file":"technical-documentation-pilot.companion.service.d.ts","sourceRoot":"","sources":["../../../../../src/technical-doc/services/technical-documentation-pilot.companion.service.ts"],"names":[],"mappings":"AAKA,OAAO,EAEL,KAAK,0CAA0C,EAG/C,KAAK,gDAAgD,EACrD,KAAK,iDAAiD,EACtD,KAAK,yCAAyC,EAC9C,KAAK,mDAAmD,EACxD,KAAK,yCAAyC,EAC/C,MAAM,uDAAuD,CAAC;AAC/D,OAAO,EACL,mDAAmD,EAQnD,yCAAyC,EACzC,KAAK,uBAAuB,EAC5B,KAAK,mCAAmC,EAExC,KAAK,oCAAoC,EAC1C,MAAM,wCAAwC,CAAC;AAgBhD,MAAM,WAAW,4CAA4C;IAC3D,QAAQ,C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4C,CAAC;IAyBzD,iFAAiF;IACpE,uBAAuB,CAAC,KAAK,EAAE;QAC1C,QAAQ,CAAC,SAAS,EAAE,uBAAuB,CAAC;QAC5C,QAAQ,CAAC,cAAc,EAAE,SAAS,MAAM,EAAE,CAAC;KAC5C,GAAG,OAAO,CAAC;QAAE,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAC;QAAC,QAAQ,CAAC,WAAW,EAAE,SAAS,MAAM,EAAE,CAAA;KAAE,CAAC;IAanF;;;;;;;OAOG;YACW,yBAAyB;YAqBzB,wBAAwB;IAiCtC;;;;;;;;OAQG;YACW,2CAA2C;YAqB3C,kBAAkB;YAyBlB,sBAAsB;YAiBtB,2BAA2B;CAkB1C"}
1
+ {"version":3,"file":"technical-documentation-pilot.companion.service.d.ts","sourceRoot":"","sources":["../../../../src/technical-doc/services/technical-documentation-pilot.companion.service.ts"],"names":[],"mappings":"AAKA,OAAO,EAEL,KAAK,0CAA0C,EAG/C,KAAK,gDAAgD,EACrD,KAAK,iDAAiD,EACtD,KAAK,yCAAyC,EAC9C,KAAK,mDAAmD,EACxD,KAAK,yCAAyC,EAC/C,MAAM,uDAAuD,CAAC;AAC/D,OAAO,EACL,mDAAmD,EAOnD,yCAAyC,EACzC,KAAK,uBAAuB,EAC5B,KAAK,mCAAmC,EAExC,KAAK,oCAAoC,EAC1C,MAAM,wCAAwC,CAAC;AAgBhD,MAAM,WAAW,4CAA4C;IAC3D,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAC;IAC1B,QAAQ,CAAC,WAAW,EAAE,MAAM,CAAC;IAC7B,QAAQ,CAAC,QAAQ,EAAE,UAAU,CAAC,OAAO,mDAAmD,CAAC,CAAC;IAC1F,QAAQ,CAAC,UAAU,EAAE,UAAU,CAAC,OAAO,yCAAyC,CAAC,CAAC;CACnF;AAED,MAAM,WAAW,0CAA2C,SAAQ,4CAA4C;IAC9G;;;OAGG;IACH,QAAQ,CAAC,gBAAgB,EAAE;QACzB,QAAQ,CAAC,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;;;;;;;OAOG;YACW,yBAAyB;YAqBzB,wBAAwB;IAiCtC;;;;;;;;OAQG;YACW,2CAA2C;YAqB3C,kBAAkB;YAyBlB,sBAAsB;YAiBtB,2BAA2B;CAkB1C"}
@@ -3,7 +3,7 @@ import { constants } from 'node:fs';
3
3
  import { access, lstat, mkdir, open, readFile, readdir, rename, rm, writeFile } from 'node:fs/promises';
4
4
  import path from 'node:path';
5
5
  import { TechnicalDocumentationApplicabilityEvidenceStatus, TechnicalDocumentationAssetResolutionStatus, TechnicalDocumentationChannel, } from '@wildo-ai/saas-specifications/technical-documentation';
6
- import { createTechnicalDocumentationAggregateRenderManifest, createTechnicalDocumentationRenderModel, readTechnicalDocumentationAuthorizedRenderInput, renderTechnicalDocumentationDocusaurus, renderTechnicalDocumentationMarkdown, renderTechnicalDocumentationSearchIndexes, renderVerifiedTechnicalDocumentationOpenApi, technicalDocumentationSha256Bytes, validateTechnicalDocumentationManagedTree, } from '@wildo-ai/saas-technical-doc/companion';
6
+ import { createTechnicalDocumentationAggregateRenderManifest, createTechnicalDocumentationRenderModel, readTechnicalDocumentationAuthorizedRenderInput, renderTechnicalDocumentationDocusaurus, renderTechnicalDocumentationSearchIndexes, renderVerifiedTechnicalDocumentationOpenApi, technicalDocumentationSha256Bytes, validateTechnicalDocumentationManagedTree, } from '@wildo-ai/saas-technical-doc/companion';
7
7
  import { TechnicalDocumentationPilotAssetsCompanionService } from './technical-documentation-pilot-assets.companion.service.js';
8
8
  const GENERATED_ROOT_RELATIVE_PATH = path.join('technical-doc', 'src', 'generated', 'consumer-documentation');
9
9
  const API_REFERENCE_GENERATED_ROOT_RELATIVE_PATH = path.join('technical-doc', 'src', 'generated', 'api-reference');
@@ -121,8 +121,16 @@ export class TechnicalDocumentationPilotCompanionService {
121
121
  }
122
122
  }
123
123
  const renderModel = createTechnicalDocumentationRenderModel(verified.authorizedBundle);
124
+ /*
125
+ * Two renderers, not three. A portable-markdown family was rendered here for as long as this
126
+ * pipeline existed and NOTHING ever read it: the site mounts `docusaurus/docs`,
127
+ * `docusaurus/sidebars.json` and `docusaurus/static`, and `src/pages/search.tsx` reads
128
+ * `indexes/search.json` — measured with a positive control, so the empty result is a real
129
+ * absence rather than a bad probe. It cost 81 files and 511 KB per publication, half the
130
+ * published bytes, and it silently DOUBLED the operator-facing page budget: both families emit
131
+ * `MARKDOWN_DOCUMENT`, so a 81-page application counted 162 against `maximumPageCount` (#274).
132
+ */
124
133
  const rendererResults = [
125
- renderTechnicalDocumentationMarkdown({ model: renderModel, resolvedAssetBundle: verified.resolvedAssetBundle, assetBytesByPath: assets.assetBytesByPath, resolveApiReferenceTarget: input.resolveApiReferenceTarget }),
126
134
  renderTechnicalDocumentationSearchIndexes(renderModel),
127
135
  renderTechnicalDocumentationDocusaurus({ model: renderModel, resolvedAssetBundle: verified.resolvedAssetBundle, assetBytesByPath: assets.assetBytesByPath, resolveApiReferenceTarget: input.resolveApiReferenceTarget }),
128
136
  ];
@@ -1 +1 @@
1
- {"version":3,"file":"technical-documentation-pilot.companion.service.js","sourceRoot":"","sources":["../../../../../src/technical-doc/services/technical-documentation-pilot.companion.service.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AACzC,OAAO,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC;AACpC,OAAO,EAAE,MAAM,EAAE,KAAK,EAAE,KAAK,EAAE,IAAI,EAAE,QAAQ,EAAE,OAAO,EAAE,MAAM,EAAE,EAAE,EAAE,SAAS,EAAE,MAAM,kBAAkB,CAAC;AACxG,OAAO,IAAI,MAAM,WAAW,CAAC;AAE7B,OAAO,EACL,iDAAiD,EAEjD,2CAA2C,EAC3C,6BAA6B,GAM9B,MAAM,uDAAuD,CAAC;AAC/D,OAAO,EACL,mDAAmD,EACnD,uCAAuC,EACvC,+CAA+C,EAC/C,sCAAsC,EACtC,oCAAoC,EACpC,yCAAyC,EACzC,2CAA2C,EAC3C,iCAAiC,EACjC,yCAAyC,GAK1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;YACrF,CAAC;iBAAM,IAAI,CAAC,aAAa,CAAC,GAAG,CAAC,YAAY,CAAC,EAAE,CAAC;gBAC5C,MAAM,EAAE,CAAC,YAAY,EAAE,EAAE,KAAK,EAAE,IAAI,EAAE,CAAC,CAAC;YAC1C,CAAC;QACH,CAAC;IACH,CAAC;CACF","sourcesContent":["import { randomUUID } from 'node:crypto';\nimport { constants } from 'node:fs';\nimport { access, lstat, mkdir, open, readFile, readdir, rename, rm, writeFile } from 'node:fs/promises';\nimport path from 'node:path';\n\nimport {\n TechnicalDocumentationApplicabilityEvidenceStatus,\n type TechnicalDocumentationApiReferenceTargetV1,\n TechnicalDocumentationAssetResolutionStatus,\n TechnicalDocumentationChannel,\n type TechnicalDocumentationAuthorizedBundleManifestV1,\n type TechnicalDocumentationPrivateDerivationManifestV1,\n type TechnicalDocumentationVersionedIdentityV1,\n type TechnicalDocumentationResolvedAssetBundleManifestV1,\n type TechnicalDocumentationSupportedApiVersion,\n} from '@wildo-ai/saas-specifications/technical-documentation';\nimport {\n createTechnicalDocumentationAggregateRenderManifest,\n createTechnicalDocumentationRenderModel,\n readTechnicalDocumentationAuthorizedRenderInput,\n renderTechnicalDocumentationDocusaurus,\n renderTechnicalDocumentationMarkdown,\n renderTechnicalDocumentationSearchIndexes,\n renderVerifiedTechnicalDocumentationOpenApi,\n technicalDocumentationSha256Bytes,\n validateTechnicalDocumentationManagedTree,\n type OpenApiGenerationOutput,\n type TechnicalDocumentationOutputBudgets,\n type TechnicalDocumentationRenderedFile,\n type TechnicalDocumentationRendererResult,\n} from '@wildo-ai/saas-technical-doc/companion';\n\nimport { TechnicalDocumentationPilotAssetsCompanionService } from './technical-documentation-pilot-assets.companion.service';\n\nconst GENERATED_ROOT_RELATIVE_PATH = path.join('technical-doc', 'src', 'generated', 'consumer-documentation');\nconst API_REFERENCE_GENERATED_ROOT_RELATIVE_PATH = path.join('technical-doc', 'src', 'generated', 'api-reference');\nconst RENDER_MANIFEST_FILE_NAME = 'render-output-manifest.json';\nconst CONSUMER_DOCUMENTATION_RENDER_REF = 'technical-documentation:render/consumer-documentation';\nconst CONSUMER_DOCUMENTATION_PUBLICATION_SIGNAL_RELATIVE_PATH = path.join(\n '.wildo-saas',\n 'runtime-signals',\n 'technical-documentation',\n 'consumer-documentation-published.json',\n);\nconst publicationOperationQueues = new Map<string, Promise<void>>();\n\nexport interface TechnicalDocumentationPilotPublicationResult {\n readonly rootPath: string;\n readonly contentPath: string;\n readonly manifest: ReturnType<typeof createTechnicalDocumentationAggregateRenderManifest>;\n readonly validation: ReturnType<typeof validateTechnicalDocumentationManagedTree>;\n}\n\nexport interface TechnicalDocumentationPilotOperationResult extends TechnicalDocumentationPilotPublicationResult {\n /**\n * Which exact stage outputs this operation joined, named `ref@version`. Four sha256 fields until\n * 2026-08-27 — unreadable in a log, unmergeable across branches, and never compared to anything.\n */\n readonly causalIdentities: {\n readonly derivation: TechnicalDocumentationVersionedIdentityV1;\n readonly authorizedBundle: TechnicalDocumentationVersionedIdentityV1;\n readonly resolvedAssetBundle: TechnicalDocumentationVersionedIdentityV1;\n readonly render: TechnicalDocumentationVersionedIdentityV1;\n };\n readonly channelCounts: { readonly publicUnits: number };\n readonly suppressions: readonly { readonly unitRef: string; readonly reason: string }[];\n readonly evidenceLimitations: readonly { readonly axis: string; readonly subjectRef: string; readonly status: string; readonly reason: string }[];\n readonly assetStates: readonly { readonly assetRef: string; readonly status: string; readonly byteDigest: string | null }[];\n readonly freshnessEvaluatedAt: string;\n}\n\nexport interface TechnicalDocumentationPilotCompositionDerivation {\n readonly privateDerivation: Pick<\n TechnicalDocumentationPrivateDerivationManifestV1,\n 'derivationRef' | 'derivationVersion' | 'environmentEvidenceSnapshot'\n >;\n readonly publicBundle: TechnicalDocumentationAuthorizedBundleManifestV1;\n}\n\nfunction assertPathWithin(parent: string, child: string): void {\n const relative = path.relative(parent, child);\n if (relative === '' || relative.startsWith('..') || path.isAbsolute(relative)) {\n throw new Error(`technical-documentation managed path escapes its root: ${child}`);\n }\n}\n\nasync function pathExists(target: string): Promise<boolean> {\n try {\n await access(target, constants.F_OK);\n return true;\n } catch {\n return false;\n }\n}\n\nasync function fsyncPath(target: string): Promise<void> {\n const handle = await open(target, 'r');\n try {\n await handle.sync();\n } finally {\n await handle.close();\n }\n}\n\nasync function listRegularFiles(root: string, relative = ''): Promise<string[]> {\n const current = relative === '' ? root : path.join(root, relative);\n const entries = await readdir(current, { withFileTypes: true });\n const files: string[] = [];\n for (const entry of entries) {\n const childRelative = relative === '' ? entry.name : path.join(relative, entry.name);\n const child = path.join(root, childRelative);\n const info = await lstat(child);\n if (info.isSymbolicLink()) throw new Error(`technical-documentation generated tree rejects symbolic links: ${childRelative}`);\n if (info.isDirectory()) files.push(...await listRegularFiles(root, childRelative));\n else if (info.isFile()) files.push(childRelative.split(path.sep).join('/'));\n else throw new Error(`technical-documentation generated tree rejects non-regular entry: ${childRelative}`);\n }\n return files.sort();\n}\n\n/**\n * Companion-owned generation boundary for application-consumer documentation.\n *\n * The complete result is synchronized into one stable, generator-owned tree.\n * API-reference files are managed directly at stable semantic paths with no\n * checksum manifest or content-addressed identity. Previous versions, diffs,\n * and rollback are intentionally delegated to Git.\n */\nexport class TechnicalDocumentationPilotCompanionService {\n public constructor(private readonly saasRoot: string) {}\n\n private async withExclusivePublicationOperation<T>(rootPath: string, operation: () => Promise<T>): Promise<T> {\n const predecessor = publicationOperationQueues.get(rootPath) ?? Promise.resolve();\n let release!: () => void;\n const currentOperation = new Promise<void>((resolve) => {\n release = resolve;\n });\n const queueTail = predecessor.catch(() => undefined).then(() => currentOperation);\n publicationOperationQueues.set(rootPath, queueTail);\n await predecessor.catch(() => undefined);\n try {\n return await operation();\n } finally {\n release();\n if (publicationOperationQueues.get(rootPath) === queueTail) publicationOperationQueues.delete(rootPath);\n }\n }\n\n public async generateValidateAndPublish(input: {\n readonly derivation: TechnicalDocumentationPilotCompositionDerivation;\n readonly supportedApiVersion: TechnicalDocumentationSupportedApiVersion;\n readonly refuseProvisionalAssets?: boolean;\n readonly forbiddenPublicSentinels: readonly string[];\n readonly budgets: TechnicalDocumentationOutputBudgets;\n readonly resolveApiReferenceTarget?: (target: TechnicalDocumentationApiReferenceTargetV1) => string;\n readonly resolvedAt?: string;\n readonly publishedAt?: string;\n }): Promise<TechnicalDocumentationPilotOperationResult> {\n const publicationEvaluatedAt = input.publishedAt ?? new Date().toISOString();\n const publicationEvaluatedAtEpochMs = Date.parse(publicationEvaluatedAt);\n const freshnessEvaluatedAtEpochMs = Date.parse(input.derivation.privateDerivation.environmentEvidenceSnapshot.freshnessEvaluatedAt);\n if (publicationEvaluatedAtEpochMs < freshnessEvaluatedAtEpochMs) {\n throw new Error('technical-documentation publication time cannot precede the derivation freshness evaluation');\n }\n const assets = await new TechnicalDocumentationPilotAssetsCompanionService().resolve({\n authorizedBundle: input.derivation.publicBundle,\n ...(input.resolvedAt === undefined ? {} : { resolvedAt: input.resolvedAt }),\n });\n if (input.refuseProvisionalAssets === true) {\n const provisional = assets.resolvedAssetBundle.resolvedAssetSet.assets\n .filter((asset) => asset.status === TechnicalDocumentationAssetResolutionStatus.PLACEHOLDER)\n .map((asset) => asset.assetRef);\n if (provisional.length > 0) {\n throw new Error(`technical-documentation publication refuses provisional assets in this environment: ${provisional.join(', ')}`);\n }\n }\n\n const verified = readTechnicalDocumentationAuthorizedRenderInput({\n authorizedBundle: input.derivation.publicBundle,\n resolvedAssetBundle: assets.resolvedAssetBundle,\n assetBytesByPath: assets.assetBytesByPath,\n });\n for (const observation of input.derivation.privateDerivation.environmentEvidenceSnapshot.observations) {\n if (\n observation.validUntil !== null\n && [\n TechnicalDocumentationApplicabilityEvidenceStatus.PROVEN,\n TechnicalDocumentationApplicabilityEvidenceStatus.DISPROVEN,\n TechnicalDocumentationApplicabilityEvidenceStatus.CONFLICTED,\n ].includes(observation.status)\n && Date.parse(observation.validUntil) <= publicationEvaluatedAtEpochMs\n ) {\n throw new Error(`technical-documentation publication requires re-derivation because evidence expired during asset resolution: ${observation.axis}/${observation.subjectRef}`);\n }\n }\n\n const renderModel = createTechnicalDocumentationRenderModel(verified.authorizedBundle);\n const rendererResults = [\n renderTechnicalDocumentationMarkdown({ model: renderModel, resolvedAssetBundle: verified.resolvedAssetBundle, assetBytesByPath: assets.assetBytesByPath, resolveApiReferenceTarget: input.resolveApiReferenceTarget }),\n renderTechnicalDocumentationSearchIndexes(renderModel),\n renderTechnicalDocumentationDocusaurus({ model: renderModel, resolvedAssetBundle: verified.resolvedAssetBundle, assetBytesByPath: assets.assetBytesByPath, resolveApiReferenceTarget: input.resolveApiReferenceTarget }),\n ];\n const publication = await this.publish({\n authorizedBundle: verified.authorizedBundle,\n resolvedAssetBundle: verified.resolvedAssetBundle,\n supportedApiVersion: input.supportedApiVersion,\n rendererResults,\n forbiddenPublicSentinels: input.forbiddenPublicSentinels,\n budgets: input.budgets,\n publishedAt: publicationEvaluatedAt,\n });\n const evidenceLimitations = input.derivation.privateDerivation.environmentEvidenceSnapshot.observations\n .filter((observation) => observation.status !== TechnicalDocumentationApplicabilityEvidenceStatus.PROVEN)\n .map((observation) => ({ axis: observation.axis, subjectRef: observation.subjectRef, status: observation.status, reason: observation.reason }));\n\n return Object.freeze({\n ...publication,\n causalIdentities: Object.freeze({\n derivation: { ref: input.derivation.privateDerivation.derivationRef, version: input.derivation.privateDerivation.derivationVersion },\n authorizedBundle: { ref: verified.authorizedBundle.bundleRef, version: verified.authorizedBundle.bundleVersion },\n resolvedAssetBundle: { ref: verified.resolvedAssetBundle.assetBundleRef, version: verified.resolvedAssetBundle.assetBundleVersion },\n render: { ref: publication.manifest.renderRef, version: publication.manifest.renderVersion },\n }),\n channelCounts: Object.freeze({ publicUnits: input.derivation.publicBundle.units.length }),\n suppressions: Object.freeze(input.derivation.publicBundle.decisions\n .filter((decision) => decision.publishedUnitVersion === null)\n .map((decision) => ({ unitRef: decision.unitRef, reason: decision.reason }))),\n evidenceLimitations: Object.freeze(evidenceLimitations),\n assetStates: Object.freeze(assets.resolvedAssetBundle.resolvedAssetSet.assets.map((asset) => ({\n assetRef: asset.assetRef,\n status: asset.status,\n byteDigest: asset.byteDigest,\n }))),\n freshnessEvaluatedAt: input.derivation.privateDerivation.environmentEvidenceSnapshot.freshnessEvaluatedAt,\n });\n }\n\n public async publish(input: {\n readonly authorizedBundle: TechnicalDocumentationAuthorizedBundleManifestV1;\n readonly resolvedAssetBundle: TechnicalDocumentationResolvedAssetBundleManifestV1;\n readonly supportedApiVersion: TechnicalDocumentationSupportedApiVersion;\n readonly rendererResults: readonly TechnicalDocumentationRendererResult[];\n readonly forbiddenPublicSentinels: readonly string[];\n readonly budgets: TechnicalDocumentationOutputBudgets;\n readonly publishedAt?: string;\n }): Promise<TechnicalDocumentationPilotPublicationResult> {\n const rootPath = path.resolve(this.saasRoot, GENERATED_ROOT_RELATIVE_PATH);\n return this.withExclusivePublicationOperation(rootPath, async () => {\n if (input.authorizedBundle.channel !== TechnicalDocumentationChannel.PUBLIC_PORTAL) {\n throw new Error('technical-documentation consumer publisher accepts only a PUBLIC_PORTAL bundle');\n }\n const manifest = createTechnicalDocumentationAggregateRenderManifest({\n ...input,\n renderRef: CONSUMER_DOCUMENTATION_RENDER_REF,\n // One render per authorized bundle version: re-rendering the same bundle is the same render.\n renderVersion: input.authorizedBundle.bundleVersion,\n });\n const files = input.rendererResults.flatMap((result) => result.files);\n const validation = validateTechnicalDocumentationManagedTree({ ...input, manifest, files });\n assertPathWithin(path.resolve(this.saasRoot), rootPath);\n await this.synchronizeGeneratedTree(rootPath, RENDER_MANIFEST_FILE_NAME, manifest, files);\n await this.writeConsumerDocumentationPublicationSignal({\n renderRef: manifest.renderRef,\n renderVersion: manifest.renderVersion,\n publishedAt: input.publishedAt ?? new Date().toISOString(),\n });\n return Object.freeze({ rootPath, contentPath: rootPath, manifest, validation });\n });\n }\n\n /** Publishes only renderer-produced OpenAPI files into the separate API tree. */\n public async publishOpenApiDocuments(input: {\n readonly documents: OpenApiGenerationOutput;\n readonly sourceUnitRefs: readonly string[];\n }): Promise<{ readonly rootPath: string; readonly outputPaths: readonly string[] }> {\n const rootPath = path.resolve(this.saasRoot, API_REFERENCE_GENERATED_ROOT_RELATIVE_PATH);\n return this.withExclusivePublicationOperation(rootPath, async () => {\n assertPathWithin(path.resolve(this.saasRoot), rootPath);\n const renderer = renderVerifiedTechnicalDocumentationOpenApi(input);\n await this.synchronizeGeneratedFiles(rootPath, renderer.files);\n return Object.freeze({\n rootPath,\n outputPaths: Object.freeze(renderer.files.map((file) => file.normalizedRelativePath).sort()),\n });\n });\n }\n\n /**\n * Synchronizes a generated tree from semantic paths alone.\n *\n * The API reference is reproducible output checked into Git, so a parallel\n * checksum inventory adds a second representation without adding product\n * meaning. Exact path inventory still prevents stale generated files from\n * surviving a section or filename change.\n */\n private async synchronizeGeneratedFiles(\n rootPath: string,\n files: readonly Pick<TechnicalDocumentationRenderedFile, 'normalizedRelativePath' | 'bytes'>[],\n ): Promise<void> {\n await mkdir(rootPath, { recursive: true });\n const rootInfo = await lstat(rootPath);\n if (!rootInfo.isDirectory() || rootInfo.isSymbolicLink()) {\n throw new Error('technical-documentation generated root must be a regular directory');\n }\n\n const expectedPaths = new Set(files.map((file) => file.normalizedRelativePath));\n for (const file of files) await this.writeGeneratedFile(rootPath, file.normalizedRelativePath, file.bytes);\n await this.removeStaleGeneratedEntries(rootPath, expectedPaths);\n\n const inventory = await listRegularFiles(rootPath);\n if (inventory.join('\\0') !== [...expectedPaths].sort().join('\\0')) {\n throw new Error('technical-documentation generated tree inventory does not match the render result');\n }\n await fsyncPath(rootPath);\n }\n\n private async synchronizeGeneratedTree(\n rootPath: string,\n manifestFileName: string,\n manifest: { readonly outputs: readonly { readonly normalizedRelativePath: string; readonly byteLength: number; readonly byteDigest: string }[] },\n files: readonly TechnicalDocumentationRenderedFile[],\n ): Promise<void> {\n await mkdir(rootPath, { recursive: true });\n const rootInfo = await lstat(rootPath);\n if (!rootInfo.isDirectory() || rootInfo.isSymbolicLink()) {\n throw new Error('technical-documentation generated root must be a regular directory');\n }\n\n const expectedPaths = new Set<string>([\n manifestFileName,\n ...files.map((file) => file.normalizedRelativePath),\n ]);\n for (const file of files) await this.writeGeneratedFile(rootPath, file.normalizedRelativePath, file.bytes);\n await this.writeGeneratedFile(rootPath, manifestFileName, `${JSON.stringify(manifest, null, 2)}\\n`);\n await this.removeStaleGeneratedEntries(rootPath, expectedPaths);\n\n const inventory = await listRegularFiles(rootPath);\n if (inventory.join('\\0') !== [...expectedPaths].sort().join('\\0')) {\n throw new Error('technical-documentation generated tree inventory does not match the render result');\n }\n for (const output of manifest.outputs) {\n const bytes = await readFile(path.join(rootPath, output.normalizedRelativePath));\n if (bytes.byteLength !== output.byteLength || technicalDocumentationSha256Bytes(bytes) !== output.byteDigest) {\n throw new Error(`technical-documentation generated tree byte mismatch: ${output.normalizedRelativePath}`);\n }\n }\n await fsyncPath(rootPath);\n }\n\n /**\n * Tells the local docs host that a complete, verified publication is ready.\n *\n * This signal is deliberately outside the checked-in generated tree. The\n * tree remains a stable, content-addressed-by-manifest publication owned by\n * Git; the signal is ephemeral local-dev orchestration state. It is written\n * only after all rendered bytes and the manifest have been synchronized and\n * re-verified, so a Docusaurus reload cannot observe a half-publication.\n */\n private async writeConsumerDocumentationPublicationSignal(input: {\n readonly renderRef: string;\n readonly renderVersion: number;\n readonly publishedAt: string;\n }): Promise<void> {\n const signalPath = path.resolve(this.saasRoot, CONSUMER_DOCUMENTATION_PUBLICATION_SIGNAL_RELATIVE_PATH);\n assertPathWithin(path.resolve(this.saasRoot), signalPath);\n const signalDirectory = path.dirname(signalPath);\n await mkdir(signalDirectory, { recursive: true });\n const temporaryPath = path.join(signalDirectory, `.${path.basename(signalPath)}.wildo-tmp-${randomUUID()}`);\n try {\n await writeFile(temporaryPath, `${JSON.stringify({ schemaVersion: 1, ...input }, null, 2)}\\n`);\n await fsyncPath(temporaryPath);\n await rename(temporaryPath, signalPath);\n await fsyncPath(signalDirectory);\n } catch (error) {\n await rm(temporaryPath, { force: true });\n throw error;\n }\n }\n\n private async writeGeneratedFile(rootPath: string, relativePath: string, bytes: Uint8Array | string): Promise<void> {\n const target = path.resolve(rootPath, relativePath);\n assertPathWithin(rootPath, target);\n await this.prepareGeneratedParent(rootPath, path.dirname(target));\n if (await pathExists(target)) {\n const targetInfo = await lstat(target);\n if (targetInfo.isDirectory()) await rm(target, { recursive: true });\n else if (targetInfo.isFile()) {\n const currentBytes = await readFile(target);\n const nextBytes = typeof bytes === 'string' ? Buffer.from(bytes, 'utf8') : bytes;\n if (currentBytes.equals(nextBytes)) return;\n }\n }\n const temporary = path.join(path.dirname(target), `.${path.basename(target)}.wildo-tmp-${randomUUID()}`);\n try {\n await writeFile(temporary, bytes);\n await fsyncPath(temporary);\n await rename(temporary, target);\n await fsyncPath(path.dirname(target));\n } catch (error) {\n await rm(temporary, { force: true });\n throw error;\n }\n }\n\n private async prepareGeneratedParent(rootPath: string, parentPath: string): Promise<void> {\n const relative = path.relative(rootPath, parentPath);\n if (relative === '') return;\n let current = rootPath;\n for (const segment of relative.split(path.sep)) {\n current = path.join(current, segment);\n let directoryExists = false;\n if (await pathExists(current)) {\n const info = await lstat(current);\n if (info.isSymbolicLink()) throw new Error(`technical-documentation generated path rejects symbolic-link parent: ${current}`);\n if (!info.isDirectory()) await rm(current);\n else directoryExists = true;\n }\n if (!directoryExists) await mkdir(current);\n }\n }\n\n private async removeStaleGeneratedEntries(\n rootPath: string,\n expectedPaths: ReadonlySet<string>,\n relativeDirectory = '',\n ): Promise<void> {\n const directory = relativeDirectory === '' ? rootPath : path.join(rootPath, relativeDirectory);\n for (const entry of await readdir(directory, { withFileTypes: true })) {\n const relativePath = (relativeDirectory === '' ? entry.name : `${relativeDirectory}/${entry.name}`).split(path.sep).join('/');\n const absolutePath = path.join(rootPath, relativePath);\n if (entry.isDirectory() && !entry.isSymbolicLink()) {\n const directoryIsNeeded = [...expectedPaths].some((expectedPath) => expectedPath.startsWith(`${relativePath}/`));\n if (!directoryIsNeeded) await rm(absolutePath, { recursive: true });\n else await this.removeStaleGeneratedEntries(rootPath, expectedPaths, relativePath);\n } else if (!expectedPaths.has(relativePath)) {\n await rm(absolutePath, { force: true });\n }\n }\n }\n}\n"]}
1
+ {"version":3,"file":"technical-documentation-pilot.companion.service.js","sourceRoot":"","sources":["../../../../src/technical-doc/services/technical-documentation-pilot.companion.service.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AACzC,OAAO,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC;AACpC,OAAO,EAAE,MAAM,EAAE,KAAK,EAAE,KAAK,EAAE,IAAI,EAAE,QAAQ,EAAE,OAAO,EAAE,MAAM,EAAE,EAAE,EAAE,SAAS,EAAE,MAAM,kBAAkB,CAAC;AACxG,OAAO,IAAI,MAAM,WAAW,CAAC;AAE7B,OAAO,EACL,iDAAiD,EAEjD,2CAA2C,EAC3C,6BAA6B,GAM9B,MAAM,uDAAuD,CAAC;AAC/D,OAAO,EACL,mDAAmD,EACnD,uCAAuC,EACvC,+CAA+C,EAC/C,sCAAsC,EACtC,yCAAyC,EACzC,2CAA2C,EAC3C,iCAAiC,EACjC,yCAAyC,GAK1C,MAAM,wCAAwC,CAAC;AAEhD,OAAO,EAAE,iDAAiD,EAAE,MAAM,0DAA0D,CAAC;AAE7H,MAAM,4BAA4B,GAAG,IAAI,CAAC,IAAI,CAAC,eAAe,EAAE,KAAK,EAAE,WAAW,EAAE,wBAAwB,CAAC,CAAC;AAC9G,MAAM,0CAA0C,GAAG,IAAI,CAAC,IAAI,CAAC,eAAe,EAAE,KAAK,EAAE,WAAW,EAAE,eAAe,CAAC,CAAC;AACnH,MAAM,yBAAyB,GAAG,6BAA6B,CAAC;AAChE,MAAM,iCAAiC,GAAG,uDAAuD,CAAC;AAClG,MAAM,uDAAuD,GAAG,IAAI,CAAC,IAAI,CACvE,aAAa,EACb,iBAAiB,EACjB,yBAAyB,EACzB,uCAAuC,CACxC,CAAC;AACF,MA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AAC,IAAI,CAAC,GAAG,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;YAC9H,MAAM,YAAY,GAAG,IAAI,CAAC,IAAI,CAAC,QAAQ,EAAE,YAAY,CAAC,CAAC;YACvD,IAAI,KAAK,CAAC,WAAW,EAAE,IAAI,CAAC,KAAK,CAAC,cAAc,EAAE,EAAE,CAAC;gBACnD,MAAM,iBAAiB,GAAG,CAAC,GAAG,aAAa,CAAC,CAAC,IAAI,CAAC,CAAC,YAAY,EAAE,EAAE,CAAC,YAAY,CAAC,UAAU,CAAC,GAAG,YAAY,GAAG,CAAC,CAAC,CAAC;gBACjH,IAAI,CAAC,iBAAiB;oBAAE,MAAM,EAAE,CAAC,YAAY,EAAE,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC,CAAC;;oBAC/D,MAAM,IAAI,CAAC,2BAA2B,CAAC,QAAQ,EAAE,aAAa,EAAE,YAAY,CAAC,CAAC;YACrF,CAAC;iBAAM,IAAI,CAAC,aAAa,CAAC,GAAG,CAAC,YAAY,CAAC,EAAE,CAAC;gBAC5C,MAAM,EAAE,CAAC,YAAY,EAAE,EAAE,KAAK,EAAE,IAAI,EAAE,CAAC,CAAC;YAC1C,CAAC;QACH,CAAC;IACH,CAAC;CACF","sourcesContent":["import { randomUUID } from 'node:crypto';\nimport { constants } from 'node:fs';\nimport { access, lstat, mkdir, open, readFile, readdir, rename, rm, writeFile } from 'node:fs/promises';\nimport path from 'node:path';\n\nimport {\n TechnicalDocumentationApplicabilityEvidenceStatus,\n type TechnicalDocumentationApiReferenceTargetV1,\n TechnicalDocumentationAssetResolutionStatus,\n TechnicalDocumentationChannel,\n type TechnicalDocumentationAuthorizedBundleManifestV1,\n type TechnicalDocumentationPrivateDerivationManifestV1,\n type TechnicalDocumentationVersionedIdentityV1,\n type TechnicalDocumentationResolvedAssetBundleManifestV1,\n type TechnicalDocumentationSupportedApiVersion,\n} from '@wildo-ai/saas-specifications/technical-documentation';\nimport {\n createTechnicalDocumentationAggregateRenderManifest,\n createTechnicalDocumentationRenderModel,\n readTechnicalDocumentationAuthorizedRenderInput,\n renderTechnicalDocumentationDocusaurus,\n renderTechnicalDocumentationSearchIndexes,\n renderVerifiedTechnicalDocumentationOpenApi,\n technicalDocumentationSha256Bytes,\n validateTechnicalDocumentationManagedTree,\n type OpenApiGenerationOutput,\n type TechnicalDocumentationOutputBudgets,\n type TechnicalDocumentationRenderedFile,\n type TechnicalDocumentationRendererResult,\n} from '@wildo-ai/saas-technical-doc/companion';\n\nimport { TechnicalDocumentationPilotAssetsCompanionService } from './technical-documentation-pilot-assets.companion.service';\n\nconst GENERATED_ROOT_RELATIVE_PATH = path.join('technical-doc', 'src', 'generated', 'consumer-documentation');\nconst API_REFERENCE_GENERATED_ROOT_RELATIVE_PATH = path.join('technical-doc', 'src', 'generated', 'api-reference');\nconst RENDER_MANIFEST_FILE_NAME = 'render-output-manifest.json';\nconst CONSUMER_DOCUMENTATION_RENDER_REF = 'technical-documentation:render/consumer-documentation';\nconst CONSUMER_DOCUMENTATION_PUBLICATION_SIGNAL_RELATIVE_PATH = path.join(\n '.wildo-saas',\n 'runtime-signals',\n 'technical-documentation',\n 'consumer-documentation-published.json',\n);\nconst publicationOperationQueues = new Map<string, Promise<void>>();\n\nexport interface TechnicalDocumentationPilotPublicationResult {\n readonly rootPath: string;\n readonly contentPath: string;\n readonly manifest: ReturnType<typeof createTechnicalDocumentationAggregateRenderManifest>;\n readonly validation: ReturnType<typeof validateTechnicalDocumentationManagedTree>;\n}\n\nexport interface TechnicalDocumentationPilotOperationResult extends TechnicalDocumentationPilotPublicationResult {\n /**\n * Which exact stage outputs this operation joined, named `ref@version`. Four sha256 fields until\n * 2026-08-27 — unreadable in a log, unmergeable across branches, and never compared to anything.\n */\n readonly causalIdentities: {\n readonly derivation: TechnicalDocumentationVersionedIdentityV1;\n readonly authorizedBundle: TechnicalDocumentationVersionedIdentityV1;\n readonly resolvedAssetBundle: TechnicalDocumentationVersionedIdentityV1;\n readonly render: TechnicalDocumentationVersionedIdentityV1;\n };\n readonly channelCounts: { readonly publicUnits: number };\n readonly suppressions: readonly { readonly unitRef: string; readonly reason: string }[];\n readonly evidenceLimitations: readonly { readonly axis: string; readonly subjectRef: string; readonly status: string; readonly reason: string }[];\n readonly assetStates: readonly { readonly assetRef: string; readonly status: string; readonly byteDigest: string | null }[];\n readonly freshnessEvaluatedAt: string;\n}\n\nexport interface TechnicalDocumentationPilotCompositionDerivation {\n readonly privateDerivation: Pick<\n TechnicalDocumentationPrivateDerivationManifestV1,\n 'derivationRef' | 'derivationVersion' | 'environmentEvidenceSnapshot'\n >;\n readonly publicBundle: TechnicalDocumentationAuthorizedBundleManifestV1;\n}\n\nfunction assertPathWithin(parent: string, child: string): void {\n const relative = path.relative(parent, child);\n if (relative === '' || relative.startsWith('..') || path.isAbsolute(relative)) {\n throw new Error(`technical-documentation managed path escapes its root: ${child}`);\n }\n}\n\nasync function pathExists(target: string): Promise<boolean> {\n try {\n await access(target, constants.F_OK);\n return true;\n } catch {\n return false;\n }\n}\n\nasync function fsyncPath(target: string): Promise<void> {\n const handle = await open(target, 'r');\n try {\n await handle.sync();\n } finally {\n await handle.close();\n }\n}\n\nasync function listRegularFiles(root: string, relative = ''): Promise<string[]> {\n const current = relative === '' ? root : path.join(root, relative);\n const entries = await readdir(current, { withFileTypes: true });\n const files: string[] = [];\n for (const entry of entries) {\n const childRelative = relative === '' ? entry.name : path.join(relative, entry.name);\n const child = path.join(root, childRelative);\n const info = await lstat(child);\n if (info.isSymbolicLink()) throw new Error(`technical-documentation generated tree rejects symbolic links: ${childRelative}`);\n if (info.isDirectory()) files.push(...await listRegularFiles(root, childRelative));\n else if (info.isFile()) files.push(childRelative.split(path.sep).join('/'));\n else throw new Error(`technical-documentation generated tree rejects non-regular entry: ${childRelative}`);\n }\n return files.sort();\n}\n\n/**\n * Companion-owned generation boundary for application-consumer documentation.\n *\n * The complete result is synchronized into one stable, generator-owned tree.\n * API-reference files are managed directly at stable semantic paths with no\n * checksum manifest or content-addressed identity. Previous versions, diffs,\n * and rollback are intentionally delegated to Git.\n */\nexport class TechnicalDocumentationPilotCompanionService {\n public constructor(private readonly saasRoot: string) {}\n\n private async withExclusivePublicationOperation<T>(rootPath: string, operation: () => Promise<T>): Promise<T> {\n const predecessor = publicationOperationQueues.get(rootPath) ?? Promise.resolve();\n let release!: () => void;\n const currentOperation = new Promise<void>((resolve) => {\n release = resolve;\n });\n const queueTail = predecessor.catch(() => undefined).then(() => currentOperation);\n publicationOperationQueues.set(rootPath, queueTail);\n await predecessor.catch(() => undefined);\n try {\n return await operation();\n } finally {\n release();\n if (publicationOperationQueues.get(rootPath) === queueTail) publicationOperationQueues.delete(rootPath);\n }\n }\n\n public async generateValidateAndPublish(input: {\n readonly derivation: TechnicalDocumentationPilotCompositionDerivation;\n readonly supportedApiVersion: TechnicalDocumentationSupportedApiVersion;\n readonly refuseProvisionalAssets?: boolean;\n readonly forbiddenPublicSentinels: readonly string[];\n readonly budgets: TechnicalDocumentationOutputBudgets;\n /** Returns `null` when this application does not publish the target — the link degrades to plain text (#472). */\n readonly resolveApiReferenceTarget?: (target: TechnicalDocumentationApiReferenceTargetV1) => string | null;\n readonly resolvedAt?: string;\n readonly publishedAt?: string;\n }): Promise<TechnicalDocumentationPilotOperationResult> {\n const publicationEvaluatedAt = input.publishedAt ?? new Date().toISOString();\n const publicationEvaluatedAtEpochMs = Date.parse(publicationEvaluatedAt);\n const freshnessEvaluatedAtEpochMs = Date.parse(input.derivation.privateDerivation.environmentEvidenceSnapshot.freshnessEvaluatedAt);\n if (publicationEvaluatedAtEpochMs < freshnessEvaluatedAtEpochMs) {\n throw new Error('technical-documentation publication time cannot precede the derivation freshness evaluation');\n }\n const assets = await new TechnicalDocumentationPilotAssetsCompanionService().resolve({\n authorizedBundle: input.derivation.publicBundle,\n ...(input.resolvedAt === undefined ? {} : { resolvedAt: input.resolvedAt }),\n });\n if (input.refuseProvisionalAssets === true) {\n const provisional = assets.resolvedAssetBundle.resolvedAssetSet.assets\n .filter((asset) => asset.status === TechnicalDocumentationAssetResolutionStatus.PLACEHOLDER)\n .map((asset) => asset.assetRef);\n if (provisional.length > 0) {\n throw new Error(`technical-documentation publication refuses provisional assets in this environment: ${provisional.join(', ')}`);\n }\n }\n\n const verified = readTechnicalDocumentationAuthorizedRenderInput({\n authorizedBundle: input.derivation.publicBundle,\n resolvedAssetBundle: assets.resolvedAssetBundle,\n assetBytesByPath: assets.assetBytesByPath,\n });\n for (const observation of input.derivation.privateDerivation.environmentEvidenceSnapshot.observations) {\n if (\n observation.validUntil !== null\n && [\n TechnicalDocumentationApplicabilityEvidenceStatus.PROVEN,\n TechnicalDocumentationApplicabilityEvidenceStatus.DISPROVEN,\n TechnicalDocumentationApplicabilityEvidenceStatus.CONFLICTED,\n ].includes(observation.status)\n && Date.parse(observation.validUntil) <= publicationEvaluatedAtEpochMs\n ) {\n throw new Error(`technical-documentation publication requires re-derivation because evidence expired during asset resolution: ${observation.axis}/${observation.subjectRef}`);\n }\n }\n\n const renderModel = createTechnicalDocumentationRenderModel(verified.authorizedBundle);\n /*\n * Two renderers, not three. A portable-markdown family was rendered here for as long as this\n * pipeline existed and NOTHING ever read it: the site mounts `docusaurus/docs`,\n * `docusaurus/sidebars.json` and `docusaurus/static`, and `src/pages/search.tsx` reads\n * `indexes/search.json` — measured with a positive control, so the empty result is a real\n * absence rather than a bad probe. It cost 81 files and 511 KB per publication, half the\n * published bytes, and it silently DOUBLED the operator-facing page budget: both families emit\n * `MARKDOWN_DOCUMENT`, so a 81-page application counted 162 against `maximumPageCount` (#274).\n */\n const rendererResults = [\n renderTechnicalDocumentationSearchIndexes(renderModel),\n renderTechnicalDocumentationDocusaurus({ model: renderModel, resolvedAssetBundle: verified.resolvedAssetBundle, assetBytesByPath: assets.assetBytesByPath, resolveApiReferenceTarget: input.resolveApiReferenceTarget }),\n ];\n const publication = await this.publish({\n authorizedBundle: verified.authorizedBundle,\n resolvedAssetBundle: verified.resolvedAssetBundle,\n supportedApiVersion: input.supportedApiVersion,\n rendererResults,\n forbiddenPublicSentinels: input.forbiddenPublicSentinels,\n budgets: input.budgets,\n publishedAt: publicationEvaluatedAt,\n });\n const evidenceLimitations = input.derivation.privateDerivation.environmentEvidenceSnapshot.observations\n .filter((observation) => observation.status !== TechnicalDocumentationApplicabilityEvidenceStatus.PROVEN)\n .map((observation) => ({ axis: observation.axis, subjectRef: observation.subjectRef, status: observation.status, reason: observation.reason }));\n\n return Object.freeze({\n ...publication,\n causalIdentities: Object.freeze({\n derivation: { ref: input.derivation.privateDerivation.derivationRef, version: input.derivation.privateDerivation.derivationVersion },\n authorizedBundle: { ref: verified.authorizedBundle.bundleRef, version: verified.authorizedBundle.bundleVersion },\n resolvedAssetBundle: { ref: verified.resolvedAssetBundle.assetBundleRef, version: verified.resolvedAssetBundle.assetBundleVersion },\n render: { ref: publication.manifest.renderRef, version: publication.manifest.renderVersion },\n }),\n channelCounts: Object.freeze({ publicUnits: input.derivation.publicBundle.units.length }),\n suppressions: Object.freeze(input.derivation.publicBundle.decisions\n .filter((decision) => decision.publishedUnitVersion === null)\n .map((decision) => ({ unitRef: decision.unitRef, reason: decision.reason }))),\n evidenceLimitations: Object.freeze(evidenceLimitations),\n assetStates: Object.freeze(assets.resolvedAssetBundle.resolvedAssetSet.assets.map((asset) => ({\n assetRef: asset.assetRef,\n status: asset.status,\n byteDigest: asset.byteDigest,\n }))),\n freshnessEvaluatedAt: input.derivation.privateDerivation.environmentEvidenceSnapshot.freshnessEvaluatedAt,\n });\n }\n\n public async publish(input: {\n readonly authorizedBundle: TechnicalDocumentationAuthorizedBundleManifestV1;\n readonly resolvedAssetBundle: TechnicalDocumentationResolvedAssetBundleManifestV1;\n readonly supportedApiVersion: TechnicalDocumentationSupportedApiVersion;\n readonly rendererResults: readonly TechnicalDocumentationRendererResult[];\n readonly forbiddenPublicSentinels: readonly string[];\n readonly budgets: TechnicalDocumentationOutputBudgets;\n readonly publishedAt?: string;\n }): Promise<TechnicalDocumentationPilotPublicationResult> {\n const rootPath = path.resolve(this.saasRoot, GENERATED_ROOT_RELATIVE_PATH);\n return this.withExclusivePublicationOperation(rootPath, async () => {\n if (input.authorizedBundle.channel !== TechnicalDocumentationChannel.PUBLIC_PORTAL) {\n throw new Error('technical-documentation consumer publisher accepts only a PUBLIC_PORTAL bundle');\n }\n const manifest = createTechnicalDocumentationAggregateRenderManifest({\n ...input,\n renderRef: CONSUMER_DOCUMENTATION_RENDER_REF,\n // One render per authorized bundle version: re-rendering the same bundle is the same render.\n renderVersion: input.authorizedBundle.bundleVersion,\n });\n const files = input.rendererResults.flatMap((result) => result.files);\n const validation = validateTechnicalDocumentationManagedTree({ ...input, manifest, files });\n assertPathWithin(path.resolve(this.saasRoot), rootPath);\n await this.synchronizeGeneratedTree(rootPath, RENDER_MANIFEST_FILE_NAME, manifest, files);\n await this.writeConsumerDocumentationPublicationSignal({\n renderRef: manifest.renderRef,\n renderVersion: manifest.renderVersion,\n publishedAt: input.publishedAt ?? new Date().toISOString(),\n });\n return Object.freeze({ rootPath, contentPath: rootPath, manifest, validation });\n });\n }\n\n /** Publishes only renderer-produced OpenAPI files into the separate API tree. */\n public async publishOpenApiDocuments(input: {\n readonly documents: OpenApiGenerationOutput;\n readonly sourceUnitRefs: readonly string[];\n }): Promise<{ readonly rootPath: string; readonly outputPaths: readonly string[] }> {\n const rootPath = path.resolve(this.saasRoot, API_REFERENCE_GENERATED_ROOT_RELATIVE_PATH);\n return this.withExclusivePublicationOperation(rootPath, async () => {\n assertPathWithin(path.resolve(this.saasRoot), rootPath);\n const renderer = renderVerifiedTechnicalDocumentationOpenApi(input);\n await this.synchronizeGeneratedFiles(rootPath, renderer.files);\n return Object.freeze({\n rootPath,\n outputPaths: Object.freeze(renderer.files.map((file) => file.normalizedRelativePath).sort()),\n });\n });\n }\n\n /**\n * Synchronizes a generated tree from semantic paths alone.\n *\n * The API reference is reproducible output checked into Git, so a parallel\n * checksum inventory adds a second representation without adding product\n * meaning. Exact path inventory still prevents stale generated files from\n * surviving a section or filename change.\n */\n private async synchronizeGeneratedFiles(\n rootPath: string,\n files: readonly Pick<TechnicalDocumentationRenderedFile, 'normalizedRelativePath' | 'bytes'>[],\n ): Promise<void> {\n await mkdir(rootPath, { recursive: true });\n const rootInfo = await lstat(rootPath);\n if (!rootInfo.isDirectory() || rootInfo.isSymbolicLink()) {\n throw new Error('technical-documentation generated root must be a regular directory');\n }\n\n const expectedPaths = new Set(files.map((file) => file.normalizedRelativePath));\n for (const file of files) await this.writeGeneratedFile(rootPath, file.normalizedRelativePath, file.bytes);\n await this.removeStaleGeneratedEntries(rootPath, expectedPaths);\n\n const inventory = await listRegularFiles(rootPath);\n if (inventory.join('\\0') !== [...expectedPaths].sort().join('\\0')) {\n throw new Error('technical-documentation generated tree inventory does not match the render result');\n }\n await fsyncPath(rootPath);\n }\n\n private async synchronizeGeneratedTree(\n rootPath: string,\n manifestFileName: string,\n manifest: { readonly outputs: readonly { readonly normalizedRelativePath: string; readonly byteLength: number; readonly byteDigest: string }[] },\n files: readonly TechnicalDocumentationRenderedFile[],\n ): Promise<void> {\n await mkdir(rootPath, { recursive: true });\n const rootInfo = await lstat(rootPath);\n if (!rootInfo.isDirectory() || rootInfo.isSymbolicLink()) {\n throw new Error('technical-documentation generated root must be a regular directory');\n }\n\n const expectedPaths = new Set<string>([\n manifestFileName,\n ...files.map((file) => file.normalizedRelativePath),\n ]);\n for (const file of files) await this.writeGeneratedFile(rootPath, file.normalizedRelativePath, file.bytes);\n await this.writeGeneratedFile(rootPath, manifestFileName, `${JSON.stringify(manifest, null, 2)}\\n`);\n await this.removeStaleGeneratedEntries(rootPath, expectedPaths);\n\n const inventory = await listRegularFiles(rootPath);\n if (inventory.join('\\0') !== [...expectedPaths].sort().join('\\0')) {\n throw new Error('technical-documentation generated tree inventory does not match the render result');\n }\n for (const output of manifest.outputs) {\n const bytes = await readFile(path.join(rootPath, output.normalizedRelativePath));\n if (bytes.byteLength !== output.byteLength || technicalDocumentationSha256Bytes(bytes) !== output.byteDigest) {\n throw new Error(`technical-documentation generated tree byte mismatch: ${output.normalizedRelativePath}`);\n }\n }\n await fsyncPath(rootPath);\n }\n\n /**\n * Tells the local docs host that a complete, verified publication is ready.\n *\n * This signal is deliberately outside the checked-in generated tree. The\n * tree remains a stable, content-addressed-by-manifest publication owned by\n * Git; the signal is ephemeral local-dev orchestration state. It is written\n * only after all rendered bytes and the manifest have been synchronized and\n * re-verified, so a Docusaurus reload cannot observe a half-publication.\n */\n private async writeConsumerDocumentationPublicationSignal(input: {\n readonly renderRef: string;\n readonly renderVersion: number;\n readonly publishedAt: string;\n }): Promise<void> {\n const signalPath = path.resolve(this.saasRoot, CONSUMER_DOCUMENTATION_PUBLICATION_SIGNAL_RELATIVE_PATH);\n assertPathWithin(path.resolve(this.saasRoot), signalPath);\n const signalDirectory = path.dirname(signalPath);\n await mkdir(signalDirectory, { recursive: true });\n const temporaryPath = path.join(signalDirectory, `.${path.basename(signalPath)}.wildo-tmp-${randomUUID()}`);\n try {\n await writeFile(temporaryPath, `${JSON.stringify({ schemaVersion: 1, ...input }, null, 2)}\\n`);\n await fsyncPath(temporaryPath);\n await rename(temporaryPath, signalPath);\n await fsyncPath(signalDirectory);\n } catch (error) {\n await rm(temporaryPath, { force: true });\n throw error;\n }\n }\n\n private async writeGeneratedFile(rootPath: string, relativePath: string, bytes: Uint8Array | string): Promise<void> {\n const target = path.resolve(rootPath, relativePath);\n assertPathWithin(rootPath, target);\n await this.prepareGeneratedParent(rootPath, path.dirname(target));\n if (await pathExists(target)) {\n const targetInfo = await lstat(target);\n if (targetInfo.isDirectory()) await rm(target, { recursive: true });\n else if (targetInfo.isFile()) {\n const currentBytes = await readFile(target);\n const nextBytes = typeof bytes === 'string' ? Buffer.from(bytes, 'utf8') : bytes;\n if (currentBytes.equals(nextBytes)) return;\n }\n }\n const temporary = path.join(path.dirname(target), `.${path.basename(target)}.wildo-tmp-${randomUUID()}`);\n try {\n await writeFile(temporary, bytes);\n await fsyncPath(temporary);\n await rename(temporary, target);\n await fsyncPath(path.dirname(target));\n } catch (error) {\n await rm(temporary, { force: true });\n throw error;\n }\n }\n\n private async prepareGeneratedParent(rootPath: string, parentPath: string): Promise<void> {\n const relative = path.relative(rootPath, parentPath);\n if (relative === '') return;\n let current = rootPath;\n for (const segment of relative.split(path.sep)) {\n current = path.join(current, segment);\n let directoryExists = false;\n if (await pathExists(current)) {\n const info = await lstat(current);\n if (info.isSymbolicLink()) throw new Error(`technical-documentation generated path rejects symbolic-link parent: ${current}`);\n if (!info.isDirectory()) await rm(current);\n else directoryExists = true;\n }\n if (!directoryExists) await mkdir(current);\n }\n }\n\n private async removeStaleGeneratedEntries(\n rootPath: string,\n expectedPaths: ReadonlySet<string>,\n relativeDirectory = '',\n ): Promise<void> {\n const directory = relativeDirectory === '' ? rootPath : path.join(rootPath, relativeDirectory);\n for (const entry of await readdir(directory, { withFileTypes: true })) {\n const relativePath = (relativeDirectory === '' ? entry.name : `${relativeDirectory}/${entry.name}`).split(path.sep).join('/');\n const absolutePath = path.join(rootPath, relativePath);\n if (entry.isDirectory() && !entry.isSymbolicLink()) {\n const directoryIsNeeded = [...expectedPaths].some((expectedPath) => expectedPath.startsWith(`${relativePath}/`));\n if (!directoryIsNeeded) await rm(absolutePath, { recursive: true });\n else await this.removeStaleGeneratedEntries(rootPath, expectedPaths, relativePath);\n } else if (!expectedPaths.has(relativePath)) {\n await rm(absolutePath, { force: true });\n }\n }\n }\n}\n"]}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wildo-ai/dev-companion",
3
- "version": "1.1.2",
3
+ "version": "1.1.4",
4
4
  "description": "Wildo.ai Dev Companion — local development management and introspection service. Canonical source home; applications receive only the built dist below their .wildo-saas/wildo-dev-companion drop.",
5
5
  "author": "Wildo AI",
6
6
  "license": "SEE LICENSE IN LICENSE",
@@ -32,22 +32,22 @@
32
32
  "dependencies": {
33
33
  "@react-email/components": "^1.0.8",
34
34
  "@react-email/render": "^2.0.4",
35
- "@wildo-ai/application-creation-runtime": "1.1.2",
36
- "@wildo-ai/external-connectors-models": "1.1.2",
37
- "@wildo-ai/framework-knowledge": "1.1.2",
38
- "@wildo-ai/platform-config-lib": "1.1.2",
39
- "@wildo-ai/platform-core-backend": "1.1.2",
40
- "@wildo-ai/platform-core-shared": "1.1.2",
41
- "@wildo-ai/platform-shared-lib": "1.1.2",
42
- "@wildo-ai/presets-components-models": "1.1.2",
43
- "@wildo-ai/saas-backend-lib": "1.1.2",
44
- "@wildo-ai/saas-frontend-lib": "1.1.2",
45
- "@wildo-ai/saas-models": "1.1.2",
46
- "@wildo-ai/saas-specifications": "1.1.2",
47
- "@wildo-ai/saas-technical-doc": "1.1.2",
48
- "@wildo-ai/saas-website": "1.1.2",
49
- "@wildo-ai/wildo-module-client": "1.1.2",
50
- "@wildo-ai/zod-decorators": "1.1.2",
35
+ "@wildo-ai/application-creation-runtime": "1.1.4",
36
+ "@wildo-ai/external-connectors-models": "1.1.4",
37
+ "@wildo-ai/framework-knowledge": "1.1.4",
38
+ "@wildo-ai/platform-config-lib": "1.1.4",
39
+ "@wildo-ai/platform-core-backend": "1.1.4",
40
+ "@wildo-ai/platform-core-shared": "1.1.4",
41
+ "@wildo-ai/platform-shared-lib": "1.1.4",
42
+ "@wildo-ai/presets-components-models": "1.1.4",
43
+ "@wildo-ai/saas-backend-lib": "1.1.4",
44
+ "@wildo-ai/saas-frontend-lib": "1.1.4",
45
+ "@wildo-ai/saas-models": "1.1.4",
46
+ "@wildo-ai/saas-specifications": "1.1.4",
47
+ "@wildo-ai/saas-technical-doc": "1.1.4",
48
+ "@wildo-ai/saas-website": "1.1.4",
49
+ "@wildo-ai/wildo-module-client": "1.1.4",
50
+ "@wildo-ai/zod-decorators": "1.1.4",
51
51
  "big.js": "^6.2.2",
52
52
  "cors": "^2.8.5",
53
53
  "date-fns": "^4.1.0",
@@ -1,44 +0,0 @@
1
- import type { AbstractControllerBackendService } from '@wildo-ai/saas-backend-lib';
2
- import type { FlowsActors_Agent } from '@wildo-ai/saas-models';
3
- /**
4
- * Startup-graph identity fence.
5
- *
6
- * Companion startup consumes one caller-supplied composition object across
7
- * several asynchronous phases (Mongo, resolved configuration, providers,
8
- * Flows/Actors, controller mounting). Between capture and consumption that
9
- * object must not change: a substituted or in-place-mutated backend config,
10
- * provider registry, provider runtime, Flows/Actors graph or controller list
11
- * would otherwise be initialized under authority the earlier phases already
12
- * validated.
13
- *
14
- * The fence compares OBJECT IDENTITY, not content: every slot is captured by
15
- * reference (`Object.is`), so a same-shaped replacement is refused exactly
16
- * like a mutated one. Descriptor traversal never invokes a getter, so schemas
17
- * and other executable authority objects are covered without executing their
18
- * code or mistaking a computed value for stable authored state.
19
- *
20
- * History: this guard was extracted from the first-activation runtime-
21
- * composition observer when the provenance-evidence machinery was removed
22
- * (issue #40). Its own JSDoc there already separated the two concerns — the
23
- * fence never entered the portable proof, because object identity has no
24
- * stable cross-process serialization. Only the evidence half was retired.
25
- */
26
- export interface CompanionStartupCompositionFenceInput {
27
- readonly customControllers: readonly AbstractControllerBackendService[];
28
- readonly backendConfig?: unknown;
29
- readonly backendProviderRegistry?: unknown;
30
- readonly providerRuntime?: unknown;
31
- readonly flowsActorsRegistry?: {
32
- readonly flowActorSystemsFactoryMap?: Readonly<Record<string, unknown>>;
33
- readonly agents?: readonly FlowsActors_Agent[];
34
- };
35
- }
36
- export declare class CompanionStartupCompositionFence {
37
- private capturedInput;
38
- private capturedIdentitySlots;
39
- /** Capture the exact startup object. Re-capturing a different object fails closed. */
40
- capture(input: CompanionStartupCompositionFenceInput): void;
41
- /** Re-verify the captured graph immediately before the next startup phase consumes it. */
42
- assertUnchanged(): void;
43
- }
44
- //# sourceMappingURL=companion-startup-composition-fence.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"companion-startup-composition-fence.d.ts","sourceRoot":"","sources":["../../../../../src/core/runtime/companion-startup-composition-fence.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,gCAAgC,EAAE,MAAM,4BAA4B,CAAC;AACnF,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,uBAAuB,CAAC;AAE/D;;;;;;;;;;;;;;;;;;;;;;GAsBG;AACH,MAAM,WAAW,qCAAqC;IACpD,QAAQ,CAAC,iBAAiB,EAAE,SAAS,gCAAgC,EAAE,CAAC;IACxE,QAAQ,CAAC,aAAa,CAAC,EAAE,OAAO,CAAC;IACjC,QAAQ,CAAC,uBAAuB,CAAC,EAAE,OAAO,CAAC;IAC3C,QAAQ,CAAC,eAAe,CAAC,EAAE,OAAO,CAAC;IACnC,QAAQ,CAAC,mBAAmB,CAAC,EAAE;QAC7B,QAAQ,CAAC,0BAA0B,CAAC,EAAE,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC,CAAC;QACxE,QAAQ,CAAC,MAAM,CAAC,EAAE,SAAS,iBAAiB,EAAE,CAAC;KAChD,CAAC;CACH;AAOD,qBACa,gCAAgC;IAC3C,OAAO,CAAC,aAAa,CAAsD;IAC3E,OAAO,CAAC,qBAAqB,CAAmE;IAEhG,sFAAsF;IAC/E,OAAO,CAAC,KAAK,EAAE,qCAAqC,GAAG,IAAI;IAYlE,0FAA0F;IACnF,eAAe,IAAI,IAAI;CAI/B"}
@@ -1,85 +0,0 @@
1
- var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
2
- var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3
- if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
4
- else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
5
- return c > 3 && r && Object.defineProperty(target, key, r), r;
6
- };
7
- import { injectable } from 'inversify';
8
- let CompanionStartupCompositionFence = class CompanionStartupCompositionFence {
9
- capturedInput = null;
10
- capturedIdentitySlots = null;
11
- /** Capture the exact startup object. Re-capturing a different object fails closed. */
12
- capture(input) {
13
- if (this.capturedInput !== null && this.capturedInput !== input) {
14
- throw new Error('Companion startup composition was already captured with a different startup input object.');
15
- }
16
- const candidateIdentitySlots = collectStartupCompositionIdentitySlots(input);
17
- if (this.capturedIdentitySlots && !sameStartupCompositionIdentitySlots(this.capturedIdentitySlots, candidateIdentitySlots)) {
18
- throw new Error('Companion startup composition object identity changed after capture.');
19
- }
20
- this.capturedInput = input;
21
- this.capturedIdentitySlots = candidateIdentitySlots;
22
- }
23
- /** Re-verify the captured graph immediately before the next startup phase consumes it. */
24
- assertUnchanged() {
25
- if (!this.capturedInput)
26
- throw new Error('Companion startup composition has not been captured from the actual startup inputs.');
27
- this.capture(this.capturedInput);
28
- }
29
- };
30
- CompanionStartupCompositionFence = __decorate([
31
- injectable()
32
- ], CompanionStartupCompositionFence);
33
- export { CompanionStartupCompositionFence };
34
- function collectStartupCompositionIdentitySlots(input) {
35
- const slots = [
36
- { path: 'customControllers', value: input.customControllers },
37
- ];
38
- input.customControllers.forEach((controller, index) => slots.push({ path: `customControllers[${index}]`, value: controller }));
39
- const seen = new WeakSet();
40
- collectPlainGraphIdentitySlots(input.backendConfig, 'backendConfig', slots, seen);
41
- collectPlainGraphIdentitySlots(input.backendProviderRegistry, 'backendProviderRegistry', slots, seen);
42
- collectPlainGraphIdentitySlots(input.providerRuntime, 'providerRuntime', slots, seen);
43
- collectPlainGraphIdentitySlots(input.flowsActorsRegistry, 'flowsActorsRegistry', slots, seen);
44
- return slots;
45
- }
46
- /**
47
- * Recursively inventories the complete declarative startup graph. Every object
48
- * contributes its prototype, own keys, descriptors, primitive values and
49
- * nested identity. Functions are atomic references. Descriptor traversal never
50
- * invokes a getter.
51
- */
52
- function collectPlainGraphIdentitySlots(value, path, slots, seen) {
53
- slots.push({ path, value });
54
- if ((typeof value !== 'object' || value === null) && typeof value !== 'function')
55
- return;
56
- const objectValue = value;
57
- if (seen.has(objectValue))
58
- return;
59
- seen.add(objectValue);
60
- if (typeof value === 'function')
61
- return;
62
- const prototype = Object.getPrototypeOf(objectValue);
63
- slots.push({ path: `${path}.[[prototype]]`, value: prototype });
64
- for (const [index, key] of Reflect.ownKeys(objectValue).entries()) {
65
- const keyPath = `${path}.[[ownKey:${index}]]`;
66
- slots.push({ path: keyPath, value: key });
67
- const descriptor = Object.getOwnPropertyDescriptor(objectValue, key);
68
- if (!descriptor)
69
- throw new Error(`Companion startup composition property disappeared during capture at ${keyPath}.`);
70
- slots.push({ path: `${keyPath}.enumerable`, value: descriptor.enumerable });
71
- slots.push({ path: `${keyPath}.configurable`, value: descriptor.configurable });
72
- if ('value' in descriptor) {
73
- slots.push({ path: `${keyPath}.writable`, value: descriptor.writable });
74
- collectPlainGraphIdentitySlots(descriptor.value, `${keyPath}.value`, slots, seen);
75
- continue;
76
- }
77
- slots.push({ path: `${keyPath}.get`, value: descriptor.get });
78
- slots.push({ path: `${keyPath}.set`, value: descriptor.set });
79
- }
80
- }
81
- function sameStartupCompositionIdentitySlots(captured, current) {
82
- return captured.length === current.length
83
- && captured.every((slot, index) => slot.path === current[index]?.path && Object.is(slot.value, current[index]?.value));
84
- }
85
- //# sourceMappingURL=companion-startup-composition-fence.js.map