github-router 0.3.354 → 0.3.356
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/ado-tools-DokE2DbX.js +1 -0
- package/dist/{aic-ledger-BdvCgRmx.js → aic-ledger-BuFrsGur.js} +3 -3
- package/dist/{aic-ledger-BdvCgRmx.js.map → aic-ledger-BuFrsGur.js.map} +1 -1
- package/dist/{aic-statusline-settings-EdsV1gzY.js → aic-statusline-settings-DBS9sEGC.js} +2 -2
- package/dist/{aic-statusline-settings-EdsV1gzY.js.map → aic-statusline-settings-DBS9sEGC.js.map} +1 -1
- package/dist/{attribution-settings-8Uv97n9j.js → attribution-settings-CnmV9MSv.js} +11 -11
- package/dist/{attribution-settings-8Uv97n9j.js.map → attribution-settings-CnmV9MSv.js.map} +1 -1
- package/dist/{auth-a_1lXYZ1.js → auth-DFawaLJU.js} +4 -4
- package/dist/{auth-a_1lXYZ1.js.map → auth-DFawaLJU.js.map} +1 -1
- package/dist/{bluebird-client-ltPIiyJU.js → bluebird-client-C29-JOkG.js} +92 -4
- package/dist/bluebird-client-C29-JOkG.js.map +1 -0
- package/dist/bluebird-client-DGE3WZqh.js +1 -0
- package/dist/browser-ext/manifest.json +1 -1
- package/dist/{check-usage-Bsbc-Sn6.js → check-usage-BkVEl-Su.js} +4 -4
- package/dist/{check-usage-Bsbc-Sn6.js.map → check-usage-BkVEl-Su.js.map} +1 -1
- package/dist/{claude-C_1OM7ce.js → claude-DvR3Y7fu.js} +28 -27
- package/dist/claude-DvR3Y7fu.js.map +1 -0
- package/dist/{claude-md-injection-CDOoGNEJ.js → claude-md-injection-Cpzolxin.js} +4 -4
- package/dist/{claude-md-injection-CDOoGNEJ.js.map → claude-md-injection-Cpzolxin.js.map} +1 -1
- package/dist/{codex-5eTmciDG.js → codex-DQpSPjpQ.js} +9 -9
- package/dist/{codex-5eTmciDG.js.map → codex-DQpSPjpQ.js.map} +1 -1
- package/dist/{copilot-discount-kpOLluHm.js → copilot-discount-Bsmv_3OX.js} +2 -2
- package/dist/{copilot-discount-kpOLluHm.js.map → copilot-discount-Bsmv_3OX.js.map} +1 -1
- package/dist/{debug-BtqbflcL.js → debug-DkNTuErv.js} +2 -2
- package/dist/{debug-BtqbflcL.js.map → debug-DkNTuErv.js.map} +1 -1
- package/dist/engine-DgmsdkCe.js +1 -0
- package/dist/{gate-discovery-CqJVzT_D.js → gate-discovery-B2x_8hNL.js} +5 -5
- package/dist/{gate-discovery-CqJVzT_D.js.map → gate-discovery-B2x_8hNL.js.map} +1 -1
- package/dist/{get-copilot-usage-0_S8pRWJ.js → get-copilot-usage-P9chc-X2.js} +3 -3
- package/dist/{get-copilot-usage-0_S8pRWJ.js.map → get-copilot-usage-P9chc-X2.js.map} +1 -1
- package/dist/hooks.mjs +2 -0
- package/dist/hooks.sha256 +1 -1
- package/dist/{index-cmd-CJXUOH4q.js → index-cmd-BkfYr9FH.js} +4 -4
- package/dist/{index-cmd-CJXUOH4q.js.map → index-cmd-BkfYr9FH.js.map} +1 -1
- package/dist/{internal-aic-status-wYPsCG4r.js → internal-aic-status-C6L4-ncP.js} +3 -3
- package/dist/{internal-aic-status-wYPsCG4r.js.map → internal-aic-status-C6L4-ncP.js.map} +1 -1
- package/dist/{internal-artifact-open-C67gDjKo.js → internal-artifact-open-DgJ3PCtt.js} +2 -2
- package/dist/{internal-artifact-open-C67gDjKo.js.map → internal-artifact-open-DgJ3PCtt.js.map} +1 -1
- package/dist/{internal-fast-dispatch-guard-D_TCtJhQ.js → internal-fast-dispatch-guard-CgBtUsQI.js} +2 -2
- package/dist/{internal-fast-dispatch-guard-D_TCtJhQ.js.map → internal-fast-dispatch-guard-CgBtUsQI.js.map} +1 -1
- package/dist/{internal-fast-dispatch-guard-A8teEib4.js → internal-fast-dispatch-guard-CicGz6oM.js} +1 -1
- package/dist/{internal-first-mate-guard-BJvCsVlU.js → internal-first-mate-guard-BfWYN6Jb.js} +3 -3
- package/dist/{internal-first-mate-guard-BJvCsVlU.js.map → internal-first-mate-guard-BfWYN6Jb.js.map} +1 -1
- package/dist/{internal-first-mate-guard-D-IQGiTs.js → internal-first-mate-guard-DTXPT7JW.js} +1 -1
- package/dist/{internal-max-dispatch-guard-D7ByWH4v.js → internal-max-dispatch-guard-CY8l9SDw.js} +3 -3
- package/dist/{internal-max-dispatch-guard-D7ByWH4v.js.map → internal-max-dispatch-guard-CY8l9SDw.js.map} +1 -1
- package/dist/{internal-max-dispatch-guard-BM_B15EH.js → internal-max-dispatch-guard-mNl9CCir.js} +1 -1
- package/dist/{internal-plan-review-DIvaBBUd.js → internal-plan-review-2OHTs8Nk.js} +3 -3
- package/dist/{internal-plan-review-DIvaBBUd.js.map → internal-plan-review-2OHTs8Nk.js.map} +1 -1
- package/dist/{internal-prompt-submit-C77GnEaW.js → internal-prompt-submit-CkfUcu34.js} +4 -4
- package/dist/{internal-prompt-submit-C77GnEaW.js.map → internal-prompt-submit-CkfUcu34.js.map} +1 -1
- package/dist/{internal-prompt-submit-CDTwamkW.js → internal-prompt-submit-DZ_-2A6a.js} +2 -2
- package/dist/{internal-rebrief-DZygfGHp.js → internal-rebrief-EhBHAHsz.js} +4 -4
- package/dist/{internal-rebrief-DZygfGHp.js.map → internal-rebrief-EhBHAHsz.js.map} +1 -1
- package/dist/{internal-session-bind-CQLDPuTx.js → internal-session-bind-Bv50ju2n.js} +2 -2
- package/dist/{internal-session-bind-CQLDPuTx.js.map → internal-session-bind-Bv50ju2n.js.map} +1 -1
- package/dist/{internal-stop-hook-Dn_AF0BF.js → internal-stop-hook-Dm-m8RoA.js} +5 -5
- package/dist/{internal-stop-hook-Dn_AF0BF.js.map → internal-stop-hook-Dm-m8RoA.js.map} +1 -1
- package/dist/{internal-stop-review-X7zRRhyc.js → internal-stop-review-K6f8xsCh.js} +2 -2
- package/dist/{internal-stop-review-X7zRRhyc.js.map → internal-stop-review-K6f8xsCh.js.map} +1 -1
- package/dist/{internal-worker-guard-wP3UN-3D.js → internal-worker-guard-GVhTjVlR.js} +2 -2
- package/dist/{internal-worker-guard-wP3UN-3D.js.map → internal-worker-guard-GVhTjVlR.js.map} +1 -1
- package/dist/{internal-workspace-header-DiUnkUeU.js → internal-workspace-header-d2hFf9Jy.js} +2 -2
- package/dist/{internal-workspace-header-DiUnkUeU.js.map → internal-workspace-header-d2hFf9Jy.js.map} +1 -1
- package/dist/lifecycle-BU_d2QMs.js +1 -0
- package/dist/lifecycle-ByFyew_w.js +1 -0
- package/dist/{lifecycle-BJ83L0tz.js → lifecycle-C6cxM_Nk.js} +2 -2
- package/dist/{lifecycle-BJ83L0tz.js.map → lifecycle-C6cxM_Nk.js.map} +1 -1
- package/dist/{lifecycle-aApO0hZW.js → lifecycle-pl9QpvqD.js} +2 -2
- package/dist/{lifecycle-aApO0hZW.js.map → lifecycle-pl9QpvqD.js.map} +1 -1
- package/dist/main.js +23 -23
- package/dist/{max-profile-contract-CMvzKSsg.js → max-profile-contract-Cx5_Z1Y7.js} +2 -2
- package/dist/{max-profile-contract-CMvzKSsg.js.map → max-profile-contract-Cx5_Z1Y7.js.map} +1 -1
- package/dist/{mcp-workspace-header-DBQugQlQ.js → mcp-workspace-header-Su8uUxJg.js} +2 -2
- package/dist/{mcp-workspace-header-DBQugQlQ.js.map → mcp-workspace-header-Su8uUxJg.js.map} +1 -1
- package/dist/{models-JIvKAGn0.js → models-D8v8OTbN.js} +3 -3
- package/dist/{models-JIvKAGn0.js.map → models-D8v8OTbN.js.map} +1 -1
- package/dist/{orchestration-D-S_0GVt.js → orchestration-Bov4rZEi.js} +2 -2
- package/dist/{orchestration-D-S_0GVt.js.map → orchestration-Bov4rZEi.js.map} +1 -1
- package/dist/{paths-xTSEAWfN.js → paths-BSI_EtDT.js} +18 -18
- package/dist/paths-BSI_EtDT.js.map +1 -0
- package/dist/paths-BYxX9DfA.js +1 -0
- package/dist/{peer-mcp-personas-DlF1dKCs.js → peer-mcp-personas-CVxXq1Q-.js} +2859 -170
- package/dist/peer-mcp-personas-CVxXq1Q-.js.map +1 -0
- package/dist/{pi-2m2IgZlm.js → pi-D-BgxVhx.js} +22 -16
- package/dist/{pi-2m2IgZlm.js.map → pi-D-BgxVhx.js.map} +1 -1
- package/dist/{plan-review-hook-BQ29WGv7.js → plan-review-hook-CHK1wL3-.js} +3 -3
- package/dist/{plan-review-hook-BQ29WGv7.js.map → plan-review-hook-CHK1wL3-.js.map} +1 -1
- package/dist/{provision-DLGlhu3a.js → provision-DYmZgZDr.js} +6 -5
- package/dist/provision-DYmZgZDr.js.map +1 -0
- package/dist/{self-invocation-Dr5zlbpM.js → self-invocation-Dk_UHD_v.js} +2 -2
- package/dist/{self-invocation-Dr5zlbpM.js.map → self-invocation-Dk_UHD_v.js.map} +1 -1
- package/dist/{serve-8tXHVHOr.js → serve-DfxxKLFl.js} +25 -17
- package/dist/serve-DfxxKLFl.js.map +1 -0
- package/dist/{server-setup-BBSmse1J.js → server-setup-VYf8ptCH.js} +168 -33
- package/dist/server-setup-VYf8ptCH.js.map +1 -0
- package/dist/{service-backend-DV1u5x0Q.js → service-backend-DHyd9vjW.js} +3 -3
- package/dist/{service-backend-DV1u5x0Q.js.map → service-backend-DHyd9vjW.js.map} +1 -1
- package/dist/{start-B7jTBpAc.js → start-BsY1d26G.js} +4 -4
- package/dist/{start-B7jTBpAc.js.map → start-BsY1d26G.js.map} +1 -1
- package/dist/{state-CfEVoqBM.js → state-CiwCLVDZ.js} +3 -1
- package/dist/{state-CfEVoqBM.js.map → state-CiwCLVDZ.js.map} +1 -1
- package/dist/{static-context-pack-BRqt4ajJ.js → static-context-pack-dKrzbfIN.js} +3 -3
- package/dist/{static-context-pack-BRqt4ajJ.js.map → static-context-pack-dKrzbfIN.js.map} +1 -1
- package/dist/{stop-gate-hook-BYd0NruJ.js → stop-gate-hook-CC7VWkZM.js} +3 -3
- package/dist/{stop-gate-hook-BYd0NruJ.js.map → stop-gate-hook-CC7VWkZM.js.map} +1 -1
- package/dist/{stop-gate-policy-FGAfpfc-.js → stop-gate-policy-CoR8xKNQ.js} +2 -2
- package/dist/{stop-gate-policy-FGAfpfc-.js.map → stop-gate-policy-CoR8xKNQ.js.map} +1 -1
- package/dist/{token-CTf5jCmP.js → token-CA2s70qj.js} +3 -3
- package/dist/{token-CTf5jCmP.js.map → token-CA2s70qj.js.map} +1 -1
- package/dist/{worker-dispatch-BjfROaic.js → worker-dispatch-B_rriT7z.js} +2 -2
- package/dist/{worker-dispatch-BjfROaic.js.map → worker-dispatch-B_rriT7z.js.map} +1 -1
- package/docs/azure-mcp.md +38 -25
- package/package.json +1 -1
- package/dist/ado-tools-CN4i9OVl.js +0 -1
- package/dist/bluebird-client-ltPIiyJU.js.map +0 -1
- package/dist/bluebird-client-mr3M67k-.js +0 -1
- package/dist/claude-C_1OM7ce.js.map +0 -1
- package/dist/engine-CIAopp0h.js +0 -1
- package/dist/lifecycle-CVg2-zQ3.js +0 -1
- package/dist/lifecycle-Dk_BHtfz.js +0 -1
- package/dist/paths-C9x5U3dO.js +0 -1
- package/dist/paths-xTSEAWfN.js.map +0 -1
- package/dist/peer-mcp-personas-DlF1dKCs.js.map +0 -1
- package/dist/provision-DLGlhu3a.js.map +0 -1
- package/dist/serve-8tXHVHOr.js.map +0 -1
- package/dist/server-setup-BBSmse1J.js.map +0 -1
|
@@ -1,18 +1,18 @@
|
|
|
1
|
-
import { I as provisionTreeSitterAssets, L as withInstallLock } from "./service-backend-
|
|
1
|
+
import { I as provisionTreeSitterAssets, L as withInstallLock } from "./service-backend-DHyd9vjW.js";
|
|
2
2
|
import { t as getPackageVersion } from "./version-C8x2hQrZ.js";
|
|
3
|
-
import { i as ensurePaths, t as PATHS } from "./paths-
|
|
4
|
-
import { t as state } from "./state-
|
|
5
|
-
import { _ as forwardError, a as cacheCopilotVersion, b as copilotBaseUrl, c as filterBetaHeader, d as resolveModel, f as sleep, g as HTTPError, i as tryRefreshAndRetry, l as isNullish, n as setupGitHubAgentToken, o as cacheModels, r as setupGitHubToken, s as cacheVSCodeVersion, t as setupCopilotToken, x as copilotHeaders } from "./token-
|
|
3
|
+
import { i as ensurePaths, t as PATHS } from "./paths-BSI_EtDT.js";
|
|
4
|
+
import { t as state } from "./state-CiwCLVDZ.js";
|
|
5
|
+
import { _ as forwardError, a as cacheCopilotVersion, b as copilotBaseUrl, c as filterBetaHeader, d as resolveModel, f as sleep, g as HTTPError, i as tryRefreshAndRetry, l as isNullish, n as setupGitHubAgentToken, o as cacheModels, r as setupGitHubToken, s as cacheVSCodeVersion, t as setupCopilotToken, x as copilotHeaders } from "./token-CA2s70qj.js";
|
|
6
6
|
import { r as fetchWithTransientRetry } from "./upstream-retry-i1k1Xai2.js";
|
|
7
|
-
import { t as getCopilotUsage } from "./get-copilot-usage-
|
|
7
|
+
import { t as getCopilotUsage } from "./get-copilot-usage-P9chc-X2.js";
|
|
8
8
|
import { a as parseBoolEnv, c as runCommandCapture, i as killManagedTree, s as resolveExecutable, u as runCommandVoid } from "./exec-Bf8g_bIR.js";
|
|
9
9
|
import { c as FAST_PROFILE_MODELS, l as FAST_PROFILE_NATIVE_AGENT_NAMES, r as FAST_PROFILE_ADVISOR_MODEL } from "./fast-profile-contract-JOnZBgFB.js";
|
|
10
|
-
import { $ as readIteratorWithTimeout, $t as
|
|
11
|
-
import { D as CHEAPEST_PROFILE_MODELS, O as CHEAPEST_PROFILE_NATIVE_AGENT_NAMES, S as CHEAPEST_PROFILE_ADVISOR_CLIENT_MODEL, _ as isBalancedFamily, g as displayModelName, m as cheapestContractFor, p as balancedContractFor, v as isCheapestFamily, y as isPinnedLaunchProfile } from "./static-context-pack-
|
|
10
|
+
import { $ as readIteratorWithTimeout, $t as getTokenCount, B as injectAdvisorTool, Bn as catalogAdvertises1M, D as toolbeltEnabled, En as BUDGET_SMALL_FAST_SLUG, F as ADVISOR_TOOL_INSTRUCTIONS, G as formatThinkingRepairDecline, Gn as CHEAP_PROFILE_MODELS, H as resolveAdvisorEffort, Hn as withOneMSuffix, I as CHEAPEST_ADVISOR_TOOL_INSTRUCTIONS, J as repairRejectedThinkingHistory, K as rememberThinkingHistoryRepair, Kn as CHEAP_PROFILE_NATIVE_AGENT_NAMES, L as CHEAPEST_REVIEWER_ADVISOR_TOOL_INSTRUCTIONS, Ln as upstreamAllowH2, Mn as UPSTREAM_INACTIVITY_TIMEOUT_MS, N as searchWeb, Nn as generateRandomPort, P as ADVISOR_INTERNAL_TOOL_NAME, Pn as isBudgetClaudeLead, Q as logStreamError, Qt as getTextTokenCount, R as FAST_ADVISOR_TOOL_INSTRUCTIONS, Rn as upstreamMaxConnections, U as resolveAdvisorModel, Un as withOneMSuffixForLead, V as isAdvisorRequested, Vn as oneMContextDisabled, W as resolveCheapestAdvisorModel, Wn as CHEAP_PROFILE_ADVISOR_CLIENT_MODEL, X as buildOpenAIErrorEvent, Xt as countTokens, Y as buildAnthropicErrorEvent, Yn as CHEAP_PROFILE_SUBAGENT_CONTEXT_TOKENS, Yt as shimDefaultsToXhigh, Z as isControllerClosedError, Zt as createMessages, an as warnOnTokenPriceDrift, at as handleMcpDelete, cn as createChatCompletions, dn as parseJsonOrDiagnose, dt as ADO_DEFAULT_TOOLSETS, en as getTokenizerFromModel, et as relayAnthropicStream, fn as normalizeOpenAIUsage, ft as normalizeAdoToolsets, gn as normalizeKustoClusterUri, hn as normalizeCloudAgentEnvironment, i as assertMcpToolSurfaceConsistent, in as assembleResponsesPayload, it as clampEffort, jn as UPSTREAM_FETCH_TIMEOUT_MS, ln as MAX_RESPONSE_BODY_BYTES, mt as agentToolsEnabled, nt as UNKNOWN_EFFORT_ANCHOR, on as resolveMcpToolTimeoutMs, ot as handleMcpPost, q as repairKnownThinkingHistory, rt as bucketEffort, sn as createResponses, tn as findLaunchBySecret, tt as EFFORT_ORDER, un as readResponseBodyCapped, ut as provisionAdoTools, wn as toolbeltPathOverride, z as buildAdvisorStream, zn as classifyMessagesRoute } from "./peer-mcp-personas-CVxXq1Q-.js";
|
|
11
|
+
import { D as CHEAPEST_PROFILE_MODELS, O as CHEAPEST_PROFILE_NATIVE_AGENT_NAMES, S as CHEAPEST_PROFILE_ADVISOR_CLIENT_MODEL, _ as isBalancedFamily, g as displayModelName, m as cheapestContractFor, p as balancedContractFor, v as isCheapestFamily, y as isPinnedLaunchProfile } from "./static-context-pack-dKrzbfIN.js";
|
|
12
12
|
import { i as BALANCED_PROFILE_NATIVE_AGENT_NAMES, r as BALANCED_PROFILE_MODELS } from "./balanced-profile-contract-DtnTIBjL.js";
|
|
13
|
-
import { A as normalizeTrailingOneMSuffix, a as MAX_PROFILE_NATIVE_AGENT_NAMES, d as maxAdvisorPinIsValid, h as maxOpusModel, i as MAX_PROFILE_MODELS, j as stripTrailingOneMSuffix, k as fastEndpointForModel, l as maxAdvisorEffortForModel, n as MAX_PROFILE_ALLOWED_LEAD_MODEL_IDS, t as MAX_PROFILE_ADVISOR_INSTRUCTIONS, u as maxAdvisorModelFromPin, y as validateMaxProfilePrerequisites } from "./max-profile-contract-
|
|
14
|
-
import { f as getAzureRepoFromGit } from "./bluebird-client-
|
|
15
|
-
import { a as extractAndRecordPricedAic, f as copilotUsageToWire, h as nanoAiuToCredits, i as extractAndRecordAic, l as recordAic, m as formatAic, p as extractCopilotUsage } from "./aic-ledger-
|
|
13
|
+
import { A as normalizeTrailingOneMSuffix, a as MAX_PROFILE_NATIVE_AGENT_NAMES, d as maxAdvisorPinIsValid, h as maxOpusModel, i as MAX_PROFILE_MODELS, j as stripTrailingOneMSuffix, k as fastEndpointForModel, l as maxAdvisorEffortForModel, n as MAX_PROFILE_ALLOWED_LEAD_MODEL_IDS, t as MAX_PROFILE_ADVISOR_INSTRUCTIONS, u as maxAdvisorModelFromPin, y as validateMaxProfilePrerequisites } from "./max-profile-contract-Cx5_Z1Y7.js";
|
|
14
|
+
import { f as getAzureRepoFromGit } from "./bluebird-client-C29-JOkG.js";
|
|
15
|
+
import { a as extractAndRecordPricedAic, f as copilotUsageToWire, h as nanoAiuToCredits, i as extractAndRecordAic, l as recordAic, m as formatAic, p as extractCopilotUsage } from "./aic-ledger-BuFrsGur.js";
|
|
16
16
|
import consola from "consola";
|
|
17
17
|
import fs, { existsSync } from "node:fs";
|
|
18
18
|
import path from "node:path";
|
|
@@ -399,7 +399,8 @@ const FAST_PROFILE = Object.freeze({
|
|
|
399
399
|
"workers",
|
|
400
400
|
"browser",
|
|
401
401
|
"ado",
|
|
402
|
-
"kusto"
|
|
402
|
+
"kusto",
|
|
403
|
+
"cloudagent"
|
|
403
404
|
]),
|
|
404
405
|
hasCoordinator: false
|
|
405
406
|
});
|
|
@@ -421,7 +422,8 @@ const CHEAP1M_PROFILE = Object.freeze({
|
|
|
421
422
|
"workers",
|
|
422
423
|
"browser",
|
|
423
424
|
"ado",
|
|
424
|
-
"kusto"
|
|
425
|
+
"kusto",
|
|
426
|
+
"cloudagent"
|
|
425
427
|
]),
|
|
426
428
|
hasCoordinator: false
|
|
427
429
|
});
|
|
@@ -443,7 +445,8 @@ const CHEAP_PROFILE = Object.freeze({
|
|
|
443
445
|
"workers",
|
|
444
446
|
"browser",
|
|
445
447
|
"ado",
|
|
446
|
-
"kusto"
|
|
448
|
+
"kusto",
|
|
449
|
+
"cloudagent"
|
|
447
450
|
]),
|
|
448
451
|
hasCoordinator: false
|
|
449
452
|
});
|
|
@@ -466,7 +469,8 @@ const CHEAPEST_PROFILE = Object.freeze({
|
|
|
466
469
|
"workers",
|
|
467
470
|
"browser",
|
|
468
471
|
"ado",
|
|
469
|
-
"kusto"
|
|
472
|
+
"kusto",
|
|
473
|
+
"cloudagent"
|
|
470
474
|
]),
|
|
471
475
|
hasCoordinator: false
|
|
472
476
|
});
|
|
@@ -488,7 +492,8 @@ const BALANCED_PROFILE = Object.freeze({
|
|
|
488
492
|
"workers",
|
|
489
493
|
"browser",
|
|
490
494
|
"ado",
|
|
491
|
-
"kusto"
|
|
495
|
+
"kusto",
|
|
496
|
+
"cloudagent"
|
|
492
497
|
]),
|
|
493
498
|
hasCoordinator: false
|
|
494
499
|
});
|
|
@@ -505,7 +510,8 @@ const CHEAPEST2_PROFILE = Object.freeze({
|
|
|
505
510
|
"workers",
|
|
506
511
|
"browser",
|
|
507
512
|
"ado",
|
|
508
|
-
"kusto"
|
|
513
|
+
"kusto",
|
|
514
|
+
"cloudagent"
|
|
509
515
|
]),
|
|
510
516
|
hasCoordinator: false
|
|
511
517
|
});
|
|
@@ -521,7 +527,8 @@ const BALANCED2_PROFILE = Object.freeze({
|
|
|
521
527
|
"workers",
|
|
522
528
|
"browser",
|
|
523
529
|
"ado",
|
|
524
|
-
"kusto"
|
|
530
|
+
"kusto",
|
|
531
|
+
"cloudagent"
|
|
525
532
|
]),
|
|
526
533
|
hasCoordinator: false
|
|
527
534
|
});
|
|
@@ -553,7 +560,8 @@ const MAX_PROFILE = Object.freeze({
|
|
|
553
560
|
"fleet",
|
|
554
561
|
"first-mate",
|
|
555
562
|
"ado",
|
|
556
|
-
"kusto"
|
|
563
|
+
"kusto",
|
|
564
|
+
"cloudagent"
|
|
557
565
|
]),
|
|
558
566
|
hasCoordinator: true
|
|
559
567
|
});
|
|
@@ -2089,8 +2097,11 @@ async function stopKeepAwake() {
|
|
|
2089
2097
|
* repo would silently provision three credentialed network clients. Four
|
|
2090
2098
|
* properties bound that:
|
|
2091
2099
|
*
|
|
2092
|
-
* 1.
|
|
2093
|
-
* only; nothing discovered from a remote
|
|
2100
|
+
* 1. Within these Azure surfaces, auto-enable can never produce a WRITE
|
|
2101
|
+
* surface. `--ado-write` is a flag only; nothing discovered from a remote
|
|
2102
|
+
* clears `X-MCP-Readonly`. The separate `cloudagent` group deliberately
|
|
2103
|
+
* steps outside this bound: discovery turns on its create tools too, and
|
|
2104
|
+
* `--no-cloudagent` is the veto (see `cloudagent-flags.ts`).
|
|
2094
2105
|
* 2. Every surface is suppressible individually (`--no-bluebird`,
|
|
2095
2106
|
* `--no-ado`, `--no-kusto`, or the `GH_ROUTER_DISABLE_*` env vars) and
|
|
2096
2107
|
* wholesale (`GH_ROUTER_AZURE_MCPS=off`), and an explicit negative always
|
|
@@ -2099,12 +2110,13 @@ async function stopKeepAwake() {
|
|
|
2099
2110
|
* that enabled it, so a session that suddenly carries three more servers is
|
|
2100
2111
|
* explainable rather than mysterious — and so a surface turned on by a
|
|
2101
2112
|
* flag is never miscredited to a remote.
|
|
2102
|
-
* 4. Kusto is the one surface whose
|
|
2103
|
-
* cluster is never discovered: discovery may turn the GROUP on, and a
|
|
2104
|
-
* names the cluster it reads
|
|
2105
|
-
*
|
|
2106
|
-
*
|
|
2107
|
-
*
|
|
2113
|
+
* 4. Kusto is the one surface whose requests extend past the repository, so
|
|
2114
|
+
* its cluster is never discovered: discovery may turn the GROUP on, and a
|
|
2115
|
+
* call names the cluster it reads. A per-call hostname is checked only for
|
|
2116
|
+
* a standalone `kusto` DNS label, with any suffix. That is not an ownership
|
|
2117
|
+
* allowlist: the selected host receives the Azure bearer token, so callers
|
|
2118
|
+
* must choose a trusted host. RBAC governs data access at a genuine Kusto
|
|
2119
|
+
* service; it does not protect the token from an untrusted endpoint.
|
|
2108
2120
|
*
|
|
2109
2121
|
* This is a deliberate difference from the deny-by-default
|
|
2110
2122
|
* `GH_ROUTER_FM_SCAFFOLD_REPOS` precedent: that allowlist guards a tool that
|
|
@@ -2152,7 +2164,7 @@ function triState(explicit, envKey, env) {
|
|
|
2152
2164
|
if (explicit === true) return true;
|
|
2153
2165
|
if (envRaw === "1") return true;
|
|
2154
2166
|
}
|
|
2155
|
-
function readIntent(inputs) {
|
|
2167
|
+
function readIntent$1(inputs) {
|
|
2156
2168
|
const env = inputs.env ?? process.env;
|
|
2157
2169
|
return {
|
|
2158
2170
|
bluebird: inputs.bluebirdFlag,
|
|
@@ -2179,7 +2191,7 @@ function readIntent(inputs) {
|
|
|
2179
2191
|
*/
|
|
2180
2192
|
function azureDiscoveryNeeded(inputs) {
|
|
2181
2193
|
if (azureMcpsSuppressed(inputs.env ?? process.env)) return false;
|
|
2182
|
-
const intent = readIntent(inputs);
|
|
2194
|
+
const intent = readIntent$1(inputs);
|
|
2183
2195
|
if (intent.bluebird === void 0) return true;
|
|
2184
2196
|
if (intent.ado === void 0 && !intent.adoOrganization) return true;
|
|
2185
2197
|
return intent.kusto === void 0 && !intent.kustoCluster;
|
|
@@ -2198,7 +2210,7 @@ function azureDiscoveryNeeded(inputs) {
|
|
|
2198
2210
|
*/
|
|
2199
2211
|
function resolveAzureMcpFlags(inputs, discovered) {
|
|
2200
2212
|
const suppressAll = azureMcpsSuppressed(inputs.env ?? process.env);
|
|
2201
|
-
const intent = readIntent(inputs);
|
|
2213
|
+
const intent = readIntent$1(inputs);
|
|
2202
2214
|
const reasons = [];
|
|
2203
2215
|
const warnings = [];
|
|
2204
2216
|
const origin = discovered ? `${discovered.organization}/${discovered.project}/${discovered.repository}` : null;
|
|
@@ -2292,6 +2304,104 @@ function discoverAzureRepo(opts = {}) {
|
|
|
2292
2304
|
return discoveryPromise;
|
|
2293
2305
|
}
|
|
2294
2306
|
//#endregion
|
|
2307
|
+
//#region src/lib/cloudagent-flags.ts
|
|
2308
|
+
/**
|
|
2309
|
+
* Whether this launch enables the `cloudagent` MCP group, and why.
|
|
2310
|
+
*
|
|
2311
|
+
* One switch. `--cloudagent` or `GH_ROUTER_ENABLE_CLOUDAGENT=1` turns the group
|
|
2312
|
+
* on, and so does the workspace's git remote being an Azure DevOps repository
|
|
2313
|
+
* when neither was given. That last path exists for the same reason the ADO,
|
|
2314
|
+
* Kusto and Bluebird groups have one: an ADO checkout is already proof the
|
|
2315
|
+
* operator works in the ecosystem, and a group nobody remembers to enable is a
|
|
2316
|
+
* group nobody uses.
|
|
2317
|
+
*
|
|
2318
|
+
* Discovery enables the WHOLE group, write tools included. That steps outside
|
|
2319
|
+
* the Azure surfaces' read-only discovery rule. It was originally read-only, on
|
|
2320
|
+
* the ground that a cloned repository's `origin` is attacker-controllable and
|
|
2321
|
+
* `create_job` spends real compute. Two things carry that risk now: the
|
|
2322
|
+
* operator's
|
|
2323
|
+
* `--no-cloudagent` / `GH_ROUTER_DISABLE_CLOUDAGENT`, which is the veto, and the
|
|
2324
|
+
* create tools' own descriptions, which tell the model to confirm with the user
|
|
2325
|
+
* before creating a job the user did not ask for. A half-enabled group was the
|
|
2326
|
+
* worse failure mode: a model that can see `list_jobs` and cannot see
|
|
2327
|
+
* `create_job` reads the gap as a bug and spends turns looking for the tool
|
|
2328
|
+
* that is missing.
|
|
2329
|
+
*
|
|
2330
|
+
* Kept in its own file rather than folded into `azure-mcp-flags.ts`: that file
|
|
2331
|
+
* owns three Azure surfaces with one shared discovery verdict and one banner,
|
|
2332
|
+
* and Cloud Agent is a separate service whose only overlap is the remote it
|
|
2333
|
+
* reads. The discovery probe itself is shared and memoized, so splitting the
|
|
2334
|
+
* rule costs no extra `git remote -v`.
|
|
2335
|
+
*
|
|
2336
|
+
* Precedence: explicit negative, then explicit positive, then discovery, then
|
|
2337
|
+
* off. The flag is TRI-STATE (`undefined` = absent, `true` = asked for,
|
|
2338
|
+
* `false` = explicitly refused) because an absent flag and `--no-cloudagent`
|
|
2339
|
+
* are different intentions, and "off unless discovered" can only be safe while
|
|
2340
|
+
* an operator can always say no.
|
|
2341
|
+
*/
|
|
2342
|
+
/** `GH_ROUTER_DISABLE_CLOUDAGENT=1` — opts out of the discovery-driven enable. */
|
|
2343
|
+
function cloudAgentSuppressed(env = process.env) {
|
|
2344
|
+
const raw = env.GH_ROUTER_DISABLE_CLOUDAGENT?.trim().toLowerCase();
|
|
2345
|
+
if (!raw) return false;
|
|
2346
|
+
return raw === "1" || raw === "true" || raw === "yes" || raw === "on";
|
|
2347
|
+
}
|
|
2348
|
+
/**
|
|
2349
|
+
* Tri-state intent for the whole group.
|
|
2350
|
+
*
|
|
2351
|
+
* An explicit CLI negative beats an env positive: the CLI is the more specific
|
|
2352
|
+
* and more recent statement of intent. `GH_ROUTER_DISABLE_CLOUDAGENT` is folded in
|
|
2353
|
+
* BEFORE the positive, so a disable can never be overridden by
|
|
2354
|
+
* `GH_ROUTER_ENABLE_CLOUDAGENT=1` left in a shell profile.
|
|
2355
|
+
*/
|
|
2356
|
+
function readIntent(inputs, env) {
|
|
2357
|
+
if (inputs.cloudAgentFlag === false) return false;
|
|
2358
|
+
if (cloudAgentSuppressed(env)) return false;
|
|
2359
|
+
const raw = env.GH_ROUTER_ENABLE_CLOUDAGENT?.trim().toLowerCase();
|
|
2360
|
+
if (raw === "0" || raw === "off" || raw === "false" || raw === "no") return false;
|
|
2361
|
+
if (inputs.cloudAgentFlag === true) return true;
|
|
2362
|
+
if (raw === "1" || raw === "true" || raw === "yes" || raw === "on") return true;
|
|
2363
|
+
}
|
|
2364
|
+
/**
|
|
2365
|
+
* Whether the git-remote read can change any outcome, consulted before
|
|
2366
|
+
* `discoverAzureRepo` so a launch that already knows its answer does not pay
|
|
2367
|
+
* for the probe.
|
|
2368
|
+
*/
|
|
2369
|
+
function cloudAgentDiscoveryNeeded(inputs = {}) {
|
|
2370
|
+
const env = inputs.env ?? process.env;
|
|
2371
|
+
if (azureMcpsSuppressed(env)) return false;
|
|
2372
|
+
return readIntent(inputs, env) === void 0;
|
|
2373
|
+
}
|
|
2374
|
+
/**
|
|
2375
|
+
* Turn the flag, the environment and the discovered repository into the final
|
|
2376
|
+
* verdict.
|
|
2377
|
+
*
|
|
2378
|
+
* The environment is validated here even when the group is off, because a
|
|
2379
|
+
* malformed value is an operator typo and a launch that silently ignores it
|
|
2380
|
+
* would surface later as "the group is missing" or, worse, as a token minted
|
|
2381
|
+
* for the wrong audience. `normalizeCloudAgentEnvironment` throws with the two
|
|
2382
|
+
* accepted values named.
|
|
2383
|
+
*/
|
|
2384
|
+
function resolveCloudAgentFlags(inputs, discovered) {
|
|
2385
|
+
const env = inputs.env ?? process.env;
|
|
2386
|
+
const environment = normalizeCloudAgentEnvironment(inputs.cloudAgentEnvironment?.trim() || env.GH_ROUTER_CLOUDAGENT_ENV?.trim() || "prod");
|
|
2387
|
+
const intent = readIntent(inputs, env);
|
|
2388
|
+
const reasons = [];
|
|
2389
|
+
let enabled = false;
|
|
2390
|
+
let fromDiscovery = false;
|
|
2391
|
+
if (intent === true) enabled = true;
|
|
2392
|
+
else if (intent === void 0 && !azureMcpsSuppressed(env) && discovered) {
|
|
2393
|
+
enabled = true;
|
|
2394
|
+
fromDiscovery = true;
|
|
2395
|
+
reasons.push(`Azure DevOps remote ${discovered.organization}/${discovered.project}/${discovered.repository}`);
|
|
2396
|
+
}
|
|
2397
|
+
return {
|
|
2398
|
+
enabled,
|
|
2399
|
+
environment,
|
|
2400
|
+
discovered: fromDiscovery,
|
|
2401
|
+
reasons
|
|
2402
|
+
};
|
|
2403
|
+
}
|
|
2404
|
+
//#endregion
|
|
2295
2405
|
//#region src/lib/first-mate/scheduler/autospawn.ts
|
|
2296
2406
|
/**
|
|
2297
2407
|
* Opt-in auto-spawn of the first-mate scheduler daemon as a SEPARATE process
|
|
@@ -2848,7 +2958,7 @@ function collectToolFieldKeys(body) {
|
|
|
2848
2958
|
//#endregion
|
|
2849
2959
|
//#region package.json
|
|
2850
2960
|
var name = "github-router";
|
|
2851
|
-
var version = "0.3.
|
|
2961
|
+
var version = "0.3.356";
|
|
2852
2962
|
//#endregion
|
|
2853
2963
|
//#region src/lib/approval.ts
|
|
2854
2964
|
const awaitApproval = async () => {
|
|
@@ -8122,7 +8232,13 @@ async function setupAndServe(options) {
|
|
|
8122
8232
|
kustoCluster: options.kustoCluster,
|
|
8123
8233
|
kustoDatabase: options.kustoDatabase
|
|
8124
8234
|
};
|
|
8125
|
-
const
|
|
8235
|
+
const cloudAgentInputs = {
|
|
8236
|
+
cloudAgentFlag: options.cloudAgentEnabled,
|
|
8237
|
+
cloudAgentEnvironment: options.cloudAgentEnvironment
|
|
8238
|
+
};
|
|
8239
|
+
const discovered = azureDiscoveryNeeded(azureInputs) || cloudAgentDiscoveryNeeded(cloudAgentInputs) ? await discoverAzureRepo({}) : null;
|
|
8240
|
+
const azureFlags = resolveAzureMcpFlags(azureInputs, discovered);
|
|
8241
|
+
const cloudAgentFlags = resolveCloudAgentFlags(cloudAgentInputs, discovered);
|
|
8126
8242
|
state.bluebirdEnabled = azureFlags.bluebird;
|
|
8127
8243
|
state.adoEnabled = azureFlags.ado;
|
|
8128
8244
|
state.adoOrganization = azureFlags.adoOrganization;
|
|
@@ -8131,10 +8247,17 @@ async function setupAndServe(options) {
|
|
|
8131
8247
|
state.kustoEnabled = azureFlags.kusto;
|
|
8132
8248
|
state.kustoCluster = azureFlags.kustoCluster;
|
|
8133
8249
|
state.kustoDatabase = azureFlags.kustoDatabase;
|
|
8250
|
+
state.cloudAgentEnabled = cloudAgentFlags.enabled;
|
|
8251
|
+
state.cloudAgentEnvironment = cloudAgentFlags.environment;
|
|
8134
8252
|
if (state.kustoEnabled && state.kustoCluster === null) consola.info("Kusto MCP: no default cluster; every call must name one (--kusto-cluster sets a default).");
|
|
8135
8253
|
for (const reason of azureFlags.reasons) consola.info(`Azure MCP auto-enabled (${reason}).`);
|
|
8136
8254
|
if (azureFlags.reasons.length > 0) consola.info("Suppress auto-enabled Azure surfaces with --no-bluebird / --no-ado / --no-kusto, or GH_ROUTER_AZURE_MCPS=off.");
|
|
8137
8255
|
for (const warning of azureFlags.warnings) consola.warn(`Azure MCP: ${warning}`);
|
|
8256
|
+
if (state.cloudAgentEnabled) {
|
|
8257
|
+
const source = cloudAgentFlags.reasons[0] ?? (options.cloudAgentEnabled === true ? "--cloudagent" : "GH_ROUTER_ENABLE_CLOUDAGENT");
|
|
8258
|
+
const veto = cloudAgentFlags.discovered ? " (--no-cloudagent opts out)" : "";
|
|
8259
|
+
consola.info(`Cloud Agent MCP (${state.cloudAgentEnvironment}): enabled by ${source}${veto}.`);
|
|
8260
|
+
}
|
|
8138
8261
|
if (state.adoEnabled && options.adoWriteEnabled === true) consola.warn("Azure DevOps MCP is running WITHOUT X-MCP-Readonly (--ado-write). Mutating tools are reachable from this session.");
|
|
8139
8262
|
if (state.adoEnabled) {
|
|
8140
8263
|
consola.info("Azure DevOps MCP: provisioning the remote tool surface...");
|
|
@@ -8338,6 +8461,16 @@ const sharedServerArgs = {
|
|
|
8338
8461
|
"kusto-database": {
|
|
8339
8462
|
type: "string",
|
|
8340
8463
|
description: "Default Kusto database for calls that do not name one, applied to whichever cluster the call resolves. Falls back to GH_ROUTER_KUSTO_DATABASE."
|
|
8464
|
+
},
|
|
8465
|
+
cloudagent: {
|
|
8466
|
+
type: "boolean",
|
|
8467
|
+
default: void 0,
|
|
8468
|
+
description: "Expose the Cloud Agent Job API v2 MCP group (mcp__cloudagent__*), all ten tools including create_job, create_pr_job and cancel_job. The whole group is enabled automatically in a checkout whose git remote is an Azure DevOps repository, like the --ado, --kusto and --bluebird groups; the create tools spend an hour or more of compute (measured median 66 min, max 447), so their descriptions tell the model to confirm with the user first. GH_ROUTER_ENABLE_CLOUDAGENT=1 is the env equivalent; --no-cloudagent is the veto. Authentication is automatic via `az account get-access-token`; no token to supply.",
|
|
8469
|
+
negativeDescription: "Never expose the Cloud Agent MCP group, even when the env equivalent is set or the repository is an Azure DevOps checkout."
|
|
8470
|
+
},
|
|
8471
|
+
"cloudagent-env": {
|
|
8472
|
+
type: "string",
|
|
8473
|
+
description: "Cloud Agent service environment: prod (default) or ppe. Naming one does NOT enable the group; it selects which service --cloudagent talks to, and which Entra audience the token is minted for. Falls back to GH_ROUTER_CLOUDAGENT_ENV."
|
|
8341
8474
|
}
|
|
8342
8475
|
};
|
|
8343
8476
|
const allowedAccountTypes = /* @__PURE__ */ new Set([
|
|
@@ -8401,7 +8534,9 @@ function parseSharedArgs(args) {
|
|
|
8401
8534
|
adoWriteEnabled: args["ado-write"],
|
|
8402
8535
|
kustoEnabled: args.kusto,
|
|
8403
8536
|
kustoCluster: args["kusto-cluster"],
|
|
8404
|
-
kustoDatabase: args["kusto-database"]
|
|
8537
|
+
kustoDatabase: args["kusto-database"],
|
|
8538
|
+
cloudAgentEnabled: args.cloudagent,
|
|
8539
|
+
cloudAgentEnvironment: args["cloudagent-env"]
|
|
8405
8540
|
};
|
|
8406
8541
|
}
|
|
8407
8542
|
/**
|
|
@@ -8657,4 +8792,4 @@ function getPiLaunchEnvVars(mirrorDir) {
|
|
|
8657
8792
|
//#endregion
|
|
8658
8793
|
export { formatFastPrerequisiteFailure as A, runSelfUpdate as B, CHEAP_REVIEWER_ALIAS_ID as C, formatCheap1mPrerequisiteFailure as D, formatBalancedPrerequisiteFailure as E, validateCheapProfilePrerequisites as F, updateClaude as H, validateCheapestProfilePrerequisites as I, validateFastProfilePrerequisites as L, resolveLaunchProfile as M, validateBalancedProfilePrerequisites as N, formatCheapPrerequisiteFailure as O, validateCheap1mProfilePrerequisites as P, validateMaxProfileLaunch as R, CHEAP_PLAN_ALIAS_ID as S, MAX_BROWSE_LOW_ALIAS_ID as T, checkClaudeVersion as V, CHEAPEST_EXPLORE_ALIAS_ID as _, setupAndServe as a, CHEAP_EXPLORE_ALIAS_ID as b, startKeepAwake as c, listModelsForEndpoint as d, enableFileLogging as f, BROWSE_LOW_ALIAS_ID as g, BALANCED_REVIEWER_ALIAS_ID as h, parseSharedArgs as i, profileDescriptor as j, formatCheapestPrerequisiteFailure as k, stopKeepAwake as l, BALANCED_GENERAL_PURPOSE_ALIAS_ID as m, getCodexEnvVars as n, sharedServerArgs as o, BALANCED_EXPLORE_ALIAS_ID as p, getPiLaunchEnvVars as r, LAUNCH_SECRET_HEADER as s, getClaudeCodeEnvVars as t, injectModelPickerSettingsFile as u, CHEAPEST_GENERAL_PURPOSE_ALIAS_ID as v, LUNA_SCOUT_ALIAS_ID as w, CHEAP_GENERAL_PURPOSE_ALIAS_ID as x, CHEAPEST_REVIEWER_ALIAS_ID as y, queueDetachedGlobalInstall as z };
|
|
8659
8794
|
|
|
8660
|
-
//# sourceMappingURL=server-setup-
|
|
8795
|
+
//# sourceMappingURL=server-setup-VYf8ptCH.js.map
|