ryco-cli 0.1.21 → 0.1.22
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.
- package/dist/{AcpNativeLogging-D54V5cIY.cjs → AcpNativeLogging-COepku4a.cjs} +78 -7
- package/dist/{AcpNativeLogging-Ch-s9nA8.mjs → AcpNativeLogging-D7e1dn7s.mjs} +74 -9
- package/dist/{AzureDevOpsSourceControlProvider-DTOlXGyd.mjs → AzureDevOpsSourceControlProvider-BNGEg1R8.mjs} +3 -3
- package/dist/{AzureDevOpsSourceControlProvider-BzB5-N9m.cjs → AzureDevOpsSourceControlProvider-CrvgKNf2.cjs} +2 -2
- package/dist/{BitbucketSourceControlProvider-DGd4IPx5.mjs → BitbucketSourceControlProvider-Bt21jw68.mjs} +3 -3
- package/dist/{BitbucketSourceControlProvider-D-8PWXO3.cjs → BitbucketSourceControlProvider-BzhsQwH-.cjs} +2 -2
- package/dist/{BunPTY-CNvWSzEJ.mjs → BunPTY-TbHbSc8S.mjs} +1 -1
- package/dist/{ClaudeDriver-DxowtK6I.mjs → ClaudeDriver-D65SPdHR.mjs} +44 -119
- package/dist/{ClaudeDriver-HEbUzW34.cjs → ClaudeDriver-D7NatUx6.cjs} +52 -127
- package/dist/{CodexDriver-CccSWoP3.mjs → CodexDriver-D4z5-wUD.mjs} +237 -50
- package/dist/{CodexDriver-YG4IwzLm.cjs → CodexDriver-DWGtHt9r.cjs} +235 -48
- package/dist/{CodexTextGeneration-CBJHkgOz.cjs → CodexTextGeneration-B4tJTUDo.cjs} +1 -1
- package/dist/{CodexTextGeneration-BfGt7ZUe.mjs → CodexTextGeneration-BikHow8k.mjs} +2 -2
- package/dist/{CopilotDriver-Bm4OZMkm.cjs → CopilotDriver-DJvYncGI.cjs} +122 -23
- package/dist/{CopilotDriver-DZAW-7yV.mjs → CopilotDriver-ZvvsAIkd.mjs} +123 -24
- package/dist/{CursorDriver-B4jb4rWd.mjs → CursorDriver-B1QSBzuH.mjs} +34 -74
- package/dist/{CursorDriver-CYcKAkUY.cjs → CursorDriver-D3I4KULs.cjs} +33 -73
- package/dist/{ForgejoSourceControlProvider-Dfi8KH7I.mjs → ForgejoSourceControlProvider-BGXysSX6.mjs} +3 -3
- package/dist/{ForgejoSourceControlProvider-CXUevO6C.cjs → ForgejoSourceControlProvider-Dh6DOoc8.cjs} +2 -2
- package/dist/{GitHubSourceControlProvider-DOs1ouvp.cjs → GitHubSourceControlProvider-8hsv_kCE.cjs} +2 -2
- package/dist/{GitHubSourceControlProvider-BH97aNa0.mjs → GitHubSourceControlProvider-CPCYV8Xo.mjs} +3 -3
- package/dist/{GitLabSourceControlProvider-CfbE6GYD.cjs → GitLabSourceControlProvider-B0ZbF9Zx.cjs} +2 -2
- package/dist/{GitLabSourceControlProvider-nIzcy9AJ.mjs → GitLabSourceControlProvider-Bvknpaon.mjs} +3 -3
- package/dist/{GrokDriver-CENrrqQc.mjs → GrokDriver-DgQe3pKz.mjs} +30 -10
- package/dist/{GrokDriver-C35gWEiw.cjs → GrokDriver-_puXDTU3.cjs} +31 -11
- package/dist/{NodePTY-lO8PwZLk.mjs → NodePTY-B_p5tLYO.mjs} +1 -1
- package/dist/{OpenCodeDriver-CHuQ6Xhc.cjs → OpenCodeDriver-401RexI0.cjs} +137 -19
- package/dist/{OpenCodeDriver-BIxSPI9J.mjs → OpenCodeDriver-DNUlF8M-.mjs} +135 -20
- package/dist/{SourceControlProviderDiscoveryCatalog-DaRgCE5d.mjs → SourceControlProviderDiscoveryCatalog-B37RHe2u.mjs} +1 -1
- package/dist/{SourceControlProviderDiscoveryCatalog-DCmYsPEa.cjs → SourceControlProviderDiscoveryCatalog-DreaAH1H.cjs} +1 -1
- package/dist/bin.cjs +4508 -613
- package/dist/bin.mjs +4499 -615
- package/dist/client/assets/AccountSettings-CypheYqM.js +1 -0
- package/dist/client/assets/AiFocusSettings-BlX0ED1t.js +1 -0
- package/dist/client/assets/AnimatedHeight-DKCe4x_Q.js +1 -0
- package/dist/client/assets/AppearanceSettings-BSyn6NXf.js +1 -0
- package/dist/client/assets/BranchToolbar.logic-fpBz8Ajj.js +1 -0
- package/dist/client/assets/BrowserPanel-BWch19QH.js +1 -0
- package/dist/client/assets/ChatRightPanel-B7yrq-hS.js +27 -0
- package/dist/client/assets/ChatThreadRouteView-Cg0d_EHs.js +1 -0
- package/dist/client/assets/CommandPaletteDialog-DImCuPaX.js +1 -0
- package/dist/client/assets/CompositeItem-BYnHWRNf.js +1 -0
- package/dist/client/assets/CompositeRoot-B28uivk7.js +1 -0
- package/dist/client/assets/ComputerUseSettings-CosW7jaG.js +1 -0
- package/dist/client/assets/ConnectionsSettings-Bk6vI3G-.js +7 -0
- package/dist/client/assets/ContextHandoffEndpointLabel-BR6ygaub.js +4 -0
- package/dist/client/assets/DiagnosticsSettings-Dp_tCNLw.js +2 -0
- package/dist/client/assets/DialogHandle-BN-QB-sO.js +1 -0
- package/dist/client/assets/DialogPopup-BuJs5WUt.js +1 -0
- package/dist/client/assets/DialogRoot-PxEcoecQ.js +1 -0
- package/dist/client/assets/DialogTitle-4nxQsra4.js +1 -0
- package/dist/client/assets/DialogTrigger-D_0canul.js +1 -0
- package/dist/client/assets/DialogViewport-DSo-2hyf.js +1 -0
- package/dist/client/assets/DraftChatThreadRouteView-C94kpMx4.js +1 -0
- package/dist/client/assets/{ExternalIdentityWeb.logic-TXvkTDG8.js → ExternalIdentityWeb.logic-CGJKCFPo.js} +1 -1
- package/dist/client/assets/{GlassSurface-k7VAG7Dp.js → GlassSurface-CyOTUS7E.js} +1 -1
- package/dist/client/assets/HostedConnectionControls-CL0Ws4ca.js +1 -0
- package/dist/client/assets/HostedHubRoot-LUINZl4r.js +1 -0
- package/dist/client/assets/HostedNativeAuthorizationRoute-CgYVBE6N.js +1 -0
- package/dist/client/assets/HostedRelayTrustNotice-DgdeZh52.js +1 -0
- package/dist/client/assets/Icons-BIUbIFr7.js +1 -0
- package/dist/client/assets/IntegrationsSettingsPanel-B7tXTaa3.js +1 -0
- package/dist/client/assets/KeybindingsSettings-HMlRcGQ4.js +7 -0
- package/dist/client/assets/LazyBrowserPanel-CKfmuM9U.js +1 -0
- package/dist/client/assets/{McpServersSettings-Cpzyop0g.js → McpServersSettings-Bq-HyhvC.js} +4 -4
- package/dist/client/assets/MobileSheet-acDRH9aa.js +1 -0
- package/dist/client/assets/NoActiveThreadState-7rym7bV7.js +1 -0
- package/dist/client/assets/NodeSecuritySettings-D8qjh4Dc.js +1 -0
- package/dist/client/assets/OpinionatedPluginsSettings-D7Uks5yR.js +1 -0
- package/dist/client/assets/PhoneGetAppInterstitial-BQXUSufH.js +1 -0
- package/dist/client/assets/PhoneGetAppInterstitialBackdrop-BbUvwGmI.js +1 -0
- package/dist/client/assets/PhoneHome-DvgdMTkh.js +1 -0
- package/dist/client/assets/PhoneSettingsSurface-DncJ540i.js +1 -0
- package/dist/client/assets/ProjectFavicon-BY5Vyyk6.js +1 -0
- package/dist/client/assets/ProviderInstanceIcon-CZe1TbeC.js +1 -0
- package/dist/client/assets/ProviderModelPicker-DHAY1n_1.js +1 -0
- package/dist/client/assets/{ProviderUpdateLaunchNotification.logic-BWOy8LJG.js → ProviderUpdateLaunchNotification.logic-DQJVrUIo.js} +1 -1
- package/dist/client/assets/ProvidersSettingsPanel-BylxZs4S.js +1 -0
- package/dist/client/assets/RedactedSensitiveText-D-enj1h5.js +1 -0
- package/dist/client/assets/RootAppShell-DBK0WW2b.js +6 -0
- package/dist/client/assets/RycoLetterMark-PnGm6TQY.js +1 -0
- package/dist/client/assets/{Separator-DiMB6Prz.js → Separator-BWKYMFqt.js} +1 -1
- package/dist/client/assets/SettingsDialog-N25hIv-a.js +1 -0
- package/dist/client/assets/SettingsPanels-D9YXmUPP.js +3 -0
- package/dist/client/assets/SettingsPanels.editor-Cn18k74l.js +1 -0
- package/dist/client/assets/SourceControlSettings-BAzSpMfR.js +1 -0
- package/dist/client/assets/StatisticsPage-CLKpfsQ8.js +1 -0
- package/dist/client/assets/StatisticsPanel-DxHUFn64.js +1 -0
- package/dist/client/assets/StatisticsSettingsLink-B3HIQYFh.js +1 -0
- package/dist/client/assets/ThreadStatusIndicators-CQZ_OgY8.js +0 -0
- package/dist/client/assets/{ThreadTerminalDrawer-ro03rSMk.js → ThreadTerminalDrawer-D1SPewXR.js} +3 -3
- package/dist/client/assets/ThreadWorkspacePanel-DVF6oZsV.js +2009 -0
- package/dist/client/assets/ToolbarRootContext-Dt8G5aCw.js +1 -0
- package/dist/client/assets/{WorkItemsTab-CBbr_lPX.js → WorkItemsTab-BoE-TcXJ.js} +8 -8
- package/dist/client/assets/{activity-1CkdQG5u.js → activity-DfFM6I8A.js} +1 -1
- package/dist/client/assets/alert-DE5SkZhr.js +1 -0
- package/dist/client/assets/alert-dialog-BqPnPhb6.js +1 -0
- package/dist/client/assets/appChrome-CJauXpqv.js +1 -0
- package/dist/client/assets/{archive-BL1hojl3.js → archive-BFV4YQ7D.js} +1 -1
- package/dist/client/assets/arrow-left-CCmICk1t.js +1 -0
- package/dist/client/assets/arrow-right-Z3Eay6Fd.js +1 -0
- package/dist/client/assets/{arrow-up-CTcWIlqV.js → arrow-up-caak6P06.js} +1 -1
- package/dist/client/assets/arrow-up-right-BwC-fCE4.js +1 -0
- package/dist/client/assets/authorization-bHsGYIT0.js +1 -0
- package/dist/client/assets/{badge-DUe5V2Mj.js → badge-m9kM3P07.js} +1 -1
- package/dist/client/assets/{bot-DJp0cuhK.js → bot-Cv7a7Ksf.js} +1 -1
- package/dist/client/assets/{button-BdUaa4U1.js → button-B6xQZNKz.js} +1 -1
- package/dist/client/assets/capabilities-D6bsjqkj.js +1 -0
- package/dist/client/assets/{chart-column-Dw6ACmXM.js → chart-column-DgGlY4sD.js} +1 -1
- package/dist/client/assets/chatThreadActions-BXaNbPbp.js +1 -0
- package/dist/client/assets/check-BfnWUGBT.js +1 -0
- package/dist/client/assets/{chevron-down-B7C6FKzM.js → chevron-down-B_FKCRVh.js} +1 -1
- package/dist/client/assets/chevron-right-B6CKNGh4.js +1 -0
- package/dist/client/assets/{circle-alert-BWvs6IOn.js → circle-alert-BV3vJE-c.js} +1 -1
- package/dist/client/assets/circle-check-D2Vx39x-.js +1 -0
- package/dist/client/assets/{external-link-fbvzDWM7.js → circle-dashed-khcA8K3Y.js} +1 -1
- package/dist/client/assets/circle-question-mark-DEuLdOiy.js +1 -0
- package/dist/client/assets/circle-x-DqfM_2wS.js +1 -0
- package/dist/client/assets/clamp-D0kAXd-u.js +1 -0
- package/dist/client/assets/{clipboard-copy-C4VV20QR.js → clipboard-copy-CiD4tBsh.js} +1 -1
- package/dist/client/assets/clock--4M7moiV.js +1 -0
- package/dist/client/assets/clock-3-NbnQqtcd.js +1 -0
- package/dist/client/assets/collapsible-BECg-ssO.js +1 -0
- package/dist/client/assets/command-DvbA3O0J.js +1 -0
- package/dist/client/assets/{copy-UQjKGt7t.js → copy-CkPe1c-r.js} +1 -1
- package/dist/client/assets/data-list-7TiaqfZU.js +1 -0
- package/dist/client/assets/desktopUpdateAtoms-6j0d8vfy.js +1 -0
- package/dist/client/assets/desktopWorkspace-8s8rm3zL.js +1 -0
- package/dist/client/assets/device-CGaJ6fwD.js +168 -0
- package/dist/client/assets/dialog-C9v8Zl6e.js +1 -0
- package/dist/client/assets/{download-CQZ-m4zW.js → download-DPjzVxTa.js} +1 -1
- package/dist/client/assets/draft-input-BRSLIjV6.js +1 -0
- package/dist/client/assets/editorPreferences-D-9SDgRM.js +1 -0
- package/dist/client/assets/empty-CuQ57p2u.js +1 -0
- package/dist/client/assets/external-link-CF9EzT-A.js +1 -0
- package/dist/client/assets/{eye-CUSPj-gd.js → eye-C2Puut9B.js} +1 -1
- package/dist/client/assets/{folder-DtsQoI9_.js → folder-BKTxLq18.js} +1 -1
- package/dist/client/assets/{folder-closed-CsvKfC6X.js → folder-closed-D2cwiusg.js} +1 -1
- package/dist/client/assets/getPseudoElementBounds-DdH76YK5.js +1 -0
- package/dist/client/assets/{git-branch-BKr-Ij4u.js → git-branch-Dauy2SWC.js} +1 -1
- package/dist/client/assets/{git-pull-request-DIYyPsg5.js → git-pull-request-DsK1gBtK.js} +1 -1
- package/dist/client/assets/globe-dS40wBdE.js +1 -0
- package/dist/client/assets/group-DBXm8riE.js +1 -0
- package/dist/client/assets/hostedConnectionCoordinator-DSMW2Ldh.js +1 -0
- package/dist/client/assets/{index-CQJvt69U.js → index-DRY8Hgrj.js} +2 -2
- package/dist/client/assets/input-Dn_zesdZ.js +1 -0
- package/dist/client/assets/kbd-BF2-WlxQ.js +1 -0
- package/dist/client/assets/{key-round-CacMputS.js → key-round-BjaaL9Df.js} +1 -1
- package/dist/client/assets/{keybindings-DCgzArdM.js → keybindings-FSJY3Tht.js} +1 -1
- package/dist/client/assets/{keyboard-BqeRMHfL.js → keyboard-AkUFPD_e.js} +1 -1
- package/dist/client/assets/label-BKjVY2A9.js +1 -0
- package/dist/client/assets/{layers-BYi0v17h.js → layers-tzRiuxSx.js} +1 -1
- package/dist/client/assets/{lib-B7pkMeOn.js → lib-D5cyGc84.js} +1 -1
- package/dist/client/assets/{loader-zHASMrUy.js → loader-BrbWRz3I.js} +1 -1
- package/dist/client/assets/loader-circle-DRKbHQst.js +1 -0
- package/dist/client/assets/{log-out-tMJm0Gk6.js → log-out-BEihaal1.js} +1 -1
- package/dist/client/assets/{logging-B1VrUJXw.js → logging-Y73f240E.js} +1 -1
- package/dist/client/assets/main-BiIQEybS.js +9 -0
- package/dist/client/assets/main-tZWU6iqX.css +2 -0
- package/dist/client/assets/menu-BxtB33Up.js +1 -0
- package/dist/client/assets/{messages-square-DiMgWzoq.js → messages-square-e0Zg750i.js} +1 -1
- package/dist/client/assets/{minimize-2-C33mL7LT.js → minimize-2-DC9gMgGl.js} +1 -1
- package/dist/client/assets/monitor-Dj0JFj4_.js +1 -0
- package/dist/client/assets/{palette-BSD_aJZg.js → palette-0qvNt1CR.js} +1 -1
- package/dist/client/assets/{pencil-B69ERoVM.js → pencil-CA0DGufX.js} +1 -1
- package/dist/client/assets/{play-DYDxlTKo.js → play-wIyvqd_g.js} +1 -1
- package/dist/client/assets/plus-5kH13lqq.js +1 -0
- package/dist/client/assets/popover-CwhgX3HA.js +1 -0
- package/dist/client/assets/primary-BqnEJHWx.js +2 -0
- package/dist/client/assets/{projectPaths-C7IGaRXO.js → projectPaths-45WPhgoj.js} +1 -1
- package/dist/client/assets/providerDriverMeta-Cc60r9Rb.js +1 -0
- package/dist/client/assets/providerInstances-Cr8JmFCe.js +1 -0
- package/dist/client/assets/providerModels-Cr8JmFCe.js +1 -0
- package/dist/client/assets/qr-code-BKrwYZ2s.js +1 -0
- package/dist/client/assets/{qr-code-ScYULAuR.js → qr-code-DDmpRnPp.js} +1 -1
- package/dist/client/assets/radio-group-DZCo21CF.js +2 -0
- package/dist/client/assets/{refresh-cw-DopCMrtR.js → refresh-cw-DiuiLTny.js} +1 -1
- package/dist/client/assets/resolveAriaLabelledBy-927ShlEO.js +1 -0
- package/dist/client/assets/rightPanelRouteSearch-CExl-IaQ.js +1 -0
- package/dist/client/assets/rotate-ccw-XOYBPtyK.js +1 -0
- package/dist/client/assets/rotate-cw-D32Z4Sdd.js +1 -0
- package/dist/client/assets/runtime-CA2W9mZ-.js +17 -0
- package/dist/client/assets/{save-Bh36JIv6.js → save-DjlqeVG_.js} +1 -1
- package/dist/client/assets/scroll-area-CylKYQms.js +1 -0
- package/dist/client/assets/scrollEdges-D7RQhYjX.js +1 -0
- package/dist/client/assets/search-B2nLj573.js +1 -0
- package/dist/client/assets/select-qTezUK8F.js +1 -0
- package/dist/client/assets/separator-D77goPy-.js +1 -0
- package/dist/client/assets/{server-JApJpgLa.js → server-y8Wq0Qwv.js} +1 -1
- package/dist/client/assets/session-logic-xfW418Rx.js +1 -0
- package/dist/client/assets/{settings-2-CZQg_KUQ.js → settings-2-DpwBKj3m.js} +1 -1
- package/dist/client/assets/settingsLayout-BuaXzjIe.js +1 -0
- package/dist/client/assets/settingsSections.logic-CR4aytUI.js +1 -0
- package/dist/client/assets/sheet-z3AEiSN4.js +1 -0
- package/dist/client/assets/{shield-IZEIJ8r7.js → shield-BuXuMVtb.js} +1 -1
- package/dist/client/assets/{shield-alert-DY9uVP5G.js → shield-alert-Dfk--o-I.js} +1 -1
- package/dist/client/assets/{shield-check-dQ-4cMKk.js → shield-check-BHi57iF1.js} +1 -1
- package/dist/client/assets/sidebar-Dst9O2OR.js +1 -0
- package/dist/client/assets/sidebarProjectFolders-DR1NBLLz.js +4 -0
- package/dist/client/assets/{sidebarStatusText-WiaEF1ae.js → sidebarStatusText-7jo1n9E1.js} +1 -1
- package/dist/client/assets/skeleton-D_kbMg21.js +1 -0
- package/dist/client/assets/{smartphone-gNe1ynB8.js → smartphone-DcUQ17YT.js} +1 -1
- package/dist/client/assets/{sparkles-CAf3oJ5S.js → sparkles-nVLLtdqb.js} +1 -1
- package/dist/client/assets/spinner-CkXSwhuf.js +1 -0
- package/dist/client/assets/{square-pen-Bj3p_Q8E.js → square-pen-dcArpda7.js} +1 -1
- package/dist/client/assets/src-I4s4HU8f.js +14 -0
- package/dist/client/assets/star-CdUOqzzZ.js +1 -0
- package/dist/client/assets/storeSelectors-Cr8JmFCe.js +1 -0
- package/dist/client/assets/switch-BMeRsIbg.js +1 -0
- package/dist/client/assets/{tabSwitchInstrumentation-CLDM7g1_.js → tabSwitchInstrumentation-BuxWNdCV.js} +1 -1
- package/dist/client/assets/terminal-DupJfYRW.js +1 -0
- package/dist/client/assets/{terminal-links-Bxew8m4Q.js → terminal-links-Bf4neyyn.js} +1 -1
- package/dist/client/assets/textarea-Bu_OTJYe.js +1 -0
- package/dist/client/assets/threadPinning-DhnkssEa.js +1 -0
- package/dist/client/assets/{threadPriorityRefreshRuntime-Cgjn5Y-7.js → threadPriorityRefreshRuntime-DJjlyX7f.js} +1 -1
- package/dist/client/assets/toast-CIjfIWUw.js +1 -0
- package/dist/client/assets/toggle-BA4mJ5v9.js +1 -0
- package/dist/client/assets/toggle-group-ChGfILTR.js +1 -0
- package/dist/client/assets/{tokenModePresentation-lVM0-Wi3.js → tokenModePresentation-B64s_OK3.js} +1 -1
- package/dist/client/assets/tooltip-C2VVqN6U.js +1 -0
- package/dist/client/assets/{trash-2-CM1zXPGb.js → trash-2-Dqgxd0nF.js} +1 -1
- package/dist/client/assets/{triangle-alert-RL_T3KLo.js → triangle-alert-D4cCh6sB.js} +1 -1
- package/dist/client/assets/types-Cr8JmFCe.js +1 -0
- package/dist/client/assets/{undo-2-x37tfI3V.js → undo-2-C8EQVSSD.js} +1 -1
- package/dist/client/assets/{unplug-Cw8iawyX.js → unplug-Dt3Sy2op.js} +1 -1
- package/dist/client/assets/useAppSidebarCollapsed-w0th-164.js +1 -0
- package/dist/client/assets/{useAtlassian-BPNtoDXL.js → useAtlassian-j7ex3bVN.js} +0 -0
- package/dist/client/assets/useButton-Dx5k1uZG.js +1 -0
- package/dist/client/assets/useCompositeListItem-BqkyY0oT.js +1 -0
- package/dist/client/assets/{clamp-CgH0Dl6R.js → useControlled-HocCF1v9.js} +1 -1
- package/dist/client/assets/useDebouncedValue-BevbEbPO.js +1 -0
- package/dist/client/assets/useFloatingRootContext-j6TgzEFa.js +1 -0
- package/dist/client/assets/useHandleNewThread-gVYty_Bg.js +1 -0
- package/dist/client/assets/useLabelableId-CcYPzJvj.js +1 -0
- package/dist/client/assets/useLocation-CZ3osOgz.js +1 -0
- package/dist/client/assets/useOpenInteractionType-apbY9ZEK.js +1 -0
- package/dist/client/assets/usePhoneThreadActions-CnDlicSp.js +1 -0
- package/dist/client/assets/usePopupViewport-0k75uXo1.js +1 -0
- package/dist/client/assets/useRenderElement-5DRNLBaU.js +1 -0
- package/dist/client/assets/useScrollLock-C5WLWXcc.js +1 -0
- package/dist/client/assets/{useStatistics-BQkcb-1_.js → useStatistics-GOFXPHO0.js} +2 -2
- package/dist/client/assets/useSwipeDismiss-BNHPBucH.js +1 -0
- package/dist/client/assets/useThreadActions-B4Xy2soQ.js +2 -0
- package/dist/client/assets/useTriggerFocusGuards-C3geWFzt.js +1 -0
- package/dist/client/assets/useValueChanged-FVqPwcY_.js +1 -0
- package/dist/client/assets/user-round-KsVtJgon.js +1 -0
- package/dist/client/assets/utils-B5qahmRn.js +1 -0
- package/dist/client/assets/visuallyHidden-j2WbVEv-.js +1 -0
- package/dist/client/assets/workspaceMetadataProjection-D3vqw40g.js +1 -0
- package/dist/client/assets/{wrench-D0IetWa1.js → wrench-BnpoYEZm.js} +1 -1
- package/dist/client/assets/x-BXHT1Zj1.js +1 -0
- package/dist/client/index.html +1 -1
- package/dist/{collectUint8StreamText-D8TBiBWk.mjs → collectUint8StreamText-C_VNyArd.mjs} +614 -20
- package/dist/{collectUint8StreamText-C5fop6Zf.cjs → collectUint8StreamText-DStwNTTK.cjs} +679 -19
- package/dist/{makeManagedServerProvider-DRlNwlhe.mjs → makeManagedServerProvider-GZcpSLrW.mjs} +22 -3
- package/dist/{makeManagedServerProvider-BytnBN6b.cjs → makeManagedServerProvider-VzxWN-04.cjs} +32 -1
- package/dist/resource-monitor/LICENSE +21 -0
- package/dist/resource-monitor/darwin-arm64/LICENSE +21 -0
- package/dist/resource-monitor/darwin-arm64/ryco-resource-monitor +0 -0
- package/dist/resource-monitor/darwin-x64/LICENSE +21 -0
- package/dist/resource-monitor/darwin-x64/ryco-resource-monitor +0 -0
- package/dist/resource-monitor/linux-arm64/LICENSE +21 -0
- package/dist/resource-monitor/linux-arm64/ryco-resource-monitor +0 -0
- package/dist/resource-monitor/linux-x64/LICENSE +21 -0
- package/dist/resource-monitor/linux-x64/ryco-resource-monitor +0 -0
- package/dist/resource-monitor/ryco-resource-monitor +0 -0
- package/dist/resource-monitor/ryco-resource-monitor.exe +0 -0
- package/dist/resource-monitor/win32-arm64/LICENSE +21 -0
- package/dist/resource-monitor/win32-arm64/ryco-resource-monitor.exe +0 -0
- package/dist/resource-monitor/win32-x64/LICENSE +21 -0
- package/dist/resource-monitor/win32-x64/ryco-resource-monitor.exe +0 -0
- package/package.json +1 -1
- package/dist/client/assets/AccountSettings--RGb4Xyh.js +0 -1
- package/dist/client/assets/AiFocusSettings-BnGcbAMj.js +0 -1
- package/dist/client/assets/AnimatedHeight-xBldRJT_.js +0 -1
- package/dist/client/assets/AppearanceSettings-BZRfC5N0.js +0 -1
- package/dist/client/assets/BranchToolbar.logic-CGpYXkLE.js +0 -1
- package/dist/client/assets/ChatRightPanel-BlooofmF.js +0 -27
- package/dist/client/assets/ChatThreadRouteView-B28bv4Zt.js +0 -1
- package/dist/client/assets/CommandPaletteDialog-hNEraTe2.js +0 -1
- package/dist/client/assets/CompositeItem-CKY4wPzb.js +0 -1
- package/dist/client/assets/CompositeRoot-Ds7U4w5S.js +0 -1
- package/dist/client/assets/ConnectionsSettings-C4VqR67L.js +0 -7
- package/dist/client/assets/DiagnosticsSettings-ByZ42-mW.js +0 -2
- package/dist/client/assets/DialogHandle-BdmgCiER.js +0 -1
- package/dist/client/assets/DialogPopup-D6m8w7-0.js +0 -1
- package/dist/client/assets/DialogRoot-BnE2_J9j.js +0 -1
- package/dist/client/assets/DialogTitle-DFkPQ5wa.js +0 -1
- package/dist/client/assets/DialogTrigger-CTCt2xVs.js +0 -1
- package/dist/client/assets/DialogViewport-OqbNjTEg.js +0 -1
- package/dist/client/assets/DraftChatThreadRouteView-B_4VVh8J.js +0 -1
- package/dist/client/assets/HostedConnectionControls-D0YyFVVm.js +0 -1
- package/dist/client/assets/HostedHubRoot-gr9o6h-w.js +0 -1
- package/dist/client/assets/HostedNativeAuthorizationRoute-DQy7gPHg.js +0 -1
- package/dist/client/assets/HostedRelayTrustNotice-DtiCe1oF.js +0 -1
- package/dist/client/assets/Icons-BHigZ6eO.js +0 -1
- package/dist/client/assets/IntegrationsSettingsPanel-RgmTIo_4.js +0 -1
- package/dist/client/assets/KeybindingsSettings-2J94301x.js +0 -7
- package/dist/client/assets/MobileSheet-5RNq1fWV.js +0 -1
- package/dist/client/assets/NewWorktreeDialog-BE_53fbt.js +0 -4
- package/dist/client/assets/NoActiveThreadState-Cpar0wiW.js +0 -1
- package/dist/client/assets/NodeSecuritySettings-BpZYwf5z.js +0 -1
- package/dist/client/assets/OpinionatedPluginsSettings-CLbbw_K_.js +0 -1
- package/dist/client/assets/PhoneGetAppInterstitial-G1mx30Rm.js +0 -1
- package/dist/client/assets/PhoneGetAppInterstitialBackdrop-nfP93au3.js +0 -1
- package/dist/client/assets/PhoneHome-D24dskaK.js +0 -1
- package/dist/client/assets/PhoneSettingsSurface-DU6QcRMa.js +0 -1
- package/dist/client/assets/ProjectFavicon-DiAvCEOv.js +0 -1
- package/dist/client/assets/ProviderModelPicker-KKoDIb0I.js +0 -1
- package/dist/client/assets/ProvidersSettingsPanel-Cotp9jkx.js +0 -1
- package/dist/client/assets/RedactedSensitiveText-Bijn-7t0.js +0 -1
- package/dist/client/assets/RootAppShell-BPFAVRor.js +0 -6
- package/dist/client/assets/RycoLetterMark-DDqdXSCR.js +0 -1
- package/dist/client/assets/SettingsDialog-C1pQqIpt.js +0 -1
- package/dist/client/assets/SettingsPanels-_z4Xw8vV.js +0 -3
- package/dist/client/assets/SettingsPanels.editor-CFrJ6eJl.js +0 -1
- package/dist/client/assets/SourceControlSettings-aZXtdyQJ.js +0 -1
- package/dist/client/assets/StatisticsPage-DLxnsLkl.js +0 -1
- package/dist/client/assets/StatisticsPanel-CZng52aF.js +0 -1
- package/dist/client/assets/StatisticsSettingsLink-BswiD6v1.js +0 -1
- package/dist/client/assets/ThreadStatusIndicators-Dg7ByO0t.js +0 -0
- package/dist/client/assets/ThreadWorkspacePanel-j_muuK0U.js +0 -2009
- package/dist/client/assets/ToolbarRootContext-gBA5VTsh.js +0 -1
- package/dist/client/assets/alert-DM55UBFJ.js +0 -1
- package/dist/client/assets/alert-dialog-t0tth9lg.js +0 -1
- package/dist/client/assets/arrow-left-Dtj9PfsA.js +0 -1
- package/dist/client/assets/arrow-up-right-DGeet8e6.js +0 -1
- package/dist/client/assets/authorization-jiPI8hG1.js +0 -1
- package/dist/client/assets/branding-31Bj-8ZC.js +0 -1
- package/dist/client/assets/capabilities-DQDkV1US.js +0 -1
- package/dist/client/assets/chatThreadActions-3VwZmcuQ.js +0 -1
- package/dist/client/assets/chevron-right-BWYGybX9.js +0 -1
- package/dist/client/assets/clock-3-r12DkpRj.js +0 -1
- package/dist/client/assets/clock-nNA05brA.js +0 -1
- package/dist/client/assets/collapsible-BmAgbTeN.js +0 -1
- package/dist/client/assets/command-8YtR6jmS.js +0 -1
- package/dist/client/assets/composerDraftStore-Bz5WIZBE.js +0 -11
- package/dist/client/assets/data-list-D7UF_rKC.js +0 -1
- package/dist/client/assets/desktopUpdateAtoms-D_GMRE2r.js +0 -1
- package/dist/client/assets/desktopWorkspace-Dg6EeBlb.js +0 -1
- package/dist/client/assets/device-DlExHdp_.js +0 -168
- package/dist/client/assets/dialog-B0sUgnpe.js +0 -1
- package/dist/client/assets/draft-input-CljKajxE.js +0 -1
- package/dist/client/assets/editorPreferences-B3qgjPa6.js +0 -1
- package/dist/client/assets/empty-D5W-VFFg.js +0 -1
- package/dist/client/assets/env-3rzMJf1D.js +0 -1
- package/dist/client/assets/folder-open-GqwNTbSV.js +0 -1
- package/dist/client/assets/getPseudoElementBounds-BAmGtfzA.js +0 -1
- package/dist/client/assets/group-BQB2fHcw.js +0 -1
- package/dist/client/assets/input-5Gxk32uP.js +0 -1
- package/dist/client/assets/kbd-B4HCyWpi.js +0 -1
- package/dist/client/assets/label-CaZNWVUA.js +0 -1
- package/dist/client/assets/loader-circle-CrtHFAvM.js +0 -1
- package/dist/client/assets/main-BPfnkW0F.js +0 -9
- package/dist/client/assets/main-DspUYA0Y.css +0 -2
- package/dist/client/assets/menu-C9Z3D_7l.js +0 -1
- package/dist/client/assets/plus-B2h-VEqh.js +0 -1
- package/dist/client/assets/popover-CCz2VJor.js +0 -1
- package/dist/client/assets/primary-BMsRfh2b.js +0 -2
- package/dist/client/assets/providerDriverMeta-CgWTJ9AV.js +0 -1
- package/dist/client/assets/providerIconUtils-DKIWQBl_.js +0 -1
- package/dist/client/assets/providerInstances-DTwJD7w4.js +0 -1
- package/dist/client/assets/providerModels-DTwJD7w4.js +0 -1
- package/dist/client/assets/qr-code-BPTdK_Fr.js +0 -1
- package/dist/client/assets/radio-group-2REtGBUc.js +0 -2
- package/dist/client/assets/resolveAriaLabelledBy-CPzaFh9Q.js +0 -1
- package/dist/client/assets/rightPanelRouteSearch-Cv7sQjf8.js +0 -1
- package/dist/client/assets/runtime-DAfYpzw4.js +0 -1
- package/dist/client/assets/scroll-area-BsYcpnWD.js +0 -1
- package/dist/client/assets/scrollEdges-CUJFIJBP.js +0 -1
- package/dist/client/assets/search-BGQsenCM.js +0 -1
- package/dist/client/assets/select-zInJ5G5C.js +0 -1
- package/dist/client/assets/separator-CsdeZPxC.js +0 -1
- package/dist/client/assets/session-logic-CjEpVbpM.js +0 -6
- package/dist/client/assets/settingsDialogStore-B7yUTgbo.js +0 -1
- package/dist/client/assets/settingsLayout-7JR7nC6x.js +0 -1
- package/dist/client/assets/settingsSections.logic-F8RXVmAq.js +0 -1
- package/dist/client/assets/sheet-CLd8wqAA.js +0 -1
- package/dist/client/assets/sidebar-BliCAaUG.js +0 -1
- package/dist/client/assets/sidebarProjectFolders-ScxWbdTn.js +0 -4
- package/dist/client/assets/skeleton-B_qDqbso.js +0 -1
- package/dist/client/assets/spinner-BlCG_0jN.js +0 -1
- package/dist/client/assets/src-Chx4ffXH.js +0 -14
- package/dist/client/assets/storeSelectors-Of4FM0vM.js +0 -1
- package/dist/client/assets/switch-DUT5lUyk.js +0 -1
- package/dist/client/assets/terminal-C_CyIsDD.js +0 -1
- package/dist/client/assets/textarea-C5eyaBI3.js +0 -1
- package/dist/client/assets/threadPinning-B8un4fjx.js +0 -1
- package/dist/client/assets/toast-X_O6OBAx.js +0 -1
- package/dist/client/assets/toggle-P-wZyQFO.js +0 -1
- package/dist/client/assets/toggle-group-Du7zfd4_.js +0 -1
- package/dist/client/assets/tooltip-D_i-87PL.js +0 -1
- package/dist/client/assets/types-Of4FM0vM.js +0 -1
- package/dist/client/assets/uiStateStore-UUXKrPLz.js +0 -1
- package/dist/client/assets/useButton-D8BjCVb-.js +0 -1
- package/dist/client/assets/useCompositeListItem-BHuxHR8U.js +0 -1
- package/dist/client/assets/useDebouncedValue-D2-9M4Tq.js +0 -1
- package/dist/client/assets/useFloatingRootContext-CTdmlYcf.js +0 -1
- package/dist/client/assets/useHandleNewThread-YGjWitl4.js +0 -1
- package/dist/client/assets/useLabelableId-LInf_Egz.js +0 -1
- package/dist/client/assets/useLocation-3zGT25DO.js +0 -1
- package/dist/client/assets/useOpenInteractionType-BPthQeg6.js +0 -1
- package/dist/client/assets/usePhoneThreadActions-D_Z29f6p.js +0 -1
- package/dist/client/assets/usePopupViewport-BErrsN0k.js +0 -1
- package/dist/client/assets/useRenderElement-DchFnsR8.js +0 -1
- package/dist/client/assets/useScrollLock-CLyJPg7p.js +0 -1
- package/dist/client/assets/useSwipeDismiss-DjMT1XiU.js +0 -1
- package/dist/client/assets/useThreadActions-ISbVGkmx.js +0 -2
- package/dist/client/assets/useTriggerFocusGuards-DwOHWbrB.js +0 -1
- package/dist/client/assets/useValueChanged-Bq39JB8D.js +0 -1
- package/dist/client/assets/user-round-Cpzx8pSw.js +0 -1
- package/dist/client/assets/utils-BFbDkTQq.js +0 -1
- package/dist/client/assets/visibilityPolling-BwzZdaSN.js +0 -1
- package/dist/client/assets/x-C1Cemsov.js +0 -1
|
@@ -1,15 +1,21 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
|
|
3
|
-
const require_collectUint8StreamText = require("./collectUint8StreamText-
|
|
3
|
+
const require_collectUint8StreamText = require("./collectUint8StreamText-DStwNTTK.cjs");
|
|
4
4
|
const require_Metrics = require("./Metrics-DIjMQ5pa.cjs");
|
|
5
5
|
const require_bin = require("./bin.cjs");
|
|
6
|
-
const require_makeManagedServerProvider = require("./makeManagedServerProvider-
|
|
6
|
+
const require_makeManagedServerProvider = require("./makeManagedServerProvider-VzxWN-04.cjs");
|
|
7
7
|
const require_ProviderDriver = require("./ProviderDriver--rNeAi3B.cjs");
|
|
8
|
-
const require_CodexTextGeneration = require("./CodexTextGeneration-
|
|
8
|
+
const require_CodexTextGeneration = require("./CodexTextGeneration-B4tJTUDo.cjs");
|
|
9
9
|
let effect = require("effect");
|
|
10
10
|
let node_crypto = require("node:crypto");
|
|
11
11
|
require("effect/unstable/process");
|
|
12
12
|
let _github_copilot_sdk = require("@github/copilot-sdk");
|
|
13
|
+
//#region src/provider/Layers/CopilotAdapter.eventScope.ts
|
|
14
|
+
/** Wildcard SDK subscriptions include child events, including their turn and abort events. */
|
|
15
|
+
function isCopilotChildEvent(event) {
|
|
16
|
+
return Boolean(event.agentId || "parentToolCallId" in event.data && event.data.parentToolCallId);
|
|
17
|
+
}
|
|
18
|
+
//#endregion
|
|
13
19
|
//#region src/provider/Layers/CopilotAdapter.types.ts
|
|
14
20
|
const COPILOT_DRIVER_KIND = require_collectUint8StreamText.ProviderDriverKind.make("copilot");
|
|
15
21
|
const DEFAULT_BINARY_PATH = "copilot";
|
|
@@ -200,6 +206,9 @@ function selectionTargetsCopilotInstance(value, instanceId) {
|
|
|
200
206
|
}
|
|
201
207
|
//#endregion
|
|
202
208
|
//#region src/provider/Layers/CopilotAdapter.mapEvent.ts
|
|
209
|
+
function nonNegativeCount(value) {
|
|
210
|
+
return value !== void 0 && Number.isSafeInteger(value) && value >= 0 ? value : void 0;
|
|
211
|
+
}
|
|
203
212
|
const mapEvent = (deps, session, event) => effect.Effect.gen(function* () {
|
|
204
213
|
const turnId = session.activeTurnId;
|
|
205
214
|
const stamp = yield* deps.makeEventStamp();
|
|
@@ -208,6 +217,57 @@ const mapEvent = (deps, session, event) => effect.Effect.gen(function* () {
|
|
|
208
217
|
method: event.type,
|
|
209
218
|
payload: event
|
|
210
219
|
};
|
|
220
|
+
if (event.type === "subagent.started" || event.type === "subagent.completed" || event.type === "subagent.failed") {
|
|
221
|
+
const data = event.data;
|
|
222
|
+
const linkage = {
|
|
223
|
+
taskId: require_collectUint8StreamText.RuntimeTaskId.make(`copilot-task:${data.toolCallId}`),
|
|
224
|
+
taskType: "subagent",
|
|
225
|
+
title: data.agentDisplayName.trim() || data.agentName.trim() || "Copilot agent",
|
|
226
|
+
...data.agentName.trim() ? { role: data.agentName.trim() } : {},
|
|
227
|
+
...data.model?.trim() ? { model: data.model.trim() } : {},
|
|
228
|
+
toolUseId: data.toolCallId
|
|
229
|
+
};
|
|
230
|
+
const base = eventBase({
|
|
231
|
+
eventId: stamp.eventId,
|
|
232
|
+
createdAt: event.timestamp,
|
|
233
|
+
threadId: session.threadId,
|
|
234
|
+
providerInstanceId: session.providerInstanceId,
|
|
235
|
+
...turnId ? { turnId } : {},
|
|
236
|
+
raw
|
|
237
|
+
});
|
|
238
|
+
if (event.type === "subagent.started") return [{
|
|
239
|
+
...base,
|
|
240
|
+
type: "task.started",
|
|
241
|
+
payload: {
|
|
242
|
+
...linkage,
|
|
243
|
+
...event.data.agentDescription.trim() ? { description: event.data.agentDescription.trim() } : {}
|
|
244
|
+
}
|
|
245
|
+
}];
|
|
246
|
+
const terminal = event.data;
|
|
247
|
+
const totalTokens = nonNegativeCount(terminal.totalTokens);
|
|
248
|
+
const toolUses = nonNegativeCount(terminal.totalToolCalls);
|
|
249
|
+
const durationMs = nonNegativeCount(terminal.durationMs);
|
|
250
|
+
const usage = {
|
|
251
|
+
...totalTokens !== void 0 ? { totalTokens } : {},
|
|
252
|
+
...toolUses !== void 0 ? { toolUses } : {},
|
|
253
|
+
...durationMs !== void 0 ? { durationMs } : {}
|
|
254
|
+
};
|
|
255
|
+
return [{
|
|
256
|
+
...base,
|
|
257
|
+
type: "task.completed",
|
|
258
|
+
payload: {
|
|
259
|
+
...linkage,
|
|
260
|
+
status: event.type === "subagent.failed" ? "failed" : event.data.cancelled ? "stopped" : "completed",
|
|
261
|
+
...event.type === "subagent.failed" && event.data.error.trim() ? { summary: event.data.error.trim() } : {},
|
|
262
|
+
...Object.keys(usage).length > 0 ? { usage } : {},
|
|
263
|
+
...totalTokens !== void 0 ? { typedUsage: {
|
|
264
|
+
...usage,
|
|
265
|
+
totalTokens
|
|
266
|
+
} } : {}
|
|
267
|
+
}
|
|
268
|
+
}];
|
|
269
|
+
}
|
|
270
|
+
if (isCopilotChildEvent(event)) return [];
|
|
211
271
|
switch (event.type) {
|
|
212
272
|
case "assistant.turn_start": {
|
|
213
273
|
const eventTurnId = require_collectUint8StreamText.TurnId.make(event.data.turnId);
|
|
@@ -294,18 +354,40 @@ const mapEvent = (deps, session, event) => effect.Effect.gen(function* () {
|
|
|
294
354
|
data: event.data
|
|
295
355
|
}
|
|
296
356
|
}];
|
|
297
|
-
case "
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
357
|
+
case "session.usage_info":
|
|
358
|
+
case "assistant.usage":
|
|
359
|
+
if (event.type === "session.usage_info") {
|
|
360
|
+
const { currentTokens, tokenLimit } = event.data;
|
|
361
|
+
if (!Number.isSafeInteger(currentTokens) || currentTokens < 0 || !Number.isSafeInteger(tokenLimit) || tokenLimit <= 0) return [];
|
|
362
|
+
session.contextUsage = {
|
|
363
|
+
usedTokens: currentTokens,
|
|
364
|
+
maxTokens: tokenLimit
|
|
365
|
+
};
|
|
366
|
+
session.lastUsage = {
|
|
367
|
+
...session.lastUsage,
|
|
368
|
+
...session.contextUsage,
|
|
369
|
+
lastUsedTokens: currentTokens
|
|
370
|
+
};
|
|
371
|
+
} else {
|
|
372
|
+
if (event.data.parentToolCallId || event.data.initiator || event.data.interactionType && !["conversation-agent", "conversation-user"].includes(event.data.interactionType)) return [];
|
|
373
|
+
session.lastUsage = {
|
|
374
|
+
...normalizeUsage(event),
|
|
375
|
+
...session.contextUsage,
|
|
376
|
+
...session.contextUsage ? { lastUsedTokens: session.contextUsage.usedTokens } : {}
|
|
377
|
+
};
|
|
378
|
+
}
|
|
379
|
+
return [{
|
|
380
|
+
...eventBase({
|
|
381
|
+
eventId: stamp.eventId,
|
|
382
|
+
createdAt: event.timestamp,
|
|
383
|
+
threadId: session.threadId,
|
|
384
|
+
providerInstanceId: session.providerInstanceId,
|
|
385
|
+
...turnId ? { turnId } : {},
|
|
386
|
+
raw
|
|
387
|
+
}),
|
|
388
|
+
type: "thread.token-usage.updated",
|
|
389
|
+
payload: { usage: session.lastUsage }
|
|
390
|
+
}];
|
|
309
391
|
case "session.idle": {
|
|
310
392
|
const readyEventId = yield* deps.nextEventId;
|
|
311
393
|
return [{
|
|
@@ -456,7 +538,7 @@ function parseResumeCursor(resumeCursor) {
|
|
|
456
538
|
return typeof resumeCursor === "object" && resumeCursor !== null && "sessionId" in resumeCursor && typeof resumeCursor.sessionId === "string" && resumeCursor.sessionId.trim().length > 0 ? resumeCursor.sessionId.trim() : void 0;
|
|
457
539
|
}
|
|
458
540
|
function attachmentMimeType(attachment) {
|
|
459
|
-
return attachment.mimeType;
|
|
541
|
+
return attachment.mimeType ?? "application/octet-stream";
|
|
460
542
|
}
|
|
461
543
|
function createTurnStartWaiter(record) {
|
|
462
544
|
let timeout;
|
|
@@ -614,8 +696,10 @@ const makeStartSession = (deps) => (input) => effect.Effect.gen(function* () {
|
|
|
614
696
|
attachSession: (nextSession) => {
|
|
615
697
|
record.unsubscribe();
|
|
616
698
|
record.session = nextSession;
|
|
699
|
+
delete record.contextUsage;
|
|
700
|
+
record.lastUsage = void 0;
|
|
617
701
|
record.unsubscribe = nextSession.on((event) => {
|
|
618
|
-
if (event.type === "assistant.turn_start") {
|
|
702
|
+
if (event.type === "assistant.turn_start" && !isCopilotChildEvent(event)) {
|
|
619
703
|
activeTurn = require_collectUint8StreamText.TurnId.make(event.data.turnId);
|
|
620
704
|
record.activeTurnId = activeTurn;
|
|
621
705
|
for (const pending of Array.from(record.pendingTurnStarts)) pending.resolve(activeTurn);
|
|
@@ -667,14 +751,19 @@ const makeStartSession = (deps) => (input) => effect.Effect.gen(function* () {
|
|
|
667
751
|
}).pipe(effect.Effect.onError(() => effect.Effect.sync(() => deps.sessions.get(input.threadId)?.agentControl).pipe(effect.Effect.flatMap((connection) => connection ? connection.revoke("runtime-teardown") : effect.Effect.void))));
|
|
668
752
|
const makeSendTurn = (deps) => (input) => effect.Effect.gen(function* () {
|
|
669
753
|
const record = yield* deps.requireSession(input.threadId);
|
|
670
|
-
const declaredAttachmentBytes = (input.attachments ?? []).reduce((total, attachment) => total + attachment.sizeBytes, 0);
|
|
754
|
+
const declaredAttachmentBytes = (input.attachments ?? []).reduce((total, attachment) => total + (attachment.sizeBytes ?? 0), 0);
|
|
671
755
|
if (declaredAttachmentBytes > 52428800) return yield* new require_bin.ProviderAdapterRequestError({
|
|
672
756
|
provider: COPILOT_DRIVER_KIND,
|
|
673
757
|
method: "session.send",
|
|
674
758
|
detail: `Attachments total ${declaredAttachmentBytes} bytes; limit is ${require_collectUint8StreamText.PROVIDER_SEND_TURN_MAX_ATTACHMENT_TOTAL_BYTES} bytes.`
|
|
675
759
|
});
|
|
676
760
|
let attachmentTotalBytes = 0;
|
|
677
|
-
const
|
|
761
|
+
const pathLineEntries = [];
|
|
762
|
+
const attachments = (yield* effect.Effect.forEach(input.attachments ?? [], (attachment) => effect.Effect.gen(function* () {
|
|
763
|
+
if (!require_bin.isPersistableChatAttachment(attachment)) {
|
|
764
|
+
pathLineEntries.push({ attachment });
|
|
765
|
+
return null;
|
|
766
|
+
}
|
|
678
767
|
const persisted = require_bin.readPersistedAttachment({
|
|
679
768
|
attachmentsDir: deps.serverConfig.attachmentsDir,
|
|
680
769
|
attachment
|
|
@@ -696,7 +785,7 @@ const makeSendTurn = (deps) => (input) => effect.Effect.gen(function* () {
|
|
|
696
785
|
mimeType: attachmentMimeType(attachment),
|
|
697
786
|
displayName: attachment.name
|
|
698
787
|
};
|
|
699
|
-
}));
|
|
788
|
+
}))).filter((attachment) => attachment !== null);
|
|
700
789
|
const copilotModelSelection = selectionTargetsCopilotInstance(input.modelSelection, deps.instanceId) ? input.modelSelection : void 0;
|
|
701
790
|
if (copilotModelSelection) {
|
|
702
791
|
record.model = copilotModelSelection.model;
|
|
@@ -723,7 +812,7 @@ const makeSendTurn = (deps) => (input) => effect.Effect.gen(function* () {
|
|
|
723
812
|
}
|
|
724
813
|
record.updatedAt = (/* @__PURE__ */ new Date()).toISOString();
|
|
725
814
|
const sendPayload = {
|
|
726
|
-
prompt: input.input ?? "",
|
|
815
|
+
prompt: require_makeManagedServerProvider.appendAttachmentPathLines(input.input ?? "", require_makeManagedServerProvider.formatAttachmentPathLines(pathLineEntries)) ?? "",
|
|
727
816
|
...attachments.length > 0 ? { attachments } : {},
|
|
728
817
|
mode: "immediate"
|
|
729
818
|
};
|
|
@@ -913,6 +1002,15 @@ const makeCopilotAdapter = effect.Effect.fn("makeCopilotAdapter")(function* (cop
|
|
|
913
1002
|
nextEventId
|
|
914
1003
|
};
|
|
915
1004
|
const handleEvent = effect.Effect.fn("handleCopilotEvent")(function* (session, event) {
|
|
1005
|
+
if (isCopilotChildEvent(event)) {
|
|
1006
|
+
yield* logNativeEvent(session.threadId, event);
|
|
1007
|
+
const mapped = (yield* mapEvent(mapEventDeps, session, event)).map((runtimeEvent) => require_makeManagedServerProvider.stampRuntimeEvent(runtimeEvent, {
|
|
1008
|
+
providerInstanceId: instanceId,
|
|
1009
|
+
runtimeSessionId: session.runtimeSessionId
|
|
1010
|
+
}));
|
|
1011
|
+
if (mapped.length > 0) yield* emit(mapped);
|
|
1012
|
+
return;
|
|
1013
|
+
}
|
|
916
1014
|
session.updatedAt = event.timestamp;
|
|
917
1015
|
const clearsActiveTurn = event.type === "session.idle" || event.type === "abort";
|
|
918
1016
|
if (event.type === "assistant.turn_start") {
|
|
@@ -927,7 +1025,6 @@ const makeCopilotAdapter = effect.Effect.fn("makeCopilotAdapter")(function* (cop
|
|
|
927
1025
|
session.turns.at(-1)?.items.push(event);
|
|
928
1026
|
} else if (event.type === "assistant.message_delta" || event.type === "assistant.reasoning" || event.type === "assistant.reasoning_delta" || event.type === "assistant.usage" || event.type === "tool.execution_start" || event.type === "tool.execution_complete" || event.type === "user_input.requested" || event.type === "user_input.completed") session.turns.at(-1)?.items.push(event);
|
|
929
1027
|
else if (event.type === "session.idle" || event.type === "abort" || event.type === "assistant.turn_end" || event.type === "session.error") session.turns.at(-1)?.items.push(event);
|
|
930
|
-
if (event.type === "assistant.usage") session.lastUsage = normalizeUsage(event);
|
|
931
1028
|
if (event.type === "session.error") {
|
|
932
1029
|
session.lastError = event.data.message;
|
|
933
1030
|
if (session.agentControl) yield* session.agentControl.revoke("runtime-teardown");
|
|
@@ -1265,11 +1362,13 @@ function mapCopilotModelCapabilities(model) {
|
|
|
1265
1362
|
})] });
|
|
1266
1363
|
}
|
|
1267
1364
|
function mapCopilotModel(model) {
|
|
1365
|
+
const maxContextTokens = model.capabilities.limits?.max_context_window_tokens;
|
|
1268
1366
|
return {
|
|
1269
1367
|
slug: model.id,
|
|
1270
1368
|
name: model.name,
|
|
1271
1369
|
isCustom: false,
|
|
1272
|
-
capabilities: mapCopilotModelCapabilities(model)
|
|
1370
|
+
capabilities: mapCopilotModelCapabilities(model),
|
|
1371
|
+
...Number.isSafeInteger(maxContextTokens) && maxContextTokens > 0 ? { maxContextTokens } : {}
|
|
1273
1372
|
};
|
|
1274
1373
|
}
|
|
1275
1374
|
function formatCopilotAuthLabel(authType) {
|
|
@@ -1,15 +1,21 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
|
|
3
|
-
import { $
|
|
3
|
+
import { $a as ProviderInstanceId, Ja as DEFAULT_GIT_TEXT_GENERATION_OPTIONS_BY_PROVIDER, Ln as TextGenerationError, Qa as ProviderDriverKind, _s as TurnId, ds as RuntimeRequestId, ir as CopilotSettings, ki as PROVIDER_SEND_TURN_MAX_ATTACHMENT_TOTAL_BYTES, ls as ProviderItemId, ms as RuntimeTaskId, qa as DEFAULT_GIT_TEXT_GENERATION_MODEL_BY_PROVIDER, rr as CodexSettings, rs as EventId, us as RuntimeItemId } from "./collectUint8StreamText-C_VNyArd.mjs";
|
|
4
4
|
import { st as ServerConfig } from "./Metrics-BP9YjxZB.mjs";
|
|
5
|
-
import { $ as
|
|
6
|
-
import { n as requireRuntimeSessionId, r as stampRuntimeEvent, t as makeManagedServerProvider } from "./makeManagedServerProvider-
|
|
5
|
+
import { $ as mergeProviderInstanceEnvironment, Ct as ProviderAdapterSessionNotFoundError, F as validateRankInboxThreadsResult, H as buildThreadTitlePrompt, M as makeEventNdjsonLogger, Qn as readPersistedAttachment, Tt as ProviderDriverError, U as extractJsonObject, Un as makeManualOnlyProviderMaintenanceCapabilities, V as buildThreadPriorityPrompt, Zn as isPersistableChatAttachment, _t as installAgentControlNativeHttp, at as buildSelectOptionDescriptor, bt as ProviderAdapterProcessError, cr as getProviderOptionStringSelectionValue, er as resolveCommandPath, ft as providerModelsFromSettings, ht as agentControlHostContext, ir as getModelSelectionStringOptionValue, j as ProviderEventLoggers, lt as isCommandMissingCause, mt as AGENT_CONTROL_INTERNAL_SERVER_NAME, n as AgentControlSessionRegistry, nr as createModelCapabilities, ot as buildServerProvider, q as sanitizeThreadTitle, t as makeServerQueueMetrics, vt as redactAgentControlSecrets, wt as ProviderAdapterValidationError, xt as ProviderAdapterRequestError, yt as createProcessDeviceToolBinding } from "./bin.mjs";
|
|
6
|
+
import { a as formatAttachmentPathLines, i as appendAttachmentPathLines, n as requireRuntimeSessionId, r as stampRuntimeEvent, t as makeManagedServerProvider } from "./makeManagedServerProvider-GZcpSLrW.mjs";
|
|
7
7
|
import { t as defaultProviderContinuationIdentity } from "./ProviderDriver-kCV60GKk.mjs";
|
|
8
|
-
import { t as makeCodexTextGeneration } from "./CodexTextGeneration-
|
|
8
|
+
import { t as makeCodexTextGeneration } from "./CodexTextGeneration-BikHow8k.mjs";
|
|
9
9
|
import { Effect, Option, Queue, Result, Schema, Stream } from "effect";
|
|
10
10
|
import { randomUUID } from "node:crypto";
|
|
11
11
|
import "effect/unstable/process";
|
|
12
12
|
import { CopilotClient, RuntimeConnection } from "@github/copilot-sdk";
|
|
13
|
+
//#region src/provider/Layers/CopilotAdapter.eventScope.ts
|
|
14
|
+
/** Wildcard SDK subscriptions include child events, including their turn and abort events. */
|
|
15
|
+
function isCopilotChildEvent(event) {
|
|
16
|
+
return Boolean(event.agentId || "parentToolCallId" in event.data && event.data.parentToolCallId);
|
|
17
|
+
}
|
|
18
|
+
//#endregion
|
|
13
19
|
//#region src/provider/Layers/CopilotAdapter.types.ts
|
|
14
20
|
const COPILOT_DRIVER_KIND = ProviderDriverKind.make("copilot");
|
|
15
21
|
const DEFAULT_BINARY_PATH = "copilot";
|
|
@@ -200,6 +206,9 @@ function selectionTargetsCopilotInstance(value, instanceId) {
|
|
|
200
206
|
}
|
|
201
207
|
//#endregion
|
|
202
208
|
//#region src/provider/Layers/CopilotAdapter.mapEvent.ts
|
|
209
|
+
function nonNegativeCount(value) {
|
|
210
|
+
return value !== void 0 && Number.isSafeInteger(value) && value >= 0 ? value : void 0;
|
|
211
|
+
}
|
|
203
212
|
const mapEvent = (deps, session, event) => Effect.gen(function* () {
|
|
204
213
|
const turnId = session.activeTurnId;
|
|
205
214
|
const stamp = yield* deps.makeEventStamp();
|
|
@@ -208,6 +217,57 @@ const mapEvent = (deps, session, event) => Effect.gen(function* () {
|
|
|
208
217
|
method: event.type,
|
|
209
218
|
payload: event
|
|
210
219
|
};
|
|
220
|
+
if (event.type === "subagent.started" || event.type === "subagent.completed" || event.type === "subagent.failed") {
|
|
221
|
+
const data = event.data;
|
|
222
|
+
const linkage = {
|
|
223
|
+
taskId: RuntimeTaskId.make(`copilot-task:${data.toolCallId}`),
|
|
224
|
+
taskType: "subagent",
|
|
225
|
+
title: data.agentDisplayName.trim() || data.agentName.trim() || "Copilot agent",
|
|
226
|
+
...data.agentName.trim() ? { role: data.agentName.trim() } : {},
|
|
227
|
+
...data.model?.trim() ? { model: data.model.trim() } : {},
|
|
228
|
+
toolUseId: data.toolCallId
|
|
229
|
+
};
|
|
230
|
+
const base = eventBase({
|
|
231
|
+
eventId: stamp.eventId,
|
|
232
|
+
createdAt: event.timestamp,
|
|
233
|
+
threadId: session.threadId,
|
|
234
|
+
providerInstanceId: session.providerInstanceId,
|
|
235
|
+
...turnId ? { turnId } : {},
|
|
236
|
+
raw
|
|
237
|
+
});
|
|
238
|
+
if (event.type === "subagent.started") return [{
|
|
239
|
+
...base,
|
|
240
|
+
type: "task.started",
|
|
241
|
+
payload: {
|
|
242
|
+
...linkage,
|
|
243
|
+
...event.data.agentDescription.trim() ? { description: event.data.agentDescription.trim() } : {}
|
|
244
|
+
}
|
|
245
|
+
}];
|
|
246
|
+
const terminal = event.data;
|
|
247
|
+
const totalTokens = nonNegativeCount(terminal.totalTokens);
|
|
248
|
+
const toolUses = nonNegativeCount(terminal.totalToolCalls);
|
|
249
|
+
const durationMs = nonNegativeCount(terminal.durationMs);
|
|
250
|
+
const usage = {
|
|
251
|
+
...totalTokens !== void 0 ? { totalTokens } : {},
|
|
252
|
+
...toolUses !== void 0 ? { toolUses } : {},
|
|
253
|
+
...durationMs !== void 0 ? { durationMs } : {}
|
|
254
|
+
};
|
|
255
|
+
return [{
|
|
256
|
+
...base,
|
|
257
|
+
type: "task.completed",
|
|
258
|
+
payload: {
|
|
259
|
+
...linkage,
|
|
260
|
+
status: event.type === "subagent.failed" ? "failed" : event.data.cancelled ? "stopped" : "completed",
|
|
261
|
+
...event.type === "subagent.failed" && event.data.error.trim() ? { summary: event.data.error.trim() } : {},
|
|
262
|
+
...Object.keys(usage).length > 0 ? { usage } : {},
|
|
263
|
+
...totalTokens !== void 0 ? { typedUsage: {
|
|
264
|
+
...usage,
|
|
265
|
+
totalTokens
|
|
266
|
+
} } : {}
|
|
267
|
+
}
|
|
268
|
+
}];
|
|
269
|
+
}
|
|
270
|
+
if (isCopilotChildEvent(event)) return [];
|
|
211
271
|
switch (event.type) {
|
|
212
272
|
case "assistant.turn_start": {
|
|
213
273
|
const eventTurnId = TurnId.make(event.data.turnId);
|
|
@@ -294,18 +354,40 @@ const mapEvent = (deps, session, event) => Effect.gen(function* () {
|
|
|
294
354
|
data: event.data
|
|
295
355
|
}
|
|
296
356
|
}];
|
|
297
|
-
case "
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
357
|
+
case "session.usage_info":
|
|
358
|
+
case "assistant.usage":
|
|
359
|
+
if (event.type === "session.usage_info") {
|
|
360
|
+
const { currentTokens, tokenLimit } = event.data;
|
|
361
|
+
if (!Number.isSafeInteger(currentTokens) || currentTokens < 0 || !Number.isSafeInteger(tokenLimit) || tokenLimit <= 0) return [];
|
|
362
|
+
session.contextUsage = {
|
|
363
|
+
usedTokens: currentTokens,
|
|
364
|
+
maxTokens: tokenLimit
|
|
365
|
+
};
|
|
366
|
+
session.lastUsage = {
|
|
367
|
+
...session.lastUsage,
|
|
368
|
+
...session.contextUsage,
|
|
369
|
+
lastUsedTokens: currentTokens
|
|
370
|
+
};
|
|
371
|
+
} else {
|
|
372
|
+
if (event.data.parentToolCallId || event.data.initiator || event.data.interactionType && !["conversation-agent", "conversation-user"].includes(event.data.interactionType)) return [];
|
|
373
|
+
session.lastUsage = {
|
|
374
|
+
...normalizeUsage(event),
|
|
375
|
+
...session.contextUsage,
|
|
376
|
+
...session.contextUsage ? { lastUsedTokens: session.contextUsage.usedTokens } : {}
|
|
377
|
+
};
|
|
378
|
+
}
|
|
379
|
+
return [{
|
|
380
|
+
...eventBase({
|
|
381
|
+
eventId: stamp.eventId,
|
|
382
|
+
createdAt: event.timestamp,
|
|
383
|
+
threadId: session.threadId,
|
|
384
|
+
providerInstanceId: session.providerInstanceId,
|
|
385
|
+
...turnId ? { turnId } : {},
|
|
386
|
+
raw
|
|
387
|
+
}),
|
|
388
|
+
type: "thread.token-usage.updated",
|
|
389
|
+
payload: { usage: session.lastUsage }
|
|
390
|
+
}];
|
|
309
391
|
case "session.idle": {
|
|
310
392
|
const readyEventId = yield* deps.nextEventId;
|
|
311
393
|
return [{
|
|
@@ -456,7 +538,7 @@ function parseResumeCursor(resumeCursor) {
|
|
|
456
538
|
return typeof resumeCursor === "object" && resumeCursor !== null && "sessionId" in resumeCursor && typeof resumeCursor.sessionId === "string" && resumeCursor.sessionId.trim().length > 0 ? resumeCursor.sessionId.trim() : void 0;
|
|
457
539
|
}
|
|
458
540
|
function attachmentMimeType(attachment) {
|
|
459
|
-
return attachment.mimeType;
|
|
541
|
+
return attachment.mimeType ?? "application/octet-stream";
|
|
460
542
|
}
|
|
461
543
|
function createTurnStartWaiter(record) {
|
|
462
544
|
let timeout;
|
|
@@ -614,8 +696,10 @@ const makeStartSession = (deps) => (input) => Effect.gen(function* () {
|
|
|
614
696
|
attachSession: (nextSession) => {
|
|
615
697
|
record.unsubscribe();
|
|
616
698
|
record.session = nextSession;
|
|
699
|
+
delete record.contextUsage;
|
|
700
|
+
record.lastUsage = void 0;
|
|
617
701
|
record.unsubscribe = nextSession.on((event) => {
|
|
618
|
-
if (event.type === "assistant.turn_start") {
|
|
702
|
+
if (event.type === "assistant.turn_start" && !isCopilotChildEvent(event)) {
|
|
619
703
|
activeTurn = TurnId.make(event.data.turnId);
|
|
620
704
|
record.activeTurnId = activeTurn;
|
|
621
705
|
for (const pending of Array.from(record.pendingTurnStarts)) pending.resolve(activeTurn);
|
|
@@ -667,14 +751,19 @@ const makeStartSession = (deps) => (input) => Effect.gen(function* () {
|
|
|
667
751
|
}).pipe(Effect.onError(() => Effect.sync(() => deps.sessions.get(input.threadId)?.agentControl).pipe(Effect.flatMap((connection) => connection ? connection.revoke("runtime-teardown") : Effect.void))));
|
|
668
752
|
const makeSendTurn = (deps) => (input) => Effect.gen(function* () {
|
|
669
753
|
const record = yield* deps.requireSession(input.threadId);
|
|
670
|
-
const declaredAttachmentBytes = (input.attachments ?? []).reduce((total, attachment) => total + attachment.sizeBytes, 0);
|
|
754
|
+
const declaredAttachmentBytes = (input.attachments ?? []).reduce((total, attachment) => total + (attachment.sizeBytes ?? 0), 0);
|
|
671
755
|
if (declaredAttachmentBytes > 52428800) return yield* new ProviderAdapterRequestError({
|
|
672
756
|
provider: COPILOT_DRIVER_KIND,
|
|
673
757
|
method: "session.send",
|
|
674
758
|
detail: `Attachments total ${declaredAttachmentBytes} bytes; limit is ${PROVIDER_SEND_TURN_MAX_ATTACHMENT_TOTAL_BYTES} bytes.`
|
|
675
759
|
});
|
|
676
760
|
let attachmentTotalBytes = 0;
|
|
677
|
-
const
|
|
761
|
+
const pathLineEntries = [];
|
|
762
|
+
const attachments = (yield* Effect.forEach(input.attachments ?? [], (attachment) => Effect.gen(function* () {
|
|
763
|
+
if (!isPersistableChatAttachment(attachment)) {
|
|
764
|
+
pathLineEntries.push({ attachment });
|
|
765
|
+
return null;
|
|
766
|
+
}
|
|
678
767
|
const persisted = readPersistedAttachment({
|
|
679
768
|
attachmentsDir: deps.serverConfig.attachmentsDir,
|
|
680
769
|
attachment
|
|
@@ -696,7 +785,7 @@ const makeSendTurn = (deps) => (input) => Effect.gen(function* () {
|
|
|
696
785
|
mimeType: attachmentMimeType(attachment),
|
|
697
786
|
displayName: attachment.name
|
|
698
787
|
};
|
|
699
|
-
}));
|
|
788
|
+
}))).filter((attachment) => attachment !== null);
|
|
700
789
|
const copilotModelSelection = selectionTargetsCopilotInstance(input.modelSelection, deps.instanceId) ? input.modelSelection : void 0;
|
|
701
790
|
if (copilotModelSelection) {
|
|
702
791
|
record.model = copilotModelSelection.model;
|
|
@@ -723,7 +812,7 @@ const makeSendTurn = (deps) => (input) => Effect.gen(function* () {
|
|
|
723
812
|
}
|
|
724
813
|
record.updatedAt = (/* @__PURE__ */ new Date()).toISOString();
|
|
725
814
|
const sendPayload = {
|
|
726
|
-
prompt: input.input ?? "",
|
|
815
|
+
prompt: appendAttachmentPathLines(input.input ?? "", formatAttachmentPathLines(pathLineEntries)) ?? "",
|
|
727
816
|
...attachments.length > 0 ? { attachments } : {},
|
|
728
817
|
mode: "immediate"
|
|
729
818
|
};
|
|
@@ -913,6 +1002,15 @@ const makeCopilotAdapter = Effect.fn("makeCopilotAdapter")(function* (copilotSet
|
|
|
913
1002
|
nextEventId
|
|
914
1003
|
};
|
|
915
1004
|
const handleEvent = Effect.fn("handleCopilotEvent")(function* (session, event) {
|
|
1005
|
+
if (isCopilotChildEvent(event)) {
|
|
1006
|
+
yield* logNativeEvent(session.threadId, event);
|
|
1007
|
+
const mapped = (yield* mapEvent(mapEventDeps, session, event)).map((runtimeEvent) => stampRuntimeEvent(runtimeEvent, {
|
|
1008
|
+
providerInstanceId: instanceId,
|
|
1009
|
+
runtimeSessionId: session.runtimeSessionId
|
|
1010
|
+
}));
|
|
1011
|
+
if (mapped.length > 0) yield* emit(mapped);
|
|
1012
|
+
return;
|
|
1013
|
+
}
|
|
916
1014
|
session.updatedAt = event.timestamp;
|
|
917
1015
|
const clearsActiveTurn = event.type === "session.idle" || event.type === "abort";
|
|
918
1016
|
if (event.type === "assistant.turn_start") {
|
|
@@ -927,7 +1025,6 @@ const makeCopilotAdapter = Effect.fn("makeCopilotAdapter")(function* (copilotSet
|
|
|
927
1025
|
session.turns.at(-1)?.items.push(event);
|
|
928
1026
|
} else if (event.type === "assistant.message_delta" || event.type === "assistant.reasoning" || event.type === "assistant.reasoning_delta" || event.type === "assistant.usage" || event.type === "tool.execution_start" || event.type === "tool.execution_complete" || event.type === "user_input.requested" || event.type === "user_input.completed") session.turns.at(-1)?.items.push(event);
|
|
929
1027
|
else if (event.type === "session.idle" || event.type === "abort" || event.type === "assistant.turn_end" || event.type === "session.error") session.turns.at(-1)?.items.push(event);
|
|
930
|
-
if (event.type === "assistant.usage") session.lastUsage = normalizeUsage(event);
|
|
931
1028
|
if (event.type === "session.error") {
|
|
932
1029
|
session.lastError = event.data.message;
|
|
933
1030
|
if (session.agentControl) yield* session.agentControl.revoke("runtime-teardown");
|
|
@@ -1265,11 +1362,13 @@ function mapCopilotModelCapabilities(model) {
|
|
|
1265
1362
|
})] });
|
|
1266
1363
|
}
|
|
1267
1364
|
function mapCopilotModel(model) {
|
|
1365
|
+
const maxContextTokens = model.capabilities.limits?.max_context_window_tokens;
|
|
1268
1366
|
return {
|
|
1269
1367
|
slug: model.id,
|
|
1270
1368
|
name: model.name,
|
|
1271
1369
|
isCustom: false,
|
|
1272
|
-
capabilities: mapCopilotModelCapabilities(model)
|
|
1370
|
+
capabilities: mapCopilotModelCapabilities(model),
|
|
1371
|
+
...Number.isSafeInteger(maxContextTokens) && maxContextTokens > 0 ? { maxContextTokens } : {}
|
|
1273
1372
|
};
|
|
1274
1373
|
}
|
|
1275
1374
|
function formatCopilotAuthLabel(authType) {
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
|
|
3
|
-
import {
|
|
3
|
+
import { $a as ProviderInstanceId, Ln as TextGenerationError, Qa as ProviderDriverKind, Yo as ApprovalRequestId, _s as TurnId, ar as CursorSettings, ds as RuntimeRequestId, rs as EventId } from "./collectUint8StreamText-C_VNyArd.mjs";
|
|
4
4
|
import { nt as sanitizeFeatureBranchName, st as ServerConfig, tt as sanitizeBranchFragment } from "./Metrics-BP9YjxZB.mjs";
|
|
5
|
-
import { $ as
|
|
6
|
-
import { n as requireRuntimeSessionId, r as stampRuntimeEvent, t as makeManagedServerProvider } from "./makeManagedServerProvider-
|
|
5
|
+
import { $ as mergeProviderInstanceEnvironment, $n as resolveAttachmentPath, B as buildPrContentPrompt, Ct as ProviderAdapterSessionNotFoundError, F as validateRankInboxThreadsResult, G as sanitizeCommitSubject, Gn as makeProviderMaintenanceCapabilities, H as buildThreadTitlePrompt, Hn as enrichProviderSnapshotWithVersionAdvisory, I as buildBranchNamePrompt, Jn as resolveProviderMaintenanceCapabilitiesEffect, K as sanitizePrTitle, Kn as makeStaticProviderMaintenanceResolver, L as buildCommitMessagePrompt, M as makeEventNdjsonLogger, R as buildIssueContentPolishPrompt, Tt as ProviderDriverError, U as extractJsonObject, V as buildThreadPriorityPrompt, Xn as ServerSettingsService, Zn as isPersistableChatAttachment, ar as getProviderOptionBooleanSelectionValue, at as buildSelectOptionDescriptor, bt as ProviderAdapterProcessError, cr as getProviderOptionStringSelectionValue, ft as providerModelsFromSettings, gt as installAgentControlAcp, ht as agentControlHostContext, it as buildBooleanOptionDescriptor, j as ProviderEventLoggers, lt as isCommandMissingCause, n as AgentControlSessionRegistry, nr as createModelCapabilities, ot as buildServerProvider, q as sanitizeThreadTitle, st as collectStreamAsString, wt as ProviderAdapterValidationError, xt as ProviderAdapterRequestError, yt as createProcessDeviceToolBinding, z as buildIssueContentTitlePrompt } from "./bin.mjs";
|
|
6
|
+
import { a as formatAttachmentPathLines, i as appendAttachmentPathLines, n as requireRuntimeSessionId, r as stampRuntimeEvent, t as makeManagedServerProvider } from "./makeManagedServerProvider-GZcpSLrW.mjs";
|
|
7
7
|
import { t as defaultProviderContinuationIdentity } from "./ProviderDriver-kCV60GKk.mjs";
|
|
8
|
-
import { a as makeAcpRequestOpenedEvent, c as makeAcpTokenUsageEvent, d as mapAcpToAdapterError, f as
|
|
8
|
+
import { a as makeAcpRequestOpenedEvent, c as makeAcpTokenUsageEvent, d as mapAcpToAdapterError, f as makeAcpSubagentRuntimeEvents, g as SessionConfigOption, i as makeAcpPlanUpdatedEvent, l as makeAcpToolCallEvent, m as parsePermissionRequest, n as makeAcpAssistantItemEvent, o as makeAcpRequestResolvedEvent, p as AcpSessionRuntime, r as makeAcpContentDeltaEvent, s as makeAcpThoughtDeltaEvent, t as makeAcpNativeLoggers, u as acpPermissionOutcome } from "./AcpNativeLogging-D7e1dn7s.mjs";
|
|
9
9
|
import { Cause, DateTime, Deferred, Effect, Exit, Fiber, FileSystem, Layer, Option, Path, PubSub, Ref, Result, Schema, Scope, Semaphore, Stream, SynchronizedRef } from "effect";
|
|
10
10
|
import { HttpClient } from "effect/unstable/http";
|
|
11
11
|
import * as nodePath from "node:path";
|
|
@@ -1033,66 +1033,6 @@ function makeCursorAdapter(cursorSettings, options) {
|
|
|
1033
1033
|
runtimeSessionId
|
|
1034
1034
|
})).pipe(Effect.asVoid);
|
|
1035
1035
|
};
|
|
1036
|
-
const offerAcpSubagentRuntimeEvents = Effect.fn("offerAcpSubagentRuntimeEvents")(function* (ctx, subagentState, rawPayload) {
|
|
1037
|
-
if (!subagentState) return;
|
|
1038
|
-
const subagentId = String(subagentState.subagent.subagentId);
|
|
1039
|
-
if (!ctx.startedSubagentIds.has(subagentId)) {
|
|
1040
|
-
ctx.startedSubagentIds.add(subagentId);
|
|
1041
|
-
yield* offerRuntimeEventForRuntime(ctx.session.runtimeSessionId, {
|
|
1042
|
-
type: "subagent.started",
|
|
1043
|
-
...yield* makeEventStamp(),
|
|
1044
|
-
provider: PROVIDER,
|
|
1045
|
-
threadId: ctx.threadId,
|
|
1046
|
-
...ctx.activeTurnId ? { turnId: ctx.activeTurnId } : {},
|
|
1047
|
-
payload: { subagent: subagentState.subagent },
|
|
1048
|
-
raw: {
|
|
1049
|
-
source: "acp.jsonrpc",
|
|
1050
|
-
method: "session/update",
|
|
1051
|
-
payload: rawPayload
|
|
1052
|
-
}
|
|
1053
|
-
});
|
|
1054
|
-
}
|
|
1055
|
-
if (subagentState.status === "completed" || subagentState.status === "failed" || subagentState.status === "stopped") {
|
|
1056
|
-
if (ctx.completedSubagentIds.has(subagentId)) return;
|
|
1057
|
-
ctx.completedSubagentIds.add(subagentId);
|
|
1058
|
-
yield* offerRuntimeEventForRuntime(ctx.session.runtimeSessionId, {
|
|
1059
|
-
type: "subagent.completed",
|
|
1060
|
-
...yield* makeEventStamp(),
|
|
1061
|
-
provider: PROVIDER,
|
|
1062
|
-
threadId: ctx.threadId,
|
|
1063
|
-
...ctx.activeTurnId ? { turnId: ctx.activeTurnId } : {},
|
|
1064
|
-
payload: {
|
|
1065
|
-
subagent: subagentState.subagent,
|
|
1066
|
-
status: subagentState.status,
|
|
1067
|
-
...subagentState.summary ? { summary: subagentState.summary } : {}
|
|
1068
|
-
},
|
|
1069
|
-
raw: {
|
|
1070
|
-
source: "acp.jsonrpc",
|
|
1071
|
-
method: "session/update",
|
|
1072
|
-
payload: rawPayload
|
|
1073
|
-
}
|
|
1074
|
-
});
|
|
1075
|
-
return;
|
|
1076
|
-
}
|
|
1077
|
-
yield* offerRuntimeEventForRuntime(ctx.session.runtimeSessionId, {
|
|
1078
|
-
type: "subagent.updated",
|
|
1079
|
-
...yield* makeEventStamp(),
|
|
1080
|
-
provider: PROVIDER,
|
|
1081
|
-
threadId: ctx.threadId,
|
|
1082
|
-
...ctx.activeTurnId ? { turnId: ctx.activeTurnId } : {},
|
|
1083
|
-
payload: {
|
|
1084
|
-
subagent: subagentState.subagent,
|
|
1085
|
-
...subagentState.status ? { status: subagentState.status } : {},
|
|
1086
|
-
...subagentState.summary ? { summary: subagentState.summary } : {},
|
|
1087
|
-
...subagentState.detail ? { detail: subagentState.detail } : {}
|
|
1088
|
-
},
|
|
1089
|
-
raw: {
|
|
1090
|
-
source: "acp.jsonrpc",
|
|
1091
|
-
method: "session/update",
|
|
1092
|
-
payload: rawPayload
|
|
1093
|
-
}
|
|
1094
|
-
});
|
|
1095
|
-
});
|
|
1096
1036
|
const getThreadSemaphore = (threadId) => SynchronizedRef.modifyEffect(threadLocksRef, (current) => {
|
|
1097
1037
|
const existing = Option.fromNullishOr(current.get(threadId));
|
|
1098
1038
|
return Option.match(existing, {
|
|
@@ -1391,8 +1331,7 @@ function makeCursorAdapter(cursorSettings, options) {
|
|
|
1391
1331
|
pendingApprovals,
|
|
1392
1332
|
pendingUserInputs,
|
|
1393
1333
|
turns: [],
|
|
1394
|
-
|
|
1395
|
-
completedSubagentIds: /* @__PURE__ */ new Set(),
|
|
1334
|
+
subagentEvents: makeAcpSubagentRuntimeEvents(),
|
|
1396
1335
|
lastPlanFingerprint: void 0,
|
|
1397
1336
|
activeTurnId: void 0,
|
|
1398
1337
|
stopped: false
|
|
@@ -1434,7 +1373,14 @@ function makeCursorAdapter(cursorSettings, options) {
|
|
|
1434
1373
|
toolCall: event.toolCall,
|
|
1435
1374
|
rawPayload: event.rawPayload
|
|
1436
1375
|
}));
|
|
1437
|
-
yield*
|
|
1376
|
+
for (const subagentEvent of yield* ctx.subagentEvents({
|
|
1377
|
+
provider: PROVIDER,
|
|
1378
|
+
threadId: ctx.threadId,
|
|
1379
|
+
turnId: ctx.activeTurnId,
|
|
1380
|
+
state: event.toolCall.subagent,
|
|
1381
|
+
rawPayload: event.rawPayload,
|
|
1382
|
+
makeStamp: makeEventStamp
|
|
1383
|
+
})) yield* offerRuntimeEventForRuntime(runtimeSessionId, subagentEvent);
|
|
1438
1384
|
return;
|
|
1439
1385
|
case "ContentDelta":
|
|
1440
1386
|
yield* logNative(ctx.threadId, "session/update", event.rawPayload, "acp.jsonrpc");
|
|
@@ -1540,11 +1486,19 @@ function makeCursorAdapter(cursorSettings, options) {
|
|
|
1540
1486
|
});
|
|
1541
1487
|
ctx.agentControlHostContextDelivered = true;
|
|
1542
1488
|
}
|
|
1543
|
-
|
|
1544
|
-
|
|
1545
|
-
|
|
1546
|
-
|
|
1547
|
-
|
|
1489
|
+
const pathLineEntries = [];
|
|
1490
|
+
const imageParts = [];
|
|
1491
|
+
for (const attachment of input.attachments ?? []) {
|
|
1492
|
+
if (!isPersistableChatAttachment(attachment) || attachment.type !== "image") {
|
|
1493
|
+
pathLineEntries.push({
|
|
1494
|
+
attachment,
|
|
1495
|
+
...attachment.id === void 0 ? {} : { resolvedPath: resolveAttachmentPath({
|
|
1496
|
+
attachmentsDir: serverConfig.attachmentsDir,
|
|
1497
|
+
attachment
|
|
1498
|
+
}) ?? void 0 }
|
|
1499
|
+
});
|
|
1500
|
+
continue;
|
|
1501
|
+
}
|
|
1548
1502
|
const attachmentPath = resolveAttachmentPath({
|
|
1549
1503
|
attachmentsDir: serverConfig.attachmentsDir,
|
|
1550
1504
|
attachment
|
|
@@ -1560,13 +1514,19 @@ function makeCursorAdapter(cursorSettings, options) {
|
|
|
1560
1514
|
detail: cause.message,
|
|
1561
1515
|
cause
|
|
1562
1516
|
})));
|
|
1563
|
-
|
|
1517
|
+
imageParts.push({
|
|
1564
1518
|
type: "image",
|
|
1565
1519
|
data: Buffer.from(bytes).toString("base64"),
|
|
1566
1520
|
mimeType: attachment.mimeType
|
|
1567
1521
|
});
|
|
1568
1522
|
}
|
|
1569
|
-
|
|
1523
|
+
const promptText = appendAttachmentPathLines(input.input?.trim(), formatAttachmentPathLines(pathLineEntries));
|
|
1524
|
+
if (promptText?.trim()) promptParts.push({
|
|
1525
|
+
type: "text",
|
|
1526
|
+
text: promptText
|
|
1527
|
+
});
|
|
1528
|
+
promptParts.push(...imageParts);
|
|
1529
|
+
if ((!promptText || promptText.trim().length === 0) && (!input.attachments || input.attachments.length === 0)) return yield* new ProviderAdapterValidationError({
|
|
1570
1530
|
provider: PROVIDER,
|
|
1571
1531
|
operation: "sendTurn",
|
|
1572
1532
|
issue: "Turn requires non-empty text or attachments."
|