@llm-dev-ops/agentics-cli 1.4.53 → 1.4.54

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 (325) hide show
  1. package/dist/bundled-agents/connector-hub-agents/package-lock.json +11697 -0
  2. package/dist/bundled-agents/connector-hub-agents/package.json +75 -0
  3. package/dist/bundled-agents/connector-hub-agents/tsconfig.build.json +22 -0
  4. package/dist/bundled-agents/connector-hub-agents/tsconfig.json +57 -0
  5. package/dist/bundled-agents/copilot-agents/functions/.gcloudignore +17 -0
  6. package/dist/bundled-agents/copilot-agents/functions/dist/functions/src/cors.d.ts +14 -0
  7. package/dist/bundled-agents/copilot-agents/functions/dist/functions/src/cors.js +35 -0
  8. package/dist/bundled-agents/copilot-agents/functions/dist/functions/src/cors.js.map +1 -0
  9. package/dist/bundled-agents/copilot-agents/functions/dist/functions/src/envelope.d.ts +55 -0
  10. package/dist/bundled-agents/copilot-agents/functions/dist/functions/src/envelope.js +40 -0
  11. package/dist/bundled-agents/copilot-agents/functions/dist/functions/src/envelope.js.map +1 -0
  12. package/dist/bundled-agents/copilot-agents/functions/dist/functions/src/health.d.ts +22 -0
  13. package/dist/bundled-agents/copilot-agents/functions/dist/functions/src/health.js +38 -0
  14. package/dist/bundled-agents/copilot-agents/functions/dist/functions/src/health.js.map +1 -0
  15. package/dist/bundled-agents/copilot-agents/functions/dist/functions/src/index.d.ts +34 -0
  16. package/dist/bundled-agents/copilot-agents/functions/dist/functions/src/index.js +186 -0
  17. package/dist/bundled-agents/copilot-agents/functions/dist/functions/src/index.js.map +1 -0
  18. package/dist/bundled-agents/copilot-agents/functions/dist/functions/src/router.d.ts +36 -0
  19. package/dist/bundled-agents/copilot-agents/functions/dist/functions/src/router.js +121 -0
  20. package/dist/bundled-agents/copilot-agents/functions/dist/functions/src/router.js.map +1 -0
  21. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/config-validation/config-validation-agent.d.ts +157 -0
  22. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/config-validation/config-validation-agent.js +948 -0
  23. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/config-validation/config-validation-agent.js.map +1 -0
  24. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/config-validation/index.d.ts +9 -0
  25. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/config-validation/index.js +27 -0
  26. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/config-validation/index.js.map +1 -0
  27. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/contracts/agent-span-wrapper.d.ts +23 -0
  28. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/contracts/agent-span-wrapper.js +50 -0
  29. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/contracts/agent-span-wrapper.js.map +1 -0
  30. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/contracts/base-agent.d.ts +214 -0
  31. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/contracts/base-agent.js +91 -0
  32. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/contracts/base-agent.js.map +1 -0
  33. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/contracts/config-validation-schemas.d.ts +1166 -0
  34. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/contracts/config-validation-schemas.js +308 -0
  35. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/contracts/config-validation-schemas.js.map +1 -0
  36. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/contracts/decision-event.d.ts +59 -0
  37. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/contracts/decision-event.js +62 -0
  38. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/contracts/decision-event.js.map +1 -0
  39. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/contracts/decomposer-schemas.d.ts +400 -0
  40. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/contracts/decomposer-schemas.js +113 -0
  41. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/contracts/decomposer-schemas.js.map +1 -0
  42. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/contracts/execution-graph.d.ts +250 -0
  43. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/contracts/execution-graph.js +169 -0
  44. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/contracts/execution-graph.js.map +1 -0
  45. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/contracts/index.d.ts +17 -0
  46. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/contracts/index.js +97 -0
  47. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/contracts/index.js.map +1 -0
  48. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/contracts/intelligence-schemas.d.ts +1674 -0
  49. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/contracts/intelligence-schemas.js +246 -0
  50. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/contracts/intelligence-schemas.js.map +1 -0
  51. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/contracts/intent-classifier-schemas.d.ts +1085 -0
  52. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/contracts/intent-classifier-schemas.js +218 -0
  53. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/contracts/intent-classifier-schemas.js.map +1 -0
  54. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/contracts/meta-reasoner-schemas.d.ts +949 -0
  55. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/contracts/meta-reasoner-schemas.js +253 -0
  56. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/contracts/meta-reasoner-schemas.js.map +1 -0
  57. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/contracts/objective-clarifier-schemas.d.ts +657 -0
  58. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/contracts/objective-clarifier-schemas.js +205 -0
  59. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/contracts/objective-clarifier-schemas.js.map +1 -0
  60. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/contracts/pipeline-schemas.d.ts +285 -0
  61. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/contracts/pipeline-schemas.js +106 -0
  62. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/contracts/pipeline-schemas.js.map +1 -0
  63. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/contracts/planner-schemas.d.ts +581 -0
  64. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/contracts/planner-schemas.js +136 -0
  65. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/contracts/planner-schemas.js.map +1 -0
  66. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/contracts/reflection-schemas.d.ts +791 -0
  67. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/contracts/reflection-schemas.js +225 -0
  68. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/contracts/reflection-schemas.js.map +1 -0
  69. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/decomposer/decomposer-agent.d.ts +120 -0
  70. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/decomposer/decomposer-agent.js +535 -0
  71. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/decomposer/decomposer-agent.js.map +1 -0
  72. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/decomposer/index.d.ts +9 -0
  73. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/decomposer/index.js +18 -0
  74. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/decomposer/index.js.map +1 -0
  75. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/intent-classifier/index.d.ts +4 -0
  76. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/intent-classifier/index.js +9 -0
  77. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/intent-classifier/index.js.map +1 -0
  78. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/intent-classifier/intent-classifier-agent.d.ts +123 -0
  79. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/intent-classifier/intent-classifier-agent.js +609 -0
  80. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/intent-classifier/intent-classifier-agent.js.map +1 -0
  81. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/meta-reasoner/index.d.ts +10 -0
  82. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/meta-reasoner/index.js +25 -0
  83. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/meta-reasoner/index.js.map +1 -0
  84. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/meta-reasoner/meta-reasoner-agent.d.ts +111 -0
  85. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/meta-reasoner/meta-reasoner-agent.js +686 -0
  86. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/meta-reasoner/meta-reasoner-agent.js.map +1 -0
  87. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/meta-reasoner/telemetry.d.ts +11 -0
  88. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/meta-reasoner/telemetry.js +25 -0
  89. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/meta-reasoner/telemetry.js.map +1 -0
  90. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/objective-clarifier/index.d.ts +6 -0
  91. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/objective-clarifier/index.js +15 -0
  92. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/objective-clarifier/index.js.map +1 -0
  93. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/objective-clarifier/objective-clarifier-agent.d.ts +126 -0
  94. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/objective-clarifier/objective-clarifier-agent.js +780 -0
  95. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/objective-clarifier/objective-clarifier-agent.js.map +1 -0
  96. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/objective-clarifier/ruvector-persistence.d.ts +49 -0
  97. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/objective-clarifier/ruvector-persistence.js +125 -0
  98. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/objective-clarifier/ruvector-persistence.js.map +1 -0
  99. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/objective-clarifier/telemetry.d.ts +73 -0
  100. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/objective-clarifier/telemetry.js +192 -0
  101. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/objective-clarifier/telemetry.js.map +1 -0
  102. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/planner/index.d.ts +11 -0
  103. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/planner/index.js +25 -0
  104. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/planner/index.js.map +1 -0
  105. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/planner/planner-agent.d.ts +127 -0
  106. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/planner/planner-agent.js +483 -0
  107. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/planner/planner-agent.js.map +1 -0
  108. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/planner/ruvector-persistence.d.ts +49 -0
  109. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/planner/ruvector-persistence.js +125 -0
  110. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/planner/ruvector-persistence.js.map +1 -0
  111. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/planner/telemetry.d.ts +73 -0
  112. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/planner/telemetry.js +192 -0
  113. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/planner/telemetry.js.map +1 -0
  114. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/reflection/index.d.ts +11 -0
  115. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/reflection/index.js +27 -0
  116. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/reflection/index.js.map +1 -0
  117. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/reflection/reflection-agent.d.ts +122 -0
  118. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/reflection/reflection-agent.js +645 -0
  119. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/reflection/reflection-agent.js.map +1 -0
  120. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/reflection/ruvector-persistence.d.ts +59 -0
  121. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/reflection/ruvector-persistence.js +156 -0
  122. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/reflection/ruvector-persistence.js.map +1 -0
  123. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/reflection/telemetry.d.ts +88 -0
  124. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/reflection/telemetry.js +246 -0
  125. package/dist/bundled-agents/copilot-agents/functions/dist/services/agents/reflection/telemetry.js.map +1 -0
  126. package/dist/bundled-agents/copilot-agents/functions/index.js +4 -0
  127. package/dist/bundled-agents/copilot-agents/functions/jest.config.js +29 -0
  128. package/dist/bundled-agents/copilot-agents/functions/lib/functions/src/cors.d.ts +14 -0
  129. package/dist/bundled-agents/copilot-agents/functions/lib/functions/src/cors.js +35 -0
  130. package/dist/bundled-agents/copilot-agents/functions/lib/functions/src/cors.js.map +1 -0
  131. package/dist/bundled-agents/copilot-agents/functions/lib/functions/src/envelope.d.ts +27 -0
  132. package/dist/bundled-agents/copilot-agents/functions/lib/functions/src/envelope.js +21 -0
  133. package/dist/bundled-agents/copilot-agents/functions/lib/functions/src/envelope.js.map +1 -0
  134. package/dist/bundled-agents/copilot-agents/functions/lib/functions/src/health.d.ts +22 -0
  135. package/dist/bundled-agents/copilot-agents/functions/lib/functions/src/health.js +38 -0
  136. package/dist/bundled-agents/copilot-agents/functions/lib/functions/src/health.js.map +1 -0
  137. package/dist/bundled-agents/copilot-agents/functions/lib/functions/src/index.d.ts +34 -0
  138. package/dist/bundled-agents/copilot-agents/functions/lib/functions/src/index.js +174 -0
  139. package/dist/bundled-agents/copilot-agents/functions/lib/functions/src/index.js.map +1 -0
  140. package/dist/bundled-agents/copilot-agents/functions/lib/functions/src/router.d.ts +27 -0
  141. package/dist/bundled-agents/copilot-agents/functions/lib/functions/src/router.js +107 -0
  142. package/dist/bundled-agents/copilot-agents/functions/lib/functions/src/router.js.map +1 -0
  143. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/config-validation/config-validation-agent.d.ts +157 -0
  144. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/config-validation/config-validation-agent.js +941 -0
  145. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/config-validation/config-validation-agent.js.map +1 -0
  146. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/config-validation/index.d.ts +9 -0
  147. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/config-validation/index.js +27 -0
  148. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/config-validation/index.js.map +1 -0
  149. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/contracts/agent-span-wrapper.d.ts +23 -0
  150. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/contracts/agent-span-wrapper.js +50 -0
  151. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/contracts/agent-span-wrapper.js.map +1 -0
  152. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/contracts/base-agent.d.ts +185 -0
  153. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/contracts/base-agent.js +86 -0
  154. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/contracts/base-agent.js.map +1 -0
  155. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/contracts/config-validation-schemas.d.ts +1081 -0
  156. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/contracts/config-validation-schemas.js +305 -0
  157. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/contracts/config-validation-schemas.js.map +1 -0
  158. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/contracts/decision-event.d.ts +59 -0
  159. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/contracts/decision-event.js +62 -0
  160. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/contracts/decision-event.js.map +1 -0
  161. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/contracts/decomposer-schemas.d.ts +315 -0
  162. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/contracts/decomposer-schemas.js +110 -0
  163. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/contracts/decomposer-schemas.js.map +1 -0
  164. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/contracts/execution-graph.d.ts +250 -0
  165. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/contracts/execution-graph.js +169 -0
  166. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/contracts/execution-graph.js.map +1 -0
  167. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/contracts/index.d.ts +16 -0
  168. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/contracts/index.js +88 -0
  169. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/contracts/index.js.map +1 -0
  170. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/contracts/intelligence-schemas.d.ts +1674 -0
  171. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/contracts/intelligence-schemas.js +246 -0
  172. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/contracts/intelligence-schemas.js.map +1 -0
  173. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/contracts/intent-classifier-schemas.d.ts +1000 -0
  174. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/contracts/intent-classifier-schemas.js +215 -0
  175. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/contracts/intent-classifier-schemas.js.map +1 -0
  176. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/contracts/meta-reasoner-schemas.d.ts +864 -0
  177. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/contracts/meta-reasoner-schemas.js +250 -0
  178. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/contracts/meta-reasoner-schemas.js.map +1 -0
  179. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/contracts/objective-clarifier-schemas.d.ts +572 -0
  180. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/contracts/objective-clarifier-schemas.js +202 -0
  181. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/contracts/objective-clarifier-schemas.js.map +1 -0
  182. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/contracts/planner-schemas.d.ts +496 -0
  183. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/contracts/planner-schemas.js +133 -0
  184. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/contracts/planner-schemas.js.map +1 -0
  185. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/contracts/reflection-schemas.d.ts +706 -0
  186. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/contracts/reflection-schemas.js +222 -0
  187. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/contracts/reflection-schemas.js.map +1 -0
  188. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/decomposer/decomposer-agent.d.ts +107 -0
  189. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/decomposer/decomposer-agent.js +360 -0
  190. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/decomposer/decomposer-agent.js.map +1 -0
  191. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/decomposer/index.d.ts +9 -0
  192. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/decomposer/index.js +18 -0
  193. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/decomposer/index.js.map +1 -0
  194. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/intent-classifier/index.d.ts +4 -0
  195. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/intent-classifier/index.js +9 -0
  196. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/intent-classifier/index.js.map +1 -0
  197. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/intent-classifier/intent-classifier-agent.d.ts +123 -0
  198. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/intent-classifier/intent-classifier-agent.js +609 -0
  199. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/intent-classifier/intent-classifier-agent.js.map +1 -0
  200. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/meta-reasoner/index.d.ts +10 -0
  201. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/meta-reasoner/index.js +25 -0
  202. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/meta-reasoner/index.js.map +1 -0
  203. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/meta-reasoner/meta-reasoner-agent.d.ts +111 -0
  204. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/meta-reasoner/meta-reasoner-agent.js +686 -0
  205. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/meta-reasoner/meta-reasoner-agent.js.map +1 -0
  206. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/meta-reasoner/telemetry.d.ts +11 -0
  207. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/meta-reasoner/telemetry.js +25 -0
  208. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/meta-reasoner/telemetry.js.map +1 -0
  209. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/objective-clarifier/index.d.ts +6 -0
  210. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/objective-clarifier/index.js +15 -0
  211. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/objective-clarifier/index.js.map +1 -0
  212. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/objective-clarifier/objective-clarifier-agent.d.ts +126 -0
  213. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/objective-clarifier/objective-clarifier-agent.js +780 -0
  214. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/objective-clarifier/objective-clarifier-agent.js.map +1 -0
  215. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/objective-clarifier/ruvector-persistence.d.ts +49 -0
  216. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/objective-clarifier/ruvector-persistence.js +125 -0
  217. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/objective-clarifier/ruvector-persistence.js.map +1 -0
  218. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/objective-clarifier/telemetry.d.ts +73 -0
  219. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/objective-clarifier/telemetry.js +192 -0
  220. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/objective-clarifier/telemetry.js.map +1 -0
  221. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/planner/index.d.ts +11 -0
  222. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/planner/index.js +25 -0
  223. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/planner/index.js.map +1 -0
  224. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/planner/planner-agent.d.ts +119 -0
  225. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/planner/planner-agent.js +421 -0
  226. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/planner/planner-agent.js.map +1 -0
  227. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/planner/ruvector-persistence.d.ts +49 -0
  228. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/planner/ruvector-persistence.js +125 -0
  229. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/planner/ruvector-persistence.js.map +1 -0
  230. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/planner/telemetry.d.ts +73 -0
  231. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/planner/telemetry.js +192 -0
  232. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/planner/telemetry.js.map +1 -0
  233. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/reflection/index.d.ts +11 -0
  234. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/reflection/index.js +27 -0
  235. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/reflection/index.js.map +1 -0
  236. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/reflection/reflection-agent.d.ts +122 -0
  237. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/reflection/reflection-agent.js +645 -0
  238. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/reflection/reflection-agent.js.map +1 -0
  239. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/reflection/ruvector-persistence.d.ts +59 -0
  240. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/reflection/ruvector-persistence.js +156 -0
  241. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/reflection/ruvector-persistence.js.map +1 -0
  242. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/reflection/telemetry.d.ts +88 -0
  243. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/reflection/telemetry.js +246 -0
  244. package/dist/bundled-agents/copilot-agents/functions/lib/services/agents/reflection/telemetry.js.map +1 -0
  245. package/dist/bundled-agents/copilot-agents/functions/package-lock.json +5473 -0
  246. package/dist/bundled-agents/copilot-agents/functions/package.json +40 -0
  247. package/dist/bundled-agents/copilot-agents/functions/src/claude.ts +71 -0
  248. package/dist/bundled-agents/copilot-agents/functions/src/cors.ts +36 -0
  249. package/dist/bundled-agents/copilot-agents/functions/src/envelope.ts +77 -0
  250. package/dist/bundled-agents/copilot-agents/functions/src/handler.test.ts +340 -0
  251. package/dist/bundled-agents/copilot-agents/functions/src/health.ts +53 -0
  252. package/dist/bundled-agents/copilot-agents/functions/src/index.ts +201 -0
  253. package/dist/bundled-agents/copilot-agents/functions/src/router.ts +148 -0
  254. package/dist/bundled-agents/copilot-agents/functions/tsconfig.json +31 -0
  255. package/dist/bundled-agents/copilot-agents/package-lock.json +11825 -0
  256. package/dist/bundled-agents/copilot-agents/package.json +5 -0
  257. package/dist/bundled-agents/governance-dashboard-agents/package-lock.json +8282 -0
  258. package/dist/bundled-agents/governance-dashboard-agents/package.json +13 -0
  259. package/dist/bundled-agents/orchestrator-agents/functions/contracts/index.js +590 -0
  260. package/dist/bundled-agents/orchestrator-agents/functions/index.js +442 -0
  261. package/dist/bundled-agents/orchestrator-agents/functions/test.js +325 -0
  262. package/dist/bundled-agents/orchestrator-agents/index.js +6 -0
  263. package/dist/bundled-agents/orchestrator-agents/package-lock.json +13254 -0
  264. package/dist/bundled-agents/orchestrator-agents/package.json +20 -0
  265. package/dist/bundled-agents/platform-agents/package-lock.json +1723 -0
  266. package/dist/bundled-agents/platform-agents/package.json +22 -0
  267. package/dist/bundled-agents/platform-agents/src/agents/decision-memo.ts +463 -0
  268. package/dist/bundled-agents/platform-agents/src/agents/decision.ts +234 -0
  269. package/dist/bundled-agents/platform-agents/src/agents/executive-summary.ts +229 -0
  270. package/dist/bundled-agents/platform-agents/src/agents/risk-score.ts +327 -0
  271. package/dist/bundled-agents/platform-agents/src/claude.ts +71 -0
  272. package/dist/bundled-agents/platform-agents/src/cors.ts +24 -0
  273. package/dist/bundled-agents/platform-agents/src/envelope.ts +37 -0
  274. package/dist/bundled-agents/platform-agents/src/health.ts +20 -0
  275. package/dist/bundled-agents/platform-agents/src/index.ts +171 -0
  276. package/dist/bundled-agents/platform-agents/src/router.ts +38 -0
  277. package/dist/bundled-agents/platform-agents/src/text-analysis.ts +238 -0
  278. package/dist/bundled-agents/platform-agents/tsconfig.json +19 -0
  279. package/dist/bundled-agents/sentinel-agents/lib/agents/alert.d.ts +3 -0
  280. package/dist/bundled-agents/sentinel-agents/lib/agents/alert.d.ts.map +1 -0
  281. package/dist/bundled-agents/sentinel-agents/lib/agents/alert.js +43 -0
  282. package/dist/bundled-agents/sentinel-agents/lib/agents/alert.js.map +1 -0
  283. package/dist/bundled-agents/sentinel-agents/lib/agents/anomaly.d.ts +3 -0
  284. package/dist/bundled-agents/sentinel-agents/lib/agents/anomaly.d.ts.map +1 -0
  285. package/dist/bundled-agents/sentinel-agents/lib/agents/anomaly.js +30 -0
  286. package/dist/bundled-agents/sentinel-agents/lib/agents/anomaly.js.map +1 -0
  287. package/dist/bundled-agents/sentinel-agents/lib/agents/correlation.d.ts +3 -0
  288. package/dist/bundled-agents/sentinel-agents/lib/agents/correlation.d.ts.map +1 -0
  289. package/dist/bundled-agents/sentinel-agents/lib/agents/correlation.js +53 -0
  290. package/dist/bundled-agents/sentinel-agents/lib/agents/correlation.js.map +1 -0
  291. package/dist/bundled-agents/sentinel-agents/lib/agents/drift.d.ts +3 -0
  292. package/dist/bundled-agents/sentinel-agents/lib/agents/drift.d.ts.map +1 -0
  293. package/dist/bundled-agents/sentinel-agents/lib/agents/drift.js +51 -0
  294. package/dist/bundled-agents/sentinel-agents/lib/agents/drift.js.map +1 -0
  295. package/dist/bundled-agents/sentinel-agents/lib/agents/rca.d.ts +3 -0
  296. package/dist/bundled-agents/sentinel-agents/lib/agents/rca.d.ts.map +1 -0
  297. package/dist/bundled-agents/sentinel-agents/lib/agents/rca.js +36 -0
  298. package/dist/bundled-agents/sentinel-agents/lib/agents/rca.js.map +1 -0
  299. package/dist/bundled-agents/sentinel-agents/lib/index.d.ts +2 -0
  300. package/dist/bundled-agents/sentinel-agents/lib/index.d.ts.map +1 -0
  301. package/dist/bundled-agents/sentinel-agents/lib/index.js +70 -0
  302. package/dist/bundled-agents/sentinel-agents/lib/index.js.map +1 -0
  303. package/dist/bundled-agents/sentinel-agents/package-lock.json +12591 -0
  304. package/dist/bundled-agents/sentinel-agents/package.json +62 -0
  305. package/dist/bundled-agents/sentinel-agents/src/agents/alert.ts +46 -0
  306. package/dist/bundled-agents/sentinel-agents/src/agents/anomaly.ts +33 -0
  307. package/dist/bundled-agents/sentinel-agents/src/agents/correlation.ts +56 -0
  308. package/dist/bundled-agents/sentinel-agents/src/agents/drift.ts +54 -0
  309. package/dist/bundled-agents/sentinel-agents/src/agents/rca.ts +38 -0
  310. package/dist/bundled-agents/sentinel-agents/src/claude.ts +71 -0
  311. package/dist/bundled-agents/sentinel-agents/src/index.ts +77 -0
  312. package/dist/bundled-agents/sentinel-agents/tsconfig.json +20 -0
  313. package/dist/pipeline/auto-chain.d.ts.map +1 -1
  314. package/dist/pipeline/auto-chain.js +52 -0
  315. package/dist/pipeline/auto-chain.js.map +1 -1
  316. package/dist/pipeline/phase2/phases/ddd-generator.d.ts.map +1 -1
  317. package/dist/pipeline/phase2/phases/ddd-generator.js +15 -1
  318. package/dist/pipeline/phase2/phases/ddd-generator.js.map +1 -1
  319. package/dist/pipeline/phase2/phases/sparc-specification.d.ts.map +1 -1
  320. package/dist/pipeline/phase2/phases/sparc-specification.js +9 -0
  321. package/dist/pipeline/phase2/phases/sparc-specification.js.map +1 -1
  322. package/dist/pipeline/phase3/phases/domain-codegen.d.ts.map +1 -1
  323. package/dist/pipeline/phase3/phases/domain-codegen.js +41 -0
  324. package/dist/pipeline/phase3/phases/domain-codegen.js.map +1 -1
  325. package/package.json +1 -1
