claude-code-best 2.6.11 → 2.6.12

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 (484) hide show
  1. package/dist/chunks/{AddWorkspaceDirectory-CGKtPsTK.js → AddWorkspaceDirectory-LhW1QZFL.js} +1 -1
  2. package/dist/chunks/{App-DF28Bpg9.js → App-DYMNbl0d.js} +1 -1
  3. package/dist/chunks/ApproveApiKey-B1XCQNW6.js +1 -0
  4. package/dist/chunks/{ApproveApiKey-D21kbmQj.js → ApproveApiKey-Bi2Iq_gN.js} +1 -1
  5. package/dist/chunks/{AssistantSessionChooser-CDfwNVi5.js → AssistantSessionChooser-Dv6yYR3s.js} +1 -1
  6. package/dist/chunks/BackgroundTasksDialog-qS15If6H.js +2 -0
  7. package/dist/chunks/{BypassPermissionsModeDialog-BDWFw61G.js → BypassPermissionsModeDialog-Bhjd2F2o.js} +1 -1
  8. package/dist/chunks/{ClaudeInChromeOnboarding-CpN0yIU_.js → ClaudeInChromeOnboarding-CxBS5xZY.js} +1 -1
  9. package/dist/chunks/{ClaudeMdExternalIncludesDialog-CWRHpy22.js → ClaudeMdExternalIncludesDialog-CiANFiNV.js} +1 -1
  10. package/dist/chunks/ClaudeMdExternalIncludesDialog-nuKXhM2t.js +1 -0
  11. package/dist/chunks/ConsoleOAuthFlow-C8FzG3uF.js +1 -0
  12. package/dist/chunks/{DesktopHandoff-CKHLXiwc.js → DesktopHandoff-BSpzQF0U.js} +1 -1
  13. package/dist/chunks/{DevChannelsDialog-BwMFW7Wt.js → DevChannelsDialog-B2xqlZtS.js} +1 -1
  14. package/dist/chunks/{DiffDialog-oA1v0BMo.js → DiffDialog-XmOsaUeN.js} +2 -2
  15. package/dist/chunks/Doctor-C6FXh99k.js +1 -0
  16. package/dist/chunks/Doctor-DLx7Z_sA.js +3 -0
  17. package/dist/chunks/{ExitFlow-DJLYN-Bd.js → ExitFlow-CHDj7fv7.js} +2 -2
  18. package/dist/chunks/{Feedback-CpfhqIEv.js → Feedback-CUjTJbIh.js} +2 -2
  19. package/dist/chunks/Grove-B8ZQOflC.js +1 -0
  20. package/dist/chunks/{Grove-BugC6ssx.js → Grove-fenDMHVw.js} +1 -1
  21. package/dist/chunks/{HybridTransport-PeXWuYfl.js → HybridTransport-CP63usH9.js} +1 -1
  22. package/dist/chunks/{ITermBackend-dcs68DGS.js → ITermBackend-Bp_3qpix.js} +1 -1
  23. package/dist/chunks/{InvalidConfigDialog-DdB9_Ve0.js → InvalidConfigDialog-CgD7HSg0.js} +1 -1
  24. package/dist/chunks/{InvalidSettingsDialog-BL8nxwWQ.js → InvalidSettingsDialog-pYMa5Fp4.js} +1 -1
  25. package/dist/chunks/MCPConnectionManager-ip1xShU_.js +1 -0
  26. package/dist/chunks/{McpParsingWarnings-BYPXpmte.js → McpParsingWarnings-DhobExFM.js} +1 -1
  27. package/dist/chunks/MessageSelector-B2X6zrsb.js +3 -0
  28. package/dist/chunks/Messages-CmsZIA66.js +11 -0
  29. package/dist/chunks/{Onboarding-ByLnHSnW.js → Onboarding-BaoLhLiT.js} +1 -1
  30. package/dist/chunks/{OverageCreditUpsell-CVNfTSKG.js → OverageCreditUpsell-DnLMobAh.js} +1 -1
  31. package/dist/chunks/{PluginSettings-h9Lj0vW6.js → PluginSettings-BetzicTb.js} +3 -3
  32. package/dist/chunks/{PromptInputFooterSuggestions-CYWSLCgA.js → PromptInputFooterSuggestions-D-1hRFAD.js} +1 -1
  33. package/dist/chunks/{PromptInputHelpMenu-BsYNhZCw.js → PromptInputHelpMenu-DnQj3Hpq.js} +1 -1
  34. package/dist/chunks/QueryEngine-BwvqdZVN.js +1 -0
  35. package/dist/chunks/REPL-CCgaPc2g.js +1 -0
  36. package/dist/chunks/{REPL-CV12-ns7.js → REPL-zS2s1JnV.js} +34 -34
  37. package/dist/chunks/{RemoteCallout-WWO84za-.js → RemoteCallout-B9hClSYj.js} +1 -1
  38. package/dist/chunks/{RemoteSessionManager-Dx2skKnM.js → RemoteSessionManager-BgLIvi8Z.js} +2 -2
  39. package/dist/chunks/ResumeConversation-DAMMGHGc.js +1 -0
  40. package/dist/chunks/{SSETransport-BHdzk1HO.js → SSETransport-CD7R7FfS.js} +1 -1
  41. package/dist/chunks/SearchExtraToolsTool-CP6G9xhL.js +1 -0
  42. package/dist/chunks/{SentryErrorBoundary-CmewX8Dv.js → SentryErrorBoundary-6dQQW6kh.js} +1 -1
  43. package/dist/chunks/SentryErrorBoundary-B2e3QmqR.js +1 -0
  44. package/dist/chunks/Settings-DgW58gbY.js +2 -0
  45. package/dist/chunks/{TeleportProgress-BmbhZlOg.js → TeleportProgress-D_USKi0I.js} +1 -1
  46. package/dist/chunks/TeleportRepoMismatchDialog-C1-iWmRP.js +1 -0
  47. package/dist/chunks/{TeleportResumeWrapper-BlkvOdYn.js → TeleportResumeWrapper-BX9nUVsC.js} +1 -1
  48. package/dist/chunks/{ThemePicker-v_3lh136.js → ThemePicker-C0JghXSS.js} +1 -1
  49. package/dist/chunks/{TmuxBackend-B7Nabc5t.js → TmuxBackend-BxPiis2l.js} +1 -1
  50. package/dist/chunks/{TrustDialog-CHu5eoeR.js → TrustDialog-BZD-KGrA.js} +1 -1
  51. package/dist/chunks/{ValidationErrorsList-BSMetgqr.js → ValidationErrorsList-CTFdkGiH.js} +1 -1
  52. package/dist/chunks/{WelcomeV2-DZfBSTu5.js → WelcomeV2-C7F1y8zh.js} +1 -1
  53. package/dist/chunks/{WindowsTerminalBackend-CeSoQ_Nk.js → WindowsTerminalBackend-DLxmmXo4.js} +2 -2
  54. package/dist/chunks/{add-dir-7UeFZkdv.js → add-dir-Dhv9aEca.js} +1 -1
  55. package/dist/chunks/{agentDisplay-DJgsfIlm.js → agentDisplay-BoBFMmGh.js} +1 -1
  56. package/dist/chunks/{agents-DD7gQVZD.js → agents-Bt9kYpgi.js} +1 -1
  57. package/dist/chunks/{agents-DK0y9jId.js → agents-CdsfzK3E.js} +7 -7
  58. package/dist/chunks/{ant-PhgMZT08.js → ant-Bo6XJuE9.js} +1 -1
  59. package/dist/chunks/api-CRPzfBL5.js +1 -0
  60. package/dist/chunks/{api-nHsRf03G.js → api-CslgFoHj.js} +1 -1
  61. package/dist/chunks/{assistant-DO7RAhd3.js → assistant--L1Ll62G.js} +1 -1
  62. package/dist/chunks/assistant-DypEudjI.js +1 -0
  63. package/dist/chunks/{assistant-BJbeizyH.js → assistant-od6Nf6EJ.js} +1 -1
  64. package/dist/chunks/auth-BaaTtn3M.js +1 -0
  65. package/dist/chunks/{auth-DxRiJwZ-.js → auth-yKNn60lZ.js} +1 -1
  66. package/dist/chunks/{autoMode-BswSpjo5.js → autoMode-C4b9u7WQ.js} +6 -6
  67. package/dist/chunks/{autonomy-Lc78acHX.js → autonomy-7nZpCyNC.js} +12 -12
  68. package/dist/chunks/{autonomy-CNJQwoAQ.js → autonomy-rMsykUYN.js} +1 -1
  69. package/dist/chunks/{autonomyPanel-DxcumRp-.js → autonomyPanel-j0q1dMDj.js} +1 -1
  70. package/dist/chunks/backgroundHousekeeping-DGAYPsK9.js +1 -0
  71. package/dist/chunks/backgroundHousekeeping-KCpR7i2h.js +17 -0
  72. package/dist/chunks/{branch-BPsUW1dk.js → branch-GL4WvvLa.js} +2 -2
  73. package/dist/chunks/{bridge-DcOGvDbb.js → bridge-BVzpVEsr.js} +2 -2
  74. package/dist/chunks/bridgeConfig-B1OTOi0O.js +1 -0
  75. package/dist/chunks/{bridgeConfig-CvKdNJOg.js → bridgeConfig-C110hgnb.js} +1 -1
  76. package/dist/chunks/{bridgeEnabled-D01faWms.js → bridgeEnabled-DrW-kkAr.js} +1 -1
  77. package/dist/chunks/bridgeEnabled-Zk2slA-p.js +1 -0
  78. package/dist/chunks/bridgeMain-C-MUVlCX.js +68 -0
  79. package/dist/chunks/bridgeMain-L1ScqrgM.js +1 -0
  80. package/dist/chunks/{bridgeMessaging-BZMDSZAN.js → bridgeMessaging-DobCpZGY.js} +1 -1
  81. package/dist/chunks/{btw-B8s-X_cm.js → btw-CSDRs-n8.js} +1 -1
  82. package/dist/chunks/{buddy-DkB1xU1o.js → buddy-D3Owb2U5.js} +1 -1
  83. package/dist/chunks/{bypassPermissionsKillswitch-B9Qz9zKO.js → bypassPermissionsKillswitch-B_5qku-e.js} +1 -1
  84. package/dist/chunks/caches-CpgRh__l.js +1 -0
  85. package/dist/chunks/{caches-BuSzLvN9.js → caches-Di_WVMtD.js} +2 -2
  86. package/dist/chunks/{ccrClient-CMZXfu9P.js → ccrClient-CWH1f8Nk.js} +1 -1
  87. package/dist/chunks/changeDetector-DEStinxa.js +1 -0
  88. package/dist/chunks/channelNotification-DxAS15nL.js +1 -0
  89. package/dist/chunks/{channelNotification-t6Kgu-vX.js → channelNotification-Y5fNpq-B.js} +1 -1
  90. package/dist/chunks/{chrome-Cvkozg2F.js → chrome-Cgl-Sq1y.js} +1 -1
  91. package/dist/chunks/clear-Dja0RB_p.js +1 -0
  92. package/dist/chunks/client-DuWXRBa0.js +1 -0
  93. package/dist/chunks/color-tvVGbuuv.js +1 -0
  94. package/dist/chunks/commands-ElmJnxRE.js +1 -0
  95. package/dist/chunks/{commitAttribution-CUqUEjsh.js → commitAttribution-CedoNRL0.js} +1 -1
  96. package/dist/chunks/commitAttribution-D6vYpAMS.js +1 -0
  97. package/dist/chunks/compact-BwsLImWZ.js +3 -0
  98. package/dist/chunks/{companion-Cf_kYtOD.js → companion-C3hWMSgF.js} +1 -1
  99. package/dist/chunks/{config-45GLd-lt.js → config-BHCIawwx.js} +1 -1
  100. package/dist/chunks/{config-JGm0O-ZQ.js → config-Dh0QGc4B.js} +1 -1
  101. package/dist/chunks/{context-Bl5VUX5M.js → context-CSHiU4LG.js} +1 -1
  102. package/dist/chunks/{context-noninteractive-DdPFYYO9.js → context-noninteractive-CKFY_j1P.js} +2 -2
  103. package/dist/chunks/context-noninteractive-DirFwn0d.js +1 -0
  104. package/dist/chunks/conversation-DfIv8Jzc.js +1 -0
  105. package/dist/chunks/conversation-Dyb5kfil.js +1 -0
  106. package/dist/chunks/{copy-CbhxPqw4.js → copy-BSyDpOx5.js} +2 -2
  107. package/dist/chunks/{createSSHSession-Dq2nMChz.js → createSSHSession-PfzB7zZR.js} +1 -1
  108. package/dist/chunks/{createSession-DTHPUie-.js → createSession-Bk6r39b1.js} +1 -1
  109. package/dist/chunks/createSession-DdsaDZoq.js +1 -0
  110. package/dist/chunks/{cronJitterConfig-IGWCRDrv.js → cronJitterConfig-BFVNIkjD.js} +3 -3
  111. package/dist/chunks/crossProjectResume-CdoH1cwH.js +40 -0
  112. package/dist/chunks/{daemon-VYRit6Aq.js → daemon-CCtZ9wY3.js} +1 -1
  113. package/dist/chunks/{datadog-FKvRNyFi.js → datadog-By0GhDXI.js} +1 -1
  114. package/dist/chunks/datadog-CTRRIaBJ.js +1 -0
  115. package/dist/chunks/{desktop-ZASE3YWy.js → desktop-BV6CI329.js} +1 -1
  116. package/dist/chunks/{diff-QP-TbxuD.js → diff-qDuBFv-P.js} +1 -1
  117. package/dist/chunks/{doctor-DVkgmkRb.js → doctor-BtTsew-G.js} +1 -1
  118. package/dist/chunks/earlyInput-RoVleNEN.js +1 -0
  119. package/dist/chunks/{effort-DbryQCua.js → effort-DSpAOBeU.js} +2 -2
  120. package/dist/chunks/{entry-D8y42iuM.js → entry-CYCQJU7M.js} +8 -8
  121. package/dist/chunks/envLessBridgeConfig-B3o52JMX.js +1 -0
  122. package/dist/chunks/{envLessBridgeConfig-D4bSwf7w.js → envLessBridgeConfig-BKs6Mk4e.js} +1 -1
  123. package/dist/chunks/exit-BgaIlRuS.js +1 -0
  124. package/dist/chunks/{export-C9A9nOA1.js → export-BOQCWSMm.js} +1 -1
  125. package/dist/chunks/{exportRenderer-CyTuZFFF.js → exportRenderer-B-2J3ocI.js} +1 -1
  126. package/dist/chunks/extra-usage-BLVbAE1O.js +1 -0
  127. package/dist/chunks/{extra-usage-C6s5mXW0.js → extra-usage-S4WYpDn5.js} +1 -1
  128. package/dist/chunks/{extra-usage-core-BFCwz3XM.js → extra-usage-core-Sq4JALS7.js} +1 -1
  129. package/dist/chunks/{extra-usage-noninteractive-IHq7s6wm.js → extra-usage-noninteractive-BlJVTTwe.js} +1 -1
  130. package/dist/chunks/{extraUsage-CIrG_Lbw.js → extraUsage-CMJ1LEPS.js} +1 -1
  131. package/dist/chunks/extractMemories-BpN0fQF-.js +1 -0
  132. package/dist/chunks/fast-B8a-zz4X.js +1 -0
  133. package/dist/chunks/{fast-NEKXVZqQ.js → fast-OzVowRYW.js} +1 -1
  134. package/dist/chunks/{feedback-D5iWO16P.js → feedback-BZet1Qu_.js} +1 -1
  135. package/dist/chunks/{firstPartyEventLogger-Dr3TK3IU.js → firstPartyEventLogger-DeytNcUC.js} +1 -1
  136. package/dist/chunks/{flushGate-DygHyqmB.js → flushGate-CeFJrqgK.js} +1 -1
  137. package/dist/chunks/{gates-Dyz_t5zJ.js → gates-Be4ovdxj.js} +1 -1
  138. package/dist/chunks/gates-WmmZ-8JT.js +1 -0
  139. package/dist/chunks/gemini-DExthrur.js +1 -0
  140. package/dist/chunks/{generateRecap-DZiXeYWn.js → generateRecap-BIFrnTIe.js} +1 -1
  141. package/dist/chunks/{generateSessionName-EbB2vl9t.js → generateSessionName-DlC0lhSv.js} +1 -1
  142. package/dist/chunks/{githubRepoPathMapping-dky2fPeU.js → githubRepoPathMapping-BKB2G52c.js} +1 -1
  143. package/dist/chunks/grok-BNxCseLh.js +1 -0
  144. package/dist/chunks/{growthbook-JD-WW3yV.js → growthbook-B3_MJJ45.js} +1 -1
  145. package/dist/chunks/{heapdump-8vyFTWly.js → heapdump-sPWpCjXq.js} +1 -1
  146. package/dist/chunks/{help-C2DM0p8U.js → help-BuUi6cM0.js} +1 -1
  147. package/dist/chunks/{hooks-CMh0a2pT.js → hooks-5vDlGpNp.js} +2 -2
  148. package/dist/chunks/hooks-CVJA4uQu.js +1 -0
  149. package/dist/chunks/{hostAdapter-CmbGfgNV.js → hostAdapter-BfBHV5nj.js} +1 -1
  150. package/dist/chunks/{ide-Bn8R7397.js → ide-DvUftvRn.js} +2 -2
  151. package/dist/chunks/inboundAttachments-CQyeysIk.js +1 -0
  152. package/dist/chunks/{inboundAttachments-BweY9sYo.js → inboundAttachments-CiF42Eku.js} +1 -1
  153. package/dist/chunks/initReplBridge-Bzg5Gx97.js +1 -0
  154. package/dist/chunks/{insights-NOl_PxhN.js → insights-CvwFcRQt.js} +64 -64
  155. package/dist/chunks/{install-github-app-SD4PvrTR.js → install-github-app-DxxG2VlZ.js} +2 -2
  156. package/dist/chunks/{install-slack-app-DLQXpOCt.js → install-slack-app-Bc5m1UFG.js} +1 -1
  157. package/dist/chunks/{install-BoT2GIcz.js → install-tclc0QHM.js} +1 -1
  158. package/dist/chunks/{instrumentation-BXJk0mxI.js → instrumentation-Dn_FDn6G.js} +3 -3
  159. package/dist/chunks/{job-CnlMlm3t.js → job-ssZ2ESAX.js} +1 -1
  160. package/dist/chunks/{keybindings-BjaRqcbD.js → keybindings-DVZlobLM.js} +2 -2
  161. package/dist/chunks/{lang-BI8CzjL6.js → lang-BQ--zwb1.js} +1 -1
  162. package/dist/chunks/language-BM5numKK.js +1 -0
  163. package/dist/chunks/{language-CRIdgj2F.js → language-CcxtaVJA.js} +1 -1
  164. package/dist/chunks/{launchAgentsPlatform-Bg9guiqy.js → launchAgentsPlatform-CLwlpK5C.js} +1 -1
  165. package/dist/chunks/{launchAutofixPr-BMfXGXwN.js → launchAutofixPr-vGLlC4Jm.js} +3 -3
  166. package/dist/chunks/{launchLocalMemory-lgnXOi6U.js → launchLocalMemory-DJ4pR8a2.js} +2 -2
  167. package/dist/chunks/{launchLocalVault-C0Oz-lto.js → launchLocalVault-Cl7Dds3W.js} +3 -3
  168. package/dist/chunks/{launchMemoryStores-Bw11ruRi.js → launchMemoryStores-Czk-a1P6.js} +1 -1
  169. package/dist/chunks/{launchOnboarding-WEW34cnl.js → launchOnboarding-66gN_781.js} +1 -1
  170. package/dist/chunks/{launchSchedule-X0rcM_kM.js → launchSchedule-Tx5efcfv.js} +1 -1
  171. package/dist/chunks/{launchSkillStore-DpxSlMCU.js → launchSkillStore-BGPd1KCD.js} +1 -1
  172. package/dist/chunks/{launchTeleport-uOtMsYcI.js → launchTeleport-DzXrNn2h.js} +2 -2
  173. package/dist/chunks/{launchVault-CJyJaPqH.js → launchVault-C5djf6XO.js} +1 -1
  174. package/dist/chunks/{loadAgentsDir-D-xcJ22-.js → loadAgentsDir-DaApSWNv.js} +807 -764
  175. package/dist/chunks/loadAgentsDir-_BePoo3r.js +1 -0
  176. package/dist/chunks/loadPluginHooks-GENkKqO8.js +1 -0
  177. package/dist/chunks/{localSearch-B6Ho7Vfj.js → localSearch-BQuH38SB.js} +1 -1
  178. package/dist/chunks/localSearch-BSR9byCr.js +1 -0
  179. package/dist/chunks/{login-uOvq1xN_.js → login-C64M5OdJ.js} +1 -1
  180. package/dist/chunks/login-dkrrvdEl.js +1 -0
  181. package/dist/chunks/{logoV2Utils-C2cdcgtp.js → logoV2Utils-D6ceZmK0.js} +1 -1
  182. package/dist/chunks/logout-BITK5qkB.js +1 -0
  183. package/dist/chunks/{magicDocs-BBjAhGN1.js → magicDocs-KPodA4bi.js} +2 -2
  184. package/dist/chunks/{main-DGsAUuG_.js → main-wb2H0Xbt.js} +48 -48
  185. package/dist/chunks/{mappers-CO6koWDa.js → mappers-D54WYYhL.js} +1 -1
  186. package/dist/chunks/mcp-Bgeq8jbd.js +6 -0
  187. package/dist/chunks/mcp-CJvRg7ft.js +2 -0
  188. package/dist/chunks/mcp-Ddvz5we7.js +1 -0
  189. package/dist/chunks/{mcpServer-C-0K3Azg.js → mcpServer-VYXTzAFl.js} +1 -1
  190. package/dist/chunks/{mcpServer-C_aDoLMg.js → mcpServer-d0863d94.js} +1 -1
  191. package/dist/chunks/memory-BNyVCuw9.js +1 -0
  192. package/dist/chunks/mode-D_L3DNsz.js +2 -0
  193. package/dist/chunks/model-DevOJk2A.js +1 -0
  194. package/dist/chunks/{model-CrAPXYZA.js → model-Dy_oUo2C.js} +1 -1
  195. package/dist/chunks/{onChangeAppState-C6ZIU1SD.js → onChangeAppState-GPs10FBm.js} +1 -1
  196. package/dist/chunks/{openai-Cm4gozk8.js → openai-C0CrRENO.js} +3 -3
  197. package/dist/chunks/{overageCreditGrant-Pe7C_4Qi.js → overageCreditGrant-DCiIf_SF.js} +1 -1
  198. package/dist/chunks/{panel-Bz_8td5D.js → panel-s9fbCKfl.js} +1 -1
  199. package/dist/chunks/{passes-BpI6azLG.js → passes-C9oR06Fa.js} +1 -1
  200. package/dist/chunks/{paths-D9CVAtXU.js → paths-BZbIj1Z1.js} +3 -3
  201. package/dist/chunks/permissions-DNb8DG22.js +3 -0
  202. package/dist/chunks/{pipeTransport-wjeyTgon.js → pipeTransport-Cx55TUNu.js} +1 -1
  203. package/dist/chunks/{plan-DA8IRpHQ.js → plan-D-RJTUxb.js} +1 -1
  204. package/dist/chunks/{plugin-N2pTkzOz.js → plugin-BV-DabiK.js} +1 -1
  205. package/dist/chunks/{pluginAutoupdate-DCc5qDvo.js → pluginAutoupdate-DPciQRLz.js} +1 -1
  206. package/dist/chunks/pluginBlocklist-CtSUf3sp.js +1 -0
  207. package/dist/chunks/{pluginCliCommands-BN7loc5T.js → pluginCliCommands-Cbcc-AQq.js} +1 -1
  208. package/dist/chunks/{pluginFlagging-Dpu1cvMo.js → pluginFlagging-D2d7jd4v.js} +1 -1
  209. package/dist/chunks/pluginOperations-rU56uptC.js +2 -0
  210. package/dist/chunks/{pluginStartupCheck-DvWHwNnD.js → pluginStartupCheck-DuhCLRbp.js} +1 -1
  211. package/dist/chunks/pluginStartupCheck-DwY7j_Cg.js +1 -0
  212. package/dist/chunks/plugins-LbLpZOhz.js +4 -0
  213. package/dist/chunks/policyLimits-Dl863Z85.js +1 -0
  214. package/dist/chunks/{pollConfig-xYxAmuXi.js → pollConfig-orFqIbGd.js} +1 -1
  215. package/dist/chunks/{poor-C0KwfFF0.js → poor-2u_yWIRG.js} +1 -1
  216. package/dist/chunks/poorMode-BBr7GGQ3.js +1 -0
  217. package/dist/chunks/{poorMode-D7WXWZtJ.js → poorMode-DtQVZvON.js} +1 -1
  218. package/dist/chunks/print-BgLbepaC.js +39 -0
  219. package/dist/chunks/{privacy-settings-DT3LGgsH.js → privacy-settings-CC_FyvjV.js} +1 -1
  220. package/dist/chunks/processBashCommand-DnekNzlT.js +1 -0
  221. package/dist/chunks/processSlashCommand-sLL0pyIW.js +6 -0
  222. package/dist/chunks/{projectContext-0fpRKUeH.js → projectContext-D5FgyE-d.js} +1 -1
  223. package/dist/chunks/{prompt-C69iv9cI.js → prompt-DHHypkUR.js} +1 -1
  224. package/dist/chunks/prompt-Dexwn9YP.js +1 -0
  225. package/dist/chunks/prompt-DhaPVt1T.js +1 -0
  226. package/dist/chunks/{promptEditor-BZqpLrcZ.js → promptEditor-I8ZpszKv.js} +2 -2
  227. package/dist/chunks/{protocolHandler-CfmBTg36.js → protocolHandler-CEsrhel_.js} +1 -1
  228. package/dist/chunks/rate-limit-options-B0Iyzr4x.js +1 -0
  229. package/dist/chunks/{rcDebugLog-CTOZ2K3E.js → rcDebugLog-CF73Wofq.js} +1 -1
  230. package/dist/chunks/{referral-D26orIXE.js → referral-Nz20w4pB.js} +1 -1
  231. package/dist/chunks/refresh-DecpoOX1.js +1 -0
  232. package/dist/chunks/{registerProtocol-DSQh-I21.js → registerProtocol-CAoaYyt8.js} +1 -1
  233. package/dist/chunks/registry-BQdQRu-K.js +1 -0
  234. package/dist/chunks/{release-notes-Cg85UVo8.js → release-notes-C0HeOmQY.js} +1 -1
  235. package/dist/chunks/{releaseNotes-Dps4SeVh.js → releaseNotes-BDzfbUAu.js} +2 -2
  236. package/dist/chunks/{reload-plugins-Bo-R1CF3.js → reload-plugins-BZ4LTYY3.js} +1 -1
  237. package/dist/chunks/{remote-env-ChQuV3rO.js → remote-env-CPalv-BL.js} +1 -1
  238. package/dist/chunks/{remoteBridgeCore-BXtygJA-.js → remoteBridgeCore-B2yFfG6S.js} +1 -1
  239. package/dist/chunks/{remoteControlServer-sqW_JLwC.js → remoteControlServer-CsnLedUv.js} +2 -2
  240. package/dist/chunks/rename-CQPtjj_Q.js +1 -0
  241. package/dist/chunks/{resume-CtOI2pOJ.js → resume-Ycuezjv2.js} +2 -2
  242. package/dist/chunks/{runtimeObserver-DojpbVgU.js → runtimeObserver-CW0_wm1t.js} +1 -1
  243. package/dist/chunks/{runtimeObserver-CJ955XSo.js → runtimeObserver-DnhLm9O1.js} +3 -3
  244. package/dist/chunks/sandbox-adapter-BOsa-en7.js +1 -0
  245. package/dist/chunks/{sandbox-toggle-B9dn09gt.js → sandbox-toggle-Bl5Drxeo.js} +1 -1
  246. package/dist/chunks/searchExtraTools-CgdrY8XO.js +1 -0
  247. package/dist/chunks/{sentry-B6tWUNGj.js → sentry-BN3GTgYM.js} +1 -1
  248. package/dist/chunks/{session-C5yIf_zV.js → session-ULekTZVn.js} +2 -2
  249. package/dist/chunks/{sessionDiscovery-CQ3iMN4s.js → sessionDiscovery-DAmbR6o-.js} +1 -1
  250. package/dist/chunks/sessionFileAccessHooks-C-o5001P.js +1 -0
  251. package/dist/chunks/sessionMemory-Bg458voj.js +1 -0
  252. package/dist/chunks/sessionMemory-DR-esdhZ.js +1 -0
  253. package/dist/chunks/sessionMemoryUtils-DgVGiwjB.js +1 -0
  254. package/dist/chunks/sessionObserver-C5cujEe6.js +1 -0
  255. package/dist/chunks/{sessionObserver-MQA9_wZw.js → sessionObserver-CQ3PQWgU.js} +1 -1
  256. package/dist/chunks/sessionStorage-BIDUQ8wo.js +1 -0
  257. package/dist/chunks/{sessionTitle-BafqFHLc.js → sessionTitle-DyexSH43.js} +1 -1
  258. package/dist/chunks/{sessionTracing-_obALZbi.js → sessionTracing-gKle2qzF.js} +1 -1
  259. package/dist/chunks/{settingsSync-DBWi-NXU.js → settingsSync-BWW4FOMm.js} +1 -1
  260. package/dist/chunks/{setup-DIxsjw17.js → setup-DX6984LY.js} +1 -1
  261. package/dist/chunks/setup-OvlOCIFL.js +2 -0
  262. package/dist/chunks/{setup-C_GrS0Rd.js → setup-n91rSYO2.js} +1 -1
  263. package/dist/chunks/{shadowedRuleDetection-CwMwv9uM.js → shadowedRuleDetection-uYIZBoii.js} +1 -1
  264. package/dist/chunks/{sideQuestion-CI5pyoQF.js → sideQuestion-DIMsNoEc.js} +2 -2
  265. package/dist/chunks/sink-BBn0HwoH.js +1 -0
  266. package/dist/chunks/{sink-BSTUubjl.js → sink-DLRpC2qX.js} +1 -1
  267. package/dist/chunks/{sinks-B9EsWFeb.js → sinks-BI1hGD9c.js} +2 -2
  268. package/dist/chunks/sinks-DKGE2sSC.js +1 -0
  269. package/dist/chunks/{skill-learning-DThetLpo.js → skill-learning-Dz-Zq-xT.js} +1 -1
  270. package/dist/chunks/skillChangeDetector-C2Te20cK.js +1 -0
  271. package/dist/chunks/{skillGapStore-BmjCK9ZR.js → skillGapStore-BFpryJIe.js} +2 -2
  272. package/dist/chunks/{skillGapStore-ax0GuSmd.js → skillGapStore-CxPjoWci.js} +1 -1
  273. package/dist/chunks/{skillGenerator-Dj3xInwG.js → skillGenerator-BGOIb5p-.js} +2 -2
  274. package/dist/chunks/skillLearning-BRvWwB8E.js +1 -0
  275. package/dist/chunks/skillLearning-DTo7lCKd.js +1 -0
  276. package/dist/chunks/{skillPanel-CJ4tvX7A.js → skillPanel-DzYZLnuH.js} +3 -3
  277. package/dist/chunks/{skillSearchPanel-hwZvXKZ4.js → skillSearchPanel-DrysL5R-.js} +3 -3
  278. package/dist/chunks/{skills-BVWDDcD9.js → skills-CTfNqisc.js} +1 -1
  279. package/dist/chunks/{sprites-B-V9otkt.js → sprites-CHzZCAGE.js} +1 -1
  280. package/dist/chunks/{stats-DcS6ZnsX.js → stats-D2s-hIY8.js} +1 -1
  281. package/dist/chunks/{status-DZKjK9CE.js → status-XxrX2kHw.js} +1 -1
  282. package/dist/chunks/statusNoticeHelpers-CUm1pflC.js +1 -0
  283. package/dist/chunks/{tag-B5b-waIf.js → tag-FV031rKW.js} +2 -2
  284. package/dist/chunks/{tasks-vXM-vULI.js → tasks-aK2rp8CW.js} +1 -1
  285. package/dist/chunks/{teamHelpers-CbFFdvPw.js → teamHelpers-2m66Mr8w.js} +1 -1
  286. package/dist/chunks/teamHelpers-Bg3nHlWr.js +1 -0
  287. package/dist/chunks/{teammateModeSnapshot-DkkMv2-b.js → teammateModeSnapshot-BtdUJBKp.js} +1 -1
  288. package/dist/chunks/teammateModeSnapshot-VojvAMbR.js +1 -0
  289. package/dist/chunks/teleport-4x9eIl8c.js +1 -0
  290. package/dist/chunks/{templateJobs-BLQqrGjb.js → templateJobs-fEz4DGWh.js} +1 -1
  291. package/dist/chunks/{terminalSetup-BLU99dau.js → terminalSetup-Cjdlcznm.js} +1 -1
  292. package/dist/chunks/{terminalSetup-BKfVYk3w.js → terminalSetup-EirH-l0a.js} +1 -1
  293. package/dist/chunks/{theme-BM2CXWYE.js → theme-BjdEyakL.js} +1 -1
  294. package/dist/chunks/thinkback-CrW3VlCR.js +1 -0
  295. package/dist/chunks/thinkback-DHyz-lmU.js +1 -0
  296. package/dist/chunks/thinkback-play-B46ystVF.js +1 -0
  297. package/dist/chunks/{toolEventObserver-nxcfjaur.js → toolEventObserver-CJ68x4wM.js} +1 -1
  298. package/dist/chunks/{toolEventObserver-71WYUega.js → toolEventObserver-Dak6ETA6.js} +1 -1
  299. package/dist/chunks/toolPool-3CMCh3QU.js +1 -0
  300. package/dist/chunks/toolPool-BHdCDihh.js +1 -0
  301. package/dist/chunks/{trustedDevice-C0KJ0qiK.js → trustedDevice-QhApqKq4.js} +1 -1
  302. package/dist/chunks/{trustedDevice-Brc9B8cZ.js → trustedDevice-oDn6E85N.js} +1 -1
  303. package/dist/chunks/{tui-BVc2q4Xv.js → tui-geoc3zxu.js} +1 -1
  304. package/dist/chunks/{ultrareviewCommand-BY0T8Pzl.js → ultrareviewCommand-Ar9zzqz4.js} +2 -2
  305. package/dist/chunks/undercover-D1ieJ54D.js +1 -0
  306. package/dist/chunks/{undercover-j27F8p49.js → undercover-DZq2Tf-o.js} +1 -1
  307. package/dist/chunks/{updateCCB-Dgb2ed9v.js → updateCCB-Db3CfFcn.js} +1 -1
  308. package/dist/chunks/upgrade-B28O0zeQ.js +1 -0
  309. package/dist/chunks/{upgrade-zs7K9UkG.js → upgrade-BZvNOhEJ.js} +1 -1
  310. package/dist/chunks/{upload-Df84yCBz.js → upload-DAmbsBq4.js} +1 -1
  311. package/dist/chunks/{usage-DKENFl_k.js → usage-COv9UCxX.js} +1 -1
  312. package/dist/chunks/{usage-lTILrQJV.js → usage-Dtv3YQf8.js} +1 -1
  313. package/dist/chunks/useMainLoopModel-BpM3dlzJ.js +1 -0
  314. package/dist/chunks/{useManagePlugins-DDKeDfIv.js → useManagePlugins-DZ-_Ll9E.js} +1 -1
  315. package/dist/chunks/useMergedTools-INKnp2ij.js +1 -0
  316. package/dist/chunks/{useSearchInput-DNpNG36H.js → useSearchInput-DobM3JKI.js} +1 -1
  317. package/dist/chunks/useSettingsErrors-DjvaCC5-.js +1 -0
  318. package/dist/chunks/{useVoice-DmObXoAh.js → useVoice-exDfbv1t.js} +1 -1
  319. package/dist/chunks/{util-9vJ9WIeZ.js → util-CDzNDmax.js} +1 -1
  320. package/dist/chunks/utils-B0iiiW_p.js +1 -0
  321. package/dist/chunks/validatePlugin-DaLnfLSC.js +1 -0
  322. package/dist/chunks/{vim-CK7lReJi.js → vim-CPKu15l_.js} +1 -1
  323. package/dist/chunks/{voice-BLVF7E3Q.js → voice-gNxUce-I.js} +2 -2
  324. package/dist/chunks/voiceModeEnabled-CwPbMJ9C.js +1 -0
  325. package/dist/chunks/{voiceModeEnabled-BpLBjY2-.js → voiceModeEnabled-DEwGjUP6.js} +1 -1
  326. package/dist/chunks/voiceStreamSTT-6b3Oslnl.js +1 -0
  327. package/dist/chunks/{voiceStreamSTT-i4tUq3Hu.js → voiceStreamSTT-BjX-mTB_.js} +1 -1
  328. package/dist/chunks/{workerRegistry-Bg7dWLHf.js → workerRegistry-Bc6t6VlK.js} +1 -1
  329. package/dist/chunks/worktree-NnuvJmoP.js +1 -0
  330. package/dist/chunks/{xml-K_hNNh2b.js → xml-Dg8-vY8G.js} +1 -1
  331. package/dist/cli.js +1 -1
  332. package/package.json +1 -1
  333. package/dist/chunks/ApproveApiKey-BtiWOryM.js +0 -1
  334. package/dist/chunks/BackgroundTasksDialog-5RpkAbJz.js +0 -2
  335. package/dist/chunks/ClaudeMdExternalIncludesDialog-Dje7A0F2.js +0 -1
  336. package/dist/chunks/ConsoleOAuthFlow-DQf3dmj6.js +0 -1
  337. package/dist/chunks/Doctor-ButdpAkf.js +0 -1
  338. package/dist/chunks/Doctor-QVMo0fIh.js +0 -3
  339. package/dist/chunks/Grove-CmdRVv9F.js +0 -1
  340. package/dist/chunks/MCPConnectionManager-D2eAGUME.js +0 -1
  341. package/dist/chunks/MessageSelector-Bzq8CYAH.js +0 -3
  342. package/dist/chunks/Messages-uRxxAMW-.js +0 -11
  343. package/dist/chunks/QueryEngine-CxP2S3qi.js +0 -1
  344. package/dist/chunks/REPL-h1bwm8ee.js +0 -1
  345. package/dist/chunks/ResumeConversation-CagiCg7-.js +0 -1
  346. package/dist/chunks/SearchExtraToolsTool-BJ2d8mtx.js +0 -1
  347. package/dist/chunks/SentryErrorBoundary-CYiFofRZ.js +0 -1
  348. package/dist/chunks/Settings-BcgtW60l.js +0 -2
  349. package/dist/chunks/TeleportRepoMismatchDialog-BAwtgUhR.js +0 -1
  350. package/dist/chunks/api-D4aCzJS-.js +0 -1
  351. package/dist/chunks/assistant-Dvx-UrTi.js +0 -1
  352. package/dist/chunks/auth-Cp7Nt0ik.js +0 -1
  353. package/dist/chunks/backgroundHousekeeping-BkfWgzIP.js +0 -17
  354. package/dist/chunks/backgroundHousekeeping-BxBI2KkX.js +0 -1
  355. package/dist/chunks/bridgeConfig-Dkn5GGec.js +0 -1
  356. package/dist/chunks/bridgeEnabled-CjaYKTo5.js +0 -1
  357. package/dist/chunks/bridgeMain-Bu2oOX31.js +0 -68
  358. package/dist/chunks/bridgeMain-CEpOBx8Z.js +0 -1
  359. package/dist/chunks/caches-Bvl2jdxF.js +0 -1
  360. package/dist/chunks/changeDetector-DTXMv7gH.js +0 -1
  361. package/dist/chunks/channelNotification-B7s1OoRK.js +0 -1
  362. package/dist/chunks/clear-C9pufI6F.js +0 -1
  363. package/dist/chunks/client-CqJ5gRGj.js +0 -1
  364. package/dist/chunks/color-AYeAYKyq.js +0 -1
  365. package/dist/chunks/commands-LcLR5Vgx.js +0 -1
  366. package/dist/chunks/commitAttribution-BZupnGMc.js +0 -1
  367. package/dist/chunks/compact-BF0-0_qh.js +0 -3
  368. package/dist/chunks/context-noninteractive-BtzPsJ8k.js +0 -1
  369. package/dist/chunks/conversation-C3NWyOB3.js +0 -1
  370. package/dist/chunks/conversation-oX932vBQ.js +0 -1
  371. package/dist/chunks/createSession-1ewHG3eq.js +0 -1
  372. package/dist/chunks/crossProjectResume-WmabPBTO.js +0 -40
  373. package/dist/chunks/datadog-Da7KYZNF.js +0 -1
  374. package/dist/chunks/earlyInput-JGJo1zcC.js +0 -1
  375. package/dist/chunks/envLessBridgeConfig-CpW0G4Eh.js +0 -1
  376. package/dist/chunks/exit-BsNW67F9.js +0 -1
  377. package/dist/chunks/extra-usage-DL2C0_BM.js +0 -1
  378. package/dist/chunks/extractMemories-CA2eJwHy.js +0 -1
  379. package/dist/chunks/fast-B01NO2uA.js +0 -1
  380. package/dist/chunks/gates-BSpXbh9s.js +0 -1
  381. package/dist/chunks/gemini-BEmbnRQR.js +0 -1
  382. package/dist/chunks/grok-BM6ZJ4w2.js +0 -1
  383. package/dist/chunks/hooks-QXGwOfWj.js +0 -1
  384. package/dist/chunks/inboundAttachments-N5DKbZSl.js +0 -1
  385. package/dist/chunks/initReplBridge-3CfmzjJL.js +0 -1
  386. package/dist/chunks/language-DmbRGIs8.js +0 -1
  387. package/dist/chunks/loadAgentsDir-ILQxk_4G.js +0 -1
  388. package/dist/chunks/loadPluginHooks-BC1Ea7_D.js +0 -1
  389. package/dist/chunks/localSearch-COyJeP9E.js +0 -1
  390. package/dist/chunks/login-Cf89biEK.js +0 -1
  391. package/dist/chunks/logout-CEXwTlEX.js +0 -1
  392. package/dist/chunks/mcp-BrN_Tbq5.js +0 -6
  393. package/dist/chunks/mcp-CZltNml5.js +0 -1
  394. package/dist/chunks/mcp-D6JOqdT8.js +0 -2
  395. package/dist/chunks/memory-BYYOgo4e.js +0 -1
  396. package/dist/chunks/model-CHgqwg6N.js +0 -1
  397. package/dist/chunks/permissions-C7wcAYOc.js +0 -3
  398. package/dist/chunks/pluginBlocklist-C_Veew3p.js +0 -1
  399. package/dist/chunks/pluginOperations-CP6NFNog.js +0 -2
  400. package/dist/chunks/pluginStartupCheck-BF0xUEJG.js +0 -1
  401. package/dist/chunks/plugins-BHoniP5f.js +0 -4
  402. package/dist/chunks/policyLimits-sh7ywop0.js +0 -1
  403. package/dist/chunks/poorMode-DZQXZ_zu.js +0 -1
  404. package/dist/chunks/print-BcRG8gkQ.js +0 -39
  405. package/dist/chunks/processBashCommand-DPfJ9lrj.js +0 -1
  406. package/dist/chunks/processSlashCommand-DyPCeZux.js +0 -6
  407. package/dist/chunks/prompt-DaIJzI1P.js +0 -1
  408. package/dist/chunks/prompt-DnLsyywj.js +0 -1
  409. package/dist/chunks/rate-limit-options-P7oQuwrl.js +0 -1
  410. package/dist/chunks/refresh-BeSXaVya.js +0 -1
  411. package/dist/chunks/registry-Dp5W2V8B.js +0 -1
  412. package/dist/chunks/rename-Bigaipiq.js +0 -1
  413. package/dist/chunks/sandbox-adapter-BbrJOJNZ.js +0 -1
  414. package/dist/chunks/searchExtraTools-Denn1c1E.js +0 -1
  415. package/dist/chunks/sessionFileAccessHooks-1IAwziOQ.js +0 -1
  416. package/dist/chunks/sessionMemory-3TAJyNuJ.js +0 -1
  417. package/dist/chunks/sessionMemory-HZNzEOLd.js +0 -1
  418. package/dist/chunks/sessionMemoryUtils-BAkA4sGG.js +0 -1
  419. package/dist/chunks/sessionObserver-DqLMFMLM.js +0 -1
  420. package/dist/chunks/sessionStorage-CFfMypMQ.js +0 -1
  421. package/dist/chunks/setup-D1sQnli9.js +0 -2
  422. package/dist/chunks/sink-fGBOXJab.js +0 -1
  423. package/dist/chunks/sinks-BCl9slVM.js +0 -1
  424. package/dist/chunks/skillChangeDetector-BOH-fyEn.js +0 -1
  425. package/dist/chunks/skillLearning-BDsjN-u-.js +0 -1
  426. package/dist/chunks/skillLearning-CXUsWxdi.js +0 -1
  427. package/dist/chunks/statusNoticeHelpers-reCcymMR.js +0 -1
  428. package/dist/chunks/teamHelpers-BBhol4dD.js +0 -1
  429. package/dist/chunks/teammateModeSnapshot-W5G22rwQ.js +0 -1
  430. package/dist/chunks/teleport-Da0rKwCo.js +0 -1
  431. package/dist/chunks/thinkback-Cd1g_2A9.js +0 -1
  432. package/dist/chunks/thinkback-ChP6pvCS.js +0 -1
  433. package/dist/chunks/thinkback-play-Cg8Ys2dq.js +0 -1
  434. package/dist/chunks/toolPool-CN1cPGQz.js +0 -1
  435. package/dist/chunks/toolPool-CygNb5cr.js +0 -1
  436. package/dist/chunks/undercover-bx8TwG9W.js +0 -1
  437. package/dist/chunks/upgrade-BkHztwGA.js +0 -1
  438. package/dist/chunks/useMainLoopModel-X1PW9z5A.js +0 -1
  439. package/dist/chunks/useMergedTools-CC3XwtOR.js +0 -1
  440. package/dist/chunks/useSettingsErrors-vGzCYpIA.js +0 -1
  441. package/dist/chunks/utils-Dg0S2Vfn.js +0 -1
  442. package/dist/chunks/validatePlugin-_Z4zhjSx.js +0 -1
  443. package/dist/chunks/voiceModeEnabled-BqFYzoXw.js +0 -1
  444. package/dist/chunks/voiceStreamSTT-C0pkuXGm.js +0 -1
  445. package/dist/chunks/worktree-Cg4p1J__.js +0 -1
  446. /package/dist/chunks/{InProcessTransport-DB52dh4f.js → InProcessTransport-gJLr5CIx.js} +0 -0
  447. /package/dist/chunks/{attributionHooks-PygdohOh.js → attributionHooks-Br5LZ6bk.js} +0 -0
  448. /package/dist/chunks/{attributionTrailer-BpvhXgRP.js → attributionTrailer-BMTuK4Ax.js} +0 -0
  449. /package/dist/chunks/{autoModeDenials-Cp6VFdsm.js → autoModeDenials-D8eQ1CoM.js} +0 -0
  450. /package/dist/chunks/{banner-CVXH2xts.js → banner-32EBTKI7.js} +0 -0
  451. /package/dist/chunks/{bedrockClient-qi1-JCOK.js → bedrockClient-Ci523Btx.js} +0 -0
  452. /package/dist/chunks/{ccshareResume-DWLjTF22.js → ccshareResume-CqNm2k-J.js} +0 -0
  453. /package/dist/chunks/{chromeNativeHost-4U39yLtd.js → chromeNativeHost-DX8f9Y2L.js} +0 -0
  454. /package/dist/chunks/{claudeDesktop-D0S1eq1F.js → claudeDesktop-C1qQs6os.js} +0 -0
  455. /package/dist/chunks/{cleanup-Bg_gFgcj.js → cleanup-Pv6U3HiI.js} +0 -0
  456. /package/dist/chunks/{connectHeadless-CwsFt-Mh.js → connectHeadless-DFCrE6O4.js} +0 -0
  457. /package/dist/chunks/{dangerousBackend-BU_PHGR2.js → dangerousBackend-Du0K4q5Z.js} +0 -0
  458. /package/dist/chunks/{earlyInput-tRkbxFv2.js → earlyInput-feVuZGzR.js} +0 -0
  459. /package/dist/chunks/{eventLoopStallDetector-Dnh1fc31.js → eventLoopStallDetector-XfubcyMN.js} +0 -0
  460. /package/dist/chunks/{fpsMetrics-DeezdcwV.js → fpsMetrics-CEQt6Tk1.js} +0 -0
  461. /package/dist/chunks/{fuse-Ch_OAlm3.js → fuse-TM-TeOo_.js} +0 -0
  462. /package/dist/chunks/{instinctParser-DHMa8xa0.js → instinctParser-CJPM8VjX.js} +0 -0
  463. /package/dist/chunks/{lockfile-DBwdlC3K.js → lockfile-Y1hwdHrQ.js} +0 -0
  464. /package/dist/chunks/{main-C6be1KFk.js → main-D9fUXJiD.js} +0 -0
  465. /package/dist/chunks/{observationStore-tvkldXUo.js → observationStore-gFvWXJmc.js} +0 -0
  466. /package/dist/chunks/{openaiShared-Bjrci9n8.js → openaiShared-Dy78YERG.js} +0 -0
  467. /package/dist/chunks/{output-style-XDb9-2Kk.js → output-style-BmEQscMd.js} +0 -0
  468. /package/dist/chunks/{parseConnectUrl-BS6i9JPo.js → parseConnectUrl-C6cvMkkH.js} +0 -0
  469. /package/dist/chunks/{poller-Ds0Y6Cir.js → poller-Dbo07OEA.js} +0 -0
  470. /package/dist/chunks/{postCommitAttribution-Ehmwzzuq.js → postCommitAttribution-DhFkZMxJ.js} +0 -0
  471. /package/dist/chunks/{projectContext-eXMSfgdZ.js → projectContext-iWPqcl0Z.js} +0 -0
  472. /package/dist/chunks/{renderOptions-BiyC2rj1.js → renderOptions-rmj4Mkls.js} +0 -0
  473. /package/dist/chunks/{rewind-CXplHgh_.js → rewind-DAn-nNs-.js} +0 -0
  474. /package/dist/chunks/{sanitization-CYp-9DbE.js → sanitization-JYRkZFrK.js} +0 -0
  475. /package/dist/chunks/{sdkHeapDumpMonitor--fevrC5z.js → sdkHeapDumpMonitor-DKtfJW5o.js} +0 -0
  476. /package/dist/chunks/{server-C5XZSlto.js → server-CswFAYwN.js} +0 -0
  477. /package/dist/chunks/{serverBanner-WlSYP-f8.js → serverBanner-CImTYGhY.js} +0 -0
  478. /package/dist/chunks/{serverLog-DtsUvDiY.js → serverLog-Bwt7XEmk.js} +0 -0
  479. /package/dist/chunks/{sessionDataUploader-Ctjo1bgR.js → sessionDataUploader-CKRXCBxI.js} +0 -0
  480. /package/dist/chunks/{sessionManager-Dw72ZUTg.js → sessionManager-Ca2O821f.js} +0 -0
  481. /package/dist/chunks/{stickers-2K05wjSp.js → stickers-BMh2qjgF.js} +0 -0
  482. /package/dist/chunks/{udsClient-BvG_Jip0.js → udsClient-BdPOrL1H.js} +0 -0
  483. /package/dist/chunks/{upstreamproxy-DcLeL2XX.js → upstreamproxy-Ci5T_JCo.js} +0 -0
  484. /package/dist/chunks/{voice-DXiiy8HX.js → voice-BcA5h8ya.js} +0 -0
