@futdevpro/ccap 1.1.3371 → 1.1.3441

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 (238) hide show
  1. package/client-dist/{agent-instances.module-TPKOBI3N.js → agent-instances.module-4ADMPXCV.js} +2 -2
  2. package/client-dist/{ca.module-I5N6QWSU.js → ca.module-RVGC3WQC.js} +2 -2
  3. package/client-dist/{cc-usage-dashboard.component-7SPVADUQ.js → cc-usage-dashboard.component-OQS2BC4L.js} +2 -2
  4. package/client-dist/{cc.module-7IL3QO5Q.js → cc.module-SPB35JNX.js} +2 -2
  5. package/client-dist/{chunk-77YTUUCR.js → chunk-2ATSF4KC.js} +2 -2
  6. package/client-dist/{chunk-RYD462IO.js → chunk-3HJWN4W6.js} +2 -2
  7. package/client-dist/{chunk-GG2WP2KM.js → chunk-4EV32FFZ.js} +2 -2
  8. package/client-dist/{chunk-UD4PV7CD.js → chunk-4H3E32UH.js} +2 -2
  9. package/client-dist/{chunk-BH3GMEZZ.js → chunk-4LCJ4GNK.js} +2 -2
  10. package/client-dist/{chunk-KX2KGHQZ.js → chunk-5NW5UGVZ.js} +2 -2
  11. package/client-dist/{chunk-BJ4I73WC.js → chunk-AM5URSKV.js} +2 -2
  12. package/client-dist/{chunk-U3Y5GO6O.js → chunk-AMROWQBM.js} +2 -2
  13. package/client-dist/{chunk-LCKABD2M.js → chunk-AR6EOT63.js} +2 -2
  14. package/client-dist/{chunk-U64N3LCA.js → chunk-B25EGDHU.js} +2 -2
  15. package/client-dist/{chunk-44TWBJUK.js → chunk-BQTJHETS.js} +2 -2
  16. package/client-dist/{chunk-657E66YR.js → chunk-COOWEMEW.js} +2 -2
  17. package/client-dist/{chunk-E6WOJOGT.js → chunk-E3JXFFHE.js} +2 -2
  18. package/client-dist/{chunk-LIGODF4I.js → chunk-ESIGVRCK.js} +2 -2
  19. package/client-dist/{chunk-CAMM4S7P.js → chunk-EVMDNGBK.js} +2 -2
  20. package/client-dist/{chunk-26YUXPZI.js → chunk-F6VMAVI5.js} +2 -2
  21. package/client-dist/chunk-FRVRMJQF.js +2 -0
  22. package/client-dist/chunk-FRVRMJQF.js.map +7 -0
  23. package/client-dist/{chunk-W7HIS2QA.js → chunk-GBOES7QW.js} +2 -2
  24. package/client-dist/{chunk-DXF2FJLD.js → chunk-GTERKRTR.js} +2 -2
  25. package/client-dist/{chunk-SK3XGSYF.js → chunk-HD4CODAD.js} +2 -2
  26. package/client-dist/{chunk-L2XJGYW4.js → chunk-I3FSMGMK.js} +2 -2
  27. package/client-dist/{chunk-5YDHEFSD.js → chunk-IFYHOOVA.js} +2 -2
  28. package/client-dist/{chunk-C4FOSX27.js → chunk-IUAZJ3PT.js} +2 -2
  29. package/client-dist/{chunk-XFXMWTQS.js → chunk-IVLMVAVJ.js} +2 -2
  30. package/client-dist/{chunk-3G2ZGV66.js → chunk-KBMXCICX.js} +2 -2
  31. package/client-dist/{chunk-5RLDT3NY.js → chunk-KIKSSJKL.js} +2 -2
  32. package/client-dist/{chunk-OLLHHMTV.js → chunk-LPNQ5PRN.js} +2 -2
  33. package/client-dist/{chunk-OKUYYDGV.js → chunk-MO37SUK2.js} +2 -2
  34. package/client-dist/{chunk-OCNDLQG5.js → chunk-MYVEHPA7.js} +2 -2
  35. package/client-dist/{chunk-PW5BAINL.js → chunk-N55GOFVU.js} +2 -2
  36. package/client-dist/{chunk-IHNAAEA2.js → chunk-NNUHTCXG.js} +2 -2
  37. package/client-dist/{chunk-7VY64KMU.js → chunk-OKTAADTQ.js} +2 -2
  38. package/client-dist/{chunk-4EOSKDXN.js → chunk-ONS7XQYD.js} +2 -2
  39. package/client-dist/{chunk-4JL2Q6FO.js → chunk-OYB7GU43.js} +2 -2
  40. package/client-dist/{chunk-A33MCHYC.js → chunk-PVSQ5ZEZ.js} +14 -14
  41. package/client-dist/{chunk-A33MCHYC.js.map → chunk-PVSQ5ZEZ.js.map} +3 -3
  42. package/client-dist/{chunk-TFB7ULAV.js → chunk-PZN2OI7U.js} +2 -2
  43. package/client-dist/{chunk-VRG74DKK.js → chunk-QUD3BEHN.js} +2 -2
  44. package/client-dist/{chunk-QQ2GRU2N.js → chunk-QUEYZI42.js} +2 -2
  45. package/client-dist/{chunk-XWYXBY7S.js → chunk-R2IBKJ4K.js} +2 -2
  46. package/client-dist/{chunk-4FK2D2PX.js → chunk-RAHCHCWR.js} +2 -2
  47. package/client-dist/{chunk-J5INQQ5M.js → chunk-RCCUSGIN.js} +2 -2
  48. package/client-dist/{chunk-CU5YQ2M4.js → chunk-RL5LPTPO.js} +2 -2
  49. package/client-dist/{chunk-7CMPZXAO.js → chunk-SDVXPGB7.js} +2 -2
  50. package/client-dist/{chunk-UVVGFHUG.js → chunk-TNLHQRL7.js} +2 -2
  51. package/client-dist/{chunk-25KTNALK.js → chunk-TWK7BOB7.js} +2 -2
  52. package/client-dist/{chunk-OS5KCUZD.js → chunk-U62YECNK.js} +2 -2
  53. package/client-dist/{chunk-VOFDBT5T.js → chunk-UOC6UYZT.js} +2 -2
  54. package/client-dist/{chunk-C2BQQRVH.js → chunk-VDQROW6J.js} +2 -2
  55. package/client-dist/{chunk-UM7AS2IW.js → chunk-VMXIXZV2.js} +2 -2
  56. package/client-dist/chunk-VQ4GBHH7.js +2 -0
  57. package/client-dist/chunk-VQ4GBHH7.js.map +7 -0
  58. package/client-dist/{chunk-6BYNIFJY.js → chunk-WRI37SX4.js} +2 -2
  59. package/client-dist/{chunk-LMK3IOKN.js → chunk-XLSL262Q.js} +2 -2
  60. package/client-dist/{chunk-RUSAMFGS.js → chunk-Y6V4NGLU.js} +2 -2
  61. package/client-dist/{chunk-RUSAMFGS.js.map → chunk-Y6V4NGLU.js.map} +1 -1
  62. package/client-dist/{chunk-PMJP2N4K.js → chunk-YN4H6MW2.js} +2 -2
  63. package/client-dist/{chunk-EDMLVG72.js → chunk-Z5FUR5ZW.js} +2 -2
  64. package/client-dist/{chunk-4PBNHSRW.js → chunk-ZCHMBEHT.js} +2 -2
  65. package/client-dist/{chunk-L42Z7YNK.js → chunk-ZPJ6KYMA.js} +2 -2
  66. package/client-dist/{consultant.module-HHTHUWRL.js → consultant.module-UWXLFLDS.js} +2 -2
  67. package/client-dist/{crd.module-ER6AHSX5.js → crd.module-2I2BDC3A.js} +2 -2
  68. package/client-dist/{dashboard.module-TSNGGBCI.js → dashboard.module-X2A6LOTA.js} +2 -2
  69. package/client-dist/{do.module-NMZD5VSM.js → do.module-CJWEKZ4L.js} +2 -2
  70. package/client-dist/{document-library.module-GHDNXP3T.js → document-library.module-WJSFZPA7.js} +2 -2
  71. package/client-dist/{embedding-eval.module-XPXBOIP5.js → embedding-eval.module-FOALIAQW.js} +2 -2
  72. package/client-dist/{embedding-registry.module-45TQGZI2.js → embedding-registry.module-SS646R4H.js} +2 -2
  73. package/client-dist/err.module-SR4ZAOQH.js +6 -0
  74. package/client-dist/err.module-SR4ZAOQH.js.map +7 -0
  75. package/client-dist/{feedback.module-TLKZ4B4N.js → feedback.module-T3MZQKXV.js} +2 -2
  76. package/client-dist/{host-runtime-mcp.module-HVJZN5R5.js → host-runtime-mcp.module-FBZZGQGD.js} +2 -2
  77. package/client-dist/index.html +2 -2
  78. package/client-dist/{live-dev-pipeline.module-5PE4ZFFW.js → live-dev-pipeline.module-OKQYFSJL.js} +2 -2
  79. package/client-dist/{logs.module-335EXKCD.js → logs.module-SHHOD5XW.js} +2 -2
  80. package/client-dist/{main-FRD6VXVH.js → main-L3WW2VTB.js} +3 -3
  81. package/client-dist/{master-control-remote-poc.module-ORHRUCZH.js → master-control-remote-poc.module-ITXHYU5K.js} +2 -2
  82. package/client-dist/{mobile-app.module-BYYNVKQR.js → mobile-app.module-Q3W3PU4O.js} +2 -2
  83. package/client-dist/{model-registry.module-KIHIJ2Z6.js → model-registry.module-DGN55LTQ.js} +2 -2
  84. package/client-dist/{oc.module-DAGIRW3Z.js → oc.module-DYSATWML.js} +2 -2
  85. package/client-dist/orc.module-NQO6OLPK.js +2 -0
  86. package/client-dist/orc.module-NQO6OLPK.js.map +7 -0
  87. package/client-dist/{project-management.module-IJNPSUQZ.js → project-management.module-T7NBKKSR.js} +2 -2
  88. package/client-dist/project-source-routed.module-YO54LEGN.js +2 -0
  89. package/client-dist/{scheduler.module-S3IKZCLL.js → scheduler.module-4CMBOTGZ.js} +2 -2
  90. package/client-dist/{session.module-FZC22UUN.js → session.module-V4SRPQRZ.js} +9 -9
  91. package/client-dist/{session.module-FZC22UUN.js.map → session.module-V4SRPQRZ.js.map} +3 -3
  92. package/client-dist/{set.module-Y2RHKW7A.js → set.module-32SVEWTG.js} +2 -2
  93. package/client-dist/{setup.module-VTI5EZ3Q.js → setup.module-5T6MCMR4.js} +2 -2
  94. package/client-dist/styles-CTUT42AQ.css +2 -0
  95. package/client-dist/{styles-MX7ZZMTH.css.map → styles-CTUT42AQ.css.map} +1 -1
  96. package/client-dist/{terminals.module-KHEDY6QN.js → terminals.module-AQO2TVO2.js} +2 -2
  97. package/client-dist/{voice-notes-poc.module-EMDLJJIT.js → voice-notes-poc.module-EI2HY7YJ.js} +2 -2
  98. package/client-dist/{wfs.module-LUTFNQG5.js → wfs.module-AHRZE5WB.js} +2 -2
  99. package/package.json +1 -1
  100. package/server/build/src/_modules/ccap-agent/_modules/agent-core/_modules/run/_services/control-services/run-flow.control-service.d.ts.map +1 -1
  101. package/server/build/src/_modules/ccap-agent/_modules/agent-core/_modules/run/_services/control-services/run-flow.control-service.js +8 -1
  102. package/server/build/src/_modules/ccap-agent/_modules/agent-core/_modules/run/_services/control-services/run-flow.control-service.js.map +1 -1
  103. package/server/build/src/_modules/ccap-agent/_modules/integrations/_modules/voice/_collections/utils/voc-mp3-id3-strip.util.d.ts +47 -0
  104. package/server/build/src/_modules/ccap-agent/_modules/integrations/_modules/voice/_collections/utils/voc-mp3-id3-strip.util.d.ts.map +1 -0
  105. package/server/build/src/_modules/ccap-agent/_modules/integrations/_modules/voice/_collections/utils/voc-mp3-id3-strip.util.js +100 -0
  106. package/server/build/src/_modules/ccap-agent/_modules/integrations/_modules/voice/_collections/utils/voc-mp3-id3-strip.util.js.map +1 -0
  107. package/server/build/src/_modules/ccap-agent/_modules/integrations/_modules/voice/_collections/utils/voc-mp3-id3-strip.util.spec.d.ts +2 -0
  108. package/server/build/src/_modules/ccap-agent/_modules/integrations/_modules/voice/_collections/utils/voc-mp3-id3-strip.util.spec.d.ts.map +1 -0
  109. package/server/build/src/_modules/ccap-agent/_modules/integrations/_modules/voice/_collections/utils/voc-mp3-id3-strip.util.spec.js +162 -0
  110. package/server/build/src/_modules/ccap-agent/_modules/integrations/_modules/voice/_collections/utils/voc-mp3-id3-strip.util.spec.js.map +1 -0
  111. package/server/build/src/_modules/ccap-agent/_modules/integrations/_modules/voice/_services/control-services/tts/voc-tts.control-service.d.ts.map +1 -1
  112. package/server/build/src/_modules/ccap-agent/_modules/integrations/_modules/voice/_services/control-services/tts/voc-tts.control-service.js +22 -4
  113. package/server/build/src/_modules/ccap-agent/_modules/integrations/_modules/voice/_services/control-services/tts/voc-tts.control-service.js.map +1 -1
  114. package/server/build/src/_modules/external-sessions/_modules/claude-code/_collections/utils/cc-stream-parser.util.d.ts +17 -0
  115. package/server/build/src/_modules/external-sessions/_modules/claude-code/_collections/utils/cc-stream-parser.util.d.ts.map +1 -1
  116. package/server/build/src/_modules/external-sessions/_modules/claude-code/_collections/utils/cc-stream-parser.util.js +65 -5
  117. package/server/build/src/_modules/external-sessions/_modules/claude-code/_collections/utils/cc-stream-parser.util.js.map +1 -1
  118. package/server/build/src/_modules/external-sessions/_modules/claude-code/_collections/utils/cc-stream-parser.util.spec.d.ts +9 -0
  119. package/server/build/src/_modules/external-sessions/_modules/claude-code/_collections/utils/cc-stream-parser.util.spec.d.ts.map +1 -0
  120. package/server/build/src/_modules/external-sessions/_modules/claude-code/_collections/utils/cc-stream-parser.util.spec.js +213 -0
  121. package/server/build/src/_modules/external-sessions/_modules/claude-code/_collections/utils/cc-stream-parser.util.spec.js.map +1 -0
  122. package/server/build/src/_modules/external-sessions/_modules/claude-code/_services/core/cc-adapter.control-service.d.ts.map +1 -1
  123. package/server/build/src/_modules/external-sessions/_modules/claude-code/_services/core/cc-adapter.control-service.js +8 -0
  124. package/server/build/src/_modules/external-sessions/_modules/claude-code/_services/core/cc-adapter.control-service.js.map +1 -1
  125. package/server/build/src/_modules/external-sessions/_modules/claude-code/_services/core/cc-adapter.interface.d.ts +10 -0
  126. package/server/build/src/_modules/external-sessions/_modules/claude-code/_services/core/cc-adapter.interface.d.ts.map +1 -1
  127. package/server/build/src/_modules/external-sessions/_modules/claude-code/_services/core/cc-manager.control-service.d.ts +39 -0
  128. package/server/build/src/_modules/external-sessions/_modules/claude-code/_services/core/cc-manager.control-service.d.ts.map +1 -1
  129. package/server/build/src/_modules/external-sessions/_modules/claude-code/_services/core/cc-manager.control-service.js +88 -0
  130. package/server/build/src/_modules/external-sessions/_modules/claude-code/_services/core/cc-manager.control-service.js.map +1 -1
  131. package/server/build/src/_modules/external-sessions/_modules/claude-code/_services/core/status/cc-status-transition.control-service.d.ts +13 -0
  132. package/server/build/src/_modules/external-sessions/_modules/claude-code/_services/core/status/cc-status-transition.control-service.d.ts.map +1 -1
  133. package/server/build/src/_modules/external-sessions/_modules/claude-code/_services/core/status/cc-status-transition.control-service.js +39 -0
  134. package/server/build/src/_modules/external-sessions/_modules/claude-code/_services/core/status/cc-status-transition.control-service.js.map +1 -1
  135. package/server/build/src/_modules/external-sessions/_modules/claude-code/_services/core/terminal/cc-adapter-terminal.control-service.d.ts.map +1 -1
  136. package/server/build/src/_modules/external-sessions/_modules/claude-code/_services/core/terminal/cc-adapter-terminal.control-service.js +9 -0
  137. package/server/build/src/_modules/external-sessions/_modules/claude-code/_services/core/terminal/cc-adapter-terminal.control-service.js.map +1 -1
  138. package/server/build/src/_modules/notification/_collections/utils/ntf-system-event.util.d.ts +10 -0
  139. package/server/build/src/_modules/notification/_collections/utils/ntf-system-event.util.d.ts.map +1 -1
  140. package/server/build/src/_modules/notification/_collections/utils/ntf-system-event.util.js +18 -0
  141. package/server/build/src/_modules/notification/_collections/utils/ntf-system-event.util.js.map +1 -1
  142. package/server/build/src/_modules/notification/_collections/utils/ntf-system-event.util.spec.js +32 -3
  143. package/server/build/src/_modules/notification/_collections/utils/ntf-system-event.util.spec.js.map +1 -1
  144. package/server/build/src/_modules/peer-instance/_services/pei-event-relay.control-service.spec.d.ts +15 -0
  145. package/server/build/src/_modules/peer-instance/_services/pei-event-relay.control-service.spec.d.ts.map +1 -0
  146. package/server/build/src/_modules/peer-instance/_services/pei-event-relay.control-service.spec.js +122 -0
  147. package/server/build/src/_modules/peer-instance/_services/pei-event-relay.control-service.spec.js.map +1 -0
  148. package/client-dist/chunk-3AG5X2MY.js +0 -2
  149. package/client-dist/chunk-3AG5X2MY.js.map +0 -7
  150. package/client-dist/chunk-CDNAFC73.js +0 -2
  151. package/client-dist/chunk-CDNAFC73.js.map +0 -7
  152. package/client-dist/err.module-GCKYDYCK.js +0 -6
  153. package/client-dist/err.module-GCKYDYCK.js.map +0 -7
  154. package/client-dist/orc.module-KZELL6XR.js +0 -2
  155. package/client-dist/orc.module-KZELL6XR.js.map +0 -7
  156. package/client-dist/project-source-routed.module-DP3RD454.js +0 -2
  157. package/client-dist/styles-MX7ZZMTH.css +0 -2
  158. /package/client-dist/{agent-instances.module-TPKOBI3N.js.map → agent-instances.module-4ADMPXCV.js.map} +0 -0
  159. /package/client-dist/{ca.module-I5N6QWSU.js.map → ca.module-RVGC3WQC.js.map} +0 -0
  160. /package/client-dist/{cc-usage-dashboard.component-7SPVADUQ.js.map → cc-usage-dashboard.component-OQS2BC4L.js.map} +0 -0
  161. /package/client-dist/{cc.module-7IL3QO5Q.js.map → cc.module-SPB35JNX.js.map} +0 -0
  162. /package/client-dist/{chunk-77YTUUCR.js.map → chunk-2ATSF4KC.js.map} +0 -0
  163. /package/client-dist/{chunk-RYD462IO.js.map → chunk-3HJWN4W6.js.map} +0 -0
  164. /package/client-dist/{chunk-GG2WP2KM.js.map → chunk-4EV32FFZ.js.map} +0 -0
  165. /package/client-dist/{chunk-UD4PV7CD.js.map → chunk-4H3E32UH.js.map} +0 -0
  166. /package/client-dist/{chunk-BH3GMEZZ.js.map → chunk-4LCJ4GNK.js.map} +0 -0
  167. /package/client-dist/{chunk-KX2KGHQZ.js.map → chunk-5NW5UGVZ.js.map} +0 -0
  168. /package/client-dist/{chunk-BJ4I73WC.js.map → chunk-AM5URSKV.js.map} +0 -0
  169. /package/client-dist/{chunk-U3Y5GO6O.js.map → chunk-AMROWQBM.js.map} +0 -0
  170. /package/client-dist/{chunk-LCKABD2M.js.map → chunk-AR6EOT63.js.map} +0 -0
  171. /package/client-dist/{chunk-U64N3LCA.js.map → chunk-B25EGDHU.js.map} +0 -0
  172. /package/client-dist/{chunk-44TWBJUK.js.map → chunk-BQTJHETS.js.map} +0 -0
  173. /package/client-dist/{chunk-657E66YR.js.map → chunk-COOWEMEW.js.map} +0 -0
  174. /package/client-dist/{chunk-E6WOJOGT.js.map → chunk-E3JXFFHE.js.map} +0 -0
  175. /package/client-dist/{chunk-LIGODF4I.js.map → chunk-ESIGVRCK.js.map} +0 -0
  176. /package/client-dist/{chunk-CAMM4S7P.js.map → chunk-EVMDNGBK.js.map} +0 -0
  177. /package/client-dist/{chunk-26YUXPZI.js.map → chunk-F6VMAVI5.js.map} +0 -0
  178. /package/client-dist/{chunk-W7HIS2QA.js.map → chunk-GBOES7QW.js.map} +0 -0
  179. /package/client-dist/{chunk-DXF2FJLD.js.map → chunk-GTERKRTR.js.map} +0 -0
  180. /package/client-dist/{chunk-SK3XGSYF.js.map → chunk-HD4CODAD.js.map} +0 -0
  181. /package/client-dist/{chunk-L2XJGYW4.js.map → chunk-I3FSMGMK.js.map} +0 -0
  182. /package/client-dist/{chunk-5YDHEFSD.js.map → chunk-IFYHOOVA.js.map} +0 -0
  183. /package/client-dist/{chunk-C4FOSX27.js.map → chunk-IUAZJ3PT.js.map} +0 -0
  184. /package/client-dist/{chunk-XFXMWTQS.js.map → chunk-IVLMVAVJ.js.map} +0 -0
  185. /package/client-dist/{chunk-3G2ZGV66.js.map → chunk-KBMXCICX.js.map} +0 -0
  186. /package/client-dist/{chunk-5RLDT3NY.js.map → chunk-KIKSSJKL.js.map} +0 -0
  187. /package/client-dist/{chunk-OLLHHMTV.js.map → chunk-LPNQ5PRN.js.map} +0 -0
  188. /package/client-dist/{chunk-OKUYYDGV.js.map → chunk-MO37SUK2.js.map} +0 -0
  189. /package/client-dist/{chunk-OCNDLQG5.js.map → chunk-MYVEHPA7.js.map} +0 -0
  190. /package/client-dist/{chunk-PW5BAINL.js.map → chunk-N55GOFVU.js.map} +0 -0
  191. /package/client-dist/{chunk-IHNAAEA2.js.map → chunk-NNUHTCXG.js.map} +0 -0
  192. /package/client-dist/{chunk-7VY64KMU.js.map → chunk-OKTAADTQ.js.map} +0 -0
  193. /package/client-dist/{chunk-4EOSKDXN.js.map → chunk-ONS7XQYD.js.map} +0 -0
  194. /package/client-dist/{chunk-4JL2Q6FO.js.map → chunk-OYB7GU43.js.map} +0 -0
  195. /package/client-dist/{chunk-TFB7ULAV.js.map → chunk-PZN2OI7U.js.map} +0 -0
  196. /package/client-dist/{chunk-VRG74DKK.js.map → chunk-QUD3BEHN.js.map} +0 -0
  197. /package/client-dist/{chunk-QQ2GRU2N.js.map → chunk-QUEYZI42.js.map} +0 -0
  198. /package/client-dist/{chunk-XWYXBY7S.js.map → chunk-R2IBKJ4K.js.map} +0 -0
  199. /package/client-dist/{chunk-4FK2D2PX.js.map → chunk-RAHCHCWR.js.map} +0 -0
  200. /package/client-dist/{chunk-J5INQQ5M.js.map → chunk-RCCUSGIN.js.map} +0 -0
  201. /package/client-dist/{chunk-CU5YQ2M4.js.map → chunk-RL5LPTPO.js.map} +0 -0
  202. /package/client-dist/{chunk-7CMPZXAO.js.map → chunk-SDVXPGB7.js.map} +0 -0
  203. /package/client-dist/{chunk-UVVGFHUG.js.map → chunk-TNLHQRL7.js.map} +0 -0
  204. /package/client-dist/{chunk-25KTNALK.js.map → chunk-TWK7BOB7.js.map} +0 -0
  205. /package/client-dist/{chunk-OS5KCUZD.js.map → chunk-U62YECNK.js.map} +0 -0
  206. /package/client-dist/{chunk-VOFDBT5T.js.map → chunk-UOC6UYZT.js.map} +0 -0
  207. /package/client-dist/{chunk-C2BQQRVH.js.map → chunk-VDQROW6J.js.map} +0 -0
  208. /package/client-dist/{chunk-UM7AS2IW.js.map → chunk-VMXIXZV2.js.map} +0 -0
  209. /package/client-dist/{chunk-6BYNIFJY.js.map → chunk-WRI37SX4.js.map} +0 -0
  210. /package/client-dist/{chunk-LMK3IOKN.js.map → chunk-XLSL262Q.js.map} +0 -0
  211. /package/client-dist/{chunk-PMJP2N4K.js.map → chunk-YN4H6MW2.js.map} +0 -0
  212. /package/client-dist/{chunk-EDMLVG72.js.map → chunk-Z5FUR5ZW.js.map} +0 -0
  213. /package/client-dist/{chunk-4PBNHSRW.js.map → chunk-ZCHMBEHT.js.map} +0 -0
  214. /package/client-dist/{chunk-L42Z7YNK.js.map → chunk-ZPJ6KYMA.js.map} +0 -0
  215. /package/client-dist/{consultant.module-HHTHUWRL.js.map → consultant.module-UWXLFLDS.js.map} +0 -0
  216. /package/client-dist/{crd.module-ER6AHSX5.js.map → crd.module-2I2BDC3A.js.map} +0 -0
  217. /package/client-dist/{dashboard.module-TSNGGBCI.js.map → dashboard.module-X2A6LOTA.js.map} +0 -0
  218. /package/client-dist/{do.module-NMZD5VSM.js.map → do.module-CJWEKZ4L.js.map} +0 -0
  219. /package/client-dist/{document-library.module-GHDNXP3T.js.map → document-library.module-WJSFZPA7.js.map} +0 -0
  220. /package/client-dist/{embedding-eval.module-XPXBOIP5.js.map → embedding-eval.module-FOALIAQW.js.map} +0 -0
  221. /package/client-dist/{embedding-registry.module-45TQGZI2.js.map → embedding-registry.module-SS646R4H.js.map} +0 -0
  222. /package/client-dist/{feedback.module-TLKZ4B4N.js.map → feedback.module-T3MZQKXV.js.map} +0 -0
  223. /package/client-dist/{host-runtime-mcp.module-HVJZN5R5.js.map → host-runtime-mcp.module-FBZZGQGD.js.map} +0 -0
  224. /package/client-dist/{live-dev-pipeline.module-5PE4ZFFW.js.map → live-dev-pipeline.module-OKQYFSJL.js.map} +0 -0
  225. /package/client-dist/{logs.module-335EXKCD.js.map → logs.module-SHHOD5XW.js.map} +0 -0
  226. /package/client-dist/{main-FRD6VXVH.js.map → main-L3WW2VTB.js.map} +0 -0
  227. /package/client-dist/{master-control-remote-poc.module-ORHRUCZH.js.map → master-control-remote-poc.module-ITXHYU5K.js.map} +0 -0
  228. /package/client-dist/{mobile-app.module-BYYNVKQR.js.map → mobile-app.module-Q3W3PU4O.js.map} +0 -0
  229. /package/client-dist/{model-registry.module-KIHIJ2Z6.js.map → model-registry.module-DGN55LTQ.js.map} +0 -0
  230. /package/client-dist/{oc.module-DAGIRW3Z.js.map → oc.module-DYSATWML.js.map} +0 -0
  231. /package/client-dist/{project-management.module-IJNPSUQZ.js.map → project-management.module-T7NBKKSR.js.map} +0 -0
  232. /package/client-dist/{project-source-routed.module-DP3RD454.js.map → project-source-routed.module-YO54LEGN.js.map} +0 -0
  233. /package/client-dist/{scheduler.module-S3IKZCLL.js.map → scheduler.module-4CMBOTGZ.js.map} +0 -0
  234. /package/client-dist/{set.module-Y2RHKW7A.js.map → set.module-32SVEWTG.js.map} +0 -0
  235. /package/client-dist/{setup.module-VTI5EZ3Q.js.map → setup.module-5T6MCMR4.js.map} +0 -0
  236. /package/client-dist/{terminals.module-KHEDY6QN.js.map → terminals.module-AQO2TVO2.js.map} +0 -0
  237. /package/client-dist/{voice-notes-poc.module-EMDLJJIT.js.map → voice-notes-poc.module-EI2HY7YJ.js.map} +0 -0
  238. /package/client-dist/{wfs.module-LUTFNQG5.js.map → wfs.module-AHRZE5WB.js.map} +0 -0
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["src/app/_collections/utils/socket-url.util.ts", "src/app/_collections/display/display-string.util.ts", "src/app/_modules/session/_services/data-services/session.data-service.ts", "src/app/_modules/session/_services/api-services/ses-conversation.api-service.ts", "src/app/_modules/session/_services/api-services/session.api-service.ts"],
4
+ "sourcesContent": ["/**\n * Socket URL számítás a GET /server/status válaszból (httpPort, socketPort).\n * Közös logika: main.ts bootstrap és reconnect flow (status refresh).\n */\n\nimport { CCAP_StatusPorts_Interface } from './socket-url.util.interface';\n\n/**\n * Socket URL util – statikus metódusokkal.\n */\nexport class SocketUrl_Util {\n /**\n * Status válaszból kiszámítja a socket URL-t.\n * Mindig same-origin (origin): dev-ben a proxy-local továbbítja 39052-re,\n * server-served HTTP (39050) esetén a socket ugyanazon a HTTP szerveren van,\n * HTTPS UI (39051) esetén a szerver /socket.io-t a belső HTTP port Engine.IO-jára proxyzza (wss).\n */\n static computeSocketUrlFromStatus(\n _data: CCAP_StatusPorts_Interface,\n origin: string,\n ): string {\n return origin;\n }\n}\n", "/**\n * Ismeretlen érték megjelenítési szöveggé alakítása.\n * Object esetén nem \"[object Object]\" hanem .message / .error / .detail vagy fallback.\n */\nexport class DisplayString_Util {\n /**\n * Ismeretlen érték megjelenítési szöveggé alakítása.\n */\n static toDisplayString(value: unknown): string {\n if (value === undefined || value === null) {\n return '';\n }\n if (typeof value === 'string') {\n return value;\n }\n if (typeof value === 'object' && value !== null) {\n const o: Record<string, unknown> = value as Record<string, unknown>;\n if (typeof o.message === 'string' && o.message.trim().length > 0) {\n return o.message.trim();\n }\n if (typeof o.error === 'string' && o.error.trim().length > 0) {\n return o.error.trim();\n }\n if (typeof o.detail === 'string' && o.detail.trim().length > 0) {\n return o.detail.trim();\n }\n }\n const s: string = String(value);\n if (s === '[object Object]') {\n return '—';\n }\n return s;\n }\n}\n", "import { effect, EffectRef, inject, Injectable, OnDestroy, signal } from '@angular/core';\n\nimport { Subject, Subscription } from 'rxjs';\n\nimport { DyFM_Error, DyFM_Log } from '@futdevpro/fsm-dynamo';\n\nimport { AC_RunExecutionMode_Type } from '@server-enums';\nimport { SocketUrl_Util } from '../../../../_collections/utils/socket-url.util';\nimport { DisplayString_Util } from '../../../../_collections/display/display-string.util';\nimport { AC_RunFlowPhase_Type } from '../../../../_enums/run-session/ccap-run-flow-phase.enum';\nimport { CCAP_SocketStatus_Type } from '../../../../_enums/ccap-socket-status.enum';\nimport { AC_LastRunSummary_Response } from '../../../../_models/interfaces/session/ccap-last-run-summary.interface';\nimport {\n CCAP_SessionListItem_Response,\n} from '../../../../_models/interfaces/session/ccap-session-list-item.interface';\nimport {\n AC_LlmDebugTraceEntry_Response,\n AC_SessionInfo_Response,\n UIn_UserInteractionRequest_Interface,\n UIn_UserInteractionResponse_Interface,\n} from '../../../../_models/server-index';\nimport {\n Ses_ArchiveScope_Type,\n Ses_ClientImageAttachment_Response,\n Ses_ClientMessage_Response,\n Ses_MessagesChunk_Response,\n} from '../api-services/conversation.api-service.interface';\nimport { Ses_Conversation_ApiService } from '../api-services/ses-conversation.api-service';\nimport { SSt_Server_ApiService } from '../../../system/_modules/system-status/_services/sst-server.api-service';\nimport { Session_ApiService } from '../api-services/session.api-service';\nimport { CCAP_Socket_ControlService } from '../../../../_services/control-services/ccap-socket.control-service';\nimport { environment } from '../../../../../environments/environment';\n\n/** Szerver event nevek (egyezzen a socket service konstansokkal). */\nconst SOCKET_EVENT_ANSWER: string = 'answer';\nconst SOCKET_EVENT_NOTIFY_USER: string = 'notify-user';\nconst SOCKET_EVENT_AGENT_EVENTS: string = 'agent-events';\nconst SOCKET_EVENT_CONTEXT_UPDATED: string = 'context:updated';\nconst SOCKET_EVENT_MONITORING_EVENT: string = 'monitoring:event';\nconst SOCKET_EVENT_USER_INTERACTION_REQUEST: string = 'user-interaction:request';\nconst SOCKET_EVENT_USER_INTERACTION_RESOLVED: string = 'user-interaction:resolved';\n\n/** NTF notification tool ID — agent-events toolId felismeréshez. */\nconst NTF_TOOL_ID: string = 'ccap_notification';\n/** Agent-events phase: notification elküldve (message típus). */\nconst NTF_PHASE_SENT: string = 'notification-sent';\n/** Agent-events phase: notification válaszra vár (interaktív típus). */\nconst NTF_PHASE_WAITING: string = 'waiting-for-user';\n\n/**\n * Session data service.\n * Session state management; real-time események a Socket Control Service event$ streamből szűrve.\n */\n@Injectable({ providedIn: 'root' })\nexport class Session_DataService implements OnDestroy {\n\n /** Session detail cache (session + lastRun) sessionId szerint. */\n private sessionDetailBySessionId: Map<\n string,\n { session: CCAP_SessionListItem_Response; lastRun: AC_LastRunSummary_Response | null }\n > = new Map();\n\n /** Session info cache sessionId szerint. */\n private sessionInfoBySessionId: Map<string, AC_SessionInfo_Response> = new Map();\n\n /** Aktív session ID (main frame WebSocket indikátor). */\n readonly activeSessionId_$ = signal<string>('');\n\n /**\n * REQ-UI-SES-MOB-AUTOCLOSE-001: bump-counter signal — explicit kérés a session-list\n * sidebar mobil-bezárására. A `ses-list` (`createNewSession` után) bumpolja, a\n * `ses-shell` effect-tel figyeli és isMobile esetén bezárja a sidebar-t. Ez kiegészíti\n * a NavigationEnd-alapú auto-close-t azokra az esetekre, ahol a route-snapshot lag\n * miatt a NavigationEnd-handler nem fut megfelelően (vagy a flow nem navigation-alapú).\n */\n readonly requestSidebarCloseOnMobileBump_$ = signal<number>(0);\n\n /** Session lista. */\n readonly sessions_$ = signal<CCAP_SessionListItem_Response[]>([]);\n\n /** Session lista betöltési hiba (null = nincs hiba); nyers error az app-ccap-error-display-nek. */\n readonly sessionsLoadError_$ = signal<unknown | null>(null);\n\n /** Session lista betöltés folyamatban (true = loading). */\n readonly sessionsLoading_$ = signal<boolean>(false);\n\n /** Archivált session lista. */\n readonly archivedSessions_$ = signal<CCAP_SessionListItem_Response[]>([]);\n\n /** Archivált session lista betöltés folyamatban (true = loading). */\n readonly archivedSessionsLoading_$ = signal<boolean>(false);\n\n /** Üzenetek (real-time chat). */\n readonly messages_$ = signal<Ses_ClientMessage_Response[]>([]);\n\n /** Üzenetek betöltés folyamatban (true = loading). */\n readonly messagesLoading_$ = signal<boolean>(false);\n\n /** Üzenetek betöltési hiba (null = nincs hiba); nyers error az app-ccap-error-display-nek. */\n readonly messagesLoadError_$ = signal<unknown | null>(null);\n\n /**\n * REQ-SES-CONTENT-CHUNK-LOAD-AND-ARCHIVE-001 Slice 5 — aktuális archive-view scope\n * (a chat-komponens „Archív szakasz megnyitása\" gomb-toggle-jétől). Default\n * `'active'` — session-switch is reset-eli erre. A `loadInitialChunk` /\n * `loadOlderChunk` callerek ezt olvassák, hogy a megfelelő scope-ot küldjék\n * az API-nak. `'archive'`-ban a chat csak archív üzeneteket lát.\n */\n readonly currentArchiveScope_$ = signal<Ses_ArchiveScope_Type>('active');\n\n /**\n * REQ-SES-CONTENT-CHUNK-LOAD-AND-ARCHIVE-001 Slice 3+4 — chunk-pagináció state.\n * `total`: aktív (scope-szerinti) message-count; `hasMore`: van-e még régebbi\n * szakasz; `nextBeforeIndex`: a következő prepend kursor (vagy null);\n * `isLoadingOlder`: true a backward-prepend fetch alatt (UI top-spinner);\n * `archivedTotal`: a session-ben lévő archív üzenetek száma (Slice 4 — UI\n * „Archív szakasz megnyitása\" gomb-szám).\n */\n readonly chunkState_$ = signal<{\n total: number;\n hasMore: boolean;\n nextBeforeIndex: number | null;\n isLoadingOlder: boolean;\n archivedTotal: number;\n }>({\n total: 0,\n hasMore: false,\n nextBeforeIndex: null,\n isLoadingOlder: false,\n archivedTotal: 0,\n });\n\n /** Agent event-ek (phase, status a chat status/typing-hoz). */\n readonly agentEvents_$ = signal<Record<string, unknown>>({});\n\n /**\n * Aktuális futás `runExecutionMode`-ja az utolsó analyze-result agent-event után;\n * törlődik run vége / új run init / session váltás után (run summary + chat badge).\n */\n readonly activeRunExecutionMode_$ = signal<string>('');\n\n /** Context frissítés event (real-time context panel). */\n readonly contextUpdated_$ = signal<{\n sessionId: string;\n contextState: Record<string, unknown>;\n } | null>(null);\n\n /** Monitoring event (real-time timeline); signal – backward compat, de nem elsődleges csatorna. */\n readonly monitoringEvent_$ = signal<{\n sessionId: string;\n event: Record<string, unknown>;\n } | null>(null);\n\n /**\n * Monitoring event Subject (megbízható event stream).\n * A signal-alapú monitoringEvent_$ batch-elés miatt köztes event-eket veszíthet;\n * ez a Subject minden event-et garantáltan továbbít a subscriber-eknek.\n */\n readonly monitoringEvent_S: Subject<{\n sessionId: string;\n event: Record<string, unknown>;\n }> = new Subject();\n\n /** Pending user interaction request (agent kérdez, user válaszol a UI card-on). */\n readonly pendingInteraction_$ = signal<UIn_UserInteractionRequest_Interface | null>(null);\n\n /**\n * Pending notification event az agent-events stream-ből (ccap_notification tool hívás közben).\n * A chat UI inline notification kártyát / status szöveget renderel ebből.\n * phase: 'notification-sent' (message típus, rövid flash) vagy 'waiting-for-user' (interaktív, amíg válasz jön).\n */\n readonly pendingNotification_$ = signal<{\n phase: string;\n notificationTitle: string;\n notificationType: string;\n notificationPriority: string;\n } | null>(null);\n\n /** Session detail map (cache). */\n readonly sessionDetailMap_$ = signal<\n Map<string, { session: CCAP_SessionListItem_Response; lastRun: AC_LastRunSummary_Response | null }>\n >(new Map());\n\n /** Session detail betöltés folyamatban. */\n readonly sessionDetailLoading_$ = signal<boolean>(false);\n\n /** Session info map (cache). */\n readonly sessionInfoMap_$ = signal<Map<string, AC_SessionInfo_Response>>(new Map());\n\n /** Session info betöltés folyamatban. */\n readonly sessionInfoLoading_$ = signal<boolean>(false);\n\n /** Session info betöltési hiba (null = nincs hiba). */\n readonly sessionInfoLoadError_$ = signal<unknown | null>(null);\n\n /** Utolsó betöltött LLM debug trace (Info panel). */\n readonly llmDebugTraceEntries_$ = signal<AC_LlmDebugTraceEntry_Response[]>([]);\n\n /** LLM debug trace betöltés folyamatban. */\n readonly llmDebugTraceLoading_$ = signal<boolean>(false);\n\n /** LLM debug trace betöltési hiba. */\n readonly llmDebugTraceLoadError_$ = signal<unknown | null>(null);\n\n /** Socket event$ feliratkozás (ngOnDestroy-ben lemondjuk). */\n private eventSubscription: Subscription | null = null;\n\n /** effect: reconnect után session:attach újraküldése. */\n private connectedEffectRef: EffectRef | null = null;\n\n private readonly session_AS: Session_ApiService = inject(Session_ApiService);\n private readonly conversation_AS: Ses_Conversation_ApiService =\n inject(Ses_Conversation_ApiService);\n private readonly serverStatus_AS: SSt_Server_ApiService =\n inject(SSt_Server_ApiService);\n private readonly socket_CS: CCAP_Socket_ControlService =\n inject(CCAP_Socket_ControlService);\n\n /** Csatlakozás signal (Socket Service-ből delegálva). */\n get connected_$() {\n return this.socket_CS.connected_$;\n }\n\n /** Socket státusz signal (main frame indikátor: connecting | connected | error). */\n get socketStatus_$() {\n return this.socket_CS.status_$;\n }\n\n /** Utolsó socket hiba signal (tooltip copy-hoz); nyers error. */\n get lastSocketError_$() {\n return this.socket_CS.lastError_$;\n }\n\n /** Csatlakozási kísérletek száma (connect_error-kor nő, sikeres connect-nél nullázódik). */\n get connectAttemptCount_$() {\n return this.socket_CS.connectAttemptCount_$;\n }\n\n /** Aktív kapcsolódási diagnosztika futtatása (probe: szerver API + socket.io endpoint). */\n diagnoseConnection(): Promise<Record<string, unknown>> {\n return this.socket_CS.diagnoseConnection();\n }\n\n constructor() {\n this.eventSubscription = this.socket_CS.event$.subscribe(\n (envelope: { event: string; payload: Record<string, unknown> }): void => {\n this.handleSocketEvent(envelope);\n },\n );\n this.connectedEffectRef = effect((): void => {\n if (this.socket_CS.connected_$() && this.getActiveSessionId()) {\n this.socket_CS.emit('session:attach', {\n sessionId: this.getActiveSessionId(),\n });\n }\n });\n }\n\n /**\n * Socket event kezelése: sessionId/channelId alapján szűr, majd a megfelelő subject-ekbe pushol.\n */\n private handleSocketEvent(envelope: { event: string; payload: Record<string, unknown> }): void {\n const payload: Record<string, unknown> = envelope.payload ?? {};\n const activeId: string = this.getActiveSessionId();\n const channelId: string | undefined =\n typeof payload.channelId === 'string' ? payload.channelId : undefined;\n const sessionIdFromPayload: string | undefined =\n typeof payload.sessionId === 'string' ? payload.sessionId : undefined;\n const isForActive: boolean =\n !channelId && !sessionIdFromPayload\n || channelId === activeId\n || sessionIdFromPayload === activeId;\n\n if (envelope.event === SOCKET_EVENT_ANSWER && isForActive) {\n const content: string = typeof payload.content === 'string' ? payload.content : '';\n const timestamp: string =\n typeof payload.timestamp === 'string' ? payload.timestamp : new Date().toISOString();\n const runId: string | undefined =\n typeof payload.runId === 'string' ? payload.runId : undefined;\n const base: Ses_ClientMessage_Response = {\n role: 'assistant',\n content: content,\n timestamp: new Date(timestamp),\n };\n const withRun: Ses_ClientMessage_Response = runId\n ? { ...base, runId: runId }\n : base;\n const stamped: Ses_ClientMessage_Response = this.ensureClientListKey(withRun);\n this.messages_$.set([...this.messages_$(), stamped]);\n return;\n }\n\n if (envelope.event === SOCKET_EVENT_NOTIFY_USER && isForActive) {\n const content: string = typeof payload.content === 'string' ? payload.content : '';\n DyFM_Log.info(\n `CCAP_SessionDS | notify-user received: ${content.substring(0, 120)}…`,\n );\n const stamped: Ses_ClientMessage_Response = this.ensureClientListKey({\n role: 'system',\n content: content,\n timestamp: new Date(),\n });\n this.messages_$.set([...this.messages_$(), stamped]);\n return;\n }\n\n if (envelope.event === SOCKET_EVENT_AGENT_EVENTS) {\n const eventData: Record<string, unknown> =\n (typeof payload.eventData === 'object' && payload.eventData !== null)\n ? (payload.eventData as Record<string, unknown>)\n : {};\n this.agentEvents_$.set(eventData);\n this.applyAgentEventRunExecutionModeLatch(eventData);\n\n // NTF notification tool hívás felismerése az agent-events stream-ből\n const toolId: string = typeof eventData.toolId === 'string' ? eventData.toolId : '';\n const eventPhase: string = typeof eventData.phase === 'string' ? eventData.phase : '';\n\n // REQ-CCI-MSG-UI-FEEDBACK-001 Slice C (cycle 976): a `runInitialization`\n // phase érkezése jelzi, hogy a tulaj-instance agent-run elindult — az\n // utolsó `'sent'` állapotú user-message-t átállítjuk `'processing'`-re,\n // hogy a chat-UI vizualizálja a feldolgozás-fázist (Slice A-tól meglévő\n // `sending`/`sent` indikátor folytatása). Heuristika: latest-pending,\n // mert az AC_UserTurn_Interface NEM tartalmaz userMsgId-t. Cross-instance\n // esetén a PEI_EventRelay automatikusan átküldi ezt az event-et.\n if (eventPhase === 'runInitialization' && isForActive) {\n this.transitionLatestUserMessageToProcessing();\n }\n\n if (toolId === NTF_TOOL_ID\n && (eventPhase === NTF_PHASE_SENT || eventPhase === NTF_PHASE_WAITING)) {\n this.pendingNotification_$.set({\n phase: eventPhase,\n notificationTitle: typeof eventData.notificationTitle === 'string'\n ? eventData.notificationTitle : '',\n notificationType: typeof eventData.notificationType === 'string'\n ? eventData.notificationType : '',\n notificationPriority: typeof eventData.notificationPriority === 'string'\n ? eventData.notificationPriority : 'info',\n });\n } else if (this.pendingNotification_$()) {\n // Bármely más agent-event törli a pending notification-t (a tool befejeződött)\n this.pendingNotification_$.set(null);\n }\n\n const toolErrorContent: unknown = eventData.toolError;\n const chId: string | undefined =\n channelId ?? (eventData.channelId as string | undefined);\n const isForThisSession: boolean = !chId || chId === activeId;\n const toolErrorStr: string = DisplayString_Util.toDisplayString(toolErrorContent).trim();\n if (toolErrorStr.length > 0 && isForThisSession) {\n DyFM_Log.info(\n `CCAP_SessionDS | toolError from agent-events, pushing to chat: ${toolErrorStr.substring(0, 80)}…`,\n );\n const stamped: Ses_ClientMessage_Response = this.ensureClientListKey({\n role: 'system',\n content: toolErrorStr,\n timestamp: new Date(),\n });\n this.messages_$.set([...this.messages_$(), stamped]);\n }\n return;\n }\n\n if (envelope.event === SOCKET_EVENT_CONTEXT_UPDATED) {\n const sid: string =\n typeof payload.sessionId === 'string' ? payload.sessionId : '';\n const contextState: Record<string, unknown> =\n (typeof payload.contextState === 'object' && payload.contextState !== null)\n ? (payload.contextState as Record<string, unknown>)\n : {};\n this.contextUpdated_$.set({\n sessionId: sid,\n contextState: contextState,\n });\n return;\n }\n\n if (envelope.event === SOCKET_EVENT_MONITORING_EVENT) {\n const sid: string =\n typeof payload.sessionId === 'string' ? payload.sessionId : '';\n const ev: Record<string, unknown> =\n (typeof payload.event === 'object' && payload.event !== null)\n ? (payload.event as Record<string, unknown>)\n : {};\n const monitoringPayload: { sessionId: string; event: Record<string, unknown> } = {\n sessionId: sid,\n event: ev,\n };\n this.monitoringEvent_$.set(monitoringPayload);\n this.monitoringEvent_S.next(monitoringPayload);\n return;\n }\n\n if (envelope.event === SOCKET_EVENT_USER_INTERACTION_REQUEST && isForActive) {\n this.pendingInteraction_$.set(payload as unknown as UIn_UserInteractionRequest_Interface);\n return;\n }\n\n // User interaction resolved (bármely csatornáról érkező válasz) → inline card eltüntetése\n if (envelope.event === SOCKET_EVENT_USER_INTERACTION_RESOLVED && isForActive) {\n const resolvedId: string | undefined =\n typeof (payload as Record<string, unknown>).interactionId === 'string'\n ? (payload as Record<string, unknown>).interactionId as string\n : undefined;\n if (!resolvedId) {\n return;\n }\n const current: UIn_UserInteractionRequest_Interface | null = this.pendingInteraction_$();\n if (current?.interactionId === resolvedId) {\n this.pendingInteraction_$.set(null);\n }\n return;\n }\n }\n\n /**\n * Session lista frissítése a server-ről.\n * Hiba esetén sessionsLoadError$ értesül, hogy a UI megkülönböztesse az üres listát a hibától.\n * @returns A betöltött session lista (sikeres betöltésnél), hibánál üres tömb.\n */\n async loadSessions(): Promise<CCAP_SessionListItem_Response[]> {\n this.sessionsLoading_$.set(true);\n try {\n this.sessionsLoadError_$.set(null);\n\n const response = await this.session_AS.listSessions();\n\n this.sessions_$.set(response.sessions);\n return response.sessions;\n } catch (error: unknown) {\n DyFM_Error.logSimple('CCAP_SessionDS | Failed to load sessions', error);\n\n this.sessionsLoadError_$.set(error);\n return [];\n } finally {\n this.sessionsLoading_$.set(false);\n }\n }\n\n /**\n * Új session létrehozása (web UI \"New session\" gomb).\n * Létrehozza a session-t, frissíti a listát, visszaadja az új session-t.\n */\n async createSession(params?: { name?: string }): Promise<CCAP_SessionListItem_Response> {\n const response = await this.session_AS.createSession(params);\n\n await this.loadSessions();\n\n return response.session;\n }\n\n /**\n * Session másolása (conversation fork).\n * Új session-t hoz létre a forrás session összes conversation üzenetével.\n */\n async copySession(params: {\n sessionId: string;\n name?: string;\n }): Promise<CCAP_SessionListItem_Response> {\n const response = await this.session_AS.copySession(params);\n\n await this.loadSessions();\n\n return response.session;\n }\n\n /**\n * REQ-SES-FORK-001 Slice 2: session fork — új session a forrás üzeneteivel a megadott\n * `forkUntilMessageKey`-ig (inclusive). Ismeretlen key esetén a szerver `CCAP-SES-FORK-NF`\n * `DyFM_Error`-t ad vissza; a hívó komponens kezeli (pl. toast + popup bezárás).\n */\n async forkSession(params: {\n sessionId: string;\n forkUntilMessageKey: string;\n name?: string;\n }): Promise<CCAP_SessionListItem_Response> {\n const response = await this.session_AS.copySession({\n sessionId: params.sessionId,\n name: params.name,\n forkUntilMessageKey: params.forkUntilMessageKey,\n });\n\n await this.loadSessions();\n\n return response.session;\n }\n\n /**\n * Archivált session-ek betöltése (\"Archiváltak betöltése\" gomb).\n * Az eredmény az archivedSessions$-on keresztül érhető el.\n */\n async loadArchivedSessions(): Promise<CCAP_SessionListItem_Response[]> {\n this.archivedSessionsLoading_$.set(true);\n try {\n const response = await this.session_AS.listArchivedSessions();\n\n this.archivedSessions_$.set(response.sessions);\n return response.sessions;\n } catch (error: unknown) {\n DyFM_Error.logSimple(\n 'CCAP_SessionDS | Failed to load archived sessions',\n error,\n );\n\n this.archivedSessions_$.set([]);\n return [];\n } finally {\n this.archivedSessionsLoading_$.set(false);\n }\n }\n\n /**\n * Aktív session beállítása; session:attach küldése a Socket Service-en (ha csatlakozva van).\n * Session váltáskor az üzenetek törlődnek.\n * Ugyanarra az id-re második hívás (pl. effect dupla futás dev-ben) nem törli a chatet.\n */\n setActiveSession(sessionId: string): void {\n const previousId: string = this.activeSessionId_$();\n if (previousId !== sessionId) {\n this.activeSessionId_$.set(sessionId);\n this.clearMessages();\n this.pendingInteraction_$.set(null);\n this.activeRunExecutionMode_$.set('');\n }\n this.socket_CS.emit('session:attach', { sessionId: sessionId });\n }\n\n /**\n * Aktív session ID lekérdezése.\n */\n getActiveSessionId(): string {\n return this.activeSessionId_$();\n }\n\n /**\n * WebSocket újracsatlakozás (main frame indikátor kattintás).\n * Először status refresh: ha a socketUrl megváltozott (pl. szerver most lett elérhető), lap újratöltés;\n * különben csak socket reconnect.\n */\n async reconnectSocket(): Promise<void> {\n try {\n const status = await this.serverStatus_AS.getStatus();\n const origin: string =\n typeof window !== 'undefined' ? window.location.origin : '';\n const newSocketUrl: string = SocketUrl_Util.computeSocketUrlFromStatus(\n { httpPort: status.httpPort, socketPort: status.socketPort },\n origin,\n );\n const currentSocketUrl: string = environment.socketUrl ?? origin;\n if (newSocketUrl !== currentSocketUrl && typeof window !== 'undefined') {\n environment.socketUrl = newSocketUrl;\n DyFM_Log.info(\n 'CCAP_SessionDS | socketUrl changed on reconnect, reloading',\n newSocketUrl,\n );\n window.location.reload();\n return;\n }\n } catch {\n // Status fetch fail: csak socket reconnect (ugyanarra a címre).\n }\n this.socket_CS.reconnect();\n }\n\n /**\n * Futó execution leállítása (stop gomb).\n * Jelzi a szervernek, hogy a jelenlegi agentic loop-ot le kell állítani.\n */\n async stopExecution(sessionId: string): Promise<boolean> {\n try {\n const result: { success: boolean } =\n await this.session_AS.stopExecution(sessionId);\n return result.success;\n } catch (err: unknown) {\n DyFM_Error.logSimple('CCAP_Session_DS | stopExecution failed', err);\n return false;\n }\n }\n\n /**\n * Üzenet küldése REST API-n keresztül (POST /session/:id/messages).\n * A valós idejű válaszok (answer, notify-user, agent-events, stb.) továbbra is a WebSocketon érkeznek.\n * Ha a content \"/new\", új session-t hoz létre (REST) és visszaadja; különben az üzenet a REST végpontra megy.\n * Ha nincs sessionId vagy az API hiba, sent: false; a komponens jelezheti és megőrizheti a szöveget (opcionális error szöveg).\n */\n async sendMessageViaSocket(\n content: string,\n imageAttachments?: Ses_ClientImageAttachment_Response[],\n ): Promise<{\n newSession?: CCAP_SessionListItem_Response;\n sent: boolean;\n error?: string;\n }> {\n const trimmed: string = content.trim();\n if (trimmed === '/new') {\n const newSession: CCAP_SessionListItem_Response = await this.createSession();\n return { newSession: newSession, sent: true };\n }\n\n const sessionId: string = this.activeSessionId_$();\n if (!sessionId) {\n return { sent: false };\n }\n\n const hasImages: boolean = (imageAttachments?.length ?? 0) > 0;\n if (!trimmed.length && !hasImages) {\n return { sent: false };\n }\n\n // Optimista megjelenítés: a user üzenete azonnal megjelenik a chatben, mielőtt a REST hívás megtörténne.\n // Így a felhasználó azonnal látja a saját üzenetét, miközben a run elindul.\n // REQ-CCI-MSG-UI-FEEDBACK-001: 'sending' állapot — a bubble mellett spinner\n // jelenik meg a REST roundtrip alatt (cross-instance latency-nél kritikus).\n const optimisticMsg: Ses_ClientMessage_Response = {\n role: 'user',\n content: content,\n timestamp: new Date(),\n processingStatus: 'sending',\n };\n const optimisticStamped: Ses_ClientMessage_Response =\n this.ensureClientListKey(optimisticMsg);\n this.messages_$.set([...this.messages_$(), optimisticStamped]);\n\n try {\n const response = await this.conversation_AS.sendMessage({\n sessionId: sessionId,\n content: content,\n imageAttachments: imageAttachments,\n });\n\n // REST válasz után frissítjük az optimista üzenetet a szerver által adott mezőkkel (messageKey, hasTtsAudio).\n // REQ-CCI-MSG-UI-FEEDBACK-001: 'sent' állapot — REST 200 OK; cross-instance esetén\n // a `response.message` undefined (relayed: true ágon), de az optimistic message\n // így is `sent`-be billen — a target instance fogadta (vagy a relay queue-zta).\n const serverMsg: Ses_ClientMessage_Response | undefined = response.message;\n const updatedMessages: Ses_ClientMessage_Response[] = this.messages_$().map(\n (msg: Ses_ClientMessage_Response): Ses_ClientMessage_Response => {\n if (msg.clientListKey !== optimisticStamped.clientListKey) {\n return msg;\n }\n const merged: Ses_ClientMessage_Response = { ...msg };\n merged.processingStatus = 'sent';\n if (serverMsg?.messageKey) {\n merged.messageKey = serverMsg.messageKey;\n }\n if (serverMsg?.hasTtsAudio !== undefined) {\n merged.hasTtsAudio = serverMsg.hasTtsAudio;\n }\n return merged;\n },\n );\n this.messages_$.set(updatedMessages);\n return { sent: true };\n } catch (error: unknown) {\n DyFM_Error.logSimple(\n 'CCAP_SessionDS | Failed to send message via REST',\n error,\n );\n\n // Hiba esetén eltávolítjuk az optimista üzenetet a chatből\n const rolledBack: Ses_ClientMessage_Response[] = this.messages_$().filter(\n (msg: Ses_ClientMessage_Response): boolean =>\n msg.clientListKey !== optimisticStamped.clientListKey,\n );\n this.messages_$.set(rolledBack);\n\n const errorMessage: string =\n error instanceof Error ? error.message : 'Üzenet küldése sikertelen.';\n return { sent: false, error: errorMessage };\n }\n }\n\n /**\n * Üzenet küldése egy tetszőleges CCAP Session-be REST API-n keresztül (POST /session/:id/messages).\n * Nem frissít lokális chat állapotot — kívülről (pl. Quick Input) hívható.\n */\n async sendMessageToSession(params: { sessionId: string; content: string }): Promise<void> {\n await this.conversation_AS.sendMessage({\n sessionId: params.sessionId,\n content: params.content,\n });\n }\n\n /**\n * User interaction válasz küldése a szerverre Socket.io-n keresztül.\n * Törli a pending interaction signal-t.\n */\n sendInteractionResponse(response: UIn_UserInteractionResponse_Interface): void {\n this.socket_CS.emit('user-interaction:response', response as unknown as Record<string, unknown>);\n this.pendingInteraction_$.set(null);\n }\n\n /**\n * Üzenetek törlése (session váltáskor). A chunk-state-et is reset-eli.\n */\n clearMessages(): void {\n this.messages_$.set([]);\n this.chunkState_$.set({\n total: 0,\n hasMore: false,\n nextBeforeIndex: null,\n isLoadingOlder: false,\n archivedTotal: 0,\n });\n this.currentArchiveScope_$.set('active');\n }\n\n /**\n * Üzenetek beállítása (pl. API-ból betöltött kezdeti üzenetek a chat single source of truth-hoz).\n */\n setMessages(messages: Ses_ClientMessage_Response[]): void {\n const raw: Ses_ClientMessage_Response[] = messages ?? [];\n const stamped: Ses_ClientMessage_Response[] = raw.map(\n (m: Ses_ClientMessage_Response): Ses_ClientMessage_Response =>\n this.ensureClientListKey(m),\n );\n this.messages_$.set(stamped);\n }\n\n /**\n * REQ-CCI-MSG-UI-FEEDBACK-001 Slice C (cycle 976) — a legutóbbi user-message\n * (a chronologically utolsó `role === 'user'` item) `processingStatus` mezőjét\n * `'sent'` → `'processing'`-re állítja, ha még `'sent'` állapotban van.\n *\n * Heuristika: tipikus use-case-ben egyszerre egy pending user-message van;\n * `runInitialization` phase érkezésekor azt mark-eljük processing-ként.\n * Ha más állapotban van (pl. `sending`-ben — REST még nem returned, ami\n * szokatlan), nem írjuk felül.\n */\n private transitionLatestUserMessageToProcessing(): void {\n const current: Ses_ClientMessage_Response[] = this.messages_$();\n let latestUserIdx: number = -1;\n for (let i = current.length - 1; i >= 0; i = i - 1) {\n if (current[i].role === 'user') {\n latestUserIdx = i;\n break;\n }\n }\n if (latestUserIdx < 0) {\n return;\n }\n const target: Ses_ClientMessage_Response = current[latestUserIdx];\n if (target.processingStatus !== 'sent') {\n return;\n }\n const updated: Ses_ClientMessage_Response[] = current.map(\n (msg: Ses_ClientMessage_Response, idx: number): Ses_ClientMessage_Response => {\n if (idx !== latestUserIdx) {\n return msg;\n }\n return { ...msg, processingStatus: 'processing' };\n },\n );\n this.messages_$.set(updated);\n }\n\n /**\n * Stabil lista-track kulcs: meglévő clientListKey, különben messageKey (API), különben UUID.\n */\n private ensureClientListKey(\n msg: Ses_ClientMessage_Response,\n ): Ses_ClientMessage_Response {\n const kept: string | undefined = msg.clientListKey?.trim();\n if (kept?.length) {\n return msg;\n }\n const fromTts: string | undefined = msg.messageKey?.trim();\n if (fromTts?.length) {\n return { ...msg, clientListKey: fromTts };\n }\n return { ...msg, clientListKey: globalThis.crypto.randomUUID() };\n }\n\n /**\n * Egy üzenet TTS cache jelölése: a messageKey-hez tartozó üzenetnél hasTtsAudio = true.\n * A message bubble így audio lejátszót jelenít meg a következő render-nél.\n */\n setMessageTtsCached(messageKey: string): void {\n const current: Ses_ClientMessage_Response[] = this.messages_$();\n const updated: Ses_ClientMessage_Response[] = current.map(\n (msg: Ses_ClientMessage_Response): Ses_ClientMessage_Response =>\n msg.messageKey === messageKey\n ? { ...msg, hasTtsAudio: true }\n : msg,\n );\n this.messages_$.set(updated);\n }\n\n /**\n * Üzenetek betöltése (mindig teljes lista – conversationFull); ha aktív session, setMessages.\n * Chat komponens ezt hívja; navigáció után cache nem kell, mert messages$ az aktív session-é.\n */\n async loadMessagesForView(sessionId: string): Promise<Ses_ClientMessage_Response[]> {\n this.messagesLoading_$.set(true);\n this.messagesLoadError_$.set(null);\n try {\n const response = await this.conversation_AS.getMessages({\n sessionId: sessionId,\n viewMode: 'conversationFull',\n });\n const messages: Ses_ClientMessage_Response[] = response.messages ?? [];\n if (sessionId === this.activeSessionId_$()) {\n this.setMessages(messages);\n }\n return messages;\n } catch (error: unknown) {\n DyFM_Error.logSimple(\n 'CCAP_SessionDS | Failed to load messages for view',\n error,\n );\n this.messagesLoadError_$.set(error);\n return [];\n } finally {\n this.messagesLoading_$.set(false);\n }\n }\n\n /**\n * REQ-SES-CONTENT-CHUNK-LOAD-AND-ARCHIVE-001 Slice 3 — initial-chunk fetch:\n * a session megnyitásakor csak az utolsó N üzenetet hozza (default 50)\n * a tail-en. A chunk-state-et a válasz alapján beállítja.\n *\n * `messages_$`-t replace-eli (nem prepend), hogy a régi session üzenetek\n * ne ragadjanak benne. Ha a session közben nem aktív, a state nem változik.\n */\n async loadInitialChunk(params: {\n sessionId: string;\n viewMode?: string;\n limit?: number;\n archiveScope?: Ses_ArchiveScope_Type;\n }): Promise<Ses_MessagesChunk_Response | null> {\n this.messagesLoading_$.set(true);\n this.messagesLoadError_$.set(null);\n try {\n const response: Ses_MessagesChunk_Response =\n await this.conversation_AS.getMessagesChunked({\n sessionId: params.sessionId,\n viewMode: params.viewMode ?? 'conversationFull',\n latest: true,\n limit: params.limit ?? 50,\n archiveScope: params.archiveScope,\n });\n if (params.sessionId === this.activeSessionId_$()) {\n this.setMessages(response.messages ?? []);\n this.chunkState_$.set({\n total: response.total,\n hasMore: response.hasMore,\n nextBeforeIndex: response.nextBeforeIndex,\n isLoadingOlder: false,\n archivedTotal: response.archivedTotal,\n });\n }\n return response;\n } catch (error: unknown) {\n DyFM_Error.logSimple(\n 'CCAP_SessionDS | Failed to load initial chunk',\n error,\n );\n this.messagesLoadError_$.set(error);\n return null;\n } finally {\n this.messagesLoading_$.set(false);\n }\n }\n\n /**\n * REQ-SES-CONTENT-CHUNK-LOAD-AND-ARCHIVE-001 Slice 3 — backward-prepend:\n * a `chunkState_$().nextBeforeIndex` cursor alapján a régebbi szeletet\n * prepend-eli a `messages_$` elejére. Ha `hasMore=false` vagy már fut egy\n * fetch (`isLoadingOlder`), no-op.\n */\n async loadOlderChunk(params: {\n sessionId: string;\n viewMode?: string;\n limit?: number;\n archiveScope?: Ses_ArchiveScope_Type;\n }): Promise<Ses_MessagesChunk_Response | null> {\n const state = this.chunkState_$();\n if (!state.hasMore || state.nextBeforeIndex == null || state.isLoadingOlder) {\n return null;\n }\n this.chunkState_$.set({ ...state, isLoadingOlder: true });\n try {\n const response: Ses_MessagesChunk_Response =\n await this.conversation_AS.getMessagesChunked({\n sessionId: params.sessionId,\n viewMode: params.viewMode ?? 'conversationFull',\n beforeIndex: state.nextBeforeIndex,\n limit: params.limit ?? 50,\n archiveScope: params.archiveScope,\n });\n if (params.sessionId === this.activeSessionId_$()) {\n const older: Ses_ClientMessage_Response[] = (response.messages ?? []).map(\n (m: Ses_ClientMessage_Response): Ses_ClientMessage_Response =>\n this.ensureClientListKey(m),\n );\n this.messages_$.set([...older, ...this.messages_$()]);\n this.chunkState_$.set({\n total: response.total,\n hasMore: response.hasMore,\n nextBeforeIndex: response.nextBeforeIndex,\n isLoadingOlder: false,\n archivedTotal: response.archivedTotal,\n });\n } else {\n this.chunkState_$.set({ ...state, isLoadingOlder: false });\n }\n return response;\n } catch (error: unknown) {\n DyFM_Error.logSimple(\n 'CCAP_SessionDS | Failed to load older chunk',\n error,\n );\n this.messagesLoadError_$.set(error);\n this.chunkState_$.set({ ...state, isLoadingOlder: false });\n return null;\n }\n }\n\n /**\n * REQ-SES-CONTENT-CHUNK-LOAD-AND-ARCHIVE-001 Slice 5 — archív nézetre váltás.\n * A chat „Archív szakasz megnyitása\" gombja hívja: scope-ot átállítja, törli a\n * jelenlegi (aktív) message-listát, majd `loadInitialChunk`-kal betölti az\n * archív tail-t. Az archivedTotal-t megőrzi a chunk-state-ben (független\n * érték a session-szintű archív szám).\n */\n async switchToArchiveView(sessionId: string): Promise<Ses_MessagesChunk_Response | null> {\n this.currentArchiveScope_$.set('archive');\n const prevArchivedTotal: number = this.chunkState_$().archivedTotal;\n this.messages_$.set([]);\n this.chunkState_$.set({\n total: 0,\n hasMore: false,\n nextBeforeIndex: null,\n isLoadingOlder: false,\n archivedTotal: prevArchivedTotal,\n });\n return this.loadInitialChunk({\n sessionId: sessionId,\n archiveScope: 'archive',\n });\n }\n\n /**\n * REQ-SES-CONTENT-CHUNK-LOAD-AND-ARCHIVE-001 Slice 5 — vissza az aktív nézetre.\n * A chat „Vissza az aktívhoz\" gombja hívja: scope-ot átállítja, törli az\n * archív listát, majd `loadInitialChunk` default scope-pal (active).\n */\n async switchToActiveView(sessionId: string): Promise<Ses_MessagesChunk_Response | null> {\n this.currentArchiveScope_$.set('active');\n this.messages_$.set([]);\n this.chunkState_$.set({\n total: 0,\n hasMore: false,\n nextBeforeIndex: null,\n isLoadingOlder: false,\n archivedTotal: 0,\n });\n return this.loadInitialChunk({\n sessionId: sessionId,\n archiveScope: 'active',\n });\n }\n\n /**\n * Session detail (session + lastRun) betöltése; cache-be mentés.\n */\n async loadSessionDetail(sessionId: string): Promise<{\n session: CCAP_SessionListItem_Response;\n lastRun: AC_LastRunSummary_Response | null;\n } | null> {\n if (!sessionId) {\n return null;\n }\n this.sessionDetailLoading_$.set(true);\n try {\n const response = await this.session_AS.getSession(sessionId);\n const entry: {\n session: CCAP_SessionListItem_Response;\n lastRun: AC_LastRunSummary_Response | null;\n } = {\n session: response.session,\n lastRun: response.lastRun ?? null,\n };\n this.sessionDetailBySessionId.set(sessionId, entry);\n this.sessionDetailMap_$.set(new Map(this.sessionDetailBySessionId));\n return entry;\n } catch (error: unknown) {\n DyFM_Error.logSimple(\n 'CCAP_SessionDS | Failed to load session detail',\n error,\n );\n return null;\n } finally {\n this.sessionDetailLoading_$.set(false);\n }\n }\n\n /**\n * Cachelt session detail lekérdezése (sync).\n */\n getCachedSessionDetail(sessionId: string): {\n session: CCAP_SessionListItem_Response;\n lastRun: AC_LastRunSummary_Response | null;\n } | null {\n return this.sessionDetailBySessionId.get(sessionId) ?? null;\n }\n\n /**\n * Session info betöltése; cache-be mentés.\n */\n async loadSessionInfo(sessionId: string): Promise<AC_SessionInfo_Response | null> {\n if (!sessionId) {\n return null;\n }\n this.sessionInfoLoading_$.set(true);\n this.sessionInfoLoadError_$.set(null);\n try {\n const response: AC_SessionInfo_Response =\n await this.session_AS.getSessionInfo(sessionId);\n this.sessionInfoBySessionId.set(sessionId, response);\n this.sessionInfoMap_$.set(new Map(this.sessionInfoBySessionId));\n return response;\n } catch (error: unknown) {\n DyFM_Error.logSimple(\n 'CCAP_SessionDS | Failed to load session info',\n error,\n );\n this.sessionInfoLoadError_$.set(error);\n return null;\n } finally {\n this.sessionInfoLoading_$.set(false);\n }\n }\n\n /**\n * Cachelt session info lekérdezése (sync).\n */\n getCachedSessionInfo(sessionId: string): AC_SessionInfo_Response | null {\n return this.sessionInfoBySessionId.get(sessionId) ?? null;\n }\n\n /**\n * LLM debug trace bejegyzések lekérése egy run-hoz — nincs globális signal írás (több run trace blokk párhuzamosan).\n */\n async fetchLlmDebugTraceEntriesForRun(params: {\n sessionId: string;\n runId: string;\n }): Promise<AC_LlmDebugTraceEntry_Response[]> {\n const sid: string = params.sessionId?.trim() ?? '';\n const rid: string = params.runId?.trim() ?? '';\n if (!sid || !rid) {\n return [];\n }\n try {\n const response: { entries: AC_LlmDebugTraceEntry_Response[] } =\n await this.session_AS.getLlmDebugTrace({\n sessionId: sid,\n runId: rid,\n });\n return response.entries ?? [];\n } catch {\n return [];\n }\n }\n\n /**\n * LLM debug trace lista betöltése session + run alapján (MongoDB trace tábla).\n */\n async loadLlmDebugTrace(params: {\n sessionId: string;\n runId: string;\n }): Promise<void> {\n const sid: string = params.sessionId?.trim() ?? '';\n const rid: string = params.runId?.trim() ?? '';\n\n if (!sid || !rid) {\n this.llmDebugTraceEntries_$.set([]);\n return;\n }\n\n this.llmDebugTraceLoading_$.set(true);\n this.llmDebugTraceLoadError_$.set(null);\n\n try {\n const response: { entries: AC_LlmDebugTraceEntry_Response[] } =\n await this.session_AS.getLlmDebugTrace({\n sessionId: sid,\n runId: rid,\n });\n this.llmDebugTraceEntries_$.set(response.entries);\n } catch (error: unknown) {\n DyFM_Error.logSimple(\n 'CCAP_SessionDS | Failed to load LLM debug trace',\n error,\n );\n this.llmDebugTraceLoadError_$.set(error);\n this.llmDebugTraceEntries_$.set([]);\n } finally {\n this.llmDebugTraceLoading_$.set(false);\n }\n }\n\n /**\n * Session frissítése (pl. archive / de-archive); API hívás után lista frissítése.\n * Archive állapotváltáskor mindkét lista reload (aktív + archivált szekció szinkron).\n */\n async updateSession(params: {\n sessionId: string;\n updates: Record<string, unknown>;\n }): Promise<CCAP_SessionListItem_Response | null> {\n try {\n const response = await this.session_AS.updateSession(params);\n const archived: unknown = params.updates.archived;\n if (archived === true || archived === false) {\n await this.loadSessions();\n await this.loadArchivedSessions();\n } else {\n await this.loadSessions();\n }\n return response.session;\n } catch (error: unknown) {\n DyFM_Error.logSimple(\n 'CCAP_SessionDS | Failed to update session',\n error,\n );\n return null;\n }\n }\n\n /**\n * Agent-events alapján `activeRunExecutionMode_$` latch frissítése.\n */\n private applyAgentEventRunExecutionModeLatch(eventData: Record<string, unknown>): void {\n const phaseRaw: unknown = eventData.phase;\n const phaseStr: string = typeof phaseRaw === 'string' ? phaseRaw.trim() : '';\n if (phaseStr === AC_RunFlowPhase_Type.analyzeResult) {\n const modeRaw: unknown = eventData.runExecutionMode;\n if (typeof modeRaw === 'string' && modeRaw.trim() !== '') {\n const normalized: string | undefined =\n Session_DataService.normalizeRunExecutionModeSocketValue(modeRaw);\n if (normalized !== undefined) {\n this.activeRunExecutionMode_$.set(normalized);\n }\n }\n return;\n }\n if (\n phaseStr === AC_RunFlowPhase_Type.runFlowComplete\n || phaseStr === AC_RunFlowPhase_Type.runInitialization\n ) {\n this.activeRunExecutionMode_$.set('');\n }\n }\n\n /**\n * Socket `runExecutionMode` érték whitelist; ismeretlen string → undefined.\n */\n private static normalizeRunExecutionModeSocketValue(raw: string): string | undefined {\n const trimmed: string = raw.trim();\n const known: AC_RunExecutionMode_Type[] = [\n AC_RunExecutionMode_Type.instant,\n AC_RunExecutionMode_Type.agenticAny,\n AC_RunExecutionMode_Type.ask,\n AC_RunExecutionMode_Type.plan,\n ];\n for (const v of known) {\n if (trimmed === v) {\n return v;\n }\n }\n return undefined;\n }\n\n ngOnDestroy(): void {\n this.monitoringEvent_S.complete();\n if (this.eventSubscription) {\n this.eventSubscription.unsubscribe();\n this.eventSubscription = null;\n }\n if (this.connectedEffectRef) {\n this.connectedEffectRef.destroy();\n this.connectedEffectRef = null;\n }\n }\n}\n", "import { inject, Injectable } from '@angular/core';\nimport { HttpClient } from '@angular/common/http';\n\nimport { firstValueFrom } from 'rxjs';\n\nimport { environment } from '../../../../../environments/environment';\nimport {\n Ses_ArchiveScope_Type,\n Ses_ClientImageAttachment_Response,\n Ses_ClientMessage_Response,\n Ses_MessagesChunk_Response,\n} from './conversation.api-service.interface';\n\n/**\n * Conversation API service.\n * HTTP hívások a server conversation endpoint-jaira.\n */\n@Injectable({ providedIn: 'root' })\nexport class Ses_Conversation_ApiService {\n\n /** API base URL. */\n private baseUrl: string = `${environment.api.baseUrl}/session`;\n\n private readonly http: HttpClient = inject(HttpClient);\n\n /**\n * Üzenetek lekérdezése viewMode alapján.\n */\n getMessages(params: {\n sessionId: string;\n viewMode: string;\n }): Promise<{\n messages: Ses_ClientMessage_Response[];\n }> {\n return firstValueFrom(\n this.http.get<{\n messages: Ses_ClientMessage_Response[];\n }>(\n `${this.baseUrl}/${params.sessionId}/messages`,\n { params: { viewMode: params.viewMode } },\n ),\n );\n }\n\n /**\n * REQ-SES-CONTENT-CHUNK-LOAD-AND-ARCHIVE-001 Slice 3 — chunk-fetch a CCAP\n * Session-en. `latest=true` boot-strap-re az utolsó N üzenetet kéri,\n * `beforeIndex` paraméterrel a régebbi szeletet (backward prepend).\n */\n getMessagesChunked(params: {\n sessionId: string;\n viewMode: string;\n beforeIndex?: number;\n limit?: number;\n latest?: boolean;\n archiveScope?: Ses_ArchiveScope_Type;\n }): Promise<Ses_MessagesChunk_Response> {\n const httpParams: Record<string, string> = {\n viewMode: params.viewMode,\n };\n if (params.beforeIndex != null) {\n httpParams['beforeIndex'] = String(params.beforeIndex);\n }\n if (params.limit != null) {\n httpParams['limit'] = String(params.limit);\n }\n if (params.latest) {\n httpParams['latest'] = '1';\n }\n if (params.archiveScope) {\n httpParams['archiveScope'] = params.archiveScope;\n }\n return firstValueFrom(\n this.http.get<Ses_MessagesChunk_Response>(\n `${this.baseUrl}/${params.sessionId}/messages/chunk`,\n { params: httpParams },\n ),\n );\n }\n\n /**\n * Új üzenet küldése. Cross-instance esetben (REQ-CCAP-CROSS-001) a server\n * `{ relayed: true, taskId, targetOnline }` body-t ad vissza — ekkor `message`\n * undefined; lokális esetben a persistált user message-szel tér vissza.\n */\n sendMessage(params: {\n sessionId: string;\n content: string;\n imageAttachments?: Ses_ClientImageAttachment_Response[];\n }): Promise<{\n message?: Ses_ClientMessage_Response;\n relayed?: boolean;\n taskId?: string;\n targetOnline?: boolean;\n }> {\n return firstValueFrom(\n this.http.post<{\n message?: Ses_ClientMessage_Response;\n relayed?: boolean;\n taskId?: string;\n targetOnline?: boolean;\n }>(\n `${this.baseUrl}/${params.sessionId}/messages`,\n {\n content: params.content,\n imageAttachments: params.imageAttachments,\n },\n ),\n );\n }\n}\n", "import { inject, Injectable } from '@angular/core';\nimport { HttpClient, HttpParams } from '@angular/common/http';\n\nimport { firstValueFrom } from 'rxjs';\n\nimport { environment } from '../../../../../environments/environment';\nimport { AC_LastRunSummary_Response } from '../../../../_models/interfaces/session/ccap-last-run-summary.interface';\nimport {\n AC_LlmDebugTraceEntry_Response,\n AC_SessionInfo_Response,\n} from '../../../../_models/server-index';\nimport {\n CCAP_SessionListItem_Response,\n} from '../../../../_models/interfaces/session/ccap-session-list-item.interface';\nimport { ExS_InstanceContext_DataService } from '../../../external-sessions/_services/exs-instance-context.data-service';\n\n/**\n * Session API service.\n * HTTP hívások a server session endpoint-jaira.\n * Minden hívás `?ccapId=<active>` paramot küld (REQ-PEI-016) —\n * a ccapId forrása az instance-szelektor (`ExS_InstanceContext_DataService.activeCcapId_$`).\n */\n@Injectable({ providedIn: 'root' })\nexport class Session_ApiService {\n\n /** API base URL. */\n private baseUrl: string = `${environment.api.baseUrl}/session`;\n\n private readonly http: HttpClient = inject(HttpClient);\n\n private readonly peiContext_DS: ExS_InstanceContext_DataService =\n inject(ExS_InstanceContext_DataService);\n\n /**\n * Aktuális ccapId — az instance-szelektor értékéből (REQ-PEI-016).\n */\n private currentCcapId(): string {\n return this.peiContext_DS.activeCcapId_$();\n }\n\n /**\n * ccapId hozzáfűzése HttpParams-hoz.\n */\n private withCcapId(params: HttpParams): HttpParams {\n const ccapId: string = this.currentCcapId();\n if (!ccapId) {\n return params;\n }\n return params.set('ccapId', ccapId);\n }\n\n /**\n * Session lista lekérdezése (csak nem archivált session-ök).\n */\n listSessions(): Promise<{\n sessions: CCAP_SessionListItem_Response[];\n }> {\n const httpParams: HttpParams = this.withCcapId(new HttpParams());\n return firstValueFrom(\n this.http.get<{\n sessions: CCAP_SessionListItem_Response[];\n }>(this.baseUrl, { params: httpParams }),\n );\n }\n\n /**\n * Archivált session-ek lekérdezése.\n */\n listArchivedSessions(): Promise<{\n sessions: CCAP_SessionListItem_Response[];\n }> {\n let httpParams: HttpParams = this.withCcapId(new HttpParams());\n httpParams = httpParams.set('archived', 'true');\n return firstValueFrom(\n this.http.get<{\n sessions: CCAP_SessionListItem_Response[];\n }>(this.baseUrl, { params: httpParams }),\n );\n }\n\n /**\n * Új session létrehozása (web UI \"New session\" gomb).\n * Opcionális `name`: kezdő lista-név (pl. Quick Input Send to session → új CCAP Session).\n */\n createSession(params?: { name?: string }): Promise<{\n session: CCAP_SessionListItem_Response;\n }> {\n const body: { name?: string } = {};\n const trimmedName: string | undefined =\n params?.name !== undefined ? params.name.trim() : undefined;\n if (trimmedName !== undefined && trimmedName.length > 0) {\n body.name = trimmedName;\n }\n const httpParams: HttpParams = this.withCcapId(new HttpParams());\n return firstValueFrom(\n this.http.post<{\n session: CCAP_SessionListItem_Response;\n }>(this.baseUrl, body, { params: httpParams }),\n );\n }\n\n /**\n * Session detail lekérdezése (session + opcionális lastRun intent/goal/summary).\n */\n getSession(sessionId: string): Promise<{\n session: CCAP_SessionListItem_Response;\n lastRun?: AC_LastRunSummary_Response;\n }> {\n const httpParams: HttpParams = this.withCcapId(new HttpParams());\n return firstValueFrom(\n this.http.get<{\n session: CCAP_SessionListItem_Response;\n lastRun?: AC_LastRunSummary_Response;\n }>(`${this.baseUrl}/${sessionId}`, { params: httpParams }),\n );\n }\n\n /**\n * Session frissítése (név, státusz).\n */\n updateSession(params: {\n sessionId: string;\n updates: Record<string, unknown>;\n }): Promise<{\n session: CCAP_SessionListItem_Response;\n }> {\n const httpParams: HttpParams = this.withCcapId(new HttpParams());\n return firstValueFrom(\n this.http.patch<{\n session: CCAP_SessionListItem_Response;\n }>(\n `${this.baseUrl}/${params.sessionId}`,\n params.updates,\n { params: httpParams },\n ),\n );\n }\n\n /**\n * Session info lekérdezése (used inputs, used elements, full active context).\n */\n getSessionInfo(sessionId: string): Promise<AC_SessionInfo_Response> {\n const httpParams: HttpParams = this.withCcapId(new HttpParams());\n return firstValueFrom(\n this.http.get<AC_SessionInfo_Response>(\n `${this.baseUrl}/${sessionId}/session-info`,\n { params: httpParams },\n ),\n );\n }\n\n /**\n * Session másolása — teljes history vagy fork a megadott `forkUntilMessageKey`-ig (REQ-SES-FORK-001).\n * `forkUntilMessageKey` hiányában a szerver változatlan copy-t csinál (az összes üzenettel).\n */\n copySession(params: {\n sessionId: string;\n name?: string;\n forkUntilMessageKey?: string;\n }): Promise<{ session: CCAP_SessionListItem_Response }> {\n const body: Record<string, unknown> = {};\n if (params.name) {\n body.name = params.name;\n }\n if (params.forkUntilMessageKey) {\n body.forkUntilMessageKey = params.forkUntilMessageKey;\n }\n const httpParams: HttpParams = this.withCcapId(new HttpParams());\n return firstValueFrom(\n this.http.post<{ session: CCAP_SessionListItem_Response }>(\n `${this.baseUrl}/${params.sessionId}/copy`,\n body,\n { params: httpParams },\n ),\n );\n }\n\n /**\n * Futó execution leállítása (stop gomb).\n */\n stopExecution(sessionId: string): Promise<{ success: boolean }> {\n const httpParams: HttpParams = this.withCcapId(new HttpParams());\n return firstValueFrom(\n this.http.post<{ success: boolean }>(\n `${this.baseUrl}/${sessionId}/stop-execution`,\n {},\n { params: httpParams },\n ),\n );\n }\n\n /**\n * LLM debug trace bejegyzések egy session + run kombinációhoz (Info panel).\n */\n getLlmDebugTrace(params: {\n sessionId: string;\n runId: string;\n }): Promise<{ entries: AC_LlmDebugTraceEntry_Response[] }> {\n let httpParams: HttpParams = this.withCcapId(new HttpParams());\n httpParams = httpParams.set('runId', params.runId);\n return firstValueFrom(\n this.http.get<{ entries: AC_LlmDebugTraceEntry_Response[] }>(\n `${this.baseUrl}/${params.sessionId}/llm-debug-trace`,\n { params: httpParams },\n ),\n );\n }\n}\n"],
5
+ "mappings": "+UAUM,IAAOA,EAAP,KAAqB,CAOzB,OAAOC,2BACLC,EACAC,EAAc,CAEd,OAAOA,CACT,GClBI,IAAOC,EAAP,KAAyB,CAI7B,OAAOC,gBAAgBC,EAAc,CACnC,GAA2BA,GAAU,KACnC,MAAO,GAET,GAAI,OAAOA,GAAU,SACnB,OAAOA,EAET,GAAI,OAAOA,GAAU,UAAYA,IAAU,KAAM,CAC/C,IAAMC,EAA6BD,EACnC,GAAI,OAAOC,EAAEC,SAAY,UAAYD,EAAEC,QAAQC,KAAI,EAAGC,OAAS,EAC7D,OAAOH,EAAEC,QAAQC,KAAI,EAEvB,GAAI,OAAOF,EAAEI,OAAU,UAAYJ,EAAEI,MA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U,CAEhD,CACA,MACF,EAEEL,IAAaC,EAAqBM,iBAC/BP,IAAaC,EAAqBO,oBAErC,KAAK9M,yBAAyB6D,IAAI,EAAE,CAExC,CAKQ,OAAO+I,qCAAqCG,EAAW,CAC7D,IAAM7E,EAAkB6E,EAAI9H,KAAI,EAC1B+H,EAAoC,CACxCC,EAAyBC,QACzBD,EAAyBE,WACzBF,EAAyBG,IACzBH,EAAyBI,IAAI,EAE/B,QAAWC,KAAKN,EACd,GAAI9E,IAAYoF,EACd,OAAOA,CAIb,CAEAC,aAAW,CACT,KAAKpN,kBAAkBqN,SAAQ,EAC3B,KAAKzM,oBACP,KAAKA,kBAAkB0M,YAAW,EAClC,KAAK1M,kBAAoB,MAEvB,KAAKC,qBACP,KAAKA,mBAAmB0M,QAAO,EAC/B,KAAK1M,mBAAqB,KAE9B,4CA3mCWvC,EAAmB,6BAAnBA,EAAmBkP,QAAnBlP,EAAmBmP,UAAAC,WADN,MAAM,CAAA,SACnBpP,CAAmB,GAAA",
6
+ "names": ["SocketUrl_Util", "computeSocketUrlFromStatus", "_data", "origin", "DisplayString_Util", "toDisplayString", "value", "o", "message", "trim", "length", "error", "detail", "s", "String", "import_fsm_dynamo", "Ses_Conversation_ApiService", "baseUrl", "environment", "api", "http", "inject", "HttpClient", "getMessages", "params", "firstValueFrom", "get", "sessionId", "viewMode", "getMessagesChunked", "httpParams", "beforeIndex", "String", "limit", "latest", "archiveScope", "sendMessage", "post", "content", "imageAttachments", "factory", "\u0275fac", "providedIn", "Session_ApiService", "baseUrl", "environment", "api", "http", "inject", "HttpClient", "peiContext_DS", "ExS_InstanceContext_DataService", "currentCcapId", "activeCcapId_$", "withCcapId", "params", "ccapId", "set", "listSessions", "httpParams", "HttpParams", "firstValueFrom", "get", "listArchivedSessions", "createSession", "body", "trimmedName", "name", "undefined", "trim", "length", "post", "getSession", "sessionId", "updateSession", "patch", "updates", "getSessionInfo", "copySession", "forkUntilMessageKey", "stopExecution", "getLlmDebugTrace", "runId", "factory", "\u0275fac", "providedIn", "SOCKET_EVENT_ANSWER", "SOCKET_EVENT_NOTIFY_USER", "SOCKET_EVENT_AGENT_EVENTS", "SOCKET_EVENT_CONTEXT_UPDATED", "SOCKET_EVENT_MONITORING_EVENT", "SOCKET_EVENT_USER_INTERACTION_REQUEST", "SOCKET_EVENT_USER_INTERACTION_RESOLVED", "NTF_TOOL_ID", "NTF_PHASE_SENT", "NTF_PHASE_WAITING", "Session_DataService", "sessionDetailBySessionId", "Map", "sessionInfoBySessionId", "activeSessionId_$", "signal", "requestSidebarCloseOnMobileBump_$", "sessions_$", "sessionsLoadError_$", "sessionsLoading_$", "archivedSessions_$", "archivedSessionsLoading_$", "messages_$", "messagesLoading_$", "messagesLoadError_$", "currentArchiveScope_$", "chunkState_$", "total", "hasMore", "nextBeforeIndex", "isLoadingOlder", "archivedTotal", "agentEvents_$", "activeRunExecutionMode_$", "contextUpdated_$", "monitoringEvent_$", "monitoringEvent_S", "Subject", "pendingInteraction_$", "pendingNotification_$", "sessionDetailMap_$", "sessionDetailLoading_$", "sessionInfoMap_$", "sessionInfoLoading_$", "sessionInfoLoadError_$", "llmDebugTraceEntries_$", "llmDebugTraceLoading_$", "llmDebugTraceLoadError_$", "eventSubscription", "connectedEffectRef", "session_AS", "inject", "Session_ApiService", "conversation_AS", "Ses_Conversation_ApiService", "serverStatus_AS", "SSt_Server_ApiService", "socket_CS", "CCAP_Socket_ControlService", "connected_$", "socketStatus_$", "status_$", "lastSocketError_$", "lastError_$", "connectAttemptCount_$", "diagnoseConnection", "constructor", "event$", "subscribe", "envelope", "handleSocketEvent", "effect", "getActiveSessionId", "emit", "sessionId", "payload", "activeId", "channelId", "undefined", "sessionIdFromPayload", "isForActive", "event", "content", "timestamp", "Date", "toISOString", "runId", "base", "role", "withRun", "__spreadProps", "__spreadValues", "stamped", "ensureClientListKey", "set", "DyFM_Log", "info", "substring", "eventData", "applyAgentEventRunExecutionModeLatch", "toolId", "eventPhase", "phase", "transitionLatestUserMessageToProcessing", "notificationTitle", "notificationType", "notificationPriority", "toolErrorContent", "toolError", "chId", "isForThisSession", "toolErrorStr", "DisplayString_Util", "toDisplayString", "trim", "length", "sid", "contextState", "ev", "monitoringPayload", "next", "resolvedId", "interactionId", "loadSessions", "__async", "response", "listSessions", "sessions", "error", "DyFM_Error", "logSimple", "createSession", "params", "session", "copySession", "forkSession", "name", "forkUntilMessageKey", "loadArchivedSessions", "listArchivedSessions", "setActiveSession", "clearMessages", "reconnectSocket", "status", "getStatus", "origin", "window", "location", "newSocketUrl", "SocketUrl_Util", "computeSocketUrlFromStatus", "httpPort", "socketPort", "currentSocketUrl", "environment", "socketUrl", "reload", "reconnect", "stopExecution", "success", "err", "sendMessageViaSocket", "imageAttachments", "trimmed", "newSession", "sent", "hasImages", "optimisticMsg", "processingStatus", "optimisticStamped", "serverMsg", "sendMessage", "message", "updatedMessages", "map", "msg", "clientListKey", "merged", "messageKey", "hasTtsAudio", "rolledBack", "filter", "Error", "sendMessageToSession", "sendInteractionResponse", "setMessages", "messages", "m", "current", "latestUserIdx", "i", "updated", "idx", "fromTts", "globalThis", "crypto", "randomUUID", "setMessageTtsCached", "loadMessagesForView", "getMessages", "viewMode", "loadInitialChunk", "getMessagesChunked", "latest", "limit", "archiveScope", "loadOlderChunk", "state", "beforeIndex", "older", "switchToArchiveView", "prevArchivedTotal", "switchToActiveView", "loadSessionDetail", "getSession", "entry", "lastRun", "getCachedSessionDetail", "get", "loadSessionInfo", "getSessionInfo", "getCachedSessionInfo", "fetchLlmDebugTraceEntriesForRun", "rid", "getLlmDebugTrace", "entries", "loadLlmDebugTrace", "updateSession", "archived", "updates", "phaseRaw", "phaseStr", "AC_RunFlowPhase_Type", "analyzeResult", "modeRaw", "runExecutionMode", "normalized", "normalizeRunExecutionModeSocketValue", "runFlowComplete", "runInitialization", "raw", "known", "AC_RunExecutionMode_Type", "instant", "agenticAny", "ask", "plan", "v", "ngOnDestroy", "complete", "unsubscribe", "destroy", "factory", "\u0275fac", "providedIn"]
7
+ }
@@ -1,2 +1,2 @@
1
- import{j as s}from"./chunk-BH3GMEZZ.js";var r="ccap-personaSoulDraft";function p(){try{let o=localStorage.getItem(r);if(!o)return null;let n=s.tryParseStrict({text:o,contextLabel:"CCAP_PersonaDraft_localStorage"});if(!n.ok)return null;let e=n.value;if(typeof e!="object"||e===null)return null;let t=Object.fromEntries(Object.entries(e)),a=typeof t.name=="string"?t.name:"",c=typeof t.personality=="string"?t.personality:"",i=typeof t.conversation_style=="string"?t.conversation_style:"",l=typeof t.work_style=="string"?t.work_style:"",f=typeof t.mission=="string"?t.mission:"",y=typeof t.avoid=="string"?t.avoid:"";return{name:a,personality:c,conversation_style:i,work_style:l,mission:f,avoid:y}}catch{return null}}function g(o){try{localStorage.setItem(r,JSON.stringify(o))}catch{}}function u(){try{localStorage.removeItem(r)}catch{}}var m={get:p,save:g,clear:u};export{m as a};
2
- //# sourceMappingURL=chunk-6BYNIFJY.js.map
1
+ import{j as s}from"./chunk-4LCJ4GNK.js";var r="ccap-personaSoulDraft";function p(){try{let o=localStorage.getItem(r);if(!o)return null;let n=s.tryParseStrict({text:o,contextLabel:"CCAP_PersonaDraft_localStorage"});if(!n.ok)return null;let e=n.value;if(typeof e!="object"||e===null)return null;let t=Object.fromEntries(Object.entries(e)),a=typeof t.name=="string"?t.name:"",c=typeof t.personality=="string"?t.personality:"",i=typeof t.conversation_style=="string"?t.conversation_style:"",l=typeof t.work_style=="string"?t.work_style:"",f=typeof t.mission=="string"?t.mission:"",y=typeof t.avoid=="string"?t.avoid:"";return{name:a,personality:c,conversation_style:i,work_style:l,mission:f,avoid:y}}catch{return null}}function g(o){try{localStorage.setItem(r,JSON.stringify(o))}catch{}}function u(){try{localStorage.removeItem(r)}catch{}}var m={get:p,save:g,clear:u};export{m as a};
2
+ //# sourceMappingURL=chunk-WRI37SX4.js.map
@@ -1,3 +1,3 @@
1
- import{c as Ce}from"./chunk-3AG5X2MY.js";import{b as Ye}from"./chunk-COVCHZOZ.js";import{a as v}from"./chunk-UFBTR2BG.js";import{h as Be,i as Fe}from"./chunk-CAMM4S7P.js";import{I as Ve}from"./chunk-RUSAMFGS.js";import{Aa as Oe,Ba as Re,C as Z,D as ae,Fa as m,Ga as L,Ha as _e,Ia as ze,J as R,K as z,L as H,M as ye,P as Pe,T as ne,Ta as le,U as F,Z as u,a as I,aa as V,b as w,da as D,fa as Y,ga as me,hb as g,ja as se,jb as Se,k as ke,la as S,oa as Le,p as be,pa as we,qa as p,ra as d,sa as W,ua as ie,ub as de,va as B,wa as C,xb as He,y as xe,za as Ge}from"./chunk-TBMJSIBB.js";var ve=class i{static getEmoji(o){let e=o.data??{},t=typeof e.step=="string"?e.step:"";return t==="run-initialization"?"\u{1F680}":t==="run-flow-complete"?"\u{1F3AF}":t==="tool-error-retry"?"\u26A0\uFE0F\u{1F9E0}":t.includes("tool-error")||t.includes("error-recovery")?"\u{1F527}\u274C":t.includes("agentic-loop-iteration")?"":o.eventType==="tool-call"||typeof e.toolId=="string"?"\u{1F527}":o.eventType==="llm-call"||typeof e.callType=="string"?"\u{1F9E0}":o.eventType==="error"?"\u26A0\uFE0F":""}static getBubbleClasses(o){let e=o.data??{},t=typeof e.step=="string"?e.step:"";return t==="run-initialization"||t==="run-flow-complete"?"bg-green-500/10 text-green-300 border border-green-500/50":t==="tool-error-retry"||t.includes("tool-error")||t.includes("error-recovery")?"bg-orange-500/10 text-orange-300 border border-orange-500/50":o.eventType==="error"||t.includes("circuit-breaker")?"bg-red-500/10 text-red-300 border border-red-500/50":t.includes("agentic-loop")?"bg-blue-500/10 text-blue-300 border border-blue-500/50":o.eventType==="tool-call"||typeof e.toolId=="string"?"bg-yellow-500/10 text-yellow-300 border border-yellow-500/50":o.eventType==="llm-call"||typeof e.callType=="string"?"bg-purple-500/10 text-purple-300 border border-purple-500/50":"bg-neutral-700 text-neutral-200 border border-neonCyan"}static getStepLabel(o){let e=o.data??{},t=e.step,n=e.toolId;if(typeof t=="string"&&t.length>0)return i.formatStepId(t);if(o.eventType==="tool-call"&&typeof n=="string"&&n.length>0)return`Eszk\xF6z: ${n}`;if(o.eventType==="llm-call"){let r=e.callType;return typeof r=="string"?`LLM: ${i.formatStepId(r)}`:"LLM h\xEDv\xE1s"}if(o.eventType==="error"){let r=e.message;return typeof r=="string"&&r.length>0?`Hiba: ${r.substring(0,40)}${r.length>40?"\u2026":""}`:"Hiba"}return o.eventType==="compacting"?typeof t=="string"&&t.length>0?i.formatStepId(t):"Compacting":i.formatEventTypeFallback(o.eventType)}static formatStepId(o){return o.split("-").map(e=>e.length>0?e.charAt(0).toUpperCase()+e.slice(1).toLowerCase():e).join(" ")}static getDotClasses(o){let e=o.data??{},t=typeof e.step=="string"?e.step:"";return t==="run-initialization"||t==="run-flow-complete"?"bg-green-400":t==="tool-error-retry"||t.includes("tool-error")||t.includes("error-recovery")?"bg-orange-400":o.eventType==="error"||t.includes("circuit-breaker")?"bg-red-400":t.includes("agentic-loop")?"bg-blue-400":o.eventType==="tool-call"||typeof e.toolId=="string"?"bg-yellow-400":o.eventType==="llm-call"||typeof e.callType=="string"?"bg-purple-400":"bg-neutral-400"}static formatEventTypeFallback(o){return{step:"L\xE9p\xE9s","tool-call":"Eszk\xF6zh\xEDv\xE1s","context-update":"Kontextus friss\xEDt\xE9s",compacting:"Compacting","llm-call":"LLM h\xEDv\xE1s","session-event":"Session event",error:"Hiba"}[o]??o}};var x=function(i){return i.pending="pending",i.active="active",i.completed="completed",i.error="error",i}(x||{});var tt={[v.runInitialization]:"milestone-init",[v.analyze]:"phase-analyze",[v.analyzeResult]:"llm-analyze",[v.assemble]:"phase-assemble",[v.execution]:"phase-execution",[v.executionStart]:"phase-execution",[v.finalization]:"phase-finalization",[v.llmRunFinalization]:"llm-finalization",[v.postFinalization]:"phase-finalization",[v.runFlowComplete]:"milestone-complete"},nt=["milestone-init","phase-analyze","llm-analyze","phase-assemble","phase-execution","phase-finalization","llm-finalization","milestone-complete"],N=class i{static mapPhaseToNodeId(o){return tt[o]??null}static computeStateTransitions(o){let e=i.mapPhaseToNodeId(o);if(!e)return[];let t=[],n=!1;for(let r of nt)r===e?(t.push({nodeId:r,state:x.active}),n=!0):n||t.push({nodeId:r,state:x.completed});return t}static extractIterationData(o){let e=o.action;if(typeof e!="string")return null;let t=o.tool,n=typeof t=="string"?t:"",r=o.intent,s=typeof r=="string"?r:"",a=o.iterationCount;return{actionType:e,tool:n,intent:s,iterationIndex:typeof a=="number"?a:0}}static mapMonitoringEventToIterationNodeId(o,e){let t=o.data??{},n=t.step,r=typeof n=="string"?n:"",s=`iter-${e}`;if(o.eventType==="llm-call"){let a=t.callType;if(a==="agentic-loop")return`${s}-llm-decision`;if(a==="tool-description")return`${s}-tool-desc`;if(a==="tool-error-retry")return`${s}-tool-error-retry`;if(a==="tool-result-chunking")return`${s}-tool-chunking`;if(a==="goal-state-update")return`${s}-goal-update`}return o.eventType==="tool-call"?`${s}-tool-call`:o.eventType==="error"||r.includes("tool-error")?`${s}-tool-call`:null}static isTerminalPhase(o){return o===v.runFlowComplete}static SKELETON_LLM_NODE_MAP={analyze:"llm-analyze","run-finalization":"llm-finalization"};static LLM_CALL_PHASE_MAP={analyze:"phase-analyze","subanalyze-run-tasks":"phase-analyze","instant-reply":"phase-execution","run-finalization":"phase-finalization","chat-history-compacting":"phase-execution","execution-history-compacting":"phase-execution","soul-compacting":"phase-execution","context-compacting":"phase-execution","message-interceptor":"phase-execution"};static ITERATION_LLM_CALL_TYPES=new Set(["agentic-loop","tool-description","tool-error-retry","tool-result-chunking","goal-state-update"]);static LLM_CALL_LABEL_MAP={analyze:"LLM: Analyze","subanalyze-run-tasks":"LLM: Subanalyze","instant-reply":"LLM: Instant Reply","agentic-loop":"LLM Decision","tool-description":"Tool Description","tool-error-retry":"LLM: Error Retry","run-finalization":"LLM: Summary","chat-history-compacting":"LLM: Compact Chat","execution-history-compacting":"LLM: Compact Exec","soul-compacting":"LLM: Compact Soul","context-compacting":"LLM: Compact Ctx","tool-result-chunking":"LLM: Chunking","goal-state-update":"LLM: Goal Update","message-interceptor":"LLM: Msg Intercept"};static getPreCreatedSkeletonNodeId(o){return i.SKELETON_LLM_NODE_MAP[o]??null}static getLlmCallPhaseId(o){return i.LLM_CALL_PHASE_MAP[o]??null}static isIterationLlmCall(o){return i.ITERATION_LLM_CALL_TYPES.has(o)}static getLlmCallLabel(o){return i.LLM_CALL_LABEL_MAP[o]??`LLM: ${o}`}};var k=function(i){return i.sequential="sequential",i.loopEntry="loop-entry",i.errorRetry="error-retry",i}(k||{});var f=function(i){return i.phase="phase",i.milestone="milestone",i.llmCall="llm-call",i.toolCall="tool-call",i.toolError="tool-error",i.loopIteration="loop-iteration",i.action="action",i.error="error",i}(f||{});var je="milestone-init",Ee="phase-analyze",it="llm-analyze",Me="phase-assemble",ee="phase-execution",he="phase-finalization",Ae="llm-finalization",De="milestone-complete",P=class i{static buildSkeletonLayout(){let o=48+220/2,e=48,t=[],n=[],r=i.createNode({id:je,category:f.milestone,label:"Initialization",phase:v.runInitialization,x:o-200/2,y:e,width:200,height:48});t.push(r),e+=84;let s=i.createNode({id:Ee,category:f.phase,label:"Analyze",phase:v.analyze,x:o-220/2,y:e,width:220,height:60});t.push(s);let a=i.createNode({id:it,category:f.llmCall,label:"LLM: Analyze",phase:v.analyzeResult,x:o+220/2+28,y:e+16/2,width:160,height:44,parentId:Ee});t.push(a),n.push(i.createEdge(je,Ee,k.sequential)),e+=96;let h=i.createNode({id:Me,category:f.phase,label:"Assemble",phase:v.assemble,x:o-220/2,y:e,width:220,height:60});t.push(h),n.push(i.createEdge(Ee,Me,k.sequential)),e+=96;let l=i.createNode({id:ee,category:f.phase,label:"Execution",phase:v.execution,x:o-220/2,y:e,width:220,height:60});t.push(l),n.push(i.createEdge(Me,ee,k.sequential)),e+=96;let c=i.createNode({id:he,category:f.phase,label:"Finalization",phase:v.finalization,x:o-220/2,y:e,width:220,height:60});t.push(c);let _=i.createNode({id:Ae,category:f.llmCall,label:"LLM: Summary",phase:v.llmRunFinalization,x:o+220/2+28,y:e+16/2,width:160,height:44,parentId:he});t.push(_),n.push(i.createEdge(ee,he,k.sequential)),e+=96;let y=i.createNode({id:De,category:f.milestone,label:"Flow Complete",phase:v.runFlowComplete,x:o-200/2,y:e,width:200,height:48});t.push(y),n.push(i.createEdge(he,De,k.sequential));let T=i.recalculateViewBox(t,48);return{nodes:t,edges:n,viewBox:T,loopContainerBounds:null}}static addIterationColumn(o,e,t,n){let r=o.nodes.map(b=>I({},b)),s=[...o.edges],a=r.find(b=>b.id===ee);if(!a)return o;let h=a.x+20+e*208,l=a.y+60+20,c=`iter-${e}`,_=l,y=[],T=i.createNode({id:`${c}-llm-decision`,category:f.llmCall,label:"LLM Decision",phase:v.llmAgenticLoop,x:h,y:_,width:160,height:44,parentId:ee,iterationIndex:e});y.push(T),_+=68;let M=i.formatActionLabel(t),O=i.createNode({id:`${c}-action`,category:f.action,label:M,phase:v.agenticLoopIteration,x:h+20/2,y:_,width:140,height:32,parentId:ee,iterationIndex:e,data:n});if(y.push(O),_+=56,t==="tool-select"){let b=i.createNode({id:`${c}-tool-desc`,category:f.llmCall,label:"Tool Description",phase:v.llmToolDescription,x:h,y:_,width:160,height:44,parentId:ee,iterationIndex:e});y.push(b),_+=68;let q=n.tool,Q=typeof q=="string"?q:"tool",te=i.createNode({id:`${c}-tool-call`,category:f.toolCall,label:Q,phase:null,x:h,y:_,width:160,height:44,parentId:ee,iterationIndex:e,data:n});y.push(te),_+=68}for(let b=0;b<y.length-1;b++)s.push(i.createEdge(y[b].id,y[b+1].id,k.sequential));r.push(...y);let E=20*2+(e+1)*180+e*28,j=60+20*2+(_-l);a.width=Math.max(a.width,E),a.height=Math.max(a.height,j);let K=a.y+a.height,A=[he,Ae,De],ue=K+36;for(let b of A){let q=r.find(Q=>Q.id===b);if(q){if(b===Ae){let Q=r.find(te=>te.id===he);Q&&(q.y=Q.y+16/2);continue}q.y=ue,ue+=q.height+36}}let ge={x:a.x,y:a.y+60,width:a.width,height:a.height-60},J=r,Je=s.map(b=>{let q=J.find(te=>te.id===b.sourceNodeId),Q=J.find(te=>te.id===b.targetNodeId);return!q||!Q?b:w(I({},b),{pathD:i.computeEdgePath(q,Q,b.category)})}),et=i.recalculateViewBox(J,48);return{nodes:J,edges:Je,viewBox:et,loopContainerBounds:ge}}static computeEdgePath(o,e,t){let n=o.x+o.width/2,r=o.y+o.height,s=e.x+e.width/2,a=e.y;if(Math.abs(n-s)<20)return`M ${n} ${r} L ${s} ${a}`;let h=o.x+o.width,l=o.y+o.height/2,c=e.x,_=e.y+e.height/2;if(e.parentId===o.id)return`M ${h} ${l} L ${c} ${_}`;let y=r+(a-r)/2;return`M ${n} ${r} L ${n} ${y} L ${s} ${y} L ${s} ${a}`}static recalculateViewBox(o,e){if(o.length===0)return{x:0,y:0,width:600,height:400};let t=1/0,n=1/0,r=-1/0,s=-1/0;for(let a of o)t=Math.min(t,a.x),n=Math.min(n,a.y),r=Math.max(r,a.x+a.width),s=Math.max(s,a.y+a.height);return{x:t-e,y:n-e,width:r-t+e*2,height:s-n+e*2}}static addDynamicLlmNode(o,e,t,n,r,s){let a=o.nodes.map(A=>I({},A)),h=[...o.edges],l=a.find(A=>A.id===e);if(!l)return o;let c,_;l.category===f.phase||l.category===f.milestone?(c=l.x+l.width+28,_=l.y+(l.height-44)/2):(c=l.x,_=l.y+l.height+24);let T=i.createNode({id:t,category:f.llmCall,label:n,phase:null,x:c,y:_,width:160,height:44,parentId:r,iterationIndex:s??void 0});a.push(T),h.push(i.createEdge(e,t,k.sequential));let M=T.y+T.height;s!=null?i.expandExecutionContainer(a,M):i.shiftDownstreamIfOverlap(a,r,M);let O=o.loopContainerBounds,E=a.find(A=>A.id==="phase-execution");E&&E.height>60&&(O={x:E.x,y:E.y+60,width:E.width,height:E.height-60});let j=h.map(A=>{let ue=a.find(J=>J.id===A.sourceNodeId),ge=a.find(J=>J.id===A.targetNodeId);return!ue||!ge?A:w(I({},A),{pathD:i.computeEdgePath(ue,ge,A.category)})}),K=i.recalculateViewBox(a,48);return{nodes:a,edges:j,viewBox:K,loopContainerBounds:O}}static expandExecutionContainer(o,e){let t=o.find(l=>l.id==="phase-execution");if(!t)return;let n=t.y+60+20,r=60+20*2+(e+24-n);if(r<=t.height)return;t.height=r;let s=t.y+t.height,a=["phase-finalization","llm-finalization","milestone-complete"],h=s+36;for(let l of a){let c=o.find(_=>_.id===l);if(c){if(l==="llm-finalization"){let _=o.find(y=>y.id==="phase-finalization");_&&(c.y=_.y+16/2);continue}c.y<h&&(c.y=h),h=c.y+c.height+36}}for(let l of o)if(l.parentId==="phase-finalization"&&l.id!=="llm-finalization"&&l.category===f.llmCall){let c=o.find(_=>_.id==="phase-finalization");c&&(l.y=Math.max(l.y,c.y))}}static shiftDownstreamIfOverlap(o,e,t){let n=["milestone-init","phase-analyze","phase-assemble","phase-execution","phase-finalization","milestone-complete"],r=n.indexOf(e);if(r<0||r>=n.length-1)return;let s=n[r+1],a=o.find(_=>_.id===s);if(!a||t+36<=a.y)return;let h=t+36-a.y,l=new Set;for(let _ of o)_.parentId===e&&_.category===f.llmCall&&l.add(_.id);let c=a.y;for(let _ of o)_.y>=c&&!l.has(_.id)&&(_.y+=h)}static createNode(o){return{id:o.id,category:o.category,state:x.pending,label:o.label,phase:o.phase,x:o.x,y:o.y,width:o.width,height:o.height,data:o.data??{},iterationIndex:o.iterationIndex??null,parentId:o.parentId??null,monitoringEvent:null}}static createEdge(o,e,t){let n=t===k.errorRetry?"#f97316":t===k.loopEntry?"#3b82f6":"#525252",r=t===k.loopEntry?"8 4":t===k.errorRetry?"6 3":"none",s=t===k.errorRetry?"url(#ses-arrow-error)":t===k.loopEntry?"url(#ses-arrow-loop)":"url(#ses-arrow-seq)";return{id:`edge-${o}-${e}`,category:t,sourceNodeId:o,targetNodeId:e,pathD:"",strokeColor:n,strokeDashArray:r,markerEnd:s}}static formatActionLabel(o){return{"tool-select":"Tool Select","tool-group-open":"Tool Group","context-handling":"Context","loop-debrief":"Debrief",result:"Result"}[o]??o}};var qe=(()=>{class i{baseUrl=`${Ve.api.baseUrl}/session`;http=Z(He);getEvents(e){let t=encodeURIComponent(e.trim());return be(this.http.get(`${this.baseUrl}/${t}/events`))}getRunTrace(e){let t=e.sessionId.trim(),n=encodeURIComponent(e.runId.trim());return be(this.http.get(`${this.baseUrl}/${encodeURIComponent(t)}/runs/${n}/trace`))}static \u0275fac=function(t){return new(t||i)};static \u0275prov=xe({token:i,factory:i.\u0275fac,providedIn:"root"})}return i})();var Ze=(()=>{class i{session_DS=Z(Ce);monitoring_AS=Z(qe);destroyRef=Z(Pe);graphLayout_$=V(null);activeNodeId_$=V("");selectedNodeId_$=V("");isLive_$=V(!1);isGraphOpen_$=V(!1);graphSessionId_$=V("");graphRunId_$=V("");isLoading_$=V(!1);currentIterationIndex=-1;monitoringSubscription=null;lastAppliedPhase="";phaseRightColumnLast={};iterationColumnLast={};dynamicNodeCounter=0;constructor(){Se(()=>{let e=this.session_DS.agentEvents_$();!this.isGraphOpen_$()||!this.isLive_$()||this.applyAgentEvent(e)},{allowSignalWrites:!0}),this.destroyRef.onDestroy(()=>{this.disposeSubscriptions()})}openGraphForRun(e,t,n){this.disposeSubscriptions(),this.resetState(),this.graphSessionId_$.set(e),this.graphRunId_$.set(t),this.isLive_$.set(n),this.isGraphOpen_$.set(!0),n?this.initLiveGraph():this.loadHistoricalGraph(e,t)}closeGraph(){this.disposeSubscriptions(),this.isGraphOpen_$.set(!1),this.selectedNodeId_$.set("")}selectNode(e){let t=this.selectedNodeId_$();this.selectedNodeId_$.set(t===e?"":e)}clearSelection(){this.selectedNodeId_$.set("")}initLiveGraph(){let e=P.buildSkeletonLayout(),t=this.recalculateEdgePaths(e);this.graphLayout_$.set(t),this.phaseRightColumnLast={"phase-analyze":"llm-analyze","phase-finalization":"llm-finalization"},this.iterationColumnLast={},this.monitoringSubscription=this.session_DS.monitoringEvent_S.subscribe(n=>{n.sessionId===this.graphSessionId_$()&&this.applyMonitoringEvent(n.event)})}applyAgentEvent(e){let t=e.phase;if(typeof t!="string"||t.length===0||t===this.lastAppliedPhase)return;if(this.lastAppliedPhase=t,t===v.agenticLoopIteration){let r=N.extractIterationData(e);r&&this.addIteration(r);return}let n=N.computeStateTransitions(t);n.length!==0&&(this.applyStateTransitions(n),N.isTerminalPhase(t)&&this.markAllIterationNodesCompleted())}addIteration(e){let t=this.graphLayout_$();if(!t)return;this.currentIterationIndex=e.iterationIndex,this.markPreviousIterationCompleted(e.iterationIndex);let n=P.addIterationColumn(t,e.iterationIndex,e.actionType,{tool:e.tool,intent:e.intent}),r=e.actionType==="tool-select"?`iter-${e.iterationIndex}-tool-call`:`iter-${e.iterationIndex}-action`;this.iterationColumnLast[e.iterationIndex]=r;let s=`iter-${e.iterationIndex}-llm-decision`,a=this.setNodeState(n,s,x.active);this.activeNodeId_$.set(s),this.graphLayout_$.set(this.recalculateEdgePaths(a))}markPreviousIterationCompleted(e){if(e<=0)return;let t=this.graphLayout_$();if(!t)return;let n=`iter-${e-1}`,r=t;for(let s of t.nodes)s.id.startsWith(n)&&s.state!==x.error&&(r=this.setNodeState(r,s.id,x.completed));this.graphLayout_$.set(r)}applyMonitoringEvent(e){let t=this.graphLayout_$();if(!t)return;let n=typeof e.eventType=="string"?e.eventType:"",r=typeof e.status=="string"?e.status:"",s=i.toRecord(e.data),a=typeof e.durationMs=="number"?e.durationMs:0,h=typeof e.inputSize=="number"?e.inputSize:0,l=typeof e.outputSize=="number"?e.outputSize:0,c={eventType:n,timestamp:new Date,data:s,durationMs:a,status:r,sessionId:this.graphSessionId_$(),runId:this.graphRunId_$(),inputSize:h,outputSize:l};if(n==="llm-call"){this.handleLlmCallMonitoringEvent(c,t);return}if(this.currentIterationIndex<0)return;let _=N.mapMonitoringEventToIterationNodeId(c,this.currentIterationIndex);if(!_)return;let y=this.enrichNodeWithMonitoringEvent(t,_,c);y&&this.graphLayout_$.set(y)}handleLlmCallMonitoringEvent(e,t){let n=e.data?.callType,r=typeof n=="string"?n:"";if(!r)return;let s=N.getPreCreatedSkeletonNodeId(r);if(s){let h=this.enrichNodeWithMonitoringEvent(t,s,e);h&&this.graphLayout_$.set(h);return}if(N.isIterationLlmCall(r)&&this.currentIterationIndex>=0){let h=N.mapMonitoringEventToIterationNodeId(e,this.currentIterationIndex);if(h){if(t.nodes.findIndex(c=>c.id===h)>=0){let c=this.enrichNodeWithMonitoringEvent(t,h,e);c&&this.graphLayout_$.set(c)}else this.createDynamicIterationLlmNode(t,r,h,e);return}}let a=N.getLlmCallPhaseId(r);a&&this.createDynamicSkeletonLlmNode(t,r,a,e)}enrichNodeWithMonitoringEvent(e,t,n){let r=e.nodes.findIndex(_=>_.id===t);if(r<0)return null;let s=n.data??{},a=n.status==="error",h=n.durationMs??0,l=a?x.error:h>0?x.completed:x.active,c=[...e.nodes];return c[r]=w(I({},c[r]),{state:l,monitoringEvent:n,data:w(I(I({},c[r].data),s),{durationMs:h})}),this.activeNodeId_$.set(l===x.active?t:""),w(I({},e),{nodes:c})}createDynamicSkeletonLlmNode(e,t,n,r){this.dynamicNodeCounter++;let s=`llm-dyn-${this.dynamicNodeCounter}`,a=N.getLlmCallLabel(t),h=this.phaseRightColumnLast[n]??n,l=P.addDynamicLlmNode(e,h,s,a,n,null);this.phaseRightColumnLast[n]=s;let c=this.enrichNodeWithMonitoringEvent(l,s,r);this.graphLayout_$.set(c??l)}createDynamicIterationLlmNode(e,t,n,r){let s=N.getLlmCallLabel(t),a=this.iterationColumnLast[this.currentIterationIndex]??`iter-${this.currentIterationIndex}-action`,h=P.addDynamicLlmNode(e,a,n,s,"phase-execution",this.currentIterationIndex);this.iterationColumnLast[this.currentIterationIndex]=n;let l=this.enrichNodeWithMonitoringEvent(h,n,r);this.graphLayout_$.set(l??h)}loadHistoricalGraph(e,t){return ke(this,null,function*(){this.isLoading_$.set(!0);try{let n=yield this.monitoring_AS.getRunTrace({sessionId:e,runId:t});this.buildHistoricalGraph(n.trace)}catch{let n=P.buildSkeletonLayout();this.graphLayout_$.set(this.recalculateEdgePaths(n))}finally{this.isLoading_$.set(!1)}})}buildHistoricalGraph(e){let t=P.buildSkeletonLayout();t=this.recalculateEdgePaths(t);let n="",r=-1,s={"phase-analyze":"llm-analyze","phase-finalization":"llm-finalization"},a={},h=0;for(let l of e){let c=l.data??{},_=c.step,y=typeof _=="string"?_:"";if(y.length>0&&N.mapPhaseToNodeId(y)&&y!==n){n=y;let M=N.computeStateTransitions(y);for(let O of M)t=this.setNodeState(t,O.nodeId,O.state)}if(y==="agentic-loop-iteration"||y.includes("agentic-loop")){let T=c.action,M=typeof T=="string"?T:"",O=c.tool,E=typeof O=="string"?O:"";if(M.length>0){r++,t=P.addIterationColumn(t,r,M,{tool:E});let j=M==="tool-select"?`iter-${r}-tool-call`:`iter-${r}-action`;a[r]=j}}if(l.eventType==="llm-call"){let T=c.callType,M=typeof T=="string"?T:"";if(M){let O=N.getPreCreatedSkeletonNodeId(M);if(O)t=this.enrichHistoricalNode(t,O,l,c);else if(N.isIterationLlmCall(M)&&r>=0){let E=N.mapMonitoringEventToIterationNodeId(l,r);if(E)if(t.nodes.findIndex(K=>K.id===E)>=0)t=this.enrichHistoricalNode(t,E,l,c);else{let K=N.getLlmCallLabel(M),A=a[r]??`iter-${r}-action`;t=P.addDynamicLlmNode(t,A,E,K,"phase-execution",r),t=this.enrichHistoricalNode(t,E,l,c),a[r]=E}}else{let E=N.getLlmCallPhaseId(M);if(E){h++;let j=`llm-dyn-${h}`,K=N.getLlmCallLabel(M),A=s[E]??E;t=P.addDynamicLlmNode(t,A,j,K,E,null),t=this.enrichHistoricalNode(t,j,l,c),s[E]=j}}}continue}if(r>=0){let T=N.mapMonitoringEventToIterationNodeId(l,r);T&&(t=this.enrichHistoricalNode(t,T,l,c))}}if(n===v.runFlowComplete)for(let l of t.nodes)l.state===x.pending&&(t=this.setNodeState(t,l.id,x.completed));this.graphLayout_$.set(this.recalculateEdgePaths(t))}enrichHistoricalNode(e,t,n,r){let s=e.nodes.findIndex(h=>h.id===t);if(s<0)return e;let a=[...e.nodes];return a[s]=w(I({},a[s]),{state:n.status==="error"?x.error:x.completed,monitoringEvent:n,data:w(I(I({},a[s].data),r),{durationMs:n.durationMs})}),w(I({},e),{nodes:a})}applyStateTransitions(e){let t=this.graphLayout_$();if(!t)return;let n="";for(let r of e)t=this.setNodeState(t,r.nodeId,r.state),r.state===x.active&&(n=r.nodeId);this.activeNodeId_$.set(n),this.graphLayout_$.set(t)}setNodeState(e,t,n){let r=e.nodes.findIndex(a=>a.id===t);if(r<0)return e;let s=[...e.nodes];return s[r]=w(I({},s[r]),{state:n}),w(I({},e),{nodes:s})}markAllIterationNodesCompleted(){let e=this.graphLayout_$();if(!e)return;let t=e;for(let n of e.nodes)n.iterationIndex!=null&&n.state!==x.error&&(t=this.setNodeState(t,n.id,x.completed));this.graphLayout_$.set(t)}recalculateEdgePaths(e){let t=e.edges.map(n=>{let r=e.nodes.find(a=>a.id===n.sourceNodeId),s=e.nodes.find(a=>a.id===n.targetNodeId);return!r||!s?n:w(I({},n),{pathD:P.computeEdgePath(r,s,n.category)})});return w(I({},e),{edges:t})}resetState(){this.graphLayout_$.set(null),this.activeNodeId_$.set(""),this.selectedNodeId_$.set(""),this.currentIterationIndex=-1,this.lastAppliedPhase="",this.isLoading_$.set(!1),this.dynamicNodeCounter=0,this.phaseRightColumnLast={},this.iterationColumnLast={}}disposeSubscriptions(){this.monitoringSubscription&&(this.monitoringSubscription.unsubscribe(),this.monitoringSubscription=null)}static toRecord(e){return typeof e!="object"||e==null?{}:JSON.parse(JSON.stringify(e))}static \u0275fac=function(t){return new(t||i)};static \u0275prov=xe({token:i,factory:i.\u0275fac,providedIn:"root"})}return i})();var ot=["appSesGraphNodeSvg",""];function rt(i,o){if(i&1&&(H(),p(0,"text",1),m(1),d()),i&2){let e=C();Y("x",10)("y",e.node().height/2+1),u(),L(e.icon_$())}}function at(i,o){if(i&1&&(H(),p(0,"text",3),m(1),d()),i&2){let e=C();Y("x",e.node().width-10)("y",12)("fill",e.node().state==="error"?"#ef4444":"#22c55e"),u(),L(e.stateIcon_$())}}function st(i,o){if(i&1&&(H(),p(0,"text",4),m(1),d()),i&2){let e=C();Y("x",e.node().width-8)("y",e.node().height-8),u(),_e("",e.durationMs_$(),"ms")}}var $e=class i{node=F.required();isHighlighted=F(!1);isSelected=F(!1);nodeClicked=ne();fillColor_$=g(()=>{let o=this.node();return o.state===x.pending?"#262626":i.CATEGORY_FILL_MAP[o.category]??"#262626"});strokeColor_$=g(()=>{let o=this.node();return o.state===x.error?"#ef4444":o.state===x.pending?"#525252":i.CATEGORY_STROKE_MAP[o.category]??"#737373"});strokeDashArray_$=g(()=>this.node().state===x.pending?"6 3":"none");textColor_$=g(()=>this.node().state===x.pending?"#737373":"#e5e5e5");opacity_$=g(()=>this.node().state===x.pending?.5:1);borderRadius_$=g(()=>this.node().category===f.action?16:8);icon_$=g(()=>{let o=this.node().category;return i.CATEGORY_ICON_MAP[o]??""});stateIcon_$=g(()=>{let o=this.node().state;return o===x.completed?"\u2713":o===x.error?"\u2715":""});animationClass_$=g(()=>this.node().state===x.active||this.isHighlighted()?"ses-graph-node--active":this.isSelected()?"ses-graph-node--selected":"");durationMs_$=g(()=>this.node().data.durationMs??0);handleClick(){this.nodeClicked.emit(this.node().id)}static CATEGORY_FILL_MAP={[f.phase]:"#1a1a2e",[f.milestone]:"#052e16",[f.llmCall]:"#1e1033",[f.toolCall]:"#2e2a05",[f.toolError]:"#2e1505",[f.loopIteration]:"#0a1628",[f.action]:"#1a1a2e",[f.error]:"#2e0505"};static CATEGORY_STROKE_MAP={[f.phase]:"#525252",[f.milestone]:"#22c55e",[f.llmCall]:"#a855f7",[f.toolCall]:"#eab308",[f.toolError]:"#f97316",[f.loopIteration]:"#3b82f6",[f.action]:"#3b82f6",[f.error]:"#ef4444"};static CATEGORY_ICON_MAP={[f.milestone]:"\u26A1",[f.llmCall]:"\u{1F9E0}",[f.toolCall]:"\u{1F527}",[f.toolError]:"\u26A0\uFE0F",[f.error]:"\u274C"};static \u0275fac=function(e){return new(e||i)};static \u0275cmp=ae({type:i,selectors:[["","appSesGraphNodeSvg",""]],inputs:{node:[1,"node"],isHighlighted:[1,"isHighlighted"],isSelected:[1,"isSelected"]},outputs:{nodeClicked:"nodeClicked"},standalone:!0,features:[le],attrs:ot,decls:7,vars:21,consts:[[2,"cursor","pointer",3,"click"],["dominant-baseline","central","text-anchor","start","font-size","14"],["dominant-baseline","central"],["text-anchor","end","dominant-baseline","central","font-size","11","font-weight","700"],["text-anchor","end","dominant-baseline","auto","fill","#737373","font-size","9"]],template:function(e,t){e&1&&(H(),p(0,"g",0),B("click",function(){return t.handleClick()}),W(1,"rect"),D(2,rt,2,3,":svg:text",1),p(3,"text",2),m(4),d(),D(5,at,2,4,":svg:text",3)(6,st,2,3,":svg:text",4),d()),e&2&&(se(t.animationClass_$()),Y("transform","translate("+t.node().x+","+t.node().y+")")("opacity",t.opacity_$()),u(),Y("width",t.node().width)("height",t.node().height)("rx",t.borderRadius_$())("fill",t.fillColor_$())("stroke",t.strokeColor_$())("stroke-width",t.isSelected()?2.5:1.5)("stroke-dasharray",t.strokeDashArray_$()),u(),S(t.icon_$()?2:-1),u(),Y("x",t.icon_$()?30:t.node().width/2)("y",t.node().height/2+1)("text-anchor",t.icon_$()?"start":"middle")("fill",t.textColor_$())("font-size",t.node().category==="phase"||t.node().category==="milestone"?14:12)("font-weight",t.node().category==="phase"||t.node().category==="milestone"?600:400),u(),L(t.node().label),u(),S(t.stateIcon_$()?5:-1),u(),S(t.durationMs_$()?6:-1))},dependencies:[de],encapsulation:2})};function lt(i,o){if(i&1&&(p(0,"div",7)(1,"span",8),m(2,"Phase"),d(),p(3,"span",9),m(4),d()()),i&2){let e=C();u(4),L(e.node().phase)}}function dt(i,o){if(i&1&&(p(0,"div",7)(1,"span",8),m(2,"Step"),d(),p(3,"span",9),m(4),d()()),i&2){let e=C();u(4),L(e.stepLabel_$())}}function ct(i,o){if(i&1&&(p(0,"div",7)(1,"span",8),m(2,"Duration"),d(),p(3,"span",9),m(4),d()()),i&2){let e=C();u(4),L(e.durationLabel_$())}}function pt(i,o){if(i&1&&(p(0,"div",7)(1,"span",8),m(2,"Tool"),d(),p(3,"span",12),m(4),d()()),i&2){let e=C();u(4),L(e.toolId_$())}}function ht(i,o){if(i&1&&(p(0,"div",10)(1,"span",13),m(2,"Intent"),d(),p(3,"span",14),m(4),d()()),i&2){let e=C();u(4),L(e.intent_$())}}function ut(i,o){if(i&1&&(p(0,"div",7)(1,"span",8),m(2,"Iteration"),d(),p(3,"span",15),m(4),d()()),i&2){let e=C();u(4),_e("#",e.node().iterationIndex,"")}}function mt(i,o){if(i&1&&(p(0,"span",13),m(1," In: "),p(2,"span",9),m(3),d()()),i&2){let e=C(2);u(3),L(e.inputSize_$())}}function _t(i,o){if(i&1&&(p(0,"span",13),m(1," Out: "),p(2,"span",9),m(3),d()()),i&2){let e=C(2);u(3),L(e.outputSize_$())}}function ft(i,o){if(i&1&&(p(0,"div",11),D(1,mt,4,1,"span",13)(2,_t,4,1,"span",13),d()),i&2){let e=C();u(),S(e.inputSize_$()>0?1:-1),u(),S(e.outputSize_$()>0?2:-1)}}function gt(i,o){if(i&1&&(p(0,"div",7)(1,"span",8),m(2,"Provider"),d(),p(3,"span",26),m(4),d()()),i&2){let e=C(3);u(4),L(e.usedProvider_$())}}function xt(i,o){if(i&1&&(p(0,"div",7)(1,"span",8),m(2,"Model"),d(),p(3,"span",26),m(4),d()()),i&2){let e=C(3);u(4),L(e.usedModel_$())}}function yt(i,o){if(i&1&&(p(0,"span",13),m(1," Cost: "),p(2,"span",27),m(3),d()()),i&2){let e=C(4);u(3),L(e.costUsd_$())}}function St(i,o){if(i&1&&(p(0,"div",25)(1,"span",13),m(2," Tokens: "),p(3,"span",9),m(4),d()(),D(5,yt,4,1,"span",13),d()),i&2){let e=C(3);u(4),L(e.tokenInfo_$().total),u(),S(e.costUsd_$()?5:-1)}}function Ct(i,o){if(i&1&&(p(0,"div",16)(1,"div",23),m(2,"Used"),d(),p(3,"div",24),D(4,gt,5,1,"div",7)(5,xt,5,1,"div",7)(6,St,6,2,"div",25),d()()),i&2){let e=C(2);u(4),S(e.usedProvider_$()?4:-1),u(),S(e.usedModel_$()?5:-1),u(),S(e.tokenInfo_$()?6:-1)}}function vt(i,o){if(i&1){let e=ie();p(0,"button",28),B("click",function(){R(e);let n=C(2);return z(n.handleClearOverride())}),m(1," Clear "),d()}}function It(i,o){i&1&&(p(0,"div",21),m(1," Session override active "),d())}function Et(i,o){if(i&1&&(p(0,"div",22)(1,"div",29),m(2,"Global default"),d(),p(3,"div",30),m(4),d()()),i&2){let e=C(2);u(4),ze(" ",e.globalDefault_$().provider," / ",e.globalDefault_$().model," ")}}function Nt(i,o){if(i&1){let e=ie();D(0,Ct,7,3,"div",16),p(1,"div",16)(2,"div",17)(3,"div",18),m(4),d(),D(5,vt,2,0,"button",19),d(),p(6,"app-s-registry-provider-model-select",20),B("modelChange",function(n){R(e);let r=C();return z(r.handleModelChange(n))}),d(),D(7,It,2,0,"div",21),d(),D(8,Et,5,2,"div",22)}if(i&2){let e=C();S(e.usedProvider_$()||e.usedModel_$()?0:-1),u(4),_e(" Override: ",e.callTypeLabel_$()," "),u(),S(e.hasSessionOverride_$()?5:-1),u(),me("selectedProvider",e.selectedProvider_$())("selectedModel",e.selectedModel_$()),u(),S(e.hasSessionOverride_$()?7:-1),u(),S(e.globalDefault_$()?8:-1)}}var Ke=(()=>{class i{graph_DS=Z(Ze);session_DS=Z(Ce);registrySsot_CS=Z(Be);node=F.required();closed=ne();stateLabel_$=g(()=>({pending:"Pending",active:"Active",completed:"Completed",error:"Error"})[this.node().state]??this.node().state);durationLabel_$=g(()=>{let e=this.node().data.durationMs;return!e||e<=0?"":e<1e3?`${Math.round(e)}ms`:`${(e/1e3).toFixed(1)}s`});toolId_$=g(()=>{let e=this.node().data,t=e.toolId??e.tool;return typeof t=="string"?t:""});intent_$=g(()=>{let e=this.node().data.intent;return typeof e=="string"?e:""});stepLabel_$=g(()=>{let e=this.node().data.step;return typeof e!="string"||e.length===0?"":ve.formatStepId(e)});inputSize_$=g(()=>{let e=this.node().monitoringEvent;return e?e.inputSize??0:0});outputSize_$=g(()=>{let e=this.node().monitoringEvent;return e?e.outputSize??0:0});stateColorClass_$=g(()=>({pending:"text-neutral-500",active:"text-cyan-400",completed:"text-green-400",error:"text-red-400"})[this.node().state]??"text-neutral-400");isLlmCall_$=g(()=>this.node().category===f.llmCall);callType_$=g(()=>{let e=this.node().data?.callType;return typeof e=="string"?e:""});callTypeLabel_$=g(()=>{let e=this.callType_$();return Ye[e]??e});usedProvider_$=g(()=>{let e=this.node().data?.provider;return typeof e=="string"?e:""});usedModel_$=g(()=>{let e=this.node().data?.model;return typeof e=="string"?e:""});sessionOverride_$=g(()=>{let e=this.callType_$();if(!e)return null;let t=this.graph_DS.graphSessionId_$();if(!t)return null;let r=this.session_DS.sessionInfoMap_$().get(t);if(!r)return null;let s=r.llmCallTypeOverrides;if(!s)return null;let a=s[e];if(typeof a!="object"||!a)return null;let h=a,l=h.provider,c=h.model;return typeof l=="string"&&typeof c=="string"?{provider:l,model:c}:null});globalDefault_$=g(()=>{let e=this.callType_$();if(!e)return null;let t=this.graph_DS.graphSessionId_$(),r=this.session_DS.sessionInfoMap_$().get(t);if(!r)return null;let s=r.globalCallTypeDefaults;if(!s)return null;let a=s[e];if(typeof a!="object"||!a)return null;let h=a,l=h.provider,c=h.model;return typeof l=="string"&&typeof c=="string"?{provider:l,model:c}:null});selectedProvider_$=g(()=>this.sessionOverride_$()?.provider??"");selectedModel_$=g(()=>this.sessionOverride_$()?.model??"");hasSessionOverride_$=g(()=>this.sessionOverride_$()!==null);tokenInfo_$=g(()=>{let e=this.node().data,t=e.promptTokens,n=e.completionTokens,r=e.totalTokens;return typeof r!="number"||r<=0?null:{prompt:typeof t=="number"?t:0,completion:typeof n=="number"?n:0,total:r}});costUsd_$=g(()=>{let e=this.node().data?.costUsd;return typeof e!="number"||e<=0?"":`$${e.toFixed(4)}`});handleClose(){this.closed.emit()}handleProviderChange(e){}handleModelChange(e){let t=this.callType_$(),n=this.graph_DS.graphSessionId_$();if(!t||!n||!e)return;let s=this.registrySsot_CS.enabledLlmModels_$().find(a=>a.modelName===e);s&&this.applySessionOverride(n,t,s.provider,s.modelName)}handleClearOverride(){let e=this.callType_$(),t=this.graph_DS.graphSessionId_$();!e||!t||this.clearSessionOverride(t,e)}applySessionOverride(e,t,n,r){let h=this.session_DS.sessionInfoMap_$().get(e)?.llmCallTypeOverrides??{},l=w(I({},h),{[t]:{provider:n,model:r}});this.session_DS.updateSession({sessionId:e,updates:{llmCallTypeOverrides:l}}).then(()=>{this.session_DS.loadSessionInfo(e)})}clearSessionOverride(e,t){let s=this.session_DS.sessionInfoMap_$().get(e)?.llmCallTypeOverrides??{},a=I({},s);Reflect.deleteProperty(a,t);let h=Object.keys(a).length>0;this.session_DS.updateSession({sessionId:e,updates:{llmCallTypeOverrides:h?a:null}}).then(()=>{this.session_DS.loadSessionInfo(e)})}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=ae({type:i,selectors:[["app-ses-graph-node-detail"]],inputs:{node:[1,"node"]},outputs:{closed:"closed"},standalone:!0,features:[le],decls:26,vars:13,consts:[[1,"w-80","max-h-[28rem]","overflow-y-auto","rounded-lg","border","border-neonCyan/30","bg-neutral-900/95","shadow-lg","backdrop-blur-sm","p-3"],[1,"flex","items-start","justify-between","gap-2","mb-2"],[1,"text-sm","font-semibold","text-neutral-200","leading-tight"],["title","Bez\xE1r\xE1s","aria-label","Bez\xE1r\xE1s",1,"p-1","min-h-[28px]","min-w-[28px]","flex","items-center","justify-center","rounded","text-neutral-400","hover:text-neutral-200","hover:bg-neutral-700","transition-colors","shrink-0",3,"click"],["viewBox","0 0 24 24","fill","none","stroke","currentColor","stroke-width","2","stroke-linecap","round","stroke-linejoin","round",1,"w-3.5","h-3.5"],["d","M18 6L6 18M6 6l12 12"],[1,"space-y-1.5","text-xs"],[1,"flex","items-center","gap-2"],[1,"text-neutral-500","w-16","shrink-0"],[1,"text-neutral-300"],[1,"flex","flex-col","gap-0.5"],[1,"flex","items-center","gap-3","pt-1","border-t","border-neutral-800"],[1,"text-yellow-300","font-mono","text-[11px]"],[1,"text-neutral-500"],[1,"text-neutral-300","text-[11px]","leading-tight","break-words"],[1,"text-blue-400"],[1,"mt-3","pt-2","border-t","border-neutral-700"],[1,"flex","items-center","justify-between","mb-1.5"],[1,"text-[10px]","text-neutral-500","uppercase","tracking-wider"],[1,"text-[10px]","text-red-400","hover:text-red-300","transition-colors"],["registryKind","llm","providerLabel","Provider","modelLabel","Model",3,"modelChange","selectedProvider","selectedModel"],[1,"mt-1.5","text-[10px]","text-purple-400"],[1,"mt-2","pt-1.5","border-t","border-neutral-800"],[1,"text-[10px]","text-neutral-500","uppercase","tracking-wider","mb-1.5"],[1,"space-y-1","text-xs"],[1,"flex","items-center","gap-3"],[1,"text-purple-300","font-mono","text-[11px]"],[1,"text-green-400"],[1,"text-[10px]","text-red-400","hover:text-red-300","transition-colors",3,"click"],[1,"text-[10px]","text-neutral-500","uppercase","tracking-wider","mb-1"],[1,"text-[11px]","text-neutral-400","font-mono"]],template:function(t,n){t&1&&(p(0,"div",0)(1,"div",1)(2,"h3",2),m(3),d(),p(4,"button",3),B("click",function(){return n.handleClose()}),H(),p(5,"svg",4),W(6,"path",5),d()()(),ye(),p(7,"div",6)(8,"div",7)(9,"span",8),m(10,"State"),d(),p(11,"span"),m(12),d()(),p(13,"div",7)(14,"span",8),m(15,"Type"),d(),p(16,"span",9),m(17),d()(),D(18,lt,5,1,"div",7)(19,dt,5,1,"div",7)(20,ct,5,1,"div",7)(21,pt,5,1,"div",7)(22,ht,5,1,"div",10)(23,ut,5,1,"div",7)(24,ft,3,2,"div",11),d(),D(25,Nt,9,7),d()),t&2&&(u(3),L(n.node().label),u(8),se(n.stateColorClass_$()+" font-medium"),u(),L(n.stateLabel_$()),u(5),L(n.node().category),u(),S(n.node().phase?18:-1),u(),S(n.stepLabel_$()?19:-1),u(),S(n.durationLabel_$()?20:-1),u(),S(n.toolId_$()?21:-1),u(),S(n.intent_$()?22:-1),u(),S(n.node().iterationIndex!==null?23:-1),u(),S(n.inputSize_$()>0||n.outputSize_$()>0?24:-1),u(),S(n.isLlmCall_$()&&n.callType_$()?25:-1))},dependencies:[de,Fe],encapsulation:2})}return i})();var $t=["graphSvg"],Qe=(i,o)=>o.id;function bt(i,o){i&1&&(p(0,"span",7),m(1,"Loading trace..."),d())}function Lt(i,o){if(i&1&&(H(),W(0,"rect",16)),i&2){let e=o;Y("x",e.x)("y",e.y)("width",e.width)("height",e.height)}}function wt(i,o){if(i&1&&(H(),W(0,"path",17)),i&2){let e=o.$implicit;Y("d",e.pathD)("stroke",e.strokeColor)("stroke-dasharray",e.strokeDashArray)("marker-end",e.markerEnd)}}function Tt(i,o){if(i&1){let e=ie();H(),p(0,"g",20),B("nodeClicked",function(n){R(e);let r=C();return z(r.handleNodeClick(n))}),d()}if(i&2){let e=o.$implicit,t=C();me("node",e)("isHighlighted",t.activeNodeId()===e.id)("isSelected",t.selectedNodeId()===e.id)}}function Mt(i,o){if(i&1){let e=ie();p(0,"app-ses-graph-node-detail",21),B("closed",function(){R(e);let n=C();return z(n.handleDetailClose())}),d()}i&2&&me("node",o)}var Gn=(()=>{class i{svgRef;layout=F(null);activeNodeId=F("");selectedNodeId=F("");isLoading=F(!1);nodeClicked=ne();detailClosed=ne();viewBox_$=V({x:0,y:0,width:800,height:600});viewBoxStr_$=g(()=>{let e=this.viewBox_$();return`${e.x} ${e.y} ${e.width} ${e.height}`});isFollowActive_$=V(!0);isPanning=!1;panStartX=0;panStartY=0;panStartViewBoxX=0;panStartViewBoxY=0;nodes_$=g(()=>this.layout()?.nodes??[]);edges_$=g(()=>this.layout()?.edges??[]);loopBounds_$=g(()=>this.layout()?.loopContainerBounds??null);selectedNode_$=g(()=>{let e=this.selectedNodeId();return e?this.nodes_$().find(t=>t.id===e)??null:null});constructor(){Se(()=>{let e=this.layout();e&&this.viewBox_$.set(I({},e.viewBox))},{allowSignalWrites:!0})}handleNodeClick(e){this.nodeClicked.emit(e)}handleDetailClose(){this.detailClosed.emit()}handlePointerDown(e){if(e.button!==0)return;this.isPanning=!0,this.panStartX=e.clientX,this.panStartY=e.clientY;let t=this.viewBox_$();this.panStartViewBoxX=t.x,this.panStartViewBoxY=t.y,this.svgRef&&this.svgRef.nativeElement.setPointerCapture(e.pointerId)}handlePointerMove(e){if(!this.isPanning||!this.svgRef)return;let t=this.svgRef.nativeElement,n=this.viewBox_$(),r=n.width/t.clientWidth,s=n.height/t.clientHeight,a=(e.clientX-this.panStartX)*r,h=(e.clientY-this.panStartY)*s;this.viewBox_$.set(w(I({},n),{x:this.panStartViewBoxX-a,y:this.panStartViewBoxY-h}))}handlePointerUp(){this.isPanning=!1}handleWheel(e){if(e.preventDefault(),!this.svgRef)return;let t=this.svgRef.nativeElement,n=this.viewBox_$(),r=e.deltaY>0?1.1:.9,s=t.getBoundingClientRect(),a=(e.clientX-s.left)/s.width,h=(e.clientY-s.top)/s.height,l=n.width*r,c=n.height*r;if(l<200||l>5e3)return;let _=n.x+(n.width-l)*a,y=n.y+(n.height-c)*h;this.viewBox_$.set({x:_,y,width:l,height:c})}handleFitToView(){let e=this.nodes_$();if(e.length===0)return;let t=P.recalculateViewBox(e,48);this.viewBox_$.set(t)}handleToggleFollowActive(){this.isFollowActive_$.update(e=>!e)}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=ae({type:i,selectors:[["app-ses-graph-view"]],viewQuery:function(t,n){if(t&1&&Ge($t,5),t&2){let r;Oe(r=Re())&&(n.svgRef=r.first)}},inputs:{layout:[1,"layout"],activeNodeId:[1,"activeNodeId"],selectedNodeId:[1,"selectedNodeId"],isLoading:[1,"isLoading"]},outputs:{nodeClicked:"nodeClicked",detailClosed:"detailClosed"},standalone:!0,features:[le],decls:25,vars:6,consts:[["graphSvg",""],[1,"flex","flex-col","h-full","w-full","overflow-hidden"],[1,"flex","items-center","gap-2","px-3","py-2","border-b","border-neutral-800","shrink-0","bg-neutral-900/80"],["title","Fit to view",1,"px-2","py-1","text-xs","border","rounded","transition-colors","border-neutral-700","text-neutral-400","hover:text-neutral-200","hover:border-neutral-500",3,"click"],["viewBox","0 0 24 24","fill","none","stroke","currentColor","stroke-width","2","stroke-linecap","round","stroke-linejoin","round",1,"w-3.5","h-3.5","inline-block","mr-1"],["d","M15 3h6v6M9 21H3v-6M21 3l-7 7M3 21l7-7"],["title","Follow active node",1,"px-2","py-1","text-xs","border","rounded","transition-colors",3,"click"],[1,"text-xs","text-neutral-500","ml-auto"],[1,"flex-1","min-h-0","relative"],["preserveAspectRatio","xMidYMid meet",1,"ses-graph-svg",3,"pointerdown","pointermove","pointerup","pointerleave","wheel"],["id","ses-arrow-seq","markerWidth","8","markerHeight","6","refX","8","refY","3","orient","auto","markerUnits","strokeWidth"],["d","M 0 0 L 8 3 L 0 6 Z","fill","#525252"],["id","ses-arrow-loop","markerWidth","8","markerHeight","6","refX","8","refY","3","orient","auto","markerUnits","strokeWidth"],["d","M 0 0 L 8 3 L 0 6 Z","fill","#3b82f6"],["id","ses-arrow-error","markerWidth","8","markerHeight","6","refX","8","refY","3","orient","auto","markerUnits","strokeWidth"],["d","M 0 0 L 8 3 L 0 6 Z","fill","#f97316"],["rx","6","fill","#0f172a","stroke","#1e3a5f","stroke-width","1","stroke-dasharray","4 2","opacity","0.5"],["stroke-width","1.5","fill","none"],["appSesGraphNodeSvg","",3,"node","isHighlighted","isSelected"],[1,"absolute","top-2","right-2","z-10",3,"node"],["appSesGraphNodeSvg","",3,"nodeClicked","node","isHighlighted","isSelected"],[1,"absolute","top-2","right-2","z-10",3,"closed","node"]],template:function(t,n){if(t&1){let r=ie();p(0,"div",1)(1,"div",2)(2,"button",3),B("click",function(){return R(r),z(n.handleFitToView())}),H(),p(3,"svg",4),W(4,"path",5),d(),m(5," Fit "),d(),ye(),p(6,"button",6),B("click",function(){return R(r),z(n.handleToggleFollowActive())}),m(7," Follow "),d(),D(8,bt,2,0,"span",7),d(),p(9,"div",8),H(),p(10,"svg",9,0),B("pointerdown",function(a){return R(r),z(n.handlePointerDown(a))})("pointermove",function(a){return R(r),z(n.handlePointerMove(a))})("pointerup",function(){return R(r),z(n.handlePointerUp())})("pointerleave",function(){return R(r),z(n.handlePointerUp())})("wheel",function(a){return R(r),z(n.handleWheel(a))}),p(12,"defs")(13,"marker",10),W(14,"path",11),d(),p(15,"marker",12),W(16,"path",13),d(),p(17,"marker",14),W(18,"path",15),d()(),D(19,Lt,1,4,":svg:rect",16),Le(20,wt,1,4,":svg:path",17,Qe),Le(22,Tt,1,3,":svg:g",18,Qe),d(),D(24,Mt,1,1,"app-ses-graph-node-detail",19),d()()}if(t&2){let r,s;u(6),se(n.isFollowActive_$()?"border-neonCyan/50 text-neonCyan bg-neonCyan/10":"border-neutral-700 text-neutral-400 hover:text-neutral-200 hover:border-neutral-500"),u(2),S(n.isLoading()?8:-1),u(2),Y("viewBox",n.viewBoxStr_$()),u(9),S((r=n.loopBounds_$())?19:-1,r),u(),we(n.edges_$()),u(2),we(n.nodes_$()),u(2),S((s=n.selectedNode_$())?24:-1,s)}},dependencies:[de,$e,Ke],styles:[`@charset "UTF-8";@keyframes _ngcontent-%COMP%_ses-graph-node-pulse{0%,to{filter:drop-shadow(0 0 4px var(--ses-graph-pulse-color, #22d3ee))}50%{filter:drop-shadow(0 0 12px var(--ses-graph-pulse-color, #22d3ee))}}[_nghost-%COMP%]{display:block;width:100%;height:100%;position:relative}.ses-graph-svg[_ngcontent-%COMP%]{width:100%;height:100%;background:#0a0a0a;-webkit-user-select:none;user-select:none} .ses-graph-node--active{animation:_ngcontent-%COMP%_ses-graph-node-pulse 1.5s ease-in-out infinite} .ses-graph-node--active rect{stroke-width:2.5} .ses-graph-node--selected{filter:drop-shadow(0 0 6px rgba(34,211,238,.4))}
1
+ import{c as Ce}from"./chunk-VQ4GBHH7.js";import{b as Ye}from"./chunk-COVCHZOZ.js";import{a as v}from"./chunk-UFBTR2BG.js";import{h as Be,i as Fe}from"./chunk-EVMDNGBK.js";import{I as Ve}from"./chunk-Y6V4NGLU.js";import{Aa as Oe,Ba as Re,C as Z,D as ae,Fa as m,Ga as L,Ha as _e,Ia as ze,J as R,K as z,L as H,M as ye,P as Pe,T as ne,Ta as le,U as F,Z as u,a as I,aa as V,b as w,da as D,fa as Y,ga as me,hb as g,ja as se,jb as Se,k as ke,la as S,oa as Le,p as be,pa as we,qa as p,ra as d,sa as W,ua as ie,ub as de,va as B,wa as C,xb as He,y as xe,za as Ge}from"./chunk-TBMJSIBB.js";var ve=class i{static getEmoji(o){let e=o.data??{},t=typeof e.step=="string"?e.step:"";return t==="run-initialization"?"\u{1F680}":t==="run-flow-complete"?"\u{1F3AF}":t==="tool-error-retry"?"\u26A0\uFE0F\u{1F9E0}":t.includes("tool-error")||t.includes("error-recovery")?"\u{1F527}\u274C":t.includes("agentic-loop-iteration")?"":o.eventType==="tool-call"||typeof e.toolId=="string"?"\u{1F527}":o.eventType==="llm-call"||typeof e.callType=="string"?"\u{1F9E0}":o.eventType==="error"?"\u26A0\uFE0F":""}static getBubbleClasses(o){let e=o.data??{},t=typeof e.step=="string"?e.step:"";return t==="run-initialization"||t==="run-flow-complete"?"bg-green-500/10 text-green-300 border border-green-500/50":t==="tool-error-retry"||t.includes("tool-error")||t.includes("error-recovery")?"bg-orange-500/10 text-orange-300 border border-orange-500/50":o.eventType==="error"||t.includes("circuit-breaker")?"bg-red-500/10 text-red-300 border border-red-500/50":t.includes("agentic-loop")?"bg-blue-500/10 text-blue-300 border border-blue-500/50":o.eventType==="tool-call"||typeof e.toolId=="string"?"bg-yellow-500/10 text-yellow-300 border border-yellow-500/50":o.eventType==="llm-call"||typeof e.callType=="string"?"bg-purple-500/10 text-purple-300 border border-purple-500/50":"bg-neutral-700 text-neutral-200 border border-neonCyan"}static getStepLabel(o){let e=o.data??{},t=e.step,n=e.toolId;if(typeof t=="string"&&t.length>0)return i.formatStepId(t);if(o.eventType==="tool-call"&&typeof n=="string"&&n.length>0)return`Eszk\xF6z: ${n}`;if(o.eventType==="llm-call"){let r=e.callType;return typeof r=="string"?`LLM: ${i.formatStepId(r)}`:"LLM h\xEDv\xE1s"}if(o.eventType==="error"){let r=e.message;return typeof r=="string"&&r.length>0?`Hiba: ${r.substring(0,40)}${r.length>40?"\u2026":""}`:"Hiba"}return o.eventType==="compacting"?typeof t=="string"&&t.length>0?i.formatStepId(t):"Compacting":i.formatEventTypeFallback(o.eventType)}static formatStepId(o){return o.split("-").map(e=>e.length>0?e.charAt(0).toUpperCase()+e.slice(1).toLowerCase():e).join(" ")}static getDotClasses(o){let e=o.data??{},t=typeof e.step=="string"?e.step:"";return t==="run-initialization"||t==="run-flow-complete"?"bg-green-400":t==="tool-error-retry"||t.includes("tool-error")||t.includes("error-recovery")?"bg-orange-400":o.eventType==="error"||t.includes("circuit-breaker")?"bg-red-400":t.includes("agentic-loop")?"bg-blue-400":o.eventType==="tool-call"||typeof e.toolId=="string"?"bg-yellow-400":o.eventType==="llm-call"||typeof e.callType=="string"?"bg-purple-400":"bg-neutral-400"}static formatEventTypeFallback(o){return{step:"L\xE9p\xE9s","tool-call":"Eszk\xF6zh\xEDv\xE1s","context-update":"Kontextus friss\xEDt\xE9s",compacting:"Compacting","llm-call":"LLM h\xEDv\xE1s","session-event":"Session event",error:"Hiba"}[o]??o}};var x=function(i){return i.pending="pending",i.active="active",i.completed="completed",i.error="error",i}(x||{});var tt={[v.runInitialization]:"milestone-init",[v.analyze]:"phase-analyze",[v.analyzeResult]:"llm-analyze",[v.assemble]:"phase-assemble",[v.execution]:"phase-execution",[v.executionStart]:"phase-execution",[v.finalization]:"phase-finalization",[v.llmRunFinalization]:"llm-finalization",[v.postFinalization]:"phase-finalization",[v.runFlowComplete]:"milestone-complete"},nt=["milestone-init","phase-analyze","llm-analyze","phase-assemble","phase-execution","phase-finalization","llm-finalization","milestone-complete"],N=class i{static mapPhaseToNodeId(o){return tt[o]??null}static computeStateTransitions(o){let e=i.mapPhaseToNodeId(o);if(!e)return[];let t=[],n=!1;for(let r of nt)r===e?(t.push({nodeId:r,state:x.active}),n=!0):n||t.push({nodeId:r,state:x.completed});return t}static extractIterationData(o){let e=o.action;if(typeof e!="string")return null;let t=o.tool,n=typeof t=="string"?t:"",r=o.intent,s=typeof r=="string"?r:"",a=o.iterationCount;return{actionType:e,tool:n,intent:s,iterationIndex:typeof a=="number"?a:0}}static mapMonitoringEventToIterationNodeId(o,e){let t=o.data??{},n=t.step,r=typeof n=="string"?n:"",s=`iter-${e}`;if(o.eventType==="llm-call"){let a=t.callType;if(a==="agentic-loop")return`${s}-llm-decision`;if(a==="tool-description")return`${s}-tool-desc`;if(a==="tool-error-retry")return`${s}-tool-error-retry`;if(a==="tool-result-chunking")return`${s}-tool-chunking`;if(a==="goal-state-update")return`${s}-goal-update`}return o.eventType==="tool-call"?`${s}-tool-call`:o.eventType==="error"||r.includes("tool-error")?`${s}-tool-call`:null}static isTerminalPhase(o){return o===v.runFlowComplete}static SKELETON_LLM_NODE_MAP={analyze:"llm-analyze","run-finalization":"llm-finalization"};static LLM_CALL_PHASE_MAP={analyze:"phase-analyze","subanalyze-run-tasks":"phase-analyze","instant-reply":"phase-execution","run-finalization":"phase-finalization","chat-history-compacting":"phase-execution","execution-history-compacting":"phase-execution","soul-compacting":"phase-execution","context-compacting":"phase-execution","message-interceptor":"phase-execution"};static ITERATION_LLM_CALL_TYPES=new Set(["agentic-loop","tool-description","tool-error-retry","tool-result-chunking","goal-state-update"]);static LLM_CALL_LABEL_MAP={analyze:"LLM: Analyze","subanalyze-run-tasks":"LLM: Subanalyze","instant-reply":"LLM: Instant Reply","agentic-loop":"LLM Decision","tool-description":"Tool Description","tool-error-retry":"LLM: Error Retry","run-finalization":"LLM: Summary","chat-history-compacting":"LLM: Compact Chat","execution-history-compacting":"LLM: Compact Exec","soul-compacting":"LLM: Compact Soul","context-compacting":"LLM: Compact Ctx","tool-result-chunking":"LLM: Chunking","goal-state-update":"LLM: Goal Update","message-interceptor":"LLM: Msg Intercept"};static getPreCreatedSkeletonNodeId(o){return i.SKELETON_LLM_NODE_MAP[o]??null}static getLlmCallPhaseId(o){return i.LLM_CALL_PHASE_MAP[o]??null}static isIterationLlmCall(o){return i.ITERATION_LLM_CALL_TYPES.has(o)}static getLlmCallLabel(o){return i.LLM_CALL_LABEL_MAP[o]??`LLM: ${o}`}};var k=function(i){return i.sequential="sequential",i.loopEntry="loop-entry",i.errorRetry="error-retry",i}(k||{});var f=function(i){return i.phase="phase",i.milestone="milestone",i.llmCall="llm-call",i.toolCall="tool-call",i.toolError="tool-error",i.loopIteration="loop-iteration",i.action="action",i.error="error",i}(f||{});var je="milestone-init",Ee="phase-analyze",it="llm-analyze",Me="phase-assemble",ee="phase-execution",he="phase-finalization",Ae="llm-finalization",De="milestone-complete",P=class i{static buildSkeletonLayout(){let o=48+220/2,e=48,t=[],n=[],r=i.createNode({id:je,category:f.milestone,label:"Initialization",phase:v.runInitialization,x:o-200/2,y:e,width:200,height:48});t.push(r),e+=84;let s=i.createNode({id:Ee,category:f.phase,label:"Analyze",phase:v.analyze,x:o-220/2,y:e,width:220,height:60});t.push(s);let a=i.createNode({id:it,category:f.llmCall,label:"LLM: Analyze",phase:v.analyzeResult,x:o+220/2+28,y:e+16/2,width:160,height:44,parentId:Ee});t.push(a),n.push(i.createEdge(je,Ee,k.sequential)),e+=96;let h=i.createNode({id:Me,category:f.phase,label:"Assemble",phase:v.assemble,x:o-220/2,y:e,width:220,height:60});t.push(h),n.push(i.createEdge(Ee,Me,k.sequential)),e+=96;let l=i.createNode({id:ee,category:f.phase,label:"Execution",phase:v.execution,x:o-220/2,y:e,width:220,height:60});t.push(l),n.push(i.createEdge(Me,ee,k.sequential)),e+=96;let c=i.createNode({id:he,category:f.phase,label:"Finalization",phase:v.finalization,x:o-220/2,y:e,width:220,height:60});t.push(c);let _=i.createNode({id:Ae,category:f.llmCall,label:"LLM: Summary",phase:v.llmRunFinalization,x:o+220/2+28,y:e+16/2,width:160,height:44,parentId:he});t.push(_),n.push(i.createEdge(ee,he,k.sequential)),e+=96;let y=i.createNode({id:De,category:f.milestone,label:"Flow Complete",phase:v.runFlowComplete,x:o-200/2,y:e,width:200,height:48});t.push(y),n.push(i.createEdge(he,De,k.sequential));let T=i.recalculateViewBox(t,48);return{nodes:t,edges:n,viewBox:T,loopContainerBounds:null}}static addIterationColumn(o,e,t,n){let r=o.nodes.map(b=>I({},b)),s=[...o.edges],a=r.find(b=>b.id===ee);if(!a)return o;let h=a.x+20+e*208,l=a.y+60+20,c=`iter-${e}`,_=l,y=[],T=i.createNode({id:`${c}-llm-decision`,category:f.llmCall,label:"LLM Decision",phase:v.llmAgenticLoop,x:h,y:_,width:160,height:44,parentId:ee,iterationIndex:e});y.push(T),_+=68;let M=i.formatActionLabel(t),O=i.createNode({id:`${c}-action`,category:f.action,label:M,phase:v.agenticLoopIteration,x:h+20/2,y:_,width:140,height:32,parentId:ee,iterationIndex:e,data:n});if(y.push(O),_+=56,t==="tool-select"){let b=i.createNode({id:`${c}-tool-desc`,category:f.llmCall,label:"Tool Description",phase:v.llmToolDescription,x:h,y:_,width:160,height:44,parentId:ee,iterationIndex:e});y.push(b),_+=68;let q=n.tool,Q=typeof q=="string"?q:"tool",te=i.createNode({id:`${c}-tool-call`,category:f.toolCall,label:Q,phase:null,x:h,y:_,width:160,height:44,parentId:ee,iterationIndex:e,data:n});y.push(te),_+=68}for(let b=0;b<y.length-1;b++)s.push(i.createEdge(y[b].id,y[b+1].id,k.sequential));r.push(...y);let E=20*2+(e+1)*180+e*28,j=60+20*2+(_-l);a.width=Math.max(a.width,E),a.height=Math.max(a.height,j);let K=a.y+a.height,A=[he,Ae,De],ue=K+36;for(let b of A){let q=r.find(Q=>Q.id===b);if(q){if(b===Ae){let Q=r.find(te=>te.id===he);Q&&(q.y=Q.y+16/2);continue}q.y=ue,ue+=q.height+36}}let ge={x:a.x,y:a.y+60,width:a.width,height:a.height-60},J=r,Je=s.map(b=>{let q=J.find(te=>te.id===b.sourceNodeId),Q=J.find(te=>te.id===b.targetNodeId);return!q||!Q?b:w(I({},b),{pathD:i.computeEdgePath(q,Q,b.category)})}),et=i.recalculateViewBox(J,48);return{nodes:J,edges:Je,viewBox:et,loopContainerBounds:ge}}static computeEdgePath(o,e,t){let n=o.x+o.width/2,r=o.y+o.height,s=e.x+e.width/2,a=e.y;if(Math.abs(n-s)<20)return`M ${n} ${r} L ${s} ${a}`;let h=o.x+o.width,l=o.y+o.height/2,c=e.x,_=e.y+e.height/2;if(e.parentId===o.id)return`M ${h} ${l} L ${c} ${_}`;let y=r+(a-r)/2;return`M ${n} ${r} L ${n} ${y} L ${s} ${y} L ${s} ${a}`}static recalculateViewBox(o,e){if(o.length===0)return{x:0,y:0,width:600,height:400};let t=1/0,n=1/0,r=-1/0,s=-1/0;for(let a of o)t=Math.min(t,a.x),n=Math.min(n,a.y),r=Math.max(r,a.x+a.width),s=Math.max(s,a.y+a.height);return{x:t-e,y:n-e,width:r-t+e*2,height:s-n+e*2}}static addDynamicLlmNode(o,e,t,n,r,s){let a=o.nodes.map(A=>I({},A)),h=[...o.edges],l=a.find(A=>A.id===e);if(!l)return o;let c,_;l.category===f.phase||l.category===f.milestone?(c=l.x+l.width+28,_=l.y+(l.height-44)/2):(c=l.x,_=l.y+l.height+24);let T=i.createNode({id:t,category:f.llmCall,label:n,phase:null,x:c,y:_,width:160,height:44,parentId:r,iterationIndex:s??void 0});a.push(T),h.push(i.createEdge(e,t,k.sequential));let M=T.y+T.height;s!=null?i.expandExecutionContainer(a,M):i.shiftDownstreamIfOverlap(a,r,M);let O=o.loopContainerBounds,E=a.find(A=>A.id==="phase-execution");E&&E.height>60&&(O={x:E.x,y:E.y+60,width:E.width,height:E.height-60});let j=h.map(A=>{let ue=a.find(J=>J.id===A.sourceNodeId),ge=a.find(J=>J.id===A.targetNodeId);return!ue||!ge?A:w(I({},A),{pathD:i.computeEdgePath(ue,ge,A.category)})}),K=i.recalculateViewBox(a,48);return{nodes:a,edges:j,viewBox:K,loopContainerBounds:O}}static expandExecutionContainer(o,e){let t=o.find(l=>l.id==="phase-execution");if(!t)return;let n=t.y+60+20,r=60+20*2+(e+24-n);if(r<=t.height)return;t.height=r;let s=t.y+t.height,a=["phase-finalization","llm-finalization","milestone-complete"],h=s+36;for(let l of a){let c=o.find(_=>_.id===l);if(c){if(l==="llm-finalization"){let _=o.find(y=>y.id==="phase-finalization");_&&(c.y=_.y+16/2);continue}c.y<h&&(c.y=h),h=c.y+c.height+36}}for(let l of o)if(l.parentId==="phase-finalization"&&l.id!=="llm-finalization"&&l.category===f.llmCall){let c=o.find(_=>_.id==="phase-finalization");c&&(l.y=Math.max(l.y,c.y))}}static shiftDownstreamIfOverlap(o,e,t){let n=["milestone-init","phase-analyze","phase-assemble","phase-execution","phase-finalization","milestone-complete"],r=n.indexOf(e);if(r<0||r>=n.length-1)return;let s=n[r+1],a=o.find(_=>_.id===s);if(!a||t+36<=a.y)return;let h=t+36-a.y,l=new Set;for(let _ of o)_.parentId===e&&_.category===f.llmCall&&l.add(_.id);let c=a.y;for(let _ of o)_.y>=c&&!l.has(_.id)&&(_.y+=h)}static createNode(o){return{id:o.id,category:o.category,state:x.pending,label:o.label,phase:o.phase,x:o.x,y:o.y,width:o.width,height:o.height,data:o.data??{},iterationIndex:o.iterationIndex??null,parentId:o.parentId??null,monitoringEvent:null}}static createEdge(o,e,t){let n=t===k.errorRetry?"#f97316":t===k.loopEntry?"#3b82f6":"#525252",r=t===k.loopEntry?"8 4":t===k.errorRetry?"6 3":"none",s=t===k.errorRetry?"url(#ses-arrow-error)":t===k.loopEntry?"url(#ses-arrow-loop)":"url(#ses-arrow-seq)";return{id:`edge-${o}-${e}`,category:t,sourceNodeId:o,targetNodeId:e,pathD:"",strokeColor:n,strokeDashArray:r,markerEnd:s}}static formatActionLabel(o){return{"tool-select":"Tool Select","tool-group-open":"Tool Group","context-handling":"Context","loop-debrief":"Debrief",result:"Result"}[o]??o}};var qe=(()=>{class i{baseUrl=`${Ve.api.baseUrl}/session`;http=Z(He);getEvents(e){let t=encodeURIComponent(e.trim());return be(this.http.get(`${this.baseUrl}/${t}/events`))}getRunTrace(e){let t=e.sessionId.trim(),n=encodeURIComponent(e.runId.trim());return be(this.http.get(`${this.baseUrl}/${encodeURIComponent(t)}/runs/${n}/trace`))}static \u0275fac=function(t){return new(t||i)};static \u0275prov=xe({token:i,factory:i.\u0275fac,providedIn:"root"})}return i})();var Ze=(()=>{class i{session_DS=Z(Ce);monitoring_AS=Z(qe);destroyRef=Z(Pe);graphLayout_$=V(null);activeNodeId_$=V("");selectedNodeId_$=V("");isLive_$=V(!1);isGraphOpen_$=V(!1);graphSessionId_$=V("");graphRunId_$=V("");isLoading_$=V(!1);currentIterationIndex=-1;monitoringSubscription=null;lastAppliedPhase="";phaseRightColumnLast={};iterationColumnLast={};dynamicNodeCounter=0;constructor(){Se(()=>{let e=this.session_DS.agentEvents_$();!this.isGraphOpen_$()||!this.isLive_$()||this.applyAgentEvent(e)},{allowSignalWrites:!0}),this.destroyRef.onDestroy(()=>{this.disposeSubscriptions()})}openGraphForRun(e,t,n){this.disposeSubscriptions(),this.resetState(),this.graphSessionId_$.set(e),this.graphRunId_$.set(t),this.isLive_$.set(n),this.isGraphOpen_$.set(!0),n?this.initLiveGraph():this.loadHistoricalGraph(e,t)}closeGraph(){this.disposeSubscriptions(),this.isGraphOpen_$.set(!1),this.selectedNodeId_$.set("")}selectNode(e){let t=this.selectedNodeId_$();this.selectedNodeId_$.set(t===e?"":e)}clearSelection(){this.selectedNodeId_$.set("")}initLiveGraph(){let e=P.buildSkeletonLayout(),t=this.recalculateEdgePaths(e);this.graphLayout_$.set(t),this.phaseRightColumnLast={"phase-analyze":"llm-analyze","phase-finalization":"llm-finalization"},this.iterationColumnLast={},this.monitoringSubscription=this.session_DS.monitoringEvent_S.subscribe(n=>{n.sessionId===this.graphSessionId_$()&&this.applyMonitoringEvent(n.event)})}applyAgentEvent(e){let t=e.phase;if(typeof t!="string"||t.length===0||t===this.lastAppliedPhase)return;if(this.lastAppliedPhase=t,t===v.agenticLoopIteration){let r=N.extractIterationData(e);r&&this.addIteration(r);return}let n=N.computeStateTransitions(t);n.length!==0&&(this.applyStateTransitions(n),N.isTerminalPhase(t)&&this.markAllIterationNodesCompleted())}addIteration(e){let t=this.graphLayout_$();if(!t)return;this.currentIterationIndex=e.iterationIndex,this.markPreviousIterationCompleted(e.iterationIndex);let n=P.addIterationColumn(t,e.iterationIndex,e.actionType,{tool:e.tool,intent:e.intent}),r=e.actionType==="tool-select"?`iter-${e.iterationIndex}-tool-call`:`iter-${e.iterationIndex}-action`;this.iterationColumnLast[e.iterationIndex]=r;let s=`iter-${e.iterationIndex}-llm-decision`,a=this.setNodeState(n,s,x.active);this.activeNodeId_$.set(s),this.graphLayout_$.set(this.recalculateEdgePaths(a))}markPreviousIterationCompleted(e){if(e<=0)return;let t=this.graphLayout_$();if(!t)return;let n=`iter-${e-1}`,r=t;for(let s of t.nodes)s.id.startsWith(n)&&s.state!==x.error&&(r=this.setNodeState(r,s.id,x.completed));this.graphLayout_$.set(r)}applyMonitoringEvent(e){let t=this.graphLayout_$();if(!t)return;let n=typeof e.eventType=="string"?e.eventType:"",r=typeof e.status=="string"?e.status:"",s=i.toRecord(e.data),a=typeof e.durationMs=="number"?e.durationMs:0,h=typeof e.inputSize=="number"?e.inputSize:0,l=typeof e.outputSize=="number"?e.outputSize:0,c={eventType:n,timestamp:new Date,data:s,durationMs:a,status:r,sessionId:this.graphSessionId_$(),runId:this.graphRunId_$(),inputSize:h,outputSize:l};if(n==="llm-call"){this.handleLlmCallMonitoringEvent(c,t);return}if(this.currentIterationIndex<0)return;let _=N.mapMonitoringEventToIterationNodeId(c,this.currentIterationIndex);if(!_)return;let y=this.enrichNodeWithMonitoringEvent(t,_,c);y&&this.graphLayout_$.set(y)}handleLlmCallMonitoringEvent(e,t){let n=e.data?.callType,r=typeof n=="string"?n:"";if(!r)return;let s=N.getPreCreatedSkeletonNodeId(r);if(s){let h=this.enrichNodeWithMonitoringEvent(t,s,e);h&&this.graphLayout_$.set(h);return}if(N.isIterationLlmCall(r)&&this.currentIterationIndex>=0){let h=N.mapMonitoringEventToIterationNodeId(e,this.currentIterationIndex);if(h){if(t.nodes.findIndex(c=>c.id===h)>=0){let c=this.enrichNodeWithMonitoringEvent(t,h,e);c&&this.graphLayout_$.set(c)}else this.createDynamicIterationLlmNode(t,r,h,e);return}}let a=N.getLlmCallPhaseId(r);a&&this.createDynamicSkeletonLlmNode(t,r,a,e)}enrichNodeWithMonitoringEvent(e,t,n){let r=e.nodes.findIndex(_=>_.id===t);if(r<0)return null;let s=n.data??{},a=n.status==="error",h=n.durationMs??0,l=a?x.error:h>0?x.completed:x.active,c=[...e.nodes];return c[r]=w(I({},c[r]),{state:l,monitoringEvent:n,data:w(I(I({},c[r].data),s),{durationMs:h})}),this.activeNodeId_$.set(l===x.active?t:""),w(I({},e),{nodes:c})}createDynamicSkeletonLlmNode(e,t,n,r){this.dynamicNodeCounter++;let s=`llm-dyn-${this.dynamicNodeCounter}`,a=N.getLlmCallLabel(t),h=this.phaseRightColumnLast[n]??n,l=P.addDynamicLlmNode(e,h,s,a,n,null);this.phaseRightColumnLast[n]=s;let c=this.enrichNodeWithMonitoringEvent(l,s,r);this.graphLayout_$.set(c??l)}createDynamicIterationLlmNode(e,t,n,r){let s=N.getLlmCallLabel(t),a=this.iterationColumnLast[this.currentIterationIndex]??`iter-${this.currentIterationIndex}-action`,h=P.addDynamicLlmNode(e,a,n,s,"phase-execution",this.currentIterationIndex);this.iterationColumnLast[this.currentIterationIndex]=n;let l=this.enrichNodeWithMonitoringEvent(h,n,r);this.graphLayout_$.set(l??h)}loadHistoricalGraph(e,t){return ke(this,null,function*(){this.isLoading_$.set(!0);try{let n=yield this.monitoring_AS.getRunTrace({sessionId:e,runId:t});this.buildHistoricalGraph(n.trace)}catch{let n=P.buildSkeletonLayout();this.graphLayout_$.set(this.recalculateEdgePaths(n))}finally{this.isLoading_$.set(!1)}})}buildHistoricalGraph(e){let t=P.buildSkeletonLayout();t=this.recalculateEdgePaths(t);let n="",r=-1,s={"phase-analyze":"llm-analyze","phase-finalization":"llm-finalization"},a={},h=0;for(let l of e){let c=l.data??{},_=c.step,y=typeof _=="string"?_:"";if(y.length>0&&N.mapPhaseToNodeId(y)&&y!==n){n=y;let M=N.computeStateTransitions(y);for(let O of M)t=this.setNodeState(t,O.nodeId,O.state)}if(y==="agentic-loop-iteration"||y.includes("agentic-loop")){let T=c.action,M=typeof T=="string"?T:"",O=c.tool,E=typeof O=="string"?O:"";if(M.length>0){r++,t=P.addIterationColumn(t,r,M,{tool:E});let j=M==="tool-select"?`iter-${r}-tool-call`:`iter-${r}-action`;a[r]=j}}if(l.eventType==="llm-call"){let T=c.callType,M=typeof T=="string"?T:"";if(M){let O=N.getPreCreatedSkeletonNodeId(M);if(O)t=this.enrichHistoricalNode(t,O,l,c);else if(N.isIterationLlmCall(M)&&r>=0){let E=N.mapMonitoringEventToIterationNodeId(l,r);if(E)if(t.nodes.findIndex(K=>K.id===E)>=0)t=this.enrichHistoricalNode(t,E,l,c);else{let K=N.getLlmCallLabel(M),A=a[r]??`iter-${r}-action`;t=P.addDynamicLlmNode(t,A,E,K,"phase-execution",r),t=this.enrichHistoricalNode(t,E,l,c),a[r]=E}}else{let E=N.getLlmCallPhaseId(M);if(E){h++;let j=`llm-dyn-${h}`,K=N.getLlmCallLabel(M),A=s[E]??E;t=P.addDynamicLlmNode(t,A,j,K,E,null),t=this.enrichHistoricalNode(t,j,l,c),s[E]=j}}}continue}if(r>=0){let T=N.mapMonitoringEventToIterationNodeId(l,r);T&&(t=this.enrichHistoricalNode(t,T,l,c))}}if(n===v.runFlowComplete)for(let l of t.nodes)l.state===x.pending&&(t=this.setNodeState(t,l.id,x.completed));this.graphLayout_$.set(this.recalculateEdgePaths(t))}enrichHistoricalNode(e,t,n,r){let s=e.nodes.findIndex(h=>h.id===t);if(s<0)return e;let a=[...e.nodes];return a[s]=w(I({},a[s]),{state:n.status==="error"?x.error:x.completed,monitoringEvent:n,data:w(I(I({},a[s].data),r),{durationMs:n.durationMs})}),w(I({},e),{nodes:a})}applyStateTransitions(e){let t=this.graphLayout_$();if(!t)return;let n="";for(let r of e)t=this.setNodeState(t,r.nodeId,r.state),r.state===x.active&&(n=r.nodeId);this.activeNodeId_$.set(n),this.graphLayout_$.set(t)}setNodeState(e,t,n){let r=e.nodes.findIndex(a=>a.id===t);if(r<0)return e;let s=[...e.nodes];return s[r]=w(I({},s[r]),{state:n}),w(I({},e),{nodes:s})}markAllIterationNodesCompleted(){let e=this.graphLayout_$();if(!e)return;let t=e;for(let n of e.nodes)n.iterationIndex!=null&&n.state!==x.error&&(t=this.setNodeState(t,n.id,x.completed));this.graphLayout_$.set(t)}recalculateEdgePaths(e){let t=e.edges.map(n=>{let r=e.nodes.find(a=>a.id===n.sourceNodeId),s=e.nodes.find(a=>a.id===n.targetNodeId);return!r||!s?n:w(I({},n),{pathD:P.computeEdgePath(r,s,n.category)})});return w(I({},e),{edges:t})}resetState(){this.graphLayout_$.set(null),this.activeNodeId_$.set(""),this.selectedNodeId_$.set(""),this.currentIterationIndex=-1,this.lastAppliedPhase="",this.isLoading_$.set(!1),this.dynamicNodeCounter=0,this.phaseRightColumnLast={},this.iterationColumnLast={}}disposeSubscriptions(){this.monitoringSubscription&&(this.monitoringSubscription.unsubscribe(),this.monitoringSubscription=null)}static toRecord(e){return typeof e!="object"||e==null?{}:JSON.parse(JSON.stringify(e))}static \u0275fac=function(t){return new(t||i)};static \u0275prov=xe({token:i,factory:i.\u0275fac,providedIn:"root"})}return i})();var ot=["appSesGraphNodeSvg",""];function rt(i,o){if(i&1&&(H(),p(0,"text",1),m(1),d()),i&2){let e=C();Y("x",10)("y",e.node().height/2+1),u(),L(e.icon_$())}}function at(i,o){if(i&1&&(H(),p(0,"text",3),m(1),d()),i&2){let e=C();Y("x",e.node().width-10)("y",12)("fill",e.node().state==="error"?"#ef4444":"#22c55e"),u(),L(e.stateIcon_$())}}function st(i,o){if(i&1&&(H(),p(0,"text",4),m(1),d()),i&2){let e=C();Y("x",e.node().width-8)("y",e.node().height-8),u(),_e("",e.durationMs_$(),"ms")}}var $e=class i{node=F.required();isHighlighted=F(!1);isSelected=F(!1);nodeClicked=ne();fillColor_$=g(()=>{let o=this.node();return o.state===x.pending?"#262626":i.CATEGORY_FILL_MAP[o.category]??"#262626"});strokeColor_$=g(()=>{let o=this.node();return o.state===x.error?"#ef4444":o.state===x.pending?"#525252":i.CATEGORY_STROKE_MAP[o.category]??"#737373"});strokeDashArray_$=g(()=>this.node().state===x.pending?"6 3":"none");textColor_$=g(()=>this.node().state===x.pending?"#737373":"#e5e5e5");opacity_$=g(()=>this.node().state===x.pending?.5:1);borderRadius_$=g(()=>this.node().category===f.action?16:8);icon_$=g(()=>{let o=this.node().category;return i.CATEGORY_ICON_MAP[o]??""});stateIcon_$=g(()=>{let o=this.node().state;return o===x.completed?"\u2713":o===x.error?"\u2715":""});animationClass_$=g(()=>this.node().state===x.active||this.isHighlighted()?"ses-graph-node--active":this.isSelected()?"ses-graph-node--selected":"");durationMs_$=g(()=>this.node().data.durationMs??0);handleClick(){this.nodeClicked.emit(this.node().id)}static CATEGORY_FILL_MAP={[f.phase]:"#1a1a2e",[f.milestone]:"#052e16",[f.llmCall]:"#1e1033",[f.toolCall]:"#2e2a05",[f.toolError]:"#2e1505",[f.loopIteration]:"#0a1628",[f.action]:"#1a1a2e",[f.error]:"#2e0505"};static CATEGORY_STROKE_MAP={[f.phase]:"#525252",[f.milestone]:"#22c55e",[f.llmCall]:"#a855f7",[f.toolCall]:"#eab308",[f.toolError]:"#f97316",[f.loopIteration]:"#3b82f6",[f.action]:"#3b82f6",[f.error]:"#ef4444"};static CATEGORY_ICON_MAP={[f.milestone]:"\u26A1",[f.llmCall]:"\u{1F9E0}",[f.toolCall]:"\u{1F527}",[f.toolError]:"\u26A0\uFE0F",[f.error]:"\u274C"};static \u0275fac=function(e){return new(e||i)};static \u0275cmp=ae({type:i,selectors:[["","appSesGraphNodeSvg",""]],inputs:{node:[1,"node"],isHighlighted:[1,"isHighlighted"],isSelected:[1,"isSelected"]},outputs:{nodeClicked:"nodeClicked"},standalone:!0,features:[le],attrs:ot,decls:7,vars:21,consts:[[2,"cursor","pointer",3,"click"],["dominant-baseline","central","text-anchor","start","font-size","14"],["dominant-baseline","central"],["text-anchor","end","dominant-baseline","central","font-size","11","font-weight","700"],["text-anchor","end","dominant-baseline","auto","fill","#737373","font-size","9"]],template:function(e,t){e&1&&(H(),p(0,"g",0),B("click",function(){return t.handleClick()}),W(1,"rect"),D(2,rt,2,3,":svg:text",1),p(3,"text",2),m(4),d(),D(5,at,2,4,":svg:text",3)(6,st,2,3,":svg:text",4),d()),e&2&&(se(t.animationClass_$()),Y("transform","translate("+t.node().x+","+t.node().y+")")("opacity",t.opacity_$()),u(),Y("width",t.node().width)("height",t.node().height)("rx",t.borderRadius_$())("fill",t.fillColor_$())("stroke",t.strokeColor_$())("stroke-width",t.isSelected()?2.5:1.5)("stroke-dasharray",t.strokeDashArray_$()),u(),S(t.icon_$()?2:-1),u(),Y("x",t.icon_$()?30:t.node().width/2)("y",t.node().height/2+1)("text-anchor",t.icon_$()?"start":"middle")("fill",t.textColor_$())("font-size",t.node().category==="phase"||t.node().category==="milestone"?14:12)("font-weight",t.node().category==="phase"||t.node().category==="milestone"?600:400),u(),L(t.node().label),u(),S(t.stateIcon_$()?5:-1),u(),S(t.durationMs_$()?6:-1))},dependencies:[de],encapsulation:2})};function lt(i,o){if(i&1&&(p(0,"div",7)(1,"span",8),m(2,"Phase"),d(),p(3,"span",9),m(4),d()()),i&2){let e=C();u(4),L(e.node().phase)}}function dt(i,o){if(i&1&&(p(0,"div",7)(1,"span",8),m(2,"Step"),d(),p(3,"span",9),m(4),d()()),i&2){let e=C();u(4),L(e.stepLabel_$())}}function ct(i,o){if(i&1&&(p(0,"div",7)(1,"span",8),m(2,"Duration"),d(),p(3,"span",9),m(4),d()()),i&2){let e=C();u(4),L(e.durationLabel_$())}}function pt(i,o){if(i&1&&(p(0,"div",7)(1,"span",8),m(2,"Tool"),d(),p(3,"span",12),m(4),d()()),i&2){let e=C();u(4),L(e.toolId_$())}}function ht(i,o){if(i&1&&(p(0,"div",10)(1,"span",13),m(2,"Intent"),d(),p(3,"span",14),m(4),d()()),i&2){let e=C();u(4),L(e.intent_$())}}function ut(i,o){if(i&1&&(p(0,"div",7)(1,"span",8),m(2,"Iteration"),d(),p(3,"span",15),m(4),d()()),i&2){let e=C();u(4),_e("#",e.node().iterationIndex,"")}}function mt(i,o){if(i&1&&(p(0,"span",13),m(1," In: "),p(2,"span",9),m(3),d()()),i&2){let e=C(2);u(3),L(e.inputSize_$())}}function _t(i,o){if(i&1&&(p(0,"span",13),m(1," Out: "),p(2,"span",9),m(3),d()()),i&2){let e=C(2);u(3),L(e.outputSize_$())}}function ft(i,o){if(i&1&&(p(0,"div",11),D(1,mt,4,1,"span",13)(2,_t,4,1,"span",13),d()),i&2){let e=C();u(),S(e.inputSize_$()>0?1:-1),u(),S(e.outputSize_$()>0?2:-1)}}function gt(i,o){if(i&1&&(p(0,"div",7)(1,"span",8),m(2,"Provider"),d(),p(3,"span",26),m(4),d()()),i&2){let e=C(3);u(4),L(e.usedProvider_$())}}function xt(i,o){if(i&1&&(p(0,"div",7)(1,"span",8),m(2,"Model"),d(),p(3,"span",26),m(4),d()()),i&2){let e=C(3);u(4),L(e.usedModel_$())}}function yt(i,o){if(i&1&&(p(0,"span",13),m(1," Cost: "),p(2,"span",27),m(3),d()()),i&2){let e=C(4);u(3),L(e.costUsd_$())}}function St(i,o){if(i&1&&(p(0,"div",25)(1,"span",13),m(2," Tokens: "),p(3,"span",9),m(4),d()(),D(5,yt,4,1,"span",13),d()),i&2){let e=C(3);u(4),L(e.tokenInfo_$().total),u(),S(e.costUsd_$()?5:-1)}}function Ct(i,o){if(i&1&&(p(0,"div",16)(1,"div",23),m(2,"Used"),d(),p(3,"div",24),D(4,gt,5,1,"div",7)(5,xt,5,1,"div",7)(6,St,6,2,"div",25),d()()),i&2){let e=C(2);u(4),S(e.usedProvider_$()?4:-1),u(),S(e.usedModel_$()?5:-1),u(),S(e.tokenInfo_$()?6:-1)}}function vt(i,o){if(i&1){let e=ie();p(0,"button",28),B("click",function(){R(e);let n=C(2);return z(n.handleClearOverride())}),m(1," Clear "),d()}}function It(i,o){i&1&&(p(0,"div",21),m(1," Session override active "),d())}function Et(i,o){if(i&1&&(p(0,"div",22)(1,"div",29),m(2,"Global default"),d(),p(3,"div",30),m(4),d()()),i&2){let e=C(2);u(4),ze(" ",e.globalDefault_$().provider," / ",e.globalDefault_$().model," ")}}function Nt(i,o){if(i&1){let e=ie();D(0,Ct,7,3,"div",16),p(1,"div",16)(2,"div",17)(3,"div",18),m(4),d(),D(5,vt,2,0,"button",19),d(),p(6,"app-s-registry-provider-model-select",20),B("modelChange",function(n){R(e);let r=C();return z(r.handleModelChange(n))}),d(),D(7,It,2,0,"div",21),d(),D(8,Et,5,2,"div",22)}if(i&2){let e=C();S(e.usedProvider_$()||e.usedModel_$()?0:-1),u(4),_e(" Override: ",e.callTypeLabel_$()," "),u(),S(e.hasSessionOverride_$()?5:-1),u(),me("selectedProvider",e.selectedProvider_$())("selectedModel",e.selectedModel_$()),u(),S(e.hasSessionOverride_$()?7:-1),u(),S(e.globalDefault_$()?8:-1)}}var Ke=(()=>{class i{graph_DS=Z(Ze);session_DS=Z(Ce);registrySsot_CS=Z(Be);node=F.required();closed=ne();stateLabel_$=g(()=>({pending:"Pending",active:"Active",completed:"Completed",error:"Error"})[this.node().state]??this.node().state);durationLabel_$=g(()=>{let e=this.node().data.durationMs;return!e||e<=0?"":e<1e3?`${Math.round(e)}ms`:`${(e/1e3).toFixed(1)}s`});toolId_$=g(()=>{let e=this.node().data,t=e.toolId??e.tool;return typeof t=="string"?t:""});intent_$=g(()=>{let e=this.node().data.intent;return typeof e=="string"?e:""});stepLabel_$=g(()=>{let e=this.node().data.step;return typeof e!="string"||e.length===0?"":ve.formatStepId(e)});inputSize_$=g(()=>{let e=this.node().monitoringEvent;return e?e.inputSize??0:0});outputSize_$=g(()=>{let e=this.node().monitoringEvent;return e?e.outputSize??0:0});stateColorClass_$=g(()=>({pending:"text-neutral-500",active:"text-cyan-400",completed:"text-green-400",error:"text-red-400"})[this.node().state]??"text-neutral-400");isLlmCall_$=g(()=>this.node().category===f.llmCall);callType_$=g(()=>{let e=this.node().data?.callType;return typeof e=="string"?e:""});callTypeLabel_$=g(()=>{let e=this.callType_$();return Ye[e]??e});usedProvider_$=g(()=>{let e=this.node().data?.provider;return typeof e=="string"?e:""});usedModel_$=g(()=>{let e=this.node().data?.model;return typeof e=="string"?e:""});sessionOverride_$=g(()=>{let e=this.callType_$();if(!e)return null;let t=this.graph_DS.graphSessionId_$();if(!t)return null;let r=this.session_DS.sessionInfoMap_$().get(t);if(!r)return null;let s=r.llmCallTypeOverrides;if(!s)return null;let a=s[e];if(typeof a!="object"||!a)return null;let h=a,l=h.provider,c=h.model;return typeof l=="string"&&typeof c=="string"?{provider:l,model:c}:null});globalDefault_$=g(()=>{let e=this.callType_$();if(!e)return null;let t=this.graph_DS.graphSessionId_$(),r=this.session_DS.sessionInfoMap_$().get(t);if(!r)return null;let s=r.globalCallTypeDefaults;if(!s)return null;let a=s[e];if(typeof a!="object"||!a)return null;let h=a,l=h.provider,c=h.model;return typeof l=="string"&&typeof c=="string"?{provider:l,model:c}:null});selectedProvider_$=g(()=>this.sessionOverride_$()?.provider??"");selectedModel_$=g(()=>this.sessionOverride_$()?.model??"");hasSessionOverride_$=g(()=>this.sessionOverride_$()!==null);tokenInfo_$=g(()=>{let e=this.node().data,t=e.promptTokens,n=e.completionTokens,r=e.totalTokens;return typeof r!="number"||r<=0?null:{prompt:typeof t=="number"?t:0,completion:typeof n=="number"?n:0,total:r}});costUsd_$=g(()=>{let e=this.node().data?.costUsd;return typeof e!="number"||e<=0?"":`$${e.toFixed(4)}`});handleClose(){this.closed.emit()}handleProviderChange(e){}handleModelChange(e){let t=this.callType_$(),n=this.graph_DS.graphSessionId_$();if(!t||!n||!e)return;let s=this.registrySsot_CS.enabledLlmModels_$().find(a=>a.modelName===e);s&&this.applySessionOverride(n,t,s.provider,s.modelName)}handleClearOverride(){let e=this.callType_$(),t=this.graph_DS.graphSessionId_$();!e||!t||this.clearSessionOverride(t,e)}applySessionOverride(e,t,n,r){let h=this.session_DS.sessionInfoMap_$().get(e)?.llmCallTypeOverrides??{},l=w(I({},h),{[t]:{provider:n,model:r}});this.session_DS.updateSession({sessionId:e,updates:{llmCallTypeOverrides:l}}).then(()=>{this.session_DS.loadSessionInfo(e)})}clearSessionOverride(e,t){let s=this.session_DS.sessionInfoMap_$().get(e)?.llmCallTypeOverrides??{},a=I({},s);Reflect.deleteProperty(a,t);let h=Object.keys(a).length>0;this.session_DS.updateSession({sessionId:e,updates:{llmCallTypeOverrides:h?a:null}}).then(()=>{this.session_DS.loadSessionInfo(e)})}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=ae({type:i,selectors:[["app-ses-graph-node-detail"]],inputs:{node:[1,"node"]},outputs:{closed:"closed"},standalone:!0,features:[le],decls:26,vars:13,consts:[[1,"w-80","max-h-[28rem]","overflow-y-auto","rounded-lg","border","border-neonCyan/30","bg-neutral-900/95","shadow-lg","backdrop-blur-sm","p-3"],[1,"flex","items-start","justify-between","gap-2","mb-2"],[1,"text-sm","font-semibold","text-neutral-200","leading-tight"],["title","Bez\xE1r\xE1s","aria-label","Bez\xE1r\xE1s",1,"p-1","min-h-[28px]","min-w-[28px]","flex","items-center","justify-center","rounded","text-neutral-400","hover:text-neutral-200","hover:bg-neutral-700","transition-colors","shrink-0",3,"click"],["viewBox","0 0 24 24","fill","none","stroke","currentColor","stroke-width","2","stroke-linecap","round","stroke-linejoin","round",1,"w-3.5","h-3.5"],["d","M18 6L6 18M6 6l12 12"],[1,"space-y-1.5","text-xs"],[1,"flex","items-center","gap-2"],[1,"text-neutral-500","w-16","shrink-0"],[1,"text-neutral-300"],[1,"flex","flex-col","gap-0.5"],[1,"flex","items-center","gap-3","pt-1","border-t","border-neutral-800"],[1,"text-yellow-300","font-mono","text-[11px]"],[1,"text-neutral-500"],[1,"text-neutral-300","text-[11px]","leading-tight","break-words"],[1,"text-blue-400"],[1,"mt-3","pt-2","border-t","border-neutral-700"],[1,"flex","items-center","justify-between","mb-1.5"],[1,"text-[10px]","text-neutral-500","uppercase","tracking-wider"],[1,"text-[10px]","text-red-400","hover:text-red-300","transition-colors"],["registryKind","llm","providerLabel","Provider","modelLabel","Model",3,"modelChange","selectedProvider","selectedModel"],[1,"mt-1.5","text-[10px]","text-purple-400"],[1,"mt-2","pt-1.5","border-t","border-neutral-800"],[1,"text-[10px]","text-neutral-500","uppercase","tracking-wider","mb-1.5"],[1,"space-y-1","text-xs"],[1,"flex","items-center","gap-3"],[1,"text-purple-300","font-mono","text-[11px]"],[1,"text-green-400"],[1,"text-[10px]","text-red-400","hover:text-red-300","transition-colors",3,"click"],[1,"text-[10px]","text-neutral-500","uppercase","tracking-wider","mb-1"],[1,"text-[11px]","text-neutral-400","font-mono"]],template:function(t,n){t&1&&(p(0,"div",0)(1,"div",1)(2,"h3",2),m(3),d(),p(4,"button",3),B("click",function(){return n.handleClose()}),H(),p(5,"svg",4),W(6,"path",5),d()()(),ye(),p(7,"div",6)(8,"div",7)(9,"span",8),m(10,"State"),d(),p(11,"span"),m(12),d()(),p(13,"div",7)(14,"span",8),m(15,"Type"),d(),p(16,"span",9),m(17),d()(),D(18,lt,5,1,"div",7)(19,dt,5,1,"div",7)(20,ct,5,1,"div",7)(21,pt,5,1,"div",7)(22,ht,5,1,"div",10)(23,ut,5,1,"div",7)(24,ft,3,2,"div",11),d(),D(25,Nt,9,7),d()),t&2&&(u(3),L(n.node().label),u(8),se(n.stateColorClass_$()+" font-medium"),u(),L(n.stateLabel_$()),u(5),L(n.node().category),u(),S(n.node().phase?18:-1),u(),S(n.stepLabel_$()?19:-1),u(),S(n.durationLabel_$()?20:-1),u(),S(n.toolId_$()?21:-1),u(),S(n.intent_$()?22:-1),u(),S(n.node().iterationIndex!==null?23:-1),u(),S(n.inputSize_$()>0||n.outputSize_$()>0?24:-1),u(),S(n.isLlmCall_$()&&n.callType_$()?25:-1))},dependencies:[de,Fe],encapsulation:2})}return i})();var $t=["graphSvg"],Qe=(i,o)=>o.id;function bt(i,o){i&1&&(p(0,"span",7),m(1,"Loading trace..."),d())}function Lt(i,o){if(i&1&&(H(),W(0,"rect",16)),i&2){let e=o;Y("x",e.x)("y",e.y)("width",e.width)("height",e.height)}}function wt(i,o){if(i&1&&(H(),W(0,"path",17)),i&2){let e=o.$implicit;Y("d",e.pathD)("stroke",e.strokeColor)("stroke-dasharray",e.strokeDashArray)("marker-end",e.markerEnd)}}function Tt(i,o){if(i&1){let e=ie();H(),p(0,"g",20),B("nodeClicked",function(n){R(e);let r=C();return z(r.handleNodeClick(n))}),d()}if(i&2){let e=o.$implicit,t=C();me("node",e)("isHighlighted",t.activeNodeId()===e.id)("isSelected",t.selectedNodeId()===e.id)}}function Mt(i,o){if(i&1){let e=ie();p(0,"app-ses-graph-node-detail",21),B("closed",function(){R(e);let n=C();return z(n.handleDetailClose())}),d()}i&2&&me("node",o)}var Gn=(()=>{class i{svgRef;layout=F(null);activeNodeId=F("");selectedNodeId=F("");isLoading=F(!1);nodeClicked=ne();detailClosed=ne();viewBox_$=V({x:0,y:0,width:800,height:600});viewBoxStr_$=g(()=>{let e=this.viewBox_$();return`${e.x} ${e.y} ${e.width} ${e.height}`});isFollowActive_$=V(!0);isPanning=!1;panStartX=0;panStartY=0;panStartViewBoxX=0;panStartViewBoxY=0;nodes_$=g(()=>this.layout()?.nodes??[]);edges_$=g(()=>this.layout()?.edges??[]);loopBounds_$=g(()=>this.layout()?.loopContainerBounds??null);selectedNode_$=g(()=>{let e=this.selectedNodeId();return e?this.nodes_$().find(t=>t.id===e)??null:null});constructor(){Se(()=>{let e=this.layout();e&&this.viewBox_$.set(I({},e.viewBox))},{allowSignalWrites:!0})}handleNodeClick(e){this.nodeClicked.emit(e)}handleDetailClose(){this.detailClosed.emit()}handlePointerDown(e){if(e.button!==0)return;this.isPanning=!0,this.panStartX=e.clientX,this.panStartY=e.clientY;let t=this.viewBox_$();this.panStartViewBoxX=t.x,this.panStartViewBoxY=t.y,this.svgRef&&this.svgRef.nativeElement.setPointerCapture(e.pointerId)}handlePointerMove(e){if(!this.isPanning||!this.svgRef)return;let t=this.svgRef.nativeElement,n=this.viewBox_$(),r=n.width/t.clientWidth,s=n.height/t.clientHeight,a=(e.clientX-this.panStartX)*r,h=(e.clientY-this.panStartY)*s;this.viewBox_$.set(w(I({},n),{x:this.panStartViewBoxX-a,y:this.panStartViewBoxY-h}))}handlePointerUp(){this.isPanning=!1}handleWheel(e){if(e.preventDefault(),!this.svgRef)return;let t=this.svgRef.nativeElement,n=this.viewBox_$(),r=e.deltaY>0?1.1:.9,s=t.getBoundingClientRect(),a=(e.clientX-s.left)/s.width,h=(e.clientY-s.top)/s.height,l=n.width*r,c=n.height*r;if(l<200||l>5e3)return;let _=n.x+(n.width-l)*a,y=n.y+(n.height-c)*h;this.viewBox_$.set({x:_,y,width:l,height:c})}handleFitToView(){let e=this.nodes_$();if(e.length===0)return;let t=P.recalculateViewBox(e,48);this.viewBox_$.set(t)}handleToggleFollowActive(){this.isFollowActive_$.update(e=>!e)}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=ae({type:i,selectors:[["app-ses-graph-view"]],viewQuery:function(t,n){if(t&1&&Ge($t,5),t&2){let r;Oe(r=Re())&&(n.svgRef=r.first)}},inputs:{layout:[1,"layout"],activeNodeId:[1,"activeNodeId"],selectedNodeId:[1,"selectedNodeId"],isLoading:[1,"isLoading"]},outputs:{nodeClicked:"nodeClicked",detailClosed:"detailClosed"},standalone:!0,features:[le],decls:25,vars:6,consts:[["graphSvg",""],[1,"flex","flex-col","h-full","w-full","overflow-hidden"],[1,"flex","items-center","gap-2","px-3","py-2","border-b","border-neutral-800","shrink-0","bg-neutral-900/80"],["title","Fit to view",1,"px-2","py-1","text-xs","border","rounded","transition-colors","border-neutral-700","text-neutral-400","hover:text-neutral-200","hover:border-neutral-500",3,"click"],["viewBox","0 0 24 24","fill","none","stroke","currentColor","stroke-width","2","stroke-linecap","round","stroke-linejoin","round",1,"w-3.5","h-3.5","inline-block","mr-1"],["d","M15 3h6v6M9 21H3v-6M21 3l-7 7M3 21l7-7"],["title","Follow active node",1,"px-2","py-1","text-xs","border","rounded","transition-colors",3,"click"],[1,"text-xs","text-neutral-500","ml-auto"],[1,"flex-1","min-h-0","relative"],["preserveAspectRatio","xMidYMid meet",1,"ses-graph-svg",3,"pointerdown","pointermove","pointerup","pointerleave","wheel"],["id","ses-arrow-seq","markerWidth","8","markerHeight","6","refX","8","refY","3","orient","auto","markerUnits","strokeWidth"],["d","M 0 0 L 8 3 L 0 6 Z","fill","#525252"],["id","ses-arrow-loop","markerWidth","8","markerHeight","6","refX","8","refY","3","orient","auto","markerUnits","strokeWidth"],["d","M 0 0 L 8 3 L 0 6 Z","fill","#3b82f6"],["id","ses-arrow-error","markerWidth","8","markerHeight","6","refX","8","refY","3","orient","auto","markerUnits","strokeWidth"],["d","M 0 0 L 8 3 L 0 6 Z","fill","#f97316"],["rx","6","fill","#0f172a","stroke","#1e3a5f","stroke-width","1","stroke-dasharray","4 2","opacity","0.5"],["stroke-width","1.5","fill","none"],["appSesGraphNodeSvg","",3,"node","isHighlighted","isSelected"],[1,"absolute","top-2","right-2","z-10",3,"node"],["appSesGraphNodeSvg","",3,"nodeClicked","node","isHighlighted","isSelected"],[1,"absolute","top-2","right-2","z-10",3,"closed","node"]],template:function(t,n){if(t&1){let r=ie();p(0,"div",1)(1,"div",2)(2,"button",3),B("click",function(){return R(r),z(n.handleFitToView())}),H(),p(3,"svg",4),W(4,"path",5),d(),m(5," Fit "),d(),ye(),p(6,"button",6),B("click",function(){return R(r),z(n.handleToggleFollowActive())}),m(7," Follow "),d(),D(8,bt,2,0,"span",7),d(),p(9,"div",8),H(),p(10,"svg",9,0),B("pointerdown",function(a){return R(r),z(n.handlePointerDown(a))})("pointermove",function(a){return R(r),z(n.handlePointerMove(a))})("pointerup",function(){return R(r),z(n.handlePointerUp())})("pointerleave",function(){return R(r),z(n.handlePointerUp())})("wheel",function(a){return R(r),z(n.handleWheel(a))}),p(12,"defs")(13,"marker",10),W(14,"path",11),d(),p(15,"marker",12),W(16,"path",13),d(),p(17,"marker",14),W(18,"path",15),d()(),D(19,Lt,1,4,":svg:rect",16),Le(20,wt,1,4,":svg:path",17,Qe),Le(22,Tt,1,3,":svg:g",18,Qe),d(),D(24,Mt,1,1,"app-ses-graph-node-detail",19),d()()}if(t&2){let r,s;u(6),se(n.isFollowActive_$()?"border-neonCyan/50 text-neonCyan bg-neonCyan/10":"border-neutral-700 text-neutral-400 hover:text-neutral-200 hover:border-neutral-500"),u(2),S(n.isLoading()?8:-1),u(2),Y("viewBox",n.viewBoxStr_$()),u(9),S((r=n.loopBounds_$())?19:-1,r),u(),we(n.edges_$()),u(2),we(n.nodes_$()),u(2),S((s=n.selectedNode_$())?24:-1,s)}},dependencies:[de,$e,Ke],styles:[`@charset "UTF-8";@keyframes _ngcontent-%COMP%_ses-graph-node-pulse{0%,to{filter:drop-shadow(0 0 4px var(--ses-graph-pulse-color, #22d3ee))}50%{filter:drop-shadow(0 0 12px var(--ses-graph-pulse-color, #22d3ee))}}[_nghost-%COMP%]{display:block;width:100%;height:100%;position:relative}.ses-graph-svg[_ngcontent-%COMP%]{width:100%;height:100%;background:#0a0a0a;-webkit-user-select:none;user-select:none} .ses-graph-node--active{animation:_ngcontent-%COMP%_ses-graph-node-pulse 1.5s ease-in-out infinite} .ses-graph-node--active rect{stroke-width:2.5} .ses-graph-node--selected{filter:drop-shadow(0 0 6px rgba(34,211,238,.4))}
2
2
  /*# sourceMappingURL=ses-graph-view.component-5NATWVIS.css.map */`]})}return i})();export{qe as a,ve as b,x as c,k as d,f as e,P as f,Ze as g,Gn as h};
3
- //# sourceMappingURL=chunk-LMK3IOKN.js.map
3
+ //# sourceMappingURL=chunk-XLSL262Q.js.map
@@ -208,5 +208,5 @@ stackLocation: ${this.stackLocation}
208
208
  DynamoPoll: "${this.name}" pollDo was UNSUCCESSFUL`,error:r})})})),this.running=!0}catch(r){throw new ru.DyFM_Error({message:`DYNAMO ERROR:
209
209
  DynamoPoll: startPoll was UNSUCCESSFUL`,error:r})}})}restartPoll(e){try{e?this.startPoll(e):this.startPoll(this.args)}catch(r){throw new ru.DyFM_Error({message:`DYNAMO ERROR:
210
210
  DynamoPoll: restartPoll was UNSUCCESSFUL`,error:r})}}stop(){this.poll.unsubscribe(),this.running=!1}end(e){this.poll.unsubscribe(),this.pollEnd?.(e),this.running=!1}};tu.DyFM_Poll=Jc});var ly=f(nu=>{"use strict";Object.defineProperty(nu,"__esModule",{value:!0});nu.DyFM_RangeValue=void 0;var Gc=class t{isRange=!0;from;to;constructor(e,r){if(e?.isRange){this.from=e.from,this.to=e.to;return}else this.from=e,this.to=r??e}constructed(){return!0}newValues(e){this.from=e.from,this.to=e.to}addRange(e){this.from+=e.from,this.to+=e.to}subtractRange(e){this.from-=e.from,this.to-=e.to}multiplyRange(e){this.from*=e.from,this.to*=e.to}divideRange(e){this.from/=e.from,this.to/=e.to}add(e){this.from+=e,this.to+=e}subtract(e){this.from-=e,this.to-=e}multiply(e){this.from*=e,this.to*=e}divide(e){this.from/=e,this.to/=e}clone(){return new t(this.from,this.to)}applyTransform(e){return new t(e(this.from),e(this.to))}toString=this.stringify;stringify(e=!0,r=!0){return r&&this.from===this.to?`${this.from}`:e?`${this.from} - ${this.to}`:`${this.from}-${this.to}`}static reType(e){return new t(e.from,e.to)}static addRange(e,r){return new t(e.from+r.from,e.to+r.to)}static subtractRange(e,r){return new t(e.from-r.from,e.to-r.to)}static multiplyRange(e,r){return new t(e.from*r.from,e.to*r.to)}static divideRange(e,r){return new t(e.from/r.from,e.to/r.to)}static add(e,r){return new t(e.from+r,e.to+r)}static subtract(e,r){return new t(e.from-r,e.to-r)}static multiply(e,r){return new t(e.from*r,e.to*r)}static divide(e,r){return new t(e.from/r,e.to/r)}static isInRange(e,r){return r.from<=e&&e<=r.to}};nu.DyFM_RangeValue=Gc});var fy=f(Ot=>{"use strict";Object.defineProperty(Ot,"__esModule",{value:!0});Ot.DyFM_serverStatus_dataParams=Ot.DyFM_ServerStatus=void 0;var Uk=iu(),Tk=kr(),Hc=class extends Tk.DyFM_Metadata{status;systemName;systemShortCode;clientVersionOk;latestClientVersion;latestClientVersionNumeric;serverVersion;serverNumericVersion;uptime;serverMessage;memoryUsage;cpuUsage;serverConnections;constructor(e){super(e),e&&Object.assign(this,e)}};Ot.DyFM_ServerStatus=Hc;Ot.DyFM_serverStatus_dataParams=new Uk.DyFM_DataModel_Params({dataName:"server_status",properties:{status:{type:"string"},systemName:{type:"string"},systemShortCode:{type:"string"},clientVersionOk:{type:"boolean"},latestClientVersion:{type:"string"},latestClientVersionNumeric:{type:"number"},serverVersion:{type:"string"},serverNumericVersion:{type:"number"},uptime:{type:"number"},serverMessage:{type:"string"},memoryUsage:{type:"object"},cpuUsage:{type:"object"},serverConnections:{type:"object"}}})});var vy=f(ur=>{"use strict";Object.defineProperty(ur,"__esModule",{value:!0});ur.DyFM_API_Input_Type=ur.DyFM_ServerRoute_SettingsBase=ur.DyFM_Endpoint_SettingsBase=void 0;var Wk=Fr(),ou=class{name;type;endpoint;pathParamKeys=[];constructor(e){if(!e.endpoint)throw new Error(`endpoint not setted up for this endpoint (${e.name??(0,Wk.DyFM_getConstructionStackLocation)()})`);e.endpoint.includes("{")&&(console.warn(`using {param} brackets in endpoint definitions will be deprecated...
211
- use :param instead ({pathParam} --> :pathParam) (${e.name})`),e.endpoint=e.endpoint.replace(/{/g,":").replace(/}/g,"")),Object.assign(this,e),this.pathParamKeys=this.endpoint.split("/").filter(r=>r.startsWith(":")).map(r=>r.replace(":",""))}};ur.DyFM_Endpoint_SettingsBase=ou;var Zc=class extends ou{preProcesses;tasks;simpleTask;constructor(e){super(e),Object.assign(this,e)}};ur.DyFM_ServerRoute_SettingsBase=Zc;var dy=function(t){return t.body="body",t.queryParams="queryParams",t}(dy||(ur.DyFM_API_Input_Type=dy={}))});var hy=f(xe=>{"use strict";Object.defineProperty(xe,"__esModule",{value:!0});xe.DyFM_errors_dataParams=xe.DyFM_Errors=xe.DyFM_errorsFlag=void 0;var Bk=Ds(),Vk=kr();xe.DyFM_errorsFlag="DyFM-ERRORS-OBJECT";var Kc=class extends Vk.DyFM_Metadata{flag=xe.DyFM_errorsFlag;source;issuer;username;versions=[];localTime;region;message;exception;exceptionObj;stackTrace=[];error;count=1;d_error;additionalContent;level;priority;duplications=[];constructor(e){super(e),e&&Object.assign(this,e)}};xe.DyFM_Errors=Kc;xe.DyFM_errors_dataParams=new Bk.DyFM_DataModel_Params({dataName:"errors",properties:{flag:{type:"string"},issuer:{type:"string"},username:{type:"string"},versions:{type:"string[]"},localTime:{type:"string"},region:{type:"string"},message:{type:"string"},exception:{type:"string"},exceptionObj:{type:"any"},stackTrace:{type:"string[]"},error:{type:"any"},count:{type:"number"},d_error:{type:"DyFM_Error"},additionalContent:{type:"any"},level:{type:"DyFM_ErrorLevel"},priority:{type:"number"},duplications:{type:"DyNTS_Error[]"}}})});var yy=f(py=>{"use strict";Object.defineProperty(py,"__esModule",{value:!0})});var my=f(_y=>{"use strict";Object.defineProperty(_y,"__esModule",{value:!0})});var gy=f(by=>{"use strict";Object.defineProperty(by,"__esModule",{value:!0})});var Sy=f(Oy=>{"use strict";Object.defineProperty(Oy,"__esModule",{value:!0})});var qy=f(wy=>{"use strict";Object.defineProperty(wy,"__esModule",{value:!0})});var jy=f(My=>{"use strict";Object.defineProperty(My,"__esModule",{value:!0})});var Ay=f(Py=>{"use strict";Object.defineProperty(Py,"__esModule",{value:!0})});var Ey=f(Fy=>{"use strict";Object.defineProperty(Fy,"__esModule",{value:!0})});var Dy=f(xy=>{"use strict";Object.defineProperty(xy,"__esModule",{value:!0})});var Iy=f(ky=>{"use strict";Object.defineProperty(ky,"__esModule",{value:!0})});var Cy=f(Ly=>{"use strict";Object.defineProperty(Ly,"__esModule",{value:!0})});var Ny=f(Ry=>{"use strict";Object.defineProperty(Ry,"__esModule",{value:!0})});var Uy=f($y=>{"use strict";Object.defineProperty($y,"__esModule",{value:!0})});var Wy=f(au=>{"use strict";Object.defineProperty(au,"__esModule",{value:!0});au.DyFM_SpecialSearch_Type=void 0;var Ty=function(t){return t.stringListSearchAny="stringListSearchAny",t.stringListSearch="stringListSearch",t.stringListSearchOrdered="stringListSearchOrdered",t}(Ty||(au.DyFM_SpecialSearch_Type=Ty={}))});var Vy=f(By=>{"use strict";Object.defineProperty(By,"__esModule",{value:!0})});var iu=f(O=>{"use strict";Object.defineProperty(O,"__esModule",{value:!0});var S=(hu(),tl(vu));S.__exportStar(pu(),O);S.__exportStar(yu(),O);S.__exportStar(Al(),O);S.__exportStar(Fl(),O);S.__exportStar(wt(),O);S.__exportStar(El(),O);S.__exportStar(Fu(),O);S.__exportStar(Il(),O);S.__exportStar(Du(),O);S.__exportStar(he(),O);S.__exportStar(Ll(),O);S.__exportStar(bn(),O);S.__exportStar(Fr(),O);S.__exportStar(Ru(),O);S.__exportStar(Lu(),O);S.__exportStar(ju(),O);S.__exportStar(Cl(),O);S.__exportStar(Uu(),O);S.__exportStar(vf(),O);S.__exportStar(pf(),O);S.__exportStar(Mt(),O);S.__exportStar(yf(),O);S.__exportStar(ds(),O);S.__exportStar(hs(),O);S.__exportStar(_f(),O);S.__exportStar(mf(),O);S.__exportStar(bf(),O);S.__exportStar(jt(),O);S.__exportStar(ms(),O);S.__exportStar(gf(),O);S.__exportStar(gs(),O);S.__exportStar(qt(),O);S.__exportStar(wf(),O);S.__exportStar(jf(),O);S.__exportStar(Af(),O);S.__exportStar(Ef(),O);S.__exportStar(Ou(),O);S.__exportStar(gu(),O);S.__exportStar(Su(),O);S.__exportStar(Ds(),O);S.__exportStar(ws(),O);S.__exportStar(Bn(),O);S.__exportStar(cy(),O);S.__exportStar(ly(),O);S.__exportStar(fy(),O);S.__exportStar(vy(),O);S.__exportStar(Fs(),O);S.__exportStar(Ms(),O);S.__exportStar(Ps(),O);S.__exportStar(hy(),O);S.__exportStar(kr(),O);S.__exportStar(yy(),O);S.__exportStar(my(),O);S.__exportStar(gy(),O);S.__exportStar(Sy(),O);S.__exportStar(qy(),O);S.__exportStar(jy(),O);S.__exportStar(Ay(),O);S.__exportStar(Ey(),O);S.__exportStar(Dy(),O);S.__exportStar(Iy(),O);S.__exportStar(Cy(),O);S.__exportStar(Ny(),O);S.__exportStar(Uy(),O);S.__exportStar(Wy(),O);S.__exportStar(Vy(),O)});var zy="1.1.3371";var Yy={baseUrl:"MISSING",api:{baseUrl:"MISSING"},production:!1,version:zy};var zk=function(t){return t.openAi="open-ai",t.anthropic="anthropic",t.google="google",t.deepseek="deepseek",t.fdpAi="fdp-ai",t.customLocalAi="custom-local-ai",t}(zk||{});var Yk=function(t){return t.openAi="open-ai",t.localAi="local-ai",t.routing="routing",t}(Yk||{});var Jk=function(t){return t.discord="discord",t.signal="signal",t.teams="teams",t.routing="routing",t}(Jk||{});var uu=function(t){return t.vaultKey="vault-key",t.instanceRegistry="instance-registry",t.general="general",t.llmProviders="llm-providers",t.messageProviders="message-providers",t.modelTesting="model-testing",t.discordAccess="discord-access",t.voice="voice",t.visuals="visuals",t.soul="soul",t.mcp="mcp",t.cliTools="cli-tools",t.secretVault="secret-vault",t.agentEmail="agent-email",t.embedding="embedding",t.rag="rag",t.developer="developer",t.agentRuntime="agent-runtime",t.agentCronJobs="agent-cron-jobs",t.scheduler="scheduler",t.github="github",t.openclawRegistry="openclaw-registry",t.deviceIdentity="device-identity",t.consultant="consultant",t.caAgent="ca-agent",t.darkOfficeLayout="dark-office-layout",t.cluster="cluster",t}(uu||{});var Gk=function(t){return t.openAi="open-ai",t.leonardo="leonardo",t.fdpai="fdpai",t.routing="routing",t}(Gk||{});var Hk=function(t){return t.elevenLabs="elevenlabs",t.fdpai="fdpai",t.routing="routing",t}(Hk||{});var Zk=function(t){return t.pending="pending",t.running="running",t.completed="completed",t.failed="failed",t}(Zk||{});var Kk=function(t){return t.apiKey="api-key",t.credentials="credentials",t}(Kk||{});var Qk=function(t){return t.req="req",t.bug="bug",t.feature="feature",t.improvement="improvement",t.task="task",t.question="question",t.research="research",t}(Qk||{});var Xk=function(t){return t.low="low",t.medium="medium",t.high="high",t.urgent="urgent",t}(Xk||{});var eI=function(t){return t.todo="todo",t.backlog="backlog",t.bugs="bugs",t.changelog="changelog",t.userInput="user-input",t.status="status",t.testErrorReports="test-error-reports",t}(eI||{});var rI=function(t){return t.update="update",t.remove="remove",t}(rI||{});var tI=function(t){return t.e2e="e2e",t.serverUnit="server-unit",t.clientUnit="client-unit",t.cli="cli",t}(tI||{});var nI=function(t){return t.instant="instant",t.agenticAny="agentic-any",t.ask="ask",t.plan="plan",t}(nI||{});var iI=function(t){return t.full="full",t.askOnly="ask-only",t.planOnly="plan-only",t}(iI||{});var oI=function(t){return t.draft="draft",t.promotedUserInput="promoted-user-input",t.promotedBug="promoted-bug",t.discarded="discarded",t}(oI||{});var aI=function(t){return t.userInput="user-input",t.bugReport="bug-report",t.unspecified="unspecified",t}(aI||{});var uI=function(t){return t.easy="easy",t.medium="medium",t.hard="hard",t.komplex="komplex",t}(uI||{});var Qc="mongodb://200.33.0.101:29017";var sI="A k\xE9r\xE9s nem jutott el a szerverig, vagy nem \xE9rkezett v\xE1lasz. Lehets\xE9ges okok: a szerver nem fut vagy m\xE1s porton hallgat, h\xE1l\xF3zati hiba, a kliens megszak\xEDtotta a k\xE9r\xE9st, vagy m\xE1s origin eset\xE9n CORS blokkolja. Ellen\u0151rizd, hogy a szerver fut-e \xE9s a megadott c\xEDm/port helyes.",cI="Szerver 500-as hiba. A v\xE1lasz body \xFCres vagy nem el\xE9rhet\u0151.",su=class t{static isLikelyHtmlErrorPage(e){let r=e.trim();if(!r.startsWith("<"))return!1;let n=r.toLowerCase();return n.includes("<!doctype")||n.includes("<html")||n.includes("<title>")||n.includes("cannot get")||n.includes("cannot post")||n.includes("cannot put")||n.includes("cannot delete")}static getMessageForHtmlHttpErrorBody(e){let r="R\xE9szletek: szerver log vagy DevTools Network tab.";return e===404?`Az endpoint nem tal\xE1lhat\xF3 (HTTP ${e}). Ellen\u0151rizd az API base URL-t \xE9s a szerver route-okat. `+r:`A szerver HTML error oldalt adott vissza (nem JSON API v\xE1lasz), HTTP ${e}. ${r}`}static getHttpErrorMessage(e,r){if(e.status===0)return sI;let n=r!=null&&typeof r=="string"&&r.trim().length>0?r:null;return n==null&&typeof e.error=="string"&&e.error.trim().length>0&&(n=e.error),n!=null&&t.isLikelyHtmlErrorPage(n)?t.getMessageForHtmlHttpErrorBody(e.status):e.status===500&&!(n!=null&&typeof n=="string"&&n.trim().length>0)?cI:n??e.message??e.statusText??`HTTP ${e.status}`}};var Jy=(()=>{class t{settingsBaseUrl=`${Yy.api.baseUrl}/settings`;http=en(ol);getDefaultWorkspace(){return R(this.http.get(`${this.settingsBaseUrl}/default-workspace`))}getSection(r){return R(this.http.get(`${this.settingsBaseUrl}/get-section/${r}`))}getRequiredWarningsSummary(){return R(this.http.get(`${this.settingsBaseUrl}/required-warnings-summary`))}saveSection(r,n){return R(this.http.patch(`${this.settingsBaseUrl}/save-section/${r}`,n))}postProviderAccessAllow(r){return R(this.http.post(`${this.settingsBaseUrl}/provider-access/allow`,r))}getSoulStatus(){return R(this.http.get(`${this.settingsBaseUrl}/soul-status`))}getSoulContent(){return R(this.http.get(`${this.settingsBaseUrl}/soul-content`))}postGenerateSoul(r){return R(this.http.post(`${this.settingsBaseUrl}/generate-soul`,r))}postTestLlmProvider(r){return R(this.http.post(`${this.settingsBaseUrl}/test-llm-provider`,r))}postListLlmModels(r){return R(this.http.post(`${this.settingsBaseUrl}/list-llm-models`,r))}postListEmbeddingModels(r){return R(this.http.post(`${this.settingsBaseUrl}/list-embedding-models`,r))}postTestMessagingProvider(r){return R(this.http.post(`${this.settingsBaseUrl}/test-messaging-provider`,r))}postMcpSync(r){return R(this.http.post(`${this.settingsBaseUrl}/mcp-sync`,r))}postCliHelpProbe(r){return R(this.http.post(`${this.settingsBaseUrl}/cli-help-probe`,r))}postCliHelpSuggest(r){return R(this.http.post(`${this.settingsBaseUrl}/cli-help-suggest`,r))}postTestAgentEmail(){return R(this.http.post(`${this.settingsBaseUrl}/test-agent-email`,{}))}testOpenclawConnection(r){return R(this.http.post(`${this.settingsBaseUrl}/test-openclaw-connection`,r))}pairOpenclawInstance(r){return R(this.http.post(`${this.settingsBaseUrl}/openclaw-registry/${r.instanceId}/pair`,{}))}getClusterDiagnostics(){return R(this.http.get(`${this.settingsBaseUrl}/cluster/diagnostics`))}postClusterReBootstrap(){return R(this.http.post(`${this.settingsBaseUrl}/cluster/re-bootstrap`,{}))}postClusterReconnectWs(){return R(this.http.post(`${this.settingsBaseUrl}/cluster/reconnect-ws`,{}))}postClusterReconnectPeer(r){let n=encodeURIComponent(r);return R(this.http.post(`${this.settingsBaseUrl}/cluster/reconnect-ws/${n}`,{}))}static \u0275fac=function(n){return new(n||t)};static \u0275prov=Xt({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();var Gy=rl(iu());var Xc=rl(iu());var cu=class{_master;get master(){return this._master}setupMaster(e){this._master=e}};var lu=class t extends cu{settings_AS=en(Jy);loading_$=ke(!1);loadError_$=ke(null);saving_$=ke(!1);saveError_$=ke(null);load(){return U(this,null,function*(){this.loading_$.set(!0),this.loadError_$.set(null);try{yield this.doLoad()}catch(e){Xc.DyFM_Error.logSimple(`${this.constructor.name} | Failed to load section`,e);let r=t.getErrorMessage(e);this.loadError_$.set(r)}finally{this.loading_$.set(!1)}})}save(){return U(this,null,function*(){this.saving_$.set(!0),this.saveError_$.set(null);try{let e=this.buildSaveBody(),r=yield this.doSave(e);return r.success?yield this.load():this.saveError_$.set(r.error??"Ment\xE9s sikertelen."),r}catch(e){Xc.DyFM_Error.logSimple(`${this.constructor.name} | Failed to save section`,e);let r=t.getErrorMessage(e);return this.saveError_$.set(r),{success:!1,error:r}}finally{this.saving_$.set(!1)}})}doSave(e){return U(this,null,function*(){return this.settings_AS.saveSection(this.getSectionId(),e)})}static getErrorMessage(e){if(e instanceof il){let r=e.error,n=null;if(r!==null&&typeof r=="object"){let i=r;typeof i.error=="string"?n=i.error:i.error!=null?n=String(i.error):typeof i.message=="string"&&(n=i.message);let o=i.errorCode,a=typeof o=="string"&&o.trim().length>0?o.trim():void 0;a!==void 0&&(n!=null&&n.trim().length>0?n=`${a}: ${n}`:n=a)}else typeof r=="string"&&(n=r);return su.getHttpErrorMessage(e,n)}return e instanceof Error?e.message||"M\u0171velet sikertelen.":String(e)||"M\u0171velet sikertelen."}};var X4=(()=>{class t extends lu{defaultWorkspacePath_$=ke("");section_$=ke({form:{mongodbUri:Qc,useOpenClawPath:!1,defaultPathOverride:"",autoStartWithSystem:!1,useLiveContext:!0,reportSocketConnectionErrorsToErrorList:!1,agenticLoopDebriefEnabled:!1,mobileAutoUpdateEnabled:!1,serverAutoUpdateEnabled:!1,serverAutoUpdateCheckInterval:"daily",ccSessionRunnerGracePeriodSec:null,ccSessionRunnerIdleTimeoutSec:null,ccSessionAutoArchiveScanIntervalSec:null,ccSessionAutoArchiveAgeDays:null,ccSessionAutoArchiveCountThreshold:null},runtime:{}});updateForm(r){this.section_$.update(n=>Sr(oe({},n),{form:oe(oe({},n.form),r)}))}setSection(r){this.section_$.set(r)}updateGeneralForm(r){this.updateForm(r),this.master?.bumpDigest()}getSectionId(){return uu.general}getSection_$(){return this.section_$}loadDefaultWorkspacePath(){return U(this,null,function*(){try{let r=yield this.settings_AS.getDefaultWorkspace();this.defaultWorkspacePath_$.set(r.workspacePath?.trim()??"")}catch(r){Gy.DyFM_Error.logSimple("CCAP_SettingsGeneral_DS | loadDefaultWorkspacePath failed",r),this.defaultWorkspacePath_$.set("")}})}doLoad(){return U(this,null,function*(){let r=yield this.settings_AS.getSection(uu.general);this.setSection({form:{mongodbUri:typeof r.mongodbUri=="string"?r.mongodbUri:Qc,useOpenClawPath:typeof r.useOpenClawPath=="boolean"?r.useOpenClawPath:!1,defaultPathOverride:typeof r.defaultPathOverride=="string"?r.defaultPathOverride:"",autoStartWithSystem:typeof r.autoStartWithSystem=="boolean"?r.autoStartWithSystem:!1,useLiveContext:typeof r.useLiveContext=="boolean"?r.useLiveContext:!0,reportSocketConnectionErrorsToErrorList:typeof r.reportSocketConnectionErrorsToErrorList=="boolean"?r.reportSocketConnectionErrorsToErrorList:!1,agenticLoopDebriefEnabled:typeof r.agenticLoopDebriefEnabled=="boolean"?r.agenticLoopDebriefEnabled:!1,mobileAutoUpdateEnabled:typeof r.mobileAutoUpdateEnabled=="boolean"?r.mobileAutoUpdateEnabled:!1,serverAutoUpdateEnabled:typeof r.serverAutoUpdateEnabled=="boolean"?r.serverAutoUpdateEnabled:!1,serverAutoUpdateCheckInterval:r.serverAutoUpdateCheckInterval==="daily"?"daily":r.serverAutoUpdateCheckInterval==="weekly"?"weekly":"daily",ccSessionRunnerGracePeriodSec:typeof r.ccSessionRunnerGracePeriodSec=="number"&&r.ccSessionRunnerGracePeriodSec>0?r.ccSessionRunnerGracePeriodSec:null,ccSessionRunnerIdleTimeoutSec:typeof r.ccSessionRunnerIdleTimeoutSec=="number"&&r.ccSessionRunnerIdleTimeoutSec>0?r.ccSessionRunnerIdleTimeoutSec:null,ccSessionAutoArchiveScanIntervalSec:typeof r.ccSessionAutoArchiveScanIntervalSec=="number"&&r.ccSessionAutoArchiveScanIntervalSec>0?r.ccSessionAutoArchiveScanIntervalSec:null,ccSessionAutoArchiveAgeDays:typeof r.ccSessionAutoArchiveAgeDays=="number"&&r.ccSessionAutoArchiveAgeDays>0?r.ccSessionAutoArchiveAgeDays:null,ccSessionAutoArchiveCountThreshold:typeof r.ccSessionAutoArchiveCountThreshold=="number"&&r.ccSessionAutoArchiveCountThreshold>0?r.ccSessionAutoArchiveCountThreshold:null},runtime:{}})})}buildSaveBody(){let r=this.section_$().form;return{mongodbUri:r.mongodbUri,useOpenClawPath:r.useOpenClawPath,defaultPathOverride:r.defaultPathOverride,autoStartWithSystem:r.autoStartWithSystem,useLiveContext:r.useLiveContext,reportSocketConnectionErrorsToErrorList:r.reportSocketConnectionErrorsToErrorList,agenticLoopDebriefEnabled:r.agenticLoopDebriefEnabled,mobileAutoUpdateEnabled:r.mobileAutoUpdateEnabled,serverAutoUpdateEnabled:r.serverAutoUpdateEnabled,serverAutoUpdateCheckInterval:r.serverAutoUpdateCheckInterval,ccSessionRunnerGracePeriodSec:r.ccSessionRunnerGracePeriodSec??void 0,ccSessionRunnerIdleTimeoutSec:r.ccSessionRunnerIdleTimeoutSec??void 0,ccSessionAutoArchiveScanIntervalSec:r.ccSessionAutoArchiveScanIntervalSec??void 0,ccSessionAutoArchiveAgeDays:r.ccSessionAutoArchiveAgeDays??void 0,ccSessionAutoArchiveCountThreshold:r.ccSessionAutoArchiveCountThreshold??void 0}}static \u0275fac=(()=>{let r;return function(i){return(r||(r=nl(t)))(i||t)}})();static \u0275prov=Xt({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();export{vu as a,hu as b,Al as c,wt as d,he as e,El as f,Fu as g,bn as h,Fr as i,ds as j,kr as k,Bn as l,Ds as m,uy as n,ly as o,iu as p,zk as q,Yk as r,Jk as s,uu as t,Gk as u,Hk as v,Zk as w,Kk as x,Qk as y,oI as z,aI as A,uI as B,Xk as C,eI as D,rI as E,tI as F,nI as G,iI as H,Yy as I,Qc as J,su as K,Jy as L,lu as M,X4 as N};
212
- //# sourceMappingURL=chunk-RUSAMFGS.js.map
211
+ use :param instead ({pathParam} --> :pathParam) (${e.name})`),e.endpoint=e.endpoint.replace(/{/g,":").replace(/}/g,"")),Object.assign(this,e),this.pathParamKeys=this.endpoint.split("/").filter(r=>r.startsWith(":")).map(r=>r.replace(":",""))}};ur.DyFM_Endpoint_SettingsBase=ou;var Zc=class extends ou{preProcesses;tasks;simpleTask;constructor(e){super(e),Object.assign(this,e)}};ur.DyFM_ServerRoute_SettingsBase=Zc;var dy=function(t){return t.body="body",t.queryParams="queryParams",t}(dy||(ur.DyFM_API_Input_Type=dy={}))});var hy=f(xe=>{"use strict";Object.defineProperty(xe,"__esModule",{value:!0});xe.DyFM_errors_dataParams=xe.DyFM_Errors=xe.DyFM_errorsFlag=void 0;var Bk=Ds(),Vk=kr();xe.DyFM_errorsFlag="DyFM-ERRORS-OBJECT";var Kc=class extends Vk.DyFM_Metadata{flag=xe.DyFM_errorsFlag;source;issuer;username;versions=[];localTime;region;message;exception;exceptionObj;stackTrace=[];error;count=1;d_error;additionalContent;level;priority;duplications=[];constructor(e){super(e),e&&Object.assign(this,e)}};xe.DyFM_Errors=Kc;xe.DyFM_errors_dataParams=new Bk.DyFM_DataModel_Params({dataName:"errors",properties:{flag:{type:"string"},issuer:{type:"string"},username:{type:"string"},versions:{type:"string[]"},localTime:{type:"string"},region:{type:"string"},message:{type:"string"},exception:{type:"string"},exceptionObj:{type:"any"},stackTrace:{type:"string[]"},error:{type:"any"},count:{type:"number"},d_error:{type:"DyFM_Error"},additionalContent:{type:"any"},level:{type:"DyFM_ErrorLevel"},priority:{type:"number"},duplications:{type:"DyNTS_Error[]"}}})});var yy=f(py=>{"use strict";Object.defineProperty(py,"__esModule",{value:!0})});var my=f(_y=>{"use strict";Object.defineProperty(_y,"__esModule",{value:!0})});var gy=f(by=>{"use strict";Object.defineProperty(by,"__esModule",{value:!0})});var Sy=f(Oy=>{"use strict";Object.defineProperty(Oy,"__esModule",{value:!0})});var qy=f(wy=>{"use strict";Object.defineProperty(wy,"__esModule",{value:!0})});var jy=f(My=>{"use strict";Object.defineProperty(My,"__esModule",{value:!0})});var Ay=f(Py=>{"use strict";Object.defineProperty(Py,"__esModule",{value:!0})});var Ey=f(Fy=>{"use strict";Object.defineProperty(Fy,"__esModule",{value:!0})});var Dy=f(xy=>{"use strict";Object.defineProperty(xy,"__esModule",{value:!0})});var Iy=f(ky=>{"use strict";Object.defineProperty(ky,"__esModule",{value:!0})});var Cy=f(Ly=>{"use strict";Object.defineProperty(Ly,"__esModule",{value:!0})});var Ny=f(Ry=>{"use strict";Object.defineProperty(Ry,"__esModule",{value:!0})});var Uy=f($y=>{"use strict";Object.defineProperty($y,"__esModule",{value:!0})});var Wy=f(au=>{"use strict";Object.defineProperty(au,"__esModule",{value:!0});au.DyFM_SpecialSearch_Type=void 0;var Ty=function(t){return t.stringListSearchAny="stringListSearchAny",t.stringListSearch="stringListSearch",t.stringListSearchOrdered="stringListSearchOrdered",t}(Ty||(au.DyFM_SpecialSearch_Type=Ty={}))});var Vy=f(By=>{"use strict";Object.defineProperty(By,"__esModule",{value:!0})});var iu=f(O=>{"use strict";Object.defineProperty(O,"__esModule",{value:!0});var S=(hu(),tl(vu));S.__exportStar(pu(),O);S.__exportStar(yu(),O);S.__exportStar(Al(),O);S.__exportStar(Fl(),O);S.__exportStar(wt(),O);S.__exportStar(El(),O);S.__exportStar(Fu(),O);S.__exportStar(Il(),O);S.__exportStar(Du(),O);S.__exportStar(he(),O);S.__exportStar(Ll(),O);S.__exportStar(bn(),O);S.__exportStar(Fr(),O);S.__exportStar(Ru(),O);S.__exportStar(Lu(),O);S.__exportStar(ju(),O);S.__exportStar(Cl(),O);S.__exportStar(Uu(),O);S.__exportStar(vf(),O);S.__exportStar(pf(),O);S.__exportStar(Mt(),O);S.__exportStar(yf(),O);S.__exportStar(ds(),O);S.__exportStar(hs(),O);S.__exportStar(_f(),O);S.__exportStar(mf(),O);S.__exportStar(bf(),O);S.__exportStar(jt(),O);S.__exportStar(ms(),O);S.__exportStar(gf(),O);S.__exportStar(gs(),O);S.__exportStar(qt(),O);S.__exportStar(wf(),O);S.__exportStar(jf(),O);S.__exportStar(Af(),O);S.__exportStar(Ef(),O);S.__exportStar(Ou(),O);S.__exportStar(gu(),O);S.__exportStar(Su(),O);S.__exportStar(Ds(),O);S.__exportStar(ws(),O);S.__exportStar(Bn(),O);S.__exportStar(cy(),O);S.__exportStar(ly(),O);S.__exportStar(fy(),O);S.__exportStar(vy(),O);S.__exportStar(Fs(),O);S.__exportStar(Ms(),O);S.__exportStar(Ps(),O);S.__exportStar(hy(),O);S.__exportStar(kr(),O);S.__exportStar(yy(),O);S.__exportStar(my(),O);S.__exportStar(gy(),O);S.__exportStar(Sy(),O);S.__exportStar(qy(),O);S.__exportStar(jy(),O);S.__exportStar(Ay(),O);S.__exportStar(Ey(),O);S.__exportStar(Dy(),O);S.__exportStar(Iy(),O);S.__exportStar(Cy(),O);S.__exportStar(Ny(),O);S.__exportStar(Uy(),O);S.__exportStar(Wy(),O);S.__exportStar(Vy(),O)});var zy="1.1.3441";var Yy={baseUrl:"MISSING",api:{baseUrl:"MISSING"},production:!1,version:zy};var zk=function(t){return t.openAi="open-ai",t.anthropic="anthropic",t.google="google",t.deepseek="deepseek",t.fdpAi="fdp-ai",t.customLocalAi="custom-local-ai",t}(zk||{});var Yk=function(t){return t.openAi="open-ai",t.localAi="local-ai",t.routing="routing",t}(Yk||{});var Jk=function(t){return t.discord="discord",t.signal="signal",t.teams="teams",t.routing="routing",t}(Jk||{});var uu=function(t){return t.vaultKey="vault-key",t.instanceRegistry="instance-registry",t.general="general",t.llmProviders="llm-providers",t.messageProviders="message-providers",t.modelTesting="model-testing",t.discordAccess="discord-access",t.voice="voice",t.visuals="visuals",t.soul="soul",t.mcp="mcp",t.cliTools="cli-tools",t.secretVault="secret-vault",t.agentEmail="agent-email",t.embedding="embedding",t.rag="rag",t.developer="developer",t.agentRuntime="agent-runtime",t.agentCronJobs="agent-cron-jobs",t.scheduler="scheduler",t.github="github",t.openclawRegistry="openclaw-registry",t.deviceIdentity="device-identity",t.consultant="consultant",t.caAgent="ca-agent",t.darkOfficeLayout="dark-office-layout",t.cluster="cluster",t}(uu||{});var Gk=function(t){return t.openAi="open-ai",t.leonardo="leonardo",t.fdpai="fdpai",t.routing="routing",t}(Gk||{});var Hk=function(t){return t.elevenLabs="elevenlabs",t.fdpai="fdpai",t.routing="routing",t}(Hk||{});var Zk=function(t){return t.pending="pending",t.running="running",t.completed="completed",t.failed="failed",t}(Zk||{});var Kk=function(t){return t.apiKey="api-key",t.credentials="credentials",t}(Kk||{});var Qk=function(t){return t.req="req",t.bug="bug",t.feature="feature",t.improvement="improvement",t.task="task",t.question="question",t.research="research",t}(Qk||{});var Xk=function(t){return t.low="low",t.medium="medium",t.high="high",t.urgent="urgent",t}(Xk||{});var eI=function(t){return t.todo="todo",t.backlog="backlog",t.bugs="bugs",t.changelog="changelog",t.userInput="user-input",t.status="status",t.testErrorReports="test-error-reports",t}(eI||{});var rI=function(t){return t.update="update",t.remove="remove",t}(rI||{});var tI=function(t){return t.e2e="e2e",t.serverUnit="server-unit",t.clientUnit="client-unit",t.cli="cli",t}(tI||{});var nI=function(t){return t.instant="instant",t.agenticAny="agentic-any",t.ask="ask",t.plan="plan",t}(nI||{});var iI=function(t){return t.full="full",t.askOnly="ask-only",t.planOnly="plan-only",t}(iI||{});var oI=function(t){return t.draft="draft",t.promotedUserInput="promoted-user-input",t.promotedBug="promoted-bug",t.discarded="discarded",t}(oI||{});var aI=function(t){return t.userInput="user-input",t.bugReport="bug-report",t.unspecified="unspecified",t}(aI||{});var uI=function(t){return t.easy="easy",t.medium="medium",t.hard="hard",t.komplex="komplex",t}(uI||{});var Qc="mongodb://200.33.0.101:29017";var sI="A k\xE9r\xE9s nem jutott el a szerverig, vagy nem \xE9rkezett v\xE1lasz. Lehets\xE9ges okok: a szerver nem fut vagy m\xE1s porton hallgat, h\xE1l\xF3zati hiba, a kliens megszak\xEDtotta a k\xE9r\xE9st, vagy m\xE1s origin eset\xE9n CORS blokkolja. Ellen\u0151rizd, hogy a szerver fut-e \xE9s a megadott c\xEDm/port helyes.",cI="Szerver 500-as hiba. A v\xE1lasz body \xFCres vagy nem el\xE9rhet\u0151.",su=class t{static isLikelyHtmlErrorPage(e){let r=e.trim();if(!r.startsWith("<"))return!1;let n=r.toLowerCase();return n.includes("<!doctype")||n.includes("<html")||n.includes("<title>")||n.includes("cannot get")||n.includes("cannot post")||n.includes("cannot put")||n.includes("cannot delete")}static getMessageForHtmlHttpErrorBody(e){let r="R\xE9szletek: szerver log vagy DevTools Network tab.";return e===404?`Az endpoint nem tal\xE1lhat\xF3 (HTTP ${e}). Ellen\u0151rizd az API base URL-t \xE9s a szerver route-okat. `+r:`A szerver HTML error oldalt adott vissza (nem JSON API v\xE1lasz), HTTP ${e}. ${r}`}static getHttpErrorMessage(e,r){if(e.status===0)return sI;let n=r!=null&&typeof r=="string"&&r.trim().length>0?r:null;return n==null&&typeof e.error=="string"&&e.error.trim().length>0&&(n=e.error),n!=null&&t.isLikelyHtmlErrorPage(n)?t.getMessageForHtmlHttpErrorBody(e.status):e.status===500&&!(n!=null&&typeof n=="string"&&n.trim().length>0)?cI:n??e.message??e.statusText??`HTTP ${e.status}`}};var Jy=(()=>{class t{settingsBaseUrl=`${Yy.api.baseUrl}/settings`;http=en(ol);getDefaultWorkspace(){return R(this.http.get(`${this.settingsBaseUrl}/default-workspace`))}getSection(r){return R(this.http.get(`${this.settingsBaseUrl}/get-section/${r}`))}getRequiredWarningsSummary(){return R(this.http.get(`${this.settingsBaseUrl}/required-warnings-summary`))}saveSection(r,n){return R(this.http.patch(`${this.settingsBaseUrl}/save-section/${r}`,n))}postProviderAccessAllow(r){return R(this.http.post(`${this.settingsBaseUrl}/provider-access/allow`,r))}getSoulStatus(){return R(this.http.get(`${this.settingsBaseUrl}/soul-status`))}getSoulContent(){return R(this.http.get(`${this.settingsBaseUrl}/soul-content`))}postGenerateSoul(r){return R(this.http.post(`${this.settingsBaseUrl}/generate-soul`,r))}postTestLlmProvider(r){return R(this.http.post(`${this.settingsBaseUrl}/test-llm-provider`,r))}postListLlmModels(r){return R(this.http.post(`${this.settingsBaseUrl}/list-llm-models`,r))}postListEmbeddingModels(r){return R(this.http.post(`${this.settingsBaseUrl}/list-embedding-models`,r))}postTestMessagingProvider(r){return R(this.http.post(`${this.settingsBaseUrl}/test-messaging-provider`,r))}postMcpSync(r){return R(this.http.post(`${this.settingsBaseUrl}/mcp-sync`,r))}postCliHelpProbe(r){return R(this.http.post(`${this.settingsBaseUrl}/cli-help-probe`,r))}postCliHelpSuggest(r){return R(this.http.post(`${this.settingsBaseUrl}/cli-help-suggest`,r))}postTestAgentEmail(){return R(this.http.post(`${this.settingsBaseUrl}/test-agent-email`,{}))}testOpenclawConnection(r){return R(this.http.post(`${this.settingsBaseUrl}/test-openclaw-connection`,r))}pairOpenclawInstance(r){return R(this.http.post(`${this.settingsBaseUrl}/openclaw-registry/${r.instanceId}/pair`,{}))}getClusterDiagnostics(){return R(this.http.get(`${this.settingsBaseUrl}/cluster/diagnostics`))}postClusterReBootstrap(){return R(this.http.post(`${this.settingsBaseUrl}/cluster/re-bootstrap`,{}))}postClusterReconnectWs(){return R(this.http.post(`${this.settingsBaseUrl}/cluster/reconnect-ws`,{}))}postClusterReconnectPeer(r){let n=encodeURIComponent(r);return R(this.http.post(`${this.settingsBaseUrl}/cluster/reconnect-ws/${n}`,{}))}static \u0275fac=function(n){return new(n||t)};static \u0275prov=Xt({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();var Gy=rl(iu());var Xc=rl(iu());var cu=class{_master;get master(){return this._master}setupMaster(e){this._master=e}};var lu=class t extends cu{settings_AS=en(Jy);loading_$=ke(!1);loadError_$=ke(null);saving_$=ke(!1);saveError_$=ke(null);load(){return U(this,null,function*(){this.loading_$.set(!0),this.loadError_$.set(null);try{yield this.doLoad()}catch(e){Xc.DyFM_Error.logSimple(`${this.constructor.name} | Failed to load section`,e);let r=t.getErrorMessage(e);this.loadError_$.set(r)}finally{this.loading_$.set(!1)}})}save(){return U(this,null,function*(){this.saving_$.set(!0),this.saveError_$.set(null);try{let e=this.buildSaveBody(),r=yield this.doSave(e);return r.success?yield this.load():this.saveError_$.set(r.error??"Ment\xE9s sikertelen."),r}catch(e){Xc.DyFM_Error.logSimple(`${this.constructor.name} | Failed to save section`,e);let r=t.getErrorMessage(e);return this.saveError_$.set(r),{success:!1,error:r}}finally{this.saving_$.set(!1)}})}doSave(e){return U(this,null,function*(){return this.settings_AS.saveSection(this.getSectionId(),e)})}static getErrorMessage(e){if(e instanceof il){let r=e.error,n=null;if(r!==null&&typeof r=="object"){let i=r;typeof i.error=="string"?n=i.error:i.error!=null?n=String(i.error):typeof i.message=="string"&&(n=i.message);let o=i.errorCode,a=typeof o=="string"&&o.trim().length>0?o.trim():void 0;a!==void 0&&(n!=null&&n.trim().length>0?n=`${a}: ${n}`:n=a)}else typeof r=="string"&&(n=r);return su.getHttpErrorMessage(e,n)}return e instanceof Error?e.message||"M\u0171velet sikertelen.":String(e)||"M\u0171velet sikertelen."}};var X4=(()=>{class t extends lu{defaultWorkspacePath_$=ke("");section_$=ke({form:{mongodbUri:Qc,useOpenClawPath:!1,defaultPathOverride:"",autoStartWithSystem:!1,useLiveContext:!0,reportSocketConnectionErrorsToErrorList:!1,agenticLoopDebriefEnabled:!1,mobileAutoUpdateEnabled:!1,serverAutoUpdateEnabled:!1,serverAutoUpdateCheckInterval:"daily",ccSessionRunnerGracePeriodSec:null,ccSessionRunnerIdleTimeoutSec:null,ccSessionAutoArchiveScanIntervalSec:null,ccSessionAutoArchiveAgeDays:null,ccSessionAutoArchiveCountThreshold:null},runtime:{}});updateForm(r){this.section_$.update(n=>Sr(oe({},n),{form:oe(oe({},n.form),r)}))}setSection(r){this.section_$.set(r)}updateGeneralForm(r){this.updateForm(r),this.master?.bumpDigest()}getSectionId(){return uu.general}getSection_$(){return this.section_$}loadDefaultWorkspacePath(){return U(this,null,function*(){try{let r=yield this.settings_AS.getDefaultWorkspace();this.defaultWorkspacePath_$.set(r.workspacePath?.trim()??"")}catch(r){Gy.DyFM_Error.logSimple("CCAP_SettingsGeneral_DS | loadDefaultWorkspacePath failed",r),this.defaultWorkspacePath_$.set("")}})}doLoad(){return U(this,null,function*(){let r=yield this.settings_AS.getSection(uu.general);this.setSection({form:{mongodbUri:typeof r.mongodbUri=="string"?r.mongodbUri:Qc,useOpenClawPath:typeof r.useOpenClawPath=="boolean"?r.useOpenClawPath:!1,defaultPathOverride:typeof r.defaultPathOverride=="string"?r.defaultPathOverride:"",autoStartWithSystem:typeof r.autoStartWithSystem=="boolean"?r.autoStartWithSystem:!1,useLiveContext:typeof r.useLiveContext=="boolean"?r.useLiveContext:!0,reportSocketConnectionErrorsToErrorList:typeof r.reportSocketConnectionErrorsToErrorList=="boolean"?r.reportSocketConnectionErrorsToErrorList:!1,agenticLoopDebriefEnabled:typeof r.agenticLoopDebriefEnabled=="boolean"?r.agenticLoopDebriefEnabled:!1,mobileAutoUpdateEnabled:typeof r.mobileAutoUpdateEnabled=="boolean"?r.mobileAutoUpdateEnabled:!1,serverAutoUpdateEnabled:typeof r.serverAutoUpdateEnabled=="boolean"?r.serverAutoUpdateEnabled:!1,serverAutoUpdateCheckInterval:r.serverAutoUpdateCheckInterval==="daily"?"daily":r.serverAutoUpdateCheckInterval==="weekly"?"weekly":"daily",ccSessionRunnerGracePeriodSec:typeof r.ccSessionRunnerGracePeriodSec=="number"&&r.ccSessionRunnerGracePeriodSec>0?r.ccSessionRunnerGracePeriodSec:null,ccSessionRunnerIdleTimeoutSec:typeof r.ccSessionRunnerIdleTimeoutSec=="number"&&r.ccSessionRunnerIdleTimeoutSec>0?r.ccSessionRunnerIdleTimeoutSec:null,ccSessionAutoArchiveScanIntervalSec:typeof r.ccSessionAutoArchiveScanIntervalSec=="number"&&r.ccSessionAutoArchiveScanIntervalSec>0?r.ccSessionAutoArchiveScanIntervalSec:null,ccSessionAutoArchiveAgeDays:typeof r.ccSessionAutoArchiveAgeDays=="number"&&r.ccSessionAutoArchiveAgeDays>0?r.ccSessionAutoArchiveAgeDays:null,ccSessionAutoArchiveCountThreshold:typeof r.ccSessionAutoArchiveCountThreshold=="number"&&r.ccSessionAutoArchiveCountThreshold>0?r.ccSessionAutoArchiveCountThreshold:null},runtime:{}})})}buildSaveBody(){let r=this.section_$().form;return{mongodbUri:r.mongodbUri,useOpenClawPath:r.useOpenClawPath,defaultPathOverride:r.defaultPathOverride,autoStartWithSystem:r.autoStartWithSystem,useLiveContext:r.useLiveContext,reportSocketConnectionErrorsToErrorList:r.reportSocketConnectionErrorsToErrorList,agenticLoopDebriefEnabled:r.agenticLoopDebriefEnabled,mobileAutoUpdateEnabled:r.mobileAutoUpdateEnabled,serverAutoUpdateEnabled:r.serverAutoUpdateEnabled,serverAutoUpdateCheckInterval:r.serverAutoUpdateCheckInterval,ccSessionRunnerGracePeriodSec:r.ccSessionRunnerGracePeriodSec??void 0,ccSessionRunnerIdleTimeoutSec:r.ccSessionRunnerIdleTimeoutSec??void 0,ccSessionAutoArchiveScanIntervalSec:r.ccSessionAutoArchiveScanIntervalSec??void 0,ccSessionAutoArchiveAgeDays:r.ccSessionAutoArchiveAgeDays??void 0,ccSessionAutoArchiveCountThreshold:r.ccSessionAutoArchiveCountThreshold??void 0}}static \u0275fac=(()=>{let r;return function(i){return(r||(r=nl(t)))(i||t)}})();static \u0275prov=Xt({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();export{vu as a,hu as b,Al as c,wt as d,he as e,El as f,Fu as g,bn as h,Fr as i,ds as j,kr as k,Bn as l,Ds as m,uy as n,ly as o,iu as p,zk as q,Yk as r,Jk as s,uu as t,Gk as u,Hk as v,Zk as w,Kk as x,Qk as y,oI as z,aI as A,uI as B,Xk as C,eI as D,rI as E,tI as F,nI as G,iI as H,Yy as I,Qc as J,su as K,Jy as L,lu as M,X4 as N};
212
+ //# sourceMappingURL=chunk-Y6V4NGLU.js.map