@wildo-ai/dev-companion 1.1.4 → 1.1.5

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 (1275) 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/__time-gov.probe.d.mts +0 -0
  6. package/dist/esm/__time-gov.probe.d.mts.map +0 -0
  7. package/dist/esm/__time-gov.probe.mjs.map +0 -0
  8. package/dist/esm/brand/models/logo-creative-brief.schemas.d.ts.map +1 -1
  9. package/dist/esm/brand/models/logo-generation.actors-system.definitions.d.ts.map +1 -1
  10. package/dist/esm/brand/models/logo-judge.actors-system.definitions.d.ts.map +1 -1
  11. package/dist/esm/brand/models/logo-judge.actors-system.definitions.js.map +1 -1
  12. package/dist/esm/brand/models/logo-judge.schemas.d.ts.map +1 -1
  13. package/dist/esm/brand/services/brand-accept.companion.service.d.ts.map +1 -1
  14. package/dist/esm/brand/services/brand-accept.companion.service.js +24 -5
  15. package/dist/esm/brand/services/brand-accept.companion.service.js.map +1 -1
  16. package/dist/esm/brand/services/logo-deliberation.companion.service.d.ts +7 -0
  17. package/dist/esm/brand/services/logo-deliberation.companion.service.d.ts.map +1 -1
  18. package/dist/esm/brand/services/logo-deliberation.companion.service.js +7 -0
  19. package/dist/esm/brand/services/logo-deliberation.companion.service.js.map +1 -1
  20. package/dist/esm/brand/services/logo-generation.companion.service.d.ts.map +1 -1
  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.map +1 -1
  23. package/dist/esm/brand/utils/derived-brand-assets.js.map +1 -1
  24. package/dist/esm/brand/utils/stage-brand-candidate.d.ts.map +1 -1
  25. package/dist/esm/brand/utils/stage-brand-candidate.js.map +1 -1
  26. package/dist/esm/claude-cli/models/application-coding-run-checkpoint.models.d.ts +143 -0
  27. package/dist/esm/claude-cli/models/application-coding-run-checkpoint.models.d.ts.map +1 -0
  28. package/dist/esm/claude-cli/models/application-coding-run-checkpoint.models.js +84 -0
  29. package/dist/esm/claude-cli/models/application-coding-run-checkpoint.models.js.map +1 -0
  30. package/dist/esm/claude-cli/models/coding-agent-dispatch.models.d.ts +129 -16
  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 +173 -11
  33. package/dist/esm/claude-cli/models/coding-agent-dispatch.models.js.map +1 -1
  34. package/dist/esm/claude-cli/models/coding-session-frame-retention.d.ts +85 -0
  35. package/dist/esm/claude-cli/models/coding-session-frame-retention.d.ts.map +1 -0
  36. package/dist/esm/claude-cli/models/coding-session-frame-retention.js +122 -0
  37. package/dist/esm/claude-cli/models/coding-session-frame-retention.js.map +1 -0
  38. package/dist/esm/claude-cli/models/concurrent-coding-runs.models.d.ts +98 -0
  39. package/dist/esm/claude-cli/models/concurrent-coding-runs.models.d.ts.map +1 -0
  40. package/dist/esm/claude-cli/models/concurrent-coding-runs.models.js +135 -0
  41. package/dist/esm/claude-cli/models/concurrent-coding-runs.models.js.map +1 -0
  42. package/dist/esm/claude-cli/models/parked-question-answer.models.d.ts +94 -0
  43. package/dist/esm/claude-cli/models/parked-question-answer.models.d.ts.map +1 -0
  44. package/dist/esm/claude-cli/models/parked-question-answer.models.js +137 -0
  45. package/dist/esm/claude-cli/models/parked-question-answer.models.js.map +1 -0
  46. package/dist/esm/claude-cli/models/parked-question-answerer.actors-system.definitions.d.ts +16 -0
  47. package/dist/esm/claude-cli/models/parked-question-answerer.actors-system.definitions.d.ts.map +1 -0
  48. package/dist/esm/claude-cli/models/parked-question-answerer.actors-system.definitions.js +46 -0
  49. package/dist/esm/claude-cli/models/parked-question-answerer.actors-system.definitions.js.map +1 -0
  50. package/dist/esm/claude-cli/services/__tests__/support/in-memory-coding-actor-plane.d.ts +46 -0
  51. package/dist/esm/claude-cli/services/__tests__/support/in-memory-coding-actor-plane.d.ts.map +1 -0
  52. package/dist/esm/claude-cli/services/__tests__/support/in-memory-coding-actor-plane.js +135 -0
  53. package/dist/esm/claude-cli/services/__tests__/support/in-memory-coding-actor-plane.js.map +1 -0
  54. package/dist/esm/claude-cli/services/accepted-change-commit.companion.service.d.ts +131 -0
  55. package/dist/esm/claude-cli/services/accepted-change-commit.companion.service.d.ts.map +1 -0
  56. package/dist/esm/claude-cli/services/accepted-change-commit.companion.service.js +371 -0
  57. package/dist/esm/claude-cli/services/accepted-change-commit.companion.service.js.map +1 -0
  58. package/dist/esm/claude-cli/services/coding-agent-dispatch.companion.service.d.ts +679 -78
  59. package/dist/esm/claude-cli/services/coding-agent-dispatch.companion.service.d.ts.map +1 -1
  60. package/dist/esm/claude-cli/services/coding-agent-dispatch.companion.service.js +1909 -420
  61. package/dist/esm/claude-cli/services/coding-agent-dispatch.companion.service.js.map +1 -1
  62. package/dist/esm/claude-cli/services/coding-run-write-register.companion.service.d.ts +109 -0
  63. package/dist/esm/claude-cli/services/coding-run-write-register.companion.service.d.ts.map +1 -0
  64. package/dist/esm/claude-cli/services/coding-run-write-register.companion.service.js +186 -0
  65. package/dist/esm/claude-cli/services/coding-run-write-register.companion.service.js.map +1 -0
  66. package/dist/esm/claude-cli/services/git-change-set.companion.service.d.ts +215 -7
  67. package/dist/esm/claude-cli/services/git-change-set.companion.service.d.ts.map +1 -1
  68. package/dist/esm/claude-cli/services/git-change-set.companion.service.js +532 -60
  69. package/dist/esm/claude-cli/services/git-change-set.companion.service.js.map +1 -1
  70. package/dist/esm/claude-cli/services/research-agent-dispatch.companion.service.d.ts +27 -6
  71. package/dist/esm/claude-cli/services/research-agent-dispatch.companion.service.d.ts.map +1 -1
  72. package/dist/esm/claude-cli/services/research-agent-dispatch.companion.service.js +97 -6
  73. package/dist/esm/claude-cli/services/research-agent-dispatch.companion.service.js.map +1 -1
  74. package/dist/esm/claude-cli/services/research-evidence-store.companion.d.ts.map +1 -1
  75. package/dist/esm/claude-cli/services/research-evidence-store.companion.js.map +1 -1
  76. package/dist/esm/code-compliance-check/check-label-placeholder-contract.companion.d.ts.map +1 -1
  77. package/dist/esm/code-compliance-check/check-raw-feature-id-literals.companion.d.ts.map +1 -1
  78. package/dist/esm/code-compliance-check/check-raw-feature-id-literals.companion.js +8 -1
  79. package/dist/esm/code-compliance-check/check-raw-feature-id-literals.companion.js.map +1 -1
  80. package/dist/esm/companion-api/companion-api.schemas.d.ts +219 -142
  81. package/dist/esm/companion-api/companion-api.schemas.d.ts.map +1 -1
  82. package/dist/esm/companion-api/companion-api.schemas.js +52 -6
  83. package/dist/esm/companion-api/companion-api.schemas.js.map +1 -1
  84. package/dist/esm/companion-api/controllers/companion-i18n-api-contract.utils.d.ts.map +1 -1
  85. package/dist/esm/companion-api/controllers/companion-token-floor.policy.d.ts.map +1 -1
  86. package/dist/esm/companion-api/controllers/companion-token-floor.policy.js +14 -3
  87. package/dist/esm/companion-api/controllers/companion-token-floor.policy.js.map +1 -1
  88. package/dist/esm/companion-api/controllers/companion.controller.d.ts +170 -13
  89. package/dist/esm/companion-api/controllers/companion.controller.d.ts.map +1 -1
  90. package/dist/esm/companion-api/controllers/companion.controller.js +520 -87
  91. package/dist/esm/companion-api/controllers/companion.controller.js.map +1 -1
  92. package/dist/esm/core/auth/companion-auth-floor.companion.service.d.ts +39 -4
  93. package/dist/esm/core/auth/companion-auth-floor.companion.service.d.ts.map +1 -1
  94. package/dist/esm/core/auth/companion-auth-floor.companion.service.js +39 -4
  95. package/dist/esm/core/auth/companion-auth-floor.companion.service.js.map +1 -1
  96. package/dist/esm/core/catalogs/catalog-context.factory.d.ts.map +1 -1
  97. package/dist/esm/core/catalogs/catalog-context.factory.models.d.ts.map +1 -1
  98. package/dist/esm/core/catalogs/schema-org/aggregate-offer-catalog-context.factory.d.ts.map +1 -1
  99. package/dist/esm/core/catalogs/schema-org/aggregate-rating-catalog-context.factory.d.ts.map +1 -1
  100. package/dist/esm/core/catalogs/schema-org/article-catalog-context.factory.d.ts.map +1 -1
  101. package/dist/esm/core/catalogs/schema-org/blog-posting-catalog-context.factory.d.ts.map +1 -1
  102. package/dist/esm/core/catalogs/schema-org/breadcrumb-list-catalog-context.factory.d.ts.map +1 -1
  103. package/dist/esm/core/catalogs/schema-org/faq-page-catalog-context.factory.d.ts.map +1 -1
  104. package/dist/esm/core/catalogs/schema-org/offer-catalog-context.factory.d.ts.map +1 -1
  105. package/dist/esm/core/catalogs/schema-org/organization-catalog-context.factory.d.ts.map +1 -1
  106. package/dist/esm/core/catalogs/schema-org/product-catalog-context.factory.d.ts.map +1 -1
  107. package/dist/esm/core/catalogs/schema-org/review-catalog-context.factory.d.ts.map +1 -1
  108. package/dist/esm/core/catalogs/schema-org/schema-org-catalog-boundary.shared.d.ts.map +1 -1
  109. package/dist/esm/core/catalogs/schema-org/schema-org-catalog-boundary.shared.js.map +1 -1
  110. package/dist/esm/core/catalogs/schema-org/schema-org-catalog-context.shared.d.ts.map +1 -1
  111. package/dist/esm/core/catalogs/schema-org/schema-org-catalog-context.shared.js.map +1 -1
  112. package/dist/esm/core/catalogs/schema-org/software-application-catalog-context.factory.d.ts.map +1 -1
  113. package/dist/esm/core/catalogs/schema-org/website-catalog-context.factory.d.ts.map +1 -1
  114. package/dist/esm/core/catalogs/structured-data-catalog-audit.service.d.ts.map +1 -1
  115. package/dist/esm/core/catalogs/structured-data-catalog-audit.service.js.map +1 -1
  116. package/dist/esm/core/config/application-schema-plan-obligation.companion.utils.d.ts +54 -0
  117. package/dist/esm/core/config/application-schema-plan-obligation.companion.utils.d.ts.map +1 -0
  118. package/dist/esm/core/config/application-schema-plan-obligation.companion.utils.js +78 -0
  119. package/dist/esm/core/config/application-schema-plan-obligation.companion.utils.js.map +1 -0
  120. package/dist/esm/core/config/primary-language.companion.utils.d.ts +13 -0
  121. package/dist/esm/core/config/primary-language.companion.utils.d.ts.map +1 -1
  122. package/dist/esm/core/config/primary-language.companion.utils.js +12 -0
  123. package/dist/esm/core/config/primary-language.companion.utils.js.map +1 -1
  124. package/dist/esm/core/context/companion-context.d.ts.map +1 -1
  125. package/dist/esm/core/context/companion-context.js +4 -0
  126. package/dist/esm/core/context/companion-context.js.map +1 -1
  127. package/dist/esm/core/context/companion-package-loaders.companion.d.ts +57 -0
  128. package/dist/esm/core/context/companion-package-loaders.companion.d.ts.map +1 -1
  129. package/dist/esm/core/context/companion-package-loaders.companion.js +181 -7
  130. package/dist/esm/core/context/companion-package-loaders.companion.js.map +1 -1
  131. package/dist/esm/core/context/draft-family-values.companion.d.ts +23 -0
  132. package/dist/esm/core/context/draft-family-values.companion.d.ts.map +1 -0
  133. package/dist/esm/core/context/draft-family-values.companion.js +49 -0
  134. package/dist/esm/core/context/draft-family-values.companion.js.map +1 -0
  135. package/dist/esm/core/inject/models/container.d.ts.map +1 -1
  136. package/dist/esm/core/inject/models/container.js +28 -4
  137. package/dist/esm/core/inject/models/container.js.map +1 -1
  138. package/dist/esm/core/inject/models/service-types.d.ts +12 -2
  139. package/dist/esm/core/inject/models/service-types.d.ts.map +1 -1
  140. package/dist/esm/core/inject/models/service-types.js +14 -2
  141. package/dist/esm/core/inject/models/service-types.js.map +1 -1
  142. package/dist/esm/core/introspection/behaviors/companion-introspection-behavior-definitions.d.ts.map +1 -1
  143. package/dist/esm/core/introspection/behaviors/companion-introspection-behavior-definitions.js +74 -2
  144. package/dist/esm/core/introspection/behaviors/companion-introspection-behavior-definitions.js.map +1 -1
  145. package/dist/esm/core/introspection/models/companion-introspection.models.d.ts +37 -1
  146. package/dist/esm/core/introspection/models/companion-introspection.models.d.ts.map +1 -1
  147. package/dist/esm/core/introspection/models/companion-introspection.models.js +55 -0
  148. package/dist/esm/core/introspection/models/companion-introspection.models.js.map +1 -1
  149. package/dist/esm/core/introspection/resources/creation-home-projection.companion.d.ts +93 -0
  150. package/dist/esm/core/introspection/resources/creation-home-projection.companion.d.ts.map +1 -0
  151. package/dist/esm/core/introspection/resources/creation-home-projection.companion.js +290 -0
  152. package/dist/esm/core/introspection/resources/creation-home-projection.companion.js.map +1 -0
  153. package/dist/esm/core/introspection/resources/creation-plane-dispatch.custom-impl.companion.service.d.ts.map +1 -1
  154. package/dist/esm/core/introspection/resources/creation-plane-dispatch.custom-impl.companion.service.js +630 -16
  155. package/dist/esm/core/introspection/resources/creation-plane-dispatch.custom-impl.companion.service.js.map +1 -1
  156. package/dist/esm/core/introspection/resources/creation-plane-projection.companion.service.d.ts +592 -17
  157. package/dist/esm/core/introspection/resources/creation-plane-projection.companion.service.d.ts.map +1 -1
  158. package/dist/esm/core/introspection/resources/creation-plane-projection.companion.service.js +1417 -93
  159. package/dist/esm/core/introspection/resources/creation-plane-projection.companion.service.js.map +1 -1
  160. package/dist/esm/core/introspection/resources/introspection-resource-notifier.companion.service.d.ts +61 -4
  161. package/dist/esm/core/introspection/resources/introspection-resource-notifier.companion.service.d.ts.map +1 -1
  162. package/dist/esm/core/introspection/resources/introspection-resource-notifier.companion.service.js +136 -10
  163. package/dist/esm/core/introspection/resources/introspection-resource-notifier.companion.service.js.map +1 -1
  164. package/dist/esm/core/introspection/resources/introspection-resource-source.companion.service.d.ts.map +1 -1
  165. package/dist/esm/core/introspection/resources/introspection-resource-source.companion.service.js +11 -0
  166. package/dist/esm/core/introspection/resources/introspection-resource-source.companion.service.js.map +1 -1
  167. package/dist/esm/core/introspection/services/companion-introspection-behavior-registry.companion.service.d.ts.map +1 -1
  168. package/dist/esm/core/introspection/services/companion-introspection.companion.service.d.ts +21 -0
  169. package/dist/esm/core/introspection/services/companion-introspection.companion.service.d.ts.map +1 -1
  170. package/dist/esm/core/introspection/services/companion-introspection.companion.service.js +21 -3
  171. package/dist/esm/core/introspection/services/companion-introspection.companion.service.js.map +1 -1
  172. package/dist/esm/core/introspection/services/introspection-derivation-state.companion.service.d.ts.map +1 -1
  173. package/dist/esm/core/introspection/services/introspection-derivation-state.companion.service.js +11 -3
  174. package/dist/esm/core/introspection/services/introspection-derivation-state.companion.service.js.map +1 -1
  175. package/dist/esm/core/introspection/services/introspection-source-state.companion.service.d.ts +15 -5
  176. package/dist/esm/core/introspection/services/introspection-source-state.companion.service.d.ts.map +1 -1
  177. package/dist/esm/core/introspection/services/introspection-source-state.companion.service.js +28 -15
  178. package/dist/esm/core/introspection/services/introspection-source-state.companion.service.js.map +1 -1
  179. package/dist/esm/core/introspection/services/introspection-source-watcher.companion.service.d.ts +24 -0
  180. package/dist/esm/core/introspection/services/introspection-source-watcher.companion.service.d.ts.map +1 -1
  181. package/dist/esm/core/introspection/services/introspection-source-watcher.companion.service.js +29 -5
  182. package/dist/esm/core/introspection/services/introspection-source-watcher.companion.service.js.map +1 -1
  183. package/dist/esm/core/introspection/services/translation-placement.companion.service.d.ts.map +1 -1
  184. package/dist/esm/core/introspection/subprocess/app-shell-placement-content.behavior.d.ts +116 -0
  185. package/dist/esm/core/introspection/subprocess/app-shell-placement-content.behavior.d.ts.map +1 -0
  186. package/dist/esm/core/introspection/subprocess/app-shell-placement-content.behavior.js +223 -0
  187. package/dist/esm/core/introspection/subprocess/app-shell-placement-content.behavior.js.map +1 -0
  188. package/dist/esm/core/introspection/subprocess/application-domain-model.behavior.d.ts +9 -6
  189. package/dist/esm/core/introspection/subprocess/application-domain-model.behavior.d.ts.map +1 -1
  190. package/dist/esm/core/introspection/subprocess/application-domain-model.behavior.js.map +1 -1
  191. package/dist/esm/core/introspection/subprocess/assertions.behavior.d.ts +2 -1
  192. package/dist/esm/core/introspection/subprocess/assertions.behavior.d.ts.map +1 -1
  193. package/dist/esm/core/introspection/subprocess/assertions.behavior.js.map +1 -1
  194. package/dist/esm/core/introspection/subprocess/asset-noop-hooks.d.ts.map +1 -1
  195. package/dist/esm/core/introspection/subprocess/asset-noop-register.d.ts.map +1 -1
  196. package/dist/esm/core/introspection/subprocess/brand-prompt-renderer.d.ts.map +1 -1
  197. package/dist/esm/core/introspection/subprocess/chart-registration-refs.behavior.d.ts.map +1 -1
  198. package/dist/esm/core/introspection/subprocess/companion-introspection-behavior-handlers.d.ts.map +1 -1
  199. package/dist/esm/core/introspection/subprocess/companion-introspection-behavior-handlers.js +82 -49
  200. package/dist/esm/core/introspection/subprocess/companion-introspection-behavior-handlers.js.map +1 -1
  201. package/dist/esm/core/introspection/subprocess/companion-introspection-child.d.ts.map +1 -1
  202. package/dist/esm/core/introspection/subprocess/companion-introspection-module-exports.utils.d.ts.map +1 -1
  203. package/dist/esm/core/introspection/subprocess/compliance-primary-facts.behavior.d.ts.map +1 -1
  204. package/dist/esm/core/introspection/subprocess/compliance-primary-facts.behavior.js.map +1 -1
  205. package/dist/esm/core/introspection/subprocess/definition-specifications.behavior.d.ts.map +1 -1
  206. package/dist/esm/core/introspection/subprocess/engine-resource-population.subprocess.utils.d.ts +33 -0
  207. package/dist/esm/core/introspection/subprocess/engine-resource-population.subprocess.utils.d.ts.map +1 -0
  208. package/dist/esm/core/introspection/subprocess/engine-resource-population.subprocess.utils.js +59 -0
  209. package/dist/esm/core/introspection/subprocess/engine-resource-population.subprocess.utils.js.map +1 -0
  210. package/dist/esm/core/introspection/subprocess/expert-persona-brief.renderer.d.ts.map +1 -1
  211. package/dist/esm/core/introspection/subprocess/family-aspects.behavior.d.ts +33 -0
  212. package/dist/esm/core/introspection/subprocess/family-aspects.behavior.d.ts.map +1 -1
  213. package/dist/esm/core/introspection/subprocess/family-aspects.behavior.head-parity.tmp.d.ts +0 -0
  214. package/dist/esm/core/introspection/subprocess/family-aspects.behavior.head-parity.tmp.d.ts.map +0 -0
  215. package/dist/esm/core/introspection/subprocess/family-aspects.behavior.head-parity.tmp.js.map +0 -0
  216. package/dist/esm/core/introspection/subprocess/family-aspects.behavior.js +46 -140
  217. package/dist/esm/core/introspection/subprocess/family-aspects.behavior.js.map +1 -1
  218. package/dist/esm/core/introspection/subprocess/frontend-labels-needed-info.behavior.d.ts +15 -0
  219. package/dist/esm/core/introspection/subprocess/frontend-labels-needed-info.behavior.d.ts.map +1 -1
  220. package/dist/esm/core/introspection/subprocess/frontend-labels-needed-info.behavior.js +140 -46
  221. package/dist/esm/core/introspection/subprocess/frontend-labels-needed-info.behavior.js.map +1 -1
  222. package/dist/esm/core/introspection/subprocess/market-context-block.builder.d.ts.map +1 -1
  223. package/dist/esm/core/introspection/subprocess/market-prompt-renderer.d.ts.map +1 -1
  224. package/dist/esm/core/introspection/subprocess/openapi-generation-input.behavior.d.ts +24 -0
  225. package/dist/esm/core/introspection/subprocess/openapi-generation-input.behavior.d.ts.map +1 -1
  226. package/dist/esm/core/introspection/subprocess/openapi-generation-input.behavior.js +116 -10
  227. package/dist/esm/core/introspection/subprocess/openapi-generation-input.behavior.js.map +1 -1
  228. package/dist/esm/core/introspection/subprocess/risk-signals.behavior.d.ts +79 -0
  229. package/dist/esm/core/introspection/subprocess/risk-signals.behavior.d.ts.map +1 -0
  230. package/dist/esm/core/introspection/subprocess/risk-signals.behavior.js +49 -0
  231. package/dist/esm/core/introspection/subprocess/risk-signals.behavior.js.map +1 -0
  232. package/dist/esm/core/introspection/subprocess/specification-artifacts.behavior.d.ts.map +1 -1
  233. package/dist/esm/core/introspection/subprocess/specification-artifacts.behavior.js +314 -212
  234. package/dist/esm/core/introspection/subprocess/specification-artifacts.behavior.js.map +1 -1
  235. package/dist/esm/core/introspection/subprocess/specification-elements.behavior.d.ts +72 -0
  236. package/dist/esm/core/introspection/subprocess/specification-elements.behavior.d.ts.map +1 -0
  237. package/dist/esm/core/introspection/subprocess/specification-elements.behavior.js +123 -0
  238. package/dist/esm/core/introspection/subprocess/specification-elements.behavior.js.map +1 -0
  239. package/dist/esm/core/introspection/workspace-element-index.companion.d.ts +184 -0
  240. package/dist/esm/core/introspection/workspace-element-index.companion.d.ts.map +1 -0
  241. package/dist/esm/core/introspection/workspace-element-index.companion.js +311 -0
  242. package/dist/esm/core/introspection/workspace-element-index.companion.js.map +1 -0
  243. package/dist/esm/core/introspection/workspace-elements.companion.d.ts +54 -0
  244. package/dist/esm/core/introspection/workspace-elements.companion.d.ts.map +1 -0
  245. package/dist/esm/core/introspection/workspace-elements.companion.js +43 -0
  246. package/dist/esm/core/introspection/workspace-elements.companion.js.map +1 -0
  247. package/dist/esm/core/lock/wildo-saas-lock.companion.service.d.ts.map +1 -1
  248. package/dist/esm/core/lock/wildo-saas-lock.companion.service.js.map +1 -1
  249. package/dist/esm/core/lock/wildo-saas-lock.models.d.ts +7 -0
  250. package/dist/esm/core/lock/wildo-saas-lock.models.d.ts.map +1 -1
  251. package/dist/esm/core/lock/wildo-saas-lock.models.js.map +1 -1
  252. package/dist/esm/core/lock/wildo-saas-lock.schemas.d.ts +7 -4
  253. package/dist/esm/core/lock/wildo-saas-lock.schemas.d.ts.map +1 -1
  254. package/dist/esm/core/lock/wildo-saas-lock.schemas.js +1 -0
  255. package/dist/esm/core/lock/wildo-saas-lock.schemas.js.map +1 -1
  256. package/dist/esm/core/runtime/application-runtime-liveness.companion.d.ts +31 -0
  257. package/dist/esm/core/runtime/application-runtime-liveness.companion.d.ts.map +1 -0
  258. package/dist/esm/core/runtime/application-runtime-liveness.companion.js +53 -0
  259. package/dist/esm/core/runtime/application-runtime-liveness.companion.js.map +1 -0
  260. package/dist/esm/core/runtime/companion-startup-assembly.d.ts.map +1 -1
  261. package/dist/esm/core/runtime/companion-startup-assembly.js +30 -1
  262. package/dist/esm/core/runtime/companion-startup-assembly.js.map +1 -1
  263. package/dist/esm/core/runtime/dev-compile-quiet.companion.d.ts.map +1 -1
  264. package/dist/esm/core/runtime/models/companion-runtime.models.d.ts.map +1 -1
  265. package/dist/esm/core/runtime/services/file-storage-initialization.companion.d.ts +54 -0
  266. package/dist/esm/core/runtime/services/file-storage-initialization.companion.d.ts.map +1 -0
  267. package/dist/esm/core/runtime/services/file-storage-initialization.companion.js +54 -0
  268. package/dist/esm/core/runtime/services/file-storage-initialization.companion.js.map +1 -0
  269. package/dist/esm/core/runtime/services/start-companion-application.service.d.ts +11 -2
  270. package/dist/esm/core/runtime/services/start-companion-application.service.d.ts.map +1 -1
  271. package/dist/esm/core/runtime/services/start-companion-application.service.js +182 -31
  272. package/dist/esm/core/runtime/services/start-companion-application.service.js.map +1 -1
  273. package/dist/esm/core/runtime/utils/companion-local-signing-key.companion.d.ts.map +1 -1
  274. package/dist/esm/core/runtime/utils/companion-platform-config.companion.d.ts +3 -3
  275. package/dist/esm/core/runtime/utils/companion-platform-config.companion.d.ts.map +1 -1
  276. package/dist/esm/core/runtime/utils/companion-platform-config.companion.js +27 -9
  277. package/dist/esm/core/runtime/utils/companion-platform-config.companion.js.map +1 -1
  278. package/dist/esm/core/runtime/utils/companion-workbench-topology.d.ts.map +1 -1
  279. package/dist/esm/core/runtime/utils/platform-core-domain-modules.companion.d.ts.map +1 -1
  280. package/dist/esm/core/specifications/chart-view-specification-context.factory.d.ts.map +1 -1
  281. package/dist/esm/core/specifications/composite-view-specification-context.factory.d.ts.map +1 -1
  282. package/dist/esm/core/specifications/cross-registry-rendering.shared.d.ts +0 -4
  283. package/dist/esm/core/specifications/cross-registry-rendering.shared.d.ts.map +1 -1
  284. package/dist/esm/core/specifications/cross-registry-rendering.shared.js +0 -4
  285. package/dist/esm/core/specifications/cross-registry-rendering.shared.js.map +1 -1
  286. package/dist/esm/core/specifications/execution-view-specification-context.factory.d.ts.map +1 -1
  287. package/dist/esm/core/specifications/feature-specification-context.factory.d.ts.map +1 -1
  288. package/dist/esm/core/specifications/flows-actors-view-specification-context.factory.d.ts.map +1 -1
  289. package/dist/esm/core/specifications/frontend-component-specification-context.factory.d.ts.map +1 -1
  290. package/dist/esm/core/specifications/full-custom-view-specification-context.factory.d.ts.map +1 -1
  291. package/dist/esm/core/specifications/guidance-flow-specification-context.factory.d.ts.map +1 -1
  292. package/dist/esm/core/specifications/guidance-flow-specification-context.factory.js.map +1 -1
  293. package/dist/esm/core/specifications/milestone-specification-context.factory.d.ts.map +1 -1
  294. package/dist/esm/core/specifications/non-composite-view-specification-context.shared.d.ts.map +1 -1
  295. package/dist/esm/core/specifications/onboarding-element-rendering.shared.d.ts.map +1 -1
  296. package/dist/esm/core/specifications/onboarding-element-rendering.shared.js +6 -34
  297. package/dist/esm/core/specifications/onboarding-element-rendering.shared.js.map +1 -1
  298. package/dist/esm/core/specifications/onboarding-view-specification-context.factory.d.ts.map +1 -1
  299. package/dist/esm/core/specifications/onboarding-view-specification-context.factory.js.map +1 -1
  300. package/dist/esm/core/specifications/product-specification-context.factory.d.ts.map +1 -1
  301. package/dist/esm/core/specifications/resource-specification-context.factory.d.ts.map +1 -1
  302. package/dist/esm/core/specifications/resource-specification-context.factory.js +2 -0
  303. package/dist/esm/core/specifications/resource-specification-context.factory.js.map +1 -1
  304. package/dist/esm/core/specifications/role-specification-context.factory.d.ts.map +1 -1
  305. package/dist/esm/core/specifications/specification-context-factory.d.ts.map +1 -1
  306. package/dist/esm/core/specifications/specification-context-factory.models.d.ts.map +1 -1
  307. package/dist/esm/core/specifications/specification-context-factory.shared.d.ts.map +1 -1
  308. package/dist/esm/core/specifications/system-email-template-specification-context.factory.d.ts.map +1 -1
  309. package/dist/esm/core/specifications/templates/composite-view/composite-view-all-information.template.d.ts.map +1 -1
  310. package/dist/esm/core/specifications/templates/composite-view/composite-view-custom-implementation-context.template.d.ts.map +1 -1
  311. package/dist/esm/core/specifications/templates/composite-view/composite-view-development-usage-context.template.d.ts.map +1 -1
  312. package/dist/esm/core/specifications/templates/composite-view/composite-view-translation-context.template.d.ts.map +1 -1
  313. package/dist/esm/core/specifications/templates/feature/feature-all-information.template.d.ts.map +1 -1
  314. package/dist/esm/core/specifications/templates/feature/feature-custom-implementation-context.template.d.ts.map +1 -1
  315. package/dist/esm/core/specifications/templates/feature/feature-development-usage-context.template.d.ts.map +1 -1
  316. package/dist/esm/core/specifications/templates/feature/feature-translation-context.template.d.ts.map +1 -1
  317. package/dist/esm/core/specifications/templates/frontend-component/frontend-component-all-information.template.d.ts.map +1 -1
  318. package/dist/esm/core/specifications/templates/frontend-component/frontend-component-custom-implementation-context.template.d.ts.map +1 -1
  319. package/dist/esm/core/specifications/templates/frontend-component/frontend-component-development-usage-context.template.d.ts.map +1 -1
  320. package/dist/esm/core/specifications/templates/frontend-component/frontend-component-translation-context.template.d.ts.map +1 -1
  321. package/dist/esm/core/specifications/templates/guidance-flow-specification/guidance-flow-all-information.template.d.ts.map +1 -1
  322. package/dist/esm/core/specifications/templates/guidance-flow-specification/guidance-flow-custom-implementation-context.template.d.ts.map +1 -1
  323. package/dist/esm/core/specifications/templates/guidance-flow-specification/guidance-flow-development-usage-context.template.d.ts.map +1 -1
  324. package/dist/esm/core/specifications/templates/guidance-flow-specification/guidance-flow-translation-context.template.d.ts.map +1 -1
  325. package/dist/esm/core/specifications/templates/milestone/milestone-all-information.template.d.ts.map +1 -1
  326. package/dist/esm/core/specifications/templates/milestone/milestone-custom-implementation-context.template.d.ts.map +1 -1
  327. package/dist/esm/core/specifications/templates/milestone/milestone-development-usage-context.template.d.ts.map +1 -1
  328. package/dist/esm/core/specifications/templates/milestone/milestone-translation-context.template.d.ts.map +1 -1
  329. package/dist/esm/core/specifications/templates/non-composite-view/non-composite-view-all-information.template.d.ts.map +1 -1
  330. package/dist/esm/core/specifications/templates/non-composite-view/non-composite-view-custom-implementation-context.template.d.ts.map +1 -1
  331. package/dist/esm/core/specifications/templates/non-composite-view/non-composite-view-development-usage-context.template.d.ts.map +1 -1
  332. package/dist/esm/core/specifications/templates/non-composite-view/non-composite-view-translation-context.template.d.ts.map +1 -1
  333. package/dist/esm/core/specifications/templates/onboarding-view-specification/onboarding-view-all-information.template.d.ts.map +1 -1
  334. package/dist/esm/core/specifications/templates/onboarding-view-specification/onboarding-view-custom-implementation-context.template.d.ts.map +1 -1
  335. package/dist/esm/core/specifications/templates/onboarding-view-specification/onboarding-view-development-usage-context.template.d.ts.map +1 -1
  336. package/dist/esm/core/specifications/templates/onboarding-view-specification/onboarding-view-translation-context.template.d.ts.map +1 -1
  337. package/dist/esm/core/specifications/templates/product/product-all-information.template.d.ts.map +1 -1
  338. package/dist/esm/core/specifications/templates/product/product-custom-implementation-context.template.d.ts.map +1 -1
  339. package/dist/esm/core/specifications/templates/product/product-development-usage-context.template.d.ts.map +1 -1
  340. package/dist/esm/core/specifications/templates/product/product-translation-context.template.d.ts.map +1 -1
  341. package/dist/esm/core/specifications/templates/resource/resource-all-information.template.d.ts.map +1 -1
  342. package/dist/esm/core/specifications/templates/resource/resource-custom-implementation-context.template.d.ts.map +1 -1
  343. package/dist/esm/core/specifications/templates/resource/resource-development-usage-context.template.d.ts.map +1 -1
  344. package/dist/esm/core/specifications/templates/resource/resource-translation-context.template.d.ts.map +1 -1
  345. package/dist/esm/core/specifications/templates/role/role-all-information.template.d.ts.map +1 -1
  346. package/dist/esm/core/specifications/templates/role/role-custom-implementation-context.template.d.ts.map +1 -1
  347. package/dist/esm/core/specifications/templates/role/role-development-usage-context.template.d.ts.map +1 -1
  348. package/dist/esm/core/specifications/templates/role/role-translation-context.template.d.ts.map +1 -1
  349. package/dist/esm/core/specifications/templates/system-email-template/system-email-template-all-information.template.d.ts.map +1 -1
  350. package/dist/esm/core/specifications/templates/system-email-template/system-email-template-custom-implementation-context.template.d.ts.map +1 -1
  351. package/dist/esm/core/specifications/templates/system-email-template/system-email-template-development-usage-context.template.d.ts.map +1 -1
  352. package/dist/esm/core/specifications/templates/system-email-template/system-email-template-translation-context.template.d.ts.map +1 -1
  353. package/dist/esm/core/specifications/validate-resource-field-completeness.d.ts.map +1 -1
  354. package/dist/esm/core/traceability/companion-agent-call-trace-sink.companion.service.d.ts +4 -2
  355. package/dist/esm/core/traceability/companion-agent-call-trace-sink.companion.service.d.ts.map +1 -1
  356. package/dist/esm/core/traceability/companion-agent-call-trace-sink.companion.service.js +12 -2
  357. package/dist/esm/core/traceability/companion-agent-call-trace-sink.companion.service.js.map +1 -1
  358. package/dist/esm/core/traceability/companion-traceability.models.d.ts.map +1 -1
  359. package/dist/esm/core/traceability/companion-traceability.service.d.ts +21 -1
  360. package/dist/esm/core/traceability/companion-traceability.service.d.ts.map +1 -1
  361. package/dist/esm/core/traceability/companion-traceability.service.js +25 -1
  362. package/dist/esm/core/traceability/companion-traceability.service.js.map +1 -1
  363. package/dist/esm/core/utils/atomic-write.utils.d.ts.map +1 -1
  364. package/dist/esm/core/utils/derived-input-signature.companion.utils.d.ts +45 -0
  365. package/dist/esm/core/utils/derived-input-signature.companion.utils.d.ts.map +1 -0
  366. package/dist/esm/core/utils/derived-input-signature.companion.utils.js +96 -0
  367. package/dist/esm/core/utils/derived-input-signature.companion.utils.js.map +1 -0
  368. package/dist/esm/creation-conversation/creation-conversation.actors-system.definitions.d.ts +35 -0
  369. package/dist/esm/creation-conversation/creation-conversation.actors-system.definitions.d.ts.map +1 -0
  370. package/dist/esm/creation-conversation/creation-conversation.actors-system.definitions.js +118 -0
  371. package/dist/esm/creation-conversation/creation-conversation.actors-system.definitions.js.map +1 -0
  372. package/dist/esm/creation-conversation/creation-conversation.function-tools.d.ts +34 -0
  373. package/dist/esm/creation-conversation/creation-conversation.function-tools.d.ts.map +1 -0
  374. package/dist/esm/creation-conversation/creation-conversation.function-tools.js +280 -0
  375. package/dist/esm/creation-conversation/creation-conversation.function-tools.js.map +1 -0
  376. package/dist/esm/deliberations/models/deliberation-agents.actors-system.definitions.d.ts.map +1 -1
  377. package/dist/esm/deliberations/models/deliberation-agents.actors-system.definitions.js.map +1 -1
  378. package/dist/esm/deliberations/services/deliberation.companion.service.d.ts +19 -1
  379. package/dist/esm/deliberations/services/deliberation.companion.service.d.ts.map +1 -1
  380. package/dist/esm/deliberations/services/deliberation.companion.service.js +61 -5
  381. package/dist/esm/deliberations/services/deliberation.companion.service.js.map +1 -1
  382. package/dist/esm/deliberations/services/structured-deliberation.companion.service.d.ts +3 -1
  383. package/dist/esm/deliberations/services/structured-deliberation.companion.service.d.ts.map +1 -1
  384. package/dist/esm/deliberations/services/structured-deliberation.companion.service.js +7 -2
  385. package/dist/esm/deliberations/services/structured-deliberation.companion.service.js.map +1 -1
  386. package/dist/esm/deliberations/utils/load-committed-expert-agents.d.ts.map +1 -1
  387. package/dist/esm/email/models/email-template.actors-system.definitions.d.ts.map +1 -1
  388. package/dist/esm/email/models/email-template.actors-system.definitions.js.map +1 -1
  389. package/dist/esm/email/services/email-spec-context-loader.companion.service.d.ts.map +1 -1
  390. package/dist/esm/email/services/email-spec-context-loader.companion.service.js.map +1 -1
  391. package/dist/esm/email/services/email-template.companion.service.d.ts +30 -0
  392. package/dist/esm/email/services/email-template.companion.service.d.ts.map +1 -1
  393. package/dist/esm/email/services/email-template.companion.service.js +92 -41
  394. package/dist/esm/email/services/email-template.companion.service.js.map +1 -1
  395. package/dist/esm/email/utils/email-labels-file-source.utils.d.ts.map +1 -1
  396. package/dist/esm/email/utils/email-template-fs-discovery.utils.d.ts.map +1 -1
  397. package/dist/esm/executions/services/companion-actor-execution-persistence.adapter.d.ts +34 -0
  398. package/dist/esm/executions/services/companion-actor-execution-persistence.adapter.d.ts.map +1 -0
  399. package/dist/esm/executions/services/companion-actor-execution-persistence.adapter.js +130 -0
  400. package/dist/esm/executions/services/companion-actor-execution-persistence.adapter.js.map +1 -0
  401. package/dist/esm/executions/services/companion-executions.companion.service.d.ts +36 -3
  402. package/dist/esm/executions/services/companion-executions.companion.service.d.ts.map +1 -1
  403. package/dist/esm/executions/services/companion-executions.companion.service.js +136 -5
  404. package/dist/esm/executions/services/companion-executions.companion.service.js.map +1 -1
  405. package/dist/esm/expert-personas/models/expert-persona-critique.actors-system.definitions.d.ts.map +1 -1
  406. package/dist/esm/expert-personas/models/expert-persona-critique.actors-system.definitions.js.map +1 -1
  407. package/dist/esm/expert-personas/models/expert-persona-derivation.actors-system.definitions.d.ts.map +1 -1
  408. package/dist/esm/expert-personas/models/expert-persona-derivation.actors-system.definitions.js.map +1 -1
  409. package/dist/esm/expert-personas/models/expert-persona-derivation.schemas.d.ts.map +1 -1
  410. package/dist/esm/expert-personas/services/expert-persona.companion.service.d.ts +5 -0
  411. package/dist/esm/expert-personas/services/expert-persona.companion.service.d.ts.map +1 -1
  412. package/dist/esm/expert-personas/services/expert-persona.companion.service.js +58 -8
  413. package/dist/esm/expert-personas/services/expert-persona.companion.service.js.map +1 -1
  414. package/dist/esm/expert-personas/services/persona-source-ownership.d.ts +8 -0
  415. package/dist/esm/expert-personas/services/persona-source-ownership.d.ts.map +1 -0
  416. package/dist/esm/expert-personas/services/persona-source-ownership.js +83 -0
  417. package/dist/esm/expert-personas/services/persona-source-ownership.js.map +1 -0
  418. package/dist/esm/i18n/components/APPLICATION_LEVEL_ACTIVITY_BAR.en.d.ts +1 -1
  419. package/dist/esm/i18n/components/APPLICATION_LEVEL_ACTIVITY_BAR.en.d.ts.map +1 -1
  420. package/dist/esm/i18n/components/APPLICATION_LEVEL_ACTIVITY_BAR.en.js +1 -1
  421. package/dist/esm/i18n/components/APPLICATION_LEVEL_ACTIVITY_BAR.en.js.map +1 -1
  422. package/dist/esm/i18n/components/APPLICATION_LEVEL_COMMAND_MENU.en.d.ts +4 -4
  423. package/dist/esm/i18n/components/APPLICATION_LEVEL_COMMAND_MENU.en.d.ts.map +1 -1
  424. package/dist/esm/i18n/components/APPLICATION_LEVEL_COMMAND_MENU.en.js +4 -4
  425. package/dist/esm/i18n/components/APPLICATION_LEVEL_COMMAND_MENU.en.js.map +1 -1
  426. package/dist/esm/i18n/components/APPLICATION_LEVEL_CONTROL_PANEL.en.d.ts +2 -2
  427. package/dist/esm/i18n/components/APPLICATION_LEVEL_CONTROL_PANEL.en.d.ts.map +1 -1
  428. package/dist/esm/i18n/components/APPLICATION_LEVEL_CONTROL_PANEL.en.js +2 -2
  429. package/dist/esm/i18n/components/APPLICATION_LEVEL_CONTROL_PANEL.en.js.map +1 -1
  430. package/dist/esm/i18n/components/APPLICATION_LEVEL_MENUBAR.en.d.ts.map +1 -1
  431. package/dist/esm/i18n/components/APPLICATION_LEVEL_NAVIGATION_BACK.en.d.ts.map +1 -1
  432. package/dist/esm/i18n/components/APPLICATION_LEVEL_NOTIFICATION_CENTER.en.d.ts +4 -2
  433. package/dist/esm/i18n/components/APPLICATION_LEVEL_NOTIFICATION_CENTER.en.d.ts.map +1 -1
  434. package/dist/esm/i18n/components/APPLICATION_LEVEL_NOTIFICATION_CENTER.en.js +5 -3
  435. package/dist/esm/i18n/components/APPLICATION_LEVEL_NOTIFICATION_CENTER.en.js.map +1 -1
  436. package/dist/esm/i18n/components/APPLICATION_LEVEL_QUICK_ACTION_BUTTON.en.d.ts +2 -1
  437. package/dist/esm/i18n/components/APPLICATION_LEVEL_QUICK_ACTION_BUTTON.en.d.ts.map +1 -1
  438. package/dist/esm/i18n/components/APPLICATION_LEVEL_QUICK_ACTION_BUTTON.en.js +2 -1
  439. package/dist/esm/i18n/components/APPLICATION_LEVEL_QUICK_ACTION_BUTTON.en.js.map +1 -1
  440. package/dist/esm/i18n/components/APPLICATION_LEVEL_QUICK_SWITCHER.en.d.ts +1 -1
  441. package/dist/esm/i18n/components/APPLICATION_LEVEL_QUICK_SWITCHER.en.d.ts.map +1 -1
  442. package/dist/esm/i18n/components/APPLICATION_LEVEL_QUICK_SWITCHER.en.js +1 -1
  443. package/dist/esm/i18n/components/APPLICATION_LEVEL_QUICK_SWITCHER.en.js.map +1 -1
  444. package/dist/esm/i18n/components/APPLICATION_LEVEL_SIDEBAR.en.d.ts +6 -5
  445. package/dist/esm/i18n/components/APPLICATION_LEVEL_SIDEBAR.en.d.ts.map +1 -1
  446. package/dist/esm/i18n/components/APPLICATION_LEVEL_SIDEBAR.en.js +7 -6
  447. package/dist/esm/i18n/components/APPLICATION_LEVEL_SIDEBAR.en.js.map +1 -1
  448. package/dist/esm/i18n/components/APPLICATION_LEVEL_STATUS_BAR.en.d.ts +3 -3
  449. package/dist/esm/i18n/components/APPLICATION_LEVEL_STATUS_BAR.en.d.ts.map +1 -1
  450. package/dist/esm/i18n/components/APPLICATION_LEVEL_STATUS_BAR.en.js +3 -3
  451. package/dist/esm/i18n/components/APPLICATION_LEVEL_STATUS_BAR.en.js.map +1 -1
  452. package/dist/esm/i18n/components/APPLICATION_LEVEL_TOOLBAR.en.d.ts.map +1 -1
  453. package/dist/esm/i18n/components/APPLICATION_LEVEL_USER_DROPDOWN.en.d.ts +2 -2
  454. package/dist/esm/i18n/components/APPLICATION_LEVEL_USER_DROPDOWN.en.d.ts.map +1 -1
  455. package/dist/esm/i18n/components/APPLICATION_LEVEL_USER_DROPDOWN.en.js +2 -2
  456. package/dist/esm/i18n/components/APPLICATION_LEVEL_USER_DROPDOWN.en.js.map +1 -1
  457. package/dist/esm/i18n/components/APPLICATION_LEVEL_UTILITY_PANEL.en.d.ts +2 -1
  458. package/dist/esm/i18n/components/APPLICATION_LEVEL_UTILITY_PANEL.en.d.ts.map +1 -1
  459. package/dist/esm/i18n/components/APPLICATION_LEVEL_UTILITY_PANEL.en.js +2 -1
  460. package/dist/esm/i18n/components/APPLICATION_LEVEL_UTILITY_PANEL.en.js.map +1 -1
  461. package/dist/esm/i18n/components/APP_LAYOUTS_APPEARANCE_SETTINGS.en.d.ts +1 -1
  462. package/dist/esm/i18n/components/APP_LAYOUTS_APPEARANCE_SETTINGS.en.d.ts.map +1 -1
  463. package/dist/esm/i18n/components/APP_LAYOUTS_APPEARANCE_SETTINGS.en.js +1 -1
  464. package/dist/esm/i18n/components/APP_LAYOUTS_APPEARANCE_SETTINGS.en.js.map +1 -1
  465. package/dist/esm/i18n/components/APP_LAYOUTS_BILLING_SETTINGS.en.d.ts +1 -1
  466. package/dist/esm/i18n/components/APP_LAYOUTS_BILLING_SETTINGS.en.d.ts.map +1 -1
  467. package/dist/esm/i18n/components/APP_LAYOUTS_BILLING_SETTINGS.en.js +1 -1
  468. package/dist/esm/i18n/components/APP_LAYOUTS_BILLING_SETTINGS.en.js.map +1 -1
  469. package/dist/esm/i18n/components/APP_LAYOUTS_CONNECTED_ACCOUNTS_SETTINGS.en.d.ts +43 -0
  470. package/dist/esm/i18n/components/APP_LAYOUTS_CONNECTED_ACCOUNTS_SETTINGS.en.d.ts.map +1 -0
  471. package/dist/esm/i18n/components/APP_LAYOUTS_CONNECTED_ACCOUNTS_SETTINGS.en.js +43 -0
  472. package/dist/esm/i18n/components/APP_LAYOUTS_CONNECTED_ACCOUNTS_SETTINGS.en.js.map +1 -0
  473. package/dist/esm/i18n/components/APP_LAYOUTS_CONSENT_GATE.en.d.ts +26 -0
  474. package/dist/esm/i18n/components/APP_LAYOUTS_CONSENT_GATE.en.d.ts.map +1 -0
  475. package/dist/esm/i18n/components/APP_LAYOUTS_CONSENT_GATE.en.js +26 -0
  476. package/dist/esm/i18n/components/APP_LAYOUTS_CONSENT_GATE.en.js.map +1 -0
  477. package/dist/esm/i18n/components/APP_LAYOUTS_DOCUMENT_ACCEPTANCE_GATE.en.d.ts +18 -0
  478. package/dist/esm/i18n/components/APP_LAYOUTS_DOCUMENT_ACCEPTANCE_GATE.en.d.ts.map +1 -0
  479. package/dist/esm/i18n/components/APP_LAYOUTS_DOCUMENT_ACCEPTANCE_GATE.en.js +18 -0
  480. package/dist/esm/i18n/components/APP_LAYOUTS_DOCUMENT_ACCEPTANCE_GATE.en.js.map +1 -0
  481. package/dist/esm/i18n/components/APP_LAYOUTS_ERROR_BOUNDARY.en.d.ts +3 -3
  482. package/dist/esm/i18n/components/APP_LAYOUTS_ERROR_BOUNDARY.en.d.ts.map +1 -1
  483. package/dist/esm/i18n/components/APP_LAYOUTS_ERROR_BOUNDARY.en.js +3 -3
  484. package/dist/esm/i18n/components/APP_LAYOUTS_ERROR_BOUNDARY.en.js.map +1 -1
  485. package/dist/esm/i18n/components/APP_LAYOUTS_HOME.en.d.ts +1 -1
  486. package/dist/esm/i18n/components/APP_LAYOUTS_HOME.en.d.ts.map +1 -1
  487. package/dist/esm/i18n/components/APP_LAYOUTS_HOME.en.js +1 -1
  488. package/dist/esm/i18n/components/APP_LAYOUTS_HOME.en.js.map +1 -1
  489. package/dist/esm/i18n/components/APP_LAYOUTS_INVITATIONS_SETTINGS.en.d.ts +2 -2
  490. package/dist/esm/i18n/components/APP_LAYOUTS_INVITATIONS_SETTINGS.en.d.ts.map +1 -1
  491. package/dist/esm/i18n/components/APP_LAYOUTS_INVITATIONS_SETTINGS.en.js +2 -2
  492. package/dist/esm/i18n/components/APP_LAYOUTS_INVITATIONS_SETTINGS.en.js.map +1 -1
  493. package/dist/esm/i18n/components/APP_LAYOUTS_MAIN_CONTAINER.en.d.ts +4 -1
  494. package/dist/esm/i18n/components/APP_LAYOUTS_MAIN_CONTAINER.en.d.ts.map +1 -1
  495. package/dist/esm/i18n/components/APP_LAYOUTS_MAIN_CONTAINER.en.js +4 -1
  496. package/dist/esm/i18n/components/APP_LAYOUTS_MAIN_CONTAINER.en.js.map +1 -1
  497. package/dist/esm/i18n/components/APP_LAYOUTS_ROUTER_ERROR_BOUNDARY.en.d.ts +10 -10
  498. package/dist/esm/i18n/components/APP_LAYOUTS_ROUTER_ERROR_BOUNDARY.en.d.ts.map +1 -1
  499. package/dist/esm/i18n/components/APP_LAYOUTS_ROUTER_ERROR_BOUNDARY.en.js +10 -10
  500. package/dist/esm/i18n/components/APP_LAYOUTS_ROUTER_ERROR_BOUNDARY.en.js.map +1 -1
  501. package/dist/esm/i18n/components/APP_LAYOUTS_SECURITY_SETTINGS.en.d.ts +25 -13
  502. package/dist/esm/i18n/components/APP_LAYOUTS_SECURITY_SETTINGS.en.d.ts.map +1 -1
  503. package/dist/esm/i18n/components/APP_LAYOUTS_SECURITY_SETTINGS.en.js +26 -14
  504. package/dist/esm/i18n/components/APP_LAYOUTS_SECURITY_SETTINGS.en.js.map +1 -1
  505. package/dist/esm/i18n/components/APP_LAYOUTS_SETTINGS_HUB.en.d.ts +1 -0
  506. package/dist/esm/i18n/components/APP_LAYOUTS_SETTINGS_HUB.en.d.ts.map +1 -1
  507. package/dist/esm/i18n/components/APP_LAYOUTS_SETTINGS_HUB.en.js +2 -1
  508. package/dist/esm/i18n/components/APP_LAYOUTS_SETTINGS_HUB.en.js.map +1 -1
  509. package/dist/esm/i18n/components/APP_LAYOUTS_SURFACE_ERROR_BOUNDARY.en.d.ts +17 -0
  510. package/dist/esm/i18n/components/APP_LAYOUTS_SURFACE_ERROR_BOUNDARY.en.d.ts.map +1 -0
  511. package/dist/esm/i18n/components/APP_LAYOUTS_SURFACE_ERROR_BOUNDARY.en.js +17 -0
  512. package/dist/esm/i18n/components/APP_LAYOUTS_SURFACE_ERROR_BOUNDARY.en.js.map +1 -0
  513. package/dist/esm/i18n/components/HIGH_LEVEL_VIEWS_CHART.en.d.ts +5 -5
  514. package/dist/esm/i18n/components/HIGH_LEVEL_VIEWS_CHART.en.d.ts.map +1 -1
  515. package/dist/esm/i18n/components/HIGH_LEVEL_VIEWS_CHART.en.js +5 -5
  516. package/dist/esm/i18n/components/HIGH_LEVEL_VIEWS_CHART.en.js.map +1 -1
  517. package/dist/esm/i18n/components/HIGH_LEVEL_VIEWS_CHART_WIDGET.en.d.ts +1 -1
  518. package/dist/esm/i18n/components/HIGH_LEVEL_VIEWS_CHART_WIDGET.en.d.ts.map +1 -1
  519. package/dist/esm/i18n/components/HIGH_LEVEL_VIEWS_CHART_WIDGET.en.js +1 -1
  520. package/dist/esm/i18n/components/HIGH_LEVEL_VIEWS_CHART_WIDGET.en.js.map +1 -1
  521. package/dist/esm/i18n/components/HIGH_LEVEL_VIEWS_EXECUTION.en.d.ts +1 -1
  522. package/dist/esm/i18n/components/HIGH_LEVEL_VIEWS_EXECUTION.en.d.ts.map +1 -1
  523. package/dist/esm/i18n/components/HIGH_LEVEL_VIEWS_EXECUTION.en.js +1 -1
  524. package/dist/esm/i18n/components/HIGH_LEVEL_VIEWS_EXECUTION.en.js.map +1 -1
  525. package/dist/esm/i18n/components/HIGH_LEVEL_VIEWS_FLOWS_ACTORS.en.d.ts +16 -2
  526. package/dist/esm/i18n/components/HIGH_LEVEL_VIEWS_FLOWS_ACTORS.en.d.ts.map +1 -1
  527. package/dist/esm/i18n/components/HIGH_LEVEL_VIEWS_FLOWS_ACTORS.en.js +16 -2
  528. package/dist/esm/i18n/components/HIGH_LEVEL_VIEWS_FLOWS_ACTORS.en.js.map +1 -1
  529. package/dist/esm/i18n/components/HIGH_LEVEL_VIEWS_NOT_FOUND.en.d.ts +3 -3
  530. package/dist/esm/i18n/components/HIGH_LEVEL_VIEWS_NOT_FOUND.en.d.ts.map +1 -1
  531. package/dist/esm/i18n/components/HIGH_LEVEL_VIEWS_NOT_FOUND.en.js +3 -3
  532. package/dist/esm/i18n/components/HIGH_LEVEL_VIEWS_NOT_FOUND.en.js.map +1 -1
  533. package/dist/esm/i18n/components/LOW_LEVEL_ACTION_BAR.en.d.ts.map +1 -1
  534. package/dist/esm/i18n/components/LOW_LEVEL_AI_ACTOR.en.d.ts +8 -8
  535. package/dist/esm/i18n/components/LOW_LEVEL_AI_ACTOR.en.d.ts.map +1 -1
  536. package/dist/esm/i18n/components/LOW_LEVEL_AI_ACTOR.en.js +8 -8
  537. package/dist/esm/i18n/components/LOW_LEVEL_AI_ACTOR.en.js.map +1 -1
  538. package/dist/esm/i18n/components/LOW_LEVEL_AI_AGENT_CONFIG.en.d.ts +14 -14
  539. package/dist/esm/i18n/components/LOW_LEVEL_AI_AGENT_CONFIG.en.d.ts.map +1 -1
  540. package/dist/esm/i18n/components/LOW_LEVEL_AI_AGENT_CONFIG.en.js +14 -14
  541. package/dist/esm/i18n/components/LOW_LEVEL_AI_AGENT_CONFIG.en.js.map +1 -1
  542. package/dist/esm/i18n/components/LOW_LEVEL_AI_APPROVAL.en.d.ts +22 -6
  543. package/dist/esm/i18n/components/LOW_LEVEL_AI_APPROVAL.en.d.ts.map +1 -1
  544. package/dist/esm/i18n/components/LOW_LEVEL_AI_APPROVAL.en.js +23 -7
  545. package/dist/esm/i18n/components/LOW_LEVEL_AI_APPROVAL.en.js.map +1 -1
  546. package/dist/esm/i18n/components/LOW_LEVEL_AI_ARTIFACT.en.d.ts +2 -2
  547. package/dist/esm/i18n/components/LOW_LEVEL_AI_ARTIFACT.en.d.ts.map +1 -1
  548. package/dist/esm/i18n/components/LOW_LEVEL_AI_ARTIFACT.en.js +2 -2
  549. package/dist/esm/i18n/components/LOW_LEVEL_AI_ARTIFACT.en.js.map +1 -1
  550. package/dist/esm/i18n/components/LOW_LEVEL_AI_ARTIFACT_BROWSER.en.d.ts +1 -1
  551. package/dist/esm/i18n/components/LOW_LEVEL_AI_ARTIFACT_BROWSER.en.d.ts.map +1 -1
  552. package/dist/esm/i18n/components/LOW_LEVEL_AI_ARTIFACT_BROWSER.en.js +1 -1
  553. package/dist/esm/i18n/components/LOW_LEVEL_AI_ARTIFACT_BROWSER.en.js.map +1 -1
  554. package/dist/esm/i18n/components/LOW_LEVEL_AI_CHAIN_OF_THOUGHT.en.d.ts.map +1 -1
  555. package/dist/esm/i18n/components/LOW_LEVEL_AI_CODE_BLOCK.en.d.ts.map +1 -1
  556. package/dist/esm/i18n/components/LOW_LEVEL_AI_CONFIRMATION.en.d.ts +1 -1
  557. package/dist/esm/i18n/components/LOW_LEVEL_AI_CONFIRMATION.en.d.ts.map +1 -1
  558. package/dist/esm/i18n/components/LOW_LEVEL_AI_CONFIRMATION.en.js +1 -1
  559. package/dist/esm/i18n/components/LOW_LEVEL_AI_CONFIRMATION.en.js.map +1 -1
  560. package/dist/esm/i18n/components/LOW_LEVEL_AI_CONTEXT.en.d.ts +1 -1
  561. package/dist/esm/i18n/components/LOW_LEVEL_AI_CONTEXT.en.d.ts.map +1 -1
  562. package/dist/esm/i18n/components/LOW_LEVEL_AI_CONTEXT.en.js +1 -1
  563. package/dist/esm/i18n/components/LOW_LEVEL_AI_CONTEXT.en.js.map +1 -1
  564. package/dist/esm/i18n/components/LOW_LEVEL_AI_CONVERSATION.en.d.ts.map +1 -1
  565. package/dist/esm/i18n/components/LOW_LEVEL_AI_DECISION.en.d.ts +2 -2
  566. package/dist/esm/i18n/components/LOW_LEVEL_AI_DECISION.en.d.ts.map +1 -1
  567. package/dist/esm/i18n/components/LOW_LEVEL_AI_DECISION.en.js +2 -2
  568. package/dist/esm/i18n/components/LOW_LEVEL_AI_DECISION.en.js.map +1 -1
  569. package/dist/esm/i18n/components/LOW_LEVEL_AI_DIFF_BLOCK.en.d.ts +21 -0
  570. package/dist/esm/i18n/components/LOW_LEVEL_AI_DIFF_BLOCK.en.d.ts.map +1 -0
  571. package/dist/esm/i18n/components/LOW_LEVEL_AI_DIFF_BLOCK.en.js +21 -0
  572. package/dist/esm/i18n/components/LOW_LEVEL_AI_DIFF_BLOCK.en.js.map +1 -0
  573. package/dist/esm/i18n/components/LOW_LEVEL_AI_EXECUTION_PLAN.en.d.ts +1 -1
  574. package/dist/esm/i18n/components/LOW_LEVEL_AI_EXECUTION_PLAN.en.d.ts.map +1 -1
  575. package/dist/esm/i18n/components/LOW_LEVEL_AI_EXECUTION_PLAN.en.js +1 -1
  576. package/dist/esm/i18n/components/LOW_LEVEL_AI_EXECUTION_PLAN.en.js.map +1 -1
  577. package/dist/esm/i18n/components/LOW_LEVEL_AI_EXECUTION_STREAM.en.d.ts +1 -1
  578. package/dist/esm/i18n/components/LOW_LEVEL_AI_EXECUTION_STREAM.en.d.ts.map +1 -1
  579. package/dist/esm/i18n/components/LOW_LEVEL_AI_EXECUTION_STREAM.en.js +1 -1
  580. package/dist/esm/i18n/components/LOW_LEVEL_AI_EXECUTION_STREAM.en.js.map +1 -1
  581. package/dist/esm/i18n/components/LOW_LEVEL_AI_FLOW_EXECUTION.en.d.ts.map +1 -1
  582. package/dist/esm/i18n/components/LOW_LEVEL_AI_FLOW_NODE.en.d.ts.map +1 -1
  583. package/dist/esm/i18n/components/LOW_LEVEL_AI_INLINE_CITATION.en.d.ts.map +1 -1
  584. package/dist/esm/i18n/components/LOW_LEVEL_AI_MESSAGE.en.d.ts +2 -2
  585. package/dist/esm/i18n/components/LOW_LEVEL_AI_MESSAGE.en.d.ts.map +1 -1
  586. package/dist/esm/i18n/components/LOW_LEVEL_AI_MESSAGE.en.js +2 -2
  587. package/dist/esm/i18n/components/LOW_LEVEL_AI_MESSAGE.en.js.map +1 -1
  588. package/dist/esm/i18n/components/LOW_LEVEL_AI_MODEL_SELECTOR.en.d.ts +1 -1
  589. package/dist/esm/i18n/components/LOW_LEVEL_AI_MODEL_SELECTOR.en.d.ts.map +1 -1
  590. package/dist/esm/i18n/components/LOW_LEVEL_AI_MODEL_SELECTOR.en.js +1 -1
  591. package/dist/esm/i18n/components/LOW_LEVEL_AI_MODEL_SELECTOR.en.js.map +1 -1
  592. package/dist/esm/i18n/components/LOW_LEVEL_AI_OPEN_IN_CHAT.en.d.ts.map +1 -1
  593. package/dist/esm/i18n/components/LOW_LEVEL_AI_PLAN.en.d.ts.map +1 -1
  594. package/dist/esm/i18n/components/LOW_LEVEL_AI_PROMPT_INPUT.en.d.ts.map +1 -1
  595. package/dist/esm/i18n/components/LOW_LEVEL_AI_SYSTEM_CATALOG.en.d.ts +4 -5
  596. package/dist/esm/i18n/components/LOW_LEVEL_AI_SYSTEM_CATALOG.en.d.ts.map +1 -1
  597. package/dist/esm/i18n/components/LOW_LEVEL_AI_SYSTEM_CATALOG.en.js +4 -5
  598. package/dist/esm/i18n/components/LOW_LEVEL_AI_SYSTEM_CATALOG.en.js.map +1 -1
  599. package/dist/esm/i18n/components/LOW_LEVEL_AI_TASK_DETAIL.en.d.ts +4 -4
  600. package/dist/esm/i18n/components/LOW_LEVEL_AI_TASK_DETAIL.en.d.ts.map +1 -1
  601. package/dist/esm/i18n/components/LOW_LEVEL_AI_TASK_DETAIL.en.js +4 -4
  602. package/dist/esm/i18n/components/LOW_LEVEL_AI_TASK_DETAIL.en.js.map +1 -1
  603. package/dist/esm/i18n/components/LOW_LEVEL_AI_TASK_MEMORY.en.d.ts +2 -2
  604. package/dist/esm/i18n/components/LOW_LEVEL_AI_TASK_MEMORY.en.d.ts.map +1 -1
  605. package/dist/esm/i18n/components/LOW_LEVEL_AI_TASK_MEMORY.en.js +2 -2
  606. package/dist/esm/i18n/components/LOW_LEVEL_AI_TASK_MEMORY.en.js.map +1 -1
  607. package/dist/esm/i18n/components/LOW_LEVEL_AI_WEB_PREVIEW.en.d.ts +1 -1
  608. package/dist/esm/i18n/components/LOW_LEVEL_AI_WEB_PREVIEW.en.d.ts.map +1 -1
  609. package/dist/esm/i18n/components/LOW_LEVEL_AI_WEB_PREVIEW.en.js +1 -1
  610. package/dist/esm/i18n/components/LOW_LEVEL_AI_WEB_PREVIEW.en.js.map +1 -1
  611. package/dist/esm/i18n/components/LOW_LEVEL_BILLING_INVOICE_HISTORY.en.d.ts +1 -0
  612. package/dist/esm/i18n/components/LOW_LEVEL_BILLING_INVOICE_HISTORY.en.d.ts.map +1 -1
  613. package/dist/esm/i18n/components/LOW_LEVEL_BILLING_INVOICE_HISTORY.en.js +2 -1
  614. package/dist/esm/i18n/components/LOW_LEVEL_BILLING_INVOICE_HISTORY.en.js.map +1 -1
  615. package/dist/esm/i18n/components/LOW_LEVEL_BILLING_PLAN_CHANGE_PREVIEW.en.d.ts +25 -0
  616. package/dist/esm/i18n/components/LOW_LEVEL_BILLING_PLAN_CHANGE_PREVIEW.en.d.ts.map +1 -0
  617. package/dist/esm/i18n/components/LOW_LEVEL_BILLING_PLAN_CHANGE_PREVIEW.en.js +25 -0
  618. package/dist/esm/i18n/components/LOW_LEVEL_BILLING_PLAN_CHANGE_PREVIEW.en.js.map +1 -0
  619. package/dist/esm/i18n/components/LOW_LEVEL_BILLING_PORTAL_LINK.en.d.ts +1 -0
  620. package/dist/esm/i18n/components/LOW_LEVEL_BILLING_PORTAL_LINK.en.d.ts.map +1 -1
  621. package/dist/esm/i18n/components/LOW_LEVEL_BILLING_PORTAL_LINK.en.js +2 -1
  622. package/dist/esm/i18n/components/LOW_LEVEL_BILLING_PORTAL_LINK.en.js.map +1 -1
  623. package/dist/esm/i18n/components/LOW_LEVEL_BILLING_PRICING_TABLE.en.d.ts +3 -2
  624. package/dist/esm/i18n/components/LOW_LEVEL_BILLING_PRICING_TABLE.en.d.ts.map +1 -1
  625. package/dist/esm/i18n/components/LOW_LEVEL_BILLING_PRICING_TABLE.en.js +4 -3
  626. package/dist/esm/i18n/components/LOW_LEVEL_BILLING_PRICING_TABLE.en.js.map +1 -1
  627. package/dist/esm/i18n/components/LOW_LEVEL_BILLING_SUBSCRIPTION_STATUS.en.d.ts +3 -2
  628. package/dist/esm/i18n/components/LOW_LEVEL_BILLING_SUBSCRIPTION_STATUS.en.d.ts.map +1 -1
  629. package/dist/esm/i18n/components/LOW_LEVEL_BILLING_SUBSCRIPTION_STATUS.en.js +4 -3
  630. package/dist/esm/i18n/components/LOW_LEVEL_BILLING_SUBSCRIPTION_STATUS.en.js.map +1 -1
  631. package/dist/esm/i18n/components/LOW_LEVEL_BILLING_USAGE_DASHBOARD.en.d.ts +3 -1
  632. package/dist/esm/i18n/components/LOW_LEVEL_BILLING_USAGE_DASHBOARD.en.d.ts.map +1 -1
  633. package/dist/esm/i18n/components/LOW_LEVEL_BILLING_USAGE_DASHBOARD.en.js +4 -2
  634. package/dist/esm/i18n/components/LOW_LEVEL_BILLING_USAGE_DASHBOARD.en.js.map +1 -1
  635. package/dist/esm/i18n/components/LOW_LEVEL_BREADCRUMB.en.d.ts.map +1 -1
  636. package/dist/esm/i18n/components/LOW_LEVEL_BUTTON.en.d.ts.map +1 -1
  637. package/dist/esm/i18n/components/LOW_LEVEL_CAROUSEL.en.d.ts.map +1 -1
  638. package/dist/esm/i18n/components/LOW_LEVEL_CELEBRATION_OVERLAY.en.d.ts.map +1 -1
  639. package/dist/esm/i18n/components/LOW_LEVEL_COLOR_INPUT.en.d.ts +3 -3
  640. package/dist/esm/i18n/components/LOW_LEVEL_COLOR_INPUT.en.d.ts.map +1 -1
  641. package/dist/esm/i18n/components/LOW_LEVEL_COLOR_INPUT.en.js +3 -3
  642. package/dist/esm/i18n/components/LOW_LEVEL_COLOR_INPUT.en.js.map +1 -1
  643. package/dist/esm/i18n/components/LOW_LEVEL_COMMAND.en.d.ts +1 -1
  644. package/dist/esm/i18n/components/LOW_LEVEL_COMMAND.en.d.ts.map +1 -1
  645. package/dist/esm/i18n/components/LOW_LEVEL_COMMAND.en.js +1 -1
  646. package/dist/esm/i18n/components/LOW_LEVEL_COMMAND.en.js.map +1 -1
  647. package/dist/esm/i18n/components/LOW_LEVEL_CONTENT_SECTION_CONTAINER.en.d.ts +3 -3
  648. package/dist/esm/i18n/components/LOW_LEVEL_CONTENT_SECTION_CONTAINER.en.d.ts.map +1 -1
  649. package/dist/esm/i18n/components/LOW_LEVEL_CONTENT_SECTION_CONTAINER.en.js +3 -3
  650. package/dist/esm/i18n/components/LOW_LEVEL_CONTENT_SECTION_CONTAINER.en.js.map +1 -1
  651. package/dist/esm/i18n/components/LOW_LEVEL_DATETIME_RANGE_PICKER.en.d.ts +15 -0
  652. package/dist/esm/i18n/components/LOW_LEVEL_DATETIME_RANGE_PICKER.en.d.ts.map +1 -0
  653. package/dist/esm/i18n/components/LOW_LEVEL_DATETIME_RANGE_PICKER.en.js +15 -0
  654. package/dist/esm/i18n/components/LOW_LEVEL_DATETIME_RANGE_PICKER.en.js.map +1 -0
  655. package/dist/esm/i18n/components/LOW_LEVEL_DIALOG.en.d.ts.map +1 -1
  656. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_ADDRESS.en.d.ts +12 -0
  657. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_ADDRESS.en.d.ts.map +1 -0
  658. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_ADDRESS.en.js +12 -0
  659. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_ADDRESS.en.js.map +1 -0
  660. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_BIGDECIMAL.en.d.ts +1 -1
  661. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_BIGDECIMAL.en.d.ts.map +1 -1
  662. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_BIGDECIMAL.en.js +1 -1
  663. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_BIGDECIMAL.en.js.map +1 -1
  664. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_BOOLEAN.en.d.ts.map +1 -1
  665. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_CODE.en.d.ts +1 -1
  666. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_CODE.en.d.ts.map +1 -1
  667. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_CODE.en.js +1 -1
  668. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_CODE.en.js.map +1 -1
  669. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_DURATION.en.d.ts.map +1 -1
  670. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_FILE.en.d.ts +4 -3
  671. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_FILE.en.d.ts.map +1 -1
  672. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_FILE.en.js +4 -3
  673. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_FILE.en.js.map +1 -1
  674. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_FILE_AUDIO.en.d.ts +1 -1
  675. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_FILE_AUDIO.en.d.ts.map +1 -1
  676. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_FILE_AUDIO.en.js +1 -1
  677. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_FILE_AUDIO.en.js.map +1 -1
  678. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_FILE_DOCUMENT.en.d.ts +3 -0
  679. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_FILE_DOCUMENT.en.d.ts.map +1 -1
  680. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_FILE_DOCUMENT.en.js +4 -1
  681. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_FILE_DOCUMENT.en.js.map +1 -1
  682. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_FILE_GALLERY.en.d.ts.map +1 -1
  683. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_FILE_IMAGE.en.d.ts +1 -1
  684. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_FILE_IMAGE.en.d.ts.map +1 -1
  685. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_FILE_IMAGE.en.js +1 -1
  686. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_FILE_IMAGE.en.js.map +1 -1
  687. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_FILE_VIDEO.en.d.ts.map +1 -1
  688. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_MONEY.en.d.ts.map +1 -1
  689. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_PHONE.en.d.ts +1 -1
  690. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_PHONE.en.d.ts.map +1 -1
  691. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_PHONE.en.js +1 -1
  692. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_PHONE.en.js.map +1 -1
  693. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_RANGE_BIGDECIMAL.en.d.ts +1 -1
  694. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_RANGE_BIGDECIMAL.en.d.ts.map +1 -1
  695. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_RANGE_BIGDECIMAL.en.js +1 -1
  696. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_RANGE_BIGDECIMAL.en.js.map +1 -1
  697. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_RANGE_MONEY.en.d.ts +1 -1
  698. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_RANGE_MONEY.en.d.ts.map +1 -1
  699. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_RANGE_MONEY.en.js +1 -1
  700. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_RANGE_MONEY.en.js.map +1 -1
  701. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_RANGE_NUMBER.en.d.ts +1 -1
  702. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_RANGE_NUMBER.en.d.ts.map +1 -1
  703. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_RANGE_NUMBER.en.js +1 -1
  704. package/dist/esm/i18n/components/LOW_LEVEL_DISPLAY_FIELD_RANGE_NUMBER.en.js.map +1 -1
  705. package/dist/esm/i18n/components/LOW_LEVEL_DRAWER.en.d.ts +1 -1
  706. package/dist/esm/i18n/components/LOW_LEVEL_DRAWER.en.d.ts.map +1 -1
  707. package/dist/esm/i18n/components/LOW_LEVEL_DRAWER.en.js +1 -1
  708. package/dist/esm/i18n/components/LOW_LEVEL_DRAWER.en.js.map +1 -1
  709. package/dist/esm/i18n/components/LOW_LEVEL_DURATION.en.d.ts +22 -0
  710. package/dist/esm/i18n/components/LOW_LEVEL_DURATION.en.d.ts.map +1 -0
  711. package/dist/esm/i18n/components/LOW_LEVEL_DURATION.en.js +22 -0
  712. package/dist/esm/i18n/components/LOW_LEVEL_DURATION.en.js.map +1 -0
  713. package/dist/esm/i18n/components/LOW_LEVEL_ERROR_DISPLAY.en.d.ts +2 -2
  714. package/dist/esm/i18n/components/LOW_LEVEL_ERROR_DISPLAY.en.d.ts.map +1 -1
  715. package/dist/esm/i18n/components/LOW_LEVEL_ERROR_DISPLAY.en.js +2 -2
  716. package/dist/esm/i18n/components/LOW_LEVEL_ERROR_DISPLAY.en.js.map +1 -1
  717. package/dist/esm/i18n/components/LOW_LEVEL_FEATURE_LOCK_BADGE.en.d.ts.map +1 -1
  718. package/dist/esm/i18n/components/LOW_LEVEL_FEATURE_UNAVAILABLE_PROMPT.en.d.ts +6 -6
  719. package/dist/esm/i18n/components/LOW_LEVEL_FEATURE_UNAVAILABLE_PROMPT.en.d.ts.map +1 -1
  720. package/dist/esm/i18n/components/LOW_LEVEL_FEATURE_UNAVAILABLE_PROMPT.en.js +6 -6
  721. package/dist/esm/i18n/components/LOW_LEVEL_FEATURE_UNAVAILABLE_PROMPT.en.js.map +1 -1
  722. package/dist/esm/i18n/components/LOW_LEVEL_FILE_UPLOAD.en.d.ts +3 -3
  723. package/dist/esm/i18n/components/LOW_LEVEL_FILE_UPLOAD.en.d.ts.map +1 -1
  724. package/dist/esm/i18n/components/LOW_LEVEL_FILE_UPLOAD.en.js +3 -3
  725. package/dist/esm/i18n/components/LOW_LEVEL_FILE_UPLOAD.en.js.map +1 -1
  726. package/dist/esm/i18n/components/LOW_LEVEL_FORM_FIELD.en.d.ts +15 -8
  727. package/dist/esm/i18n/components/LOW_LEVEL_FORM_FIELD.en.d.ts.map +1 -1
  728. package/dist/esm/i18n/components/LOW_LEVEL_FORM_FIELD.en.js +16 -9
  729. package/dist/esm/i18n/components/LOW_LEVEL_FORM_FIELD.en.js.map +1 -1
  730. package/dist/esm/i18n/components/LOW_LEVEL_FORM_FIELD_ADDRESS.en.d.ts +20 -0
  731. package/dist/esm/i18n/components/LOW_LEVEL_FORM_FIELD_ADDRESS.en.d.ts.map +1 -0
  732. package/dist/esm/i18n/components/LOW_LEVEL_FORM_FIELD_ADDRESS.en.js +20 -0
  733. package/dist/esm/i18n/components/LOW_LEVEL_FORM_FIELD_ADDRESS.en.js.map +1 -0
  734. package/dist/esm/i18n/components/LOW_LEVEL_FORM_FIELD_BOOLEAN.en.d.ts.map +1 -1
  735. package/dist/esm/i18n/components/LOW_LEVEL_FORM_FIELD_CODE.en.d.ts +1 -1
  736. package/dist/esm/i18n/components/LOW_LEVEL_FORM_FIELD_CODE.en.d.ts.map +1 -1
  737. package/dist/esm/i18n/components/LOW_LEVEL_FORM_FIELD_CODE.en.js +1 -1
  738. package/dist/esm/i18n/components/LOW_LEVEL_FORM_FIELD_CODE.en.js.map +1 -1
  739. package/dist/esm/i18n/components/LOW_LEVEL_FORM_FIELD_FILE.en.d.ts +39 -20
  740. package/dist/esm/i18n/components/LOW_LEVEL_FORM_FIELD_FILE.en.d.ts.map +1 -1
  741. package/dist/esm/i18n/components/LOW_LEVEL_FORM_FIELD_FILE.en.js +39 -20
  742. package/dist/esm/i18n/components/LOW_LEVEL_FORM_FIELD_FILE.en.js.map +1 -1
  743. package/dist/esm/i18n/components/LOW_LEVEL_FORM_FIELD_PHONE.en.d.ts.map +1 -1
  744. package/dist/esm/i18n/components/LOW_LEVEL_FORM_FIELD_STRING.en.d.ts.map +1 -1
  745. package/dist/esm/i18n/components/LOW_LEVEL_FORM_MESSAGE.en.d.ts +5 -5
  746. package/dist/esm/i18n/components/LOW_LEVEL_FORM_MESSAGE.en.d.ts.map +1 -1
  747. package/dist/esm/i18n/components/LOW_LEVEL_FORM_MESSAGE.en.js +5 -5
  748. package/dist/esm/i18n/components/LOW_LEVEL_FORM_MESSAGE.en.js.map +1 -1
  749. package/dist/esm/i18n/components/LOW_LEVEL_IMAGE_CROP.en.d.ts.map +1 -1
  750. package/dist/esm/i18n/components/LOW_LEVEL_LOADING_OVERLAY.en.d.ts.map +1 -1
  751. package/dist/esm/i18n/components/LOW_LEVEL_LOADING_SPINNER.en.d.ts.map +1 -1
  752. package/dist/esm/i18n/components/LOW_LEVEL_OPERATIONS_CONFIRM_CRITICAL.en.d.ts +1 -1
  753. package/dist/esm/i18n/components/LOW_LEVEL_OPERATIONS_CONFIRM_CRITICAL.en.d.ts.map +1 -1
  754. package/dist/esm/i18n/components/LOW_LEVEL_OPERATIONS_CONFIRM_CRITICAL.en.js +1 -1
  755. package/dist/esm/i18n/components/LOW_LEVEL_OPERATIONS_CONFIRM_CRITICAL.en.js.map +1 -1
  756. package/dist/esm/i18n/components/LOW_LEVEL_OVERLAY_CONTAINER.en.d.ts.map +1 -1
  757. package/dist/esm/i18n/components/LOW_LEVEL_PAGINATION.en.d.ts.map +1 -1
  758. package/dist/esm/i18n/components/LOW_LEVEL_PASSWORD_INPUT.en.d.ts +13 -0
  759. package/dist/esm/i18n/components/LOW_LEVEL_PASSWORD_INPUT.en.d.ts.map +1 -0
  760. package/dist/esm/i18n/components/LOW_LEVEL_PASSWORD_INPUT.en.js +13 -0
  761. package/dist/esm/i18n/components/LOW_LEVEL_PASSWORD_INPUT.en.js.map +1 -0
  762. package/dist/esm/i18n/components/LOW_LEVEL_RANGE_SLIDER.en.d.ts +13 -0
  763. package/dist/esm/i18n/components/LOW_LEVEL_RANGE_SLIDER.en.d.ts.map +1 -0
  764. package/dist/esm/i18n/components/LOW_LEVEL_RANGE_SLIDER.en.js +13 -0
  765. package/dist/esm/i18n/components/LOW_LEVEL_RANGE_SLIDER.en.js.map +1 -0
  766. package/dist/esm/i18n/components/LOW_LEVEL_SELECT_MULTIPLE.en.d.ts.map +1 -1
  767. package/dist/esm/i18n/components/LOW_LEVEL_SHEET.en.d.ts.map +1 -1
  768. package/dist/esm/i18n/components/LOW_LEVEL_SIDEBAR.en.d.ts +3 -3
  769. package/dist/esm/i18n/components/LOW_LEVEL_SIDEBAR.en.d.ts.map +1 -1
  770. package/dist/esm/i18n/components/LOW_LEVEL_SIDEBAR.en.js +3 -3
  771. package/dist/esm/i18n/components/LOW_LEVEL_SIDEBAR.en.js.map +1 -1
  772. package/dist/esm/i18n/components/LOW_LEVEL_TIME_RANGE_PICKER.en.d.ts +15 -0
  773. package/dist/esm/i18n/components/LOW_LEVEL_TIME_RANGE_PICKER.en.d.ts.map +1 -0
  774. package/dist/esm/i18n/components/LOW_LEVEL_TIME_RANGE_PICKER.en.js +15 -0
  775. package/dist/esm/i18n/components/LOW_LEVEL_TIME_RANGE_PICKER.en.js.map +1 -0
  776. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_AUTH_CALLBACK.en.d.ts +5 -3
  777. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_AUTH_CALLBACK.en.d.ts.map +1 -1
  778. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_AUTH_CALLBACK.en.js +6 -4
  779. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_AUTH_CALLBACK.en.js.map +1 -1
  780. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_ENROLLMENT_REQUIRED.en.d.ts +10 -9
  781. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_ENROLLMENT_REQUIRED.en.d.ts.map +1 -1
  782. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_ENROLLMENT_REQUIRED.en.js +11 -10
  783. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_ENROLLMENT_REQUIRED.en.js.map +1 -1
  784. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_FILE_UPLOAD_GRANT.en.d.ts.map +1 -1
  785. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_FILE_UPLOAD_GRANT.en.js.map +1 -1
  786. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_MAGIC_LINK_VERIFY.en.d.ts +5 -5
  787. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_MAGIC_LINK_VERIFY.en.d.ts.map +1 -1
  788. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_MAGIC_LINK_VERIFY.en.js +5 -5
  789. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_MAGIC_LINK_VERIFY.en.js.map +1 -1
  790. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_MFA_CHALLENGE.en.d.ts +6 -6
  791. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_MFA_CHALLENGE.en.d.ts.map +1 -1
  792. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_MFA_CHALLENGE.en.js +6 -6
  793. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_MFA_CHALLENGE.en.js.map +1 -1
  794. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_OAUTH_CONSENT.en.d.ts +7 -7
  795. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_OAUTH_CONSENT.en.d.ts.map +1 -1
  796. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_OAUTH_CONSENT.en.js +7 -7
  797. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_OAUTH_CONSENT.en.js.map +1 -1
  798. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_OAUTH_LOGGED_OUT.en.d.ts +1 -1
  799. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_OAUTH_LOGGED_OUT.en.d.ts.map +1 -1
  800. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_OAUTH_LOGGED_OUT.en.js +1 -1
  801. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_OAUTH_LOGGED_OUT.en.js.map +1 -1
  802. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_OAUTH_LOGOUT_CONFIRM.en.d.ts +1 -1
  803. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_OAUTH_LOGOUT_CONFIRM.en.d.ts.map +1 -1
  804. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_OAUTH_LOGOUT_CONFIRM.en.js +1 -1
  805. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_OAUTH_LOGOUT_CONFIRM.en.js.map +1 -1
  806. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_ONE_OFF_SESSION.en.d.ts +4 -4
  807. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_ONE_OFF_SESSION.en.d.ts.map +1 -1
  808. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_ONE_OFF_SESSION.en.js +4 -4
  809. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_ONE_OFF_SESSION.en.js.map +1 -1
  810. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_ORGANIZATION_ONBOARDING.en.d.ts +24 -0
  811. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_ORGANIZATION_ONBOARDING.en.d.ts.map +1 -0
  812. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_ORGANIZATION_ONBOARDING.en.js +24 -0
  813. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_ORGANIZATION_ONBOARDING.en.js.map +1 -0
  814. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_TERMS.en.d.ts +6 -4
  815. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_TERMS.en.d.ts.map +1 -1
  816. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_TERMS.en.js +6 -4
  817. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_TERMS.en.js.map +1 -1
  818. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_USER_AUTH.en.d.ts +14 -10
  819. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_USER_AUTH.en.d.ts.map +1 -1
  820. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_USER_AUTH.en.js +14 -10
  821. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_USER_AUTH.en.js.map +1 -1
  822. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_USER_CONFIRM_EMAIL.en.d.ts +6 -6
  823. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_USER_CONFIRM_EMAIL.en.d.ts.map +1 -1
  824. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_USER_CONFIRM_EMAIL.en.js +6 -6
  825. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_USER_CONFIRM_EMAIL.en.js.map +1 -1
  826. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_USER_INVITATION.en.d.ts +11 -8
  827. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_USER_INVITATION.en.d.ts.map +1 -1
  828. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_USER_INVITATION.en.js +12 -9
  829. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_USER_INVITATION.en.js.map +1 -1
  830. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_USER_PASSWORD_LOST.en.d.ts +9 -8
  831. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_USER_PASSWORD_LOST.en.d.ts.map +1 -1
  832. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_USER_PASSWORD_LOST.en.js +9 -8
  833. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_USER_PASSWORD_LOST.en.js.map +1 -1
  834. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_USER_REGISTER.en.d.ts +25 -9
  835. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_USER_REGISTER.en.d.ts.map +1 -1
  836. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_USER_REGISTER.en.js +25 -9
  837. package/dist/esm/i18n/components/PUBLIC_LAYOUTS_USER_REGISTER.en.js.map +1 -1
  838. package/dist/esm/i18n/components/RESOURCES_FIELDS_RESOURCE_REFERENCE.en.d.ts +1 -1
  839. package/dist/esm/i18n/components/RESOURCES_FIELDS_RESOURCE_REFERENCE.en.d.ts.map +1 -1
  840. package/dist/esm/i18n/components/RESOURCES_FIELDS_RESOURCE_REFERENCE.en.js +1 -1
  841. package/dist/esm/i18n/components/RESOURCES_FIELDS_RESOURCE_REFERENCE.en.js.map +1 -1
  842. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_ACTION.en.d.ts +2 -2
  843. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_ACTION.en.d.ts.map +1 -1
  844. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_ACTION.en.js +2 -2
  845. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_ACTION.en.js.map +1 -1
  846. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_CONTAINER_NESTED.en.d.ts +1 -0
  847. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_CONTAINER_NESTED.en.d.ts.map +1 -1
  848. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_CONTAINER_NESTED.en.js +2 -1
  849. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_CONTAINER_NESTED.en.js.map +1 -1
  850. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_CREATE.en.d.ts +25 -24
  851. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_CREATE.en.d.ts.map +1 -1
  852. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_CREATE.en.js +26 -25
  853. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_CREATE.en.js.map +1 -1
  854. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_DANGER_ZONE.en.d.ts +1 -1
  855. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_DANGER_ZONE.en.d.ts.map +1 -1
  856. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_DANGER_ZONE.en.js +1 -1
  857. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_DANGER_ZONE.en.js.map +1 -1
  858. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_FILTERS.en.d.ts +3 -1
  859. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_FILTERS.en.d.ts.map +1 -1
  860. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_FILTERS.en.js +4 -2
  861. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_FILTERS.en.js.map +1 -1
  862. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_HEADER.en.d.ts +2 -2
  863. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_HEADER.en.d.ts.map +1 -1
  864. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_HEADER.en.js +2 -2
  865. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_HEADER.en.js.map +1 -1
  866. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_LIST.en.d.ts +11 -11
  867. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_LIST.en.d.ts.map +1 -1
  868. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_LIST.en.js +11 -11
  869. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_LIST.en.js.map +1 -1
  870. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_OPERATIONS_BULK.en.d.ts +1 -1
  871. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_OPERATIONS_BULK.en.d.ts.map +1 -1
  872. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_OPERATIONS_BULK.en.js +1 -1
  873. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_OPERATIONS_BULK.en.js.map +1 -1
  874. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_OPERATIONS_ITEMS.en.d.ts +12 -0
  875. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_OPERATIONS_ITEMS.en.d.ts.map +1 -1
  876. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_OPERATIONS_ITEMS.en.js +13 -1
  877. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_OPERATIONS_ITEMS.en.js.map +1 -1
  878. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_PAGINATION.en.d.ts.map +1 -1
  879. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_READ.en.d.ts +6 -6
  880. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_READ.en.d.ts.map +1 -1
  881. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_READ.en.js +6 -6
  882. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_READ.en.js.map +1 -1
  883. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_SEARCH.en.d.ts +2 -2
  884. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_SEARCH.en.d.ts.map +1 -1
  885. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_SEARCH.en.js +2 -2
  886. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_SEARCH.en.js.map +1 -1
  887. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_UPDATE.en.d.ts +2 -2
  888. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_UPDATE.en.d.ts.map +1 -1
  889. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_UPDATE.en.js +2 -2
  890. package/dist/esm/i18n/components/RESOURCES_LAYOUTS_UPDATE.en.js.map +1 -1
  891. package/dist/esm/i18n/components/guidance_announcement.en.d.ts.map +1 -1
  892. package/dist/esm/i18n/components/guidance_banner.en.d.ts +1 -1
  893. package/dist/esm/i18n/components/guidance_banner.en.d.ts.map +1 -1
  894. package/dist/esm/i18n/components/guidance_banner.en.js +1 -1
  895. package/dist/esm/i18n/components/guidance_banner.en.js.map +1 -1
  896. package/dist/esm/i18n/components/guidance_card.en.d.ts.map +1 -1
  897. package/dist/esm/i18n/components/guidance_checklist.en.d.ts +2 -2
  898. package/dist/esm/i18n/components/guidance_checklist.en.d.ts.map +1 -1
  899. package/dist/esm/i18n/components/guidance_checklist.en.js +2 -2
  900. package/dist/esm/i18n/components/guidance_checklist.en.js.map +1 -1
  901. package/dist/esm/i18n/components/guidance_checklist_item.en.d.ts +1 -0
  902. package/dist/esm/i18n/components/guidance_checklist_item.en.d.ts.map +1 -1
  903. package/dist/esm/i18n/components/guidance_checklist_item.en.js +2 -1
  904. package/dist/esm/i18n/components/guidance_checklist_item.en.js.map +1 -1
  905. package/dist/esm/i18n/components/guidance_modal.en.d.ts.map +1 -1
  906. package/dist/esm/i18n/components/guidance_onboarding_view.en.d.ts +1 -1
  907. package/dist/esm/i18n/components/guidance_onboarding_view.en.d.ts.map +1 -1
  908. package/dist/esm/i18n/components/guidance_onboarding_view.en.js +1 -1
  909. package/dist/esm/i18n/components/guidance_onboarding_view.en.js.map +1 -1
  910. package/dist/esm/i18n/components/guidance_survey.en.d.ts +1 -0
  911. package/dist/esm/i18n/components/guidance_survey.en.d.ts.map +1 -1
  912. package/dist/esm/i18n/components/guidance_survey.en.js +2 -1
  913. package/dist/esm/i18n/components/guidance_survey.en.js.map +1 -1
  914. package/dist/esm/i18n/components/guidance_tooltip.en.d.ts.map +1 -1
  915. package/dist/esm/i18n/components/guidance_tour.en.d.ts.map +1 -1
  916. package/dist/esm/i18n/components/progression_achievement_badge.en.d.ts +1 -1
  917. package/dist/esm/i18n/components/progression_achievement_badge.en.d.ts.map +1 -1
  918. package/dist/esm/i18n/components/progression_achievement_badge.en.js +1 -1
  919. package/dist/esm/i18n/components/progression_achievement_badge.en.js.map +1 -1
  920. package/dist/esm/i18n/components/progression_milestone_tracker.en.d.ts +5 -1
  921. package/dist/esm/i18n/components/progression_milestone_tracker.en.d.ts.map +1 -1
  922. package/dist/esm/i18n/components/progression_milestone_tracker.en.js +6 -2
  923. package/dist/esm/i18n/components/progression_milestone_tracker.en.js.map +1 -1
  924. package/dist/esm/i18n/composite_views/app.creation-board.en.d.ts +0 -13
  925. package/dist/esm/i18n/composite_views/app.creation-board.en.d.ts.map +0 -1
  926. package/dist/esm/i18n/composite_views/app.creation-board.en.js.map +0 -1
  927. package/dist/esm/i18n/composite_views/app.creation-conversation.en.d.ts +17 -0
  928. package/dist/esm/i18n/composite_views/app.creation-conversation.en.d.ts.map +1 -0
  929. package/dist/esm/i18n/composite_views/app.creation-conversation.en.js +252 -0
  930. package/dist/esm/i18n/composite_views/app.creation-conversation.en.js.map +1 -0
  931. package/dist/esm/i18n/composite_views/app.creation-dossier.en.d.ts +15 -0
  932. package/dist/esm/i18n/composite_views/app.creation-dossier.en.d.ts.map +1 -0
  933. package/dist/esm/i18n/composite_views/app.creation-dossier.en.js +58 -0
  934. package/dist/esm/i18n/composite_views/app.creation-dossier.en.js.map +1 -0
  935. package/dist/esm/i18n/composite_views/app.domain-model.en.d.ts.map +1 -1
  936. package/dist/esm/i18n/errors_messages/errors-messages.en.d.ts +96 -0
  937. package/dist/esm/i18n/errors_messages/errors-messages.en.d.ts.map +1 -0
  938. package/dist/esm/i18n/errors_messages/errors-messages.en.js +54 -0
  939. package/dist/esm/i18n/errors_messages/errors-messages.en.js.map +1 -0
  940. package/dist/esm/i18n/index.d.ts.map +1 -1
  941. package/dist/esm/i18n/resources/wildoApplicationActorSystemExecutions.en.d.ts +2014 -1
  942. package/dist/esm/i18n/resources/wildoApplicationActorSystemExecutions.en.d.ts.map +1 -1
  943. package/dist/esm/i18n/resources/wildoApplicationActorSystemExecutions.en.js +516 -0
  944. package/dist/esm/i18n/resources/wildoApplicationActorSystemExecutions.en.js.map +1 -1
  945. package/dist/esm/i18n/resources/wildoApplicationActorTasks.en.d.ts +878 -8
  946. package/dist/esm/i18n/resources/wildoApplicationActorTasks.en.d.ts.map +1 -1
  947. package/dist/esm/i18n/resources/wildoApplicationActorTasks.en.js +247 -0
  948. package/dist/esm/i18n/resources/wildoApplicationActorTasks.en.js.map +1 -1
  949. package/dist/esm/i18n/resources/wildoApplicationFlowSystemExecutions.en.d.ts +504 -1
  950. package/dist/esm/i18n/resources/wildoApplicationFlowSystemExecutions.en.d.ts.map +1 -1
  951. package/dist/esm/i18n/resources/wildoApplicationFlowSystemExecutions.en.js +153 -0
  952. package/dist/esm/i18n/resources/wildoApplicationFlowSystemExecutions.en.js.map +1 -1
  953. package/dist/esm/i18n/resources/workbenchAspects.en.d.ts +78 -0
  954. package/dist/esm/i18n/resources/workbenchAspects.en.d.ts.map +1 -0
  955. package/dist/esm/i18n/resources/workbenchAspects.en.js +255 -0
  956. package/dist/esm/i18n/resources/workbenchAspects.en.js.map +1 -0
  957. package/dist/esm/i18n/resources/workbenchBuildDispatchPlan.en.d.ts +149 -0
  958. package/dist/esm/i18n/resources/workbenchBuildDispatchPlan.en.d.ts.map +1 -0
  959. package/dist/esm/i18n/resources/workbenchBuildDispatchPlan.en.js +79 -0
  960. package/dist/esm/i18n/resources/workbenchBuildDispatchPlan.en.js.map +1 -0
  961. package/dist/esm/i18n/resources/workbenchBuildDispatches.en.d.ts +89 -0
  962. package/dist/esm/i18n/resources/workbenchBuildDispatches.en.d.ts.map +1 -0
  963. package/dist/esm/i18n/resources/workbenchBuildDispatches.en.js +74 -0
  964. package/dist/esm/i18n/resources/workbenchBuildDispatches.en.js.map +1 -0
  965. package/dist/esm/i18n/resources/workbenchBuildPlanTasks.en.d.ts +70 -5
  966. package/dist/esm/i18n/resources/workbenchBuildPlanTasks.en.d.ts.map +1 -1
  967. package/dist/esm/i18n/resources/workbenchBuildPlanTasks.en.js +67 -0
  968. package/dist/esm/i18n/resources/workbenchBuildPlanTasks.en.js.map +1 -1
  969. package/dist/esm/i18n/resources/workbenchCodingLaneStatus.en.d.ts +80 -0
  970. package/dist/esm/i18n/resources/workbenchCodingLaneStatus.en.d.ts.map +1 -0
  971. package/dist/esm/i18n/resources/workbenchCodingLaneStatus.en.js +50 -0
  972. package/dist/esm/i18n/resources/workbenchCodingLaneStatus.en.js.map +1 -0
  973. package/dist/esm/i18n/resources/workbenchCreationHomeLines.en.d.ts +95 -0
  974. package/dist/esm/i18n/resources/workbenchCreationHomeLines.en.d.ts.map +1 -0
  975. package/dist/esm/i18n/resources/workbenchCreationHomeLines.en.js +54 -0
  976. package/dist/esm/i18n/resources/workbenchCreationHomeLines.en.js.map +1 -0
  977. package/dist/esm/i18n/resources/workbenchCreationOutcomes.en.d.ts +95 -0
  978. package/dist/esm/i18n/resources/workbenchCreationOutcomes.en.d.ts.map +1 -0
  979. package/dist/esm/i18n/resources/workbenchCreationOutcomes.en.js +51 -0
  980. package/dist/esm/i18n/resources/workbenchCreationOutcomes.en.js.map +1 -0
  981. package/dist/esm/i18n/resources/workbenchDomainResources.en.d.ts +1 -1
  982. package/dist/esm/i18n/resources/workbenchDomainResources.en.d.ts.map +1 -1
  983. package/dist/esm/i18n/resources/workbenchDomainResources.en.js +2 -2
  984. package/dist/esm/i18n/resources/workbenchDomainResources.en.js.map +1 -1
  985. package/dist/esm/i18n/resources/workbenchDossierEntries.en.d.ts +108 -0
  986. package/dist/esm/i18n/resources/workbenchDossierEntries.en.d.ts.map +1 -0
  987. package/dist/esm/i18n/resources/workbenchDossierEntries.en.js +61 -0
  988. package/dist/esm/i18n/resources/workbenchDossierEntries.en.js.map +1 -0
  989. package/dist/esm/i18n/resources/workbenchGovernanceDocuments.en.d.ts +99 -0
  990. package/dist/esm/i18n/resources/workbenchGovernanceDocuments.en.d.ts.map +1 -0
  991. package/dist/esm/i18n/resources/workbenchGovernanceDocuments.en.js +87 -0
  992. package/dist/esm/i18n/resources/workbenchGovernanceDocuments.en.js.map +1 -0
  993. package/dist/esm/i18n/resources/workbenchGovernanceQuestions.en.d.ts +121 -0
  994. package/dist/esm/i18n/resources/workbenchGovernanceQuestions.en.d.ts.map +1 -0
  995. package/dist/esm/i18n/resources/workbenchGovernanceQuestions.en.js +84 -0
  996. package/dist/esm/i18n/resources/workbenchGovernanceQuestions.en.js.map +1 -0
  997. package/dist/esm/i18n/resources/workbenchParkedCodingQuestions.en.d.ts +83 -0
  998. package/dist/esm/i18n/resources/workbenchParkedCodingQuestions.en.d.ts.map +1 -0
  999. package/dist/esm/i18n/resources/workbenchParkedCodingQuestions.en.js +71 -0
  1000. package/dist/esm/i18n/resources/workbenchParkedCodingQuestions.en.js.map +1 -0
  1001. package/dist/esm/i18n/resources/workbenchPlaybookRuns.en.d.ts +159 -0
  1002. package/dist/esm/i18n/resources/workbenchPlaybookRuns.en.d.ts.map +1 -0
  1003. package/dist/esm/i18n/resources/workbenchPlaybookRuns.en.js +103 -0
  1004. package/dist/esm/i18n/resources/workbenchPlaybookRuns.en.js.map +1 -0
  1005. package/dist/esm/i18n/resources/workbenchPlaybooks.en.d.ts +142 -6
  1006. package/dist/esm/i18n/resources/workbenchPlaybooks.en.d.ts.map +1 -1
  1007. package/dist/esm/i18n/resources/workbenchPlaybooks.en.js +103 -0
  1008. package/dist/esm/i18n/resources/workbenchPlaybooks.en.js.map +1 -1
  1009. package/dist/esm/i18n/resources/workbenchRunWriteRecords.en.d.ts +94 -4
  1010. package/dist/esm/i18n/resources/workbenchRunWriteRecords.en.d.ts.map +1 -1
  1011. package/dist/esm/i18n/resources/workbenchRunWriteRecords.en.js +79 -0
  1012. package/dist/esm/i18n/resources/workbenchRunWriteRecords.en.js.map +1 -1
  1013. package/dist/esm/i18n/resources/workbenchSpecificationArtifacts.en.d.ts +5074 -257
  1014. package/dist/esm/i18n/resources/workbenchSpecificationArtifacts.en.d.ts.map +1 -1
  1015. package/dist/esm/i18n/resources/workbenchSpecificationArtifacts.en.js +1201 -44
  1016. package/dist/esm/i18n/resources/workbenchSpecificationArtifacts.en.js.map +1 -1
  1017. package/dist/esm/i18n/resources/workbenchTraceSessions.en.d.ts +86 -3
  1018. package/dist/esm/i18n/resources/workbenchTraceSessions.en.d.ts.map +1 -1
  1019. package/dist/esm/i18n/resources/workbenchTraceSessions.en.js +90 -0
  1020. package/dist/esm/i18n/resources/workbenchTraceSessions.en.js.map +1 -1
  1021. package/dist/esm/i18n/resources/workbenchWaitingPlaybookRuns.en.d.ts +97 -0
  1022. package/dist/esm/i18n/resources/workbenchWaitingPlaybookRuns.en.d.ts.map +1 -0
  1023. package/dist/esm/i18n/resources/workbenchWaitingPlaybookRuns.en.js +77 -0
  1024. package/dist/esm/i18n/resources/workbenchWaitingPlaybookRuns.en.js.map +1 -0
  1025. package/dist/esm/i18n/system_enums/application-creation.en.d.ts +272 -0
  1026. package/dist/esm/i18n/system_enums/application-creation.en.d.ts.map +1 -0
  1027. package/dist/esm/i18n/system_enums/application-creation.en.js +319 -0
  1028. package/dist/esm/i18n/system_enums/application-creation.en.js.map +1 -0
  1029. package/dist/esm/i18n/system_enums/compliance-programme.en.d.ts +154 -0
  1030. package/dist/esm/i18n/system_enums/compliance-programme.en.d.ts.map +1 -0
  1031. package/dist/esm/i18n/system_enums/compliance-programme.en.js +154 -0
  1032. package/dist/esm/i18n/system_enums/compliance-programme.en.js.map +1 -0
  1033. package/dist/esm/i18n/system_enums/flows-actors.en.d.ts +54 -0
  1034. package/dist/esm/i18n/system_enums/flows-actors.en.d.ts.map +1 -0
  1035. package/dist/esm/i18n/system_enums/flows-actors.en.js +54 -0
  1036. package/dist/esm/i18n/system_enums/flows-actors.en.js.map +1 -0
  1037. package/dist/esm/i18n/system_enums/market.en.d.ts +12 -2
  1038. package/dist/esm/i18n/system_enums/market.en.d.ts.map +1 -1
  1039. package/dist/esm/i18n/system_enums/market.en.js +12 -2
  1040. package/dist/esm/i18n/system_enums/market.en.js.map +1 -1
  1041. package/dist/esm/i18n/system_enums/processor-register.en.d.ts +43 -0
  1042. package/dist/esm/i18n/system_enums/processor-register.en.d.ts.map +1 -0
  1043. package/dist/esm/i18n/system_enums/processor-register.en.js +43 -0
  1044. package/dist/esm/i18n/system_enums/processor-register.en.js.map +1 -0
  1045. package/dist/esm/i18n/system_enums/risk-register.en.d.ts +56 -0
  1046. package/dist/esm/i18n/system_enums/risk-register.en.d.ts.map +1 -0
  1047. package/dist/esm/i18n/system_enums/risk-register.en.js +56 -0
  1048. package/dist/esm/i18n/system_enums/risk-register.en.js.map +1 -0
  1049. package/dist/esm/i18n/system_enums/workbench-build.en.d.ts +50 -0
  1050. package/dist/esm/i18n/system_enums/workbench-build.en.d.ts.map +1 -0
  1051. package/dist/esm/i18n/system_enums/workbench-build.en.js +55 -0
  1052. package/dist/esm/i18n/system_enums/workbench-build.en.js.map +1 -0
  1053. package/dist/esm/i18n/system_enums/workbench-creation-home.en.d.ts +47 -0
  1054. package/dist/esm/i18n/system_enums/workbench-creation-home.en.d.ts.map +1 -0
  1055. package/dist/esm/i18n/system_enums/workbench-creation-home.en.js +48 -0
  1056. package/dist/esm/i18n/system_enums/workbench-creation-home.en.js.map +1 -0
  1057. package/dist/esm/i18n/system_enums/workbench-dossier.en.d.ts +18 -0
  1058. package/dist/esm/i18n/system_enums/workbench-dossier.en.d.ts.map +1 -0
  1059. package/dist/esm/i18n/system_enums/workbench-dossier.en.js +18 -0
  1060. package/dist/esm/i18n/system_enums/workbench-dossier.en.js.map +1 -0
  1061. package/dist/esm/i18n/system_enums/workbench-playbook-run.en.d.ts +29 -0
  1062. package/dist/esm/i18n/system_enums/workbench-playbook-run.en.d.ts.map +1 -0
  1063. package/dist/esm/i18n/system_enums/workbench-playbook-run.en.js +29 -0
  1064. package/dist/esm/i18n/system_enums/workbench-playbook-run.en.js.map +1 -0
  1065. package/dist/esm/i18n/system_enums/workbench-specification-artifact.en.d.ts +24 -0
  1066. package/dist/esm/i18n/system_enums/workbench-specification-artifact.en.d.ts.map +1 -0
  1067. package/dist/esm/i18n/system_enums/workbench-specification-artifact.en.js +24 -0
  1068. package/dist/esm/i18n/system_enums/workbench-specification-artifact.en.js.map +1 -0
  1069. package/dist/esm/i18n-labelling/models/labelling-unit.models.d.ts +51 -3
  1070. package/dist/esm/i18n-labelling/models/labelling-unit.models.d.ts.map +1 -1
  1071. package/dist/esm/i18n-labelling/models/labelling-unit.models.js +36 -2
  1072. package/dist/esm/i18n-labelling/models/labelling-unit.models.js.map +1 -1
  1073. package/dist/esm/i18n-labelling/models/labelling.actors-system.definitions.d.ts.map +1 -1
  1074. package/dist/esm/i18n-labelling/models/labelling.actors-system.definitions.js.map +1 -1
  1075. package/dist/esm/i18n-labelling/services/component-labels-bootstrap.companion.service.d.ts.map +1 -1
  1076. package/dist/esm/i18n-labelling/services/labelling-planner.companion.service.d.ts +26 -16
  1077. package/dist/esm/i18n-labelling/services/labelling-planner.companion.service.d.ts.map +1 -1
  1078. package/dist/esm/i18n-labelling/services/labelling-planner.companion.service.js +167 -40
  1079. package/dist/esm/i18n-labelling/services/labelling-planner.companion.service.js.map +1 -1
  1080. package/dist/esm/i18n-labelling/services/labelling-spec-context-loader.companion.service.d.ts +8 -8
  1081. package/dist/esm/i18n-labelling/services/labelling-spec-context-loader.companion.service.d.ts.map +1 -1
  1082. package/dist/esm/i18n-labelling/services/labelling-spec-context-loader.companion.service.js +45 -39
  1083. package/dist/esm/i18n-labelling/services/labelling-spec-context-loader.companion.service.js.map +1 -1
  1084. package/dist/esm/i18n-labelling/services/labellize-orchestrator.companion.service.d.ts +104 -0
  1085. package/dist/esm/i18n-labelling/services/labellize-orchestrator.companion.service.d.ts.map +1 -1
  1086. package/dist/esm/i18n-labelling/services/labellize-orchestrator.companion.service.js +456 -16
  1087. package/dist/esm/i18n-labelling/services/labellize-orchestrator.companion.service.js.map +1 -1
  1088. package/dist/esm/i18n-labelling/services/translate-orchestrator.companion.service.d.ts.map +1 -1
  1089. package/dist/esm/i18n-labelling/services/translate-orchestrator.companion.service.js +30 -1
  1090. package/dist/esm/i18n-labelling/services/translate-orchestrator.companion.service.js.map +1 -1
  1091. package/dist/esm/i18n-labelling/utils/application-tone-of-voice.utils.d.ts +91 -0
  1092. package/dist/esm/i18n-labelling/utils/application-tone-of-voice.utils.d.ts.map +1 -0
  1093. package/dist/esm/i18n-labelling/utils/application-tone-of-voice.utils.js +149 -0
  1094. package/dist/esm/i18n-labelling/utils/application-tone-of-voice.utils.js.map +1 -0
  1095. package/dist/esm/i18n-labelling/utils/declared-refusal-codes.utils.d.ts +27 -0
  1096. package/dist/esm/i18n-labelling/utils/declared-refusal-codes.utils.d.ts.map +1 -0
  1097. package/dist/esm/i18n-labelling/utils/declared-refusal-codes.utils.js +44 -0
  1098. package/dist/esm/i18n-labelling/utils/declared-refusal-codes.utils.js.map +1 -0
  1099. package/dist/esm/i18n-labelling/utils/frontend-derived-label-keys.utils.d.ts +27 -0
  1100. package/dist/esm/i18n-labelling/utils/frontend-derived-label-keys.utils.d.ts.map +1 -1
  1101. package/dist/esm/i18n-labelling/utils/frontend-derived-label-keys.utils.js +27 -0
  1102. package/dist/esm/i18n-labelling/utils/frontend-derived-label-keys.utils.js.map +1 -1
  1103. package/dist/esm/i18n-labelling/utils/guidance-keys.utils.d.ts +12 -0
  1104. package/dist/esm/i18n-labelling/utils/guidance-keys.utils.d.ts.map +1 -1
  1105. package/dist/esm/i18n-labelling/utils/guidance-keys.utils.js +58 -1
  1106. package/dist/esm/i18n-labelling/utils/guidance-keys.utils.js.map +1 -1
  1107. package/dist/esm/i18n-labelling/utils/label-file-source.utils.d.ts.map +1 -1
  1108. package/dist/esm/i18n-labelling/utils/label-file-source.utils.js +19 -0
  1109. package/dist/esm/i18n-labelling/utils/label-file-source.utils.js.map +1 -1
  1110. package/dist/esm/i18n-labelling/utils/label-placeholder-drift.utils.d.ts.map +1 -1
  1111. package/dist/esm/i18n-labelling/utils/label-placeholder-drift.utils.js.map +1 -1
  1112. package/dist/esm/i18n-labelling/utils/orphan-label-artifacts.utils.d.ts.map +1 -1
  1113. package/dist/esm/i18n-labelling/utils/orphan-label-artifacts.utils.js.map +1 -1
  1114. package/dist/esm/i18n-labelling/utils/per-unit-file.utils.d.ts.map +1 -1
  1115. package/dist/esm/i18n-labelling/utils/per-unit-file.utils.js +10 -0
  1116. package/dist/esm/i18n-labelling/utils/per-unit-file.utils.js.map +1 -1
  1117. package/dist/esm/i18n-labelling/utils/role-lifecycle-keys.utils.d.ts.map +1 -1
  1118. package/dist/esm/i18n-labelling/utils/schema-fields-extractor.utils.d.ts +27 -24
  1119. package/dist/esm/i18n-labelling/utils/schema-fields-extractor.utils.d.ts.map +1 -1
  1120. package/dist/esm/i18n-labelling/utils/schema-fields-extractor.utils.js +176 -136
  1121. package/dist/esm/i18n-labelling/utils/schema-fields-extractor.utils.js.map +1 -1
  1122. package/dist/esm/i18n-labelling/utils/structured-chunk-completion.utils.d.ts +11 -0
  1123. package/dist/esm/i18n-labelling/utils/structured-chunk-completion.utils.d.ts.map +1 -1
  1124. package/dist/esm/i18n-labelling/utils/structured-chunk-completion.utils.js +27 -3
  1125. package/dist/esm/i18n-labelling/utils/structured-chunk-completion.utils.js.map +1 -1
  1126. package/dist/esm/i18n-labelling/utils/translate-locale-contract.utils.d.ts.map +1 -1
  1127. package/dist/esm/index.d.ts.map +1 -1
  1128. package/dist/esm/market/services/market-generation.companion.service.d.ts.map +1 -1
  1129. package/dist/esm/meta-workflows/models/application-build.actors-system.definitions.d.ts +29 -0
  1130. package/dist/esm/meta-workflows/models/application-build.actors-system.definitions.d.ts.map +1 -0
  1131. package/dist/esm/meta-workflows/models/application-build.actors-system.definitions.js +59 -0
  1132. package/dist/esm/meta-workflows/models/application-build.actors-system.definitions.js.map +1 -0
  1133. package/dist/esm/meta-workflows/models/application-coding-agent.actors-system.definitions.d.ts +35 -0
  1134. package/dist/esm/meta-workflows/models/application-coding-agent.actors-system.definitions.d.ts.map +1 -1
  1135. package/dist/esm/meta-workflows/models/application-coding-agent.actors-system.definitions.js +69 -3
  1136. package/dist/esm/meta-workflows/models/application-coding-agent.actors-system.definitions.js.map +1 -1
  1137. package/dist/esm/meta-workflows/models/application-research-agent.actors-system.definitions.d.ts.map +1 -1
  1138. package/dist/esm/meta-workflows/models/application-research-agent.actors-system.definitions.js +6 -4
  1139. package/dist/esm/meta-workflows/models/application-research-agent.actors-system.definitions.js.map +1 -1
  1140. package/dist/esm/meta-workflows/models/brief-adequacy.actors-system.definitions.d.ts +1 -0
  1141. package/dist/esm/meta-workflows/models/brief-adequacy.actors-system.definitions.d.ts.map +1 -1
  1142. package/dist/esm/meta-workflows/models/brief-adequacy.actors-system.definitions.js +21 -0
  1143. package/dist/esm/meta-workflows/models/brief-adequacy.actors-system.definitions.js.map +1 -1
  1144. package/dist/esm/meta-workflows/models/build-task-rearm.models.d.ts +46 -0
  1145. package/dist/esm/meta-workflows/models/build-task-rearm.models.d.ts.map +1 -0
  1146. package/dist/esm/meta-workflows/models/build-task-rearm.models.js +43 -0
  1147. package/dist/esm/meta-workflows/models/build-task-rearm.models.js.map +1 -0
  1148. package/dist/esm/meta-workflows/models/carried-verification-failure.models.d.ts +34 -0
  1149. package/dist/esm/meta-workflows/models/carried-verification-failure.models.d.ts.map +1 -0
  1150. package/dist/esm/meta-workflows/models/carried-verification-failure.models.js +59 -0
  1151. package/dist/esm/meta-workflows/models/carried-verification-failure.models.js.map +1 -0
  1152. package/dist/esm/meta-workflows/models/composite-round-relaunch.models.d.ts +65 -0
  1153. package/dist/esm/meta-workflows/models/composite-round-relaunch.models.d.ts.map +1 -0
  1154. package/dist/esm/meta-workflows/models/composite-round-relaunch.models.js +83 -0
  1155. package/dist/esm/meta-workflows/models/composite-round-relaunch.models.js.map +1 -0
  1156. package/dist/esm/meta-workflows/models/meta-workflows-lane.models.d.ts +69 -7
  1157. package/dist/esm/meta-workflows/models/meta-workflows-lane.models.d.ts.map +1 -1
  1158. package/dist/esm/meta-workflows/models/meta-workflows-lane.models.js +70 -7
  1159. package/dist/esm/meta-workflows/models/meta-workflows-lane.models.js.map +1 -1
  1160. package/dist/esm/meta-workflows/models/meta-workflows.actors-system.definitions.d.ts.map +1 -1
  1161. package/dist/esm/meta-workflows/models/meta-workflows.actors-system.definitions.js +27 -5
  1162. package/dist/esm/meta-workflows/models/meta-workflows.actors-system.definitions.js.map +1 -1
  1163. package/dist/esm/meta-workflows/models/playbook-run-checkpoint.models.d.ts +208 -0
  1164. package/dist/esm/meta-workflows/models/playbook-run-checkpoint.models.d.ts.map +1 -0
  1165. package/dist/esm/meta-workflows/models/playbook-run-checkpoint.models.js +273 -0
  1166. package/dist/esm/meta-workflows/models/playbook-run-checkpoint.models.js.map +1 -0
  1167. package/dist/esm/meta-workflows/models/playbook-run-record.models.d.ts +356 -0
  1168. package/dist/esm/meta-workflows/models/playbook-run-record.models.d.ts.map +1 -0
  1169. package/dist/esm/meta-workflows/models/playbook-run-record.models.js +417 -0
  1170. package/dist/esm/meta-workflows/models/playbook-run-record.models.js.map +1 -0
  1171. package/dist/esm/meta-workflows/models/playbook-step-schema-namespaces.models.d.ts +14 -0
  1172. package/dist/esm/meta-workflows/models/playbook-step-schema-namespaces.models.d.ts.map +1 -0
  1173. package/dist/esm/meta-workflows/models/playbook-step-schema-namespaces.models.js +21 -0
  1174. package/dist/esm/meta-workflows/models/playbook-step-schema-namespaces.models.js.map +1 -0
  1175. package/dist/esm/meta-workflows/services/__tests__/application-build-task-coding.companion.test-fixtures.d.ts.map +1 -1
  1176. package/dist/esm/meta-workflows/services/__tests__/application-build-task-coding.companion.test-fixtures.js +3 -1
  1177. package/dist/esm/meta-workflows/services/__tests__/application-build-task-coding.companion.test-fixtures.js.map +1 -1
  1178. package/dist/esm/meta-workflows/services/__tests__/support/in-memory-actor-plane.d.ts +65 -0
  1179. package/dist/esm/meta-workflows/services/__tests__/support/in-memory-actor-plane.d.ts.map +1 -0
  1180. package/dist/esm/meta-workflows/services/__tests__/support/in-memory-actor-plane.js +148 -0
  1181. package/dist/esm/meta-workflows/services/__tests__/support/in-memory-actor-plane.js.map +1 -0
  1182. package/dist/esm/meta-workflows/services/application-build-dispatch.companion.service.d.ts +929 -51
  1183. package/dist/esm/meta-workflows/services/application-build-dispatch.companion.service.d.ts.map +1 -1
  1184. package/dist/esm/meta-workflows/services/application-build-dispatch.companion.service.js +2047 -146
  1185. package/dist/esm/meta-workflows/services/application-build-dispatch.companion.service.js.map +1 -1
  1186. package/dist/esm/meta-workflows/services/application-build-generation-step.companion.service.d.ts +115 -36
  1187. package/dist/esm/meta-workflows/services/application-build-generation-step.companion.service.d.ts.map +1 -1
  1188. package/dist/esm/meta-workflows/services/application-build-generation-step.companion.service.js +270 -47
  1189. package/dist/esm/meta-workflows/services/application-build-generation-step.companion.service.js.map +1 -1
  1190. package/dist/esm/meta-workflows/services/application-build-task-coding-policy.companion.service.d.ts +402 -16
  1191. package/dist/esm/meta-workflows/services/application-build-task-coding-policy.companion.service.d.ts.map +1 -1
  1192. package/dist/esm/meta-workflows/services/application-build-task-coding-policy.companion.service.js +1398 -70
  1193. package/dist/esm/meta-workflows/services/application-build-task-coding-policy.companion.service.js.map +1 -1
  1194. package/dist/esm/meta-workflows/services/application-maturity-executor.companion.service.d.ts +47 -0
  1195. package/dist/esm/meta-workflows/services/application-maturity-executor.companion.service.d.ts.map +1 -0
  1196. package/dist/esm/meta-workflows/services/application-maturity-executor.companion.service.js +103 -0
  1197. package/dist/esm/meta-workflows/services/application-maturity-executor.companion.service.js.map +1 -0
  1198. package/dist/esm/meta-workflows/services/build-plan-authoring.companion.service.d.ts +29 -0
  1199. package/dist/esm/meta-workflows/services/build-plan-authoring.companion.service.d.ts.map +1 -0
  1200. package/dist/esm/meta-workflows/services/build-plan-authoring.companion.service.js +88 -0
  1201. package/dist/esm/meta-workflows/services/build-plan-authoring.companion.service.js.map +1 -0
  1202. package/dist/esm/meta-workflows/services/capability-composition-executor.companion.service.d.ts +47 -0
  1203. package/dist/esm/meta-workflows/services/capability-composition-executor.companion.service.d.ts.map +1 -0
  1204. package/dist/esm/meta-workflows/services/capability-composition-executor.companion.service.js +102 -0
  1205. package/dist/esm/meta-workflows/services/capability-composition-executor.companion.service.js.map +1 -0
  1206. package/dist/esm/meta-workflows/services/creator-inputs.companion.service.d.ts +0 -0
  1207. package/dist/esm/meta-workflows/services/creator-inputs.companion.service.d.ts.map +0 -0
  1208. package/dist/esm/meta-workflows/services/creator-inputs.companion.service.js.map +0 -0
  1209. package/dist/esm/meta-workflows/services/dossier.companion.service.d.ts +81 -0
  1210. package/dist/esm/meta-workflows/services/dossier.companion.service.d.ts.map +1 -0
  1211. package/dist/esm/meta-workflows/services/dossier.companion.service.js +231 -0
  1212. package/dist/esm/meta-workflows/services/dossier.companion.service.js.map +1 -0
  1213. package/dist/esm/meta-workflows/services/engine-settings-destination-catalog.companion.d.ts +36 -0
  1214. package/dist/esm/meta-workflows/services/engine-settings-destination-catalog.companion.d.ts.map +1 -0
  1215. package/dist/esm/meta-workflows/services/engine-settings-destination-catalog.companion.js +72 -0
  1216. package/dist/esm/meta-workflows/services/engine-settings-destination-catalog.companion.js.map +1 -0
  1217. package/dist/esm/meta-workflows/services/execution-trace-read.companion.service.d.ts +82 -1
  1218. package/dist/esm/meta-workflows/services/execution-trace-read.companion.service.d.ts.map +1 -1
  1219. package/dist/esm/meta-workflows/services/execution-trace-read.companion.service.js +200 -31
  1220. package/dist/esm/meta-workflows/services/execution-trace-read.companion.service.js.map +1 -1
  1221. package/dist/esm/meta-workflows/services/external-authentication-brief.companion.utils.d.ts +16 -0
  1222. package/dist/esm/meta-workflows/services/external-authentication-brief.companion.utils.d.ts.map +1 -0
  1223. package/dist/esm/meta-workflows/services/external-authentication-brief.companion.utils.js +29 -0
  1224. package/dist/esm/meta-workflows/services/external-authentication-brief.companion.utils.js.map +1 -0
  1225. package/dist/esm/meta-workflows/services/foundation-executor.companion.service.d.ts +196 -1
  1226. package/dist/esm/meta-workflows/services/foundation-executor.companion.service.d.ts.map +1 -1
  1227. package/dist/esm/meta-workflows/services/foundation-executor.companion.service.js +380 -10
  1228. package/dist/esm/meta-workflows/services/foundation-executor.companion.service.js.map +1 -1
  1229. package/dist/esm/meta-workflows/services/landed-module-import.companion.d.ts +2 -0
  1230. package/dist/esm/meta-workflows/services/landed-module-import.companion.d.ts.map +1 -0
  1231. package/dist/esm/meta-workflows/services/landed-module-import.companion.js +36 -0
  1232. package/dist/esm/meta-workflows/services/landed-module-import.companion.js.map +1 -0
  1233. package/dist/esm/meta-workflows/services/playbook-execution-trace.companion.service.d.ts.map +1 -1
  1234. package/dist/esm/meta-workflows/services/playbook-run-write-register.companion.service.d.ts +57 -0
  1235. package/dist/esm/meta-workflows/services/playbook-run-write-register.companion.service.d.ts.map +1 -1
  1236. package/dist/esm/meta-workflows/services/playbook-run-write-register.companion.service.js +83 -3
  1237. package/dist/esm/meta-workflows/services/playbook-run-write-register.companion.service.js.map +1 -1
  1238. package/dist/esm/meta-workflows/services/playbook-run.companion.service.d.ts +949 -177
  1239. package/dist/esm/meta-workflows/services/playbook-run.companion.service.d.ts.map +1 -1
  1240. package/dist/esm/meta-workflows/services/playbook-run.companion.service.js +3151 -454
  1241. package/dist/esm/meta-workflows/services/playbook-run.companion.service.js.map +1 -1
  1242. package/dist/esm/meta-workflows/services/playbook-spend-meter.companion.service.d.ts +100 -0
  1243. package/dist/esm/meta-workflows/services/playbook-spend-meter.companion.service.d.ts.map +1 -0
  1244. package/dist/esm/meta-workflows/services/playbook-spend-meter.companion.service.js +156 -0
  1245. package/dist/esm/meta-workflows/services/playbook-spend-meter.companion.service.js.map +1 -0
  1246. package/dist/esm/meta-workflows/services/schema-plan-freshness-loop.companion.d.ts +49 -0
  1247. package/dist/esm/meta-workflows/services/schema-plan-freshness-loop.companion.d.ts.map +1 -0
  1248. package/dist/esm/meta-workflows/services/schema-plan-freshness-loop.companion.js +93 -0
  1249. package/dist/esm/meta-workflows/services/schema-plan-freshness-loop.companion.js.map +1 -0
  1250. package/dist/esm/meta-workflows/utils/unified-diff.companion.utils.d.ts +45 -0
  1251. package/dist/esm/meta-workflows/utils/unified-diff.companion.utils.d.ts.map +1 -0
  1252. package/dist/esm/meta-workflows/utils/unified-diff.companion.utils.js +145 -0
  1253. package/dist/esm/meta-workflows/utils/unified-diff.companion.utils.js.map +1 -0
  1254. package/dist/esm/technical-doc/services/technical-doc.companion.service.d.ts +33 -9
  1255. package/dist/esm/technical-doc/services/technical-doc.companion.service.d.ts.map +1 -1
  1256. package/dist/esm/technical-doc/services/technical-doc.companion.service.js +70 -29
  1257. package/dist/esm/technical-doc/services/technical-doc.companion.service.js.map +1 -1
  1258. package/dist/esm/technical-doc/services/technical-documentation-application-derivation.companion.service.d.ts +20 -5
  1259. package/dist/esm/technical-doc/services/technical-documentation-application-derivation.companion.service.d.ts.map +1 -1
  1260. package/dist/esm/technical-doc/services/technical-documentation-application-derivation.companion.service.js +38 -16
  1261. package/dist/esm/technical-doc/services/technical-documentation-application-derivation.companion.service.js.map +1 -1
  1262. package/dist/esm/technical-doc/services/technical-documentation-environment-identity.companion.service.d.ts.map +1 -1
  1263. package/dist/esm/technical-doc/services/technical-documentation-pilot-assets.companion.service.d.ts.map +1 -1
  1264. package/dist/esm/technical-doc/services/technical-documentation-pilot.companion.service.d.ts.map +1 -1
  1265. package/dist/esm/technical-doc/services/technical-documentation-pilot.companion.service.js.map +1 -1
  1266. package/package.json +18 -18
  1267. package/dist/esm/i18n/composite_views/app.creation-board.en.js +0 -91
  1268. package/dist/esm/meta-workflows/services/playbook-choreography-checkpoint.companion.service.d.ts +0 -92
  1269. package/dist/esm/meta-workflows/services/playbook-choreography-checkpoint.companion.service.d.ts.map +0 -1
  1270. package/dist/esm/meta-workflows/services/playbook-choreography-checkpoint.companion.service.js +0 -178
  1271. package/dist/esm/meta-workflows/services/playbook-choreography-checkpoint.companion.service.js.map +0 -1
  1272. package/dist/esm/meta-workflows/services/playbook-suspended-run.companion.service.d.ts +0 -107
  1273. package/dist/esm/meta-workflows/services/playbook-suspended-run.companion.service.d.ts.map +0 -1
  1274. package/dist/esm/meta-workflows/services/playbook-suspended-run.companion.service.js +0 -188
  1275. package/dist/esm/meta-workflows/services/playbook-suspended-run.companion.service.js.map +0 -1