@@ -1,11 +1,11 @@
1
- import{n as e}from"./chunk-DR8-3Aex.js";import{n as t,s as n}from"./envUtils-BWeoiL4Y.js";import{Oo as r,Pr as i,Tr as a,jo as o,rs as s}from"./paths-D9CVAtXU.js";import{E as c,K as l,T as u,V as d,w as f}from"./debug-UI3T040K.js";import{o as p,s as m}from"./log-CzsijfHZ.js";import{r as h,t as g}from"./execFileNoThrow-CuQN1sz8.js";import{Ar as _,Co as v,Cr as y,LO as b,Lo as x,Uk as S,Wk as ee,it as C,tt as te,wr as ne,xr as re,zr as ie}from"./loadAgentsDir-D-xcJ22-.js";import{n as w,r as ae}from"./xml-K_hNNh2b.js";import{X as T}from"./rcDebugLog-CTOZ2K3E.js";import{tmpdir as oe}from"os";import{extname as se,join as E}from"path";import{constants as ce}from"fs";import{copyFile as le,mkdir as D,mkdtemp as ue,readFile as O,readdir as k,rm as de,unlink as fe,writeFile as A}from"fs/promises";import{execFileSync as pe}from"child_process";function j(){return a()}function me(){return a()}function M(){return E(t(),`usage-data`)}function N(){return E(M(),`facets`)}function P(){return E(M(),`session-meta`)}function he(e){return K[se(e).toLowerCase()]||null}function ge(e){let t={},n={},i=0,a=0,o=0,s=0,c=0,l=[],u=0,d={},f=!1,p=0,m=0,h=new Set,g=[],_=[],v=!1,y=!1,b=!1,x=null;for(let S of e.messages){let e=S.timestamp;if(S.type===`assistant`&&S.message){e&&(x=e);let c=S.message.usage;c&&(o+=c.input_tokens||0,s+=c.output_tokens||0);let l=S.message.content;if(Array.isArray(l)){for(let e of l)if(e.type===`tool_use`&&`name`in e){let o=e.name;t[o]=(t[o]||0)+1,(o===`Agent`||o===`Task`)&&(f=!0),o.startsWith(`mcp__`)&&(v=!0),o===`WebSearch`&&(y=!0),o===`WebFetch`&&(b=!0);let s=e.input;if(s){let e=s.file_path||``;if(e){let t=he(e);t&&(n[t]=(n[t]||0)+1),(o===`Edit`||o===`Write`)&&h.add(e)}if(o===`Edit`){let e=s.old_string||``,t=s.new_string||``;for(let n of ee(e,t))n.added&&(p+=n.count||0),n.removed&&(m+=n.count||0)}if(o===`Write`){let e=s.content||``;e&&(p+=r(e,`
2
- `)+1)}let t=s.command||``;t.includes(`git commit`)&&i++,t.includes(`git push`)&&a++}}}}if(S.type===`user`&&S.message){let t=S.message.content,n=!1;if(typeof t==`string`&&t.trim())n=!0;else if(Array.isArray(t)){for(let e of t)if(e.type===`text`&&`text`in e){n=!0;break}}if(n){if(e)try{let t=new Date(e).getHours();g.push(t),_.push(e)}catch{}if(x&&e){let t=new Date(x).getTime(),n=(new Date(e).getTime()-t)/1e3;n>2&&n<3600&&l.push(n)}}if(Array.isArray(t)){for(let e of t)if(e.type===`tool_result`&&`content`in e&&e.is_error){u++;let t=e.content,n=`Other`;if(typeof t==`string`){let e=t.toLowerCase();e.includes(`exit code`)?n=`Command Failed`:e.includes(`rejected`)||e.includes(`doesn't want`)?n=`User Rejected`:e.includes(`string to replace not found`)||e.includes(`no changes`)?n=`Edit Failed`:e.includes(`modified since read`)?n=`File Changed`:e.includes(`exceeds maximum`)||e.includes(`too large`)?n=`File Too Large`:(e.includes(`file not found`)||e.includes(`does not exist`))&&(n=`File Not Found`)}d[n]=(d[n]||0)+1}}if(typeof t==`string`)t.includes(`[Request interrupted by user`)&&c++;else if(Array.isArray(t)){for(let e of t)if(e.type===`text`&&`text`in e&&e.text.includes(`[Request interrupted by user`)){c++;break}}}}return{toolCounts:t,languages:n,gitCommits:i,gitPushes:a,inputTokens:o,outputTokens:s,userInterruptions:c,userResponseTimes:l,toolErrors:u,toolErrorCategories:d,usesTaskAgent:f,usesMcp:v,usesWebSearch:y,usesWebFetch:b,linesAdded:p,linesRemoved:m,filesModified:h,messageHours:g,userMessageTimestamps:_}}function _e(e){return!Number.isNaN(e.created.getTime())&&!Number.isNaN(e.modified.getTime())}function F(e){let t=ge(e),n=ne(e)||`unknown`,r=e.created.toISOString(),i=Math.round((e.modified.getTime()-e.created.getTime())/1e3/60),a=0,o=0;for(let t of e.messages)if(t.type===`assistant`&&o++,t.type===`user`&&t.message){let e=t.message.content,n=!1;if(typeof e==`string`&&e.trim())n=!0;else if(Array.isArray(e)){for(let t of e)if(t.type===`text`&&`text`in t){n=!0;break}}n&&a++}return{session_id:n,project_path:e.projectPath||``,start_time:r,duration_minutes:i,user_message_count:a,assistant_message_count:o,tool_counts:t.toolCounts,languages:t.languages,git_commits:t.gitCommits,git_pushes:t.gitPushes,input_tokens:t.inputTokens,output_tokens:t.outputTokens,first_prompt:e.firstPrompt||``,summary:e.summary,user_interruptions:t.userInterruptions,user_response_times:t.userResponseTimes,tool_errors:t.toolErrors,tool_error_categories:t.toolErrorCategories,uses_task_agent:t.usesTaskAgent,uses_mcp:t.usesMcp,uses_web_search:t.usesWebSearch,uses_web_fetch:t.usesWebFetch,lines_added:t.linesAdded,lines_removed:t.linesRemoved,files_modified:t.filesModified.size,message_hours:t.messageHours,user_message_timestamps:t.userMessageTimestamps}}function ve(e){let t=[],n=F(e);t.push(`Session: ${n.session_id.slice(0,8)}`),t.push(`Date: ${n.start_time}`),t.push(`Project: ${n.project_path}`),t.push(`Duration: ${n.duration_minutes} min`),t.push(``);for(let n of e.messages)if(n.type===`user`&&n.message){let e=n.message.content;if(typeof e==`string`)t.push(`[User]: ${e.slice(0,500)}`);else if(Array.isArray(e))for(let n of e)n.type===`text`&&`text`in n&&t.push(`[User]: ${n.text.slice(0,500)}`)}else if(n.type===`assistant`&&n.message){let e=n.message.content;if(Array.isArray(e))for(let n of e)n.type===`text`&&`text`in n?t.push(`[Assistant]: ${n.text.slice(0,300)}`):n.type===`tool_use`&&`name`in n&&t.push(`[Tool: ${n.name}]`)}return t.join(`
3
- `)}async function ye(e){try{return v((await C({systemPrompt:T([]),userPrompt:Y+e,signal:new AbortController().signal,options:{model:j(),querySource:`insights`,agents:[],isNonInteractiveSession:!0,hasAppendSystemPrompt:!1,mcpTools:[],maxOutputTokensOverride:500}})).message.content)||e.slice(0,2e3)}catch{return e.slice(0,2e3)}}async function be(e){let t=ve(e);if(t.length<=3e4)return t;let n=25e3,r=[];for(let e=0;e<t.length;e+=n)r.push(t.slice(e,e+n));let i=await Promise.all(r.map(ye)),a=F(e);return[`Session: ${a.session_id.slice(0,8)}`,`Date: ${a.start_time}`,`Project: ${a.project_path}`,`Duration: ${a.duration_minutes} min`,`[Long session - ${r.length} parts summarized]`,``].join(`
1
+ import{n as e}from"./chunk-DR8-3Aex.js";import{n as t,s as n}from"./envUtils-BWeoiL4Y.js";import{Oo as r,Pr as i,Tr as a,jo as o,rs as s}from"./paths-BZbIj1Z1.js";import{E as c,K as l,T as u,V as d,w as f}from"./debug-UI3T040K.js";import{o as p,s as m}from"./log-CzsijfHZ.js";import{r as h,t as g}from"./execFileNoThrow-CuQN1sz8.js";import{Do as _,Dr as v,Jk as y,Or as b,Pr as x,Tr as S,Ur as C,VO as ee,Vo as te,it as w,qk as ne,tt as re}from"./loadAgentsDir-DaApSWNv.js";import{n as T,r as ie}from"./xml-Dg8-vY8G.js";import{X as E}from"./rcDebugLog-CF73Wofq.js";import{tmpdir as ae}from"os";import{extname as oe,join as D}from"path";import{constants as se}from"fs";import{copyFile as ce,mkdir as O,mkdtemp as le,readFile as k,readdir as A,rm as ue,unlink as de,writeFile as j}from"fs/promises";import{execFileSync as fe}from"child_process";function M(){return a()}function pe(){return a()}function N(){return D(t(),`usage-data`)}function P(){return D(N(),`facets`)}function F(){return D(N(),`session-meta`)}function me(e){return K[oe(e).toLowerCase()]||null}function he(e){let t={},n={},i=0,a=0,o=0,s=0,c=0,l=[],u=0,d={},f=!1,p=0,m=0,h=new Set,g=[],_=[],v=!1,b=!1,x=!1,S=null;for(let C of e.messages){let e=C.timestamp;if(C.type===`assistant`&&C.message){e&&(S=e);let c=C.message.usage;c&&(o+=c.input_tokens||0,s+=c.output_tokens||0);let l=C.message.content;if(Array.isArray(l)){for(let e of l)if(e.type===`tool_use`&&`name`in e){let o=e.name;t[o]=(t[o]||0)+1,(o===`Agent`||o===`Task`)&&(f=!0),o.startsWith(`mcp__`)&&(v=!0),o===`WebSearch`&&(b=!0),o===`WebFetch`&&(x=!0);let s=e.input;if(s){let e=s.file_path||``;if(e){let t=me(e);t&&(n[t]=(n[t]||0)+1),(o===`Edit`||o===`Write`)&&h.add(e)}if(o===`Edit`){let e=s.old_string||``,t=s.new_string||``;for(let n of y(e,t))n.added&&(p+=n.count||0),n.removed&&(m+=n.count||0)}if(o===`Write`){let e=s.content||``;e&&(p+=r(e,`
2
+ `)+1)}let t=s.command||``;t.includes(`git commit`)&&i++,t.includes(`git push`)&&a++}}}}if(C.type===`user`&&C.message){let t=C.message.content,n=!1;if(typeof t==`string`&&t.trim())n=!0;else if(Array.isArray(t)){for(let e of t)if(e.type===`text`&&`text`in e){n=!0;break}}if(n){if(e)try{let t=new Date(e).getHours();g.push(t),_.push(e)}catch{}if(S&&e){let t=new Date(S).getTime(),n=(new Date(e).getTime()-t)/1e3;n>2&&n<3600&&l.push(n)}}if(Array.isArray(t)){for(let e of t)if(e.type===`tool_result`&&`content`in e&&e.is_error){u++;let t=e.content,n=`Other`;if(typeof t==`string`){let e=t.toLowerCase();e.includes(`exit code`)?n=`Command Failed`:e.includes(`rejected`)||e.includes(`doesn't want`)?n=`User Rejected`:e.includes(`string to replace not found`)||e.includes(`no changes`)?n=`Edit Failed`:e.includes(`modified since read`)?n=`File Changed`:e.includes(`exceeds maximum`)||e.includes(`too large`)?n=`File Too Large`:(e.includes(`file not found`)||e.includes(`does not exist`))&&(n=`File Not Found`)}d[n]=(d[n]||0)+1}}if(typeof t==`string`)t.includes(`[Request interrupted by user`)&&c++;else if(Array.isArray(t)){for(let e of t)if(e.type===`text`&&`text`in e&&e.text.includes(`[Request interrupted by user`)){c++;break}}}}return{toolCounts:t,languages:n,gitCommits:i,gitPushes:a,inputTokens:o,outputTokens:s,userInterruptions:c,userResponseTimes:l,toolErrors:u,toolErrorCategories:d,usesTaskAgent:f,usesMcp:v,usesWebSearch:b,usesWebFetch:x,linesAdded:p,linesRemoved:m,filesModified:h,messageHours:g,userMessageTimestamps:_}}function ge(e){return!Number.isNaN(e.created.getTime())&&!Number.isNaN(e.modified.getTime())}function I(e){let t=he(e),n=b(e)||`unknown`,r=e.created.toISOString(),i=Math.round((e.modified.getTime()-e.created.getTime())/1e3/60),a=0,o=0;for(let t of e.messages)if(t.type===`assistant`&&o++,t.type===`user`&&t.message){let e=t.message.content,n=!1;if(typeof e==`string`&&e.trim())n=!0;else if(Array.isArray(e)){for(let t of e)if(t.type===`text`&&`text`in t){n=!0;break}}n&&a++}return{session_id:n,project_path:e.projectPath||``,start_time:r,duration_minutes:i,user_message_count:a,assistant_message_count:o,tool_counts:t.toolCounts,languages:t.languages,git_commits:t.gitCommits,git_pushes:t.gitPushes,input_tokens:t.inputTokens,output_tokens:t.outputTokens,first_prompt:e.firstPrompt||``,summary:e.summary,user_interruptions:t.userInterruptions,user_response_times:t.userResponseTimes,tool_errors:t.toolErrors,tool_error_categories:t.toolErrorCategories,uses_task_agent:t.usesTaskAgent,uses_mcp:t.usesMcp,uses_web_search:t.usesWebSearch,uses_web_fetch:t.usesWebFetch,lines_added:t.linesAdded,lines_removed:t.linesRemoved,files_modified:t.filesModified.size,message_hours:t.messageHours,user_message_timestamps:t.userMessageTimestamps}}function _e(e){let t=[],n=I(e);t.push(`Session: ${n.session_id.slice(0,8)}`),t.push(`Date: ${n.start_time}`),t.push(`Project: ${n.project_path}`),t.push(`Duration: ${n.duration_minutes} min`),t.push(``);for(let n of e.messages)if(n.type===`user`&&n.message){let e=n.message.content;if(typeof e==`string`)t.push(`[User]: ${e.slice(0,500)}`);else if(Array.isArray(e))for(let n of e)n.type===`text`&&`text`in n&&t.push(`[User]: ${n.text.slice(0,500)}`)}else if(n.type===`assistant`&&n.message){let e=n.message.content;if(Array.isArray(e))for(let n of e)n.type===`text`&&`text`in n?t.push(`[Assistant]: ${n.text.slice(0,300)}`):n.type===`tool_use`&&`name`in n&&t.push(`[Tool: ${n.name}]`)}return t.join(`
3
+ `)}async function ve(e){try{return _((await w({systemPrompt:E([]),userPrompt:Y+e,signal:new AbortController().signal,options:{model:M(),querySource:`insights`,agents:[],isNonInteractiveSession:!0,hasAppendSystemPrompt:!1,mcpTools:[],maxOutputTokensOverride:500}})).message.content)||e.slice(0,2e3)}catch{return e.slice(0,2e3)}}async function ye(e){let t=_e(e);if(t.length<=3e4)return t;let n=25e3,r=[];for(let e=0;e<t.length;e+=n)r.push(t.slice(e,e+n));let i=await Promise.all(r.map(ve)),a=I(e);return[`Session: ${a.session_id.slice(0,8)}`,`Date: ${a.start_time}`,`Project: ${a.project_path}`,`Duration: ${a.duration_minutes} min`,`[Long session - ${r.length} parts summarized]`,``].join(`
4
4
  `)+i.join(`
5
5
 
6
6
  ---
7
7
 
8
- `)}async function xe(e){let t=E(N(),`${e}.json`);try{let e=u(await O(t,{encoding:`utf-8`}));if(!V(e)){try{await fe(t)}catch{}return null}return e}catch{return null}}async function Se(e){try{await D(N(),{recursive:!0})}catch{}await A(E(N(),`${e.session_id}.json`),c(e,null,2),{encoding:`utf-8`,mode:384})}async function Ce(e){let t=E(P(),`${e}.json`);try{return u(await O(t,{encoding:`utf-8`}))}catch{return null}}async function we(e){try{await D(P(),{recursive:!0})}catch{}await A(E(P(),`${e.session_id}.json`),c(e,null,2),{encoding:`utf-8`,mode:384})}async function Te(e,t){try{let n=`${J}${await be(e)}
8
+ `)}async function be(e){let t=D(P(),`${e}.json`);try{let e=u(await k(t,{encoding:`utf-8`}));if(!V(e)){try{await de(t)}catch{}return null}return e}catch{return null}}async function xe(e){try{await O(P(),{recursive:!0})}catch{}await j(D(P(),`${e.session_id}.json`),c(e,null,2),{encoding:`utf-8`,mode:384})}async function Se(e){let t=D(F(),`${e}.json`);try{return u(await k(t,{encoding:`utf-8`}))}catch{return null}}async function Ce(e){try{await O(F(),{recursive:!0})}catch{}await j(D(F(),`${e.session_id}.json`),c(e,null,2),{encoding:`utf-8`,mode:384})}async function we(e,t){try{let n=`${J}${await ye(e)}
9
9
 
10
10
  RESPOND WITH ONLY A VALID JSON OBJECT matching this schema:
11
11
  {
@@ -19,10 +19,10 @@ RESPOND WITH ONLY A VALID JSON OBJECT matching this schema:
19
19
  "friction_detail": "One sentence describing friction or empty",
20
20
  "primary_success": "none|fast_accurate_search|correct_code_edits|good_explanations|proactive_help|multi_file_changes|good_debugging",
21
21
  "brief_summary": "One sentence: what user wanted and whether they got it"
22
- }`,r=v((await C({systemPrompt:T([]),userPrompt:n,signal:new AbortController().signal,options:{model:j(),querySource:`insights`,agents:[],isNonInteractiveSession:!0,hasAppendSystemPrompt:!1,mcpTools:[],maxOutputTokensOverride:4096}})).message.content).match(/\{[\s\S]*\}/);if(!r)return null;let i=u(r[0]);return V(i)?{...i,session_id:t}:null}catch(e){return m(Error(`Facet extraction failed: ${l(e).message}`)),null}}function Ee(e){let t=[];for(let n of e)for(let e of n.user_message_timestamps)try{let r=new Date(e).getTime();t.push({ts:r,sessionId:n.session_id})}catch{}t.sort((e,t)=>e.ts-t.ts);let n=new Set,r=new Set,i=0,a=new Map;for(let e=0;e<t.length;e++){let o=t[e];for(;i<e&&o.ts-t[i].ts>18e5;){let e=t[i];a.get(e.sessionId)===i&&a.delete(e.sessionId),i++}let s=a.get(o.sessionId);if(s!==void 0)for(let i=s+1;i<e;i++){let e=t[i];if(e.sessionId!==o.sessionId){let i=[o.sessionId,e.sessionId].sort().join(`:`);n.add(i),r.add(`${t[s].ts}:${o.sessionId}`),r.add(`${e.ts}:${e.sessionId}`),r.add(`${o.ts}:${o.sessionId}`);break}}a.set(o.sessionId,e)}let o=new Set;for(let e of n){let[t,n]=e.split(`:`);t&&o.add(t),n&&o.add(n)}return{overlap_events:n.size,sessions_involved:o.size,user_messages_during:r.size}}function De(e,t){let n={total_sessions:e.length,sessions_with_facets:t.size,date_range:{start:``,end:``},total_messages:0,total_duration_hours:0,total_input_tokens:0,total_output_tokens:0,tool_counts:{},languages:{},git_commits:0,git_pushes:0,projects:{},goal_categories:{},outcomes:{},satisfaction:{},helpfulness:{},session_types:{},friction:{},success:{},session_summaries:[],total_interruptions:0,total_tool_errors:0,tool_error_categories:{},user_response_times:[],median_response_time:0,avg_response_time:0,sessions_using_task_agent:0,sessions_using_mcp:0,sessions_using_web_search:0,sessions_using_web_fetch:0,total_lines_added:0,total_lines_removed:0,total_files_modified:0,days_active:0,messages_per_day:0,message_hours:[],multi_clauding:{overlap_events:0,sessions_involved:0,user_messages_during:0}},r=[],i=[],a=[];for(let o of e){r.push(o.start_time),n.total_messages+=o.user_message_count,n.total_duration_hours+=o.duration_minutes/60,n.total_input_tokens+=o.input_tokens,n.total_output_tokens+=o.output_tokens,n.git_commits+=o.git_commits,n.git_pushes+=o.git_pushes,n.total_interruptions+=o.user_interruptions,n.total_tool_errors+=o.tool_errors;for(let[e,t]of Object.entries(o.tool_error_categories))n.tool_error_categories[e]=(n.tool_error_categories[e]||0)+t;i.push(...o.user_response_times),o.uses_task_agent&&n.sessions_using_task_agent++,o.uses_mcp&&n.sessions_using_mcp++,o.uses_web_search&&n.sessions_using_web_search++,o.uses_web_fetch&&n.sessions_using_web_fetch++,n.total_lines_added+=o.lines_added,n.total_lines_removed+=o.lines_removed,n.total_files_modified+=o.files_modified,a.push(...o.message_hours);for(let[e,t]of Object.entries(o.tool_counts))n.tool_counts[e]=(n.tool_counts[e]||0)+t;for(let[e,t]of Object.entries(o.languages))n.languages[e]=(n.languages[e]||0)+t;o.project_path&&(n.projects[o.project_path]=(n.projects[o.project_path]||0)+1);let e=t.get(o.session_id);if(e){for(let[t,r]of B(e.goal_categories))r>0&&(n.goal_categories[t]=(n.goal_categories[t]||0)+r);n.outcomes[e.outcome]=(n.outcomes[e.outcome]||0)+1;for(let[t,r]of B(e.user_satisfaction_counts))r>0&&(n.satisfaction[t]=(n.satisfaction[t]||0)+r);n.helpfulness[e.claude_helpfulness]=(n.helpfulness[e.claude_helpfulness]||0)+1,n.session_types[e.session_type]=(n.session_types[e.session_type]||0)+1;for(let[t,r]of B(e.friction_counts))r>0&&(n.friction[t]=(n.friction[t]||0)+r);e.primary_success!==`none`&&(n.success[e.primary_success]=(n.success[e.primary_success]||0)+1)}n.session_summaries.length<50&&n.session_summaries.push({id:o.session_id.slice(0,8),date:o.start_time.split(`T`)[0]||``,summary:o.summary||o.first_prompt.slice(0,100),goal:e?.underlying_goal})}if(r.sort(),n.date_range.start=r[0]?.split(`T`)[0]||``,n.date_range.end=r[r.length-1]?.split(`T`)[0]||``,n.user_response_times=i,i.length>0){let e=[...i].sort((e,t)=>e-t);n.median_response_time=e[Math.floor(e.length/2)]||0,n.avg_response_time=i.reduce((e,t)=>e+t,0)/i.length}return n.days_active=new Set(r.map(e=>e.split(`T`)[0])).size,n.messages_per_day=n.days_active>0?Math.round(n.total_messages/n.days_active*10)/10:0,n.message_hours=a,n.multi_clauding=Ee(e),n}async function I(e,t){try{let n=v((await C({systemPrompt:T([]),userPrompt:e.prompt+`
22
+ }`,r=_((await w({systemPrompt:E([]),userPrompt:n,signal:new AbortController().signal,options:{model:M(),querySource:`insights`,agents:[],isNonInteractiveSession:!0,hasAppendSystemPrompt:!1,mcpTools:[],maxOutputTokensOverride:4096}})).message.content).match(/\{[\s\S]*\}/);if(!r)return null;let i=u(r[0]);return V(i)?{...i,session_id:t}:null}catch(e){return m(Error(`Facet extraction failed: ${l(e).message}`)),null}}function Te(e){let t=[];for(let n of e)for(let e of n.user_message_timestamps)try{let r=new Date(e).getTime();t.push({ts:r,sessionId:n.session_id})}catch{}t.sort((e,t)=>e.ts-t.ts);let n=new Set,r=new Set,i=0,a=new Map;for(let e=0;e<t.length;e++){let o=t[e];for(;i<e&&o.ts-t[i].ts>18e5;){let e=t[i];a.get(e.sessionId)===i&&a.delete(e.sessionId),i++}let s=a.get(o.sessionId);if(s!==void 0)for(let i=s+1;i<e;i++){let e=t[i];if(e.sessionId!==o.sessionId){let i=[o.sessionId,e.sessionId].sort().join(`:`);n.add(i),r.add(`${t[s].ts}:${o.sessionId}`),r.add(`${e.ts}:${e.sessionId}`),r.add(`${o.ts}:${o.sessionId}`);break}}a.set(o.sessionId,e)}let o=new Set;for(let e of n){let[t,n]=e.split(`:`);t&&o.add(t),n&&o.add(n)}return{overlap_events:n.size,sessions_involved:o.size,user_messages_during:r.size}}function Ee(e,t){let n={total_sessions:e.length,sessions_with_facets:t.size,date_range:{start:``,end:``},total_messages:0,total_duration_hours:0,total_input_tokens:0,total_output_tokens:0,tool_counts:{},languages:{},git_commits:0,git_pushes:0,projects:{},goal_categories:{},outcomes:{},satisfaction:{},helpfulness:{},session_types:{},friction:{},success:{},session_summaries:[],total_interruptions:0,total_tool_errors:0,tool_error_categories:{},user_response_times:[],median_response_time:0,avg_response_time:0,sessions_using_task_agent:0,sessions_using_mcp:0,sessions_using_web_search:0,sessions_using_web_fetch:0,total_lines_added:0,total_lines_removed:0,total_files_modified:0,days_active:0,messages_per_day:0,message_hours:[],multi_clauding:{overlap_events:0,sessions_involved:0,user_messages_during:0}},r=[],i=[],a=[];for(let o of e){r.push(o.start_time),n.total_messages+=o.user_message_count,n.total_duration_hours+=o.duration_minutes/60,n.total_input_tokens+=o.input_tokens,n.total_output_tokens+=o.output_tokens,n.git_commits+=o.git_commits,n.git_pushes+=o.git_pushes,n.total_interruptions+=o.user_interruptions,n.total_tool_errors+=o.tool_errors;for(let[e,t]of Object.entries(o.tool_error_categories))n.tool_error_categories[e]=(n.tool_error_categories[e]||0)+t;i.push(...o.user_response_times),o.uses_task_agent&&n.sessions_using_task_agent++,o.uses_mcp&&n.sessions_using_mcp++,o.uses_web_search&&n.sessions_using_web_search++,o.uses_web_fetch&&n.sessions_using_web_fetch++,n.total_lines_added+=o.lines_added,n.total_lines_removed+=o.lines_removed,n.total_files_modified+=o.files_modified,a.push(...o.message_hours);for(let[e,t]of Object.entries(o.tool_counts))n.tool_counts[e]=(n.tool_counts[e]||0)+t;for(let[e,t]of Object.entries(o.languages))n.languages[e]=(n.languages[e]||0)+t;o.project_path&&(n.projects[o.project_path]=(n.projects[o.project_path]||0)+1);let e=t.get(o.session_id);if(e){for(let[t,r]of B(e.goal_categories))r>0&&(n.goal_categories[t]=(n.goal_categories[t]||0)+r);n.outcomes[e.outcome]=(n.outcomes[e.outcome]||0)+1;for(let[t,r]of B(e.user_satisfaction_counts))r>0&&(n.satisfaction[t]=(n.satisfaction[t]||0)+r);n.helpfulness[e.claude_helpfulness]=(n.helpfulness[e.claude_helpfulness]||0)+1,n.session_types[e.session_type]=(n.session_types[e.session_type]||0)+1;for(let[t,r]of B(e.friction_counts))r>0&&(n.friction[t]=(n.friction[t]||0)+r);e.primary_success!==`none`&&(n.success[e.primary_success]=(n.success[e.primary_success]||0)+1)}n.session_summaries.length<50&&n.session_summaries.push({id:o.session_id.slice(0,8),date:o.start_time.split(`T`)[0]||``,summary:o.summary||o.first_prompt.slice(0,100),goal:e?.underlying_goal})}if(r.sort(),n.date_range.start=r[0]?.split(`T`)[0]||``,n.date_range.end=r[r.length-1]?.split(`T`)[0]||``,n.user_response_times=i,i.length>0){let e=[...i].sort((e,t)=>e-t);n.median_response_time=e[Math.floor(e.length/2)]||0,n.avg_response_time=i.reduce((e,t)=>e+t,0)/i.length}return n.days_active=new Set(r.map(e=>e.split(`T`)[0])).size,n.messages_per_day=n.days_active>0?Math.round(n.total_messages/n.days_active*10)/10:0,n.message_hours=a,n.multi_clauding=Te(e),n}async function L(e,t){try{let n=_((await w({systemPrompt:E([]),userPrompt:e.prompt+`
23
23
 
24
24
  DATA:
25
- `+t,signal:new AbortController().signal,options:{model:me(),querySource:`insights`,agents:[],isNonInteractiveSession:!0,hasAppendSystemPrompt:!1,mcpTools:[],maxOutputTokensOverride:e.maxTokens}})).message.content);if(n){let t=n.match(/\{[\s\S]*\}/);if(t)try{return{name:e.name,result:u(t[0])}}catch{return{name:e.name,result:null}}}return{name:e.name,result:null}}catch(t){return m(Error(`${e.name} failed: ${l(t).message}`)),{name:e.name,result:null}}}async function Oe(e,t){let n=Array.from(t.values()).slice(0,50).map(e=>`- ${e.brief_summary} (${e.outcome}, ${e.claude_helpfulness})`).join(`
25
+ `+t,signal:new AbortController().signal,options:{model:pe(),querySource:`insights`,agents:[],isNonInteractiveSession:!0,hasAppendSystemPrompt:!1,mcpTools:[],maxOutputTokensOverride:e.maxTokens}})).message.content);if(n){let t=n.match(/\{[\s\S]*\}/);if(t)try{return{name:e.name,result:u(t[0])}}catch{return{name:e.name,result:null}}}return{name:e.name,result:null}}catch(t){return m(Error(`${e.name} failed: ${l(t).message}`)),{name:e.name,result:null}}}async function De(e,t){let n=Array.from(t.values()).slice(0,50).map(e=>`- ${e.brief_summary} (${e.outcome}, ${e.claude_helpfulness})`).join(`
26
26
  `),r=Array.from(t.values()).filter(e=>e.friction_detail).slice(0,20).map(e=>`- ${e.friction_detail}`).join(`
27
27
  `),i=Array.from(t.values()).flatMap(e=>e.user_instructions_to_claude||[]).slice(0,15).map(e=>`- ${e}`).join(`
28
28
  `),a=c({sessions:e.total_sessions,analyzed:e.sessions_with_facets,date_range:e.date_range,messages:e.total_messages,hours:Math.round(e.total_duration_hours),commits:e.git_commits,top_tools:Object.entries(e.tool_counts).sort((e,t)=>t[1]-e[1]).slice(0,8),top_goals:Object.entries(e.goal_categories).sort((e,t)=>t[1]-e[1]).slice(0,8),outcomes:e.outcomes,satisfaction:e.satisfaction,friction:e.friction,success:e.success,languages:e.languages},null,2)+`
@@ -34,7 +34,7 @@ FRICTION DETAILS:
34
34
  `+r+`
35
35
 
36
36
  USER INSTRUCTIONS TO CLAUDE:
37
- `+(i||`None captured`),o=await Promise.all(X.map(e=>I(e,a))),s={};for(let{name:e,result:t}of o)t&&(s[e]=t);let l=await I({name:`at_a_glance`,prompt:`You're writing an "At a Glance" summary for a Claude Code usage insights report for Claude Code users. The goal is to help them understand their usage and improve how they can use Claude better, especially as models improve.
37
+ `+(i||`None captured`),o=await Promise.all(X.map(e=>L(e,a))),s={};for(let{name:e,result:t}of o)t&&(s[e]=t);let l=await L({name:`at_a_glance`,prompt:`You're writing an "At a Glance" summary for a Claude Code usage insights report for Claude Code users. The goal is to help them understand their usage and improve how they can use Claude better, especially as models improve.
38
38
 
39
39
  Use this 4-part structure:
40
40
 
@@ -81,17 +81,17 @@ ${s.suggestions?.usage_patterns?.map(e=>`- ${e.title}: ${e.suggestion}`).join(`
81
81
 
82
82
  ## On the Horizon (ambitious workflows for better models)
83
83
  ${s.on_the_horizon?.opportunities?.map(e=>`- ${e.title}: ${e.whats_possible}`).join(`
84
- `)||``}`,maxTokens:8192},``);return l.result&&(s.at_a_glance=l.result),s}function L(e){return w(e).replace(/\*\*(.+?)\*\*/g,`<strong>$1</strong>`)}function R(e,t,n=6,r){let i;if(i=r?r.filter(t=>t in e&&(e[t]??0)>0).map(t=>[t,e[t]??0]):Object.entries(e).sort((e,t)=>t[1]-e[1]).slice(0,n),i.length===0)return`<p class="empty">No data</p>`;let a=Math.max(...i.map(e=>e[1]));return i.map(([e,n])=>{let r=n/a*100;return`<div class="bar-row">
85
- <div class="bar-label">${w(q[e]||e.replace(/_/g,` `).replace(/\b\w/g,e=>e.toUpperCase()))}</div>
84
+ `)||``}`,maxTokens:8192},``);return l.result&&(s.at_a_glance=l.result),s}function R(e){return T(e).replace(/\*\*(.+?)\*\*/g,`<strong>$1</strong>`)}function z(e,t,n=6,r){let i;if(i=r?r.filter(t=>t in e&&(e[t]??0)>0).map(t=>[t,e[t]??0]):Object.entries(e).sort((e,t)=>t[1]-e[1]).slice(0,n),i.length===0)return`<p class="empty">No data</p>`;let a=Math.max(...i.map(e=>e[1]));return i.map(([e,n])=>{let r=n/a*100;return`<div class="bar-row">
85
+ <div class="bar-label">${T(q[e]||e.replace(/_/g,` `).replace(/\b\w/g,e=>e.toUpperCase()))}</div>
86
86
  <div class="bar-track"><div class="bar-fill" style="width:${r}%;background:${t}"></div></div>
87
87
  <div class="bar-value">${n}</div>
88
88
  </div>`}).join(`
89
- `)}function ke(e){if(e.length===0)return`<p class="empty">No response time data</p>`;let t={"2-10s":0,"10-30s":0,"30s-1m":0,"1-2m":0,"2-5m":0,"5-15m":0,">15m":0};for(let n of e)n<10?t[`2-10s`]=(t[`2-10s`]??0)+1:n<30?t[`10-30s`]=(t[`10-30s`]??0)+1:n<60?t[`30s-1m`]=(t[`30s-1m`]??0)+1:n<120?t[`1-2m`]=(t[`1-2m`]??0)+1:n<300?t[`2-5m`]=(t[`2-5m`]??0)+1:n<900?t[`5-15m`]=(t[`5-15m`]??0)+1:t[`>15m`]=(t[`>15m`]??0)+1;let n=Math.max(...Object.values(t));return n===0?`<p class="empty">No response time data</p>`:Object.entries(t).map(([e,t])=>`<div class="bar-row">
89
+ `)}function Oe(e){if(e.length===0)return`<p class="empty">No response time data</p>`;let t={"2-10s":0,"10-30s":0,"30s-1m":0,"1-2m":0,"2-5m":0,"5-15m":0,">15m":0};for(let n of e)n<10?t[`2-10s`]=(t[`2-10s`]??0)+1:n<30?t[`10-30s`]=(t[`10-30s`]??0)+1:n<60?t[`30s-1m`]=(t[`30s-1m`]??0)+1:n<120?t[`1-2m`]=(t[`1-2m`]??0)+1:n<300?t[`2-5m`]=(t[`2-5m`]??0)+1:n<900?t[`5-15m`]=(t[`5-15m`]??0)+1:t[`>15m`]=(t[`>15m`]??0)+1;let n=Math.max(...Object.values(t));return n===0?`<p class="empty">No response time data</p>`:Object.entries(t).map(([e,t])=>`<div class="bar-row">
90
90
  <div class="bar-label">${e}</div>
91
91
  <div class="bar-track"><div class="bar-fill" style="width:${t/n*100}%;background:#6366f1"></div></div>
92
92
  <div class="bar-value">${t}</div>
93
93
  </div>`).join(`
94
- `)}function z(e){if(e.length===0)return`<p class="empty">No time data</p>`;let t=[{label:`Morning (6-12)`,range:[6,7,8,9,10,11]},{label:`Afternoon (12-18)`,range:[12,13,14,15,16,17]},{label:`Evening (18-24)`,range:[18,19,20,21,22,23]},{label:`Night (0-6)`,range:[0,1,2,3,4,5]}],n={};for(let t of e)n[t]=(n[t]||0)+1;let r=t.map(e=>({label:e.label,count:e.range.reduce((e,t)=>e+(n[t]||0),0)})),i=Math.max(...r.map(e=>e.count))||1;return`<div id="hour-histogram">${r.map(e=>`
94
+ `)}function ke(e){if(e.length===0)return`<p class="empty">No time data</p>`;let t=[{label:`Morning (6-12)`,range:[6,7,8,9,10,11]},{label:`Afternoon (12-18)`,range:[12,13,14,15,16,17]},{label:`Evening (18-24)`,range:[18,19,20,21,22,23]},{label:`Night (0-6)`,range:[0,1,2,3,4,5]}],n={};for(let t of e)n[t]=(n[t]||0)+1;let r=t.map(e=>({label:e.label,count:e.range.reduce((e,t)=>e+(n[t]||0),0)})),i=Math.max(...r.map(e=>e.count))||1;return`<div id="hour-histogram">${r.map(e=>`
95
95
  <div class="bar-row">
96
96
  <div class="bar-label">${e.label}</div>
97
97
  <div class="bar-track"><div class="bar-fill" style="width:${e.count/i*100}%;background:#8b5cf6"></div></div>
@@ -99,15 +99,15 @@ ${s.on_the_horizon?.opportunities?.map(e=>`- ${e.title}: ${e.whats_possible}`).j
99
99
  </div>`).join(`
100
100
  `)}</div>`}function Ae(e){let t={};for(let n of e)t[n]=(t[n]||0)+1;return c(t)}function je(e,t){let n=e=>e?e.split(`
101
101
 
102
- `).map(e=>{let t=w(e);return t=t.replace(/\*\*(.+?)\*\*/g,`<strong>$1</strong>`),t=t.replace(/^- /gm,`• `),t=t.replace(/\n/g,`<br>`),`<p>${t}</p>`}).join(`
102
+ `).map(e=>{let t=T(e);return t=t.replace(/\*\*(.+?)\*\*/g,`<strong>$1</strong>`),t=t.replace(/^- /gm,`• `),t=t.replace(/\n/g,`<br>`),`<p>${t}</p>`}).join(`
103
103
  `):``,r=t.at_a_glance,i=r?`
104
104
  <div class="at-a-glance">
105
105
  <div class="glance-title">At a Glance</div>
106
106
  <div class="glance-sections">
107
- ${r.whats_working?`<div class="glance-section"><strong>What's working:</strong> ${L(r.whats_working)} <a href="#section-wins" class="see-more">Impressive Things You Did →</a></div>`:``}
108
- ${r.whats_hindering?`<div class="glance-section"><strong>What's hindering you:</strong> ${L(r.whats_hindering)} <a href="#section-friction" class="see-more">Where Things Go Wrong →</a></div>`:``}
109
- ${r.quick_wins?`<div class="glance-section"><strong>Quick wins to try:</strong> ${L(r.quick_wins)} <a href="#section-features" class="see-more">Features to Try →</a></div>`:``}
110
- ${r.ambitious_workflows?`<div class="glance-section"><strong>Ambitious workflows:</strong> ${L(r.ambitious_workflows)} <a href="#section-horizon" class="see-more">On the Horizon →</a></div>`:``}
107
+ ${r.whats_working?`<div class="glance-section"><strong>What's working:</strong> ${R(r.whats_working)} <a href="#section-wins" class="see-more">Impressive Things You Did →</a></div>`:``}
108
+ ${r.whats_hindering?`<div class="glance-section"><strong>What's hindering you:</strong> ${R(r.whats_hindering)} <a href="#section-friction" class="see-more">Where Things Go Wrong →</a></div>`:``}
109
+ ${r.quick_wins?`<div class="glance-section"><strong>Quick wins to try:</strong> ${R(r.quick_wins)} <a href="#section-features" class="see-more">Features to Try →</a></div>`:``}
110
+ ${r.ambitious_workflows?`<div class="glance-section"><strong>Ambitious workflows:</strong> ${R(r.ambitious_workflows)} <a href="#section-horizon" class="see-more">On the Horizon →</a></div>`:``}
111
111
  </div>
112
112
  </div>
113
113
  `:``,a=t.project_areas?.areas||[],o=a.length>0?`
@@ -116,10 +116,10 @@ ${s.on_the_horizon?.opportunities?.map(e=>`- ${e.title}: ${e.whats_possible}`).j
116
116
  ${a.map(e=>`
117
117
  <div class="project-area">
118
118
  <div class="area-header">
119
- <span class="area-name">${w(e.name)}</span>
119
+ <span class="area-name">${T(e.name)}</span>
120
120
  <span class="area-count">~${e.session_count} sessions</span>
121
121
  </div>
122
- <div class="area-desc">${w(e.description)}</div>
122
+ <div class="area-desc">${T(e.description)}</div>
123
123
  </div>
124
124
  `).join(``)}
125
125
  </div>
@@ -127,28 +127,28 @@ ${s.on_the_horizon?.opportunities?.map(e=>`- ${e.title}: ${e.whats_possible}`).j
127
127
  <h2 id="section-usage">How You Use Claude Code</h2>
128
128
  <div class="narrative">
129
129
  ${n(s.narrative)}
130
- ${s.key_pattern?`<div class="key-insight"><strong>Key pattern:</strong> ${w(s.key_pattern)}</div>`:``}
130
+ ${s.key_pattern?`<div class="key-insight"><strong>Key pattern:</strong> ${T(s.key_pattern)}</div>`:``}
131
131
  </div>
132
132
  `:``,l=t.what_works,u=l?.impressive_workflows&&l.impressive_workflows.length>0?`
133
133
  <h2 id="section-wins">Impressive Things You Did</h2>
134
- ${l.intro?`<p class="section-intro">${w(l.intro)}</p>`:``}
134
+ ${l.intro?`<p class="section-intro">${T(l.intro)}</p>`:``}
135
135
  <div class="big-wins">
136
136
  ${l.impressive_workflows.map(e=>`
137
137
  <div class="big-win">
138
- <div class="big-win-title">${w(e.title||``)}</div>
139
- <div class="big-win-desc">${w(e.description||``)}</div>
138
+ <div class="big-win-title">${T(e.title||``)}</div>
139
+ <div class="big-win-desc">${T(e.description||``)}</div>
140
140
  </div>
141
141
  `).join(``)}
142
142
  </div>
143
143
  `:``,d=t.friction_analysis,f=d?.categories&&d.categories.length>0?`
144
144
  <h2 id="section-friction">Where Things Go Wrong</h2>
145
- ${d.intro?`<p class="section-intro">${w(d.intro)}</p>`:``}
145
+ ${d.intro?`<p class="section-intro">${T(d.intro)}</p>`:``}
146
146
  <div class="friction-categories">
147
147
  ${d.categories.map(e=>`
148
148
  <div class="friction-category">
149
- <div class="friction-title">${w(e.category||``)}</div>
150
- <div class="friction-desc">${w(e.description||``)}</div>
151
- ${e.examples?`<ul class="friction-examples">${e.examples.map(e=>`<li>${w(e)}</li>`).join(``)}</ul>`:``}
149
+ <div class="friction-title">${T(e.category||``)}</div>
150
+ <div class="friction-desc">${T(e.description||``)}</div>
151
+ ${e.examples?`<ul class="friction-examples">${e.examples.map(e=>`<li>${T(e)}</li>`).join(``)}</ul>`:``}
152
152
  </div>
153
153
  `).join(``)}
154
154
  </div>
@@ -163,12 +163,12 @@ ${s.on_the_horizon?.opportunities?.map(e=>`- ${e.title}: ${e.whats_possible}`).j
163
163
  </div>
164
164
  ${p.claude_md_additions.map((e,t)=>`
165
165
  <div class="claude-md-item">
166
- <input type="checkbox" id="cmd-${t}" class="cmd-checkbox" checked data-text="${w(e.prompt_scaffold||e.where||`Add to CLAUDE.md`)}\\n\\n${w(e.addition)}">
166
+ <input type="checkbox" id="cmd-${t}" class="cmd-checkbox" checked data-text="${T(e.prompt_scaffold||e.where||`Add to CLAUDE.md`)}\\n\\n${T(e.addition)}">
167
167
  <label for="cmd-${t}">
168
- <code class="cmd-code">${w(e.addition)}</code>
168
+ <code class="cmd-code">${T(e.addition)}</code>
169
169
  <button class="copy-btn" onclick="copyCmdItem(${t})">Copy</button>
170
170
  </label>
171
- <div class="cmd-why">${w(e.why)}</div>
171
+ <div class="cmd-why">${T(e.why)}</div>
172
172
  </div>
173
173
  `).join(``)}
174
174
  </div>
@@ -178,14 +178,14 @@ ${s.on_the_horizon?.opportunities?.map(e=>`- ${e.title}: ${e.whats_possible}`).j
178
178
  <div class="features-section">
179
179
  ${p.features_to_try.map(e=>`
180
180
  <div class="feature-card">
181
- <div class="feature-title">${w(e.feature||``)}</div>
182
- <div class="feature-oneliner">${w(e.one_liner||``)}</div>
183
- <div class="feature-why"><strong>Why for you:</strong> ${w(e.why_for_you||``)}</div>
181
+ <div class="feature-title">${T(e.feature||``)}</div>
182
+ <div class="feature-oneliner">${T(e.one_liner||``)}</div>
183
+ <div class="feature-why"><strong>Why for you:</strong> ${T(e.why_for_you||``)}</div>
184
184
  ${e.example_code?`
185
185
  <div class="feature-examples">
186
186
  <div class="feature-example">
187
187
  <div class="example-code-row">
188
- <code class="example-code">${w(e.example_code)}</code>
188
+ <code class="example-code">${T(e.example_code)}</code>
189
189
  <button class="copy-btn" onclick="copyText(this)">Copy</button>
190
190
  </div>
191
191
  </div>
@@ -201,14 +201,14 @@ ${s.on_the_horizon?.opportunities?.map(e=>`- ${e.title}: ${e.whats_possible}`).j
201
201
  <div class="patterns-section">
202
202
  ${p.usage_patterns.map(e=>`
203
203
  <div class="pattern-card">
204
- <div class="pattern-title">${w(e.title||``)}</div>
205
- <div class="pattern-summary">${w(e.suggestion||``)}</div>
206
- ${e.detail?`<div class="pattern-detail">${w(e.detail)}</div>`:``}
204
+ <div class="pattern-title">${T(e.title||``)}</div>
205
+ <div class="pattern-summary">${T(e.suggestion||``)}</div>
206
+ ${e.detail?`<div class="pattern-detail">${T(e.detail)}</div>`:``}
207
207
  ${e.copyable_prompt?`
208
208
  <div class="copyable-prompt-section">
209
209
  <div class="prompt-label">Paste into Claude Code:</div>
210
210
  <div class="copyable-prompt-row">
211
- <code class="copyable-prompt">${w(e.copyable_prompt)}</code>
211
+ <code class="copyable-prompt">${T(e.copyable_prompt)}</code>
212
212
  <button class="copy-btn" onclick="copyText(this)">Copy</button>
213
213
  </div>
214
214
  </div>
@@ -219,14 +219,14 @@ ${s.on_the_horizon?.opportunities?.map(e=>`- ${e.title}: ${e.whats_possible}`).j
219
219
  `:``}
220
220
  `:``,h=t.on_the_horizon,g=h?.opportunities&&h.opportunities.length>0?`
221
221
  <h2 id="section-horizon">On the Horizon</h2>
222
- ${h.intro?`<p class="section-intro">${w(h.intro)}</p>`:``}
222
+ ${h.intro?`<p class="section-intro">${T(h.intro)}</p>`:``}
223
223
  <div class="horizon-section">
224
224
  ${h.opportunities.map(e=>`
225
225
  <div class="horizon-card">
226
- <div class="horizon-title">${w(e.title||``)}</div>
227
- <div class="horizon-possible">${w(e.whats_possible||``)}</div>
228
- ${e.how_to_try?`<div class="horizon-tip"><strong>Getting started:</strong> ${w(e.how_to_try)}</div>`:``}
229
- ${e.copyable_prompt?`<div class="pattern-prompt"><div class="prompt-label">Paste into Claude Code:</div><code>${w(e.copyable_prompt)}</code><button class="copy-btn" onclick="copyText(this)">Copy</button></div>`:``}
226
+ <div class="horizon-title">${T(e.title||``)}</div>
227
+ <div class="horizon-possible">${T(e.whats_possible||``)}</div>
228
+ ${e.how_to_try?`<div class="horizon-tip"><strong>Getting started:</strong> ${T(e.how_to_try)}</div>`:``}
229
+ ${e.copyable_prompt?`<div class="pattern-prompt"><div class="prompt-label">Paste into Claude Code:</div><code>${T(e.copyable_prompt)}</code><button class="copy-btn" onclick="copyText(this)">Copy</button></div>`:``}
230
230
  </div>
231
231
  `).join(``)}
232
232
  </div>
@@ -243,9 +243,9 @@ ${s.on_the_horizon?.opportunities?.map(e=>`- ${e.title}: ${e.whats_possible}`).j
243
243
  <div class="suggestions-section">
244
244
  ${_.map(e=>`
245
245
  <div class="feedback-card team-card">
246
- <div class="feedback-title">${w(e.title||``)}</div>
247
- <div class="feedback-detail">${w(e.detail||``)}</div>
248
- ${e.evidence?`<div class="feedback-evidence"><em>Evidence:</em> ${w(e.evidence)}</div>`:``}
246
+ <div class="feedback-title">${T(e.title||``)}</div>
247
+ <div class="feedback-detail">${T(e.detail||``)}</div>
248
+ ${e.evidence?`<div class="feedback-evidence"><em>Evidence:</em> ${T(e.evidence)}</div>`:``}
249
249
  </div>
250
250
  `).join(``)}
251
251
  </div>
@@ -262,9 +262,9 @@ ${s.on_the_horizon?.opportunities?.map(e=>`- ${e.title}: ${e.whats_possible}`).j
262
262
  <div class="suggestions-section">
263
263
  ${v.map(e=>`
264
264
  <div class="feedback-card model-card">
265
- <div class="feedback-title">${w(e.title||``)}</div>
266
- <div class="feedback-detail">${w(e.detail||``)}</div>
267
- ${e.evidence?`<div class="feedback-evidence"><em>Evidence:</em> ${w(e.evidence)}</div>`:``}
265
+ <div class="feedback-title">${T(e.title||``)}</div>
266
+ <div class="feedback-detail">${T(e.detail||``)}</div>
267
+ ${e.evidence?`<div class="feedback-evidence"><em>Evidence:</em> ${T(e.evidence)}</div>`:``}
268
268
  </div>
269
269
  `).join(``)}
270
270
  </div>
@@ -273,8 +273,8 @@ ${s.on_the_horizon?.opportunities?.map(e=>`- ${e.title}: ${e.whats_possible}`).j
273
273
  `:``}
274
274
  `:``,b=t.fun_ending,x=b?.headline?`
275
275
  <div class="fun-ending">
276
- <div class="fun-headline">"${w(b.headline)}"</div>
277
- ${b.detail?`<div class="fun-detail">${w(b.detail)}</div>`:``}
276
+ <div class="fun-headline">"${T(b.headline)}"</div>
277
+ ${b.detail?`<div class="fun-detail">${T(b.detail)}</div>`:``}
278
278
  </div>
279
279
  `:``,S=`
280
280
  function toggleCollapsible(header) {
@@ -521,22 +521,22 @@ ${s.on_the_horizon?.opportunities?.map(e=>`- ${e.title}: ${e.whats_possible}`).j
521
521
  <div class="charts-row">
522
522
  <div class="chart-card">
523
523
  <div class="chart-title">What You Wanted</div>
524
- ${R(e.goal_categories,`#2563eb`)}
524
+ ${z(e.goal_categories,`#2563eb`)}
525
525
  </div>
526
526
  <div class="chart-card">
527
527
  <div class="chart-title">Top Tools Used</div>
528
- ${R(e.tool_counts,`#0891b2`)}
528
+ ${z(e.tool_counts,`#0891b2`)}
529
529
  </div>
530
530
  </div>
531
531
 
532
532
  <div class="charts-row">
533
533
  <div class="chart-card">
534
534
  <div class="chart-title">Languages</div>
535
- ${R(e.languages,`#10b981`)}
535
+ ${z(e.languages,`#10b981`)}
536
536
  </div>
537
537
  <div class="chart-card">
538
538
  <div class="chart-title">Session Types</div>
539
- ${R(e.session_types||{},`#8b5cf6`)}
539
+ ${z(e.session_types||{},`#8b5cf6`)}
540
540
  </div>
541
541
  </div>
542
542
 
@@ -545,7 +545,7 @@ ${s.on_the_horizon?.opportunities?.map(e=>`- ${e.title}: ${e.whats_possible}`).j
545
545
  <!-- Response Time Distribution -->
546
546
  <div class="chart-card" style="margin: 24px 0;">
547
547
  <div class="chart-title">User Response Time Distribution</div>
548
- ${ke(e.user_response_times)}
548
+ ${Oe(e.user_response_times)}
549
549
  <div style="font-size: 12px; color: #64748b; margin-top: 8px;">
550
550
  Median: ${e.median_response_time.toFixed(1)}s &bull; Average: ${e.avg_response_time.toFixed(1)}s
551
551
  </div>
@@ -595,11 +595,11 @@ ${s.on_the_horizon?.opportunities?.map(e=>`- ${e.title}: ${e.whats_possible}`).j
595
595
  </select>
596
596
  <input type="number" id="custom-offset" placeholder="UTC offset" style="display: none; width: 80px; font-size: 12px; padding: 4px; border-radius: 4px; border: 1px solid #e2e8f0;">
597
597
  </div>
598
- ${z(e.message_hours)}
598
+ ${ke(e.message_hours)}
599
599
  </div>
600
600
  <div class="chart-card">
601
601
  <div class="chart-title">Tool Errors Encountered</div>
602
- ${Object.keys(e.tool_error_categories).length>0?R(e.tool_error_categories,`#dc2626`):`<p class="empty">No tool errors</p>`}
602
+ ${Object.keys(e.tool_error_categories).length>0?z(e.tool_error_categories,`#dc2626`):`<p class="empty">No tool errors</p>`}
603
603
  </div>
604
604
  </div>
605
605
 
@@ -608,11 +608,11 @@ ${s.on_the_horizon?.opportunities?.map(e=>`- ${e.title}: ${e.whats_possible}`).j
608
608
  <div class="charts-row">
609
609
  <div class="chart-card">
610
610
  <div class="chart-title">What Helped Most (Claude's Capabilities)</div>
611
- ${R(e.success,`#16a34a`)}
611
+ ${z(e.success,`#16a34a`)}
612
612
  </div>
613
613
  <div class="chart-card">
614
614
  <div class="chart-title">Outcomes</div>
615
- ${R(e.outcomes,`#8b5cf6`,6,Q)}
615
+ ${z(e.outcomes,`#8b5cf6`,6,Q)}
616
616
  </div>
617
617
  </div>
618
618
 
@@ -621,11 +621,11 @@ ${s.on_the_horizon?.opportunities?.map(e=>`- ${e.title}: ${e.whats_possible}`).j
621
621
  <div class="charts-row">
622
622
  <div class="chart-card">
623
623
  <div class="chart-title">Primary Friction Types</div>
624
- ${R(e.friction,`#dc2626`)}
624
+ ${z(e.friction,`#dc2626`)}
625
625
  </div>
626
626
  <div class="chart-card">
627
627
  <div class="chart-title">Inferred Satisfaction (model-estimated)</div>
628
- ${R(e.satisfaction,`#eab308`,6,Z)}
628
+ ${z(e.satisfaction,`#eab308`,6,Z)}
629
629
  </div>
630
630
  </div>
631
631
 
@@ -639,7 +639,7 @@ ${s.on_the_horizon?.opportunities?.map(e=>`- ${e.title}: ${e.whats_possible}`).j
639
639
  </div>
640
640
  <script>${S}<\/script>
641
641
  </body>
642
- </html>`}async function Me(){let e=re(),t;try{t=await k(e,{withFileTypes:!0})}catch{return[]}let n=t.filter(e=>e.isDirectory()).map(t=>E(e,t.name)),r=[];for(let e=0;e<n.length;e++){let t=await y(n[e]);for(let[e,n]of t)r.push({sessionId:e,path:n.path,mtime:n.mtime,size:n.size});e%10==9&&await new Promise(e=>setImmediate(e))}return r.sort((e,t)=>t.mtime-e.mtime),r}async function Ne(e){let n;if(process.env.USER_TYPE===`ant`&&e?.collectRemote){let{hosts:e,totalCopied:r}=await G(E(t(),`projects`));n={hosts:e,totalCopied:r}}let r=await Me(),i=r.length,a=[],o=[];for(let e=0;e<r.length;e+=50){let t=r.slice(e,e+50),n=await Promise.all(t.map(async e=>({sessionInfo:e,cached:await Ce(e.sessionId)})));for(let{sessionInfo:e,cached:t}of n)t?a.push(t):o.length<200&&o.push(e)}let s=new Map,c=e=>{for(let t of e.messages.slice(0,5))if(t.type===`user`&&t.message){let e=t.message.content;if(typeof e==`string`&&(e.includes(`RESPOND WITH ONLY A VALID JSON OBJECT`)||e.includes(`record_facets`)))return!0}return!1};for(let e=0;e<o.length;e+=10){let t=o.slice(e,e+10),n=await Promise.all(t.map(async e=>{try{return await ie(e.path)}catch{return[]}})),r=[];for(let e of n)for(let t of e){if(c(t)||!_e(t))continue;let e=F(t);a.push(e),r.push(e),s.set(e.session_id,t)}await Promise.all(r.map(e=>we(e)))}let l=new Map;for(let e of a){let t=l.get(e.session_id);(!t||e.user_message_count>t.user_message_count||e.user_message_count===t.user_message_count&&e.duration_minutes>t.duration_minutes)&&l.set(e.session_id,e)}let u=new Set(l.keys());a=[...l.values()];for(let e of s.keys())u.has(e)||s.delete(e);a.sort((e,t)=>t.start_time.localeCompare(e.start_time));let d=a.filter(e=>!(e.user_message_count<2||e.duration_minutes<1)),f=new Map,p=[],m=await Promise.all(d.map(async e=>({sessionId:e.session_id,cached:await xe(e.session_id)})));for(let{sessionId:e,cached:t}of m)if(t)f.set(e,t);else{let t=s.get(e);t&&p.length<50&&p.push({log:t,sessionId:e})}for(let e=0;e<p.length;e+=50){let t=p.slice(e,e+50),n=await Promise.all(t.map(async({log:e,sessionId:t})=>({sessionId:t,newFacets:await Te(e,t)}))),r=[];for(let{sessionId:e,newFacets:t}of n)t&&(f.set(e,t),r.push(t));await Promise.all(r.map(e=>Se(e)))}let h=e=>{let t=f.get(e);if(!t)return!1;let n=t.goal_categories,r=Pe(n).filter(e=>(n[e]??0)>0);return r.length===1&&r[0]===`warmup_minimal`},g=d.filter(e=>!h(e.session_id)),_=new Map;for(let[e,t]of f)h(e)||_.set(e,t);let v=De(g,_);v.total_sessions_scanned=i;let y=await Oe(v,f),b=je(v,y);try{await D(M(),{recursive:!0})}catch{}let x=E(M(),`report.html`);return await A(x,b,{encoding:`utf-8`,mode:384}),{insights:y,htmlPath:x,data:v,remoteStats:n,facets:_}}function B(e){return e?Object.entries(e):[]}function Pe(e){return e?Object.keys(e):[]}function V(e){if(!e||typeof e!=`object`)return!1;let t=e;return typeof t.underlying_goal==`string`&&typeof t.outcome==`string`&&typeof t.brief_summary==`string`&&t.goal_categories!==null&&typeof t.goal_categories==`object`&&t.user_satisfaction_counts!==null&&typeof t.user_satisfaction_counts==`object`&&t.friction_counts!==null&&typeof t.friction_counts==`object`}var H,U,W,G,K,q,J,Y,X,Z,Q,$;e((()=>{S(),te(),s(),n(),d(),h(),p(),x(),i(),_(),f(),o(),b(),ae(),H=process.env.USER_TYPE===`ant`?async()=>{let{stdout:e,code:t}=await g(`coder`,[`list`,`-o`,`json`],{timeout:3e4});if(t!==0)return[];try{return u(e).filter(e=>e.latest_build?.status===`running`).map(e=>e.name)}catch{return[]}}:async()=>[],U=process.env.USER_TYPE===`ant`?async e=>{let{stdout:t,code:n}=await g(`ssh`,[`${e}.coder`,`find /root/.claude/projects -name "*.jsonl" 2>/dev/null | wc -l`],{timeout:3e4});return n===0&&parseInt(t.trim(),10)||0}:async()=>0,W=process.env.USER_TYPE===`ant`?async(e,t)=>{let n={copied:0,skipped:0},r=await ue(E(oe(),`claude-hs-`));try{if((await g(`scp`,[`-rq`,`${e}.coder:/root/.claude/projects/`,r],{timeout:3e5})).code!==0)return n;let i=E(r,`projects`),a;try{a=await k(i,{withFileTypes:!0})}catch{return n}await Promise.all(a.map(async r=>{let a=r.name,o=E(i,a);if(!r.isDirectory())return;let s=E(t,`${a}__${e}`);try{await D(s,{recursive:!0})}catch{}let c;try{c=await k(o,{withFileTypes:!0})}catch{return}await Promise.all(c.map(async e=>{let t=e.name;if(!t.endsWith(`.jsonl`))return;let r=E(o,t),i=E(s,t);try{await le(r,i,ce.COPYFILE_EXCL),n.copied++}catch{n.skipped++}}))}))}finally{try{await de(r,{recursive:!0,force:!0})}catch{}}return n}:async()=>({copied:0,skipped:0}),G=process.env.USER_TYPE===`ant`?async e=>{let t=await H(),n=[],r=0,i=0,a=await Promise.all(t.map(async t=>{let n=await U(t);if(n>0){let{copied:r,skipped:i}=await W(t,e);return{name:t,sessionCount:n,copied:r,skipped:i}}return{name:t,sessionCount:n,copied:0,skipped:0}}));for(let e of a)n.push({name:e.name,sessionCount:e.sessionCount}),r+=e.copied,i+=e.skipped;return{hosts:n,totalCopied:r,totalSkipped:i}}:async()=>({hosts:[],totalCopied:0,totalSkipped:0}),K={".ts":`TypeScript`,".tsx":`TypeScript`,".js":`JavaScript`,".jsx":`JavaScript`,".py":`Python`,".rb":`Ruby`,".go":`Go`,".rs":`Rust`,".java":`Java`,".md":`Markdown`,".json":`JSON`,".yaml":`YAML`,".yml":`YAML`,".sh":`Shell`,".css":`CSS`,".html":`HTML`},q={debug_investigate:`Debug/Investigate`,implement_feature:`Implement Feature`,fix_bug:`Fix Bug`,write_script_tool:`Write Script/Tool`,refactor_code:`Refactor Code`,configure_system:`Configure System`,create_pr_commit:`Create PR/Commit`,analyze_data:`Analyze Data`,understand_codebase:`Understand Codebase`,write_tests:`Write Tests`,write_docs:`Write Docs`,deploy_infra:`Deploy/Infra`,warmup_minimal:`Cache Warmup`,fast_accurate_search:`Fast/Accurate Search`,correct_code_edits:`Correct Code Edits`,good_explanations:`Good Explanations`,proactive_help:`Proactive Help`,multi_file_changes:`Multi-file Changes`,handled_complexity:`Multi-file Changes`,good_debugging:`Good Debugging`,misunderstood_request:`Misunderstood Request`,wrong_approach:`Wrong Approach`,buggy_code:`Buggy Code`,user_rejected_action:`User Rejected Action`,claude_got_blocked:`Claude Got Blocked`,user_stopped_early:`User Stopped Early`,wrong_file_or_location:`Wrong File/Location`,excessive_changes:`Excessive Changes`,slow_or_verbose:`Slow/Verbose`,tool_failed:`Tool Failed`,user_unclear:`User Unclear`,external_issue:`External Issue`,frustrated:`Frustrated`,dissatisfied:`Dissatisfied`,likely_satisfied:`Likely Satisfied`,satisfied:`Satisfied`,happy:`Happy`,unsure:`Unsure`,neutral:`Neutral`,delighted:`Delighted`,single_task:`Single Task`,multi_task:`Multi Task`,iterative_refinement:`Iterative Refinement`,exploration:`Exploration`,quick_question:`Quick Question`,fully_achieved:`Fully Achieved`,mostly_achieved:`Mostly Achieved`,partially_achieved:`Partially Achieved`,not_achieved:`Not Achieved`,unclear_from_transcript:`Unclear`,unhelpful:`Unhelpful`,slightly_helpful:`Slightly Helpful`,moderately_helpful:`Moderately Helpful`,very_helpful:`Very Helpful`,essential:`Essential`},J=`Analyze this Claude Code session and extract structured facets.
642
+ </html>`}async function Me(){let e=S(),t;try{t=await A(e,{withFileTypes:!0})}catch{return[]}let n=t.filter(e=>e.isDirectory()).map(t=>D(e,t.name)),r=[];for(let e=0;e<n.length;e++){let t=await v(n[e]);for(let[e,n]of t)r.push({sessionId:e,path:n.path,mtime:n.mtime,size:n.size});e%10==9&&await new Promise(e=>setImmediate(e))}return r.sort((e,t)=>t.mtime-e.mtime),r}async function Ne(e){let n;if(process.env.USER_TYPE===`ant`&&e?.collectRemote){let{hosts:e,totalCopied:r}=await G(D(t(),`projects`));n={hosts:e,totalCopied:r}}let r=await Me(),i=r.length,a=[],o=[];for(let e=0;e<r.length;e+=50){let t=r.slice(e,e+50),n=await Promise.all(t.map(async e=>({sessionInfo:e,cached:await Se(e.sessionId)})));for(let{sessionInfo:e,cached:t}of n)t?a.push(t):o.length<200&&o.push(e)}let s=new Map,c=e=>{for(let t of e.messages.slice(0,5))if(t.type===`user`&&t.message){let e=t.message.content;if(typeof e==`string`&&(e.includes(`RESPOND WITH ONLY A VALID JSON OBJECT`)||e.includes(`record_facets`)))return!0}return!1};for(let e=0;e<o.length;e+=10){let t=o.slice(e,e+10),n=await Promise.all(t.map(async e=>{try{return await C(e.path)}catch{return[]}})),r=[];for(let e of n)for(let t of e){if(c(t)||!ge(t))continue;let e=I(t);a.push(e),r.push(e),s.set(e.session_id,t)}await Promise.all(r.map(e=>Ce(e)))}let l=new Map;for(let e of a){let t=l.get(e.session_id);(!t||e.user_message_count>t.user_message_count||e.user_message_count===t.user_message_count&&e.duration_minutes>t.duration_minutes)&&l.set(e.session_id,e)}let u=new Set(l.keys());a=[...l.values()];for(let e of s.keys())u.has(e)||s.delete(e);a.sort((e,t)=>t.start_time.localeCompare(e.start_time));let d=a.filter(e=>!(e.user_message_count<2||e.duration_minutes<1)),f=new Map,p=[],m=await Promise.all(d.map(async e=>({sessionId:e.session_id,cached:await be(e.session_id)})));for(let{sessionId:e,cached:t}of m)if(t)f.set(e,t);else{let t=s.get(e);t&&p.length<50&&p.push({log:t,sessionId:e})}for(let e=0;e<p.length;e+=50){let t=p.slice(e,e+50),n=await Promise.all(t.map(async({log:e,sessionId:t})=>({sessionId:t,newFacets:await we(e,t)}))),r=[];for(let{sessionId:e,newFacets:t}of n)t&&(f.set(e,t),r.push(t));await Promise.all(r.map(e=>xe(e)))}let h=e=>{let t=f.get(e);if(!t)return!1;let n=t.goal_categories,r=Pe(n).filter(e=>(n[e]??0)>0);return r.length===1&&r[0]===`warmup_minimal`},g=d.filter(e=>!h(e.session_id)),_=new Map;for(let[e,t]of f)h(e)||_.set(e,t);let v=Ee(g,_);v.total_sessions_scanned=i;let y=await De(v,f),b=je(v,y);try{await O(N(),{recursive:!0})}catch{}let x=D(N(),`report.html`);return await j(x,b,{encoding:`utf-8`,mode:384}),{insights:y,htmlPath:x,data:v,remoteStats:n,facets:_}}function B(e){return e?Object.entries(e):[]}function Pe(e){return e?Object.keys(e):[]}function V(e){if(!e||typeof e!=`object`)return!1;let t=e;return typeof t.underlying_goal==`string`&&typeof t.outcome==`string`&&typeof t.brief_summary==`string`&&t.goal_categories!==null&&typeof t.goal_categories==`object`&&t.user_satisfaction_counts!==null&&typeof t.user_satisfaction_counts==`object`&&t.friction_counts!==null&&typeof t.friction_counts==`object`}var H,U,W,G,K,q,J,Y,X,Z,Q,$;e((()=>{ne(),re(),s(),n(),d(),h(),p(),te(),i(),x(),f(),o(),ee(),ie(),H=process.env.USER_TYPE===`ant`?async()=>{let{stdout:e,code:t}=await g(`coder`,[`list`,`-o`,`json`],{timeout:3e4});if(t!==0)return[];try{return u(e).filter(e=>e.latest_build?.status===`running`).map(e=>e.name)}catch{return[]}}:async()=>[],U=process.env.USER_TYPE===`ant`?async e=>{let{stdout:t,code:n}=await g(`ssh`,[`${e}.coder`,`find /root/.claude/projects -name "*.jsonl" 2>/dev/null | wc -l`],{timeout:3e4});return n===0&&parseInt(t.trim(),10)||0}:async()=>0,W=process.env.USER_TYPE===`ant`?async(e,t)=>{let n={copied:0,skipped:0},r=await le(D(ae(),`claude-hs-`));try{if((await g(`scp`,[`-rq`,`${e}.coder:/root/.claude/projects/`,r],{timeout:3e5})).code!==0)return n;let i=D(r,`projects`),a;try{a=await A(i,{withFileTypes:!0})}catch{return n}await Promise.all(a.map(async r=>{let a=r.name,o=D(i,a);if(!r.isDirectory())return;let s=D(t,`${a}__${e}`);try{await O(s,{recursive:!0})}catch{}let c;try{c=await A(o,{withFileTypes:!0})}catch{return}await Promise.all(c.map(async e=>{let t=e.name;if(!t.endsWith(`.jsonl`))return;let r=D(o,t),i=D(s,t);try{await ce(r,i,se.COPYFILE_EXCL),n.copied++}catch{n.skipped++}}))}))}finally{try{await ue(r,{recursive:!0,force:!0})}catch{}}return n}:async()=>({copied:0,skipped:0}),G=process.env.USER_TYPE===`ant`?async e=>{let t=await H(),n=[],r=0,i=0,a=await Promise.all(t.map(async t=>{let n=await U(t);if(n>0){let{copied:r,skipped:i}=await W(t,e);return{name:t,sessionCount:n,copied:r,skipped:i}}return{name:t,sessionCount:n,copied:0,skipped:0}}));for(let e of a)n.push({name:e.name,sessionCount:e.sessionCount}),r+=e.copied,i+=e.skipped;return{hosts:n,totalCopied:r,totalSkipped:i}}:async()=>({hosts:[],totalCopied:0,totalSkipped:0}),K={".ts":`TypeScript`,".tsx":`TypeScript`,".js":`JavaScript`,".jsx":`JavaScript`,".py":`Python`,".rb":`Ruby`,".go":`Go`,".rs":`Rust`,".java":`Java`,".md":`Markdown`,".json":`JSON`,".yaml":`YAML`,".yml":`YAML`,".sh":`Shell`,".css":`CSS`,".html":`HTML`},q={debug_investigate:`Debug/Investigate`,implement_feature:`Implement Feature`,fix_bug:`Fix Bug`,write_script_tool:`Write Script/Tool`,refactor_code:`Refactor Code`,configure_system:`Configure System`,create_pr_commit:`Create PR/Commit`,analyze_data:`Analyze Data`,understand_codebase:`Understand Codebase`,write_tests:`Write Tests`,write_docs:`Write Docs`,deploy_infra:`Deploy/Infra`,warmup_minimal:`Cache Warmup`,fast_accurate_search:`Fast/Accurate Search`,correct_code_edits:`Correct Code Edits`,good_explanations:`Good Explanations`,proactive_help:`Proactive Help`,multi_file_changes:`Multi-file Changes`,handled_complexity:`Multi-file Changes`,good_debugging:`Good Debugging`,misunderstood_request:`Misunderstood Request`,wrong_approach:`Wrong Approach`,buggy_code:`Buggy Code`,user_rejected_action:`User Rejected Action`,claude_got_blocked:`Claude Got Blocked`,user_stopped_early:`User Stopped Early`,wrong_file_or_location:`Wrong File/Location`,excessive_changes:`Excessive Changes`,slow_or_verbose:`Slow/Verbose`,tool_failed:`Tool Failed`,user_unclear:`User Unclear`,external_issue:`External Issue`,frustrated:`Frustrated`,dissatisfied:`Dissatisfied`,likely_satisfied:`Likely Satisfied`,satisfied:`Satisfied`,happy:`Happy`,unsure:`Unsure`,neutral:`Neutral`,delighted:`Delighted`,single_task:`Single Task`,multi_task:`Multi Task`,iterative_refinement:`Iterative Refinement`,exploration:`Exploration`,quick_question:`Quick Question`,fully_achieved:`Fully Achieved`,mostly_achieved:`Mostly Achieved`,partially_achieved:`Partially Achieved`,not_achieved:`Not Achieved`,unclear_from_transcript:`Unclear`,unhelpful:`Unhelpful`,slightly_helpful:`Slightly Helpful`,moderately_helpful:`Moderately Helpful`,very_helpful:`Very Helpful`,essential:`Essential`},J=`Analyze this Claude Code session and extract structured facets.
643
643
 
644
644
  CRITICAL GUIDELINES:
645
645
 
@@ -783,7 +783,7 @@ RESPOND WITH ONLY A VALID JSON OBJECT:
783
783
  "detail": "Brief context about when/where this happened"
784
784
  }
785
785
 
786
- Find something genuinely interesting or amusing from the session summaries.`,maxTokens:8192}],Z=[`frustrated`,`dissatisfied`,`likely_satisfied`,`satisfied`,`happy`,`unsure`],Q=[`not_achieved`,`partially_achieved`,`mostly_achieved`,`fully_achieved`,`unclear_from_transcript`],$={type:`prompt`,name:`insights`,description:`Generate a report analyzing your Claude Code sessions`,contentLength:0,progressMessage:`analyzing your sessions`,source:`builtin`,async getPromptForCommand(e){let t=!1,n=[],r=!1;process.env.USER_TYPE===`ant`&&(t=e?.includes(`--homespaces`)??!1,n=await H(),r=n.length>0,t&&r&&console.error(`Collecting sessions from ${n.length} homespace(s): ${n.join(`, `)}...`));let{insights:i,htmlPath:a,data:o,remoteStats:s}=await Ne({collectRemote:t}),l=`file://${a}`,u=``;if(process.env.USER_TYPE===`ant`){let e=new Date().toISOString().replace(/[-:]/g,``).replace(`T`,`_`).slice(0,15),t=`${process.env.SAFEUSER||process.env.USER||`unknown`}_insights_${e}.html`,n=`s3://anthropic-serve/atamkin/cc-user-reports/${t}`,r=`https://s3-frontend.infra.ant.dev/anthropic-serve/atamkin/cc-user-reports/${t}`;l=r;try{pe(`ff`,[`cp`,a,n],{timeout:6e4,stdio:`pipe`})}catch{l=`file://${a}`,u=`\nAutomatic upload failed. Are you on the boron namespace? Try \`use-bo\` and ensure you've run \`sso\`.
786
+ Find something genuinely interesting or amusing from the session summaries.`,maxTokens:8192}],Z=[`frustrated`,`dissatisfied`,`likely_satisfied`,`satisfied`,`happy`,`unsure`],Q=[`not_achieved`,`partially_achieved`,`mostly_achieved`,`fully_achieved`,`unclear_from_transcript`],$={type:`prompt`,name:`insights`,description:`Generate a report analyzing your Claude Code sessions`,contentLength:0,progressMessage:`analyzing your sessions`,source:`builtin`,async getPromptForCommand(e){let t=!1,n=[],r=!1;process.env.USER_TYPE===`ant`&&(t=e?.includes(`--homespaces`)??!1,n=await H(),r=n.length>0,t&&r&&console.error(`Collecting sessions from ${n.length} homespace(s): ${n.join(`, `)}...`));let{insights:i,htmlPath:a,data:o,remoteStats:s}=await Ne({collectRemote:t}),l=`file://${a}`,u=``;if(process.env.USER_TYPE===`ant`){let e=new Date().toISOString().replace(/[-:]/g,``).replace(`T`,`_`).slice(0,15),t=`${process.env.SAFEUSER||process.env.USER||`unknown`}_insights_${e}.html`,n=`s3://anthropic-serve/atamkin/cc-user-reports/${t}`,r=`https://s3-frontend.infra.ant.dev/anthropic-serve/atamkin/cc-user-reports/${t}`;l=r;try{fe(`ff`,[`cp`,a,n],{timeout:6e4,stdio:`pipe`})}catch{l=`file://${a}`,u=`\nAutomatic upload failed. Are you on the boron namespace? Try \`use-bo\` and ensure you've run \`sso\`.
787
787
  To share, run: ff cp ${a} ${n}
788
788
  Then access at: ${r}`}}let d=[o.total_sessions_scanned&&o.total_sessions_scanned>o.total_sessions?`${o.total_sessions_scanned.toLocaleString()} sessions total · ${o.total_sessions} analyzed`:`${o.total_sessions} sessions`,`${o.total_messages.toLocaleString()} messages`,`${Math.round(o.total_duration_hours)}h`,`${o.git_commits} commits`].join(` · `),f=``;if(process.env.USER_TYPE===`ant`)if(s&&s.totalCopied>0){let e=s.hosts.filter(e=>e.sessionCount>0).map(e=>e.name).join(`, `);f=`\n_Collected ${s.totalCopied} new sessions from: ${e}_\n`}else !t&&r&&(f=`\n_Tip: Run \`/insights --homespaces\` to include sessions from your ${n.length} running homespace(s)_\n`);let p=i.at_a_glance,m=p?`## At a Glance
789
789
 
@@ -807,7 +807,7 @@ ${c(i,null,2)}
807
807
 
808
808
  Report URL: ${l}
809
809
  HTML file: ${a}
810
- Facets directory: ${N()}
810
+ Facets directory: ${P()}
811
811
 
812
812
  Here is what the user sees:
813
813
  ${h}
@@ -1,4 +1,4 @@
1
- import{n as e,o as t}from"./chunk-DR8-3Aex.js";import{n,t as r}from"./figures-gfT9mM8P.js";import{F as i,Q as a,Rn as o,T as s,b as c,f as l,g as u,h as d,nt as f,t as p,tn as m,tt as h,v as g,x as _}from"./src-Di342QoJ.js";import{t as v}from"./jsx-runtime-D-D469L8.js";import{Ac as y,Mn as b,Pc as x,Po as ee,Vt as te,cn as S,jo as C,on as w}from"./paths-D9CVAtXU.js";import{n as T,r as E}from"./analytics-DqMQntaB.js";import{l as ne,v as re}from"./git-CN3qtTb_.js";import{r as ie,t as ae}from"./execa-CGue6Z3n.js";import{o as oe,s as D}from"./log-CzsijfHZ.js";import{r as se,t as O}from"./execFileNoThrow-CuQN1sz8.js";import{Bx as k,Nx as ce,OT as le,Sy as ue,Uw as A,by as j,eC as de,gy as fe,hy as pe,kT as me,my as he,tC as ge,zx as M}from"./loadAgentsDir-D-xcJ22-.js";import{n as _e,t as ve}from"./browser-fLRXxIsQ.js";import{t as N}from"./useKeybinding-FsOnjW6T.js";import{l as ye,u as be}from"./referral-D26orIXE.js";function xe(e){return e.pending?(0,F.jsxs)(c,{children:[`Press `,e.keyName,` again to exit`]}):(0,F.jsxs)(d,{children:[(0,F.jsx)(u,{shortcut:`↑↓`,action:`navigate`}),(0,F.jsx)(u,{shortcut:`Space`,action:`toggle`}),(0,F.jsx)(u,{shortcut:`Enter`,action:`confirm`}),(0,F.jsx)(de,{action:`confirm:no`,context:`Confirmation`,fallback:`Esc`,description:`cancel`})]})}function Se({onSubmit:e,defaultSelections:t}){let[n,r]=(0,P.useState)(!1),i=(0,P.useCallback)(t=>{if(t.length===0){r(!0);return}r(!1),e(t)},[e]),o=(0,P.useCallback)(()=>{r(!1)},[]),s=(0,P.useCallback)(()=>{r(!0)},[]);return(0,F.jsxs)(l,{title:`Select GitHub workflows to install`,subtitle:`We'll create a workflow file in your repository for each one you select.`,onCancel:s,inputGuide:xe,children:[(0,F.jsx)(_,{children:(0,F.jsxs)(c,{dimColor:!0,children:[`More workflow examples (issue triage, CI fixes, etc.) at:`,` `,(0,F.jsx)(a,{url:`https://github.com/anthropics/claude-code-action/blob/main/examples/`,children:`https://github.com/anthropics/claude-code-action/blob/main/examples/`})]})}),(0,F.jsx)(pe,{options:Ce.map(e=>({label:e.label,value:e.value})),defaultValue:t,onSubmit:i,onChange:o,onCancel:s,hideIndexes:!0}),n&&(0,F.jsx)(_,{children:(0,F.jsx)(c,{color:`error`,children:`You must select at least one workflow to continue`})})]})}var P,F,Ce,we=e((()=>{P=t(o(),1),p(),ge(),fe(),F=v(),Ce=[{value:`claude`,label:`@Claude Code - Tag @claude in issues and PR comments`},{value:`claude-review`,label:`Claude Code Review - Automated code review on new PRs`}]})),Te,I,Ee,De,Oe,L=e((()=>{Te=`Add Claude Code GitHub Workflow`,I=`https://github.com/anthropics/claude-code-action/blob/main/docs/setup.md`,Ee=`name: Claude Code
1
+ import{n as e,o as t}from"./chunk-DR8-3Aex.js";import{n,t as r}from"./figures-gfT9mM8P.js";import{F as i,Q as a,Rn as o,T as s,b as c,f as l,g as u,h as d,nt as f,t as p,tn as m,tt as h,v as g,x as _}from"./src-Di342QoJ.js";import{t as v}from"./jsx-runtime-D-D469L8.js";import{Ac as y,Mn as b,Pc as x,Po as ee,Vt as te,cn as S,jo as C,on as w}from"./paths-BZbIj1Z1.js";import{n as T,r as E}from"./analytics-DqMQntaB.js";import{l as ne,v as re}from"./git-CN3qtTb_.js";import{r as ie,t as ae}from"./execa-CGue6Z3n.js";import{o as oe,s as D}from"./log-CzsijfHZ.js";import{r as se,t as O}from"./execFileNoThrow-CuQN1sz8.js";import{Ey as ce,Lx as le,MT as ue,NT as de,Ux as k,Wx as A,aC as fe,by as pe,iC as me,qw as j,vy as he,wy as M,yy as ge}from"./loadAgentsDir-DaApSWNv.js";import{n as _e,t as ve}from"./browser-fLRXxIsQ.js";import{t as N}from"./useKeybinding-FsOnjW6T.js";import{l as ye,u as be}from"./referral-Nz20w4pB.js";function xe(e){return e.pending?(0,F.jsxs)(c,{children:[`Press `,e.keyName,` again to exit`]}):(0,F.jsxs)(d,{children:[(0,F.jsx)(u,{shortcut:`↑↓`,action:`navigate`}),(0,F.jsx)(u,{shortcut:`Space`,action:`toggle`}),(0,F.jsx)(u,{shortcut:`Enter`,action:`confirm`}),(0,F.jsx)(me,{action:`confirm:no`,context:`Confirmation`,fallback:`Esc`,description:`cancel`})]})}function Se({onSubmit:e,defaultSelections:t}){let[n,r]=(0,P.useState)(!1),i=(0,P.useCallback)(t=>{if(t.length===0){r(!0);return}r(!1),e(t)},[e]),o=(0,P.useCallback)(()=>{r(!1)},[]),s=(0,P.useCallback)(()=>{r(!0)},[]);return(0,F.jsxs)(l,{title:`Select GitHub workflows to install`,subtitle:`We'll create a workflow file in your repository for each one you select.`,onCancel:s,inputGuide:xe,children:[(0,F.jsx)(_,{children:(0,F.jsxs)(c,{dimColor:!0,children:[`More workflow examples (issue triage, CI fixes, etc.) at:`,` `,(0,F.jsx)(a,{url:`https://github.com/anthropics/claude-code-action/blob/main/examples/`,children:`https://github.com/anthropics/claude-code-action/blob/main/examples/`})]})}),(0,F.jsx)(ge,{options:Ce.map(e=>({label:e.label,value:e.value})),defaultValue:t,onSubmit:i,onChange:o,onCancel:s,hideIndexes:!0}),n&&(0,F.jsx)(_,{children:(0,F.jsx)(c,{color:`error`,children:`You must select at least one workflow to continue`})})]})}var P,F,Ce,we=e((()=>{P=t(o(),1),p(),fe(),pe(),F=v(),Ce=[{value:`claude`,label:`@Claude Code - Tag @claude in issues and PR comments`},{value:`claude-review`,label:`Claude Code Review - Automated code review on new PRs`}]})),Te,I,Ee,De,Oe,L=e((()=>{Te=`Add Claude Code GitHub Workflow`,I=`https://github.com/anthropics/claude-code-action/blob/main/docs/setup.md`,Ee=`name: Claude Code
2
2
 
3
3
  on:
4
4
  issue_comment:
@@ -132,7 +132,7 @@ jobs:
132
132
  # See https://github.com/anthropics/claude-code-action/blob/main/docs/usage.md
133
133
  # or https://code.claude.com/docs/en/cli-reference for available options
134
134
 
135
- `}));function ke({existingApiKey:e,apiKeyOrOAuthToken:t,onApiKeyChange:n,onSubmit:r,onToggleUseExistingKey:a,onCreateOAuthToken:o,selectedOption:l=e?`existing`:o?`oauth`:`new`,onSelectOption:u}){let[d,p]=(0,R.useState)(0),m=i(),[h]=s(),v=(0,R.useCallback)(()=>{l===`new`&&o?u?.(`oauth`):l===`oauth`&&e&&(u?.(`existing`),a(!0))},[l,o,e,u,a]),y=(0,R.useCallback)(()=>{l===`existing`?(u?.(o?`oauth`:`new`),a(!1)):l===`oauth`&&u?.(`new`)},[l,o,u,a]),b=(0,R.useCallback)(()=>{l===`oauth`&&o?o():r()},[l,o,r]),x=l===`new`;return f({"confirm:previous":v,"confirm:next":y,"confirm:yes":b},{context:`Confirmation`,isActive:!x}),f({"confirm:previous":v,"confirm:next":y},{context:`Confirmation`,isActive:x}),(0,z.jsxs)(z.Fragment,{children:[(0,z.jsxs)(_,{flexDirection:`column`,borderStyle:`round`,paddingX:1,children:[(0,z.jsxs)(_,{flexDirection:`column`,marginBottom:1,children:[(0,z.jsx)(c,{bold:!0,children:`Install GitHub App`}),(0,z.jsx)(c,{dimColor:!0,children:`Choose API key`})]}),e&&(0,z.jsx)(_,{marginBottom:1,children:(0,z.jsxs)(c,{children:[l===`existing`?g(`success`,h)(`> `):` `,`Use your existing Claude Code API key`]})}),o&&(0,z.jsx)(_,{marginBottom:1,children:(0,z.jsxs)(c,{children:[l===`oauth`?g(`success`,h)(`> `):` `,`Create a long-lived token with your Claude subscription`]})}),(0,z.jsx)(_,{marginBottom:1,children:(0,z.jsxs)(c,{children:[l===`new`?g(`success`,h)(`> `):` `,`Enter a new API key`]})}),l===`new`&&(0,z.jsx)(M,{value:t,onChange:n,onSubmit:r,onPaste:n,focus:!0,placeholder:`sk-ant… (Create a new key at https://platform.claude.com/settings/keys)`,mask:`*`,columns:m.columns,cursorOffset:d,onChangeCursorOffset:p,showCursor:!0})]}),(0,z.jsx)(_,{marginLeft:3,children:(0,z.jsx)(c,{dimColor:!0,children:`↑/↓ to select · Enter to continue`})})]})}var R,z,Ae=e((()=>{R=t(o(),1),k(),A(),p(),N(),z=v()}));function je({useExistingSecret:e,secretName:t,onToggleUseExistingSecret:n,onSecretNameChange:r,onSubmit:a}){let[o,l]=(0,B.useState)(0),u=i(),[d]=s(),p=(0,B.useCallback)(()=>n(!0),[n]),m=(0,B.useCallback)(()=>n(!1),[n]);return f({"confirm:previous":p,"confirm:next":m,"confirm:yes":a},{context:`Confirmation`,isActive:e}),f({"confirm:previous":p,"confirm:next":m},{context:`Confirmation`,isActive:!e}),(0,V.jsxs)(V.Fragment,{children:[(0,V.jsxs)(_,{flexDirection:`column`,borderStyle:`round`,paddingX:1,children:[(0,V.jsxs)(_,{flexDirection:`column`,marginBottom:1,children:[(0,V.jsx)(c,{bold:!0,children:`Install GitHub App`}),(0,V.jsx)(c,{dimColor:!0,children:`Setup API key secret`})]}),(0,V.jsx)(_,{marginBottom:1,children:(0,V.jsx)(c,{color:`warning`,children:`ANTHROPIC_API_KEY already exists in repository secrets!`})}),(0,V.jsx)(_,{marginBottom:1,children:(0,V.jsx)(c,{children:`Would you like to:`})}),(0,V.jsx)(_,{marginBottom:1,children:(0,V.jsxs)(c,{children:[e?g(`success`,d)(`> `):` `,`Use the existing API key`]})}),(0,V.jsx)(_,{marginBottom:1,children:(0,V.jsxs)(c,{children:[e?` `:g(`success`,d)(`> `),`Create a new secret with a different name`]})}),!e&&(0,V.jsxs)(V.Fragment,{children:[(0,V.jsx)(_,{marginBottom:1,children:(0,V.jsx)(c,{children:`Enter new secret name (alphanumeric with underscores):`})}),(0,V.jsx)(M,{value:t,onChange:r,onSubmit:a,focus:!0,placeholder:`e.g., CLAUDE_API_KEY`,columns:u.columns,cursorOffset:o,onChangeCursorOffset:l,showCursor:!0})]})]}),(0,V.jsx)(_,{marginLeft:3,children:(0,V.jsx)(c,{dimColor:!0,children:`↑/↓ to select · Enter to continue`})})]})}var B,V,Me=e((()=>{B=t(o(),1),k(),A(),p(),N(),V=v()}));function Ne(){return(0,Pe.jsx)(c,{children:`Checking GitHub CLI installation…`})}var Pe,Fe=e((()=>{p(),Pe=v()}));function Ie({currentRepo:e,useCurrentRepo:t,repoUrl:n,onRepoUrlChange:r,onSubmit:a,onToggleUseCurrentRepo:o}){let[s,l]=(0,H.useState)(0),[u,d]=(0,H.useState)(!1),p=i().columns,m=(0,H.useCallback)(()=>{if(!(t?e:n)?.trim()){d(!0);return}a()},[t,e,n,a]),h=!t||!e,g=(0,H.useCallback)(()=>{o(!0),d(!1)},[o]),v=(0,H.useCallback)(()=>{o(!1),d(!1)},[o]);return f({"confirm:previous":g,"confirm:next":v,"confirm:yes":m},{context:`Confirmation`,isActive:!h}),f({"confirm:previous":g,"confirm:next":v},{context:`Confirmation`,isActive:h}),(0,U.jsxs)(U.Fragment,{children:[(0,U.jsxs)(_,{flexDirection:`column`,borderStyle:`round`,paddingX:1,children:[(0,U.jsxs)(_,{flexDirection:`column`,marginBottom:1,children:[(0,U.jsx)(c,{bold:!0,children:`Install GitHub App`}),(0,U.jsx)(c,{dimColor:!0,children:`Select GitHub repository`})]}),e&&(0,U.jsx)(_,{marginBottom:1,children:(0,U.jsxs)(c,{bold:t,color:t?`permission`:void 0,children:[t?`> `:` `,`Use current repository: `,e]})}),(0,U.jsx)(_,{marginBottom:1,children:(0,U.jsxs)(c,{bold:!t||!e,color:!t||!e?`permission`:void 0,children:[!t||!e?`> `:` `,e?`Enter a different repository`:`Enter repository`]})}),(!t||!e)&&(0,U.jsx)(_,{marginLeft:2,marginBottom:1,children:(0,U.jsx)(M,{value:n,onChange:e=>{r(e),d(!1)},onSubmit:m,focus:!0,placeholder:`Enter a repo as owner/repo or https://github.com/owner/repo…`,columns:p,cursorOffset:s,onChangeCursorOffset:l,showCursor:!0})})]}),u&&(0,U.jsx)(_,{marginLeft:3,marginBottom:1,children:(0,U.jsx)(c,{color:`error`,children:`Please enter a repository name to continue`})}),(0,U.jsx)(_,{marginLeft:3,children:(0,U.jsxs)(c,{dimColor:!0,children:[e?`↑/↓ to select · `:``,`Enter to continue`]})})]})}var H,U,Le=e((()=>{H=t(o(),1),k(),A(),p(),N(),U=v()}));function Re({currentWorkflowInstallStep:e,secretExists:t,useExistingSecret:n,secretName:r,skipWorkflow:i=!1,selectedWorkflows:a}){let o=i?[`Getting repository information`,t&&n?`Using existing API key secret`:`Setting up ${r} secret`]:[`Getting repository information`,`Creating branch`,a.length>1?`Creating workflow files`:`Creating workflow file`,t&&n?`Using existing API key secret`:`Setting up ${r} secret`,`Opening pull request page`];return(0,W.jsx)(W.Fragment,{children:(0,W.jsxs)(_,{flexDirection:`column`,borderStyle:`round`,paddingX:1,children:[(0,W.jsxs)(_,{flexDirection:`column`,marginBottom:1,children:[(0,W.jsx)(c,{bold:!0,children:`Install GitHub App`}),(0,W.jsx)(c,{dimColor:!0,children:`Create GitHub Actions workflow`})]}),o.map((t,n)=>{let r=`pending`;return n<e?r=`completed`:n===e&&(r=`in-progress`),(0,W.jsx)(_,{children:(0,W.jsxs)(c,{color:r===`completed`?`success`:r===`in-progress`?`warning`:void 0,children:[r===`completed`?`✓ `:``,t,r===`in-progress`?`…`:``]})},n)})]})})}var W,ze=e((()=>{p(),W=v()}));function Be({error:e,errorReason:t,errorInstructions:n}){return(0,G.jsxs)(G.Fragment,{children:[(0,G.jsxs)(_,{flexDirection:`column`,borderStyle:`round`,paddingX:1,children:[(0,G.jsx)(_,{flexDirection:`column`,marginBottom:1,children:(0,G.jsx)(c,{bold:!0,children:`Install GitHub App`})}),(0,G.jsxs)(c,{color:`error`,children:[`Error: `,e]}),t&&(0,G.jsx)(_,{marginTop:1,children:(0,G.jsxs)(c,{dimColor:!0,children:[`Reason: `,t]})}),n&&n.length>0&&(0,G.jsxs)(_,{flexDirection:`column`,marginTop:1,children:[(0,G.jsx)(c,{dimColor:!0,children:`How to fix:`}),n.map((e,t)=>(0,G.jsxs)(_,{marginLeft:2,children:[(0,G.jsx)(c,{dimColor:!0,children:`• `}),(0,G.jsx)(c,{children:e})]},t))]}),(0,G.jsx)(_,{marginTop:1,children:(0,G.jsxs)(c,{dimColor:!0,children:[`For manual setup instructions, see: `,(0,G.jsx)(c,{color:`claude`,children:I})]})})]}),(0,G.jsx)(_,{marginLeft:3,children:(0,G.jsx)(c,{dimColor:!0,children:`Press any key to exit`})})]})}var G,Ve=e((()=>{L(),p(),G=v()}));function He({repoName:e,onSelectAction:t}){return(0,K.jsxs)(_,{flexDirection:`column`,borderStyle:`round`,borderDimColor:!0,paddingX:1,children:[(0,K.jsxs)(_,{flexDirection:`column`,marginBottom:1,children:[(0,K.jsx)(c,{bold:!0,children:`Existing Workflow Found`}),(0,K.jsxs)(c,{dimColor:!0,children:[`Repository: `,e]})]}),(0,K.jsxs)(_,{flexDirection:`column`,marginBottom:1,children:[(0,K.jsxs)(c,{children:[`A Claude workflow file already exists at `,(0,K.jsx)(c,{color:`claude`,children:`.github/workflows/claude.yml`})]}),(0,K.jsx)(c,{dimColor:!0,children:`What would you like to do?`})]}),(0,K.jsx)(_,{flexDirection:`column`,children:(0,K.jsx)(ce,{options:[{label:`Update workflow file with latest version`,value:`update`},{label:`Skip workflow update (configure secrets only)`,value:`skip`},{label:`Exit without making changes`,value:`exit`}],onChange:e=>{t(e)},onCancel:()=>{t(`exit`)}})}),(0,K.jsx)(_,{marginTop:1,children:(0,K.jsxs)(c,{dimColor:!0,children:[`View the latest workflow template at:`,` `,(0,K.jsx)(c,{color:`claude`,children:`https://github.com/anthropics/claude-code-action/blob/main/examples/claude.yml`})]})})]})}var K,Ue=e((()=>{he(),p(),K=v()}));function We({repoUrl:e,onSubmit:t}){return h(`confirm:yes`,t,{context:`Confirmation`}),(0,q.jsxs)(_,{flexDirection:`column`,borderStyle:`round`,borderDimColor:!0,paddingX:1,children:[(0,q.jsx)(_,{flexDirection:`column`,marginBottom:1,children:(0,q.jsx)(c,{bold:!0,children:`Install the Claude GitHub App`})}),(0,q.jsx)(_,{marginBottom:1,children:(0,q.jsx)(c,{children:`Opening browser to install the Claude GitHub App…`})}),(0,q.jsx)(_,{marginBottom:1,children:(0,q.jsx)(c,{children:`If your browser doesn't open automatically, visit:`})}),(0,q.jsx)(_,{marginBottom:1,children:(0,q.jsx)(c,{underline:!0,children:`https://github.com/apps/claude`})}),(0,q.jsx)(_,{marginBottom:1,children:(0,q.jsxs)(c,{children:[`Please install the app for repository: `,(0,q.jsx)(c,{bold:!0,children:e})]})}),(0,q.jsx)(_,{marginBottom:1,children:(0,q.jsx)(c,{dimColor:!0,children:`Important: Make sure to grant access to this specific repository`})}),(0,q.jsx)(_,{children:(0,q.jsxs)(c,{bold:!0,color:`permission`,children:[`Press Enter once you've installed the app`,r.ellipsis]})}),(0,q.jsx)(_,{marginTop:1,children:(0,q.jsxs)(c,{dimColor:!0,children:[`Having trouble? See manual setup instructions at: `,(0,q.jsx)(c,{color:`claude`,children:I})]})})]})}var q,Ge=e((()=>{n(),L(),p(),N(),q=v()}));function Ke({onSuccess:e,onCancel:t}){let[n,r]=(0,J.useState)({state:`starting`}),[o]=(0,J.useState)(()=>new le),[s,l]=(0,J.useState)(``),[d,f]=(0,J.useState)(0),[p,h]=(0,J.useState)(!1),[g,v]=(0,J.useState)(!1),y=(0,J.useRef)(new Set),x=(0,J.useRef)(void 0),ee=i(),te=Math.max(50,ee.columns-30-4);function S(e){n.state===`error`&&(e.preventDefault(),e.key===`return`&&n.toRetry?(l(``),f(0),r({state:`about_to_retry`,nextState:n.toRetry})):t())}async function C(e,t){try{let[n,i]=e.split(`#`);if(!n||!i){r({state:`error`,message:`Invalid code. Please make sure the full code was copied`,toRetry:{state:`waiting_for_login`,url:t}});return}E(`tengu_oauth_manual_entry`,{}),o.handleManualAuthCodeInput({authorizationCode:n,state:i})}catch(e){D(e),r({state:`error`,message:e.message,toRetry:{state:`waiting_for_login`,url:t}})}}let w=(0,J.useCallback)(async()=>{y.current.forEach(e=>clearTimeout(e)),y.current.clear();try{let t=await o.startOAuthFlow(async e=>{r({state:`waiting_for_login`,url:e});let t=setTimeout(h,3e3,!0);y.current.add(t)},{loginWithClaudeAi:!0,inferenceOnly:!0,expiresIn:365*24*60*60});r({state:`processing`}),b(t);let n=setTimeout((e,t,n,r)=>{e({state:`success`,token:t});let i=setTimeout(n,1e3,t);r.current.add(i)},100,r,t.accessToken,e,y);y.current.add(n)}catch(e){let t=e.message;r({state:`error`,message:t,toRetry:{state:`starting`}}),D(e),E(`tengu_oauth_error`,{error:t})}},[o,e]);(0,J.useEffect)(()=>{n.state===`starting`&&w()},[n.state,w]),(0,J.useEffect)(()=>{if(n.state===`about_to_retry`){let e=setTimeout((e,t,n)=>{t(e.state===`waiting_for_login`),n(e)},500,n.nextState,h,r);y.current.add(e)}},[n]),(0,J.useEffect)(()=>{s===`c`&&n.state===`waiting_for_login`&&p&&!g&&(m(n.url).then(e=>{e&&process.stdout.write(e),v(!0),clearTimeout(x.current),x.current=setTimeout(v,2e3,!1)}),l(``))},[s,n,p,g]),(0,J.useEffect)(()=>{let e=y.current;return()=>{o.cleanup(),e.forEach(e=>clearTimeout(e)),e.clear(),clearTimeout(x.current)}},[o]);function T(){switch(n.state){case`starting`:return(0,Y.jsxs)(_,{children:[(0,Y.jsx)(j,{}),(0,Y.jsx)(c,{children:`Starting authentication…`})]});case`waiting_for_login`:return(0,Y.jsxs)(_,{flexDirection:`column`,gap:1,children:[!p&&(0,Y.jsxs)(_,{children:[(0,Y.jsx)(j,{}),(0,Y.jsx)(c,{children:`Opening browser to sign in with your Claude account…`})]}),p&&(0,Y.jsxs)(_,{children:[(0,Y.jsx)(c,{children:qe}),(0,Y.jsx)(M,{value:s,onChange:l,onSubmit:e=>C(e,n.url),cursorOffset:d,onChangeCursorOffset:f,columns:te})]})]});case`processing`:return(0,Y.jsxs)(_,{children:[(0,Y.jsx)(j,{}),(0,Y.jsx)(c,{children:`Processing authentication…`})]});case`success`:return(0,Y.jsxs)(_,{flexDirection:`column`,gap:1,children:[(0,Y.jsx)(c,{color:`success`,children:`✓ Authentication token created successfully!`}),(0,Y.jsx)(c,{dimColor:!0,children:`Using token for GitHub Actions setup…`})]});case`error`:return(0,Y.jsxs)(_,{flexDirection:`column`,gap:1,children:[(0,Y.jsxs)(c,{color:`error`,children:[`OAuth error: `,n.message]}),n.toRetry?(0,Y.jsx)(c,{dimColor:!0,children:`Press Enter to try again, or any other key to cancel`}):(0,Y.jsx)(c,{dimColor:!0,children:`Press any key to return to API key selection`})]});case`about_to_retry`:return(0,Y.jsx)(_,{flexDirection:`column`,gap:1,children:(0,Y.jsx)(c,{color:`permission`,children:`Retrying…`})});default:return null}}return(0,Y.jsxs)(_,{flexDirection:`column`,gap:1,tabIndex:0,autoFocus:!0,onKeyDown:S,children:[n.state===`starting`&&(0,Y.jsxs)(_,{flexDirection:`column`,gap:1,paddingBottom:1,children:[(0,Y.jsx)(c,{bold:!0,children:`Create Authentication Token`}),(0,Y.jsx)(c,{dimColor:!0,children:`Creating a long-lived token for GitHub Actions`})]}),n.state!==`success`&&n.state!==`starting`&&n.state!==`processing`&&(0,Y.jsxs)(_,{flexDirection:`column`,gap:1,paddingBottom:1,children:[(0,Y.jsx)(c,{bold:!0,children:`Create Authentication Token`}),(0,Y.jsx)(c,{dimColor:!0,children:`Creating a long-lived token for GitHub Actions`})]},`header`),n.state===`waiting_for_login`&&p&&(0,Y.jsxs)(_,{flexDirection:`column`,gap:1,paddingBottom:1,children:[(0,Y.jsxs)(_,{paddingX:1,children:[(0,Y.jsx)(c,{dimColor:!0,children:`Browser didn't open? Use the url below to sign in `}),g?(0,Y.jsx)(c,{color:`success`,children:`(Copied!)`}):(0,Y.jsx)(c,{dimColor:!0,children:(0,Y.jsx)(u,{shortcut:`c`,action:`copy`,parens:!0})})]}),(0,Y.jsx)(a,{url:n.url,children:(0,Y.jsx)(c,{dimColor:!0,children:n.url})})]},`urlToCopy`),(0,Y.jsx)(_,{paddingLeft:1,flexDirection:`column`,gap:1,children:T()})]})}var J,Y,qe,Je=e((()=>{J=t(o(),1),T(),p(),ue(),k(),A(),me(),w(),oe(),Y=v(),qe=`Paste code here if prompted > `}));function Ye({secretExists:e,useExistingSecret:t,secretName:n,skipWorkflow:r=!1}){return(0,X.jsxs)(X.Fragment,{children:[(0,X.jsxs)(_,{flexDirection:`column`,borderStyle:`round`,paddingX:1,children:[(0,X.jsxs)(_,{flexDirection:`column`,marginBottom:1,children:[(0,X.jsx)(c,{bold:!0,children:`Install GitHub App`}),(0,X.jsx)(c,{dimColor:!0,children:`Success`})]}),!r&&(0,X.jsx)(c,{color:`success`,children:`✓ GitHub Actions workflow created!`}),e&&t&&(0,X.jsx)(_,{marginTop:1,children:(0,X.jsx)(c,{color:`success`,children:`✓ Using existing ANTHROPIC_API_KEY secret`})}),(!e||!t)&&(0,X.jsx)(_,{marginTop:1,children:(0,X.jsxs)(c,{color:`success`,children:[`✓ API key saved as `,n,` secret`]})}),(0,X.jsx)(_,{marginTop:1,children:(0,X.jsx)(c,{children:`Next steps:`})}),r?(0,X.jsxs)(X.Fragment,{children:[(0,X.jsx)(c,{children:`1. Install the Claude GitHub App if you haven't already`}),(0,X.jsx)(c,{children:`2. Your workflow file was kept unchanged`}),(0,X.jsx)(c,{children:`3. API key is configured and ready to use`})]}):(0,X.jsxs)(X.Fragment,{children:[(0,X.jsx)(c,{children:`1. A pre-filled PR page has been created`}),(0,X.jsx)(c,{children:`2. Install the Claude GitHub App if you haven't already`}),(0,X.jsx)(c,{children:`3. Merge the PR to enable Claude PR assistance`})]})]}),(0,X.jsx)(_,{marginLeft:3,children:(0,X.jsx)(c,{dimColor:!0,children:`Press any key to exit`})})]})}var X,Xe=e((()=>{o(),p(),X=v()}));async function Ze(e,t,n,r,i,a,o){let s=await O(`gh`,[`api`,`repos/${e}/contents/${n}`,`--jq`,`.sha`]),c=null;s.code===0&&(c=s.stdout.trim());let l=r;i===`CLAUDE_CODE_OAUTH_TOKEN`?l=r.replace(/anthropic_api_key: \$\{\{ secrets\.ANTHROPIC_API_KEY \}\}/g,"claude_code_oauth_token: ${{ secrets.CLAUDE_CODE_OAUTH_TOKEN }}"):i!==`ANTHROPIC_API_KEY`&&(l=r.replace(/anthropic_api_key: \$\{\{ secrets\.ANTHROPIC_API_KEY \}\}/g,`anthropic_api_key: \${{ secrets.${i} }}`));let u=Buffer.from(l).toString(`base64`),d=[`api`,`--method`,`PUT`,`repos/${e}/contents/${n}`,`-f`,`message=${c?`"Update ${a}"`:`"${a}"`}`,`-f`,`content=${u}`,`-f`,`branch=${t}`];c&&d.push(`-f`,`sha=${c}`);let f=await O(`gh`,d);if(f.code!==0)throw f.stderr.includes(`422`)&&f.stderr.includes(`sha`)?(E(`tengu_setup_github_actions_failed`,{reason:`failed_to_create_workflow_file`,exit_code:f.code,...o}),Error(`Failed to create workflow file ${n}: A Claude workflow file already exists in this repository. Please remove it first or update it manually.`)):(E(`tengu_setup_github_actions_failed`,{reason:`failed_to_create_workflow_file`,exit_code:f.code,...o}),Error(`Failed to create workflow file ${n}: ${f.stderr}
135
+ `}));function ke({existingApiKey:e,apiKeyOrOAuthToken:t,onApiKeyChange:n,onSubmit:r,onToggleUseExistingKey:a,onCreateOAuthToken:o,selectedOption:l=e?`existing`:o?`oauth`:`new`,onSelectOption:u}){let[d,p]=(0,R.useState)(0),m=i(),[h]=s(),v=(0,R.useCallback)(()=>{l===`new`&&o?u?.(`oauth`):l===`oauth`&&e&&(u?.(`existing`),a(!0))},[l,o,e,u,a]),y=(0,R.useCallback)(()=>{l===`existing`?(u?.(o?`oauth`:`new`),a(!1)):l===`oauth`&&u?.(`new`)},[l,o,u,a]),b=(0,R.useCallback)(()=>{l===`oauth`&&o?o():r()},[l,o,r]),x=l===`new`;return f({"confirm:previous":v,"confirm:next":y,"confirm:yes":b},{context:`Confirmation`,isActive:!x}),f({"confirm:previous":v,"confirm:next":y},{context:`Confirmation`,isActive:x}),(0,z.jsxs)(z.Fragment,{children:[(0,z.jsxs)(_,{flexDirection:`column`,borderStyle:`round`,paddingX:1,children:[(0,z.jsxs)(_,{flexDirection:`column`,marginBottom:1,children:[(0,z.jsx)(c,{bold:!0,children:`Install GitHub App`}),(0,z.jsx)(c,{dimColor:!0,children:`Choose API key`})]}),e&&(0,z.jsx)(_,{marginBottom:1,children:(0,z.jsxs)(c,{children:[l===`existing`?g(`success`,h)(`> `):` `,`Use your existing Claude Code API key`]})}),o&&(0,z.jsx)(_,{marginBottom:1,children:(0,z.jsxs)(c,{children:[l===`oauth`?g(`success`,h)(`> `):` `,`Create a long-lived token with your Claude subscription`]})}),(0,z.jsx)(_,{marginBottom:1,children:(0,z.jsxs)(c,{children:[l===`new`?g(`success`,h)(`> `):` `,`Enter a new API key`]})}),l===`new`&&(0,z.jsx)(k,{value:t,onChange:n,onSubmit:r,onPaste:n,focus:!0,placeholder:`sk-ant… (Create a new key at https://platform.claude.com/settings/keys)`,mask:`*`,columns:m.columns,cursorOffset:d,onChangeCursorOffset:p,showCursor:!0})]}),(0,z.jsx)(_,{marginLeft:3,children:(0,z.jsx)(c,{dimColor:!0,children:`↑/↓ to select · Enter to continue`})})]})}var R,z,Ae=e((()=>{R=t(o(),1),A(),j(),p(),N(),z=v()}));function je({useExistingSecret:e,secretName:t,onToggleUseExistingSecret:n,onSecretNameChange:r,onSubmit:a}){let[o,l]=(0,B.useState)(0),u=i(),[d]=s(),p=(0,B.useCallback)(()=>n(!0),[n]),m=(0,B.useCallback)(()=>n(!1),[n]);return f({"confirm:previous":p,"confirm:next":m,"confirm:yes":a},{context:`Confirmation`,isActive:e}),f({"confirm:previous":p,"confirm:next":m},{context:`Confirmation`,isActive:!e}),(0,V.jsxs)(V.Fragment,{children:[(0,V.jsxs)(_,{flexDirection:`column`,borderStyle:`round`,paddingX:1,children:[(0,V.jsxs)(_,{flexDirection:`column`,marginBottom:1,children:[(0,V.jsx)(c,{bold:!0,children:`Install GitHub App`}),(0,V.jsx)(c,{dimColor:!0,children:`Setup API key secret`})]}),(0,V.jsx)(_,{marginBottom:1,children:(0,V.jsx)(c,{color:`warning`,children:`ANTHROPIC_API_KEY already exists in repository secrets!`})}),(0,V.jsx)(_,{marginBottom:1,children:(0,V.jsx)(c,{children:`Would you like to:`})}),(0,V.jsx)(_,{marginBottom:1,children:(0,V.jsxs)(c,{children:[e?g(`success`,d)(`> `):` `,`Use the existing API key`]})}),(0,V.jsx)(_,{marginBottom:1,children:(0,V.jsxs)(c,{children:[e?` `:g(`success`,d)(`> `),`Create a new secret with a different name`]})}),!e&&(0,V.jsxs)(V.Fragment,{children:[(0,V.jsx)(_,{marginBottom:1,children:(0,V.jsx)(c,{children:`Enter new secret name (alphanumeric with underscores):`})}),(0,V.jsx)(k,{value:t,onChange:r,onSubmit:a,focus:!0,placeholder:`e.g., CLAUDE_API_KEY`,columns:u.columns,cursorOffset:o,onChangeCursorOffset:l,showCursor:!0})]})]}),(0,V.jsx)(_,{marginLeft:3,children:(0,V.jsx)(c,{dimColor:!0,children:`↑/↓ to select · Enter to continue`})})]})}var B,V,Me=e((()=>{B=t(o(),1),A(),j(),p(),N(),V=v()}));function Ne(){return(0,Pe.jsx)(c,{children:`Checking GitHub CLI installation…`})}var Pe,Fe=e((()=>{p(),Pe=v()}));function Ie({currentRepo:e,useCurrentRepo:t,repoUrl:n,onRepoUrlChange:r,onSubmit:a,onToggleUseCurrentRepo:o}){let[s,l]=(0,H.useState)(0),[u,d]=(0,H.useState)(!1),p=i().columns,m=(0,H.useCallback)(()=>{if(!(t?e:n)?.trim()){d(!0);return}a()},[t,e,n,a]),h=!t||!e,g=(0,H.useCallback)(()=>{o(!0),d(!1)},[o]),v=(0,H.useCallback)(()=>{o(!1),d(!1)},[o]);return f({"confirm:previous":g,"confirm:next":v,"confirm:yes":m},{context:`Confirmation`,isActive:!h}),f({"confirm:previous":g,"confirm:next":v},{context:`Confirmation`,isActive:h}),(0,U.jsxs)(U.Fragment,{children:[(0,U.jsxs)(_,{flexDirection:`column`,borderStyle:`round`,paddingX:1,children:[(0,U.jsxs)(_,{flexDirection:`column`,marginBottom:1,children:[(0,U.jsx)(c,{bold:!0,children:`Install GitHub App`}),(0,U.jsx)(c,{dimColor:!0,children:`Select GitHub repository`})]}),e&&(0,U.jsx)(_,{marginBottom:1,children:(0,U.jsxs)(c,{bold:t,color:t?`permission`:void 0,children:[t?`> `:` `,`Use current repository: `,e]})}),(0,U.jsx)(_,{marginBottom:1,children:(0,U.jsxs)(c,{bold:!t||!e,color:!t||!e?`permission`:void 0,children:[!t||!e?`> `:` `,e?`Enter a different repository`:`Enter repository`]})}),(!t||!e)&&(0,U.jsx)(_,{marginLeft:2,marginBottom:1,children:(0,U.jsx)(k,{value:n,onChange:e=>{r(e),d(!1)},onSubmit:m,focus:!0,placeholder:`Enter a repo as owner/repo or https://github.com/owner/repo…`,columns:p,cursorOffset:s,onChangeCursorOffset:l,showCursor:!0})})]}),u&&(0,U.jsx)(_,{marginLeft:3,marginBottom:1,children:(0,U.jsx)(c,{color:`error`,children:`Please enter a repository name to continue`})}),(0,U.jsx)(_,{marginLeft:3,children:(0,U.jsxs)(c,{dimColor:!0,children:[e?`↑/↓ to select · `:``,`Enter to continue`]})})]})}var H,U,Le=e((()=>{H=t(o(),1),A(),j(),p(),N(),U=v()}));function Re({currentWorkflowInstallStep:e,secretExists:t,useExistingSecret:n,secretName:r,skipWorkflow:i=!1,selectedWorkflows:a}){let o=i?[`Getting repository information`,t&&n?`Using existing API key secret`:`Setting up ${r} secret`]:[`Getting repository information`,`Creating branch`,a.length>1?`Creating workflow files`:`Creating workflow file`,t&&n?`Using existing API key secret`:`Setting up ${r} secret`,`Opening pull request page`];return(0,W.jsx)(W.Fragment,{children:(0,W.jsxs)(_,{flexDirection:`column`,borderStyle:`round`,paddingX:1,children:[(0,W.jsxs)(_,{flexDirection:`column`,marginBottom:1,children:[(0,W.jsx)(c,{bold:!0,children:`Install GitHub App`}),(0,W.jsx)(c,{dimColor:!0,children:`Create GitHub Actions workflow`})]}),o.map((t,n)=>{let r=`pending`;return n<e?r=`completed`:n===e&&(r=`in-progress`),(0,W.jsx)(_,{children:(0,W.jsxs)(c,{color:r===`completed`?`success`:r===`in-progress`?`warning`:void 0,children:[r===`completed`?`✓ `:``,t,r===`in-progress`?`…`:``]})},n)})]})})}var W,ze=e((()=>{p(),W=v()}));function Be({error:e,errorReason:t,errorInstructions:n}){return(0,G.jsxs)(G.Fragment,{children:[(0,G.jsxs)(_,{flexDirection:`column`,borderStyle:`round`,paddingX:1,children:[(0,G.jsx)(_,{flexDirection:`column`,marginBottom:1,children:(0,G.jsx)(c,{bold:!0,children:`Install GitHub App`})}),(0,G.jsxs)(c,{color:`error`,children:[`Error: `,e]}),t&&(0,G.jsx)(_,{marginTop:1,children:(0,G.jsxs)(c,{dimColor:!0,children:[`Reason: `,t]})}),n&&n.length>0&&(0,G.jsxs)(_,{flexDirection:`column`,marginTop:1,children:[(0,G.jsx)(c,{dimColor:!0,children:`How to fix:`}),n.map((e,t)=>(0,G.jsxs)(_,{marginLeft:2,children:[(0,G.jsx)(c,{dimColor:!0,children:`• `}),(0,G.jsx)(c,{children:e})]},t))]}),(0,G.jsx)(_,{marginTop:1,children:(0,G.jsxs)(c,{dimColor:!0,children:[`For manual setup instructions, see: `,(0,G.jsx)(c,{color:`claude`,children:I})]})})]}),(0,G.jsx)(_,{marginLeft:3,children:(0,G.jsx)(c,{dimColor:!0,children:`Press any key to exit`})})]})}var G,Ve=e((()=>{L(),p(),G=v()}));function He({repoName:e,onSelectAction:t}){return(0,K.jsxs)(_,{flexDirection:`column`,borderStyle:`round`,borderDimColor:!0,paddingX:1,children:[(0,K.jsxs)(_,{flexDirection:`column`,marginBottom:1,children:[(0,K.jsx)(c,{bold:!0,children:`Existing Workflow Found`}),(0,K.jsxs)(c,{dimColor:!0,children:[`Repository: `,e]})]}),(0,K.jsxs)(_,{flexDirection:`column`,marginBottom:1,children:[(0,K.jsxs)(c,{children:[`A Claude workflow file already exists at `,(0,K.jsx)(c,{color:`claude`,children:`.github/workflows/claude.yml`})]}),(0,K.jsx)(c,{dimColor:!0,children:`What would you like to do?`})]}),(0,K.jsx)(_,{flexDirection:`column`,children:(0,K.jsx)(le,{options:[{label:`Update workflow file with latest version`,value:`update`},{label:`Skip workflow update (configure secrets only)`,value:`skip`},{label:`Exit without making changes`,value:`exit`}],onChange:e=>{t(e)},onCancel:()=>{t(`exit`)}})}),(0,K.jsx)(_,{marginTop:1,children:(0,K.jsxs)(c,{dimColor:!0,children:[`View the latest workflow template at:`,` `,(0,K.jsx)(c,{color:`claude`,children:`https://github.com/anthropics/claude-code-action/blob/main/examples/claude.yml`})]})})]})}var K,Ue=e((()=>{he(),p(),K=v()}));function We({repoUrl:e,onSubmit:t}){return h(`confirm:yes`,t,{context:`Confirmation`}),(0,q.jsxs)(_,{flexDirection:`column`,borderStyle:`round`,borderDimColor:!0,paddingX:1,children:[(0,q.jsx)(_,{flexDirection:`column`,marginBottom:1,children:(0,q.jsx)(c,{bold:!0,children:`Install the Claude GitHub App`})}),(0,q.jsx)(_,{marginBottom:1,children:(0,q.jsx)(c,{children:`Opening browser to install the Claude GitHub App…`})}),(0,q.jsx)(_,{marginBottom:1,children:(0,q.jsx)(c,{children:`If your browser doesn't open automatically, visit:`})}),(0,q.jsx)(_,{marginBottom:1,children:(0,q.jsx)(c,{underline:!0,children:`https://github.com/apps/claude`})}),(0,q.jsx)(_,{marginBottom:1,children:(0,q.jsxs)(c,{children:[`Please install the app for repository: `,(0,q.jsx)(c,{bold:!0,children:e})]})}),(0,q.jsx)(_,{marginBottom:1,children:(0,q.jsx)(c,{dimColor:!0,children:`Important: Make sure to grant access to this specific repository`})}),(0,q.jsx)(_,{children:(0,q.jsxs)(c,{bold:!0,color:`permission`,children:[`Press Enter once you've installed the app`,r.ellipsis]})}),(0,q.jsx)(_,{marginTop:1,children:(0,q.jsxs)(c,{dimColor:!0,children:[`Having trouble? See manual setup instructions at: `,(0,q.jsx)(c,{color:`claude`,children:I})]})})]})}var q,Ge=e((()=>{n(),L(),p(),N(),q=v()}));function Ke({onSuccess:e,onCancel:t}){let[n,r]=(0,J.useState)({state:`starting`}),[o]=(0,J.useState)(()=>new ue),[s,l]=(0,J.useState)(``),[d,f]=(0,J.useState)(0),[p,h]=(0,J.useState)(!1),[g,v]=(0,J.useState)(!1),y=(0,J.useRef)(new Set),x=(0,J.useRef)(void 0),ee=i(),te=Math.max(50,ee.columns-30-4);function S(e){n.state===`error`&&(e.preventDefault(),e.key===`return`&&n.toRetry?(l(``),f(0),r({state:`about_to_retry`,nextState:n.toRetry})):t())}async function C(e,t){try{let[n,i]=e.split(`#`);if(!n||!i){r({state:`error`,message:`Invalid code. Please make sure the full code was copied`,toRetry:{state:`waiting_for_login`,url:t}});return}E(`tengu_oauth_manual_entry`,{}),o.handleManualAuthCodeInput({authorizationCode:n,state:i})}catch(e){D(e),r({state:`error`,message:e.message,toRetry:{state:`waiting_for_login`,url:t}})}}let w=(0,J.useCallback)(async()=>{y.current.forEach(e=>clearTimeout(e)),y.current.clear();try{let t=await o.startOAuthFlow(async e=>{r({state:`waiting_for_login`,url:e});let t=setTimeout(h,3e3,!0);y.current.add(t)},{loginWithClaudeAi:!0,inferenceOnly:!0,expiresIn:365*24*60*60});r({state:`processing`}),b(t);let n=setTimeout((e,t,n,r)=>{e({state:`success`,token:t});let i=setTimeout(n,1e3,t);r.current.add(i)},100,r,t.accessToken,e,y);y.current.add(n)}catch(e){let t=e.message;r({state:`error`,message:t,toRetry:{state:`starting`}}),D(e),E(`tengu_oauth_error`,{error:t})}},[o,e]);(0,J.useEffect)(()=>{n.state===`starting`&&w()},[n.state,w]),(0,J.useEffect)(()=>{if(n.state===`about_to_retry`){let e=setTimeout((e,t,n)=>{t(e.state===`waiting_for_login`),n(e)},500,n.nextState,h,r);y.current.add(e)}},[n]),(0,J.useEffect)(()=>{s===`c`&&n.state===`waiting_for_login`&&p&&!g&&(m(n.url).then(e=>{e&&process.stdout.write(e),v(!0),clearTimeout(x.current),x.current=setTimeout(v,2e3,!1)}),l(``))},[s,n,p,g]),(0,J.useEffect)(()=>{let e=y.current;return()=>{o.cleanup(),e.forEach(e=>clearTimeout(e)),e.clear(),clearTimeout(x.current)}},[o]);function T(){switch(n.state){case`starting`:return(0,Y.jsxs)(_,{children:[(0,Y.jsx)(M,{}),(0,Y.jsx)(c,{children:`Starting authentication…`})]});case`waiting_for_login`:return(0,Y.jsxs)(_,{flexDirection:`column`,gap:1,children:[!p&&(0,Y.jsxs)(_,{children:[(0,Y.jsx)(M,{}),(0,Y.jsx)(c,{children:`Opening browser to sign in with your Claude account…`})]}),p&&(0,Y.jsxs)(_,{children:[(0,Y.jsx)(c,{children:qe}),(0,Y.jsx)(k,{value:s,onChange:l,onSubmit:e=>C(e,n.url),cursorOffset:d,onChangeCursorOffset:f,columns:te})]})]});case`processing`:return(0,Y.jsxs)(_,{children:[(0,Y.jsx)(M,{}),(0,Y.jsx)(c,{children:`Processing authentication…`})]});case`success`:return(0,Y.jsxs)(_,{flexDirection:`column`,gap:1,children:[(0,Y.jsx)(c,{color:`success`,children:`✓ Authentication token created successfully!`}),(0,Y.jsx)(c,{dimColor:!0,children:`Using token for GitHub Actions setup…`})]});case`error`:return(0,Y.jsxs)(_,{flexDirection:`column`,gap:1,children:[(0,Y.jsxs)(c,{color:`error`,children:[`OAuth error: `,n.message]}),n.toRetry?(0,Y.jsx)(c,{dimColor:!0,children:`Press Enter to try again, or any other key to cancel`}):(0,Y.jsx)(c,{dimColor:!0,children:`Press any key to return to API key selection`})]});case`about_to_retry`:return(0,Y.jsx)(_,{flexDirection:`column`,gap:1,children:(0,Y.jsx)(c,{color:`permission`,children:`Retrying…`})});default:return null}}return(0,Y.jsxs)(_,{flexDirection:`column`,gap:1,tabIndex:0,autoFocus:!0,onKeyDown:S,children:[n.state===`starting`&&(0,Y.jsxs)(_,{flexDirection:`column`,gap:1,paddingBottom:1,children:[(0,Y.jsx)(c,{bold:!0,children:`Create Authentication Token`}),(0,Y.jsx)(c,{dimColor:!0,children:`Creating a long-lived token for GitHub Actions`})]}),n.state!==`success`&&n.state!==`starting`&&n.state!==`processing`&&(0,Y.jsxs)(_,{flexDirection:`column`,gap:1,paddingBottom:1,children:[(0,Y.jsx)(c,{bold:!0,children:`Create Authentication Token`}),(0,Y.jsx)(c,{dimColor:!0,children:`Creating a long-lived token for GitHub Actions`})]},`header`),n.state===`waiting_for_login`&&p&&(0,Y.jsxs)(_,{flexDirection:`column`,gap:1,paddingBottom:1,children:[(0,Y.jsxs)(_,{paddingX:1,children:[(0,Y.jsx)(c,{dimColor:!0,children:`Browser didn't open? Use the url below to sign in `}),g?(0,Y.jsx)(c,{color:`success`,children:`(Copied!)`}):(0,Y.jsx)(c,{dimColor:!0,children:(0,Y.jsx)(u,{shortcut:`c`,action:`copy`,parens:!0})})]}),(0,Y.jsx)(a,{url:n.url,children:(0,Y.jsx)(c,{dimColor:!0,children:n.url})})]},`urlToCopy`),(0,Y.jsx)(_,{paddingLeft:1,flexDirection:`column`,gap:1,children:T()})]})}var J,Y,qe,Je=e((()=>{J=t(o(),1),T(),p(),ce(),A(),j(),de(),w(),oe(),Y=v(),qe=`Paste code here if prompted > `}));function Ye({secretExists:e,useExistingSecret:t,secretName:n,skipWorkflow:r=!1}){return(0,X.jsxs)(X.Fragment,{children:[(0,X.jsxs)(_,{flexDirection:`column`,borderStyle:`round`,paddingX:1,children:[(0,X.jsxs)(_,{flexDirection:`column`,marginBottom:1,children:[(0,X.jsx)(c,{bold:!0,children:`Install GitHub App`}),(0,X.jsx)(c,{dimColor:!0,children:`Success`})]}),!r&&(0,X.jsx)(c,{color:`success`,children:`✓ GitHub Actions workflow created!`}),e&&t&&(0,X.jsx)(_,{marginTop:1,children:(0,X.jsx)(c,{color:`success`,children:`✓ Using existing ANTHROPIC_API_KEY secret`})}),(!e||!t)&&(0,X.jsx)(_,{marginTop:1,children:(0,X.jsxs)(c,{color:`success`,children:[`✓ API key saved as `,n,` secret`]})}),(0,X.jsx)(_,{marginTop:1,children:(0,X.jsx)(c,{children:`Next steps:`})}),r?(0,X.jsxs)(X.Fragment,{children:[(0,X.jsx)(c,{children:`1. Install the Claude GitHub App if you haven't already`}),(0,X.jsx)(c,{children:`2. Your workflow file was kept unchanged`}),(0,X.jsx)(c,{children:`3. API key is configured and ready to use`})]}):(0,X.jsxs)(X.Fragment,{children:[(0,X.jsx)(c,{children:`1. A pre-filled PR page has been created`}),(0,X.jsx)(c,{children:`2. Install the Claude GitHub App if you haven't already`}),(0,X.jsx)(c,{children:`3. Merge the PR to enable Claude PR assistance`})]})]}),(0,X.jsx)(_,{marginLeft:3,children:(0,X.jsx)(c,{dimColor:!0,children:`Press any key to exit`})})]})}var X,Xe=e((()=>{o(),p(),X=v()}));async function Ze(e,t,n,r,i,a,o){let s=await O(`gh`,[`api`,`repos/${e}/contents/${n}`,`--jq`,`.sha`]),c=null;s.code===0&&(c=s.stdout.trim());let l=r;i===`CLAUDE_CODE_OAUTH_TOKEN`?l=r.replace(/anthropic_api_key: \$\{\{ secrets\.ANTHROPIC_API_KEY \}\}/g,"claude_code_oauth_token: ${{ secrets.CLAUDE_CODE_OAUTH_TOKEN }}"):i!==`ANTHROPIC_API_KEY`&&(l=r.replace(/anthropic_api_key: \$\{\{ secrets\.ANTHROPIC_API_KEY \}\}/g,`anthropic_api_key: \${{ secrets.${i} }}`));let u=Buffer.from(l).toString(`base64`),d=[`api`,`--method`,`PUT`,`repos/${e}/contents/${n}`,`-f`,`message=${c?`"Update ${a}"`:`"${a}"`}`,`-f`,`content=${u}`,`-f`,`branch=${t}`];c&&d.push(`-f`,`sha=${c}`);let f=await O(`gh`,d);if(f.code!==0)throw f.stderr.includes(`422`)&&f.stderr.includes(`sha`)?(E(`tengu_setup_github_actions_failed`,{reason:`failed_to_create_workflow_file`,exit_code:f.code,...o}),Error(`Failed to create workflow file ${n}: A Claude workflow file already exists in this repository. Please remove it first or update it manually.`)):(E(`tengu_setup_github_actions_failed`,{reason:`failed_to_create_workflow_file`,exit_code:f.code,...o}),Error(`Failed to create workflow file ${n}: ${f.stderr}
136
136
 
137
137
  Need help? Common issues:
138
138
  · Permission denied → Run: gh auth refresh -h github.com -s repo,workflow
@@ -1 +1 @@
1
- import{n as e}from"./chunk-DR8-3Aex.js";import{Ac as t,Pc as n}from"./paths-D9CVAtXU.js";import{n as r,r as i}from"./analytics-DqMQntaB.js";import{n as a,t as o}from"./browser-fLRXxIsQ.js";async function s(){return i(`tengu_install_slack_app_clicked`,{}),n(e=>({...e,slackAppInstallCount:(e.slackAppInstallCount??0)+1})),await a(c)?{type:`text`,value:`Opening Slack app installation page in browser…`}:{type:`text`,value:`Couldn't open browser. Visit: ${c}`}}var c;e((()=>{r(),o(),t(),c=`https://slack.com/marketplace/A08SF47R6P4-claude`}))();export{s as call};
1
+ import{n as e}from"./chunk-DR8-3Aex.js";import{Ac as t,Pc as n}from"./paths-BZbIj1Z1.js";import{n as r,r as i}from"./analytics-DqMQntaB.js";import{n as a,t as o}from"./browser-fLRXxIsQ.js";async function s(){return i(`tengu_install_slack_app_clicked`,{}),n(e=>({...e,slackAppInstallCount:(e.slackAppInstallCount??0)+1})),await a(c)?{type:`text`,value:`Opening Slack app installation page in browser…`}:{type:`text`,value:`Couldn't open browser. Visit: ${c}`}}var c;e((()=>{r(),o(),t(),c=`https://slack.com/marketplace/A08SF47R6P4-claude`}))();export{s as call};
@@ -1 +1 @@
1
- import{o as e}from"./chunk-DR8-3Aex.js";import{Mt as t,Rn as n,b as r,o as i,t as a,x as o}from"./src-Di342QoJ.js";import{t as s}from"./jsx-runtime-D-D469L8.js";import{Ka as c,lo as l,oo as u}from"./paths-D9CVAtXU.js";import{L as d,V as f,d as p,s as m}from"./debug-UI3T040K.js";import{n as h,r as g}from"./analytics-DqMQntaB.js";import{a as _,n as v}from"./env-chR0gV31.js";import{Bb as y,Hb as b,Rb as x,Ub as S,zb as C}from"./loadAgentsDir-D-xcJ22-.js";import{join as w}from"node:path";import{homedir as T}from"node:os";var E=e(n(),1);h(),a(),m(),_(),f(),x(),u();var D=s();function O(){let e=v.platform===`win32`,t=T();return e?w(t,`.local`,`bin`,`claude.exe`).replace(/\//g,`\\`):`~/.local/bin/claude`}function k({messages:e}){return e.length===0?null:(0,D.jsxs)(o,{flexDirection:`column`,gap:0,marginBottom:1,children:[(0,D.jsx)(o,{children:(0,D.jsxs)(r,{color:`warning`,children:[(0,D.jsx)(i,{status:`warning`,withSpace:!0}),`Setup notes:`]})}),e.map((e,t)=>(0,D.jsx)(o,{marginLeft:2,children:(0,D.jsxs)(r,{dimColor:!0,children:[`• `,e]})},t))]})}function A({onDone:e,force:t,target:n}){let[a,s]=(0,E.useState)({type:`checking`});return(0,E.useEffect)(()=>{async function e(){try{p(`Install: Starting installation process (force=${t}, target=${n})`);let e=n||c()?.autoUpdatesChannel||`latest`;s({type:`installing`,version:e}),p(`Install: Calling installLatest(channelOrVersion=${e}, forceReinstall=${t})`);let r=await S(e,t);if(p(`Install: installLatest returned version=${r.latestVersion}, wasUpdated=${r.wasUpdated}, lockFailed=${r.lockFailed}`),r.lockFailed)throw Error(`Could not install - another process is currently installing Claude. Please try again in a moment.`);r.latestVersion||p(`Install: Failed to retrieve version information during install`,{level:`error`}),r.wasUpdated||p(`Install: Already up to date`),s({type:`setting-up`});let i=await C(!0);p(`Install: Setup launcher completed with ${i.length} messages`),i.length>0&&i.forEach(e=>p(`Install: Setup message: ${e.message}`)),p(`Install: Cleaning up npm installations after successful install`);let{removed:a,errors:o,warnings:u}=await y();a>0&&p(`Cleaned up ${a} npm installation(s)`),o.length>0&&p(`Cleanup errors: ${o.join(`, `)}`);let d=await b();d.length>0&&p(`Shell alias cleanup: ${d.map(e=>e.message).join(`; `)}`),g(`tengu_claude_install_command`,{has_version:+!!r.latestVersion,forced:+!!t}),(n===`latest`||n===`stable`)&&(l(`userSettings`,{autoUpdatesChannel:n}),p(`Install: Saved autoUpdatesChannel=${n} to user settings`));let f=[...u,...d.map(e=>e.message)];i.length>0?(s({type:`set-up`,messages:i.map(e=>e.message)}),setTimeout(s,2e3,{type:`success`,version:r.latestVersion||`current`,setupMessages:[...i.map(e=>e.message),...f]})):(p(`Install: Shell PATH already configured`),s({type:`success`,version:r.latestVersion||`current`,setupMessages:f.length>0?f:void 0}))}catch(e){p(`Install command failed: ${e}`,{level:`error`}),s({type:`error`,message:d(e)})}}e()},[t,n]),(0,E.useEffect)(()=>{a.type===`success`?setTimeout(e,2e3,`Claude Code installation completed successfully`,{display:`system`}):a.type===`error`&&setTimeout(e,3e3,`Claude Code installation failed`,{display:`system`})},[a,e]),(0,D.jsxs)(o,{flexDirection:`column`,marginTop:1,children:[a.type===`checking`&&(0,D.jsx)(r,{color:`claude`,children:`Checking installation status...`}),a.type===`cleaning-npm`&&(0,D.jsx)(r,{color:`warning`,children:`Cleaning up old npm installations...`}),a.type===`installing`&&(0,D.jsxs)(r,{color:`claude`,children:[`Installing Claude Code native build `,a.version,`...`]}),a.type===`setting-up`&&(0,D.jsx)(r,{color:`claude`,children:`Setting up launcher and shell integration...`}),a.type===`set-up`&&(0,D.jsx)(k,{messages:a.messages}),a.type===`success`&&(0,D.jsxs)(o,{flexDirection:`column`,gap:1,children:[(0,D.jsxs)(o,{children:[(0,D.jsx)(i,{status:`success`,withSpace:!0}),(0,D.jsx)(r,{color:`success`,bold:!0,children:`Claude Code successfully installed!`})]}),(0,D.jsxs)(o,{marginLeft:2,flexDirection:`column`,gap:1,children:[a.version!==`current`&&(0,D.jsxs)(o,{children:[(0,D.jsx)(r,{dimColor:!0,children:`Version: `}),(0,D.jsx)(r,{color:`claude`,children:a.version})]}),(0,D.jsxs)(o,{children:[(0,D.jsx)(r,{dimColor:!0,children:`Location: `}),(0,D.jsx)(r,{color:`text`,children:O()})]})]}),(0,D.jsx)(o,{marginLeft:2,flexDirection:`column`,gap:1,children:(0,D.jsxs)(o,{marginTop:1,children:[(0,D.jsx)(r,{dimColor:!0,children:`Next: Run `}),(0,D.jsx)(r,{color:`claude`,bold:!0,children:`claude --help`}),(0,D.jsx)(r,{dimColor:!0,children:` to get started`})]})}),a.setupMessages&&(0,D.jsx)(k,{messages:a.setupMessages})]}),a.type===`error`&&(0,D.jsxs)(o,{flexDirection:`column`,gap:1,children:[(0,D.jsxs)(o,{children:[(0,D.jsx)(i,{status:`error`,withSpace:!0}),(0,D.jsx)(r,{color:`error`,children:`Installation failed`})]}),(0,D.jsx)(r,{color:`error`,children:a.message}),(0,D.jsx)(o,{marginTop:1,children:(0,D.jsx)(r,{dimColor:!0,children:`Try running with --force to override checks`})})]})]})}var j={type:`local-jsx`,name:`install`,description:`Install Claude Code native build`,argumentHint:`[options]`,async call(e,n,r){let i=r.includes(`--force`),a=r.filter(e=>!e.startsWith(`--`))[0],{unmount:o}=await t((0,D.jsx)(A,{onDone:(t,n)=>{o(),e(t,n)},force:i,target:a}))}};export{j as install};
1
+ import{o as e}from"./chunk-DR8-3Aex.js";import{Mt as t,Rn as n,b as r,o as i,t as a,x as o}from"./src-Di342QoJ.js";import{t as s}from"./jsx-runtime-D-D469L8.js";import{Ka as c,lo as l,oo as u}from"./paths-BZbIj1Z1.js";import{L as d,V as f,d as p,s as m}from"./debug-UI3T040K.js";import{n as h,r as g}from"./analytics-DqMQntaB.js";import{a as _,n as v}from"./env-chR0gV31.js";import{Hb as y,Kb as b,Ub as x,Wb as S,qb as C}from"./loadAgentsDir-DaApSWNv.js";import{join as w}from"node:path";import{homedir as T}from"node:os";var E=e(n(),1);h(),a(),m(),_(),f(),y(),u();var D=s();function O(){let e=v.platform===`win32`,t=T();return e?w(t,`.local`,`bin`,`claude.exe`).replace(/\//g,`\\`):`~/.local/bin/claude`}function k({messages:e}){return e.length===0?null:(0,D.jsxs)(o,{flexDirection:`column`,gap:0,marginBottom:1,children:[(0,D.jsx)(o,{children:(0,D.jsxs)(r,{color:`warning`,children:[(0,D.jsx)(i,{status:`warning`,withSpace:!0}),`Setup notes:`]})}),e.map((e,t)=>(0,D.jsx)(o,{marginLeft:2,children:(0,D.jsxs)(r,{dimColor:!0,children:[`• `,e]})},t))]})}function A({onDone:e,force:t,target:n}){let[a,s]=(0,E.useState)({type:`checking`});return(0,E.useEffect)(()=>{async function e(){try{p(`Install: Starting installation process (force=${t}, target=${n})`);let e=n||c()?.autoUpdatesChannel||`latest`;s({type:`installing`,version:e}),p(`Install: Calling installLatest(channelOrVersion=${e}, forceReinstall=${t})`);let r=await C(e,t);if(p(`Install: installLatest returned version=${r.latestVersion}, wasUpdated=${r.wasUpdated}, lockFailed=${r.lockFailed}`),r.lockFailed)throw Error(`Could not install - another process is currently installing Claude. Please try again in a moment.`);r.latestVersion||p(`Install: Failed to retrieve version information during install`,{level:`error`}),r.wasUpdated||p(`Install: Already up to date`),s({type:`setting-up`});let i=await x(!0);p(`Install: Setup launcher completed with ${i.length} messages`),i.length>0&&i.forEach(e=>p(`Install: Setup message: ${e.message}`)),p(`Install: Cleaning up npm installations after successful install`);let{removed:a,errors:o,warnings:u}=await S();a>0&&p(`Cleaned up ${a} npm installation(s)`),o.length>0&&p(`Cleanup errors: ${o.join(`, `)}`);let d=await b();d.length>0&&p(`Shell alias cleanup: ${d.map(e=>e.message).join(`; `)}`),g(`tengu_claude_install_command`,{has_version:+!!r.latestVersion,forced:+!!t}),(n===`latest`||n===`stable`)&&(l(`userSettings`,{autoUpdatesChannel:n}),p(`Install: Saved autoUpdatesChannel=${n} to user settings`));let f=[...u,...d.map(e=>e.message)];i.length>0?(s({type:`set-up`,messages:i.map(e=>e.message)}),setTimeout(s,2e3,{type:`success`,version:r.latestVersion||`current`,setupMessages:[...i.map(e=>e.message),...f]})):(p(`Install: Shell PATH already configured`),s({type:`success`,version:r.latestVersion||`current`,setupMessages:f.length>0?f:void 0}))}catch(e){p(`Install command failed: ${e}`,{level:`error`}),s({type:`error`,message:d(e)})}}e()},[t,n]),(0,E.useEffect)(()=>{a.type===`success`?setTimeout(e,2e3,`Claude Code installation completed successfully`,{display:`system`}):a.type===`error`&&setTimeout(e,3e3,`Claude Code installation failed`,{display:`system`})},[a,e]),(0,D.jsxs)(o,{flexDirection:`column`,marginTop:1,children:[a.type===`checking`&&(0,D.jsx)(r,{color:`claude`,children:`Checking installation status...`}),a.type===`cleaning-npm`&&(0,D.jsx)(r,{color:`warning`,children:`Cleaning up old npm installations...`}),a.type===`installing`&&(0,D.jsxs)(r,{color:`claude`,children:[`Installing Claude Code native build `,a.version,`...`]}),a.type===`setting-up`&&(0,D.jsx)(r,{color:`claude`,children:`Setting up launcher and shell integration...`}),a.type===`set-up`&&(0,D.jsx)(k,{messages:a.messages}),a.type===`success`&&(0,D.jsxs)(o,{flexDirection:`column`,gap:1,children:[(0,D.jsxs)(o,{children:[(0,D.jsx)(i,{status:`success`,withSpace:!0}),(0,D.jsx)(r,{color:`success`,bold:!0,children:`Claude Code successfully installed!`})]}),(0,D.jsxs)(o,{marginLeft:2,flexDirection:`column`,gap:1,children:[a.version!==`current`&&(0,D.jsxs)(o,{children:[(0,D.jsx)(r,{dimColor:!0,children:`Version: `}),(0,D.jsx)(r,{color:`claude`,children:a.version})]}),(0,D.jsxs)(o,{children:[(0,D.jsx)(r,{dimColor:!0,children:`Location: `}),(0,D.jsx)(r,{color:`text`,children:O()})]})]}),(0,D.jsx)(o,{marginLeft:2,flexDirection:`column`,gap:1,children:(0,D.jsxs)(o,{marginTop:1,children:[(0,D.jsx)(r,{dimColor:!0,children:`Next: Run `}),(0,D.jsx)(r,{color:`claude`,bold:!0,children:`claude --help`}),(0,D.jsx)(r,{dimColor:!0,children:` to get started`})]})}),a.setupMessages&&(0,D.jsx)(k,{messages:a.setupMessages})]}),a.type===`error`&&(0,D.jsxs)(o,{flexDirection:`column`,gap:1,children:[(0,D.jsxs)(o,{children:[(0,D.jsx)(i,{status:`error`,withSpace:!0}),(0,D.jsx)(r,{color:`error`,children:`Installation failed`})]}),(0,D.jsx)(r,{color:`error`,children:a.message}),(0,D.jsx)(o,{marginTop:1,children:(0,D.jsx)(r,{dimColor:!0,children:`Try running with --force to override checks`})})]})]})}var j={type:`local-jsx`,name:`install`,description:`Install Claude Code native build`,argumentHint:`[options]`,async call(e,n,r){let i=r.includes(`--force`),a=r.filter(e=>!e.startsWith(`--`))[0],{unmount:o}=await t((0,D.jsx)(A,{onDone:(t,n)=>{o(),e(t,n)},force:i,target:a}))}};export{j as install};