@@ -0,0 +1,75 @@
1
+ {
2
+ "name": "llm-connector-hub",
3
+ "version": "0.1.0",
4
+ "private": true,
5
+ "description": "A unified TypeScript framework for interfacing with multiple Large Language Model providers",
6
+ "workspaces": [
7
+ "packages/*"
8
+ ],
9
+ "publishConfig": {
10
+ "access": "public"
11
+ },
12
+ "scripts": {
13
+ "build": "npm run build --workspaces --if-present",
14
+ "test": "vitest",
15
+ "test:coverage": "vitest --coverage",
16
+ "lint": "eslint . --ext .ts",
17
+ "lint:fix": "eslint . --ext .ts --fix",
18
+ "format": "prettier --write \"**/*.{ts,json,md}\"",
19
+ "format:check": "prettier --check \"**/*.{ts,json,md}\"",
20
+ "typecheck": "tsc --noEmit",
21
+ "clean": "npm run clean --workspaces --if-present && rm -rf node_modules",
22
+ "bench": "node --expose-gc ./node_modules/.bin/tsx benchmarks/index.ts",
23
+ "bench:provider": "node --expose-gc ./node_modules/.bin/tsx benchmarks/provider-benchmark.ts",
24
+ "bench:cache": "node --expose-gc ./node_modules/.bin/tsx benchmarks/cache-benchmark.ts",
25
+ "bench:middleware": "node --expose-gc ./node_modules/.bin/tsx benchmarks/middleware-benchmark.ts",
26
+ "bench:hub": "node --expose-gc ./node_modules/.bin/tsx benchmarks/hub-benchmark.ts",
27
+ "bench:stress": "node --expose-gc ./node_modules/.bin/tsx benchmarks/stress-test.ts",
28
+ "bench:load": "node --expose-gc ./node_modules/.bin/tsx benchmarks/load-test.ts",
29
+ "bench:all": "npm run bench && npm run bench:stress && npm run bench:load",
30
+ "bench:save": "npm run bench -- all --save",
31
+ "bench:analyze": "tsx scripts/performance/analyze-results.ts",
32
+ "perf": "bash scripts/performance/run-benchmarks.sh",
33
+ "perf:load": "bash scripts/performance/run-load-tests.sh",
34
+ "prepublish": "npm run build && npm test",
35
+ "publish:all": "npm publish --workspace=packages/core && npm publish --workspace=packages/providers && npm publish --workspace=packages/middleware && npm publish --workspace=packages/hub && npm publish --workspace=packages/cli",
36
+ "publish:dry-run": "npm publish --dry-run --workspace=packages/core && npm publish --dry-run --workspace=packages/providers && npm publish --dry-run --workspace=packages/middleware && npm publish --dry-run --workspace=packages/hub && npm publish --dry-run --workspace=packages/cli",
37
+ "version:patch": "npm version patch --workspaces --no-git-tag-version",
38
+ "version:minor": "npm version minor --workspaces --no-git-tag-version",
39
+ "version:major": "npm version major --workspaces --no-git-tag-version"
40
+ },
41
+ "devDependencies": {
42
+ "@types/node": "^20.10.0",
43
+ "@typescript-eslint/eslint-plugin": "^6.15.0",
44
+ "@typescript-eslint/parser": "^6.15.0",
45
+ "@vitest/coverage-v8": "^1.0.0",
46
+ "eslint": "^8.56.0",
47
+ "eslint-config-prettier": "^9.1.0",
48
+ "eslint-plugin-import": "^2.29.1",
49
+ "prettier": "^3.1.1",
50
+ "tsx": "^4.20.6",
51
+ "typescript": "^5.3.3",
52
+ "vitest": "^1.0.0"
53
+ },
54
+ "dependencies": {
55
+ "claude-flow": "2.7.41"
56
+ },
57
+ "engines": {
58
+ "node": ">=18.0.0",
59
+ "npm": ">=9.0.0"
60
+ },
61
+ "repository": {
62
+ "type": "git",
63
+ "url": "https://github.com/globalbusinessadvisors/llm-connector-hub"
64
+ },
65
+ "keywords": [
66
+ "llm",
67
+ "openai",
68
+ "anthropic",
69
+ "ai",
70
+ "connector",
71
+ "typescript"
72
+ ],
73
+ "author": "",
74
+ "license": "Apache-2.0"
75
+ }
@@ -0,0 +1,22 @@
1
+ {
2
+ "extends": "./tsconfig.json",
3
+ "compilerOptions": {
4
+ "composite": true,
5
+ "rootDir": "./packages",
6
+ "declarationMap": true,
7
+ "sourceMap": true
8
+ },
9
+ "exclude": [
10
+ "node_modules",
11
+ "**/*.spec.ts",
12
+ "**/*.test.ts",
13
+ "**/tests/**",
14
+ "examples/**"
15
+ ],
16
+ "references": [
17
+ { "path": "./packages/core" },
18
+ { "path": "./packages/providers" },
19
+ { "path": "./packages/middleware" },
20
+ { "path": "./packages/hub" }
21
+ ]
22
+ }
@@ -0,0 +1,57 @@
1
+ {
2
+ "compilerOptions": {
3
+ /* Language and Environment */
4
+ "target": "ES2022",
5
+ "lib": ["ES2022"],
6
+ "module": "commonjs",
7
+ "moduleResolution": "node",
8
+
9
+ /* Strict Type-Checking Options */
10
+ "strict": true,
11
+ "noImplicitAny": true,
12
+ "strictNullChecks": true,
13
+ "strictFunctionTypes": true,
14
+ "strictBindCallApply": true,
15
+ "strictPropertyInitialization": true,
16
+ "noImplicitThis": true,
17
+ "alwaysStrict": true,
18
+
19
+ /* Additional Checks */
20
+ "noUnusedLocals": true,
21
+ "noUnusedParameters": true,
22
+ "noImplicitReturns": true,
23
+ "noFallthroughCasesInSwitch": true,
24
+ "noUncheckedIndexedAccess": true,
25
+ "noImplicitOverride": true,
26
+ "noPropertyAccessFromIndexSignature": true,
27
+
28
+ /* Module Resolution */
29
+ "esModuleInterop": true,
30
+ "allowSyntheticDefaultImports": true,
31
+ "resolveJsonModule": true,
32
+ "forceConsistentCasingInFileNames": true,
33
+
34
+ /* Emit */
35
+ "declaration": true,
36
+ "declarationMap": true,
37
+ "sourceMap": true,
38
+ "outDir": "./dist",
39
+ "removeComments": false,
40
+ "importHelpers": true,
41
+
42
+ /* Interop Constraints */
43
+ "isolatedModules": true,
44
+ "allowJs": false,
45
+
46
+ /* Skip Lib Check */
47
+ "skipLibCheck": true
48
+ },
49
+ "exclude": [
50
+ "node_modules",
51
+ "dist",
52
+ "**/dist",
53
+ "**/node_modules",
54
+ "**/*.spec.ts",
55
+ "**/*.test.ts"
56
+ ]
57
+ }
@@ -0,0 +1,17 @@
1
+ # This file specifies files that are *not* uploaded to Google Cloud
2
+ # using gcloud. It follows the same syntax as .gitignore, with the addition of
3
+ # "#!include" directives (which insert the entries of the given .gitignore-style
4
+ # file at that point).
5
+ #
6
+ # For more information, run:
7
+ # $ gcloud topic gcloudignore
8
+ #
9
+ .gcloudignore
10
+ # If you would like to upload your .git directory, .gitignore file or files
11
+ # from your .gitignore file, remove the corresponding line
12
+ # below:
13
+ .git
14
+ .gitignore
15
+
16
+ node_modules
17
+ #!include:.gitignore
@@ -0,0 +1,14 @@
1
+ /**
2
+ * CORS Middleware for Cloud Functions
3
+ *
4
+ * Handles preflight requests and sets CORS headers on all responses.
5
+ */
6
+ import { CfResponse } from './index';
7
+ /**
8
+ * Set CORS headers on the response
9
+ */
10
+ export declare function setCorsHeaders(res: CfResponse): void;
11
+ /**
12
+ * Handle CORS preflight (OPTIONS) request
13
+ */
14
+ export declare function handlePreflight(res: CfResponse): void;
@@ -0,0 +1,35 @@
1
+ "use strict";
2
+ /**
3
+ * CORS Middleware for Cloud Functions
4
+ *
5
+ * Handles preflight requests and sets CORS headers on all responses.
6
+ */
7
+ Object.defineProperty(exports, "__esModule", { value: true });
8
+ exports.setCorsHeaders = setCorsHeaders;
9
+ exports.handlePreflight = handlePreflight;
10
+ const ALLOWED_ORIGINS = [
11
+ 'https://agentics.dev',
12
+ 'https://console.agentics.dev',
13
+ 'https://us-central1-agentics-dev.cloudfunctions.net',
14
+ ];
15
+ const ALLOWED_METHODS = 'GET, POST, OPTIONS';
16
+ const ALLOWED_HEADERS = 'Content-Type, Authorization, X-Correlation-Id, X-Request-Id';
17
+ const MAX_AGE = '3600';
18
+ /**
19
+ * Set CORS headers on the response
20
+ */
21
+ function setCorsHeaders(res) {
22
+ // Allow any origin for now (can be restricted via ALLOWED_ORIGINS in production)
23
+ res.setHeader('Access-Control-Allow-Origin', '*');
24
+ res.setHeader('Access-Control-Allow-Methods', ALLOWED_METHODS);
25
+ res.setHeader('Access-Control-Allow-Headers', ALLOWED_HEADERS);
26
+ res.setHeader('Access-Control-Max-Age', MAX_AGE);
27
+ }
28
+ /**
29
+ * Handle CORS preflight (OPTIONS) request
30
+ */
31
+ function handlePreflight(res) {
32
+ res.writeHead(204);
33
+ res.end();
34
+ }
35
+ //# sourceMappingURL=cors.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"cors.js","sourceRoot":"","sources":["../../../src/cors.ts"],"names":[],"mappings":";AAAA;;;;GAIG;;AAiBH,wCAMC;AAKD,0CAGC;AA3BD,MAAM,eAAe,GAAG;IACtB,sBAAsB;IACtB,8BAA8B;IAC9B,qDAAqD;CACtD,CAAC;AAEF,MAAM,eAAe,GAAG,oBAAoB,CAAC;AAC7C,MAAM,eAAe,GAAG,6DAA6D,CAAC;AACtF,MAAM,OAAO,GAAG,MAAM,CAAC;AAEvB;;GAEG;AACH,SAAgB,cAAc,CAAC,GAAe;IAC5C,iFAAiF;IACjF,GAAG,CAAC,SAAS,CAAC,6BAA6B,EAAE,GAAG,CAAC,CAAC;IAClD,GAAG,CAAC,SAAS,CAAC,8BAA8B,EAAE,eAAe,CAAC,CAAC;IAC/D,GAAG,CAAC,SAAS,CAAC,8BAA8B,EAAE,eAAe,CAAC,CAAC;IAC/D,GAAG,CAAC,SAAS,CAAC,wBAAwB,EAAE,OAAO,CAAC,CAAC;AACnD,CAAC;AAED;;GAEG;AACH,SAAgB,eAAe,CAAC,GAAe;IAC7C,GAAG,CAAC,SAAS,CAAC,GAAG,CAAC,CAAC;IACnB,GAAG,CAAC,GAAG,EAAE,CAAC;AACZ,CAAC"}
@@ -0,0 +1,55 @@
1
+ /**
2
+ * Response Envelope
3
+ *
4
+ * Every response from copilot-agents MUST include:
5
+ * - execution_metadata (trace_id, timestamp, service, execution_id)
6
+ * - layers_executed (routing + agent layer with status and duration)
7
+ *
8
+ * Agent responses additionally include per-agent execution_metadata inside
9
+ * the `result` wrapper (trace_id, agent, domain, timestamp, pipeline_context).
10
+ */
11
+ import { PipelineContext } from '../../services/agents/contracts';
12
+ export interface ExecutionMetadata {
13
+ trace_id: string;
14
+ timestamp: string;
15
+ service: 'copilot-agents';
16
+ execution_id: string;
17
+ }
18
+ export interface LayerExecuted {
19
+ layer: string;
20
+ status: 'completed' | 'error';
21
+ duration_ms?: number;
22
+ }
23
+ /**
24
+ * Per-agent execution metadata included in the result wrapper
25
+ * when routing to an agent.
26
+ */
27
+ export interface AgentExecutionMetadata {
28
+ trace_id: string;
29
+ agent: string;
30
+ domain: string;
31
+ timestamp: string;
32
+ pipeline_context?: PipelineContext;
33
+ }
34
+ export interface EnvelopedResponse {
35
+ data: unknown;
36
+ execution_metadata: ExecutionMetadata;
37
+ layers_executed: LayerExecuted[];
38
+ }
39
+ /**
40
+ * Wrap any response payload with execution_metadata and layers_executed
41
+ */
42
+ export declare function wrapResponse(data: unknown, executionMetadata: ExecutionMetadata, layersExecuted: LayerExecuted[]): EnvelopedResponse;
43
+ /**
44
+ * Wrap an agent result with per-agent execution_metadata.
45
+ *
46
+ * Produces:
47
+ * {
48
+ * result: <agentResult>,
49
+ * execution_metadata: { trace_id, agent, domain, timestamp, pipeline_context? }
50
+ * }
51
+ */
52
+ export declare function wrapAgentResult(agentResult: unknown, agentMeta: AgentExecutionMetadata): {
53
+ result: unknown;
54
+ execution_metadata: AgentExecutionMetadata;
55
+ };
@@ -0,0 +1,40 @@
1
+ "use strict";
2
+ /**
3
+ * Response Envelope
4
+ *
5
+ * Every response from copilot-agents MUST include:
6
+ * - execution_metadata (trace_id, timestamp, service, execution_id)
7
+ * - layers_executed (routing + agent layer with status and duration)
8
+ *
9
+ * Agent responses additionally include per-agent execution_metadata inside
10
+ * the `result` wrapper (trace_id, agent, domain, timestamp, pipeline_context).
11
+ */
12
+ Object.defineProperty(exports, "__esModule", { value: true });
13
+ exports.wrapResponse = wrapResponse;
14
+ exports.wrapAgentResult = wrapAgentResult;
15
+ /**
16
+ * Wrap any response payload with execution_metadata and layers_executed
17
+ */
18
+ function wrapResponse(data, executionMetadata, layersExecuted) {
19
+ return {
20
+ data,
21
+ execution_metadata: executionMetadata,
22
+ layers_executed: layersExecuted,
23
+ };
24
+ }
25
+ /**
26
+ * Wrap an agent result with per-agent execution_metadata.
27
+ *
28
+ * Produces:
29
+ * {
30
+ * result: <agentResult>,
31
+ * execution_metadata: { trace_id, agent, domain, timestamp, pipeline_context? }
32
+ * }
33
+ */
34
+ function wrapAgentResult(agentResult, agentMeta) {
35
+ return {
36
+ result: agentResult,
37
+ execution_metadata: agentMeta,
38
+ };
39
+ }
40
+ //# sourceMappingURL=envelope.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"envelope.js","sourceRoot":"","sources":["../../../src/envelope.ts"],"names":[],"mappings":";AAAA;;;;;;;;;GASG;;AAsCH,oCAUC;AAWD,0CAQC;AAhCD;;GAEG;AACH,SAAgB,YAAY,CAC1B,IAAa,EACb,iBAAoC,EACpC,cAA+B;IAE/B,OAAO;QACL,IAAI;QACJ,kBAAkB,EAAE,iBAAiB;QACrC,eAAe,EAAE,cAAc;KAChC,CAAC;AACJ,CAAC;AAED;;;;;;;;GAQG;AACH,SAAgB,eAAe,CAC7B,WAAoB,EACpB,SAAiC;IAEjC,OAAO;QACL,MAAM,EAAE,WAAW;QACnB,kBAAkB,EAAE,SAAS;KAC9B,CAAC;AACJ,CAAC"}
@@ -0,0 +1,22 @@
1
+ /**
2
+ * Health Check Handler
3
+ *
4
+ * Returns the status of all 7 copilot agents.
5
+ * Agents: planner, config, decomposer, clarifier, intent, reflection, meta-reasoner
6
+ */
7
+ export interface AgentHealthStatus {
8
+ agent: string;
9
+ status: 'healthy' | 'degraded' | 'unhealthy';
10
+ version: string;
11
+ }
12
+ export interface HealthResponse {
13
+ status: 'healthy' | 'degraded' | 'unhealthy';
14
+ service: string;
15
+ version: string;
16
+ agents: AgentHealthStatus[];
17
+ uptime_seconds: number;
18
+ }
19
+ /**
20
+ * Build health check response for all agents
21
+ */
22
+ export declare function handleHealth(): HealthResponse;
@@ -0,0 +1,38 @@
1
+ "use strict";
2
+ /**
3
+ * Health Check Handler
4
+ *
5
+ * Returns the status of all 7 copilot agents.
6
+ * Agents: planner, config, decomposer, clarifier, intent, reflection, meta-reasoner
7
+ */
8
+ Object.defineProperty(exports, "__esModule", { value: true });
9
+ exports.handleHealth = handleHealth;
10
+ const SERVICE_START_TIME = Date.now();
11
+ const AGENT_REGISTRY = [
12
+ { name: 'planner', version: '1.0.0' },
13
+ { name: 'config', version: '1.0.0' },
14
+ { name: 'decomposer', version: '1.0.0' },
15
+ { name: 'clarifier', version: '1.0.0' },
16
+ { name: 'intent', version: '1.0.0' },
17
+ { name: 'reflection', version: '1.0.0' },
18
+ { name: 'meta-reasoner', version: '1.0.0' },
19
+ ];
20
+ /**
21
+ * Build health check response for all agents
22
+ */
23
+ function handleHealth() {
24
+ const agents = AGENT_REGISTRY.map(agent => ({
25
+ agent: agent.name,
26
+ status: 'healthy',
27
+ version: agent.version,
28
+ }));
29
+ const allHealthy = agents.every(a => a.status === 'healthy');
30
+ return {
31
+ status: allHealthy ? 'healthy' : 'degraded',
32
+ service: 'copilot-agents',
33
+ version: '1.0.0',
34
+ agents,
35
+ uptime_seconds: Math.floor((Date.now() - SERVICE_START_TIME) / 1000),
36
+ };
37
+ }
38
+ //# sourceMappingURL=health.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"health.js","sourceRoot":"","sources":["../../../src/health.ts"],"names":[],"mappings":";AAAA;;;;;GAKG;;AA+BH,oCAgBC;AA/BD,MAAM,kBAAkB,GAAG,IAAI,CAAC,GAAG,EAAE,CAAC;AAEtC,MAAM,cAAc,GAA6C;IAC/D,EAAE,IAAI,EAAE,SAAS,EAAE,OAAO,EAAE,OAAO,EAAE;IACrC,EAAE,IAAI,EAAE,QAAQ,EAAE,OAAO,EAAE,OAAO,EAAE;IACpC,EAAE,IAAI,EAAE,YAAY,EAAE,OAAO,EAAE,OAAO,EAAE;IACxC,EAAE,IAAI,EAAE,WAAW,EAAE,OAAO,EAAE,OAAO,EAAE;IACvC,EAAE,IAAI,EAAE,QAAQ,EAAE,OAAO,EAAE,OAAO,EAAE;IACpC,EAAE,IAAI,EAAE,YAAY,EAAE,OAAO,EAAE,OAAO,EAAE;IACxC,EAAE,IAAI,EAAE,eAAe,EAAE,OAAO,EAAE,OAAO,EAAE;CAC5C,CAAC;AAEF;;GAEG;AACH,SAAgB,YAAY;IAC1B,MAAM,MAAM,GAAwB,cAAc,CAAC,GAAG,CAAC,KAAK,CAAC,EAAE,CAAC,CAAC;QAC/D,KAAK,EAAE,KAAK,CAAC,IAAI;QACjB,MAAM,EAAE,SAAkB;QAC1B,OAAO,EAAE,KAAK,CAAC,OAAO;KACvB,CAAC,CAAC,CAAC;IAEJ,MAAM,UAAU,GAAG,MAAM,CAAC,KAAK,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,MAAM,KAAK,SAAS,CAAC,CAAC;IAE7D,OAAO;QACL,MAAM,EAAE,UAAU,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,UAAU;QAC3C,OAAO,EAAE,gBAAgB;QACzB,OAAO,EAAE,OAAO;QAChB,MAAM;QACN,cAAc,EAAE,IAAI,CAAC,KAAK,CAAC,CAAC,IAAI,CAAC,GAAG,EAAE,GAAG,kBAAkB,CAAC,GAAG,IAAI,CAAC;KACrE,CAAC;AACJ,CAAC"}
@@ -0,0 +1,34 @@
1
+ /**
2
+ * Cloud Function Entry Point: copilot-agents
3
+ *
4
+ * Unified HTTP handler for all 7 copilot agents.
5
+ * Deploy: gcloud functions deploy copilot-agents --runtime nodejs20 --trigger-http
6
+ * --region us-central1 --project agentics-dev --entry-point handler
7
+ * --memory 512MB --timeout 120s --no-allow-unauthenticated
8
+ *
9
+ * Routes:
10
+ * POST /v1/copilot/planner → Planner Agent
11
+ * POST /v1/copilot/config → Config Validation Agent
12
+ * POST /v1/copilot/decomposer → Decomposer Agent
13
+ * POST /v1/copilot/clarifier → Objective Clarifier Agent
14
+ * POST /v1/copilot/intent → Intent Classifier Agent
15
+ * POST /v1/copilot/reflection → Reflection Agent
16
+ * POST /v1/copilot/meta-reasoner → Meta-Reasoner Agent
17
+ * GET /health → Health check
18
+ */
19
+ import { IncomingMessage, ServerResponse } from 'http';
20
+ export interface CfRequest extends IncomingMessage {
21
+ body?: unknown;
22
+ rawBody?: Buffer;
23
+ }
24
+ export interface CfResponse extends ServerResponse {
25
+ status?: (code: number) => CfResponse;
26
+ json?: (data: unknown) => void;
27
+ send?: (data: string | Buffer) => void;
28
+ }
29
+ /**
30
+ * Main Cloud Function handler
31
+ *
32
+ * Entry point name: handler
33
+ */
34
+ export declare function handler(req: CfRequest, res: CfResponse): Promise<void>;
@@ -0,0 +1,186 @@
1
+ "use strict";
2
+ /**
3
+ * Cloud Function Entry Point: copilot-agents
4
+ *
5
+ * Unified HTTP handler for all 7 copilot agents.
6
+ * Deploy: gcloud functions deploy copilot-agents --runtime nodejs20 --trigger-http
7
+ * --region us-central1 --project agentics-dev --entry-point handler
8
+ * --memory 512MB --timeout 120s --no-allow-unauthenticated
9
+ *
10
+ * Routes:
11
+ * POST /v1/copilot/planner → Planner Agent
12
+ * POST /v1/copilot/config → Config Validation Agent
13
+ * POST /v1/copilot/decomposer → Decomposer Agent
14
+ * POST /v1/copilot/clarifier → Objective Clarifier Agent
15
+ * POST /v1/copilot/intent → Intent Classifier Agent
16
+ * POST /v1/copilot/reflection → Reflection Agent
17
+ * POST /v1/copilot/meta-reasoner → Meta-Reasoner Agent
18
+ * GET /health → Health check
19
+ */
20
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
21
+ if (k2 === undefined) k2 = k;
22
+ var desc = Object.getOwnPropertyDescriptor(m, k);
23
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
24
+ desc = { enumerable: true, get: function() { return m[k]; } };
25
+ }
26
+ Object.defineProperty(o, k2, desc);
27
+ }) : (function(o, m, k, k2) {
28
+ if (k2 === undefined) k2 = k;
29
+ o[k2] = m[k];
30
+ }));
31
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
32
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
33
+ }) : function(o, v) {
34
+ o["default"] = v;
35
+ });
36
+ var __importStar = (this && this.__importStar) || (function () {
37
+ var ownKeys = function(o) {
38
+ ownKeys = Object.getOwnPropertyNames || function (o) {
39
+ var ar = [];
40
+ for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
41
+ return ar;
42
+ };
43
+ return ownKeys(o);
44
+ };
45
+ return function (mod) {
46
+ if (mod && mod.__esModule) return mod;
47
+ var result = {};
48
+ if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
49
+ __setModuleDefault(result, mod);
50
+ return result;
51
+ };
52
+ })();
53
+ Object.defineProperty(exports, "__esModule", { value: true });
54
+ exports.handler = handler;
55
+ const crypto = __importStar(require("crypto"));
56
+ const router_1 = require("./router");
57
+ const health_1 = require("./health");
58
+ const cors_1 = require("./cors");
59
+ const envelope_1 = require("./envelope");
60
+ /**
61
+ * Parse JSON body from request
62
+ */
63
+ function parseBody(req) {
64
+ // Cloud Functions automatically parse JSON bodies into req.body
65
+ if (req.body !== undefined) {
66
+ return req.body;
67
+ }
68
+ return undefined;
69
+ }
70
+ /**
71
+ * Send JSON response
72
+ */
73
+ function sendJson(res, statusCode, data) {
74
+ res.writeHead(statusCode, { 'Content-Type': 'application/json' });
75
+ res.end(JSON.stringify(data));
76
+ }
77
+ /**
78
+ * Main Cloud Function handler
79
+ *
80
+ * Entry point name: handler
81
+ */
82
+ async function handler(req, res) {
83
+ const startTime = Date.now();
84
+ // CORS headers on every response
85
+ (0, cors_1.setCorsHeaders)(res);
86
+ // Handle CORS preflight
87
+ if (req.method === 'OPTIONS') {
88
+ (0, cors_1.handlePreflight)(res);
89
+ return;
90
+ }
91
+ const url = new URL(req.url || '/', `https://${req.headers.host || 'localhost'}`);
92
+ const pathname = url.pathname;
93
+ // Build execution metadata
94
+ const traceId = req.headers['x-correlation-id'] || crypto.randomUUID();
95
+ const executionId = crypto.randomUUID();
96
+ const executionMetadata = {
97
+ trace_id: traceId,
98
+ timestamp: new Date().toISOString(),
99
+ service: 'copilot-agents',
100
+ execution_id: executionId,
101
+ };
102
+ // Health endpoint
103
+ if (pathname === '/health' && (req.method === 'GET' || req.method === 'HEAD')) {
104
+ const healthResult = (0, health_1.handleHealth)();
105
+ const layers = [
106
+ { layer: 'AGENT_ROUTING', status: 'completed' },
107
+ { layer: 'HEALTH_CHECK', status: 'completed', duration_ms: Date.now() - startTime },
108
+ ];
109
+ sendJson(res, 200, (0, envelope_1.wrapResponse)(healthResult, executionMetadata, layers));
110
+ return;
111
+ }
112
+ // Agent routes: POST /v1/copilot/{agent}
113
+ if (req.method === 'POST' && pathname.startsWith('/v1/copilot/')) {
114
+ // Require end-user Anthropic API key via header
115
+ const anthropicApiKey = req.headers['x-anthropic-api-key'];
116
+ if (!anthropicApiKey) {
117
+ const layers = [
118
+ { layer: 'AGENT_ROUTING', status: 'error' },
119
+ ];
120
+ sendJson(res, 400, (0, envelope_1.wrapResponse)({ error: 'Missing Anthropic API key. Set it via `agentics login` or the ANTHROPIC_API_KEY environment variable.' }, executionMetadata, layers));
121
+ return;
122
+ }
123
+ const agentSlug = pathname.replace('/v1/copilot/', '').replace(/\/$/, '');
124
+ const body = parseBody(req);
125
+ if (!body || typeof body !== 'object') {
126
+ const layers = [
127
+ { layer: 'AGENT_ROUTING', status: 'completed' },
128
+ ];
129
+ sendJson(res, 400, (0, envelope_1.wrapResponse)({ error: 'Request body must be a JSON object' }, executionMetadata, layers));
130
+ return;
131
+ }
132
+ try {
133
+ const routingLayerStart = Date.now();
134
+ const routeResult = await (0, router_1.routeRequest)(agentSlug, body);
135
+ const routingDuration = Date.now() - routingLayerStart;
136
+ const agentName = agentSlug.toUpperCase().replace(/-/g, '_');
137
+ const layers = [
138
+ { layer: 'AGENT_ROUTING', status: 'completed' },
139
+ { layer: `COPILOT_${agentName}`, status: 'completed', duration_ms: routingDuration },
140
+ ];
141
+ // Build per-agent execution_metadata
142
+ const agentMeta = {
143
+ trace_id: traceId,
144
+ agent: agentSlug,
145
+ domain: 'copilot',
146
+ timestamp: new Date().toISOString(),
147
+ };
148
+ if (routeResult.pipelineContext) {
149
+ agentMeta.pipeline_context = routeResult.pipelineContext;
150
+ }
151
+ // Wrap the agent result with per-agent execution_metadata
152
+ const wrappedResult = (0, envelope_1.wrapAgentResult)(routeResult.agentResult, agentMeta);
153
+ const statusCode = routeResult.agentResult.status === 'success' ? 200 : 422;
154
+ sendJson(res, statusCode, (0, envelope_1.wrapResponse)(wrappedResult, executionMetadata, layers));
155
+ return;
156
+ }
157
+ catch (err) {
158
+ const agentName = agentSlug.toUpperCase().replace(/-/g, '_');
159
+ const layers = [
160
+ { layer: 'AGENT_ROUTING', status: 'completed' },
161
+ { layer: `COPILOT_${agentName}`, status: 'error', duration_ms: Date.now() - startTime },
162
+ ];
163
+ const errorMessage = err instanceof Error ? err.message : 'Internal server error';
164
+ sendJson(res, 500, (0, envelope_1.wrapResponse)({ error: errorMessage }, executionMetadata, layers));
165
+ return;
166
+ }
167
+ }
168
+ // 404 for unmatched routes
169
+ const layers = [
170
+ { layer: 'AGENT_ROUTING', status: 'error' },
171
+ ];
172
+ sendJson(res, 404, (0, envelope_1.wrapResponse)({
173
+ error: 'Not found',
174
+ available_routes: [
175
+ 'POST /v1/copilot/planner',
176
+ 'POST /v1/copilot/config',
177
+ 'POST /v1/copilot/decomposer',
178
+ 'POST /v1/copilot/clarifier',
179
+ 'POST /v1/copilot/intent',
180
+ 'POST /v1/copilot/reflection',
181
+ 'POST /v1/copilot/meta-reasoner',
182
+ 'GET /health',
183
+ ],
184
+ }, executionMetadata, layers));
185
+ }
186
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/index.ts"],"names":[],"mappings":"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"}
@@ -0,0 +1,36 @@
1
+ /**
2
+ * Agent Router
3
+ *
4
+ * Maps URL slugs to agent invocations.
5
+ * Does NOT create new agents or modify business logic.
6
+ * Instantiates existing agents with persistence/telemetry from env
7
+ * and routes HTTP bodies to agent.invoke().
8
+ *
9
+ * Routes:
10
+ * planner → PlannerAgent
11
+ * config → ConfigValidationAgent
12
+ * decomposer → DecomposerAgent
13
+ * clarifier → ObjectiveClarifierAgent
14
+ * intent → IntentClassifierAgent
15
+ * reflection → ReflectionAgent
16
+ * meta-reasoner → MetaReasonerAgent
17
+ */
18
+ import { AgentResult, PipelineContext } from '../../services/agents/contracts';
19
+ /**
20
+ * Result of routing a request to an agent.
21
+ * Includes the AgentResult plus metadata needed for the response envelope.
22
+ */
23
+ export interface RouteResult {
24
+ agentResult: AgentResult;
25
+ agentSlug: string;
26
+ pipelineContext?: PipelineContext;
27
+ }
28
+ /**
29
+ * Route a request to the appropriate agent
30
+ *
31
+ * @param slug - The agent slug from the URL path
32
+ * @param body - The parsed JSON request body
33
+ * @returns RouteResult with agent result and metadata
34
+ * @throws If the slug is unknown
35
+ */
36
+ export declare function routeRequest(slug: string, body: unknown): Promise<RouteResult>;