@@ -15,10 +15,12 @@ import { join, resolve } from 'node:path';
15
15
  import { fileURLToPath } from 'node:url';
16
16
  import { inject, injectable } from 'inversify';
17
17
  import { SAAS_SERVICE_TYPES } from '@wildo-ai/saas-backend-lib';
18
+ import { AppFrontendType } from '@wildo-ai/saas-models';
18
19
  import { AppLibraryType, resolvePackageCompanionEntryPath } from '@wildo-ai/platform-config-lib';
19
20
  import { CompanionIntrospectionResultSchema } from '../../../companion-api/companion-api.schemas.js';
20
21
  import { CompanionIntrospectionBehaviorRegistryService } from './companion-introspection-behavior-registry.companion.service.js';
21
22
  import { IntrospectionDerivationStateCompanionService } from './introspection-derivation-state.companion.service.js';
23
+ import { IntrospectionInputValidationError } from '../models/companion-introspection.models.js';
22
24
  import { COMPANION_SERVICE_TYPES } from '../../inject/models/service-types.js';
23
25
  const DEFAULT_MAX_CONCURRENCY = 4;
24
26
  /**
@@ -305,13 +307,16 @@ let CompanionIntrospectionService = class CompanionIntrospectionService {
305
307
  description: definition.description,
306
308
  category: definition.category,
307
309
  supportedServiceKinds: definition.supportedServiceKinds,
310
+ ...(definition.inputSummary !== undefined ? { inputSummary: definition.inputSummary } : {}),
308
311
  }));
309
312
  const serviceKeys = Object.entries(this.companionContext.servicesByKey).map(([key, service]) => ({
310
313
  key,
311
314
  kind: this.resolveServiceKind(service),
315
+ ...(service.frontendType !== undefined ? { frontendType: String(service.frontendType) } : {}),
312
316
  }));
313
317
  const defaultBackendServiceKey = serviceKeys.find((service) => service.kind === 'backend')?.key ?? null;
314
- return { behaviors, serviceKeys, defaultBackendServiceKey };
318
+ const defaultFrontendServiceKey = serviceKeys.find((service) => service.frontendType === AppFrontendType.SAAS_APP)?.key ?? null;
319
+ return { behaviors, serviceKeys, defaultBackendServiceKey, defaultFrontendServiceKey };
315
320
  }
316
321
  async requestInfo(request) {
317
322
  const resolvedTarget = await this.resolveTarget(request);
@@ -397,7 +402,18 @@ let CompanionIntrospectionService = class CompanionIntrospectionService {
397
402
  async resolveTarget(request) {
398
403
  const serviceDefinition = this.companionContext.servicesByKey[request.serviceKey];
399
404
  if (!serviceDefinition) {
400
- throw new Error(`Unknown SaaS service key "${request.serviceKey}".`);
405
+ /*
406
+ * A caller's bad input, so it must answer 4xx CARRYING ITS MESSAGE — the same contract
407
+ * `IntrospectionInputValidationError` was introduced for (#1459). A plain `Error` here is
408
+ * sanitized to a bodyless 500, and the CLI's health hint then fires on a companion that is
409
+ * demonstrably up, sending the reader to check a process instead of their own argument.
410
+ *
411
+ * The likeliest way to get here is passing a service NAME where the key is wanted
412
+ * (`--service scratch-journey-app` for the service keyed `app`), which is why the valid keys
413
+ * are named rather than merely the rejected one.
414
+ */
415
+ throw new IntrospectionInputValidationError(`Unknown SaaS service key "${request.serviceKey}". This application declares: `
416
+ + `${Object.keys(this.companionContext.servicesByKey).sort().map((key) => `"${key}"`).join(', ')}.`);
401
417
  }
