@openhands/agent-canvas 1.0.0-alpha.4 → 1.0.0-alpha.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (204) hide show
  1. package/build/assets/acp-providers-SCPK1BIU.js +1 -0
  2. package/build/assets/{acp-route-guard-CY4Kktrm.js → acp-route-guard-IWlFmS6x.js} +1 -1
  3. package/build/assets/active-backend-context-CkP3ZEJs.js +1 -0
  4. package/build/assets/{add-backend-modal-MoeYcSlW.js → add-backend-modal-CqjNjGqY.js} +1 -1
  5. package/build/assets/{agent-server-compatibility-DnXbX5aL.js → agent-server-compatibility-DvKtnXHw.js} +1 -1
  6. package/build/assets/agent-server-conversation-service.api-BdEre_71.js +5 -0
  7. package/build/assets/{agent-settings-D9CvPVkc.js → agent-settings-DdisD2Xx.js} +1 -1
  8. package/build/assets/{alert-banner-BopWFWDK.js → alert-banner-CvTYN73l.js} +1 -1
  9. package/build/assets/{analytics-consent-form-modal-FvOoRQJt.js → analytics-consent-form-modal-BKgT9i2w.js} +1 -1
  10. package/build/assets/{app-settings-Dh9WIVcy.js → app-settings-DcYXtxGP.js} +1 -1
  11. package/build/assets/{automation-detail-B1toFzbL.js → automation-detail-ZQs6D2d3.js} +1 -1
  12. package/build/assets/{automations-list-lQ_f_eVe.js → automations-list-CqHXGwSw.js} +1 -1
  13. package/build/assets/backend-form-modal-KudhWUX8.js +1 -0
  14. package/build/assets/{backend-synced-settings-badge-f7SIwZJJ.js → backend-synced-settings-badge-BFy2HylT.js} +1 -1
  15. package/build/assets/{base-modal-D0AZIorb.js → base-modal-B4HvlFHE.js} +1 -1
  16. package/build/assets/{browser-store-CYpN823z.js → browser-store-C3AqxAO7.js} +1 -1
  17. package/build/assets/{browser-tab-Cy5h30Rj.js → browser-tab-DTM6RyoV.js} +1 -1
  18. package/build/assets/{browser-CqONu_f3.js → browser-vYpdU3CR.js} +1 -1
  19. package/build/assets/{circle-plus-check-toggle-BLCVOBAz.js → circle-plus-check-toggle-DRvuu-RD.js} +1 -1
  20. package/build/assets/{color-themes-VfRROuOB.js → color-themes-DSaoIL6A.js} +1 -1
  21. package/build/assets/{command-store-BUJOHJw0.js → command-store-DFN_17p1.js} +1 -1
  22. package/build/assets/{condenser-settings-tU2QpcvW.js → condenser-settings-DduLQcpV.js} +1 -1
  23. package/build/assets/{confirmation-modal-C9X6T5NM.js → confirmation-modal-B-DOYMUH.js} +1 -1
  24. package/build/assets/{context-menu-list-item-CdiNsCXt.js → context-menu-list-item-DzjPB8aC.js} +1 -1
  25. package/build/assets/conversation-CeGMBOyB.js +1 -0
  26. package/build/assets/conversation-D8scXOe7.js +17 -0
  27. package/build/assets/conversation-panel-DMz46ji-.js +1 -0
  28. package/build/assets/{conversation-service.api-bFeuJPps.js → conversation-service.api-YTGTw0pz.js} +1 -1
  29. package/build/assets/conversation-state-store-Bc0slAjL.js +1 -0
  30. package/build/assets/{conversation-store-CAtSuhbI.js → conversation-store-Z5iMCRpc.js} +1 -1
  31. package/build/assets/conversation-websocket-context-B0Gd3yiT.js +3 -0
  32. package/build/assets/{device-verify-B3pEa6X6.js → device-verify-CTbXX9CQ.js} +1 -1
  33. package/build/assets/dist-yMQV8IUk.js +1 -0
  34. package/build/assets/{edit-automation-modal-CoJon94X.js → edit-automation-modal-DgW0Q8vr.js} +1 -1
  35. package/build/assets/{ellipsis-button-BMXoWChN.js → ellipsis-button-BoU2-xlG.js} +1 -1
  36. package/build/assets/{entry.client-DH09zdmW.js → entry.client-DU7-q4ZU.js} +2 -2
  37. package/build/assets/{environment-switch-overlay-akifSJ7a.js → environment-switch-overlay-DQ1n6Iu6.js} +1 -1
  38. package/build/assets/{extensions-hub-BTPY21Mo.js → extensions-hub-BW1FAKFJ.js} +1 -1
  39. package/build/assets/{extensions-navigation-Bw61uJe9.js → extensions-navigation-CbPMhSML.js} +1 -1
  40. package/build/assets/{files-tab-CsZQRSpv.js → files-tab-CbJ4s7Ik.js} +1 -1
  41. package/build/assets/files-tab-store-CDyVTXNT.js +1 -0
  42. package/build/assets/git-control-bar-branch-button-DhpPgadK.js +27 -0
  43. package/build/assets/git-provider-icon-D8RE4unY.js +1 -0
  44. package/build/assets/health-store-BDC2rM-X.js +1 -0
  45. package/build/assets/{home-7IR9W24e.js → home-D9fJfhQA.js} +1 -1
  46. package/build/assets/{install-server-modal-BL4pprnN.js → install-server-modal-VB5hOBpW.js} +1 -1
  47. package/build/assets/{launch-Bd5avLyw.js → launch-DKCU9uJH.js} +1 -1
  48. package/build/assets/{llm-client-BvUU4If8.js → llm-client-BpIfxETv.js} +1 -1
  49. package/build/assets/{llm-settings-yIFf1UoE.js → llm-settings-BOJC4vD-.js} +1 -1
  50. package/build/assets/llm-settings-CIdxmimN.js +1 -0
  51. package/build/assets/{manage-backends-modal-buYNliLv.js → manage-backends-modal-DqpzcxdI.js} +1 -1
  52. package/build/assets/{manage-workspaces-modal-BiTj6Z4W.js → manage-workspaces-modal-eG6XgAvw.js} +1 -1
  53. package/build/assets/manifest-f141dc70.js +1 -0
  54. package/build/assets/{markdown-renderer-CeCYDWvz.js → markdown-renderer-wZnLDbA1.js} +1 -1
  55. package/build/assets/{mcp-DSzTA9H1.js → mcp-BdfyCW1l.js} +1 -1
  56. package/build/assets/{messages-x5kGl-bQ.js → messages-BfaEAG2q.js} +1 -1
  57. package/build/assets/{model-selector-CED-tBXx.js → model-selector-7id-Uirf.js} +1 -1
  58. package/build/assets/{navigation-link-C_YVC2i-.js → navigation-link-DFQ7YcWq.js} +1 -1
  59. package/build/assets/{option-service.api-Bqy363N2.js → option-service.api-DN0ZcGjw.js} +1 -1
  60. package/build/assets/{organization-service.api-BAwDUJoL.js → organization-service.api-Ct2dZF8M.js} +1 -1
  61. package/build/assets/{path-utils-3ccf0YXA.js → path-utils-D1ZtqFC7.js} +1 -1
  62. package/build/assets/{planner-tab-b0Q_JZvr.js → planner-tab-yubfN-6U.js} +1 -1
  63. package/build/assets/{profiles-client-Cj9KHwuq.js → profiles-client-D4twHRVf.js} +1 -1
  64. package/build/assets/{providers-CdDNvcEb.js → providers-C2T07PM3.js} +1 -1
  65. package/build/assets/{proxy-3uQm0NJ9.js → proxy-BMZyC45G.js} +1 -1
  66. package/build/assets/query-client-config-CiK0GJJO.js +1 -0
  67. package/build/assets/{recommended-automations-launcher--puKMsm-.js → recommended-automations-launcher-Cx7svuGE.js} +17 -3
  68. package/build/assets/root-layout-DvYGxAnr.js +2 -0
  69. package/build/assets/root-luPHQiBx.js +2 -0
  70. package/build/assets/{sdk-section-page-Dgmjx3Nh.js → sdk-section-page-03k88tIR.js} +1 -1
  71. package/build/assets/{sdk-settings-schema-QrDJfOon.js → sdk-settings-schema-BY8dOy3a.js} +1 -1
  72. package/build/assets/{secrets-service-Dy7jaVk0.js → secrets-service-Z3qtRb_G.js} +1 -1
  73. package/build/assets/{secrets-settings-9X_bB7-j.js → secrets-settings-BnlByuMZ.js} +1 -1
  74. package/build/assets/{server-client-BvA-DepM.js → server-client-CG1zHqph.js} +1 -1
  75. package/build/assets/{settings-CLfgxw_Q.js → settings-DyzGLF_d.js} +1 -1
  76. package/build/assets/{settings-client-DjnapAI3.js → settings-client-CkXDJwIY.js} +1 -1
  77. package/build/assets/{settings-dropdown-input-1bMoP5ld.js → settings-dropdown-input-CAQWQgx-.js} +1 -1
  78. package/build/assets/{settings-index-QV1myqj-.js → settings-index-KtTw49xL.js} +1 -1
  79. package/build/assets/{settings-input-Bz9QClNU.js → settings-input-BWCZt9g2.js} +1 -1
  80. package/build/assets/{settings-list-classes-vFnNAdFx.js → settings-list-classes-xMleGkTC.js} +1 -1
  81. package/build/assets/{settings-modal-CmsyiNtY.js → settings-modal-Cv2YWSUY.js} +1 -1
  82. package/build/assets/{settings-service.api-DfJwVvYA.js → settings-service.api-Z6x0l0GU.js} +1 -1
  83. package/build/assets/{shared-conversation-CsGvti_a.js → shared-conversation-BfZNCsvo.js} +1 -1
  84. package/build/assets/{sidebar-mobile-menu-toggle-CRQrI0ED.js → sidebar-mobile-menu-toggle-DXplko7u.js} +1 -1
  85. package/build/assets/{sidebar-nav-link-qrRmYl8T.js → sidebar-nav-link-B4h8naZ7.js} +1 -1
  86. package/build/assets/{sidebar-store-CUm9qCi_.js → sidebar-store-cOeaKmIm.js} +1 -1
  87. package/build/assets/{skill-card-pill-row-DdaVfIxC.js → skill-card-pill-row-D0oTWx-a.js} +1 -1
  88. package/build/assets/{skills-plugins-BX5zDQC6.js → skills-plugins-BTnp7QcQ.js} +1 -1
  89. package/build/assets/{skills-settings-CuoWDnTN.js → skills-settings-CbOQvzkR.js} +1 -1
  90. package/build/assets/{styled-tooltip-C7QOGK28.js → styled-tooltip-Awq4HMw3.js} +1 -1
  91. package/build/assets/{task-list-tab-Bz7_oCIo.js → task-list-tab-B45ktzHM.js} +1 -1
  92. package/build/assets/{terminal-CRX7ZSEA.js → terminal-D5pzR9Ru.js} +1 -1
  93. package/build/assets/{typography-BqlA_dVV.js → typography-BbaUAC4V.js} +1 -1
  94. package/build/assets/{use-active-conversation-DOLpeZZ5.js → use-active-conversation-Bu5J9iLy.js} +1 -1
  95. package/build/assets/{use-agent-settings-schema-D90oKLgR.js → use-agent-settings-schema-BbtOsR7P.js} +1 -1
  96. package/build/assets/{use-agent-state-BqaILzms.js → use-agent-state-DN9Nc5pP.js} +1 -1
  97. package/build/assets/{use-cloud-current-user-id-Dy9b3ahi.js → use-cloud-current-user-id-B_rMUiu8.js} +1 -1
  98. package/build/assets/{use-config-BD9X1AvI.js → use-config-Bcz2JL2t.js} +1 -1
  99. package/build/assets/{use-conversation-id-DPRiMh48.js → use-conversation-id-BOaaZahn.js} +1 -1
  100. package/build/assets/{use-create-conversation-B4M_yYz3.js → use-create-conversation-BWFA_FId.js} +1 -1
  101. package/build/assets/{use-event-store-DDhcATXi.js → use-event-store-CQZCcVz-.js} +1 -1
  102. package/build/assets/{use-handle-plan-click-Dno7Yfm3.js → use-handle-plan-click-CgrCGmT1.js} +1 -1
  103. package/build/assets/{use-is-creating-conversation-CVum0xhv.js → use-is-creating-conversation-DhoM7UAB.js} +1 -1
  104. package/build/assets/{use-launch-skill-in-chat-sASpuCpy.js → use-launch-skill-in-chat-DOyQsXFO.js} +1 -1
  105. package/build/assets/{use-llm-profiles-DHxXPcrl.js → use-llm-profiles-CAIzHJDX.js} +1 -1
  106. package/build/assets/{use-runtime-is-ready-C-dZi-ZU.js → use-runtime-is-ready-BQWLEyqa.js} +1 -1
  107. package/build/assets/{use-save-settings-pkHKHB31.js → use-save-settings-5m3w89Ph.js} +1 -1
  108. package/build/assets/{use-settings-ClRWXa6p.js → use-settings-DzG0C3vO.js} +1 -1
  109. package/build/assets/{use-settings-nav-items-CDy22kOR.js → use-settings-nav-items-BIsKeX52.js} +1 -1
  110. package/build/assets/use-skills-Cn-78xP1.js +1 -0
  111. package/build/assets/{use-task-list-BwJGWML_.js → use-task-list-Bs90uF2N.js} +1 -1
  112. package/build/assets/{use-unified-vscode-url-DU7On_6w.js → use-unified-vscode-url-C5iI-Z5A.js} +1 -1
  113. package/build/assets/{use-user-conversation-DdUU6uqz.js → use-user-conversation-BCYpbPT1.js} +1 -1
  114. package/build/assets/{vendor~conversation-panel~conversation-CJfSHdwC.js → vendor~conversation-panel~conversation-CbjvWBSu.js} +1 -1
  115. package/build/assets/{vendor~conversation-panel~conversation~index-DZ7eKFW3.js → vendor~conversation-panel~conversation~index-C23ZXO4R.js} +1 -1
  116. package/build/assets/{vendor~entry.client~root~root-layout~home~conversation-panel~conversation~launch~skills-set~jfc6hidu-ksomn5Bg.js → vendor~entry.client~root~root-layout~home~conversation-panel~conversation~launch~skills-set~jfc6hidu-VnmIZrq3.js} +1 -1
  117. package/build/assets/{vendor~home~conversation-panel~conversation~shared-conversation~planner-tab~files-tab-CM_1dibO.js → vendor~home~conversation-panel~conversation~shared-conversation~planner-tab~files-tab-B92czPCF.js} +1 -1
  118. package/build/assets/{vendor~home~conversation-panel~conversation~shared-conversation~planner-tab~files-tab-B-s2ZXN7.js → vendor~home~conversation-panel~conversation~shared-conversation~planner-tab~files-tab-BbFOrAjI.js} +1 -1
  119. package/build/assets/{vendor~home~conversation-panel~conversation~shared-conversation~planner-tab~files-tab-bTqZAHqW.js → vendor~home~conversation-panel~conversation~shared-conversation~planner-tab~files-tab-By5W2oHN.js} +1 -1
  120. package/build/assets/{vendor~home~conversation-panel~conversation~shared-conversation~planner-tab~files-tab-8cYFyeHR.js → vendor~home~conversation-panel~conversation~shared-conversation~planner-tab~files-tab-CofhIDpd.js} +1 -1
  121. package/build/assets/{vendor~home~conversation-panel~conversation~shared-conversation~planner-tab~files-tab-uK_SqCPd.js → vendor~home~conversation-panel~conversation~shared-conversation~planner-tab~files-tab-DpAdkv8m.js} +1 -1
  122. package/build/assets/{vendor~home~mcp~automations-list-a--VL9Np.js → vendor~home~mcp~automations-list-DRfWZRnF.js} +1 -1
  123. package/build/assets/{vendor~home~mcp~llm-settings~agent-settings~condenser-settings~verification-settings~app-se~ocm3mykx-WuKCleb6.js → vendor~home~mcp~llm-settings~agent-settings~condenser-settings~verification-settings~app-se~ocm3mykx-BQPOygpY.js} +2 -2
  124. package/build/assets/{vendor~home~mcp~llm-settings~agent-settings~condenser-settings~verification-settings~app-se~ocm3mykx-BG3to4e4.js → vendor~home~mcp~llm-settings~agent-settings~condenser-settings~verification-settings~app-se~ocm3mykx-CyYIBiBk.js} +1 -1
  125. package/build/assets/{vendor~root-layout~home~conversation-panel~conversation-DL8iX8eY.js → vendor~root-layout~home~conversation-panel~conversation-DjAjXS5J.js} +1 -1
  126. package/build/assets/{vendor~root-layout~home~conversation-panel~conversation~extensions-hub~skills-settings~skil~iguv7bgw-8l0SYWBt.js → vendor~root-layout~home~conversation-panel~conversation~extensions-hub~skills-settings~skil~iguv7bgw-CFpDeb9o.js} +1 -1
  127. package/build/assets/{vendor~root-layout~home~conversation-panel~conversation~extensions-hub~skills-settings~skil~iguv7bgw-CrBN5IsU.js → vendor~root-layout~home~conversation-panel~conversation~extensions-hub~skills-settings~skil~iguv7bgw-CuGq_cxH.js} +1 -1
  128. package/build/assets/{vendor~root-layout~home~conversation-panel~conversation~extensions-hub~skills-settings~skil~k776hupu-DHbj3Bsh.js → vendor~root-layout~home~conversation-panel~conversation~extensions-hub~skills-settings~skil~k776hupu-C1p8-pMr.js} +2 -2
  129. package/build/assets/vendor~root-layout~home~conversation-panel~conversation~launch~extensions-hub~skills-settin~dp08i1qy-BJm2mGIp.js +48 -0
  130. package/build/assets/{verification-settings-CiaMSkli.js → verification-settings-DbziMp4K.js} +1 -1
  131. package/build/assets/{vscode-tab-DkUK-4Xb.js → vscode-tab-BVhQR2rt.js} +1 -1
  132. package/build/index.html +4 -4
  133. package/dist/constants/acp-providers.cjs +1 -1
  134. package/dist/constants/acp-providers.cjs.map +1 -1
  135. package/dist/constants/acp-providers.d.ts +10 -18
  136. package/dist/constants/acp-providers.js +42 -209
  137. package/dist/constants/acp-providers.js.map +1 -1
  138. package/dist/hooks/query/use-paginated-conversations.cjs +1 -1
  139. package/dist/hooks/query/use-paginated-conversations.cjs.map +1 -1
  140. package/dist/hooks/query/use-paginated-conversations.js +2 -1
  141. package/dist/hooks/query/use-paginated-conversations.js.map +1 -1
  142. package/dist/node_modules/@openhands/typescript-client/dist/index.cjs +1 -1
  143. package/dist/node_modules/@openhands/typescript-client/dist/index.js +1 -0
  144. package/dist/node_modules/@openhands/typescript-client/dist/models/acp-providers.cjs +2 -0
  145. package/dist/node_modules/@openhands/typescript-client/dist/models/acp-providers.cjs.map +1 -0
  146. package/dist/node_modules/@openhands/typescript-client/dist/models/acp-providers.js +213 -0
  147. package/dist/node_modules/@openhands/typescript-client/dist/models/acp-providers.js.map +1 -0
  148. package/dist/node_modules/@openhands/typescript-client/dist/models/acp.cjs +2 -0
  149. package/dist/node_modules/@openhands/typescript-client/dist/models/acp.cjs.map +1 -0
  150. package/dist/node_modules/@openhands/typescript-client/dist/models/acp.js +10 -0
  151. package/dist/node_modules/@openhands/typescript-client/dist/models/acp.js.map +1 -0
  152. package/dist/package.cjs +1 -1
  153. package/dist/package.cjs.map +1 -1
  154. package/dist/package.js +3 -3
  155. package/dist/package.js.map +1 -1
  156. package/dist/query-client-config.cjs +1 -1
  157. package/dist/query-client-config.cjs.map +1 -1
  158. package/dist/query-client-config.js +30 -23
  159. package/dist/query-client-config.js.map +1 -1
  160. package/package.json +3 -3
  161. package/scripts/check-sdk-version-sync.mjs +6 -6
  162. package/scripts/dev-safe.mjs +1 -1
  163. package/build/assets/acp-providers-BhOEPsud.js +0 -1
  164. package/build/assets/active-backend-context-jthDtMCD.js +0 -1
  165. package/build/assets/agent-server-conversation-service.api-CA7hOJAy.js +0 -5
  166. package/build/assets/backend-form-modal-DbriBS-v.js +0 -1
  167. package/build/assets/conversation-CDHXbtHw.js +0 -17
  168. package/build/assets/conversation-Dd7NkKCq.js +0 -1
  169. package/build/assets/conversation-panel-BZ1-fw2m.js +0 -1
  170. package/build/assets/conversation-state-store-Dpa4x70O.js +0 -1
  171. package/build/assets/conversation-websocket-context-BEeh-jIG.js +0 -3
  172. package/build/assets/dist-dxViYC8L.js +0 -1
  173. package/build/assets/files-tab-store-ymnFnIBO.js +0 -1
  174. package/build/assets/git-control-bar-branch-button-BzqhhzW4.js +0 -27
  175. package/build/assets/git-provider-icon-Cf-vdwYZ.js +0 -1
  176. package/build/assets/llm-settings-BwVWlOyB.js +0 -1
  177. package/build/assets/manifest-e27751af.js +0 -1
  178. package/build/assets/query-client-config-BtB8Yvpf.js +0 -1
  179. package/build/assets/root-Xt6cd1J6.js +0 -2
  180. package/build/assets/root-layout-Bp7iQEOJ.js +0 -2
  181. package/build/assets/skills-client-DOeT6HEj.js +0 -1
  182. package/build/assets/use-skills-C2S3iOtJ.js +0 -1
  183. package/build/assets/vendor~root-layout~home~conversation-panel~conversation~launch~automations-list~automation-~f57mv2f3-D6ItaxF-.js +0 -48
  184. package/scripts/check-acp-providers-sync.mjs +0 -560
  185. /package/build/assets/{agent-server-client-options-BvlH7qGM.js → agent-server-client-options-8OJSXbm8.js} +0 -0
  186. /package/build/assets/{agent-server-ui-style-scope-DWLieFHA.js → agent-server-ui-style-scope-BwIZYdC1.js} +0 -0
  187. /package/build/assets/{brand-button-BYloqbQ3.js → brand-button-8fVVei4i.js} +0 -0
  188. /package/build/assets/{combobox-caret-C7rVhI_V.js → combobox-caret-BMsz5mQX.js} +0 -0
  189. /package/build/assets/{conversation-local-storage-BQSptoYo.js → conversation-local-storage-UYl-SX-r.js} +0 -0
  190. /package/build/assets/{dist-3eF0ujsw.js → dist-DZHSA2e6.js} +0 -0
  191. /package/build/assets/{environment-switch-store-CBXkf5bS.js → environment-switch-store-C4ulFJKp.js} +0 -0
  192. /package/build/assets/{loading-spinner-D-ea2dZq.js → loading-spinner-91b5FiMQ.js} +0 -0
  193. /package/build/assets/{middleware-iK-zKVe0.js → middleware-BC9EwbB9.js} +0 -0
  194. /package/build/assets/{modal-backdrop-DML21GPD.js → modal-backdrop-B04pVYAD.js} +0 -0
  195. /package/build/assets/{modal-body-RpEv_U1i.js → modal-body-CgUoFQA1.js} +0 -0
  196. /package/build/assets/{modal-close-button-SKLwT3A4.js → modal-close-button-SM_WXzDY.js} +0 -0
  197. /package/build/assets/{navigation-context-DtjWNE3F.js → navigation-context-BFjstyH6.js} +0 -0
  198. /package/build/assets/{objectWithoutPropertiesLoose-SGdQSpMZ.js → objectWithoutPropertiesLoose-Du6eBn-V.js} +0 -0
  199. /package/build/assets/{openhands-logo-BRKD7Ir9.js → openhands-logo-DkDp75rC.js} +0 -0
  200. /package/build/assets/{query-keys-D5xWPArX.js → query-keys-tAsQcc_9.js} +0 -0
  201. /package/build/assets/{react-DMUxGBRt.js → react-Do0CT17Y.js} +0 -0
  202. /package/build/assets/{vendor~entry.client~root~root-layout~home~conversation-panel~conversation~launch~skills-set~zm51vy4j-Csgp2p8o.js → vendor~entry.client~root~root-layout~home~conversation-panel~conversation~launch~skills-set~zm51vy4j-iOsylxCS.js} +0 -0
  203. /package/build/assets/{vendor~root-layout~home~conversation-panel~conversation~extensions-hub~skills-settings~skil~i4kjfqhl-BdNVgtVT.js → vendor~root-layout~home~conversation-panel~conversation~extensions-hub~skills-settings~skil~i4kjfqhl-BebWhFNT.js} +0 -0
  204. /package/build/assets/{vendor~root-layout~home~conversation-panel~conversation~launch~extensions-hub~skills-settin~pfbaerbd-DFFy3NX_.js → vendor~root-layout~home~conversation-panel~conversation~launch~extensions-hub~skills-settin~pfbaerbd-zhv9fooy.js} +0 -0
@@ -1,48 +0,0 @@
1
- import{t as e}from"./rolldown-runtime-BFRubm34.js";import{o as t,s as n}from"./agent-server-client-options-BvlH7qGM.js";var r=class{constructor(e){this.host=e.host.replace(/\/$/,``),this.apiKey=e.apiKey,this.client=new t({baseUrl:this.host,apiKey:this.apiKey,timeout:e.timeout||6e4})}async searchEvents(e={}){return(await this.client.get(`/api/bash/bash_events/search`,{params:e})).data}async getEvent(e){return(await this.client.get(`/api/bash/bash_events/${e}`)).data}async getEvents(e){return Promise.all(e.map(async e=>{try{return await this.getEvent(e)}catch(e){if(e instanceof n&&e.status===404)return null;throw e}}))}async startCommand(e,t,n){let r=this.normalizeRequest(e,t,n);return(await this.client.post(`/api/bash/start_bash_command`,r)).data}async executeCommand(e,t,n){let r=this.normalizeRequest(e,t,n);return(await this.client.post(`/api/bash/execute_bash_command`,r,{timeout:((r.timeout||30)+10)*1e3})).data}async clearEvents(){return(await this.client.delete(`/api/bash/bash_events`)).data}close(){this.client.close()}normalizeRequest(e,t,n){return typeof e==`string`?{command:e,...t?{cwd:t}:{},...n===void 0?{}:{timeout:Math.floor(n)}}:{...e,...e.timeout===void 0?{}:{timeout:Math.floor(e.timeout)}}}},i=`AGENT_SERVER_VERSION_TOO_OLD`,a={workspaces:{feature:`workspaces`,displayName:`Workspaces`,minVersion:`1.23.0`},hooks:{feature:`hooks`,displayName:`Hooks API`,minVersion:`1.23.0`},mcpTest:{feature:`mcp-test`,displayName:`MCP test API`,minVersion:`1.23.0`},cloudProxy:{feature:`cloud-proxy`,displayName:`Cloud proxy`,minVersion:`1.23.0`}},o=class e extends Error{constructor({requirement:t,actualVersion:n}){super(`${t.displayName} requires agent-server ${t.minVersion} or newer; this backend is running ${n}. Please upgrade your agent-server backend.`),this.code=i,this.name=`AgentServerVersionError`,this.feature=t.feature,this.displayName=t.displayName,this.requiredVersion=t.minVersion,this.actualVersion=n,Object.setPrototypeOf(this,e.prototype)}},s=new WeakMap;function c(e){return e instanceof o||typeof e==`object`&&!!e&&`code`in e&&e.code===`AGENT_SERVER_VERSION_TOO_OLD`}async function l(e){let t=s.get(e);if(t)return t;let n=e.get(`/server_info`).then(e=>e.data);return s.set(e,n),n}async function u(e,t){let n=await l(e),r=typeof n.version==`string`&&n.version.trim()?n.version.trim():`unknown`,i=d(r,t.minVersion);if(i===null||i<0)throw new o({requirement:t,actualVersion:r});return n}function d(e,t){let n=f(e),r=f(t);if(!n||!r)return null;for(let e of[`major`,`minor`,`patch`]){if(n[e]>r[e])return 1;if(n[e]<r[e])return-1}return n.prerelease&&!r.prerelease?-1:!n.prerelease&&r.prerelease?1:n.prerelease&&r.prerelease?n.prerelease.localeCompare(r.prerelease):0}function f(e){let[t]=e.trim().replace(/^v/,``).split(`+`),[n,r]=t.split(`-`,2),i=n.split(`.`);if(i.length!==3)return null;let[a,o,s]=i.map(e=>Number(e));return[a,o,s].every(e=>Number.isInteger(e)&&e>=0)?{major:a,minor:o,patch:s,prerelease:r}:null}var p=class{constructor(e){this.host=e.host.replace(/\/$/,``),this.apiKey=e.apiKey,this.client=new t({baseUrl:this.host,apiKey:this.apiKey,timeout:e.timeout||6e4})}async createConversation(e){return(await this.client.post(`/api/conversations`,e)).data}async searchConversations(e={}){return(await this.client.get(`/api/conversations/search`,{params:e})).data}async countConversations(e={}){return(await this.client.get(`/api/conversations/count`,{params:e})).data}async getConversations(e){return(await this.client.get(`/api/conversations`,{params:{ids:e}})).data}async getConversation(e){return(await this.client.get(`/api/conversations/${e}`)).data}async searchEvents(e,t={}){return(await this.client.get(`/api/conversations/${e}/events/search`,{params:t})).data}async getEvent(e,t){return(await this.client.get(`/api/conversations/${e}/events/${t}`)).data}async getEvents(e,t){return Promise.all(t.map(async t=>{try{return await this.getEvent(e,t)}catch(e){if(e instanceof n&&e.status===404)return null;throw e}}))}async sendEvent(e,t,n={}){await this.client.post(`/api/conversations/${e}/events`,{...t,...n.run===void 0?{}:{run:n.run}})}async pauseConversation(e){return(await this.client.post(`/api/conversations/${e}/pause`,{})).data}async interruptConversation(e){return(await this.client.post(`/api/conversations/${e}/interrupt`,{})).data}async runConversation(e){return(await this.client.post(`/api/conversations/${e}/run`,{})).data}async askAgent(e,t){return(await this.client.post(`/api/conversations/${e}/ask_agent`,{question:t})).data}async getEventCount(e,t={}){return(await this.client.get(`/api/conversations/${e}/events/count`,{params:t})).data}async respondToConfirmation(e,t){return(await this.client.post(`/api/conversations/${e}/events/respond_to_confirmation`,t)).data}async getAgentFinalResponse(e){return(await this.client.get(`/api/conversations/${e}/agent_final_response`)).data}async setConfirmationPolicy(e,t){let n=`policy`in t?t:{policy:t};return(await this.client.post(`/api/conversations/${e}/confirmation_policy`,n)).data}async condenseConversation(e){return(await this.client.post(`/api/conversations/${e}/condense`,{})).data}async setSecurityAnalyzer(e,t){let n=m(t)?t:{security_analyzer:t};return(await this.client.post(`/api/conversations/${e}/security_analyzer`,n)).data}async updateSecrets(e,t){return(await this.client.post(`/api/conversations/${e}/secrets`,t)).data}async forkConversation(e,t={},n={}){return(await this.client.post(`/api/conversations/${e}/fork`,t,{params:n.includeSkills===void 0?void 0:{include_skills:n.includeSkills}})).data}async switchProfile(e,t){await this.client.post(`/api/conversations/${e}/switch_profile`,{profile_name:t})}async switchLLM(e,t){await this.client.post(`/api/conversations/${e}/switch_llm`,{llm:t})}async deleteConversation(e){await this.client.delete(`/api/conversations/${e}`)}async updateConversation(e,t){return(await this.client.patch(`/api/conversations/${e}`,t)).data}close(){this.client.close()}};function m(e){return typeof e==`object`&&!!e&&`security_analyzer`in e}var h=class{constructor(e){this.host=e.host.replace(/\/$/,``),this.apiKey=e.apiKey,this.client=new t({baseUrl:this.host,apiKey:this.apiKey,timeout:e.timeout||6e4})}async searchSubdirectories(e,t={}){return(await this.client.get(`/api/file/search_subdirs`,{params:{path:e,page_id:t.pageId,limit:t.limit}})).data}async getHome(){return(await this.client.get(`/api/file/home`)).data}async downloadFile(e){return(await this.client.get(`/api/file/download`,{params:{path:e},responseType:`arrayBuffer`})).data}async downloadTextFile(e){return new TextDecoder().decode(await this.downloadFile(e))}async uploadFile(e,t,n){let r=new FormData,i=typeof File>`u`?void 0:File;return i&&e instanceof i?r.append(`file`,e,n||e.name):e instanceof Blob?r.append(`file`,e,n||`blob-file`):r.append(`file`,new Blob([e],{type:`text/plain`}),n||`text-file.txt`),(await this.client.post(`/api/file/upload`,r,{params:{path:t}})).data}async uploadTextFile(e,t,n){return this.uploadFile(e,t,n)}async downloadTrajectory(e){return(await this.client.get(`/api/file/download-trajectory/${encodeURIComponent(e)}`,{responseType:`blob`})).data}close(){this.client.close()}},g=class{constructor(e){this.host=e.host.replace(/\/$/,``),this.apiKey=e.apiKey,this.client=new t({baseUrl:this.host,apiKey:this.apiKey,timeout:e.timeout||6e4})}async getUrl(e={}){return(await this.client.get(`/api/vscode/url`,{params:{...e.baseUrl?{base_url:e.baseUrl}:{},...e.workspaceDir?{workspace_dir:e.workspaceDir}:{}}})).data.url}async getStatus(){return(await this.client.get(`/api/vscode/status`)).data}close(){this.client.close()}},_=class{constructor(e){this.host=e.host.replace(/\/$/,``),this.apiKey=e.apiKey,this.client=new t({baseUrl:this.host,apiKey:this.apiKey,timeout:e.timeout||6e4})}async getSharedConversations(e){return(await this.client.get(`/api/shared-conversations`,{params:{ids:e}})).data}async getSharedConversation(e){return(await this.getSharedConversations([e]))[0]??null}async searchSharedEvents(e){return(await this.client.get(`/api/shared-events/search`,{params:{conversation_id:e.conversationId,limit:e.limit,page_id:e.pageId}})).data}close(){this.client.close()}},v=class{constructor(e){this.host=e.host.replace(/\/$/,``),this.apiKey=e.apiKey,this.client=new t({baseUrl:this.host,apiKey:this.apiKey,timeout:e.timeout||6e4})}async listWorkspaces(){return await this.ensureWorkspacesSupported(),(await this.client.get(`/api/workspaces`)).data}async addWorkspaces(e){return await this.ensureWorkspacesSupported(),(await this.client.post(`/api/workspaces`,{workspaces:e})).data}async deleteWorkspace(e){return await this.ensureWorkspacesSupported(),(await this.client.delete(`/api/workspaces`,{params:{path:e}})).data}async addWorkspaceParents(e){return await this.ensureWorkspacesSupported(),(await this.client.post(`/api/workspaces/parents`,{parents:e})).data}async deleteWorkspaceParent(e){return await this.ensureWorkspacesSupported(),(await this.client.delete(`/api/workspaces/parents`,{params:{path:e}})).data}close(){this.client.close()}async ensureWorkspacesSupported(){await u(this.client,a.workspaces)}},y=e(((e,t)=>{t.exports=function(){throw Error(`ws does not work in the browser. Browser clients must use the native WebSocket object`)}}));if(typeof window<`u`&&window.WebSocket)window.WebSocket;else try{y()}catch{}var b=class{constructor(e,n){this.cachedEvents=[],this.cachedEventIds=new Set,this.client=e instanceof t?e:new t(e),this.conversationId=n}async search(e={}){let t={limit:e.limit??100};return e.page_id&&(t.page_id=e.page_id),e.kind&&(t.kind=e.kind),e.source&&(t.source=e.source),e.body&&(t.body=e.body),e.sort_order&&(t.sort_order=e.sort_order),e.timestamp__gte&&(t.timestamp__gte=e.timestamp__gte),e.timestamp__lt&&(t.timestamp__lt=e.timestamp__lt),(await this.client.get(`/api/conversations/${this.conversationId}/events/search`,{params:t})).data}async count(e={}){let t={};return e.kind&&(t.kind=e.kind),e.source&&(t.source=e.source),e.body&&(t.body=e.body),e.timestamp__gte&&(t.timestamp__gte=e.timestamp__gte),e.timestamp__lt&&(t.timestamp__lt=e.timestamp__lt),(await this.client.get(`/api/conversations/${this.conversationId}/events/count`,{params:t})).data}async getEventById(e){return(await this.client.get(`/api/conversations/${this.conversationId}/events/${e}`)).data}async getEventsById(e){return Promise.all(e.map(async e=>{try{return await this.getEventById(e)}catch(e){if(e instanceof n&&e.status===404)return null;throw e}}))}async addEvent(e){this.cachedEventIds.has(e.id)||(this.cachedEvents.push(e),this.cachedEventIds.add(e.id))}async append(e){await this.addEvent(e)}createDefaultCallback(e){return t=>{this.addEvent(t).catch(t=>{e&&e(t instanceof Error?t:Error(`Error adding event to cache: ${t}`))})}}async length(){return this.cachedEvents.length}async getEvent(e){return this.cachedEvents[e]}async getEvents(e,t){let n=[],r;for(;;){let e={limit:100};r&&(e.page_id=r);let t=(await this.client.get(`/api/conversations/${this.conversationId}/events/search`,{params:e})).data;if(n.push(...t.items),!t.next_page_id)break;r=t.next_page_id}let i=new Set(n.map(e=>e.id)),a=[...n,...this.cachedEvents.filter(e=>!i.has(e.id))];return e===void 0&&t===void 0?a:a.slice(e,t)}async*[Symbol.asyncIterator](){let e=await this.getEvents();for(let t of e)yield t}},x=`__full_state__`,S=class e{constructor(e,t){this.cachedState=null,this.cachedAt=0,this.lock=new C,this.client=e,this.conversationId=t,this._events=new b(e,t)}async getConversationInfo(){return await this.lock.acquire(async()=>{if(this.cachedState!==null&&Date.now()-this.cachedAt<e.CACHE_TTL_MS)return this.cachedState;let t=await this.client.get(`/api/conversations/${this.conversationId}`),n;return n=t.data.full_state?t.data.full_state:t.data,this.cachedState=n,this.cachedAt=Date.now(),n})}async refresh(){return this.cachedState=null,this.getConversationInfo()}async updateStateFromEvent(e){await this.lock.acquire(async()=>{if(e.key===x){this.cachedState===null&&(this.cachedState={});let t=e.value?.full_state??e.value;Object.assign(this.cachedState,t)}else this.cachedState===null&&(this.cachedState={}),this.cachedState[e.key]=e.value;this.cachedAt=Date.now()})}createStateUpdateCallback(e){return t=>{t.kind===`ConversationStateUpdateEvent`&&this.updateStateFromEvent(t).catch(t=>{e&&e(t instanceof Error?t:Error(`Error updating state from event: ${t}`))})}}get events(){return this._events}get id(){return this.conversationId}unwrapState(e){return e.full_state??e}async getExecutionStatus(){let e=await this.getConversationInfo(),t=this.unwrapState(e),n=t.execution_status??t.agent_status;if(n==null)throw Error(`execution_status missing in conversation info: ${JSON.stringify(e)}`);return n}async getAgentStatus(){return this.getExecutionStatus()}async setAgentStatus(e){throw Error(`Setting execution_status on RemoteState has no effect. Remote execution status is managed server-side. Attempted to set: ${e}`)}async getConfirmationPolicy(){let e=await this.getConversationInfo(),t=this.unwrapState(e).confirmation_policy;if(t==null)throw Error(`confirmation_policy missing in conversation info: ${JSON.stringify(e)}`);return t}async getActivatedKnowledgeSkills(){let e=await this.getConversationInfo();return this.unwrapState(e).activated_knowledge_skills||[]}async getAgent(){let e=await this.getConversationInfo(),t=this.unwrapState(e).agent;if(t==null)throw Error(`agent missing in conversation info: ${JSON.stringify(e)}`);return t}async getWorkspace(){let e=await this.getConversationInfo(),t=this.unwrapState(e).workspace;if(t==null)throw Error(`workspace missing in conversation info: ${JSON.stringify(e)}`);return t}async getPersistenceDir(){let e=await this.getConversationInfo(),t=this.unwrapState(e).persistence_dir;if(t==null)throw Error(`persistence_dir missing in conversation info: ${JSON.stringify(e)}`);return t}async modelDump(){let e=await this.getConversationInfo();return this.unwrapState(e)}async modelDumpJson(){let e=await this.modelDump();return JSON.stringify(e)}};S.CACHE_TTL_MS=2e3;var C=class{constructor(){this.locked=!1,this.queue=[]}async acquire(e){return new Promise((t,n)=>{let r=async()=>{try{t(await e())}catch(e){n(e)}finally{this.locked=!1;let e=this.queue.shift();e&&e()}};this.locked?this.queue.push(r):(this.locked=!0,r())})}},w=class{constructor(e){this.host=e.host.replace(/\/$/,``),this.workingDir=e.workingDir,this.apiKey=e.apiKey,this.client=new t({baseUrl:this.host,apiKey:this.apiKey,timeout:6e4}),this.bash=new r({host:this.host,...this.apiKey?{apiKey:this.apiKey}:{}})}async startWorkspaceSession(e){return await this.client.post(`/api/auth/workspace-session`,void 0,{credentials:`include`}),`${this.host}/api/conversations/${e}/workspace/`}async deleteWorkspaceSession(){await this.client.delete(`/api/auth/workspace-session`,{credentials:`include`,acceptableStatusCodes:new Set([204])})}async executeCommand(e,t,n=30){let r={command:e,timeout:Math.floor(n)};t&&(r.cwd=t);let i=(await this.client.post(`/api/bash/execute_bash_command`,r,{timeout:(n+10)*1e3})).data;return{command:e,exit_code:i.exit_code??0,stdout:i.stdout||``,stderr:i.stderr||``,timeout_occurred:!1}}async fileUpload(e,t,n){let r=new FormData,i,a;e instanceof File?(i=e,a=n||e.name):e instanceof Blob?(i=e,a=n||`blob-file`):(i=new Blob([e],{type:`text/plain`}),a=n||`text-file.txt`),r.append(`file`,i,a);let o=(await this.client.request({method:`POST`,url:`/api/file/upload`,params:{path:t},data:r,timeout:6e4})).data;return{success:o.success??!0,source_path:a,destination_path:t,file_size:o.file_size,error:o.error}}async fileDownload(e){let t=await this.client.get(`/api/file/download`,{params:{path:e},timeout:6e4}),n,r;if(typeof t.data==`string`)n=t.data,r=new Blob([t.data]).size;else if(t.data instanceof ArrayBuffer)n=new Blob([t.data]),r=t.data.byteLength;else if(t.data instanceof Blob)n=t.data,r=t.data.size;else{let e=JSON.stringify(t.data);n=e,r=new Blob([e]).size}return{success:!0,source_path:e,content:n,file_size:r}}async gitChanges(e,t={}){let n={path:e};t.ref!==void 0&&(n.ref=t.ref);try{return(await this.client.get(`/api/git/changes`,{params:n})).data}catch(e){throw Error(`Failed to get git changes: ${e instanceof Error?e.message:String(e)}`,{cause:e})}}async gitDiff(e,t={}){let n={path:e};t.ref!==void 0&&(n.ref=t.ref);try{return(await this.client.get(`/api/git/diff`,{params:n})).data}catch(e){throw Error(`Failed to get git diff: ${e instanceof Error?e.message:String(e)}`,{cause:e})}}async uploadText(e,t,n){return this.fileUpload(e,t,n)}async uploadFileObject(e,t){return this.fileUpload(e,t)}async downloadAsText(e){let t=await this.fileDownload(e);if(!t.success)throw Error(t.error||`Download failed`);return typeof t.content==`string`?t.content:t.content instanceof Blob?await t.content.text():``}async downloadAsBlob(e){let t=await this.fileDownload(e);if(!t.success)throw Error(t.error||`Download failed`);return t.content instanceof Blob?t.content:typeof t.content==`string`?new Blob([t.content],{type:`text/plain`}):new Blob}async downloadAndSave(e,t){let n=await this.downloadAsBlob(e),r=URL.createObjectURL(n),i=document.createElement(`a`);i.href=r,i.download=t||e.split(`/`).pop()||`download`,document.body.appendChild(i),i.click(),document.body.removeChild(i),URL.revokeObjectURL(r)}close(){this.bash.close(),this.client.close()}},T={execute_command:`Execute a bash command in the terminal within a persistent shell session.
2
-
3
- ### Command Execution
4
- * One command at a time: You can only execute one bash command at a time. If you need to run multiple commands sequentially, use \`&&\` or \`;\` to chain them together.
5
- * Persistent session: Commands execute in a persistent shell session where environment variables, virtual environments, and working directory persist between commands.
6
-
7
- ### Best Practices
8
- * Directory verification: Before creating new directories or files, first verify the parent directory exists and is the correct location.
9
- * Directory management: Try to maintain working directory by using absolute paths and avoiding excessive use of \`cd\`.
10
-
11
- ### Output Handling
12
- * Output truncation: If the output exceeds a maximum length, it will be truncated before being returned.`,read_file:`Read the contents of a file from the workspace.
13
-
14
- Custom editing tool for viewing, creating and editing files in plain-text format.
15
- * If \`path\` is a text file, returns the file contents with line numbers
16
- * If \`path\` is a directory, lists non-hidden files and directories up to 2 levels deep
17
-
18
- Best practices:
19
- * Use this tool to understand the file's contents and context before making edits
20
- * Verify the directory path is correct when working with files`,write_file:`Write content to a file in the workspace. Creates the file if it does not exist.
21
-
22
- When making edits:
23
- * Ensure the edit results in idiomatic, correct code
24
- * Do not leave the code in a broken state
25
- * Always use absolute file paths (starting with /)
26
-
27
- CRITICAL REQUIREMENTS:
28
- * The content should be the complete file content, not a diff or patch
29
- * Ensure proper formatting and indentation`,think:`Use the tool to think about something. It will not obtain new information or make any changes to the repository, but just log the thought. Use it when complex reasoning or brainstorming is needed.
30
-
31
- Common use cases:
32
- 1. When exploring a repository and discovering the source of a bug, call this tool to brainstorm several unique ways of fixing the bug, and assess which change(s) are likely to be simplest and most effective.
33
- 2. After receiving test results, use this tool to brainstorm ways to fix failing tests.
34
- 3. When planning a complex refactoring, use this tool to outline different approaches and their tradeoffs.
35
- 4. When designing a new feature, use this tool to think through architecture decisions and implementation details.
36
- 5. When debugging a complex issue, use this tool to organize your thoughts and hypotheses.
37
-
38
- The tool simply logs your thought process for better transparency and does not execute any code or make changes.`,finish:`Signals the completion of the current task or conversation.
39
-
40
- Use this tool when:
41
- - You have successfully completed the user's requested task
42
- - You cannot proceed further due to technical limitations or missing information
43
-
44
- The message should include:
45
- - A clear summary of actions taken and their results
46
- - Any next steps for the user
47
- - Explanation if you're unable to complete the task
48
- - Any follow-up questions if more information is needed`};T.execute_command,T.read_file,T.write_file,T.think,T.finish;var E;(function(e){e.PRE_TOOL_USE=`PreToolUse`,e.POST_TOOL_USE=`PostToolUse`,e.USER_PROMPT_SUBMIT=`UserPromptSubmit`,e.SESSION_START=`SessionStart`,e.SESSION_END=`SessionEnd`,e.STOP=`Stop`})(E||={});var D;(function(e){e.COMMAND=`command`,e.PROMPT=`prompt`})(D||={});var O;if((function(e){e.ALLOW=`allow`,e.DENY=`deny`})(O||={}),new Set(`|.*+?[]()^$\\`.split(``)),typeof window<`u`&&window.WebSocket)window.WebSocket;else try{y()}catch{}var k;(function(e){e.TIMESTAMP=`TIMESTAMP`,e.TIMESTAMP_DESC=`TIMESTAMP_DESC`})(k||={}),(function(e){e.REVERSE_TIMESTAMP=`TIMESTAMP_DESC`})(k||={});var A;(function(e){e.IDLE=`idle`,e.RUNNING=`running`,e.PAUSED=`paused`,e.WAITING_FOR_CONFIRMATION=`waiting_for_confirmation`,e.FINISHED=`finished`,e.ERROR=`error`,e.STUCK=`stuck`,e.DELETING=`deleting`})(A||={});var j;(function(e){e.CREATED_AT=`CREATED_AT`,e.UPDATED_AT=`UPDATED_AT`,e.CREATED_AT_DESC=`CREATED_AT_DESC`,e.UPDATED_AT_DESC=`UPDATED_AT_DESC`})(j||={});var M=[];for(let e=0;e<256;++e)M.push((e+256).toString(16).slice(1));function N(e,t=0){return(M[e[t+0]]+M[e[t+1]]+M[e[t+2]]+M[e[t+3]]+`-`+M[e[t+4]]+M[e[t+5]]+`-`+M[e[t+6]]+M[e[t+7]]+`-`+M[e[t+8]]+M[e[t+9]]+`-`+M[e[t+10]]+M[e[t+11]]+M[e[t+12]]+M[e[t+13]]+M[e[t+14]]+M[e[t+15]]).toLowerCase()}var P=new Uint8Array(16);function F(){return crypto.getRandomValues(P)}function I(e,t,n){return!t&&!e&&crypto.randomUUID?crypto.randomUUID():L(e,t,n)}function L(e,t,n){e||={};let r=e.random??e.rng?.()??F();if(r.length<16)throw Error(`Random bytes length must be >= 16`);if(r[6]=r[6]&15|64,r[8]=r[8]&63|128,t){if(n||=0,n<0||n+16>t.length)throw RangeError(`UUID byte range ${n}:${n+15} is out of buffer bounds`);for(let e=0;e<16;++e)t[n+e]=r[e];return t}return N(r)}export{v as a,h as c,r as d,b as i,p as l,j as n,_ as o,w as r,g as s,I as t,c as u};
@@ -1,560 +0,0 @@
1
- #!/usr/bin/env node
2
-
3
- /**
4
- * Check ACP Providers Sync
5
- *
6
- * Verifies the canvas TypeScript mirror in ``src/constants/acp-providers.ts``
7
- * stays in lockstep with the Python source of truth at
8
- * ``openhands-sdk/openhands/sdk/settings/acp_providers.py`` in
9
- * https://github.com/OpenHands/software-agent-sdk.
10
- *
11
- * Why this exists (#587): the registries can drift silently and the failure
12
- * mode is invisible — a stale ``default_command`` spawns a CLI that doesn't
13
- * speak ACP and the agent-server deadlocks on the handshake (we shipped
14
- * ``["npx","-y","@openai/codex","acp"]`` once and it took an E2E session to
15
- * find). This check fails CI before that ships.
16
- *
17
- * Compared fields (the subset the TS mirror actually carries):
18
- * - key
19
- * - display_name
20
- * - default_command
21
- *
22
- * The richer SDK record (api_key_env_var, base_url_env_var, session mode,
23
- * agent_name_patterns, supports_set_session_model, session_meta_key) is
24
- * intentionally NOT mirrored on the canvas side — canvas only uses this
25
- * registry in Settings → Agent + onboarding tile rendering. Those fields
26
- * live in the SDK because ``ACPAgent`` reads them at spawn time inside
27
- * the agent-server, where canvas never runs.
28
- *
29
- * Usage:
30
- * node scripts/check-acp-providers-sync.mjs
31
- * node scripts/check-acp-providers-sync.mjs --sdk-ref v1.23.0
32
- * node scripts/check-acp-providers-sync.mjs --sdk-file /path/to/acp_providers.py
33
- *
34
- * Options:
35
- * --sdk-ref <ref> Git ref in OpenHands/software-agent-sdk to fetch
36
- * acp_providers.py from. Default: ``main``. Also
37
- * overridable via ``ACP_SDK_REF`` env var.
38
- * --sdk-repo <owner/name> Override the SDK repo (default
39
- * ``OpenHands/software-agent-sdk``).
40
- * --sdk-file <path> Read the Python source from a local file instead
41
- * of GitHub. Wins over --sdk-ref. Useful for testing
42
- * offline or against a local SDK checkout.
43
- * --ts-file <path> Override the TS mirror path (default
44
- * ``src/constants/acp-providers.ts``).
45
- * --json Emit a machine-readable summary on stdout
46
- * (the human-readable report still goes to stderr).
47
- * --help, -h Show help.
48
- *
49
- * Exit codes:
50
- * 0 — Registries match on the compared fields.
51
- * 1 — Drift detected, or parse/fetch error.
52
- */
53
-
54
- import { readFileSync } from "node:fs";
55
- import { dirname, join, resolve } from "node:path";
56
- import { fileURLToPath } from "node:url";
57
- import process from "node:process";
58
-
59
- const __dirname = dirname(fileURLToPath(import.meta.url));
60
- const projectRoot = join(__dirname, "..");
61
-
62
- const DEFAULT_SDK_REPO = "OpenHands/software-agent-sdk";
63
- const DEFAULT_SDK_PATH =
64
- "openhands-sdk/openhands/sdk/settings/acp_providers.py";
65
- const DEFAULT_TS_PATH = join(
66
- projectRoot,
67
- "src",
68
- "constants",
69
- "acp-providers.ts",
70
- );
71
-
72
- const colors = {
73
- reset: "\x1b[0m",
74
- red: "\x1b[31m",
75
- green: "\x1b[32m",
76
- yellow: "\x1b[33m",
77
- cyan: "\x1b[36m",
78
- dim: "\x1b[2m",
79
- };
80
-
81
- function parseArgs(argv) {
82
- const args = {
83
- help: false,
84
- sdkFile: null,
85
- sdkRef: process.env.ACP_SDK_REF || "main",
86
- sdkRepo: DEFAULT_SDK_REPO,
87
- tsFile: DEFAULT_TS_PATH,
88
- json: false,
89
- };
90
- for (let i = 0; i < argv.length; i++) {
91
- const a = argv[i];
92
- if (a === "--help" || a === "-h") args.help = true;
93
- else if (a === "--sdk-file") args.sdkFile = argv[++i];
94
- else if (a === "--sdk-ref") args.sdkRef = argv[++i];
95
- else if (a === "--sdk-repo") args.sdkRepo = argv[++i];
96
- else if (a === "--ts-file") args.tsFile = argv[++i];
97
- else if (a === "--json") args.json = true;
98
- else throw new Error(`Unknown argument: ${a}`);
99
- }
100
- return args;
101
- }
102
-
103
- function showHelp() {
104
- process.stdout.write(
105
- `\nACP Providers Sync Check\n\n` +
106
- `Verifies that src/constants/acp-providers.ts matches the SDK's\n` +
107
- `acp_providers.py on the fields canvas mirrors (key, display_name,\n` +
108
- `default_command).\n\n` +
109
- `Usage:\n` +
110
- ` node scripts/check-acp-providers-sync.mjs [options]\n\n` +
111
- `Options:\n` +
112
- ` --sdk-ref <ref> Git ref to fetch from (default: main, env ACP_SDK_REF)\n` +
113
- ` --sdk-repo <owner/name> Override SDK repo (default: ${DEFAULT_SDK_REPO})\n` +
114
- ` --sdk-file <path> Read Python source from a local path instead\n` +
115
- ` --ts-file <path> Override TS mirror path\n` +
116
- ` --json Emit JSON summary on stdout\n` +
117
- ` --help, -h Show this help\n\n` +
118
- `Exit codes: 0 = in sync, 1 = drift or error.\n\n`,
119
- );
120
- }
121
-
122
- /**
123
- * String-aware brace matcher. Skips characters inside ``"…"`` / ``'…'``
124
- * (with backslash escapes), Python triple-quoted strings, ``#`` line
125
- * comments, and JS ``//`` / ``/* … *\/`` comments — anywhere we know
126
- * the source file might legitimately contain the delimiter without
127
- * meaning a real depth change. Returns the index of the matching close
128
- * delimiter or -1 if none.
129
- */
130
- function findMatchingDelimiter(source, openIdx, open, close) {
131
- let depth = 0;
132
- let i = openIdx;
133
- while (i < source.length) {
134
- const c = source[i];
135
- // Python triple-quoted strings.
136
- if (
137
- (c === '"' || c === "'") &&
138
- source[i + 1] === c &&
139
- source[i + 2] === c
140
- ) {
141
- const q = c;
142
- i += 3;
143
- while (i < source.length - 2) {
144
- if (source[i] === q && source[i + 1] === q && source[i + 2] === q) {
145
- i += 3;
146
- break;
147
- }
148
- i++;
149
- }
150
- continue;
151
- }
152
- if (c === '"' || c === "'" || c === "`") {
153
- const q = c;
154
- i++;
155
- while (i < source.length) {
156
- if (source[i] === "\\") {
157
- i += 2;
158
- continue;
159
- }
160
- if (source[i] === q) {
161
- i++;
162
- break;
163
- }
164
- i++;
165
- }
166
- continue;
167
- }
168
- if (c === "#") {
169
- while (i < source.length && source[i] !== "\n") i++;
170
- continue;
171
- }
172
- if (c === "/" && source[i + 1] === "/") {
173
- while (i < source.length && source[i] !== "\n") i++;
174
- continue;
175
- }
176
- if (c === "/" && source[i + 1] === "*") {
177
- i += 2;
178
- while (
179
- i < source.length - 1 &&
180
- !(source[i] === "*" && source[i + 1] === "/")
181
- )
182
- i++;
183
- i += 2;
184
- continue;
185
- }
186
- if (c === open) depth++;
187
- else if (c === close) {
188
- depth--;
189
- if (depth === 0) return i;
190
- }
191
- i++;
192
- }
193
- return -1;
194
- }
195
-
196
- /** Extract the contents of every double-quoted string literal in ``s``, in order. */
197
- function extractStringList(s) {
198
- const out = [];
199
- const re = /"((?:\\.|[^"\\])*)"/g;
200
- let m;
201
- while ((m = re.exec(s)) !== null) {
202
- // Resolve the common escapes we might see in command tokens.
203
- out.push(m[1].replace(/\\(.)/g, "$1"));
204
- }
205
- return out;
206
- }
207
-
208
- /**
209
- * Parse the SDK Python source and return one record per provider entry:
210
- * { mapKey, key, display_name, default_command }
211
- *
212
- * ``mapKey`` is the outer mapping key (``"claude-code"`` in the example
213
- * below); ``key`` is the ``key=...`` argument inside ``ACPProviderInfo``.
214
- * They should always agree in practice, but we surface them separately
215
- * so a drift between them is caught as a field mismatch rather than
216
- * silently dropped.
217
- *
218
- * Expected shape:
219
- * ACP_PROVIDERS: Mapping[str, ACPProviderInfo] = MappingProxyType(
220
- * {
221
- * "claude-code": ACPProviderInfo(
222
- * key="claude-code",
223
- * display_name="Claude Code",
224
- * default_command=("npx", "-y", "@…"),
225
- * …
226
- * ),
227
- * …
228
- * }
229
- * )
230
- */
231
- export function parsePython(source) {
232
- const startMatch = source.match(
233
- /ACP_PROVIDERS\s*:\s*Mapping[^=]*=\s*MappingProxyType\s*\(\s*\{/,
234
- );
235
- if (!startMatch) {
236
- throw new Error(
237
- "Could not find `ACP_PROVIDERS: Mapping[...] = MappingProxyType({...})` in Python source",
238
- );
239
- }
240
- const braceIdx = startMatch.index + startMatch[0].length - 1;
241
- const mapEnd = findMatchingDelimiter(source, braceIdx, "{", "}");
242
- if (mapEnd === -1)
243
- throw new Error("Unclosed `ACP_PROVIDERS` mapping literal");
244
- const body = source.slice(braceIdx + 1, mapEnd);
245
-
246
- const records = [];
247
- const reEntry = /"([^"]+)"\s*:\s*ACPProviderInfo\s*\(/g;
248
- let m;
249
- while ((m = reEntry.exec(body)) !== null) {
250
- const mapKey = m[1];
251
- const parenStart = m.index + m[0].length - 1;
252
- const parenEnd = findMatchingDelimiter(body, parenStart, "(", ")");
253
- if (parenEnd === -1)
254
- throw new Error(`Unclosed ACPProviderInfo(...) for ${mapKey}`);
255
- const inner = body.slice(parenStart + 1, parenEnd);
256
-
257
- const keyMatch = inner.match(/\bkey\s*=\s*"([^"]+)"/);
258
- const dnMatch = inner.match(/\bdisplay_name\s*=\s*"([^"]+)"/);
259
- if (!keyMatch || !dnMatch) {
260
- throw new Error(
261
- `Failed to parse key/display_name for Python provider ${mapKey}`,
262
- );
263
- }
264
- // default_command is a tuple — match the keyword then balance the opening `(`.
265
- const dcKwMatch = inner.match(/\bdefault_command\s*=\s*\(/);
266
- if (!dcKwMatch) {
267
- throw new Error(
268
- `Failed to find default_command tuple for Python provider ${mapKey}`,
269
- );
270
- }
271
- const dcOpen = dcKwMatch.index + dcKwMatch[0].length - 1;
272
- const dcClose = findMatchingDelimiter(inner, dcOpen, "(", ")");
273
- if (dcClose === -1)
274
- throw new Error(`Unclosed default_command tuple for ${mapKey}`);
275
- const default_command = extractStringList(inner.slice(dcOpen + 1, dcClose));
276
-
277
- records.push({
278
- mapKey,
279
- key: keyMatch[1],
280
- display_name: dnMatch[1],
281
- default_command,
282
- });
283
- }
284
- if (records.length === 0) {
285
- throw new Error("No ACPProviderInfo entries found in Python source");
286
- }
287
- return records;
288
- }
289
-
290
- /**
291
- * Parse ``export const ACP_PROVIDERS: ACPProviderConfig[] = [...]`` and
292
- * return one record per object literal:
293
- * { key, display_name, default_command }
294
- */
295
- export function parseTypeScript(source) {
296
- const m = source.match(
297
- /export\s+const\s+ACP_PROVIDERS\s*:\s*ACPProviderConfig\[\]\s*=\s*\[/,
298
- );
299
- if (!m) {
300
- throw new Error(
301
- "Could not find `export const ACP_PROVIDERS: ACPProviderConfig[] = [...]` in TS mirror",
302
- );
303
- }
304
- const bracketIdx = m.index + m[0].length - 1;
305
- const arrEnd = findMatchingDelimiter(source, bracketIdx, "[", "]");
306
- if (arrEnd === -1) throw new Error("Unclosed ACP_PROVIDERS array literal");
307
- const body = source.slice(bracketIdx + 1, arrEnd);
308
-
309
- // Walk the array body and split out each top-level `{...}` literal.
310
- const objects = [];
311
- let i = 0;
312
- while (i < body.length) {
313
- const c = body[i];
314
- if (c === "{") {
315
- const close = findMatchingDelimiter(body, i, "{", "}");
316
- if (close === -1)
317
- throw new Error("Unclosed object literal in ACP_PROVIDERS");
318
- objects.push(body.slice(i + 1, close));
319
- i = close + 1;
320
- } else {
321
- i++;
322
- }
323
- }
324
-
325
- return objects.map((inner) => {
326
- const keyMatch = inner.match(/\bkey\s*:\s*"([^"]+)"/);
327
- const dnMatch = inner.match(/\bdisplay_name\s*:\s*"([^"]+)"/);
328
- const dcKwMatch = inner.match(/\bdefault_command\s*:\s*\[/);
329
- if (!keyMatch || !dnMatch || !dcKwMatch) {
330
- throw new Error(
331
- "Failed to parse key / display_name / default_command in TS provider entry",
332
- );
333
- }
334
- const dcOpen = dcKwMatch.index + dcKwMatch[0].length - 1;
335
- const dcClose = findMatchingDelimiter(inner, dcOpen, "[", "]");
336
- if (dcClose === -1)
337
- throw new Error("Unclosed default_command array in TS provider entry");
338
- const default_command = extractStringList(inner.slice(dcOpen + 1, dcClose));
339
- return { key: keyMatch[1], display_name: dnMatch[1], default_command };
340
- });
341
- }
342
-
343
- export function diffRegistries(pyRecs, tsRecs) {
344
- const pyByKey = new Map();
345
- for (const r of pyRecs) pyByKey.set(r.key, r);
346
- const tsByKey = new Map();
347
- for (const r of tsRecs) tsByKey.set(r.key, r);
348
-
349
- const issues = [];
350
-
351
- // Order-of-keys drift is worth flagging: the SDK iterates ACP_PROVIDERS in
352
- // insertion order for agent-name detection, and the onboarding tile list
353
- // surfaces providers in TS order. A reorder shouldn't break correctness,
354
- // but does mean the two files no longer mean exactly the same thing.
355
- const pyOrder = pyRecs.map((r) => r.key).join(",");
356
- const tsOrder = tsRecs.map((r) => r.key).join(",");
357
- if (pyOrder !== tsOrder) {
358
- issues.push({
359
- kind: "order-mismatch",
360
- py: pyRecs.map((r) => r.key),
361
- ts: tsRecs.map((r) => r.key),
362
- });
363
- }
364
-
365
- for (const r of pyRecs) {
366
- if (r.mapKey !== r.key) {
367
- issues.push({
368
- kind: "python-internal-mismatch",
369
- key: r.key,
370
- mapKey: r.mapKey,
371
- });
372
- }
373
- }
374
-
375
- for (const key of pyByKey.keys()) {
376
- if (!tsByKey.has(key)) {
377
- issues.push({ kind: "missing-in-ts", key, py: pyByKey.get(key) });
378
- }
379
- }
380
- for (const key of tsByKey.keys()) {
381
- if (!pyByKey.has(key)) {
382
- issues.push({ kind: "missing-in-py", key, ts: tsByKey.get(key) });
383
- }
384
- }
385
- for (const [key, py] of pyByKey) {
386
- const ts = tsByKey.get(key);
387
- if (!ts) continue;
388
- if (py.display_name !== ts.display_name) {
389
- issues.push({
390
- kind: "field-mismatch",
391
- key,
392
- field: "display_name",
393
- py: py.display_name,
394
- ts: ts.display_name,
395
- });
396
- }
397
- const pyCmd = JSON.stringify(py.default_command);
398
- const tsCmd = JSON.stringify(ts.default_command);
399
- if (pyCmd !== tsCmd) {
400
- issues.push({
401
- kind: "field-mismatch",
402
- key,
403
- field: "default_command",
404
- py: py.default_command,
405
- ts: ts.default_command,
406
- });
407
- }
408
- }
409
-
410
- return issues;
411
- }
412
-
413
- async function fetchSdkSource({ sdkFile, sdkRef, sdkRepo }) {
414
- if (sdkFile) {
415
- return {
416
- source: readFileSync(resolve(sdkFile), "utf8"),
417
- origin: `file:${sdkFile}`,
418
- };
419
- }
420
- const url = `https://raw.githubusercontent.com/${sdkRepo}/${sdkRef}/${DEFAULT_SDK_PATH}`;
421
- const res = await fetch(url);
422
- if (!res.ok) {
423
- throw new Error(
424
- `Failed to fetch ${url}: HTTP ${res.status} ${res.statusText}. ` +
425
- `Verify --sdk-ref names a branch or tag in ${sdkRepo}.`,
426
- );
427
- }
428
- return { source: await res.text(), origin: url };
429
- }
430
-
431
- function log(...parts) {
432
- process.stderr.write(parts.join(" ") + "\n");
433
- }
434
-
435
- function formatIssue(i) {
436
- if (i.kind === "missing-in-ts") {
437
- return (
438
- ` ${colors.red}+ ${i.key}${colors.reset} present in SDK, missing in TS mirror\n` +
439
- ` ${colors.dim}display_name: ${JSON.stringify(i.py.display_name)}${colors.reset}\n` +
440
- ` ${colors.dim}default_command: ${JSON.stringify(i.py.default_command)}${colors.reset}`
441
- );
442
- }
443
- if (i.kind === "missing-in-py") {
444
- return (
445
- ` ${colors.red}- ${i.key}${colors.reset} present in TS mirror, missing in SDK\n` +
446
- ` ${colors.dim}default_command: ${JSON.stringify(i.ts.default_command)}${colors.reset}`
447
- );
448
- }
449
- if (i.kind === "field-mismatch") {
450
- const pyStr =
451
- typeof i.py === "string" ? JSON.stringify(i.py) : JSON.stringify(i.py);
452
- const tsStr =
453
- typeof i.ts === "string" ? JSON.stringify(i.ts) : JSON.stringify(i.ts);
454
- return (
455
- ` ${colors.red}~ ${i.key}.${i.field}${colors.reset}\n` +
456
- ` SDK: ${colors.green}${pyStr}${colors.reset}\n` +
457
- ` TS: ${colors.yellow}${tsStr}${colors.reset}`
458
- );
459
- }
460
- if (i.kind === "order-mismatch") {
461
- return (
462
- ` ${colors.red}# provider order differs${colors.reset}\n` +
463
- ` SDK: ${colors.green}${i.py.join(", ")}${colors.reset}\n` +
464
- ` TS: ${colors.yellow}${i.ts.join(", ")}${colors.reset}`
465
- );
466
- }
467
- if (i.kind === "python-internal-mismatch") {
468
- return (
469
- ` ${colors.red}~ Python mapping key vs ACPProviderInfo.key disagree${colors.reset}\n` +
470
- ` mapping key: ${colors.yellow}${i.mapKey}${colors.reset}\n` +
471
- ` ACPProviderInfo.key: ${colors.green}${i.key}${colors.reset}\n` +
472
- ` (fix this in the SDK, not in canvas.)`
473
- );
474
- }
475
- return ` unknown issue ${JSON.stringify(i)}`;
476
- }
477
-
478
- async function main() {
479
- const args = parseArgs(process.argv.slice(2));
480
- if (args.help) {
481
- showHelp();
482
- return;
483
- }
484
-
485
- log("");
486
- log(`${colors.cyan}ACP Providers Sync Check${colors.reset}`);
487
- log("─".repeat(50));
488
- log("");
489
-
490
- const tsSource = readFileSync(args.tsFile, "utf8");
491
- const { source: pySource, origin: pyOrigin } = await fetchSdkSource(args);
492
-
493
- log(`SDK source: ${colors.dim}${pyOrigin}${colors.reset}`);
494
- log(`TS mirror: ${colors.dim}${args.tsFile}${colors.reset}`);
495
- log("");
496
-
497
- const pyRecs = parsePython(pySource);
498
- const tsRecs = parseTypeScript(tsSource);
499
-
500
- log(`Python providers: ${pyRecs.length}`);
501
- log(`TS providers: ${tsRecs.length}`);
502
- log("");
503
-
504
- const issues = diffRegistries(pyRecs, tsRecs);
505
-
506
- if (args.json) {
507
- process.stdout.write(
508
- JSON.stringify(
509
- {
510
- in_sync: issues.length === 0,
511
- sdk_origin: pyOrigin,
512
- ts_path: args.tsFile,
513
- python_providers: pyRecs,
514
- ts_providers: tsRecs,
515
- issues,
516
- },
517
- null,
518
- 2,
519
- ) + "\n",
520
- );
521
- }
522
-
523
- if (issues.length === 0) {
524
- log(
525
- `${colors.green}✓ Canvas ACP_PROVIDERS is in sync with the SDK on the mirrored fields.${colors.reset}`,
526
- );
527
- log("");
528
- return;
529
- }
530
-
531
- log(
532
- `${colors.red}✗ Drift detected (${issues.length} issue${
533
- issues.length === 1 ? "" : "s"
534
- }):${colors.reset}`,
535
- );
536
- log("");
537
- for (const i of issues) log(formatIssue(i));
538
- log("");
539
- log(
540
- `Update ${colors.cyan}src/constants/acp-providers.ts${colors.reset} to match the SDK,`,
541
- );
542
- log(
543
- `or — if the SDK changed intentionally — bump ${colors.cyan}@openhands/typescript-client${colors.reset}`,
544
- );
545
- log(`and re-run this check before merging.`);
546
- log("");
547
- process.exit(1);
548
- }
549
-
550
- // Only run main() when invoked as the entry script — importing the module
551
- // (e.g. from tests) shouldn't hit the SDK or read the TS mirror.
552
- const invokedDirectly =
553
- process.argv[1] &&
554
- resolve(process.argv[1]) === fileURLToPath(import.meta.url);
555
- if (invokedDirectly) {
556
- main().catch((err) => {
557
- log(`${colors.red}Error: ${err.message}${colors.reset}`);
558
- process.exit(1);
559
- });
560
- }