402
418
  const serviceKind = this.resolveServiceKind(serviceDefinition);
403
419
  const resolvedBehavior = this.behaviorRegistryService.resolveBehaviorForServiceKind(request.behavior, serviceKind);
@@ -406,7 +422,9 @@ let CompanionIntrospectionService = class CompanionIntrospectionService {
406
422
  .filter((targetId, index, allTargetIds) => allTargetIds.indexOf(targetId) === index)
407
423
  .filter((targetId) => !resolvedTargets[targetId]);
408
424
  if (missingTargets.length > 0) {
409
- throw new Error(`Behavior "${request.behavior}" requires config-declared target(s) ${missingTargets.map((targetId) => `"${targetId}"`).join(', ')}, but they are not declared or resolvable for service "${request.serviceKey}".`);
425
+ // Also the caller's: they named a service that cannot serve this behavior, and the message
426
+ // says which targets are missing — so it must survive sanitization like the key above.
427
+ throw new IntrospectionInputValidationError(`Behavior "${request.behavior}" requires config-declared target(s) ${missingTargets.map((targetId) => `"${targetId}"`).join(', ')}, but they are not declared or resolvable for service "${request.serviceKey}".`);
410
428
  }
411
429
  const behaviorTarget = resolvedTargets[resolvedBehavior.route.target];
412
430
  const servicePath = resolve(this.companionContext.saasRoot, serviceDefinition.path);
@@ -1 +1 @@
1
- {"version":3,"file":"companion-introspection.companion.service.js","sourceRoot":"","sources":["../../../../../src/core/introspection/services/companion-introspection.companion.service.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,oBAAoB,CAAC;AAC3C,OAAO,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAC1C,OAAO,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AACzC,OAAO,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,WAAW,CAAC;AAE/C,OAAO,EAAE,kBAAkB,EAAE,MAAM,4BAA4B,CAAC;AAChE,OAAO,EAAE,cAAc,EAAE,gCAAgC,EAAE,MAAM,+BAA+B,CAAC;AACjG,OAAO,EAAE,kCAAkC,EAAE,MAAM,8CAA8C,CAAC;AAElG,OAAO,EAAE,6CAA6C,EAAE,MAAM,+DAA+D,CAAC;AAC9H,OAAO,EAAE,4CAA4C,EAAE,MAAM,oDAAoD,CAAC;AAalH,OAAO,EAAE,uBAAuB,EAAE,MAAM,mCAAmC,CAAC;AAE5E,MAAM,uBAAuB,GAAG,CAAC,CAAC;AAElC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAwCG;AACH,MAAM,kBAAkB,GAAG,OAAO,CAAC;AAEnC;;;;;;;GAOG;AACH,MAAM,4BAA4B,GAAG,IAAI,GAAG,CAAS,CAAC,SAAS,EAAE,QAAQ,EAAE,QAAQ,CAAC,CAAC,CAAC;AAEtF;;;;;;;;;;;;;;GAcG;AACH,MAAM,UAAU,wBAAwB,CAAC,KAIxC;IACC,IAAI,KAAK,CAAC,iBAAiB,IAAI,KAAK,CAAC,eAAe;QAAE,OAA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,kBAAkB,CACxB,MAA4C,EAC5C,SAAiB,EACjB,KAAyC;QAEzC,OAAO;YACL,OAAO,EAAE,KAAK;YACd,QAAQ,EAAE,MAAM,CAAC,QAAQ;YACzB,UAAU,EAAE,MAAM,CAAC,UAAU;YAC7B,WAAW,EAAE,MAAM,CAAC,WAAW;YAC/B,gBAAgB,EAAE,MAAM,CAAC,gBAAgB;YACzC,mBAAmB,EAAE,MAAM,CAAC,mBAAmB;YAC/C,QAAQ,EAAE,MAAM,CAAC,QAAQ;YACzB,UAAU,EAAE,IAAI,CAAC,GAAG,EAAE,GAAG,SAAS;YAClC,KAAK;SACN,CAAC;IACJ,CAAC;CACF,CAAA;AAxoBY,6BAA6B;IADzC,UAAU,EAAE;IAoBR,WAAA,MAAM,CAAC,kBAAkB,CAAC,MAAM,CAAC,CAAA;IACjC,WAAA,MAAM,CAAC,uBAAuB,CAAC,gBAAgB,CAAC,CAAA;IAChD,WAAA,MAAM,CAAC,uBAAuB,CAAC,oCAAoC,CAAC,CAAA;IAEpE,WAAA,MAAM,CAAC,uBAAuB,CAAC,mCAAmC,CAAC,CAAA;uDAD1B,6CAA6C;QAErD,4CAA4C;GAxBrE,6BAA6B,CAwoBzC","sourcesContent":["import { spawn } from 'node:child_process';\nimport { join, resolve } from 'node:path';\nimport { fileURLToPath } from 'node:url';\nimport { inject, injectable } from 'inversify';\nimport type { LoggerService } from '@wildo-ai/saas-backend-lib';\nimport { SAAS_SERVICE_TYPES } from '@wildo-ai/saas-backend-lib';\nimport { AppLibraryType, resolvePackageCompanionEntryPath } from '@wildo-ai/platform-config-lib';\nimport { CompanionIntrospectionResultSchema } from '../../../companion-api/companion-api.schemas';\nimport type { CompanionContext } from '../../context/companion-context';\nimport { CompanionIntrospectionBehaviorRegistryService } from './companion-introspection-behavior-registry.companion.service';\nimport { IntrospectionDerivationStateCompanionService } from './introspection-derivation-state.companion.service';\nimport type {\n CompanionIntrospectionChildRequest,\n CompanionIntrospectionErrorDetails,\n CompanionIntrospectionFailureResult,\n CompanionIntrospectionHomesSnapshot,\n CompanionIntrospectionRequest,\n CompanionIntrospectionResolvedPackageTarget,\n CompanionIntrospectionResolvedTarget,\n CompanionIntrospectionResult,\n CompanionIntrospectionRouteTargetId,\n CompanionIntrospectionServiceKind,\n} from '../models/companion-introspection.models';\nimport { COMPANION_SERVICE_TYPES } from '../../inject/models/service-types';\n\nconst DEFAULT_MAX_CONCURRENCY = 4;\n\n/**\n * How long one introspection subprocess may run before it is killed and reported as a timeout.\n *\n * ## This bounds a HANG. It is not a latency budget.\n *\n * A child that answers slowly is still answering; the only thing this ceiling exists to catch is a\n * child that will never answer. So it must sit comfortably ABOVE the most expensive legitimate read,\n * and the cost of setting it too low is far worse than the cost of setting it too high: an\n * over-tight ceiling does not slow a playbook down, it makes the playbook permanently unable to run.\n *\n * ## Measured 2026-09-09 on `examples/wonder-todos`, and why 30s had to go\n *\n * It was `30_000` — an unjustified round number — and every `specifications`-target behavior a\n * `workspace_truth` playbook assembles EXCEEDED it, deterministically. Timing the child directly,\n * with nothing but the dev stack competing:\n *\n * | behavior | target | measured |\n * |---|---|---|\n * | `expert-persona-charters` | specifications | 11.5s |\n * | `expert-persona-derivation-inputs` | specifications | 13.5s |\n * | `specification-artifacts` | specifications | **30.6s** |\n * | `application-domain-model` | specifications | **35.3s** |\n *\n * The consequence was not an intermittent flake. `bottom_up.placement-plan` — and anything else\n * declaring `contextSources: ['workspace_truth']` — watched every one of its context reads fail at\n * exactly 30s intervals (`specification-artifacts`, `family-aspects`, `frontend-labels-needed-info`,\n * `openapi-generation-input`, …), assembled an empty brief, and could not complete. It read as a\n * `500 INTERNAL / critical`, which sends a reader looking for a bug in the behavior rather than at\n * the clock.\n *\n * ## Why 120s\n *\n * ~3.4x headroom over the worst measurement, because a developer machine mid-compile-storm is\n * materially slower than one that is idle, and this is the machine every one of these reads runs on.\n * A genuinely hung child is still detected and still reported — two minutes later instead of thirty\n * seconds, which nobody is waiting on interactively.\n *\n * Re-measure before lowering this: the cost is dominated by importing a real application's compiled\n * `specifications` package and the engine graph behind it, so it grows with the application. A\n * deployment that wants a tighter bound sets `COMPANION_INTROSPECTION_TIMEOUT_MS`.\n */\nconst DEFAULT_TIMEOUT_MS = 120_000;\n\n/**\n * The signals that mean SOMEONE ELSE stopped this process tree.\n *\n * Read only in the exit branch that has already established this service sent no kill of its own, so\n * membership here is what separates \"the companion is going down\" from \"the derivation failed\".\n * `SIGKILL` is deliberately absent: it is what this service's own force-kill escalation sends, and a\n * child that reaches it has already been through `requestTermination`.\n */\nconst EXTERNAL_TERMINATION_SIGNALS = new Set<string>(['SIGTERM', 'SIGINT', 'SIGHUP']);\n\n/**\n * Whether a dead introspection child was killed by SOMEONE OTHER than this service.\n *\n * Exported because it is the whole decision — the call site is one branch — and because it is the\n * part worth pinning: the plumbing around it needs a real subprocess and a real signal, while the\n * reasoning is three booleans.\n *\n * The inference rests on an invariant of this file: every termination this service performs goes\n * through `requestTermination`, which sets a pending failure BEFORE killing, and the exit handler\n * returns that failure without consulting this. So a termination signal arriving with no pending\n * failure and no parsed result means nobody here asked — the child died because its PARENT did,\n * taking the process group with it. If a future kill path forgets to set the pending failure first,\n * this starts misreporting a local kill as an external one, which is why the invariant is stated\n * here rather than left implicit at the call site.\n */\nexport function wasTerminatedFromOutside(input: {\n readonly signal: string | null;\n readonly hasPendingFailure: boolean;\n readonly hasParsedResult: boolean;\n}): boolean {\n if (input.hasPendingFailure || input.hasParsedResult) return false;\n return input.signal !== null && EXTERNAL_TERMINATION_SIGNALS.has(input.signal);\n}\n\n/**\n * Env value that turns the derivation cache off entirely.\n *\n * Read once at construction. A door rather than a design: if the cache is ever suspected of serving\n * a stale answer, an operator can settle the question in one restart instead of reasoning about the\n * invalidation, and the diagnosis stays about the application rather than about this file. The\n * default is ON — the whole point is that the workbench stops paying a cold transpile per request.\n */\nconst DISABLE_DERIVATION_CACHE_VALUE = 'off';\n\n/**\n * Env-var namespaces stripped from the spawned introspection child's\n * environment so pre-bootstrap reads surface `undefined` instead of inheriting\n * stale values from the parent shell.\n *\n * The trusted homes snapshot is delivered through the IPC handshake and\n * reapplied by `applyTrustedHomesToChildProcess()` as the first action of\n * `handleChildProcessMessage()`. Any code that happens to read these env\n * vars during the narrow window BEFORE that handler runs (for example while\n * `reflect-metadata` is loading) would otherwise see whatever the parent\n * shell had set — including stale values from a previous companion run or\n * from the operator's shell — which would reintroduce the Phase 5\n * \"env-over-context\" class of regression at the subprocess boundary.\n *\n * `WILDO_COMPANION_INTROSPECTION_CHILD` is the intentional child-mode flag\n * and is re-injected fresh for every spawn.\n */\nexport const SCRUBBED_CHILD_ENV_NAMES = [\n 'COMPANION_WORKSPACE_ROOT',\n 'COMPANION_RUNTIME_HOME',\n 'COMPANION_PACKAGE_ROOT',\n 'COMPANION_FRAMEWORK_ROOT',\n 'WILDO_COMPANION_INTROSPECTION_CHILD',\n] as const;\n\n/**\n * Render an arbitrary behavior `input` so that two structurally equal inputs produce one key.\n *\n * `JSON.stringify` alone would not: `{a:1,b:2}` and `{b:2,a:1}` are the same question and would\n * occupy two cache entries, so the second phrasing of a question would always miss. Object keys are\n * therefore sorted at every depth. Arrays keep their order, because in an input an array's order is\n * part of the question.\n *\n * A value that cannot be rendered — a cycle, a `BigInt` — yields `null`, which the caller reads as\n * \"this question is not cacheable\" rather than as an error. Nothing in the current behavior surface\n * sends such an input; treating it as uncacheable rather than throwing keeps a future one working.\n */\nexport function renderStableCacheableInput(input: unknown): string | null {\n const seen = new WeakSet<object>();\n\n const render = (value: unknown): string => {\n if (value === undefined) return 'undefined';\n if (value === null) return 'null';\n if (typeof value === 'bigint') throw new Error('BigInt is not renderable.');\n if (typeof value !== 'object') return JSON.stringify(value) ?? 'undefined';\n if (seen.has(value as object)) throw new Error('Cyclic input is not renderable.');\n seen.add(value as object);\n if (Array.isArray(value)) {\n return `[${value.map(render).join(',')}]`;\n }\n const entries = Object.entries(value as Record<string, unknown>)\n .filter(([, entryValue]) => entryValue !== undefined)\n .sort(([left], [right]) => (left < right ? -1 : left > right ? 1 : 0));\n return `{${entries.map(([key, entryValue]) => `${JSON.stringify(key)}:${render(entryValue)}`).join(',')}}`;\n };\n\n try {\n return render(input);\n } catch {\n return null;\n }\n}\n\n/**\n * The identity of a derivation on the REQUEST side.\n *\n * Everything the child is given that can change its answer: which service, which behavior, which\n * target it routes to, and the behavior input. `entryPath` and `packageRoot` are included because a\n * package whose built `./companion` export appears or disappears changes which bytes are imported\n * without changing the behavior id — and `resolvePackageCompanionEntryPath` prefers `dist` when it\n * exists and falls back to source when it does not.\n *\n * Returns `null` for an input that cannot be stably rendered, which the caller reads as\n * \"derive, do not remember\".\n */\nfunction buildDerivationCacheKey(target: CompanionIntrospectionResolvedTarget): string | null {\n const renderedInput = renderStableCacheableInput(target.input);\n if (renderedInput === null) return null;\n\n return [\n target.serviceKey,\n target.serviceKind,\n target.behavior,\n target.targetId,\n target.packageRoot,\n target.entryPath,\n renderedInput,\n ].join('\\u0001');\n}\n\n/**\n * Build the `env` object handed to the spawned introspection child process.\n *\n * Responsibilities:\n *\n * 1. Inherit the caller's `process.env` as a base, so the child still sees\n * normal environment (`PATH`, `NODE_OPTIONS`, node-debug flags, etc.).\n * 2. Scrub every `COMPANION_*` bootstrap seed that\n * `applyTrustedHomesToChildProcess()` owns on the child side. Leaving\n * them in place would let `reflect-metadata` (or anything else imported\n * before the first IPC message arrives) read a stale value from the\n * parent shell — the exact Phase 5 \"env-over-context\" regression class\n * this slice was introduced to close.\n * 3. Drop any pre-existing `WILDO_COMPANION_INTROSPECTION_CHILD` so it\n * cannot survive from a parent that was itself a child in a nested\n * spawn, then re-inject it as the exact string `'1'`. The child's\n * `shouldRegisterChildMessageHandler()` gate only accepts `'1'`, so\n * this is also the enforcement point that keeps the flag's contract\n * single-sourced here.\n *\n * Exported purely for unit testing; production code reaches it through\n * `this.runSubprocess(...)` in `CompanionIntrospectionService`.\n */\nexport function buildSubprocessEnv(): NodeJS.ProcessEnv {\n const scrubbed: NodeJS.ProcessEnv = { ...process.env };\n for (const key of SCRUBBED_CHILD_ENV_NAMES) {\n delete scrubbed[key];\n }\n scrubbed.WILDO_COMPANION_INTROSPECTION_CHILD = '1';\n return scrubbed;\n}\n\n@injectable()\nexport class CompanionIntrospectionService {\n private readonly logDebug: (message: string, context?: Record<string, unknown>) => void;\n private readonly maxConcurrency: number;\n private readonly timeoutMs: number;\n private activeCount = 0;\n private readonly queue: Array<() => void> = [];\n /** Test seam only; production always retains Node's real child-process spawn. */\n private spawnSubprocess: typeof spawn = spawn;\n /**\n * Whether compiled state may be retained at all.\n *\n * `COMPANION_INTROSPECTION_CACHE=off` still means what it always meant — every read compiles, and\n * no state is consulted or written. The flag is read here rather than inside the state service\n * because this is the door every consumer already comes through, so switching it off cannot be\n * bypassed by a caller that reaches the state service directly.\n */\n private readonly derivationCacheEnabled: boolean;\n\n constructor(\n @inject(SAAS_SERVICE_TYPES.Logger) private readonly logger: LoggerService,\n @inject(COMPANION_SERVICE_TYPES.CompanionContext) private readonly companionContext: CompanionContext,\n @inject(COMPANION_SERVICE_TYPES.IntrospectionBehaviorRegistryService)\n private readonly behaviorRegistryService: CompanionIntrospectionBehaviorRegistryService,\n @inject(COMPANION_SERVICE_TYPES.IntrospectionDerivationStateService)\n private readonly derivationState: IntrospectionDerivationStateCompanionService,\n ) {\n this.logDebug = this.logger.debugByType('CompanionIntrospectionService');\n this.logger.setDebugTypeLogging('CompanionIntrospectionService', true);\n this.maxConcurrency = Math.max(\n 1,\n Number.parseInt(process.env.COMPANION_INTROSPECTION_MAX_CONCURRENCY ?? '', 10)\n || DEFAULT_MAX_CONCURRENCY,\n );\n this.timeoutMs = Math.max(\n 1_000,\n Number.parseInt(process.env.COMPANION_INTROSPECTION_TIMEOUT_MS ?? '', 10)\n || DEFAULT_TIMEOUT_MS,\n );\n this.derivationCacheEnabled = (process.env.COMPANION_INTROSPECTION_CACHE ?? '').trim().toLowerCase()\n !== DISABLE_DERIVATION_CACHE_VALUE;\n }\n\n /**\n * Answer an introspection request, re-deriving only when the application's source has moved.\n *\n * ## The three tiers, in order\n *\n * 1. **Cache hit** — a previous derivation of this exact question, taken against a source tree\n * whose observation token still matches. No subprocess, no import, no registry materialization.\n * 2. **In-flight join** — the identical question is already being derived against the identical\n * token. The caller waits on that one rather than spawning a second child.\n * 3. **Derive** — spawn, under the existing concurrency queue.\n *\n * ## What is cached, and what deliberately is not\n *\n * Only SUCCESS. A failure is not memoized, for two separate reasons and either is sufficient: the\n * common failure here is an application whose `dist` is not built, whose remedy moves the source\n * and would invalidate anyway; and a transient failure — a timeout on a loaded machine — would\n * otherwise stick to an unchanged tree and be served as the answer forever. In-flight JOINING\n * still covers failures, because two concurrent identical questions should cost one subprocess\n * whatever the outcome.\n *\n * ## Where the source reading happens\n *\n * Outside the concurrency queue. The observation is ~125 ms of filesystem work with no subprocess\n * behind it; holding one of the four queue slots for it would make a cache HIT contend with real\n * derivations, which is the opposite of the point.\n */\n /**\n * The introspection MENU — what this running companion can answer, for a caller that has to choose.\n *\n * Serves `wildo context list` (issue #252): the door's tier-1 progressive-disclosure catalog. It is a\n * COMPANION answer rather than a CLI-side copy of the behavior definitions on purpose — the CLI and a\n * running companion can be different builds, and a menu describing behaviors the serving side does not\n * have is the staleness class `.claude/rules/staleness-presents-as-a-logic-defect.md` records. Runtime\n * truth, one hop.\n *\n * `defaultBackendServiceKey` is here for the same one-authority reason: `POST /_meta/introspect`\n * REQUIRES a `serviceKey`, and the \"first backend service\" default already exists in the playbook\n * composer (`composeWorkspaceTruthSection`). Publishing the resolved default lets a CLI caller pass it\n * explicitly instead of re-deriving the rule, so the POST contract stays strict and the rule stays in\n * companion code.\n */\n public describeCatalog(): {\n readonly behaviors: ReadonlyArray<{\n readonly behaviorId: string;\n readonly description: string;\n readonly category: string;\n readonly supportedServiceKinds: readonly CompanionIntrospectionServiceKind[];\n }>;\n readonly serviceKeys: ReadonlyArray<{ readonly key: string; readonly kind: CompanionIntrospectionServiceKind }>;\n readonly defaultBackendServiceKey: string | null;\n } {\n const behaviors = this.behaviorRegistryService.listBehaviorDefinitions().map((definition) => ({\n behaviorId: definition.behaviorId,\n description: definition.description,\n category: definition.category,\n supportedServiceKinds: definition.supportedServiceKinds,\n }));\n const serviceKeys = Object.entries(this.companionContext.servicesByKey).map(([key, service]) => ({\n key,\n kind: this.resolveServiceKind(service),\n }));\n const defaultBackendServiceKey = serviceKeys.find((service) => service.kind === 'backend')?.key ?? null;\n return { behaviors, serviceKeys, defaultBackendServiceKey };\n }\n\n public async requestInfo(request: CompanionIntrospectionRequest): Promise<CompanionIntrospectionResult> {\n const resolvedTarget = await this.resolveTarget(request);\n\n if (!this.derivationCacheEnabled) {\n return this.deriveThroughQueue(resolvedTarget);\n }\n\n const cacheKey = buildDerivationCacheKey(resolvedTarget);\n if (cacheKey === null) {\n return this.deriveThroughQueue(resolvedTarget);\n }\n\n return this.derivationState.read(\n { cacheKey, behavior: resolvedTarget.behavior, serviceKey: resolvedTarget.serviceKey },\n () => this.deriveThroughQueue(resolvedTarget),\n );\n }\n\n /**\n * Compile a derivation without consulting or writing compiled state.\n *\n * The COMPILE primitive, exposed so the state service can drive a recompilation that no read\n * asked for. It is the same path a cache miss took before, minus the memo: the concurrency queue,\n * the subprocess, the IPC result. Nothing here decides freshness, which is the separation this\n * whole change exists to make — a caller that wants the current answer asks the state service, and\n * a caller that wants a NEW answer asks this.\n */\n public async compileNow(\n request: CompanionIntrospectionRequest,\n ): Promise<CompanionIntrospectionResult> {\n return this.deriveThroughQueue(await this.resolveTarget(request));\n }\n\n /**\n * The cache key a request resolves to, for a caller that needs to talk about a derivation's\n * identity — to warm it, to stamp a notification with its generation — without running it.\n *\n * `null` means the request's input cannot be stably rendered, which every caller reads as\n * \"compile, do not remember\".\n */\n public async resolveDerivationIdentity(request: CompanionIntrospectionRequest): Promise<{\n readonly cacheKey: string;\n readonly behavior: string;\n readonly serviceKey: string;\n } | null> {\n const resolvedTarget = await this.resolveTarget(request);\n const cacheKey = buildDerivationCacheKey(resolvedTarget);\n if (cacheKey === null) return null;\n return { cacheKey, behavior: resolvedTarget.behavior, serviceKey: resolvedTarget.serviceKey };\n }\n\n /**\n * Drop every compiled derivation.\n *\n * Costs a recompilation and changes no answer — the property that makes this state per-run runtime\n * state rather than a second source of truth. Kept on this service because it is the door every\n * consumer already holds; the state itself lives one layer down.\n */\n public clearDerivationCache(): void {\n this.derivationState.clear();\n }\n\n private async deriveThroughQueue(\n resolvedTarget: CompanionIntrospectionResolvedTarget,\n ): Promise<CompanionIntrospectionResult> {\n return this.enqueue(async () => {\n this.logDebug('Executing companion introspection request', {\n serviceKey: resolvedTarget.serviceKey,\n behavior: resolvedTarget.behavior,\n targetId: resolvedTarget.targetId,\n entryPath: resolvedTarget.entryPath,\n });\n\n return this.runSubprocess(resolvedTarget);\n });\n }\n\n private async enqueue<T>(task: () => Promise<T>): Promise<T> {\n if (this.activeCount < this.maxConcurrency) {\n return this.runQueuedTask(task);\n }\n\n return new Promise<T>((resolvePromise, rejectPromise) => {\n this.queue.push(() => {\n void this.runQueuedTask(task).then(resolvePromise, rejectPromise);\n });\n });\n }\n\n private async runQueuedTask<T>(task: () => Promise<T>): Promise<T> {\n this.activeCount += 1;\n\n try {\n return await task();\n } finally {\n this.activeCount -= 1;\n const nextTask = this.queue.shift();\n if (nextTask) {\n nextTask();\n }\n }\n }\n\n private async resolveTarget(\n request: CompanionIntrospectionRequest,\n ): Promise<CompanionIntrospectionResolvedTarget> {\n const serviceDefinition = this.companionContext.servicesByKey[request.serviceKey];\n if (!serviceDefinition) {\n throw new Error(`Unknown SaaS service key \"${request.serviceKey}\".`);\n }\n\n const serviceKind = this.resolveServiceKind(serviceDefinition);\n const resolvedBehavior = this.behaviorRegistryService.resolveBehaviorForServiceKind(\n request.behavior,\n serviceKind,\n );\n\n const resolvedTargets = this.resolveCompanionTargets(serviceDefinition);\n const missingTargets = [resolvedBehavior.route.target, ...(resolvedBehavior.route.requiredTargets ?? [])]\n .filter((targetId, index, allTargetIds) => allTargetIds.indexOf(targetId) === index)\n .filter((targetId) => !resolvedTargets[targetId]);\n if (missingTargets.length > 0) {\n throw new Error(\n `Behavior \"${request.behavior}\" requires config-declared target(s) ${missingTargets.map((targetId) => `\"${targetId}\"`).join(', ')}, but they are not declared or resolvable for service \"${request.serviceKey}\".`,\n );\n }\n const behaviorTarget = resolvedTargets[resolvedBehavior.route.target]!;\n\n const servicePath = resolve(this.companionContext.saasRoot, serviceDefinition.path);\n\n return {\n serviceKey: request.serviceKey,\n servicePath,\n serviceName: serviceDefinition.serviceName,\n serviceKind,\n behavior: request.behavior,\n behaviorCategory: resolvedBehavior.category,\n materializationKind: resolvedBehavior.execution.materializationKind,\n targetId: resolvedBehavior.route.target,\n packageRoot: behaviorTarget.packageRoot,\n entryPath: behaviorTarget.entryPath,\n resolvedTargets,\n resolvedBehavior,\n input: request.input,\n };\n }\n\n private resolveServiceKind(\n serviceDefinition: CompanionContext['servicesByKey'][string],\n ): CompanionIntrospectionServiceKind {\n return serviceDefinition.frontendType ? 'frontend' : 'backend';\n }\n\n private async runSubprocess(\n target: CompanionIntrospectionResolvedTarget,\n ): Promise<CompanionIntrospectionResult> {\n const childRequest = this.buildChildRequest(target);\n const launchContext = this.resolveSubprocessLaunchContext();\n\n return new Promise<CompanionIntrospectionResult>((resolvePromise) => {\n const startedAt = Date.now();\n const child = this.spawnSubprocess(process.execPath, [\n /*\n * Silence tsx's own deprecation warning at the SOURCE.\n *\n * `tsx` registers its ESM hooks through `module.register()`, which Node 26 deprecates\n * (DEP0205). The warning is emitted by a dependency on every single introspection call, it\n * says nothing about this application, and there is nothing an application developer can do\n * about it — but it lands in the child's stderr, which is buffered and logged, so it\n * DOMINATED the one place a reader looks to find out what an introspection actually did.\n *\n * Suppressed here rather than filtered out of the log: a warning that is never emitted cannot\n * be mistaken for output, and filtering would leave the next reader wondering whether the\n * filter is hiding something real. Scoped to this ONE code, so a genuine future deprecation\n * still surfaces.\n */\n '--disable-warning=DEP0205',\n '--import',\n 'tsx',\n '--import',\n launchContext.assetNoopRegisterPath,\n launchContext.runnerPath,\n ], {\n cwd: launchContext.cwd,\n env: buildSubprocessEnv(),\n stdio: ['ignore', 'pipe', 'pipe', 'ipc'],\n });\n\n let stdout = '';\n let stderr = '';\n let settled = false;\n let parsedResult: CompanionIntrospectionResult | null = null;\n let pendingFailure: CompanionIntrospectionFailureResult | null = null;\n let naturalExitHandle: NodeJS.Timeout | null = null;\n let forceKillHandle: NodeJS.Timeout | null = null;\n\n /*\n * The child's output, as TWO named fields rather than one ` | `-joined blob.\n *\n * The blob was unreadable in practice: a routine success printed one useful line of stdout\n * glued to a multi-line third-party deprecation warning, and a reader could not tell at a\n * glance whether an introspection had worked, what it had found, or whether the stderr meant\n * anything. Stdout and stderr answer different questions — what it DID versus what went WRONG —\n * and joining them makes the log answer neither.\n */\n const buildOutputContext = (): { stdout?: string; stderr?: string } | undefined => {\n const trimmedStdout = stdout.trim();\n const trimmedStderr = stderr.trim();\n if (trimmedStdout.length === 0 && trimmedStderr.length === 0) return undefined;\n return {\n ...(trimmedStdout.length > 0 ? { stdout: trimmedStdout } : {}),\n ...(trimmedStderr.length > 0 ? { stderr: trimmedStderr } : {}),\n };\n };\n\n /** One line for a message that has no room for two fields. */\n const describeOutputContext = (context: { stdout?: string; stderr?: string } | undefined): string =>\n context === undefined\n ? ''\n : [\n ...(context.stdout ? [`stdout: ${context.stdout}`] : []),\n ...(context.stderr ? [`stderr: ${context.stderr}`] : []),\n ].join(' | ');\n\n const onStdout = (chunk: Buffer | string) => {\n stdout += chunk.toString();\n };\n const onStderr = (chunk: Buffer | string) => {\n stderr += chunk.toString();\n };\n child.stdout?.on('data', onStdout);\n child.stderr?.on('data', onStderr);\n\n const clearTimer = (handle: NodeJS.Timeout | null): void => {\n if (handle !== null) clearTimeout(handle);\n };\n\n const cleanup = () => {\n clearTimeout(timeoutHandle);\n clearTimer(naturalExitHandle);\n clearTimer(forceKillHandle);\n child.off('spawn', onSpawn);\n child.off('message', onMessage);\n child.off('error', onError);\n child.off('close', onClose);\n child.stdout?.off('data', onStdout);\n child.stderr?.off('data', onStderr);\n };\n\n const finalize = (result: CompanionIntrospectionResult) => {\n if (settled) {\n return;\n }\n\n settled = true;\n cleanup();\n const finalResult = {\n ...result,\n stdout: stdout || undefined,\n stderr: stderr || undefined,\n };\n resolvePromise(finalResult);\n };\n\n const requestTermination = (failure: CompanionIntrospectionFailureResult): void => {\n if (pendingFailure === null) pendingFailure = failure;\n clearTimeout(timeoutHandle);\n clearTimer(naturalExitHandle);\n naturalExitHandle = null;\n if (forceKillHandle !== null) return;\n try {\n child.kill('SIGTERM');\n } catch {\n // A concurrent exit can make kill throw; settlement still waits for\n // the terminal `close` event rather than guessing process state.\n }\n forceKillHandle = setTimeout(() => {\n try {\n child.kill('SIGKILL');\n } catch {\n // The terminal `close` event remains the only settlement signal.\n }\n }, 1_000);\n };\n\n const onSpawn = () => {\n child.send?.(childRequest);\n };\n\n const onMessage = (message: unknown) => {\n clearTimeout(timeoutHandle);\n if (pendingFailure !== null) return;\n if (parsedResult !== null) {\n requestTermination(this.buildFailureResult(target, startedAt, {\n message: 'Companion introspection subprocess returned more than one result payload.',\n name: 'CompanionIntrospectionDuplicateResultError',\n }));\n return;\n }\n try {\n parsedResult = CompanionIntrospectionResultSchema.parse(message) as CompanionIntrospectionResult;\n // A valid payload is provisional until the child proves that no late\n // failure occurred. Give the normal child one bounded window to\n // disconnect and exit cleanly before beginning termination.\n naturalExitHandle = setTimeout(() => {\n requestTermination(this.buildFailureResult(target, startedAt, {\n message: 'Companion introspection subprocess returned a result but did not exit cleanly within 1000ms.',\n name: 'CompanionIntrospectionResultExitTimeoutError',\n }));\n }, 1_000);\n } catch (error) {\n // describeCaughtError: N/A — this `try` wraps exactly one statement,\n // `CompanionIntrospectionResultSchema.parse(message)`, which throws a `ZodError`.\n // No engine service is called inside it, so a `WildoError_Backend` (a plain\n // object, which the test below would reject) cannot reach here. The site also\n // needs `.name` and `.stack`, which the string helper does not carry. Left as-is\n // deliberately, not overlooked by the 2026-08-21 sweep.\n const standardError = error instanceof Error ? error : new Error('Invalid companion introspection subprocess payload.');\n requestTermination(this.buildFailureResult(target, startedAt, {\n message: standardError.message,\n name: standardError.name,\n stack: standardError.stack,\n }));\n }\n };\n\n const onError = (error: Error) => {\n requestTermination(this.buildFailureResult(target, startedAt, {\n message: error.message,\n name: error.name,\n stack: error.stack,\n }));\n };\n\n const onClose = (code: number | null, signal: NodeJS.Signals | null) => {\n if (settled) return;\n const outputContext = buildOutputContext();\n if (outputContext) {\n /*\n * Named for what the reader wants to know — WHICH introspection, and whether it went\n * cleanly — rather than for the mechanism. \"exited with buffered output\" described the\n * plumbing and left the behavior buried in a field.\n */\n const cleanExit = code === 0 && signal === null;\n this.logDebug(\n `Companion introspection \"${target.behavior}\" on \"${target.serviceKey}\" ${cleanExit ? 'completed' : `exited code=${code ?? 'null'} signal=${signal ?? 'null'}`}`,\n {\n serviceKey: target.serviceKey,\n behavior: target.behavior,\n targetId: target.targetId,\n code,\n signal,\n ...outputContext,\n },\n );\n }\n if (pendingFailure !== null) {\n finalize(pendingFailure);\n return;\n }\n if (parsedResult !== null && code === 0 && signal === null) {\n finalize(parsedResult);\n return;\n }\n if (parsedResult !== null && parsedResult.success === false) {\n finalize(parsedResult);\n return;\n }\n /*\n * A signal THIS SERVICE DID NOT SEND means the kill came from outside, and saying so is the\n * difference between an actionable message and a misleading one.\n *\n * Every termination this service performs goes through `requestTermination`, which sets\n * `pendingFailure` BEFORE killing — and the branch above returns that failure. So reaching\n * here with a termination signal proves nobody here asked for it: the child died because its\n * PARENT did, taking the process group with it.\n *\n * In a dev loop that is the supervisor restarting the companion. Measured 2026-09-02 across\n * four session logs: 30 such failures at a median of 11.4 s — nowhere near the 30 s ceiling —\n * and the line immediately preceding each one is\n * `[runtime-supervisor:wildo-dev-companion] Stopping runtime before readiness...`.\n *\n * The old message named the subprocess as the thing that exited, which is true and useless:\n * it reads as a fault in the derivation, and `signal=SIGTERM` beside a 30 s timeout constant\n * reads as that timeout firing. It cost a full investigation before the log said otherwise.\n */\n const terminatedFromOutside = wasTerminatedFromOutside({\n signal,\n hasPendingFailure: pendingFailure !== null,\n hasParsedResult: parsedResult !== null,\n });\n\n finalize(this.buildFailureResult(target, startedAt, terminatedFromOutside\n ? {\n message: `Companion introspection was terminated by ${signal} that this service did not send — the companion process itself is stopping, so the derivation was cut short rather than failing. Re-run it once the companion is ready.`,\n name: 'CompanionIntrospectionParentTerminatedError',\n }\n : {\n message: parsedResult === null\n ? `Companion introspection subprocess exited before returning a result (code=${code ?? 'null'}, signal=${signal ?? 'null'})${outputContext ? ` — ${describeOutputContext(outputContext)}` : ''}.`\n : `Companion introspection subprocess returned a result then exited unsuccessfully (code=${code ?? 'null'}, signal=${signal ?? 'null'}).`,\n name: 'CompanionIntrospectionSubprocessExitError',\n }));\n };\n\n const timeoutHandle = setTimeout(() => {\n requestTermination(this.buildFailureResult(target, startedAt, {\n message: `Companion introspection timed out after ${this.timeoutMs}ms.`,\n name: 'CompanionIntrospectionTimeoutError',\n }));\n }, this.timeoutMs);\n\n child.on('spawn', onSpawn);\n child.on('message', onMessage);\n child.on('error', onError);\n // `close`, unlike `message` or `exit`, proves that the process and its\n // stdio handles are all quiescent. The parent never releases its queue\n // slot while the child can still emit output or fail late.\n child.on('close', onClose);\n });\n }\n\n private buildChildRequest(\n target: CompanionIntrospectionResolvedTarget,\n ): CompanionIntrospectionChildRequest {\n return {\n behavior: target.behavior,\n serviceKind: target.serviceKind,\n behaviorCategory: target.behaviorCategory,\n materializationKind: target.materializationKind,\n targetId: target.targetId,\n serviceKey: target.serviceKey,\n entryPath: target.entryPath,\n packageRoot: target.packageRoot,\n homes: this.buildChildHomesSnapshot(),\n resolvedTargets: target.resolvedTargets,\n input: target.input,\n };\n }\n\n /**\n * Resolve subprocess launch paths from THIS MODULE's own location, never from\n * `companionHome/src`. Under dist-only delivery (issue #64) the application's\n * `.wildo-saas/wildo-dev-companion` drop contains no source tree at all — the child runner and\n * the asset-noop register ship as COMPILED siblings of this service inside `dist/esm`, so the\n * only location that is guaranteed to hold them is the directory graph this very module runs\n * from. When the suite executes the source directly (vitest resolves the `.ts` module), the\n * sibling files are the authored `.ts` sources and the child is executable because the spawn\n * always registers `tsx` before the register hook. `cwd` stays the application's companion\n * home: the child resolves app packages and `node_modules` (including `tsx` itself) from there.\n */\n private resolveSubprocessLaunchContext(): {\n cwd: string;\n runnerPath: string;\n assetNoopRegisterPath: string;\n } {\n const isSourceExecution = import.meta.url.endsWith('.ts');\n const subprocessDir = fileURLToPath(new URL('../subprocess/', import.meta.url));\n return {\n cwd: this.companionContext.companionHome,\n runnerPath: join(subprocessDir, isSourceExecution ? 'companion-introspection-child.ts' : 'companion-introspection-child.js'),\n assetNoopRegisterPath: join(subprocessDir, isSourceExecution ? 'asset-noop-register.ts' : 'asset-noop-register.js'),\n };\n }\n\n private buildChildHomesSnapshot(): CompanionIntrospectionHomesSnapshot {\n const appLayout = this.companionContext.resolvedHomes.app.layout;\n if (!appLayout) {\n throw new Error('Companion introspection requires an app layout in the trusted homes snapshot.');\n }\n\n return {\n appDeclarationRoot: appLayout.declarationRoot,\n appRuntimeHome: appLayout.runtimeHome,\n companionHome: this.companionContext.companionHome,\n frameworkRepositoryRoot: this.companionContext.resolvedHomes.framework.repositoryRoot,\n };\n }\n\n private resolveCompanionTargets(\n serviceDefinition: CompanionContext['servicesByKey'][string],\n ): Partial<Record<CompanionIntrospectionRouteTargetId, CompanionIntrospectionResolvedPackageTarget>> {\n const sharedLibrary = this.companionContext.resolvedLibraries.shared;\n const resolvedLibraryTarget = sharedLibrary?.libraryType === AppLibraryType.FULLSTACK\n ? {\n targetId: 'library' as const,\n packageRoot: sharedLibrary.packageRoot,\n entryPath: sharedLibrary.entryPath,\n declaredPath: sharedLibrary.declaredPath,\n }\n : undefined;\n\n return {\n service: this.tryResolveCompanionTarget('service', serviceDefinition.path),\n library: resolvedLibraryTarget,\n specifications: this.companionContext.resolvedSpecifications\n ? {\n targetId: 'specifications',\n packageRoot: this.companionContext.resolvedSpecifications.packageRoot,\n entryPath: this.companionContext.resolvedSpecifications.entryPath,\n declaredPath: this.companionContext.resolvedSpecifications.declaredPath,\n }\n : undefined,\n };\n }\n\n private tryResolveCompanionTarget(\n targetId: CompanionIntrospectionRouteTargetId,\n declaredPath: string,\n ): CompanionIntrospectionResolvedPackageTarget | undefined {\n const packageRoot = resolve(this.companionContext.saasRoot, declaredPath);\n\n try {\n return {\n targetId,\n packageRoot,\n entryPath: resolvePackageCompanionEntryPath(packageRoot),\n declaredPath,\n };\n } catch {\n return undefined;\n }\n }\n\n private buildFailureResult(\n target: CompanionIntrospectionResolvedTarget,\n startedAt: number,\n error: CompanionIntrospectionErrorDetails,\n ): CompanionIntrospectionFailureResult {\n return {\n success: false,\n behavior: target.behavior,\n serviceKey: target.serviceKey,\n serviceKind: target.serviceKind,\n behaviorCategory: target.behaviorCategory,\n materializationKind: target.materializationKind,\n targetId: target.targetId,\n durationMs: Date.now() - startedAt,\n error,\n };\n }\n}\n"]}
1
+ {"version":3,"file":"companion-introspection.companion.service.js","sourceRoot":"","sources":["../../../../../../src/core/introspection/services/companion-introspection.companion.service.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,oBAAoB,CAAC;AAC3C,OAAO,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAC1C,OAAO,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AACzC,OAAO,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,WAAW,CAAC;AAE/C,OAAO,EAAE,kBAAkB,EAAE,MAAM,4BAA4B,CAAC;AAChE,OAAO,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AACxD,OAAO,EAAE,cAAc,EAAE,gCAAgC,EAAE,MAAM,+BAA+B,CAAC;AACjG,OAAO,EAAE,kCAAkC,EAAE,MAAM,8CAA8C,CAAC;AAElG,OAAO,EAAE,6CAA6C,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J,CAAC;QAAC,MAAM,CAAC;YACP,OAAO,SAAS,CAAC;QACnB,CAAC;IACH,CAAC;IAEO,kBAAkB,CACxB,MAA4C,EAC5C,SAAiB,EACjB,KAAyC;QAEzC,OAAO;YACL,OAAO,EAAE,KAAK;YACd,QAAQ,EAAE,MAAM,CAAC,QAAQ;YACzB,UAAU,EAAE,MAAM,CAAC,UAAU;YAC7B,WAAW,EAAE,MAAM,CAAC,WAAW;YAC/B,gBAAgB,EAAE,MAAM,CAAC,gBAAgB;YACzC,mBAAmB,EAAE,MAAM,CAAC,mBAAmB;YAC/C,QAAQ,EAAE,MAAM,CAAC,QAAQ;YACzB,UAAU,EAAE,IAAI,CAAC,GAAG,EAAE,GAAG,SAAS;YAClC,KAAK;SACN,CAAC;IACJ,CAAC;CACF,CAAA;AAprBY,6BAA6B;IADzC,UAAU,EAAE;IAoBR,WAAA,MAAM,CAAC,kBAAkB,CAAC,MAAM,CAAC,CAAA;IACjC,WAAA,MAAM,CAAC,uBAAuB,CAAC,gBAAgB,CAAC,CAAA;IAChD,WAAA,MAAM,CAAC,uBAAuB,CAAC,oCAAoC,CAAC,CAAA;IAEpE,WAAA,MAAM,CAAC,uBAAuB,CAAC,mCAAmC,CAAC,CAAA;uDAD1B,6CAA6C;QAErD,4CAA4C;GAxBrE,6BAA6B,CAorBzC","sourcesContent":["import { spawn } from 'node:child_process';\nimport { join, resolve } from 'node:path';\nimport { fileURLToPath } from 'node:url';\nimport { inject, injectable } from 'inversify';\nimport type { LoggerService } from '@wildo-ai/saas-backend-lib';\nimport { SAAS_SERVICE_TYPES } from '@wildo-ai/saas-backend-lib';\nimport { AppFrontendType } from '@wildo-ai/saas-models';\nimport { AppLibraryType, resolvePackageCompanionEntryPath } from '@wildo-ai/platform-config-lib';\nimport { CompanionIntrospectionResultSchema } from '../../../companion-api/companion-api.schemas';\nimport type { CompanionContext } from '../../context/companion-context';\nimport { CompanionIntrospectionBehaviorRegistryService } from './companion-introspection-behavior-registry.companion.service';\nimport { IntrospectionDerivationStateCompanionService } from './introspection-derivation-state.companion.service';\nimport type {\n CompanionIntrospectionChildRequest,\n CompanionIntrospectionErrorDetails,\n CompanionIntrospectionFailureResult,\n CompanionIntrospectionHomesSnapshot,\n CompanionIntrospectionRequest,\n CompanionIntrospectionResolvedPackageTarget,\n CompanionIntrospectionResolvedTarget,\n CompanionIntrospectionResult,\n CompanionIntrospectionRouteTargetId,\n CompanionIntrospectionServiceKind,\n} from '../models/companion-introspection.models';\nimport { IntrospectionInputValidationError } from '../models/companion-introspection.models';\nimport { COMPANION_SERVICE_TYPES } from '../../inject/models/service-types';\n\nconst DEFAULT_MAX_CONCURRENCY = 4;\n\n/**\n * How long one introspection subprocess may run before it is killed and reported as a timeout.\n *\n * ## This bounds a HANG. It is not a latency budget.\n *\n * A child that answers slowly is still answering; the only thing this ceiling exists to catch is a\n * child that will never answer. So it must sit comfortably ABOVE the most expensive legitimate read,\n * and the cost of setting it too low is far worse than the cost of setting it too high: an\n * over-tight ceiling does not slow a playbook down, it makes the playbook permanently unable to run.\n *\n * ## Measured 2026-09-09 on `examples/wonder-todos`, and why 30s had to go\n *\n * It was `30_000` — an unjustified round number — and every `specifications`-target behavior a\n * `workspace_truth` playbook assembles EXCEEDED it, deterministically. Timing the child directly,\n * with nothing but the dev stack competing:\n *\n * | behavior | target | measured |\n * |---|---|---|\n * | `expert-persona-charters` | specifications | 11.5s |\n * | `expert-persona-derivation-inputs` | specifications | 13.5s |\n * | `specification-artifacts` | specifications | **30.6s** |\n * | `application-domain-model` | specifications | **35.3s** |\n *\n * The consequence was not an intermittent flake. `bottom_up.placement-plan` — and anything else\n * declaring `contextSources: ['workspace_truth']` — watched every one of its context reads fail at\n * exactly 30s intervals (`specification-artifacts`, `family-aspects`, `frontend-labels-needed-info`,\n * `openapi-generation-input`, …), assembled an empty brief, and could not complete. It read as a\n * `500 INTERNAL / critical`, which sends a reader looking for a bug in the behavior rather than at\n * the clock.\n *\n * ## Why 120s\n *\n * ~3.4x headroom over the worst measurement, because a developer machine mid-compile-storm is\n * materially slower than one that is idle, and this is the machine every one of these reads runs on.\n * A genuinely hung child is still detected and still reported — two minutes later instead of thirty\n * seconds, which nobody is waiting on interactively.\n *\n * Re-measure before lowering this: the cost is dominated by importing a real application's compiled\n * `specifications` package and the engine graph behind it, so it grows with the application. A\n * deployment that wants a tighter bound sets `COMPANION_INTROSPECTION_TIMEOUT_MS`.\n */\nconst DEFAULT_TIMEOUT_MS = 120_000;\n\n/**\n * The signals that mean SOMEONE ELSE stopped this process tree.\n *\n * Read only in the exit branch that has already established this service sent no kill of its own, so\n * membership here is what separates \"the companion is going down\" from \"the derivation failed\".\n * `SIGKILL` is deliberately absent: it is what this service's own force-kill escalation sends, and a\n * child that reaches it has already been through `requestTermination`.\n */\nconst EXTERNAL_TERMINATION_SIGNALS = new Set<string>(['SIGTERM', 'SIGINT', 'SIGHUP']);\n\n/**\n * Whether a dead introspection child was killed by SOMEONE OTHER than this service.\n *\n * Exported because it is the whole decision — the call site is one branch — and because it is the\n * part worth pinning: the plumbing around it needs a real subprocess and a real signal, while the\n * reasoning is three booleans.\n *\n * The inference rests on an invariant of this file: every termination this service performs goes\n * through `requestTermination`, which sets a pending failure BEFORE killing, and the exit handler\n * returns that failure without consulting this. So a termination signal arriving with no pending\n * failure and no parsed result means nobody here asked — the child died because its PARENT did,\n * taking the process group with it. If a future kill path forgets to set the pending failure first,\n * this starts misreporting a local kill as an external one, which is why the invariant is stated\n * here rather than left implicit at the call site.\n */\nexport function wasTerminatedFromOutside(input: {\n readonly signal: string | null;\n readonly hasPendingFailure: boolean;\n readonly hasParsedResult: boolean;\n}): boolean {\n if (input.hasPendingFailure || input.hasParsedResult) return false;\n return input.signal !== null && EXTERNAL_TERMINATION_SIGNALS.has(input.signal);\n}\n\n/**\n * Env value that turns the derivation cache off entirely.\n *\n * Read once at construction. A door rather than a design: if the cache is ever suspected of serving\n * a stale answer, an operator can settle the question in one restart instead of reasoning about the\n * invalidation, and the diagnosis stays about the application rather than about this file. The\n * default is ON — the whole point is that the workbench stops paying a cold transpile per request.\n */\nconst DISABLE_DERIVATION_CACHE_VALUE = 'off';\n\n/**\n * Env-var namespaces stripped from the spawned introspection child's\n * environment so pre-bootstrap reads surface `undefined` instead of inheriting\n * stale values from the parent shell.\n *\n * The trusted homes snapshot is delivered through the IPC handshake and\n * reapplied by `applyTrustedHomesToChildProcess()` as the first action of\n * `handleChildProcessMessage()`. Any code that happens to read these env\n * vars during the narrow window BEFORE that handler runs (for example while\n * `reflect-metadata` is loading) would otherwise see whatever the parent\n * shell had set — including stale values from a previous companion run or\n * from the operator's shell — which would reintroduce the Phase 5\n * \"env-over-context\" class of regression at the subprocess boundary.\n *\n * `WILDO_COMPANION_INTROSPECTION_CHILD` is the intentional child-mode flag\n * and is re-injected fresh for every spawn.\n */\nexport const SCRUBBED_CHILD_ENV_NAMES = [\n 'COMPANION_WORKSPACE_ROOT',\n 'COMPANION_RUNTIME_HOME',\n 'COMPANION_PACKAGE_ROOT',\n 'COMPANION_FRAMEWORK_ROOT',\n 'WILDO_COMPANION_INTROSPECTION_CHILD',\n] as const;\n\n/**\n * Render an arbitrary behavior `input` so that two structurally equal inputs produce one key.\n *\n * `JSON.stringify` alone would not: `{a:1,b:2}` and `{b:2,a:1}` are the same question and would\n * occupy two cache entries, so the second phrasing of a question would always miss. Object keys are\n * therefore sorted at every depth. Arrays keep their order, because in an input an array's order is\n * part of the question.\n *\n * A value that cannot be rendered — a cycle, a `BigInt` — yields `null`, which the caller reads as\n * \"this question is not cacheable\" rather than as an error. Nothing in the current behavior surface\n * sends such an input; treating it as uncacheable rather than throwing keeps a future one working.\n */\nexport function renderStableCacheableInput(input: unknown): string | null {\n const seen = new WeakSet<object>();\n\n const render = (value: unknown): string => {\n if (value === undefined) return 'undefined';\n if (value === null) return 'null';\n if (typeof value === 'bigint') throw new Error('BigInt is not renderable.');\n if (typeof value !== 'object') return JSON.stringify(value) ?? 'undefined';\n if (seen.has(value as object)) throw new Error('Cyclic input is not renderable.');\n seen.add(value as object);\n if (Array.isArray(value)) {\n return `[${value.map(render).join(',')}]`;\n }\n const entries = Object.entries(value as Record<string, unknown>)\n .filter(([, entryValue]) => entryValue !== undefined)\n .sort(([left], [right]) => (left < right ? -1 : left > right ? 1 : 0));\n return `{${entries.map(([key, entryValue]) => `${JSON.stringify(key)}:${render(entryValue)}`).join(',')}}`;\n };\n\n try {\n return render(input);\n } catch {\n return null;\n }\n}\n\n/**\n * The identity of a derivation on the REQUEST side.\n *\n * Everything the child is given that can change its answer: which service, which behavior, which\n * target it routes to, and the behavior input. `entryPath` and `packageRoot` are included because a\n * package whose built `./companion` export appears or disappears changes which bytes are imported\n * without changing the behavior id — and `resolvePackageCompanionEntryPath` prefers `dist` when it\n * exists and falls back to source when it does not.\n *\n * Returns `null` for an input that cannot be stably rendered, which the caller reads as\n * \"derive, do not remember\".\n */\nfunction buildDerivationCacheKey(target: CompanionIntrospectionResolvedTarget): string | null {\n const renderedInput = renderStableCacheableInput(target.input);\n if (renderedInput === null) return null;\n\n return [\n target.serviceKey,\n target.serviceKind,\n target.behavior,\n target.targetId,\n target.packageRoot,\n target.entryPath,\n renderedInput,\n ].join('\\u0001');\n}\n\n/**\n * Build the `env` object handed to the spawned introspection child process.\n *\n * Responsibilities:\n *\n * 1. Inherit the caller's `process.env` as a base, so the child still sees\n * normal environment (`PATH`, `NODE_OPTIONS`, node-debug flags, etc.).\n * 2. Scrub every `COMPANION_*` bootstrap seed that\n * `applyTrustedHomesToChildProcess()` owns on the child side. Leaving\n * them in place would let `reflect-metadata` (or anything else imported\n * before the first IPC message arrives) read a stale value from the\n * parent shell — the exact Phase 5 \"env-over-context\" regression class\n * this slice was introduced to close.\n * 3. Drop any pre-existing `WILDO_COMPANION_INTROSPECTION_CHILD` so it\n * cannot survive from a parent that was itself a child in a nested\n * spawn, then re-inject it as the exact string `'1'`. The child's\n * `shouldRegisterChildMessageHandler()` gate only accepts `'1'`, so\n * this is also the enforcement point that keeps the flag's contract\n * single-sourced here.\n *\n * Exported purely for unit testing; production code reaches it through\n * `this.runSubprocess(...)` in `CompanionIntrospectionService`.\n */\nexport function buildSubprocessEnv(): NodeJS.ProcessEnv {\n const scrubbed: NodeJS.ProcessEnv = { ...process.env };\n for (const key of SCRUBBED_CHILD_ENV_NAMES) {\n delete scrubbed[key];\n }\n scrubbed.WILDO_COMPANION_INTROSPECTION_CHILD = '1';\n return scrubbed;\n}\n\n@injectable()\nexport class CompanionIntrospectionService {\n private readonly logDebug: (message: string, context?: Record<string, unknown>) => void;\n private readonly maxConcurrency: number;\n private readonly timeoutMs: number;\n private activeCount = 0;\n private readonly queue: Array<() => void> = [];\n /** Test seam only; production always retains Node's real child-process spawn. */\n private spawnSubprocess: typeof spawn = spawn;\n /**\n * Whether compiled state may be retained at all.\n *\n * `COMPANION_INTROSPECTION_CACHE=off` still means what it always meant — every read compiles, and\n * no state is consulted or written. The flag is read here rather than inside the state service\n * because this is the door every consumer already comes through, so switching it off cannot be\n * bypassed by a caller that reaches the state service directly.\n */\n private readonly derivationCacheEnabled: boolean;\n\n constructor(\n @inject(SAAS_SERVICE_TYPES.Logger) private readonly logger: LoggerService,\n @inject(COMPANION_SERVICE_TYPES.CompanionContext) private readonly companionContext: CompanionContext,\n @inject(COMPANION_SERVICE_TYPES.IntrospectionBehaviorRegistryService)\n private readonly behaviorRegistryService: CompanionIntrospectionBehaviorRegistryService,\n @inject(COMPANION_SERVICE_TYPES.IntrospectionDerivationStateService)\n private readonly derivationState: IntrospectionDerivationStateCompanionService,\n ) {\n this.logDebug = this.logger.debugByType('CompanionIntrospectionService');\n this.logger.setDebugTypeLogging('CompanionIntrospectionService', true);\n this.maxConcurrency = Math.max(\n 1,\n Number.parseInt(process.env.COMPANION_INTROSPECTION_MAX_CONCURRENCY ?? '', 10)\n || DEFAULT_MAX_CONCURRENCY,\n );\n this.timeoutMs = Math.max(\n 1_000,\n Number.parseInt(process.env.COMPANION_INTROSPECTION_TIMEOUT_MS ?? '', 10)\n || DEFAULT_TIMEOUT_MS,\n );\n this.derivationCacheEnabled = (process.env.COMPANION_INTROSPECTION_CACHE ?? '').trim().toLowerCase()\n !== DISABLE_DERIVATION_CACHE_VALUE;\n }\n\n /**\n * Answer an introspection request, re-deriving only when the application's source has moved.\n *\n * ## The three tiers, in order\n *\n * 1. **Cache hit** — a previous derivation of this exact question, taken against a source tree\n * whose observation token still matches. No subprocess, no import, no registry materialization.\n * 2. **In-flight join** — the identical question is already being derived against the identical\n * token. The caller waits on that one rather than spawning a second child.\n * 3. **Derive** — spawn, under the existing concurrency queue.\n *\n * ## What is cached, and what deliberately is not\n *\n * Only SUCCESS. A failure is not memoized, for two separate reasons and either is sufficient: the\n * common failure here is an application whose `dist` is not built, whose remedy moves the source\n * and would invalidate anyway; and a transient failure — a timeout on a loaded machine — would\n * otherwise stick to an unchanged tree and be served as the answer forever. In-flight JOINING\n * still covers failures, because two concurrent identical questions should cost one subprocess\n * whatever the outcome.\n *\n * ## Where the source reading happens\n *\n * Outside the concurrency queue. The observation is ~125 ms of filesystem work with no subprocess\n * behind it; holding one of the four queue slots for it would make a cache HIT contend with real\n * derivations, which is the opposite of the point.\n */\n /**\n * The introspection MENU — what this running companion can answer, for a caller that has to choose.\n *\n * Serves `wildo context list` (issue #252): the door's tier-1 progressive-disclosure catalog. It is a\n * COMPANION answer rather than a CLI-side copy of the behavior definitions on purpose — the CLI and a\n * running companion can be different builds, and a menu describing behaviors the serving side does not\n * have is the staleness class `.claude/rules/staleness-presents-as-a-logic-defect.md` records. Runtime\n * truth, one hop.\n *\n * `defaultBackendServiceKey` is here for the same one-authority reason: `POST /_meta/introspect`\n * REQUIRES a `serviceKey`, and the \"first backend service\" default already exists in the playbook\n * composer (`composeWorkspaceTruthSection`). Publishing the resolved default lets a CLI caller pass it\n * explicitly instead of re-deriving the rule, so the POST contract stays strict and the rule stays in\n * companion code.\n */\n public describeCatalog(): {\n readonly behaviors: ReadonlyArray<{\n readonly behaviorId: string;\n readonly description: string;\n readonly category: string;\n readonly supportedServiceKinds: readonly CompanionIntrospectionServiceKind[];\n readonly inputSummary?: string;\n }>;\n readonly serviceKeys: ReadonlyArray<{\n readonly key: string;\n readonly kind: CompanionIntrospectionServiceKind;\n /**\n * The frontend's KIND OF FRONTEND (`AppFrontendType`), for a frontend service only.\n *\n * `kind` collapses `saas-app`, `static-website` and `tech-doc` into one word, which is right\n * for ROUTING a behavior (all three are introspected the same way) and useless for CHOOSING\n * between them. An application commonly declares all three, so a caller asking a shell\n * behavior of \"the frontend\" has three answers and no way to tell which one has a shell.\n * Published so the choice is a lookup rather than a guess.\n */\n readonly frontendType?: string;\n }>;\n readonly defaultBackendServiceKey: string | null;\n /**\n * The SaaS application's own frontend — the twin of `defaultBackendServiceKey`, and the answer\n * to \"which frontend did you mean\" for every behavior that reads the application shell.\n *\n * Derived from `frontendType === 'saas-app'` rather than from declaration ORDER: order would be\n * a guess that happens to be right in the applications checked, and wrong for one that declares\n * its marketing site first. `null` when the application declares no SaaS frontend, which is a\n * real shape — a docs-only or website-only package.\n */\n readonly defaultFrontendServiceKey: string | null;\n } {\n const behaviors = this.behaviorRegistryService.listBehaviorDefinitions().map((definition) => ({\n behaviorId: definition.behaviorId,\n description: definition.description,\n category: definition.category,\n supportedServiceKinds: definition.supportedServiceKinds,\n ...(definition.inputSummary !== undefined ? { inputSummary: definition.inputSummary } : {}),\n }));\n const serviceKeys = Object.entries(this.companionContext.servicesByKey).map(([key, service]) => ({\n key,\n kind: this.resolveServiceKind(service),\n ...(service.frontendType !== undefined ? { frontendType: String(service.frontendType) } : {}),\n }));\n const defaultBackendServiceKey = serviceKeys.find((service) => service.kind === 'backend')?.key ?? null;\n const defaultFrontendServiceKey = serviceKeys.find(\n (service) => service.frontendType === AppFrontendType.SAAS_APP,\n )?.key ?? null;\n return { behaviors, serviceKeys, defaultBackendServiceKey, defaultFrontendServiceKey };\n }\n\n public async requestInfo(request: CompanionIntrospectionRequest): Promise<CompanionIntrospectionResult> {\n const resolvedTarget = await this.resolveTarget(request);\n\n if (!this.derivationCacheEnabled) {\n return this.deriveThroughQueue(resolvedTarget);\n }\n\n const cacheKey = buildDerivationCacheKey(resolvedTarget);\n if (cacheKey === null) {\n return this.deriveThroughQueue(resolvedTarget);\n }\n\n return this.derivationState.read(\n { cacheKey, behavior: resolvedTarget.behavior, serviceKey: resolvedTarget.serviceKey },\n () => this.deriveThroughQueue(resolvedTarget),\n );\n }\n\n /**\n * Compile a derivation without consulting or writing compiled state.\n *\n * The COMPILE primitive, exposed so the state service can drive a recompilation that no read\n * asked for. It is the same path a cache miss took before, minus the memo: the concurrency queue,\n * the subprocess, the IPC result. Nothing here decides freshness, which is the separation this\n * whole change exists to make — a caller that wants the current answer asks the state service, and\n * a caller that wants a NEW answer asks this.\n */\n public async compileNow(\n request: CompanionIntrospectionRequest,\n ): Promise<CompanionIntrospectionResult> {\n return this.deriveThroughQueue(await this.resolveTarget(request));\n }\n\n /**\n * The cache key a request resolves to, for a caller that needs to talk about a derivation's\n * identity — to warm it, to stamp a notification with its generation — without running it.\n *\n * `null` means the request's input cannot be stably rendered, which every caller reads as\n * \"compile, do not remember\".\n */\n public async resolveDerivationIdentity(request: CompanionIntrospectionRequest): Promise<{\n readonly cacheKey: string;\n readonly behavior: string;\n readonly serviceKey: string;\n } | null> {\n const resolvedTarget = await this.resolveTarget(request);\n const cacheKey = buildDerivationCacheKey(resolvedTarget);\n if (cacheKey === null) return null;\n return { cacheKey, behavior: resolvedTarget.behavior, serviceKey: resolvedTarget.serviceKey };\n }\n\n /**\n * Drop every compiled derivation.\n *\n * Costs a recompilation and changes no answer — the property that makes this state per-run runtime\n * state rather than a second source of truth. Kept on this service because it is the door every\n * consumer already holds; the state itself lives one layer down.\n */\n public clearDerivationCache(): void {\n this.derivationState.clear();\n }\n\n private async deriveThroughQueue(\n resolvedTarget: CompanionIntrospectionResolvedTarget,\n ): Promise<CompanionIntrospectionResult> {\n return this.enqueue(async () => {\n this.logDebug('Executing companion introspection request', {\n serviceKey: resolvedTarget.serviceKey,\n behavior: resolvedTarget.behavior,\n targetId: resolvedTarget.targetId,\n entryPath: resolvedTarget.entryPath,\n });\n\n return this.runSubprocess(resolvedTarget);\n });\n }\n\n private async enqueue<T>(task: () => Promise<T>): Promise<T> {\n if (this.activeCount < this.maxConcurrency) {\n return this.runQueuedTask(task);\n }\n\n return new Promise<T>((resolvePromise, rejectPromise) => {\n this.queue.push(() => {\n void this.runQueuedTask(task).then(resolvePromise, rejectPromise);\n });\n });\n }\n\n private async runQueuedTask<T>(task: () => Promise<T>): Promise<T> {\n this.activeCount += 1;\n\n try {\n return await task();\n } finally {\n this.activeCount -= 1;\n const nextTask = this.queue.shift();\n if (nextTask) {\n nextTask();\n }\n }\n }\n\n private async resolveTarget(\n request: CompanionIntrospectionRequest,\n ): Promise<CompanionIntrospectionResolvedTarget> {\n const serviceDefinition = this.companionContext.servicesByKey[request.serviceKey];\n if (!serviceDefinition) {\n /*\n * A caller's bad input, so it must answer 4xx CARRYING ITS MESSAGE — the same contract\n * `IntrospectionInputValidationError` was introduced for (#1459). A plain `Error` here is\n * sanitized to a bodyless 500, and the CLI's health hint then fires on a companion that is\n * demonstrably up, sending the reader to check a process instead of their own argument.\n *\n * The likeliest way to get here is passing a service NAME where the key is wanted\n * (`--service scratch-journey-app` for the service keyed `app`), which is why the valid keys\n * are named rather than merely the rejected one.\n */\n throw new IntrospectionInputValidationError(\n `Unknown SaaS service key \"${request.serviceKey}\". This application declares: `\n + `${Object.keys(this.companionContext.servicesByKey).sort().map((key) => `\"${key}\"`).join(', ')}.`,\n );\n }\n\n const serviceKind = this.resolveServiceKind(serviceDefinition);\n const resolvedBehavior = this.behaviorRegistryService.resolveBehaviorForServiceKind(\n request.behavior,\n serviceKind,\n );\n\n const resolvedTargets = this.resolveCompanionTargets(serviceDefinition);\n const missingTargets = [resolvedBehavior.route.target, ...(resolvedBehavior.route.requiredTargets ?? [])]\n .filter((targetId, index, allTargetIds) => allTargetIds.indexOf(targetId) === index)\n .filter((targetId) => !resolvedTargets[targetId]);\n if (missingTargets.length > 0) {\n // Also the caller's: they named a service that cannot serve this behavior, and the message\n // says which targets are missing — so it must survive sanitization like the key above.\n throw new IntrospectionInputValidationError(\n `Behavior \"${request.behavior}\" requires config-declared target(s) ${missingTargets.map((targetId) => `\"${targetId}\"`).join(', ')}, but they are not declared or resolvable for service \"${request.serviceKey}\".`,\n );\n }\n const behaviorTarget = resolvedTargets[resolvedBehavior.route.target]!;\n\n const servicePath = resolve(this.companionContext.saasRoot, serviceDefinition.path);\n\n return {\n serviceKey: request.serviceKey,\n servicePath,\n serviceName: serviceDefinition.serviceName,\n serviceKind,\n behavior: request.behavior,\n behaviorCategory: resolvedBehavior.category,\n materializationKind: resolvedBehavior.execution.materializationKind,\n targetId: resolvedBehavior.route.target,\n packageRoot: behaviorTarget.packageRoot,\n entryPath: behaviorTarget.entryPath,\n resolvedTargets,\n resolvedBehavior,\n input: request.input,\n };\n }\n\n private resolveServiceKind(\n serviceDefinition: CompanionContext['servicesByKey'][string],\n ): CompanionIntrospectionServiceKind {\n return serviceDefinition.frontendType ? 'frontend' : 'backend';\n }\n\n private async runSubprocess(\n target: CompanionIntrospectionResolvedTarget,\n ): Promise<CompanionIntrospectionResult> {\n const childRequest = this.buildChildRequest(target);\n const launchContext = this.resolveSubprocessLaunchContext();\n\n return new Promise<CompanionIntrospectionResult>((resolvePromise) => {\n const startedAt = Date.now();\n const child = this.spawnSubprocess(process.execPath, [\n /*\n * Silence tsx's own deprecation warning at the SOURCE.\n *\n * `tsx` registers its ESM hooks through `module.register()`, which Node 26 deprecates\n * (DEP0205). The warning is emitted by a dependency on every single introspection call, it\n * says nothing about this application, and there is nothing an application developer can do\n * about it — but it lands in the child's stderr, which is buffered and logged, so it\n * DOMINATED the one place a reader looks to find out what an introspection actually did.\n *\n * Suppressed here rather than filtered out of the log: a warning that is never emitted cannot\n * be mistaken for output, and filtering would leave the next reader wondering whether the\n * filter is hiding something real. Scoped to this ONE code, so a genuine future deprecation\n * still surfaces.\n */\n '--disable-warning=DEP0205',\n '--import',\n 'tsx',\n '--import',\n launchContext.assetNoopRegisterPath,\n launchContext.runnerPath,\n ], {\n cwd: launchContext.cwd,\n env: buildSubprocessEnv(),\n stdio: ['ignore', 'pipe', 'pipe', 'ipc'],\n });\n\n let stdout = '';\n let stderr = '';\n let settled = false;\n let parsedResult: CompanionIntrospectionResult | null = null;\n let pendingFailure: CompanionIntrospectionFailureResult | null = null;\n let naturalExitHandle: NodeJS.Timeout | null = null;\n let forceKillHandle: NodeJS.Timeout | null = null;\n\n /*\n * The child's output, as TWO named fields rather than one ` | `-joined blob.\n *\n * The blob was unreadable in practice: a routine success printed one useful line of stdout\n * glued to a multi-line third-party deprecation warning, and a reader could not tell at a\n * glance whether an introspection had worked, what it had found, or whether the stderr meant\n * anything. Stdout and stderr answer different questions — what it DID versus what went WRONG —\n * and joining them makes the log answer neither.\n */\n const buildOutputContext = (): { stdout?: string; stderr?: string } | undefined => {\n const trimmedStdout = stdout.trim();\n const trimmedStderr = stderr.trim();\n if (trimmedStdout.length === 0 && trimmedStderr.length === 0) return undefined;\n return {\n ...(trimmedStdout.length > 0 ? { stdout: trimmedStdout } : {}),\n ...(trimmedStderr.length > 0 ? { stderr: trimmedStderr } : {}),\n };\n };\n\n /** One line for a message that has no room for two fields. */\n const describeOutputContext = (context: { stdout?: string; stderr?: string } | undefined): string =>\n context === undefined\n ? ''\n : [\n ...(context.stdout ? [`stdout: ${context.stdout}`] : []),\n ...(context.stderr ? [`stderr: ${context.stderr}`] : []),\n ].join(' | ');\n\n const onStdout = (chunk: Buffer | string) => {\n stdout += chunk.toString();\n };\n const onStderr = (chunk: Buffer | string) => {\n stderr += chunk.toString();\n };\n child.stdout?.on('data', onStdout);\n child.stderr?.on('data', onStderr);\n\n const clearTimer = (handle: NodeJS.Timeout | null): void => {\n if (handle !== null) clearTimeout(handle);\n };\n\n const cleanup = () => {\n clearTimeout(timeoutHandle);\n clearTimer(naturalExitHandle);\n clearTimer(forceKillHandle);\n child.off('spawn', onSpawn);\n child.off('message', onMessage);\n child.off('error', onError);\n child.off('close', onClose);\n child.stdout?.off('data', onStdout);\n child.stderr?.off('data', onStderr);\n };\n\n const finalize = (result: CompanionIntrospectionResult) => {\n if (settled) {\n return;\n }\n\n settled = true;\n cleanup();\n const finalResult = {\n ...result,\n stdout: stdout || undefined,\n stderr: stderr || undefined,\n };\n resolvePromise(finalResult);\n };\n\n const requestTermination = (failure: CompanionIntrospectionFailureResult): void => {\n if (pendingFailure === null) pendingFailure = failure;\n clearTimeout(timeoutHandle);\n clearTimer(naturalExitHandle);\n naturalExitHandle = null;\n if (forceKillHandle !== null) return;\n try {\n child.kill('SIGTERM');\n } catch {\n // A concurrent exit can make kill throw; settlement still waits for\n // the terminal `close` event rather than guessing process state.\n }\n forceKillHandle = setTimeout(() => {\n try {\n child.kill('SIGKILL');\n } catch {\n // The terminal `close` event remains the only settlement signal.\n }\n }, 1_000);\n };\n\n const onSpawn = () => {\n child.send?.(childRequest);\n };\n\n const onMessage = (message: unknown) => {\n clearTimeout(timeoutHandle);\n if (pendingFailure !== null) return;\n if (parsedResult !== null) {\n requestTermination(this.buildFailureResult(target, startedAt, {\n message: 'Companion introspection subprocess returned more than one result payload.',\n name: 'CompanionIntrospectionDuplicateResultError',\n }));\n return;\n }\n try {\n parsedResult = CompanionIntrospectionResultSchema.parse(message) as CompanionIntrospectionResult;\n // A valid payload is provisional until the child proves that no late\n // failure occurred. Give the normal child one bounded window to\n // disconnect and exit cleanly before beginning termination.\n naturalExitHandle = setTimeout(() => {\n requestTermination(this.buildFailureResult(target, startedAt, {\n message: 'Companion introspection subprocess returned a result but did not exit cleanly within 1000ms.',\n name: 'CompanionIntrospectionResultExitTimeoutError',\n }));\n }, 1_000);\n } catch (error) {\n // describeCaughtError: N/A — this `try` wraps exactly one statement,\n // `CompanionIntrospectionResultSchema.parse(message)`, which throws a `ZodError`.\n // No engine service is called inside it, so a `WildoError_Backend` (a plain\n // object, which the test below would reject) cannot reach here. The site also\n // needs `.name` and `.stack`, which the string helper does not carry. Left as-is\n // deliberately, not overlooked by the 2026-08-21 sweep.\n const standardError = error instanceof Error ? error : new Error('Invalid companion introspection subprocess payload.');\n requestTermination(this.buildFailureResult(target, startedAt, {\n message: standardError.message,\n name: standardError.name,\n stack: standardError.stack,\n }));\n }\n };\n\n const onError = (error: Error) => {\n requestTermination(this.buildFailureResult(target, startedAt, {\n message: error.message,\n name: error.name,\n stack: error.stack,\n }));\n };\n\n const onClose = (code: number | null, signal: NodeJS.Signals | null) => {\n if (settled) return;\n const outputContext = buildOutputContext();\n if (outputContext) {\n /*\n * Named for what the reader wants to know — WHICH introspection, and whether it went\n * cleanly — rather than for the mechanism. \"exited with buffered output\" described the\n * plumbing and left the behavior buried in a field.\n */\n const cleanExit = code === 0 && signal === null;\n this.logDebug(\n `Companion introspection \"${target.behavior}\" on \"${target.serviceKey}\" ${cleanExit ? 'completed' : `exited code=${code ?? 'null'} signal=${signal ?? 'null'}`}`,\n {\n serviceKey: target.serviceKey,\n behavior: target.behavior,\n targetId: target.targetId,\n code,\n signal,\n ...outputContext,\n },\n );\n }\n if (pendingFailure !== null) {\n finalize(pendingFailure);\n return;\n }\n if (parsedResult !== null && code === 0 && signal === null) {\n finalize(parsedResult);\n return;\n }\n if (parsedResult !== null && parsedResult.success === false) {\n finalize(parsedResult);\n return;\n }\n /*\n * A signal THIS SERVICE DID NOT SEND means the kill came from outside, and saying so is the\n * difference between an actionable message and a misleading one.\n *\n * Every termination this service performs goes through `requestTermination`, which sets\n * `pendingFailure` BEFORE killing — and the branch above returns that failure. So reaching\n * here with a termination signal proves nobody here asked for it: the child died because its\n * PARENT did, taking the process group with it.\n *\n * In a dev loop that is the supervisor restarting the companion. Measured 2026-09-02 across\n * four session logs: 30 such failures at a median of 11.4 s — nowhere near the 30 s ceiling —\n * and the line immediately preceding each one is\n * `[runtime-supervisor:wildo-dev-companion] Stopping runtime before readiness...`.\n *\n * The old message named the subprocess as the thing that exited, which is true and useless:\n * it reads as a fault in the derivation, and `signal=SIGTERM` beside a 30 s timeout constant\n * reads as that timeout firing. It cost a full investigation before the log said otherwise.\n */\n const terminatedFromOutside = wasTerminatedFromOutside({\n signal,\n hasPendingFailure: pendingFailure !== null,\n hasParsedResult: parsedResult !== null,\n });\n\n finalize(this.buildFailureResult(target, startedAt, terminatedFromOutside\n ? {\n message: `Companion introspection was terminated by ${signal} that this service did not send — the companion process itself is stopping, so the derivation was cut short rather than failing. Re-run it once the companion is ready.`,\n name: 'CompanionIntrospectionParentTerminatedError',\n }\n : {\n message: parsedResult === null\n ? `Companion introspection subprocess exited before returning a result (code=${code ?? 'null'}, signal=${signal ?? 'null'})${outputContext ? ` — ${describeOutputContext(outputContext)}` : ''}.`\n : `Companion introspection subprocess returned a result then exited unsuccessfully (code=${code ?? 'null'}, signal=${signal ?? 'null'}).`,\n name: 'CompanionIntrospectionSubprocessExitError',\n }));\n };\n\n const timeoutHandle = setTimeout(() => {\n requestTermination(this.buildFailureResult(target, startedAt, {\n message: `Companion introspection timed out after ${this.timeoutMs}ms.`,\n name: 'CompanionIntrospectionTimeoutError',\n }));\n }, this.timeoutMs);\n\n child.on('spawn', onSpawn);\n child.on('message', onMessage);\n child.on('error', onError);\n // `close`, unlike `message` or `exit`, proves that the process and its\n // stdio handles are all quiescent. The parent never releases its queue\n // slot while the child can still emit output or fail late.\n child.on('close', onClose);\n });\n }\n\n private buildChildRequest(\n target: CompanionIntrospectionResolvedTarget,\n ): CompanionIntrospectionChildRequest {\n return {\n behavior: target.behavior,\n serviceKind: target.serviceKind,\n behaviorCategory: target.behaviorCategory,\n materializationKind: target.materializationKind,\n targetId: target.targetId,\n serviceKey: target.serviceKey,\n entryPath: target.entryPath,\n packageRoot: target.packageRoot,\n homes: this.buildChildHomesSnapshot(),\n resolvedTargets: target.resolvedTargets,\n input: target.input,\n };\n }\n\n /**\n * Resolve subprocess launch paths from THIS MODULE's own location, never from\n * `companionHome/src`. Under dist-only delivery (issue #64) the application's\n * `.wildo-saas/wildo-dev-companion` drop contains no source tree at all — the child runner and\n * the asset-noop register ship as COMPILED siblings of this service inside `dist/esm`, so the\n * only location that is guaranteed to hold them is the directory graph this very module runs\n * from. When the suite executes the source directly (vitest resolves the `.ts` module), the\n * sibling files are the authored `.ts` sources and the child is executable because the spawn\n * always registers `tsx` before the register hook. `cwd` stays the application's companion\n * home: the child resolves app packages and `node_modules` (including `tsx` itself) from there.\n */\n private resolveSubprocessLaunchContext(): {\n cwd: string;\n runnerPath: string;\n assetNoopRegisterPath: string;\n } {\n const isSourceExecution = import.meta.url.endsWith('.ts');\n const subprocessDir = fileURLToPath(new URL('../subprocess/', import.meta.url));\n return {\n cwd: this.companionContext.companionHome,\n runnerPath: join(subprocessDir, isSourceExecution ? 'companion-introspection-child.ts' : 'companion-introspection-child.js'),\n assetNoopRegisterPath: join(subprocessDir, isSourceExecution ? 'asset-noop-register.ts' : 'asset-noop-register.js'),\n };\n }\n\n private buildChildHomesSnapshot(): CompanionIntrospectionHomesSnapshot {\n const appLayout = this.companionContext.resolvedHomes.app.layout;\n if (!appLayout) {\n throw new Error('Companion introspection requires an app layout in the trusted homes snapshot.');\n }\n\n return {\n appDeclarationRoot: appLayout.declarationRoot,\n appRuntimeHome: appLayout.runtimeHome,\n companionHome: this.companionContext.companionHome,\n frameworkRepositoryRoot: this.companionContext.resolvedHomes.framework.repositoryRoot,\n };\n }\n\n private resolveCompanionTargets(\n serviceDefinition: CompanionContext['servicesByKey'][string],\n ): Partial<Record<CompanionIntrospectionRouteTargetId, CompanionIntrospectionResolvedPackageTarget>> {\n const sharedLibrary = this.companionContext.resolvedLibraries.shared;\n const resolvedLibraryTarget = sharedLibrary?.libraryType === AppLibraryType.FULLSTACK\n ? {\n targetId: 'library' as const,\n packageRoot: sharedLibrary.packageRoot,\n entryPath: sharedLibrary.entryPath,\n declaredPath: sharedLibrary.declaredPath,\n }\n : undefined;\n\n return {\n service: this.tryResolveCompanionTarget('service', serviceDefinition.path),\n library: resolvedLibraryTarget,\n specifications: this.companionContext.resolvedSpecifications\n ? {\n targetId: 'specifications',\n packageRoot: this.companionContext.resolvedSpecifications.packageRoot,\n entryPath: this.companionContext.resolvedSpecifications.entryPath,\n declaredPath: this.companionContext.resolvedSpecifications.declaredPath,\n }\n : undefined,\n };\n }\n\n private tryResolveCompanionTarget(\n targetId: CompanionIntrospectionRouteTargetId,\n declaredPath: string,\n ): CompanionIntrospectionResolvedPackageTarget | undefined {\n const packageRoot = resolve(this.companionContext.saasRoot, declaredPath);\n\n try {\n return {\n targetId,\n packageRoot,\n entryPath: resolvePackageCompanionEntryPath(packageRoot),\n declaredPath,\n };\n } catch {\n return undefined;\n }\n }\n\n private buildFailureResult(\n target: CompanionIntrospectionResolvedTarget,\n startedAt: number,\n error: CompanionIntrospectionErrorDetails,\n ): CompanionIntrospectionFailureResult {\n return {\n success: false,\n behavior: target.behavior,\n serviceKey: target.serviceKey,\n serviceKind: target.serviceKind,\n behaviorCategory: target.behaviorCategory,\n materializationKind: target.materializationKind,\n targetId: target.targetId,\n durationMs: Date.now() - startedAt,\n error,\n };\n }\n}\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"introspection-derivation-state.companion.service.d.ts","sourceRoot":"","sources":["../../../../../src/core/introspection/services/introspection-derivation-state.companion.service.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,4BAA4B,CAAC;AAIhE,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,iCAAiC,CAAC;AACxE,OAAO,EAAE,gCAAgC,EAAE,MAAM,gDAAgD,CAAC;AAClG,OAAO,KAAK,EACV,4BAA4B,EAC5B,mCAAmC,EACpC,MAAM,0CAA0C,CAAC;AAElD;;;;;;;;;;;;GAYG;AACH,oBAAY,0BAA0B;IACpC,iFAAiF;IACjF,gBAAgB,qBAAqB;IACrC,sFAAsF;IACtF,IAAI,SAAS;CACd;AAED,0FAA0F;AAC1F,oBAAY,4BAA4B;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C,KAAK;CAqCd;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+BG;AACH,wBAAgB,0BAA0B,CACxC,IAAI,EAAE,mCAAmC,GAAG,SAAS,EACrD,KAAK,EAAE,mCAAmC,GAAG,SAAS,GACrD,OAAO,CAGT"}
1
+ {"version":3,"file":"introspection-derivation-state.companion.service.d.ts","sourceRoot":"","sources":["../../../../../../src/core/introspection/services/introspection-derivation-state.companion.service.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,4BAA4B,CAAC;AAIhE,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,iCAAiC,CAAC;AACxE,OAAO,EAAE,gCAAgC,EAAE,MAAM,gDAAgD,CAAC;AAClG,OAAO,KAAK,EACV,4BAA4B,EAC5B,mCAAmC,EACpC,MAAM,0CAA0C,CAAC;AAElD;;;;;;;;;;;;GAYG;AACH,oBAAY,0BAA0B;IACpC,iFAAiF;IACjF,gBAAgB,qBAAqB;IACrC,sFAAsF;IACtF,IAAI,SAAS;CACd;AAED,0FAA0F;AAC1F,oBAAY,4BAA4B;IACtC,mDAAmD;IACnD,eAAe,oBAAoB;IACnC,sFAAsF;IACtF,cAAc,mBAAmB;IACjC,iDAAiD;IACjD,SAAS,cAAc;IACvB,6CAA6C;IAC7C,SAAS,cAAc;CACxB;AAED;;GAEG;AACH,MAAM,WAAW,+BAA+B;IAC9C;;;;;;;OAOG;IACH,QAAQ,CAAC,MAAM,EAAE,mCAAmC,CAAC;IACrD,wDAAwD;IACxD,QAAQ,CAAC,gBAAgB,EAAE,MAAM,CAAC;IAClC;;;;;;;;OAQG;IACH,QAAQ,CAAC,UAAU,EAAE,MAAM,CAAC;IAC5B,+EAA+E;IAC/E,QAAQ,CAAC,UAAU,EAAE,MAAM,CAAC;CAC7B;AAED,kGAAkG;AAClG,MAAM,WAAW,6BAA6B;IAC5C,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAC;IAC1B,QAAQ,CAAC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AE,EAC/F,OAAO,EAAE,MAAM,OAAO,CAAC,4BAA4B,CAAC,GACnD,OAAO,CAAC,4BAA4B,CAAC;IA4BxC;;;;;OAKG;YACW,0BAA0B;IAqCxC;;;;;;;;;;;OAWG;IACU,sBAAsB,CACjC,MAAM,EAAE,4BAA4B,GACnC,OAAO,CAAC;QAAE,QAAQ,CAAC,KAAK,EAAE,OAAO,CAAC;QAAC,QAAQ,CAAC,QAAQ,EAAE,SAAS,6BAA6B,EAAE,CAAA;KAAE,CAAC;IA2DpG;;;;;OAKG;IACH,IAAW,uBAAuB,IAAI,MAAM,CAE3C;IAED,4FAA4F;IACrF,YAAY,CAAC,QAAQ,EAAE,MAAM,GAAG,MAAM,GAAG,SAAS;IAIzD;;;;;OAKG;IACI,KAAK,IAAI,IAAI;IAKpB;;;OAGG;IACI,kBAAkB,CAAC,QAAQ,EAAE,MAAM,GAAG,IAAI;IAIjD,iGAAiG;IAC1F,gCAAgC,CAAC,QAAQ,EAAE,gCAAgC,GAAG,IAAI;IAIzF;;;;;;OAMG;YACW,WAAW;IA6CzB,6FAA6F;IAC7F,OAAO,CAAC,KAAK;CAqCd;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+BG;AACH,wBAAgB,0BAA0B,CACxC,IAAI,EAAE,mCAAmC,GAAG,SAAS,EACrD,KAAK,EAAE,mCAAmC,GAAG,SAAS,GACrD,OAAO,CAGT"}
@@ -149,13 +149,17 @@ let IntrospectionDerivationStateCompanionService = class IntrospectionDerivation
149
149
  }
150
150
  const held = this.state.get(identity.cacheKey);
151
151
  if (held) {
152
+ const ageMs = Date.now() - held.compiledAt;
152
153
  this.logDebug('Introspection derivation served from compiled state', {
153
154
  behavior: identity.behavior,
154
155
  serviceKey: identity.serviceKey,
155
- ageMs: Date.now() - held.compiledAt,
156
+ ageMs,
156
157
  generation: held.generation,
157
158
  });
158
- return { ...held.result, servedFromCache: true };
159
+ // The age TRAVELS now (#1437). It was computed here for a debug line while the consumer that
160
+ // needs it — one deciding whether a held answer still describes the tree it is about to edit —
161
+ // could not see it.
162
+ return { ...held.result, servedFromCache: true, derivationAgeMs: ageMs };
159
163
  }
160
164
  return (await this.compileInto(identity.cacheKey, IntrospectionRecompileReason.COLD_READ))
161
165
  ?? compile();
@@ -175,7 +179,11 @@ let IntrospectionDerivationStateCompanionService = class IntrospectionDerivation
175
179
  serviceKey: identity.serviceKey,
176
180
  sourceObservationMs: observation.durationMs,
177
181
  });
178
- return { ...held.result, servedFromCache: true };
182
+ // BOTH read paths, and stating why they differ: this one has already checked the source token,
183
+ // so the age says how long ago the answer was taken rather than how long it MIGHT be stale.
184
+ // Reporting it on only one path would make the field mean different things per freshness mode,
185
+ // which is worse than not having it.
186
+ return { ...held.result, servedFromCache: true, derivationAgeMs: Date.now() - held.compiledAt };
179
187
  }
180
188
  /*
181
189
  * Routed through `compileInto` rather than calling the closure here, because that is where the
@@ -1 +1 @@
1
- {"version":3,"file":"introspection-derivation-state.companion.service.js","sourceRoot":"","sources":["../../../../../../src/core/introspection/services/introspection-derivation-state.companion.service.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,OAAO,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,WAAW,CAAC;AAE/C,OAAO,EAAE,kBAAkB,EAAE,MAAM,4BAA4B,CAAC;AAEhE,OAAO,EAAE,uBAAuB,EAAE,MAAM,mCAAmC,CAAC;AAE5E,OAAO,EAAE,gCAAgC,EAAE,MAAM,gDAAgD,CAAC;AAMlG;;;;;;;;;;;;GAYG;AACH,MAAM,CAAN,IAAY,0BAKX;AALD,WAAY,0BAA0B;IACpC,iFAAiF;IACjF,mEAAqC,CAAA;IACrC,sFAAsF;IACtF,2CAAa,CAAA;AACf,CAAC,EALW,0BAA0B,KAA1B,0BAA0B,QAKrC;AAED,0FAA0F;AAC1F,MAAM,CAAN,IAAY,4BASX;AATD,WAAY,4BAA4B;IACtC,mDAAmD;IACnD,mEAAmC,CAAA;IACnC,sFAAsF;IACtF,iEAAiC,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Content":["import { inject, injectable } from 'inversify';\nimport type { LoggerService } from '@wildo-ai/saas-backend-lib';\nimport { SAAS_SERVICE_TYPES } from '@wildo-ai/saas-backend-lib';\n\nimport { COMPANION_SERVICE_TYPES } from '../../inject/models/service-types';\nimport type { CompanionContext } from '../../context/companion-context';\nimport { IntrospectionSourceStateObserver } from './introspection-source-state.companion.service';\nimport type {\n CompanionIntrospectionResult,\n CompanionIntrospectionSuccessResult,\n} from '../models/companion-introspection.models';\n\n/**\n * How a derivation's freshness is currently decided.\n *\n * The two modes are not a preference. `OBSERVE_PER_READ` is exactly the behaviour issue #159 shipped\n * — sweep the source on every read, serve the memo only when the token still matches — and it is the\n * FALLBACK, kept because it is correct without any collaborator. `PUSH` is the mode this service\n * exists for: a freshness authority (the source watcher) tells the state when the source moved, so a\n * read consults nothing but memory.\n *\n * The service starts in `OBSERVE_PER_READ` and is promoted only when an authority registers. That\n * ordering is deliberate: a companion whose watcher failed to start, or a unit test that wires none,\n * degrades to slow-and-correct rather than to fast-and-stale.\n */\nexport enum IntrospectionFreshnessMode {\n /** No authority registered. Every read sweeps, exactly as issue #159 left it. */\n OBSERVE_PER_READ = 'observe-per-read',\n /** An authority is live. Reads consult memory; the authority drives recompilation. */\n PUSH = 'push',\n}\n\n/** Why a recompilation was triggered, carried into the log line and the change report. */\nexport enum IntrospectionRecompileReason {\n /** The freshness authority saw the source move. */\n SOURCE_MUTATION = 'source-mutation',\n /** The periodic reconciliation sweep found a token the authority had not reported. */\n RECONCILIATION = 'reconciliation',\n /** Startup warming, before anybody has asked. */\n BOOT_WARM = 'boot-warm',\n /** A read found no compiled state at all. */\n COLD_READ = 'cold-read',\n}\n\n/**\n * One compiled derivation, and everything a consumer needs to talk about it without recompiling.\n */\nexport interface IntrospectionCompiledDerivation {\n /**\n * The child's answer, exactly as `requestInfo` would have returned it.\n *\n * Typed as the SUCCESS result rather than the union, because only a success is ever retained —\n * see `store`. That is not a narrowing for convenience: `servedFromCache` exists only on the\n * success arm, so a union here would make the flag unassignable, and the type is the place that\n * says a failure is never held.\n */\n readonly result: CompanionIntrospectionSuccessResult;\n /** The source-state token this was compiled against. */\n readonly sourceStateToken: string;\n /**\n * A monotonically increasing stamp for this derivation, used as the WebSocket sync `version`.\n *\n * **It must never go backwards, including across a companion restart.** `ResourceMutationManager`\n * drops any pushed update whose `version <= this._version`, so a counter that resets to zero on\n * restart makes every browser tab that stayed open ignore every later update — silently, with no\n * error and no refetch, leaving a permanently frozen view. Wall-clock milliseconds cannot regress\n * across a restart, which is the whole reason they are used here rather than a counter.\n */\n readonly generation: number;\n /** When this was compiled, for the debug line that explains a lookup's age. */\n readonly compiledAt: number;\n}\n\n/** What one recompilation did, per derivation, so a caller can emit a diff without re-reading. */\nexport interface IntrospectionRecompileOutcome {\n readonly cacheKey: string;\n readonly behavior: string;\n readonly serviceKey: string;\n /** The state before, absent on a first compile. */\n readonly previous: IntrospectionCompiledDerivation | undefined;\n /** The state after. Absent when the recompilation FAILED and the previous state was kept. */\n readonly next: IntrospectionCompiledDerivation | undefined;\n /** `false` when the recompilation produced a byte-identical payload — nothing to notify about. */\n readonly changed: boolean;\n}\n\n/** A registered derivation the state service knows how to recompile without being asked again. */\ninterface KnownDerivation {\n readonly cacheKey: string;\n readonly behavior: string;\n readonly serviceKey: string;\n /** The closure that compiles this exact question. Held so recompilation needs no caller. */\n readonly compile: () => Promise<CompanionIntrospectionResult>;\n}\n\n/**\n * Owns COMPILED introspection state, so that reading one is not the act that compiles it.\n *\n * ## Why this is a separate service rather than a better cache\n *\n * Before this, compilation and retrieval were the same code path: `requestInfo` observed the source,\n * compared a token, and compiled on a miss — all inside the caller's request. That fusion has three\n * consequences that no amount of cache tuning removes.\n *\n * 1. **Every read pays the freshness probe.** Measured on wonder-crm, 2026-09-02: a warm\n * `LIST /api/v1/workbench-domain-resources` answered in 200–270 ms, of which the source sweep is\n * 180–225 ms. The cache was working perfectly and almost all of the remaining latency was the act\n * of asking whether it could be used.\n * 2. **A miss is charged to whoever happened to ask.** Same session: a cold `LIST` cost 8.95 s and an\n * addressed `READ` cost 44.4 s, then 500. In a tree with the engine's `tsc-watch` fleet running,\n * the token moves constantly, so a miss is the NORMAL case rather than the exception.\n * 3. **Nothing can be notified.** A pull-shaped cache learns that the source moved only while\n * somebody is waiting for an answer, so there is no moment at which it could tell a frontend that\n * a row changed. Push requires knowing BEFORE the read.\n *\n * Separating the two makes each answerable on its own terms: compilation is triggered by the source\n * moving, retrieval is a map lookup, and the moment between them is where a notification can exist.\n *\n * ## What this holds is TIME, never TRUTH\n *\n * `one-source-of-truth.md` Rule 5: this is per-run runtime state. Deleting all of it costs a\n * recompilation and changes no answer — {@link clear} is the proof obligation, and the byte-identical\n * payload across it is the test. Nothing here is a ledger, nothing is persisted, and no decision\n * anywhere may be made from the absence of an entry.\n */\n@injectable()\nexport class IntrospectionDerivationStateCompanionService {\n private readonly logDebug: (message: string, context?: Record<string, unknown>) => void;\n private readonly state = new Map<string, IntrospectionCompiledDerivation>();\n private readonly known = new Map<string, KnownDerivation>();\n /** Recompilations currently running, so two triggers cannot compile the same question twice. */\n private readonly inFlight = new Map<string, Promise<CompanionIntrospectionResult>>();\n private readonly observer: IntrospectionSourceStateObserver;\n private freshnessMode: IntrospectionFreshnessMode = IntrospectionFreshnessMode.OBSERVE_PER_READ;\n private freshnessAuthorityName: string | undefined;\n /** The token the state was last compiled against, in `PUSH` mode. */\n private currentToken: string | undefined;\n private lastGeneration = 0;\n\n constructor(\n @inject(SAAS_SERVICE_TYPES.Logger) private readonly logger: LoggerService,\n @inject(COMPANION_SERVICE_TYPES.CompanionContext) private readonly companionContext: CompanionContext,\n ) {\n this.logDebug = this.logger.debugByType('IntrospectionDerivationState');\n this.logger.setDebugTypeLogging('IntrospectionDerivationState', true);\n this.observer = new IntrospectionSourceStateObserver(this.companionContext);\n }\n\n public get mode(): IntrospectionFreshnessMode {\n return this.freshnessMode;\n }\n\n /**\n * Promote the service out of per-read observation.\n *\n * Called by the source watcher once it is actually watching. The name is carried so an operator\n * reading a log line can tell WHICH authority is responsible for freshness, and so a second\n * registration is visible rather than silent.\n */\n public registerFreshnessAuthority(name: string): void {\n this.freshnessAuthorityName = name;\n this.freshnessMode = IntrospectionFreshnessMode.PUSH;\n this.logger.info('Introspection derivation state promoted to push freshness', { authority: name });\n }\n\n /**\n * Demote back to per-read observation.\n *\n * The watcher calls this when it errors or closes. Demoting is always safe and never wrong — it\n * only costs time — whereas staying in `PUSH` with a dead authority serves a tree that has moved.\n */\n public noteFreshnessAuthorityLost(reason: string): void {\n if (this.freshnessMode === IntrospectionFreshnessMode.OBSERVE_PER_READ) return;\n this.freshnessMode = IntrospectionFreshnessMode.OBSERVE_PER_READ;\n this.logger.warn('Introspection freshness authority lost; falling back to per-read source observation', {\n authority: this.freshnessAuthorityName,\n reason,\n });\n this.freshnessAuthorityName = undefined;\n }\n\n /**\n * Read a derivation, compiling only when there is nothing to read.\n *\n * `compile` is retained against the cache key on first sight, which is what lets a later\n * source mutation recompile this question with no caller present. That is the whole mechanism by\n * which retrieval stops driving compilation: the FIRST read teaches the service the question, and\n * every subsequent answer — including the ones nobody asked for yet — is produced by the source\n * moving instead.\n *\n * In `OBSERVE_PER_READ` mode the freshness probe still runs here, because without an authority\n * there is nothing else that could run it.\n */\n public async read(\n identity: { readonly cacheKey: string; readonly behavior: string; readonly serviceKey: string },\n compile: () => Promise<CompanionIntrospectionResult>,\n ): Promise<CompanionIntrospectionResult> {\n if (!this.known.has(identity.cacheKey)) {\n this.known.set(identity.cacheKey, { ...identity, compile });\n }\n\n if (this.freshnessMode === IntrospectionFreshnessMode.OBSERVE_PER_READ) {\n return this.readWithPerReadObservation(identity, compile);\n }\n\n const held = this.state.get(identity.cacheKey);\n if (held) {\n this.logDebug('Introspection derivation served from compiled state', {\n behavior: identity.behavior,\n serviceKey: identity.serviceKey,\n ageMs: Date.now() - held.compiledAt,\n generation: held.generation,\n });\n return { ...held.result, servedFromCache: true };\n }\n\n return (await this.compileInto(identity.cacheKey, IntrospectionRecompileReason.COLD_READ))\n ?? compile();\n }\n\n /**\n * The pre-#159-separation path, kept verbatim in behaviour for the no-authority case.\n *\n * A read observes the source, serves the held derivation when the token still matches, and\n * compiles otherwise. Slower by exactly one sweep per read, and correct with no collaborator.\n */\n private async readWithPerReadObservation(\n identity: { readonly cacheKey: string; readonly behavior: string; readonly serviceKey: string },\n compile: () => Promise<CompanionIntrospectionResult>,\n ): Promise<CompanionIntrospectionResult> {\n const observation = await this.observer.observe(Date.now());\n const held = this.state.get(identity.cacheKey);\n if (held && held.sourceStateToken === observation.token) {\n this.logDebug('Introspection derivation served from compiled state (per-read observation)', {\n behavior: identity.behavior,\n serviceKey: identity.serviceKey,\n sourceObservationMs: observation.durationMs,\n });\n return { ...held.result, servedFromCache: true };\n }\n\n /*\n * Routed through `compileInto` rather than calling the closure here, because that is where the\n * in-flight join lives. `maxConcurrency` caps how many subprocesses run at once; it does not\n * notice that two of them are asking the identical question. Two concurrent reads of one\n * behavior must cost ONE subprocess, and calling the closure directly would silently\n * reintroduce the second child.\n *\n * `bounded: false` means the sweep gave up before seeing the whole tree, so its token says\n * nothing about whether the source moved. Compiling is still correct; RETAINING against that\n * token would not be — which is why the token is handed over only when the sweep completed.\n */\n return (await this.compileInto(\n identity.cacheKey,\n IntrospectionRecompileReason.COLD_READ,\n observation.bounded ? observation.token : undefined,\n )) ?? compile();\n }\n\n /**\n * Recompile everything this service knows about, if the source has actually moved.\n *\n * Returns one outcome per known derivation, with `changed` telling the caller whether anything\n * downstream needs to hear about it. A recompilation that produces a byte-identical payload is\n * reported as unchanged, because an operator saving a file that alters nothing observable must not\n * produce a wave of notifications.\n *\n * A FAILED recompilation keeps the previous state rather than dropping it. The dominant failure\n * here is an application mid-build, and answering \"could not look\" for the seconds a `tsc` takes —\n * when a correct answer from one second ago is in hand — is worse than answering slightly late.\n */\n public async recompileIfSourceMoved(\n reason: IntrospectionRecompileReason,\n ): Promise<{ readonly moved: boolean; readonly outcomes: readonly IntrospectionRecompileOutcome[] }> {\n const observation = await this.observer.observe(Date.now());\n if (!observation.bounded) {\n this.logger.warn('Introspection source observation exceeded its ceiling; recompiling without remembering', {\n reason,\n observedEntryCount: observation.observedEntryCount,\n });\n }\n\n if (this.currentToken === observation.token && observation.bounded) {\n return { moved: false, outcomes: [] };\n }\n this.currentToken = observation.bounded ? observation.token : undefined;\n\n /*\n * Snapshot every previous state BEFORE compiling any of them.\n *\n * `store` prunes entries taken against a superseded token, so the FIRST compilation of this loop\n * deletes every OTHER derivation's previous state — they still carry the old token. Reading\n * `previous` inside the loop therefore returned `undefined` for every derivation after the first,\n * and each one reported its whole row set as CREATED.\n *\n * Measured before the fix on wonder-crm: 180 publications in three minutes, every one of them\n * `created: N, updated: 0, deleted: 0` — a full-repaint storm, the exact opposite of what the\n * diff exists to produce. Found by reading the live log rather than by a test, which is why the\n * regression pin below compares TWO derivations rather than one.\n */\n const previousByKey = new Map<string, IntrospectionCompiledDerivation>();\n for (const entry of this.known.values()) {\n const held = this.state.get(entry.cacheKey);\n if (held) previousByKey.set(entry.cacheKey, held);\n }\n\n const outcomes: IntrospectionRecompileOutcome[] = [];\n for (const entry of this.known.values()) {\n const previous = previousByKey.get(entry.cacheKey);\n await this.compileInto(entry.cacheKey, reason, observation.token);\n const next = this.state.get(entry.cacheKey);\n outcomes.push({\n cacheKey: entry.cacheKey,\n behavior: entry.behavior,\n serviceKey: entry.serviceKey,\n previous,\n next,\n changed: next !== undefined && next !== previous\n && !areDerivationPayloadsEqual(previous?.result, next.result),\n });\n }\n\n this.logDebug('Introspection source moved; recompiled known derivations', {\n reason,\n derivationCount: outcomes.length,\n changedCount: outcomes.filter((outcome) => outcome.changed).length,\n sourceObservationMs: observation.durationMs,\n });\n\n return { moved: true, outcomes };\n }\n\n /**\n * How many derivations are currently held.\n *\n * A diagnostic, and the pin for the pruning invariant: the map is bounded by the distinct\n * questions asked since the last source change, not by every question ever asked.\n */\n public get compiledDerivationCount(): number {\n return this.state.size;\n }\n\n /** The generation currently held for a derivation, for a caller stamping a notification. */\n public generationOf(cacheKey: string): number | undefined {\n return this.state.get(cacheKey)?.generation;\n }\n\n /**\n * Drop every compiled derivation.\n *\n * Costs a recompilation and changes no answer. That property is what makes this state rather than\n * a ledger, so it is exercised by a test rather than merely asserted here.\n */\n public clear(): void {\n this.state.clear();\n this.currentToken = undefined;\n }\n\n /**\n * Test seam: drop ONE compiled entry, to reproduce a single-key compile against a partly-empty\n * state. Production never evicts a single entry — see the note in `store`.\n */\n public clearOneForTesting(cacheKey: string): void {\n this.state.delete(cacheKey);\n }\n\n /** Test seam: replace the source observer with a fake. Production always observes real trees. */\n public setSourceStateObserverForTesting(observer: IntrospectionSourceStateObserver): void {\n (this as unknown as { observer: IntrospectionSourceStateObserver }).observer = observer;\n }\n\n /**\n * Compile one known derivation into the state, joining an identical in-flight compilation.\n *\n * The join matters more here than in a request-shaped cache: a watcher burst and a cold read can\n * arrive within the same millisecond, and a subprocess that imports the whole application is the\n * most expensive thing this process does.\n */\n private async compileInto(\n cacheKey: string,\n reason: IntrospectionRecompileReason,\n tokenOverride?: string,\n ): Promise<CompanionIntrospectionResult | undefined> {\n const existing = this.inFlight.get(cacheKey);\n if (existing) return existing;\n\n const entry = this.known.get(cacheKey);\n if (!entry) return undefined;\n\n const run = (async (): Promise<CompanionIntrospectionResult> => {\n let token = tokenOverride;\n if (token === undefined) {\n const observation = await this.observer.observe(Date.now());\n token = observation.bounded ? observation.token : undefined;\n }\n\n const result = await entry.compile();\n if (!result.success || token === undefined) {\n /*\n * A failure is never retained, and the reasoning is the same as before the split: the\n * dominant failure here is an application whose `dist` is not built, whose remedy moves the\n * source and would invalidate anyway; and a transient failure — a timeout on a loaded\n * machine — would otherwise stick to an unchanged tree and be served as the answer forever.\n */\n this.logDebug('Introspection compilation not retained', {\n behavior: entry.behavior,\n serviceKey: entry.serviceKey,\n reason,\n success: result.success,\n hasToken: token !== undefined,\n });\n return result;\n }\n this.store(cacheKey, result, token);\n return result;\n })().finally(() => {\n this.inFlight.delete(cacheKey);\n });\n\n this.inFlight.set(cacheKey, run);\n return run;\n }\n\n /** Write a compiled derivation into the state under a fresh, never-decreasing generation. */\n private store(\n cacheKey: string,\n result: CompanionIntrospectionSuccessResult,\n sourceStateToken: string,\n ): IntrospectionCompiledDerivation {\n const compiledAt = Date.now();\n // Wall-clock is monotone across a restart; the `+1` only breaks a tie between two compilations\n // landing inside the same millisecond, which a browser tab would otherwise read as a stale push.\n this.lastGeneration = Math.max(compiledAt, this.lastGeneration + 1);\n const compiled: IntrospectionCompiledDerivation = {\n result,\n sourceStateToken,\n generation: this.lastGeneration,\n compiledAt,\n };\n /*\n * NOTHING IS PRUNED HERE, and that REVERSES what issue #159's cache did — deliberately.\n *\n * That cache dropped every entry taken against a superseded token, on the reasoning that such an\n * entry \"describes a tree that no longer exists, so it can never be served again\". The first half\n * is still true; the conclusion is not, because an entry now has a SECOND job. It is the basis\n * the next recompilation diffs against, and being unservable as an ANSWER does not make it\n * useless as a BASELINE.\n *\n * Pruning here cost exactly that: compiling ONE derivation evicted every other derivation's\n * baseline, so the next recompile-all saw no previous state for them and reported their whole row\n * sets as CREATED. Measured on wonder-crm before the fix — 180 publications in three minutes,\n * every one a full repaint.\n *\n * The growth the pruning guarded against cannot occur any more either: this map holds ONE entry\n * per cache key, and a recompilation OVERWRITES that key rather than adding a second entry. Its\n * size is bounded by the number of distinct questions in {@link known}, which is the same bound\n * that map already carries.\n */\n this.state.set(cacheKey, compiled);\n return compiled;\n }\n}\n\n/**\n * Whether two derivations carry the same answer.\n *\n * Compared on the DATA the child returned, not on the envelope: a result carries timing and a\n * `servedFromCache` flag that differ between two compilations of an unchanged application, and\n * comparing those would report every recompilation as a change.\n *\n * A stable stringify is deliberately NOT used. The child's payload is produced by one code path from\n * one imported module graph, so key order is stable between two runs of the same bytes; and an\n * ordering difference that did appear would mean the application's own output was non-deterministic,\n * which is a change worth reporting rather than hiding.\n *\n * ## This OVER-reports, deliberately, and the row diff is the real decision\n *\n * Measured on wonder-crm 2026-09-02, by recompiling three times against byte-identical sources: two\n * of three derivations reported `changed` every time. Diffing two payloads leaf by leaf found exactly\n * one differing value — `specification-artifacts` stamps `trace.evaluatedAt` with the wall-clock\n * instant of the derivation, so its payload can never compare equal to its predecessor.\n * (`application-domain-model` differed in **0** leaves, so the volatility is per-behavior, not\n * general.)\n *\n * That is safe, and it is safe for a specific reason rather than by luck: `changed` only decides\n * whether the notifier is INVITED to look. What it publishes is decided by `diffProjectedRows` over\n * the projected ROWS, and `trace` sits outside this behavior's `rowsPath`. The live check confirms\n * it — three touch-only recompilations produced `changedCount: 2` and **zero** publications.\n *\n * The alternative — excluding known-volatile keys here — was rejected: it would be a second, drifting\n * description of what a row contains, when the projection already owns that answer. **But the\n * guarantee rests on volatile fields staying OUT of the projected rows.** A behavior that put a\n * timestamp INSIDE a row would push an update for every row on every recompilation, and nothing here\n * would catch it — the diff would be correct and the data would be noise.\n */\nexport function areDerivationPayloadsEqual(\n left: CompanionIntrospectionSuccessResult | undefined,\n right: CompanionIntrospectionSuccessResult | undefined,\n): boolean {\n if (left === undefined || right === undefined) return false;\n return JSON.stringify(left.data) === JSON.stringify(right.data);\n}\n"]}
1
+ {"version":3,"file":"introspection-derivation-state.companion.service.js","sourceRoot":"","sources":["../../../../../../src/core/introspection/services/introspection-derivation-state.companion.service.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,OAAO,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,WAAW,CAAC;AAE/C,OAAO,EAAE,kBAAkB,EAAE,MAAM,4BAA4B,CAAC;AAEhE,OAAO,EAAE,uBAAuB,EAAE,MAAM,mCAAmC,CAAC;AAE5E,OAAO,EAAE,gCAAgC,EAAE,MAAM,gDAAgD,CAAC;AAMlG;;;;;;;;;;;;GAYG;AACH,MAAM,CAAN,IAAY,0BAKX;AALD,WAAY,0BAA0B;IACpC,iFAAiF;IACjF,mEAAqC,CAAA;IACrC,sFAAsF;IACtF,2CAAa,CAAA;AACf,CAAC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M,CAAC,uBAAuB,CAAC,gBAAgB,CAAC,CAAA;;GAfxC,4CAA4C,CAuVxD;;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+BG;AACH,MAAM,UAAU,0BAA0B,CACxC,IAAqD,EACrD,KAAsD;IAEtD,IAAI,IAAI,KAAK,SAAS,IAAI,KAAK,KAAK,SAAS;QAAE,OAAO,KAAK,CAAC;IAC5D,OAAO,IAAI,CAAC,SAAS,CAAC,IAAI,CAAC,IAAI,CAAC,KAAK,IAAI,CAAC,SAAS,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC;AAClE,CAAC","sourcesContent":["import { inject, injectable } from 'inversify';\nimport type { LoggerService } from '@wildo-ai/saas-backend-lib';\nimport { SAAS_SERVICE_TYPES } from '@wildo-ai/saas-backend-lib';\n\nimport { COMPANION_SERVICE_TYPES } from '../../inject/models/service-types';\nimport type { CompanionContext } from '../../context/companion-context';\nimport { IntrospectionSourceStateObserver } from './introspection-source-state.companion.service';\nimport type {\n CompanionIntrospectionResult,\n CompanionIntrospectionSuccessResult,\n} from '../models/companion-introspection.models';\n\n/**\n * How a derivation's freshness is currently decided.\n *\n * The two modes are not a preference. `OBSERVE_PER_READ` is exactly the behaviour issue #159 shipped\n * — sweep the source on every read, serve the memo only when the token still matches — and it is the\n * FALLBACK, kept because it is correct without any collaborator. `PUSH` is the mode this service\n * exists for: a freshness authority (the source watcher) tells the state when the source moved, so a\n * read consults nothing but memory.\n *\n * The service starts in `OBSERVE_PER_READ` and is promoted only when an authority registers. That\n * ordering is deliberate: a companion whose watcher failed to start, or a unit test that wires none,\n * degrades to slow-and-correct rather than to fast-and-stale.\n */\nexport enum IntrospectionFreshnessMode {\n /** No authority registered. Every read sweeps, exactly as issue #159 left it. */\n OBSERVE_PER_READ = 'observe-per-read',\n /** An authority is live. Reads consult memory; the authority drives recompilation. */\n PUSH = 'push',\n}\n\n/** Why a recompilation was triggered, carried into the log line and the change report. */\nexport enum IntrospectionRecompileReason {\n /** The freshness authority saw the source move. */\n SOURCE_MUTATION = 'source-mutation',\n /** The periodic reconciliation sweep found a token the authority had not reported. */\n RECONCILIATION = 'reconciliation',\n /** Startup warming, before anybody has asked. */\n BOOT_WARM = 'boot-warm',\n /** A read found no compiled state at all. */\n COLD_READ = 'cold-read',\n}\n\n/**\n * One compiled derivation, and everything a consumer needs to talk about it without recompiling.\n */\nexport interface IntrospectionCompiledDerivation {\n /**\n * The child's answer, exactly as `requestInfo` would have returned it.\n *\n * Typed as the SUCCESS result rather than the union, because only a success is ever retained —\n * see `store`. That is not a narrowing for convenience: `servedFromCache` exists only on the\n * success arm, so a union here would make the flag unassignable, and the type is the place that\n * says a failure is never held.\n */\n readonly result: CompanionIntrospectionSuccessResult;\n /** The source-state token this was compiled against. */\n readonly sourceStateToken: string;\n /**\n * A monotonically increasing stamp for this derivation, used as the WebSocket sync `version`.\n *\n * **It must never go backwards, including across a companion restart.** `ResourceMutationManager`\n * drops any pushed update whose `version <= this._version`, so a counter that resets to zero on\n * restart makes every browser tab that stayed open ignore every later update — silently, with no\n * error and no refetch, leaving a permanently frozen view. Wall-clock milliseconds cannot regress\n * across a restart, which is the whole reason they are used here rather than a counter.\n */\n readonly generation: number;\n /** When this was compiled, for the debug line that explains a lookup's age. */\n readonly compiledAt: number;\n}\n\n/** What one recompilation did, per derivation, so a caller can emit a diff without re-reading. */\nexport interface IntrospectionRecompileOutcome {\n readonly cacheKey: string;\n readonly behavior: string;\n readonly serviceKey: string;\n /** The state before, absent on a first compile. */\n readonly previous: IntrospectionCompiledDerivation | undefined;\n /** The state after. Absent when the recompilation FAILED and the previous state was kept. */\n readonly next: IntrospectionCompiledDerivation | undefined;\n /** `false` when the recompilation produced a byte-identical payload — nothing to notify about. */\n readonly changed: boolean;\n}\n\n/** A registered derivation the state service knows how to recompile without being asked again. */\ninterface KnownDerivation {\n readonly cacheKey: string;\n readonly behavior: string;\n readonly serviceKey: string;\n /** The closure that compiles this exact question. Held so recompilation needs no caller. */\n readonly compile: () => Promise<CompanionIntrospectionResult>;\n}\n\n/**\n * Owns COMPILED introspection state, so that reading one is not the act that compiles it.\n *\n * ## Why this is a separate service rather than a better cache\n *\n * Before this, compilation and retrieval were the same code path: `requestInfo` observed the source,\n * compared a token, and compiled on a miss — all inside the caller's request. That fusion has three\n * consequences that no amount of cache tuning removes.\n *\n * 1. **Every read pays the freshness probe.** Measured on wonder-crm, 2026-09-02: a warm\n * `LIST /api/v1/workbench-domain-resources` answered in 200–270 ms, of which the source sweep is\n * 180–225 ms. The cache was working perfectly and almost all of the remaining latency was the act\n * of asking whether it could be used.\n * 2. **A miss is charged to whoever happened to ask.** Same session: a cold `LIST` cost 8.95 s and an\n * addressed `READ` cost 44.4 s, then 500. In a tree with the engine's `tsc-watch` fleet running,\n * the token moves constantly, so a miss is the NORMAL case rather than the exception.\n * 3. **Nothing can be notified.** A pull-shaped cache learns that the source moved only while\n * somebody is waiting for an answer, so there is no moment at which it could tell a frontend that\n * a row changed. Push requires knowing BEFORE the read.\n *\n * Separating the two makes each answerable on its own terms: compilation is triggered by the source\n * moving, retrieval is a map lookup, and the moment between them is where a notification can exist.\n *\n * ## What this holds is TIME, never TRUTH\n *\n * `one-source-of-truth.md` Rule 5: this is per-run runtime state. Deleting all of it costs a\n * recompilation and changes no answer — {@link clear} is the proof obligation, and the byte-identical\n * payload across it is the test. Nothing here is a ledger, nothing is persisted, and no decision\n * anywhere may be made from the absence of an entry.\n */\n@injectable()\nexport class IntrospectionDerivationStateCompanionService {\n private readonly logDebug: (message: string, context?: Record<string, unknown>) => void;\n private readonly state = new Map<string, IntrospectionCompiledDerivation>();\n private readonly known = new Map<string, KnownDerivation>();\n /** Recompilations currently running, so two triggers cannot compile the same question twice. */\n private readonly inFlight = new Map<string, Promise<CompanionIntrospectionResult>>();\n private readonly observer: IntrospectionSourceStateObserver;\n private freshnessMode: IntrospectionFreshnessMode = IntrospectionFreshnessMode.OBSERVE_PER_READ;\n private freshnessAuthorityName: string | undefined;\n /** The token the state was last compiled against, in `PUSH` mode. */\n private currentToken: string | undefined;\n private lastGeneration = 0;\n\n constructor(\n @inject(SAAS_SERVICE_TYPES.Logger) private readonly logger: LoggerService,\n @inject(COMPANION_SERVICE_TYPES.CompanionContext) private readonly companionContext: CompanionContext,\n ) {\n this.logDebug = this.logger.debugByType('IntrospectionDerivationState');\n this.logger.setDebugTypeLogging('IntrospectionDerivationState', true);\n this.observer = new IntrospectionSourceStateObserver(this.companionContext);\n }\n\n public get mode(): IntrospectionFreshnessMode {\n return this.freshnessMode;\n }\n\n /**\n * Promote the service out of per-read observation.\n *\n * Called by the source watcher once it is actually watching. The name is carried so an operator\n * reading a log line can tell WHICH authority is responsible for freshness, and so a second\n * registration is visible rather than silent.\n */\n public registerFreshnessAuthority(name: string): void {\n this.freshnessAuthorityName = name;\n this.freshnessMode = IntrospectionFreshnessMode.PUSH;\n this.logger.info('Introspection derivation state promoted to push freshness', { authority: name });\n }\n\n /**\n * Demote back to per-read observation.\n *\n * The watcher calls this when it errors or closes. Demoting is always safe and never wrong — it\n * only costs time — whereas staying in `PUSH` with a dead authority serves a tree that has moved.\n */\n public noteFreshnessAuthorityLost(reason: string): void {\n if (this.freshnessMode === IntrospectionFreshnessMode.OBSERVE_PER_READ) return;\n this.freshnessMode = IntrospectionFreshnessMode.OBSERVE_PER_READ;\n this.logger.warn('Introspection freshness authority lost; falling back to per-read source observation', {\n authority: this.freshnessAuthorityName,\n reason,\n });\n this.freshnessAuthorityName = undefined;\n }\n\n /**\n * Read a derivation, compiling only when there is nothing to read.\n *\n * `compile` is retained against the cache key on first sight, which is what lets a later\n * source mutation recompile this question with no caller present. That is the whole mechanism by\n * which retrieval stops driving compilation: the FIRST read teaches the service the question, and\n * every subsequent answer — including the ones nobody asked for yet — is produced by the source\n * moving instead.\n *\n * In `OBSERVE_PER_READ` mode the freshness probe still runs here, because without an authority\n * there is nothing else that could run it.\n */\n public async read(\n identity: { readonly cacheKey: string; readonly behavior: string; readonly serviceKey: string },\n compile: () => Promise<CompanionIntrospectionResult>,\n ): Promise<CompanionIntrospectionResult> {\n if (!this.known.has(identity.cacheKey)) {\n this.known.set(identity.cacheKey, { ...identity, compile });\n }\n\n if (this.freshnessMode === IntrospectionFreshnessMode.OBSERVE_PER_READ) {\n return this.readWithPerReadObservation(identity, compile);\n }\n\n const held = this.state.get(identity.cacheKey);\n if (held) {\n const ageMs = Date.now() - held.compiledAt;\n this.logDebug('Introspection derivation served from compiled state', {\n behavior: identity.behavior,\n serviceKey: identity.serviceKey,\n ageMs,\n generation: held.generation,\n });\n // The age TRAVELS now (#1437). It was computed here for a debug line while the consumer that\n // needs it — one deciding whether a held answer still describes the tree it is about to edit —\n // could not see it.\n return { ...held.result, servedFromCache: true, derivationAgeMs: ageMs };\n }\n\n return (await this.compileInto(identity.cacheKey, IntrospectionRecompileReason.COLD_READ))\n ?? compile();\n }\n\n /**\n * The pre-#159-separation path, kept verbatim in behaviour for the no-authority case.\n *\n * A read observes the source, serves the held derivation when the token still matches, and\n * compiles otherwise. Slower by exactly one sweep per read, and correct with no collaborator.\n */\n private async readWithPerReadObservation(\n identity: { readonly cacheKey: string; readonly behavior: string; readonly serviceKey: string },\n compile: () => Promise<CompanionIntrospectionResult>,\n ): Promise<CompanionIntrospectionResult> {\n const observation = await this.observer.observe(Date.now());\n const held = this.state.get(identity.cacheKey);\n if (held && held.sourceStateToken === observation.token) {\n this.logDebug('Introspection derivation served from compiled state (per-read observation)', {\n behavior: identity.behavior,\n serviceKey: identity.serviceKey,\n sourceObservationMs: observation.durationMs,\n });\n // BOTH read paths, and stating why they differ: this one has already checked the source token,\n // so the age says how long ago the answer was taken rather than how long it MIGHT be stale.\n // Reporting it on only one path would make the field mean different things per freshness mode,\n // which is worse than not having it.\n return { ...held.result, servedFromCache: true, derivationAgeMs: Date.now() - held.compiledAt };\n }\n\n /*\n * Routed through `compileInto` rather than calling the closure here, because that is where the\n * in-flight join lives. `maxConcurrency` caps how many subprocesses run at once; it does not\n * notice that two of them are asking the identical question. Two concurrent reads of one\n * behavior must cost ONE subprocess, and calling the closure directly would silently\n * reintroduce the second child.\n *\n * `bounded: false` means the sweep gave up before seeing the whole tree, so its token says\n * nothing about whether the source moved. Compiling is still correct; RETAINING against that\n * token would not be — which is why the token is handed over only when the sweep completed.\n */\n return (await this.compileInto(\n identity.cacheKey,\n IntrospectionRecompileReason.COLD_READ,\n observation.bounded ? observation.token : undefined,\n )) ?? compile();\n }\n\n /**\n * Recompile everything this service knows about, if the source has actually moved.\n *\n * Returns one outcome per known derivation, with `changed` telling the caller whether anything\n * downstream needs to hear about it. A recompilation that produces a byte-identical payload is\n * reported as unchanged, because an operator saving a file that alters nothing observable must not\n * produce a wave of notifications.\n *\n * A FAILED recompilation keeps the previous state rather than dropping it. The dominant failure\n * here is an application mid-build, and answering \"could not look\" for the seconds a `tsc` takes —\n * when a correct answer from one second ago is in hand — is worse than answering slightly late.\n */\n public async recompileIfSourceMoved(\n reason: IntrospectionRecompileReason,\n ): Promise<{ readonly moved: boolean; readonly outcomes: readonly IntrospectionRecompileOutcome[] }> {\n const observation = await this.observer.observe(Date.now());\n if (!observation.bounded) {\n this.logger.warn('Introspection source observation exceeded its ceiling; recompiling without remembering', {\n reason,\n observedEntryCount: observation.observedEntryCount,\n });\n }\n\n if (this.currentToken === observation.token && observation.bounded) {\n return { moved: false, outcomes: [] };\n }\n this.currentToken = observation.bounded ? observation.token : undefined;\n\n /*\n * Snapshot every previous state BEFORE compiling any of them.\n *\n * `store` prunes entries taken against a superseded token, so the FIRST compilation of this loop\n * deletes every OTHER derivation's previous state — they still carry the old token. Reading\n * `previous` inside the loop therefore returned `undefined` for every derivation after the first,\n * and each one reported its whole row set as CREATED.\n *\n * Measured before the fix on wonder-crm: 180 publications in three minutes, every one of them\n * `created: N, updated: 0, deleted: 0` — a full-repaint storm, the exact opposite of what the\n * diff exists to produce. Found by reading the live log rather than by a test, which is why the\n * regression pin below compares TWO derivations rather than one.\n */\n const previousByKey = new Map<string, IntrospectionCompiledDerivation>();\n for (const entry of this.known.values()) {\n const held = this.state.get(entry.cacheKey);\n if (held) previousByKey.set(entry.cacheKey, held);\n }\n\n const outcomes: IntrospectionRecompileOutcome[] = [];\n for (const entry of this.known.values()) {\n const previous = previousByKey.get(entry.cacheKey);\n await this.compileInto(entry.cacheKey, reason, observation.token);\n const next = this.state.get(entry.cacheKey);\n outcomes.push({\n cacheKey: entry.cacheKey,\n behavior: entry.behavior,\n serviceKey: entry.serviceKey,\n previous,\n next,\n changed: next !== undefined && next !== previous\n && !areDerivationPayloadsEqual(previous?.result, next.result),\n });\n }\n\n this.logDebug('Introspection source moved; recompiled known derivations', {\n reason,\n derivationCount: outcomes.length,\n changedCount: outcomes.filter((outcome) => outcome.changed).length,\n sourceObservationMs: observation.durationMs,\n });\n\n return { moved: true, outcomes };\n }\n\n /**\n * How many derivations are currently held.\n *\n * A diagnostic, and the pin for the pruning invariant: the map is bounded by the distinct\n * questions asked since the last source change, not by every question ever asked.\n */\n public get compiledDerivationCount(): number {\n return this.state.size;\n }\n\n /** The generation currently held for a derivation, for a caller stamping a notification. */\n public generationOf(cacheKey: string): number | undefined {\n return this.state.get(cacheKey)?.generation;\n }\n\n /**\n * Drop every compiled derivation.\n *\n * Costs a recompilation and changes no answer. That property is what makes this state rather than\n * a ledger, so it is exercised by a test rather than merely asserted here.\n */\n public clear(): void {\n this.state.clear();\n this.currentToken = undefined;\n }\n\n /**\n * Test seam: drop ONE compiled entry, to reproduce a single-key compile against a partly-empty\n * state. Production never evicts a single entry — see the note in `store`.\n */\n public clearOneForTesting(cacheKey: string): void {\n this.state.delete(cacheKey);\n }\n\n /** Test seam: replace the source observer with a fake. Production always observes real trees. */\n public setSourceStateObserverForTesting(observer: IntrospectionSourceStateObserver): void {\n (this as unknown as { observer: IntrospectionSourceStateObserver }).observer = observer;\n }\n\n /**\n * Compile one known derivation into the state, joining an identical in-flight compilation.\n *\n * The join matters more here than in a request-shaped cache: a watcher burst and a cold read can\n * arrive within the same millisecond, and a subprocess that imports the whole application is the\n * most expensive thing this process does.\n */\n private async compileInto(\n cacheKey: string,\n reason: IntrospectionRecompileReason,\n tokenOverride?: string,\n ): Promise<CompanionIntrospectionResult | undefined> {\n const existing = this.inFlight.get(cacheKey);\n if (existing) return existing;\n\n const entry = this.known.get(cacheKey);\n if (!entry) return undefined;\n\n const run = (async (): Promise<CompanionIntrospectionResult> => {\n let token = tokenOverride;\n if (token === undefined) {\n const observation = await this.observer.observe(Date.now());\n token = observation.bounded ? observation.token : undefined;\n }\n\n const result = await entry.compile();\n if (!result.success || token === undefined) {\n /*\n * A failure is never retained, and the reasoning is the same as before the split: the\n * dominant failure here is an application whose `dist` is not built, whose remedy moves the\n * source and would invalidate anyway; and a transient failure — a timeout on a loaded\n * machine — would otherwise stick to an unchanged tree and be served as the answer forever.\n */\n this.logDebug('Introspection compilation not retained', {\n behavior: entry.behavior,\n serviceKey: entry.serviceKey,\n reason,\n success: result.success,\n hasToken: token !== undefined,\n });\n return result;\n }\n this.store(cacheKey, result, token);\n return result;\n })().finally(() => {\n this.inFlight.delete(cacheKey);\n });\n\n this.inFlight.set(cacheKey, run);\n return run;\n }\n\n /** Write a compiled derivation into the state under a fresh, never-decreasing generation. */\n private store(\n cacheKey: string,\n result: CompanionIntrospectionSuccessResult,\n sourceStateToken: string,\n ): IntrospectionCompiledDerivation {\n const compiledAt = Date.now();\n // Wall-clock is monotone across a restart; the `+1` only breaks a tie between two compilations\n // landing inside the same millisecond, which a browser tab would otherwise read as a stale push.\n this.lastGeneration = Math.max(compiledAt, this.lastGeneration + 1);\n const compiled: IntrospectionCompiledDerivation = {\n result,\n sourceStateToken,\n generation: this.lastGeneration,\n compiledAt,\n };\n /*\n * NOTHING IS PRUNED HERE, and that REVERSES what issue #159's cache did — deliberately.\n *\n * That cache dropped every entry taken against a superseded token, on the reasoning that such an\n * entry \"describes a tree that no longer exists, so it can never be served again\". The first half\n * is still true; the conclusion is not, because an entry now has a SECOND job. It is the basis\n * the next recompilation diffs against, and being unservable as an ANSWER does not make it\n * useless as a BASELINE.\n *\n * Pruning here cost exactly that: compiling ONE derivation evicted every other derivation's\n * baseline, so the next recompile-all saw no previous state for them and reported their whole row\n * sets as CREATED. Measured on wonder-crm before the fix — 180 publications in three minutes,\n * every one a full repaint.\n *\n * The growth the pruning guarded against cannot occur any more either: this map holds ONE entry\n * per cache key, and a recompilation OVERWRITES that key rather than adding a second entry. Its\n * size is bounded by the number of distinct questions in {@link known}, which is the same bound\n * that map already carries.\n */\n this.state.set(cacheKey, compiled);\n return compiled;\n }\n}\n\n/**\n * Whether two derivations carry the same answer.\n *\n * Compared on the DATA the child returned, not on the envelope: a result carries timing and a\n * `servedFromCache` flag that differ between two compilations of an unchanged application, and\n * comparing those would report every recompilation as a change.\n *\n * A stable stringify is deliberately NOT used. The child's payload is produced by one code path from\n * one imported module graph, so key order is stable between two runs of the same bytes; and an\n * ordering difference that did appear would mean the application's own output was non-deterministic,\n * which is a change worth reporting rather than hiding.\n *\n * ## This OVER-reports, deliberately, and the row diff is the real decision\n *\n * Measured on wonder-crm 2026-09-02, by recompiling three times against byte-identical sources: two\n * of three derivations reported `changed` every time. Diffing two payloads leaf by leaf found exactly\n * one differing value — `specification-artifacts` stamps `trace.evaluatedAt` with the wall-clock\n * instant of the derivation, so its payload can never compare equal to its predecessor.\n * (`application-domain-model` differed in **0** leaves, so the volatility is per-behavior, not\n * general.)\n *\n * That is safe, and it is safe for a specific reason rather than by luck: `changed` only decides\n * whether the notifier is INVITED to look. What it publishes is decided by `diffProjectedRows` over\n * the projected ROWS, and `trace` sits outside this behavior's `rowsPath`. The live check confirms\n * it — three touch-only recompilations produced `changedCount: 2` and **zero** publications.\n *\n * The alternative — excluding known-volatile keys here — was rejected: it would be a second, drifting\n * description of what a row contains, when the projection already owns that answer. **But the\n * guarantee rests on volatile fields staying OUT of the projected rows.** A behavior that put a\n * timestamp INSIDE a row would push an update for every row on every recompilation, and nothing here\n * would catch it — the diff would be correct and the data would be noise.\n */\nexport function areDerivationPayloadsEqual(\n left: CompanionIntrospectionSuccessResult | undefined,\n right: CompanionIntrospectionSuccessResult | undefined,\n): boolean {\n if (left === undefined || right === undefined) return false;\n return JSON.stringify(left.data) === JSON.stringify(right.data);\n}\n"]}
@@ -29,11 +29,12 @@ export interface IntrospectionSourceStateObservation {
29
29
  *
30
30
  * ## Why a token rather than a watcher
31
31
  *
32
- * The companion has no file watcher and adding one would mean a new always-on dependency, a new
33
- * always-on process cost, and a new class of missed-event bug on the platforms this repository does
34
- * not test on. A sweep answers the same question on demand, costs ~125 ms against the largest
35
- * dogfood application, and cannot miss an event because it does not observe events at all — it
36
- * observes the tree.
32
+ * The companion's file watcher (`IntrospectionSourceWatcherCompanionService`) is best-effort —
33
+ * `fs.watch` can go deaf with no error — so it only says WHEN to look; this observer says WHETHER
34
+ * anything moved. A sweep answers that on demand, costs ~125 ms against the largest dogfood
35
+ * application, and cannot miss an event because it does not observe events at all — it observes the
36
+ * tree. (This paragraph said "the companion has no file watcher" until 2026-09-24; the watcher was
37
+ * added on top of the observer, not instead of it.)
37
38
  *
38
39
  * ## Why mtimes rather than content
39
40
  *
@@ -183,4 +184,13 @@ export declare class IntrospectionSourceStateObserver {
183
184
  */
184
185
  private visitDirectory;
185
186
  }
187
+ /**
188
+ * Every APPLICATION package an introspection derivation can import: each declared service, each
189
+ * resolved library, and the specifications package.
190
+ *
191
+ * ONE enumeration, shared by this observer and by the creation-plane projection's input signature
192
+ * (#1310, seventh review G1), because both answer the same question — "which built trees can move an
193
+ * introspection result?" — and two lists of one population agree only until one gains an entry.
194
+ */
195
+ export declare function resolveIntrospectedApplicationPackageRoots(companionContext: Pick<CompanionContext, 'saasRoot' | 'servicesByKey' | 'resolvedLibraries' | 'resolvedSpecifications'>): readonly string[];
186
196
  //# sourceMappingURL=introspection-source-state.companion.service.d.ts.map