github-router 0.3.357 → 0.3.367
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-rysFZDws.js +1 -0
- package/dist/{aic-ledger-BuFrsGur.js → aic-ledger-_mvGW2Ev.js} +42 -7
- package/dist/aic-ledger-_mvGW2Ev.js.map +1 -0
- package/dist/{aic-statusline-settings-DBS9sEGC.js → aic-statusline-settings-B5EMMSFC.js} +2 -2
- package/dist/{aic-statusline-settings-DBS9sEGC.js.map → aic-statusline-settings-B5EMMSFC.js.map} +1 -1
- package/dist/{attribution-settings-D9PxJxkL.js → attribution-settings-wVzQvIdL.js} +188 -64
- package/dist/attribution-settings-wVzQvIdL.js.map +1 -0
- package/dist/{auth-DFawaLJU.js → auth-B3UvYB2r.js} +3 -3
- package/dist/{auth-DFawaLJU.js.map → auth-B3UvYB2r.js.map} +1 -1
- package/dist/browser-ext/manifest.json +1 -1
- package/dist/{check-usage-BkVEl-Su.js → check-usage-45vyaLfl.js} +4 -4
- package/dist/{check-usage-BkVEl-Su.js.map → check-usage-45vyaLfl.js.map} +1 -1
- package/dist/{claude-BTYQjK-K.js → claude-B3pIageM.js} +89 -41
- package/dist/claude-B3pIageM.js.map +1 -0
- package/dist/{claude-md-injection-Cpzolxin.js → claude-md-injection-BV4tPUWo.js} +126 -35
- package/dist/claude-md-injection-BV4tPUWo.js.map +1 -0
- package/dist/{codex-TdsG6C9K.js → codex-B_AMB6JM.js} +7 -7
- package/dist/{codex-TdsG6C9K.js.map → codex-B_AMB6JM.js.map} +1 -1
- package/dist/{copilot-discount-Bsmv_3OX.js → copilot-discount-BuDbQOHq.js} +2 -2
- package/dist/{copilot-discount-Bsmv_3OX.js.map → copilot-discount-BuDbQOHq.js.map} +1 -1
- package/dist/{debug-DkNTuErv.js → debug-DL2JsRqY.js} +2 -2
- package/dist/{debug-DkNTuErv.js.map → debug-DL2JsRqY.js.map} +1 -1
- package/dist/engine-D3oNrF6Z.js +1 -0
- package/dist/{gate-discovery-NNQg0t0H.js → gate-discovery-CXE-7VcM.js} +5 -5
- package/dist/{gate-discovery-NNQg0t0H.js.map → gate-discovery-CXE-7VcM.js.map} +1 -1
- package/dist/{get-copilot-usage-P9chc-X2.js → get-copilot-usage-BbGmK03C.js} +2 -2
- package/dist/{get-copilot-usage-P9chc-X2.js.map → get-copilot-usage-BbGmK03C.js.map} +1 -1
- package/dist/hooks.mjs +200 -117
- package/dist/hooks.sha256 +1 -1
- package/dist/{index-cmd-BkfYr9FH.js → index-cmd-CjRcmYk3.js} +4 -4
- package/dist/{index-cmd-BkfYr9FH.js.map → index-cmd-CjRcmYk3.js.map} +1 -1
- package/dist/{internal-aic-status-C6L4-ncP.js → internal-aic-status-BAVomi5A.js} +4 -4
- package/dist/{internal-aic-status-C6L4-ncP.js.map → internal-aic-status-BAVomi5A.js.map} +1 -1
- package/dist/{internal-artifact-open-DgJ3PCtt.js → internal-artifact-open-NAGn9Mgt.js} +2 -2
- package/dist/{internal-artifact-open-DgJ3PCtt.js.map → internal-artifact-open-NAGn9Mgt.js.map} +1 -1
- package/dist/{internal-fast-dispatch-guard-CicGz6oM.js → internal-fast-dispatch-guard-DP25L_Bx.js} +1 -1
- package/dist/{internal-fast-dispatch-guard-CgBtUsQI.js → internal-fast-dispatch-guard-DbrgO9Ab.js} +2 -2
- package/dist/{internal-fast-dispatch-guard-CgBtUsQI.js.map → internal-fast-dispatch-guard-DbrgO9Ab.js.map} +1 -1
- package/dist/{internal-first-mate-guard-DTXPT7JW.js → internal-first-mate-guard-C8GwLbaX.js} +1 -1
- package/dist/{internal-first-mate-guard-BfWYN6Jb.js → internal-first-mate-guard-GufCUMl3.js} +3 -3
- package/dist/{internal-first-mate-guard-BfWYN6Jb.js.map → internal-first-mate-guard-GufCUMl3.js.map} +1 -1
- package/dist/{internal-max-dispatch-guard-mNl9CCir.js → internal-max-dispatch-guard-BB0vwiPx.js} +1 -1
- package/dist/{internal-max-dispatch-guard-CY8l9SDw.js → internal-max-dispatch-guard-BodVFHRC.js} +2 -2
- package/dist/{internal-max-dispatch-guard-CY8l9SDw.js.map → internal-max-dispatch-guard-BodVFHRC.js.map} +1 -1
- package/dist/{internal-plan-review-2OHTs8Nk.js → internal-plan-review-ChFx8wTX.js} +3 -3
- package/dist/{internal-plan-review-2OHTs8Nk.js.map → internal-plan-review-ChFx8wTX.js.map} +1 -1
- package/dist/{internal-prompt-submit-CkfUcu34.js → internal-prompt-submit-BaccW_CC.js} +4 -4
- package/dist/{internal-prompt-submit-CkfUcu34.js.map → internal-prompt-submit-BaccW_CC.js.map} +1 -1
- package/dist/{internal-prompt-submit-DZ_-2A6a.js → internal-prompt-submit-DPUBQZtG.js} +2 -2
- package/dist/{internal-rebrief-EhBHAHsz.js → internal-rebrief-NjSlx5QY.js} +4 -4
- package/dist/{internal-rebrief-EhBHAHsz.js.map → internal-rebrief-NjSlx5QY.js.map} +1 -1
- package/dist/{internal-session-bind-Bv50ju2n.js → internal-session-bind-dsUOcKxU.js} +2 -2
- package/dist/{internal-session-bind-Bv50ju2n.js.map → internal-session-bind-dsUOcKxU.js.map} +1 -1
- package/dist/{internal-stop-hook-Iz8XXE07.js → internal-stop-hook-B2TTl6Zp.js} +5 -5
- package/dist/{internal-stop-hook-Iz8XXE07.js.map → internal-stop-hook-B2TTl6Zp.js.map} +1 -1
- package/dist/{internal-stop-review-K6f8xsCh.js → internal-stop-review-D_KEV_04.js} +2 -2
- package/dist/{internal-stop-review-K6f8xsCh.js.map → internal-stop-review-D_KEV_04.js.map} +1 -1
- package/dist/{internal-worker-guard-GVhTjVlR.js → internal-worker-guard-DB6shBIn.js} +2 -2
- package/dist/{internal-worker-guard-GVhTjVlR.js.map → internal-worker-guard-DB6shBIn.js.map} +1 -1
- package/dist/{internal-workspace-header-d2hFf9Jy.js → internal-workspace-header-DBg5Y7oN.js} +2 -2
- package/dist/{internal-workspace-header-d2hFf9Jy.js.map → internal-workspace-header-DBg5Y7oN.js.map} +1 -1
- package/dist/{lifecycle-C6cxM_Nk.js → lifecycle-9nX09dBl.js} +2 -2
- package/dist/{lifecycle-C6cxM_Nk.js.map → lifecycle-9nX09dBl.js.map} +1 -1
- package/dist/lifecycle-C_CT13c9.js +1 -0
- package/dist/lifecycle-DibiH857.js +1 -0
- package/dist/{lifecycle-pl9QpvqD.js → lifecycle-Gge2Dadd.js} +2 -2
- package/dist/{lifecycle-pl9QpvqD.js.map → lifecycle-Gge2Dadd.js.map} +1 -1
- package/dist/main.js +23 -23
- package/dist/{mcp-workspace-header-Su8uUxJg.js → mcp-workspace-header-Xw9B1W6T.js} +2 -2
- package/dist/{mcp-workspace-header-Su8uUxJg.js.map → mcp-workspace-header-Xw9B1W6T.js.map} +1 -1
- package/dist/{models-D8v8OTbN.js → models-BR6i348u.js} +3 -3
- package/dist/{models-D8v8OTbN.js.map → models-BR6i348u.js.map} +1 -1
- package/dist/{orchestration-Bov4rZEi.js → orchestration-D3-2ulhX.js} +2 -2
- package/dist/{orchestration-Bov4rZEi.js.map → orchestration-D3-2ulhX.js.map} +1 -1
- package/dist/{paths-BSI_EtDT.js → paths-C5477RGC.js} +48 -4
- package/dist/paths-C5477RGC.js.map +1 -0
- package/dist/paths-CEswtFj5.js +1 -0
- package/dist/{peer-mcp-personas-GANlrtNR.js → peer-mcp-personas-BOgR46nM.js} +519 -169
- package/dist/peer-mcp-personas-BOgR46nM.js.map +1 -0
- package/dist/{pi-TKFwPyLA.js → pi-DcWp83mx.js} +377 -602
- package/dist/pi-DcWp83mx.js.map +1 -0
- package/dist/{plan-review-hook-CHK1wL3-.js → plan-review-hook-C9K-em4D.js} +3 -3
- package/dist/{plan-review-hook-CHK1wL3-.js.map → plan-review-hook-C9K-em4D.js.map} +1 -1
- package/dist/{provision-BNN6yRk8.js → provision-DkWR9B6I.js} +5 -5
- package/dist/{provision-BNN6yRk8.js.map → provision-DkWR9B6I.js.map} +1 -1
- package/dist/{self-invocation-Dk_UHD_v.js → self-invocation-BtcGj-lY.js} +2 -2
- package/dist/{self-invocation-Dk_UHD_v.js.map → self-invocation-BtcGj-lY.js.map} +1 -1
- package/dist/{serve-BaeLm9Um.js → serve-BGwEVDdc.js} +14 -14
- package/dist/{serve-BaeLm9Um.js.map → serve-BGwEVDdc.js.map} +1 -1
- package/dist/{server-setup-BcUQv5ac.js → server-setup-DVPL9iph.js} +911 -100
- package/dist/server-setup-DVPL9iph.js.map +1 -0
- package/dist/{service-backend-DHyd9vjW.js → service-backend-B6D_DY1Z.js} +3 -3
- package/dist/{service-backend-DHyd9vjW.js.map → service-backend-B6D_DY1Z.js.map} +1 -1
- package/dist/{start-BdoGJc36.js → start-BUWx3nSr.js} +4 -4
- package/dist/{start-BdoGJc36.js.map → start-BUWx3nSr.js.map} +1 -1
- package/dist/{static-context-pack-dKrzbfIN.js → static-context-pack-ChHuxBpk.js} +232 -61
- package/dist/static-context-pack-ChHuxBpk.js.map +1 -0
- package/dist/{stop-gate-hook-CC7VWkZM.js → stop-gate-hook-DnLC09Lg.js} +3 -3
- package/dist/{stop-gate-hook-CC7VWkZM.js.map → stop-gate-hook-DnLC09Lg.js.map} +1 -1
- package/dist/{stop-gate-policy-CoR8xKNQ.js → stop-gate-policy-Dx9c98_d.js} +2 -2
- package/dist/{stop-gate-policy-CoR8xKNQ.js.map → stop-gate-policy-Dx9c98_d.js.map} +1 -1
- package/dist/{token-CA2s70qj.js → token-OTb61rOC.js} +2 -2
- package/dist/{token-CA2s70qj.js.map → token-OTb61rOC.js.map} +1 -1
- package/dist/{worker-dispatch-B_rriT7z.js → worker-dispatch-B1w2qfjX.js} +2 -2
- package/dist/{worker-dispatch-B_rriT7z.js.map → worker-dispatch-B1w2qfjX.js.map} +1 -1
- package/docs/azure-mcp.md +29 -31
- package/package.json +1 -1
- package/dist/ado-tools-DqLJ-u19.js +0 -1
- package/dist/aic-ledger-BuFrsGur.js.map +0 -1
- package/dist/attribution-settings-D9PxJxkL.js.map +0 -1
- package/dist/claude-BTYQjK-K.js.map +0 -1
- package/dist/claude-md-injection-Cpzolxin.js.map +0 -1
- package/dist/engine-CmhUwYI5.js +0 -1
- package/dist/lifecycle-BU_d2QMs.js +0 -1
- package/dist/lifecycle-ByFyew_w.js +0 -1
- package/dist/paths-BSI_EtDT.js.map +0 -1
- package/dist/paths-BYxX9DfA.js +0 -1
- package/dist/peer-mcp-personas-GANlrtNR.js.map +0 -1
- package/dist/pi-TKFwPyLA.js.map +0 -1
- package/dist/server-setup-BcUQv5ac.js.map +0 -1
- package/dist/static-context-pack-dKrzbfIN.js.map +0 -1
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { i as ensurePaths, t as PATHS } from "./paths-
|
|
1
|
+
import { i as ensurePaths, t as PATHS } from "./paths-C5477RGC.js";
|
|
2
2
|
import { t as state } from "./state-CiwCLVDZ.js";
|
|
3
|
-
import { r as setupGitHubToken } from "./token-
|
|
3
|
+
import { r as setupGitHubToken } from "./token-OTb61rOC.js";
|
|
4
4
|
import { defineCommand } from "citty";
|
|
5
5
|
import consola from "consola";
|
|
6
6
|
//#region src/auth.ts
|
|
@@ -42,4 +42,4 @@ const auth = defineCommand({
|
|
|
42
42
|
//#endregion
|
|
43
43
|
export { auth };
|
|
44
44
|
|
|
45
|
-
//# sourceMappingURL=auth-
|
|
45
|
+
//# sourceMappingURL=auth-B3UvYB2r.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"auth-
|
|
1
|
+
{"version":3,"file":"auth-B3UvYB2r.js","names":[],"sources":["../src/auth.ts"],"sourcesContent":["#!/usr/bin/env node\n\nimport { defineCommand } from \"citty\"\nimport consola from \"consola\"\n\nimport { PATHS, ensurePaths } from \"./lib/paths\"\nimport { state } from \"./lib/state\"\nimport { setupGitHubToken } from \"./lib/token\"\n\ninterface RunAuthOptions {\n verbose: boolean\n showToken: boolean\n}\n\nexport async function runAuth(options: RunAuthOptions): Promise<void> {\n if (options.verbose) {\n consola.level = 5\n consola.info(\"Verbose logging enabled\")\n }\n\n state.showToken = options.showToken\n\n await ensurePaths()\n await setupGitHubToken({ force: true })\n consola.success(\"GitHub token written to\", PATHS.GITHUB_TOKEN_PATH)\n}\n\nexport const auth = defineCommand({\n meta: {\n name: \"auth\",\n description: \"Run GitHub auth flow without running the server\",\n },\n args: {\n verbose: {\n alias: \"v\",\n type: \"boolean\",\n default: false,\n description: \"Enable verbose logging\",\n },\n \"show-token\": {\n type: \"boolean\",\n default: false,\n description: \"Show GitHub token on auth\",\n },\n },\n run({ args }) {\n return runAuth({\n verbose: args.verbose,\n showToken: args[\"show-token\"],\n })\n },\n})\n"],"mappings":";;;;;;AAcA,eAAsB,QAAQ,SAAwC;CACpE,IAAI,QAAQ,SAAS;EACnB,QAAQ,QAAQ;EAChB,QAAQ,KAAK,yBAAyB;CACxC;CAEA,MAAM,YAAY,QAAQ;CAE1B,MAAM,YAAY;CAClB,MAAM,iBAAiB,EAAE,OAAO,KAAK,CAAC;CACtC,QAAQ,QAAQ,2BAA2B,MAAM,iBAAiB;AACpE;AAEA,MAAa,OAAO,cAAc;CAChC,MAAM;EACJ,MAAM;EACN,aAAa;CACf;CACA,MAAM;EACJ,SAAS;GACP,OAAO;GACP,MAAM;GACN,SAAS;GACT,aAAa;EACf;EACA,cAAc;GACZ,MAAM;GACN,SAAS;GACT,aAAa;EACf;CACF;CACA,IAAI,EAAE,QAAQ;EACZ,OAAO,QAAQ;GACb,SAAS,KAAK;GACd,WAAW,KAAK;EAClB,CAAC;CACH;AACF,CAAC"}
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"manifest_version": 3,
|
|
3
3
|
"name": "github-router browser bridge",
|
|
4
4
|
"short_name": "gh-router-browser",
|
|
5
|
-
"version": "0.3.
|
|
5
|
+
"version": "0.3.367",
|
|
6
6
|
"description": "Bridge between Claude (via github-router /mcp) and the browser. Implements tab control, navigation, clicks, form fill, downloads, screenshots, devtools eval. Blocks navigation to chrome://settings.",
|
|
7
7
|
"key": "MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAqJElxuBlonBS3TVW9FJN0mGTtShB3L1hoaYf6k39SOr1ogGYmF90EjRxy1i21k9wQQjPf26bcBu/9X67KrQjQV0uB38CaNukgiSeoLjfptN811u+PJHx6BP+jx3Qa6/3VenNPxHC8WEU0GXql8QSjIHEyCwKb6fMASXOK94JyB5Ywov2x8mt/+9ncqBBBMVzf6r5Sagy4PL1XnryLsuADD/vOEkPet8wXgH/Oj7v5tTsQQZ7U1JT51PoDs2BFnXc5v3TkVgZwd32k3ONh+nkDw1Hof+4zwUGOyJE6eMrlYzRlKM4Qxdf9JpavQvqfieAbTRWcyKeclnHeoIfE7cDBQIDAQAB",
|
|
8
8
|
"background": {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { i as ensurePaths } from "./paths-
|
|
2
|
-
import { r as setupGitHubToken } from "./token-
|
|
3
|
-
import { t as getCopilotUsage } from "./get-copilot-usage-
|
|
1
|
+
import { i as ensurePaths } from "./paths-C5477RGC.js";
|
|
2
|
+
import { r as setupGitHubToken } from "./token-OTb61rOC.js";
|
|
3
|
+
import { t as getCopilotUsage } from "./get-copilot-usage-BbGmK03C.js";
|
|
4
4
|
import { defineCommand } from "citty";
|
|
5
5
|
import consola from "consola";
|
|
6
6
|
//#region src/check-usage.ts
|
|
@@ -40,4 +40,4 @@ const checkUsage = defineCommand({
|
|
|
40
40
|
//#endregion
|
|
41
41
|
export { checkUsage };
|
|
42
42
|
|
|
43
|
-
//# sourceMappingURL=check-usage-
|
|
43
|
+
//# sourceMappingURL=check-usage-45vyaLfl.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"check-usage-
|
|
1
|
+
{"version":3,"file":"check-usage-45vyaLfl.js","names":[],"sources":["../src/check-usage.ts"],"sourcesContent":["import { defineCommand } from \"citty\"\nimport consola from \"consola\"\n\nimport { ensurePaths } from \"./lib/paths\"\nimport { setupGitHubToken } from \"./lib/token\"\nimport {\n getCopilotUsage,\n type QuotaDetail,\n} from \"./services/github/get-copilot-usage\"\n\nexport const checkUsage = defineCommand({\n meta: {\n name: \"check-usage\",\n description: \"Show current GitHub Copilot usage/quota information\",\n },\n async run() {\n await ensurePaths()\n await setupGitHubToken()\n try {\n const usage = await getCopilotUsage()\n const premium = usage.quota_snapshots.premium_interactions\n const premiumTotal = premium.entitlement\n const premiumUsed = premiumTotal - premium.remaining\n const premiumPercentUsed =\n premiumTotal > 0 ? (premiumUsed / premiumTotal) * 100 : 0\n const premiumPercentRemaining = premium.percent_remaining\n\n // Helper to summarize a quota snapshot\n function summarizeQuota(name: string, snap: QuotaDetail | undefined) {\n if (!snap) return `${name}: N/A`\n const total = snap.entitlement\n const used = total - snap.remaining\n const percentUsed = total > 0 ? (used / total) * 100 : 0\n const percentRemaining = snap.percent_remaining\n return `${name}: ${used}/${total} used (${percentUsed.toFixed(1)}% used, ${percentRemaining.toFixed(1)}% remaining)`\n }\n\n const premiumLine = `Premium: ${premiumUsed}/${premiumTotal} used (${premiumPercentUsed.toFixed(1)}% used, ${premiumPercentRemaining.toFixed(1)}% remaining)`\n const chatLine = summarizeQuota(\"Chat\", usage.quota_snapshots.chat)\n const completionsLine = summarizeQuota(\n \"Completions\",\n usage.quota_snapshots.completions,\n )\n\n consola.box(\n `Copilot Usage (plan: ${usage.copilot_plan})\\n`\n + `Quota resets: ${usage.quota_reset_date}\\n`\n + `\\nQuotas:\\n`\n + ` ${premiumLine}\\n`\n + ` ${chatLine}\\n`\n + ` ${completionsLine}`,\n )\n } catch (err) {\n consola.error(\"Failed to fetch Copilot usage:\", err)\n process.exit(1)\n }\n },\n})\n"],"mappings":";;;;;;AAUA,MAAa,aAAa,cAAc;CACtC,MAAM;EACJ,MAAM;EACN,aAAa;CACf;CACA,MAAM,MAAM;EACV,MAAM,YAAY;EAClB,MAAM,iBAAiB;EACvB,IAAI;GACF,MAAM,QAAQ,MAAM,gBAAgB;GACpC,MAAM,UAAU,MAAM,gBAAgB;GACtC,MAAM,eAAe,QAAQ;GAC7B,MAAM,cAAc,eAAe,QAAQ;GAC3C,MAAM,qBACJ,eAAe,IAAK,cAAc,eAAgB,MAAM;GAC1D,MAAM,0BAA0B,QAAQ;GAGxC,SAAS,eAAe,MAAc,MAA+B;IACnE,IAAI,CAAC,MAAM,OAAO,GAAG,KAAK;IAC1B,MAAM,QAAQ,KAAK;IACnB,MAAM,OAAO,QAAQ,KAAK;IAC1B,MAAM,cAAc,QAAQ,IAAK,OAAO,QAAS,MAAM;IACvD,MAAM,mBAAmB,KAAK;IAC9B,OAAO,GAAG,KAAK,IAAI,KAAK,GAAG,MAAM,SAAS,YAAY,QAAQ,CAAC,EAAE,UAAU,iBAAiB,QAAQ,CAAC,EAAE;GACzG;GAEA,MAAM,cAAc,YAAY,YAAY,GAAG,aAAa,SAAS,mBAAmB,QAAQ,CAAC,EAAE,UAAU,wBAAwB,QAAQ,CAAC,EAAE;GAChJ,MAAM,WAAW,eAAe,QAAQ,MAAM,gBAAgB,IAAI;GAClE,MAAM,kBAAkB,eACtB,eACA,MAAM,gBAAgB,WACxB;GAEA,QAAQ,IACN,wBAAwB,MAAM,aAAa,mBACtB,MAAM,iBAAiB,iBAEnC,YAAY,MACZ,SAAS,MACT,iBACX;EACF,SAAS,KAAK;GACZ,QAAQ,MAAM,kCAAkC,GAAG;GACnD,QAAQ,KAAK,CAAC;EAChB;CACF;AACF,CAAC"}
|
|
@@ -1,30 +1,30 @@
|
|
|
1
|
-
import { P as warmTreeSitterPool } from "./service-backend-
|
|
2
|
-
import { d as writeArtifactCredsToMirror, o as purgeNonRouterAgentsFromMirror, r as ensureClaudeConfigMirror, s as removeOwnClaudeConfigMirror, t as PATHS } from "./paths-
|
|
1
|
+
import { P as warmTreeSitterPool } from "./service-backend-B6D_DY1Z.js";
|
|
2
|
+
import { d as writeArtifactCredsToMirror, f as writeLaunchBoundSyntheticCredential, o as purgeNonRouterAgentsFromMirror, r as ensureClaudeConfigMirror, s as removeOwnClaudeConfigMirror, t as PATHS } from "./paths-C5477RGC.js";
|
|
3
3
|
import { t as state } from "./state-CiwCLVDZ.js";
|
|
4
|
-
import { d as resolveModel } from "./token-
|
|
4
|
+
import { d as resolveModel } from "./token-OTb61rOC.js";
|
|
5
5
|
import { a as parseBoolEnv } from "./exec-Bf8g_bIR.js";
|
|
6
|
-
import {
|
|
6
|
+
import { $ as runSelfUpdate, B as formatCheapPrerequisiteFailure, C as listModelsForEndpoint, G as resolveLaunchProfile, H as formatFastPrerequisiteFailure, J as validateCheapProfilePrerequisites, K as validateBalancedProfilePrerequisites, Q as validateMaxProfileLaunch, R as formatBalancedPrerequisiteFailure, S as injectModelPickerSettingsFile, U as formatLocalPrerequisiteFailure, V as formatCheapestPrerequisiteFailure, W as profileDescriptor, X as validateFastProfilePrerequisites, Y as validateCheapestProfilePrerequisites, Z as validateLocalProfilePrerequisites, a as setupAndServe, b as startKeepAwake, c as localBaseUrl, et as checkClaudeVersion, i as parseSharedArgs, l as LAUNCH_SECRET_HEADER, o as sharedServerArgs, q as validateCheap1mProfilePrerequisites, s as configureLocalEgress, t as getClaudeCodeEnvVars, tt as updateClaude, w as enableFileLogging, x as stopKeepAwake, z as formatCheap1mPrerequisiteFailure } from "./server-setup-DVPL9iph.js";
|
|
7
7
|
import { t as FAST_PROFILE_ADVISOR_CLIENT_MODEL } from "./fast-profile-contract-JOnZBgFB.js";
|
|
8
|
-
import { At as
|
|
9
|
-
import {
|
|
8
|
+
import { At as cloudAgentToolsEnabled, Bn as isBudgetClaudeLead, Bt as generalPurposeFastModel, Ct as browserToolsEnabled, D as toolbeltEnabled, Dn as semanticSearchOptedIn, Dt as cheapestAdvisorModel, E as buildToolbeltAwareness, En as provisionAndIndexColbert, Et as cheapReviewerModel, Ft as fastPlanModel, Gt as reviewerFastModel, Hn as resolveLeadSlugArg, Ht as kustoToolsEnabled, It as fastReviewerModel, Jt as scribeModel, Kt as reviewerModel, Lt as fastScoutModel, Mt as fastAstraModel, Nn as DEFAULT_CLAUDE_MODEL_FALLBACKS, Nt as fastGeneralPurposeModel, On as shouldUseInsecureTls, Ot as cheapestOracleModel, Pt as fastOracleModel, Rt as fleetToolsEnabled, St as browserCompoundToolsEnabled, T as availableToolCommands, Tn as colbertDegradedWarning, Tt as cheapOracleModel, Ut as nativeSubagentModel, Vn as pickClaudeDefault, Vt as implementerFastModel, Wt as resolveGeminiReviewModel, Xn as CHEAP_PROFILE_ADVISOR_CLIENT_MODEL, Xt as workerToolsEnabled, Yt as standInToolEnabled, Zn as CHEAP_PROFILE_MODELS, _t as artifactToolsEnabled, an as launchBoundAccessToken, bt as brainstormModel, er as CHEAP_PROFILE_NATIVE_MODELS, gt as agentToolsEnabled, ht as adoToolsEnabled, jt as fastAdvisorModel, kt as cheapestReviewerModel, o as buildPeerAwarenessSnippet, on as registerLaunch, qt as scoutModel, r as agentNamesForToolAllowlist, s as buildPeerAwarenessSummary, sn as unregisterLaunch, vt as balancedOracleModel, wt as cheapAdvisorModel, xt as browseAgentEnabled, yn as provisionBrowserAssets, yt as balancedReviewerModel, zt as geminiAvailable } from "./peer-mcp-personas-BOgR46nM.js";
|
|
9
|
+
import { O as CHEAPEST_PROFILE_ADVISOR_CLIENT_MODEL, _ as isCheapestFamily, b as local2AdvisorContract, f as balancedContractFor, g as isBalancedFamily, h as displayModelName, p as cheapestContractFor, r as buildPromptSubmitHookCommand, v as isLocalFamily, x as localContractFor, y as isPinnedLaunchProfile } from "./static-context-pack-ChHuxBpk.js";
|
|
10
10
|
import { _ as maxReviewerModel, c as formatMaxPrerequisiteFailure, f as maxCodexReviewerModel, h as maxOpusModel, i as MAX_PROFILE_MODELS, m as maxGrokModel, o as MAX_PROFILE_NATIVE_EFFORTS, p as maxGeminiModel, v as maxSonnetModel } from "./max-profile-contract-Cx5_Z1Y7.js";
|
|
11
|
-
import { n as hookLauncherDegradedWarning, r as resolveSelfInvocation } from "./self-invocation-
|
|
12
|
-
import { i as launchChild, r as getCodexVersion, t as provisionToolbelt } from "./provision-
|
|
13
|
-
import { d as stopGateEnabledForRepo, l as repoFingerprint, p as trustRepo, t as fileBaselineStore, u as repoRoot } from "./stop-gate-policy-
|
|
14
|
-
import { d as sweepStaleAicLedgerFiles, n as aicSnapshot, o as formatAicExitSummary, t as aicLedgerPath
|
|
15
|
-
import { d as stopGateId, i as captureLaunchBaseline, l as purgeNonRouterHooksForPinnedProfile, n as buildSessionBindHookCommand, r as buildStopHookCommand, s as injectStopHookIntoSettingsFile, t as buildArtifactOpenHookCommand, u as stopGateDisabled } from "./stop-gate-hook-
|
|
16
|
-
import { t as liveExec } from "./orchestration-
|
|
17
|
-
import { l as guardToolMatcher, n as activeDispatchModes, r as buildWorkerGuardHookCommand } from "./worker-dispatch-
|
|
18
|
-
import { a as buildArtifactReviewSkill, c as injectAllowRules, f as injectPeerMcpIntoMirror, g as writePeerMcpRuntimeFiles, h as workersKeyOf, i as writeInjectedSkill, l as planModeAllowRules, m as resolveGroupKeysFromMirror, p as resolveCodexCliBackend, r as injectedSkillsForLaunch, t as injectAttributionSuppressionIntoSettingsFile } from "./attribution-settings-
|
|
11
|
+
import { n as hookLauncherDegradedWarning, r as resolveSelfInvocation } from "./self-invocation-BtcGj-lY.js";
|
|
12
|
+
import { i as launchChild, r as getCodexVersion, t as provisionToolbelt } from "./provision-DkWR9B6I.js";
|
|
13
|
+
import { d as stopGateEnabledForRepo, l as repoFingerprint, p as trustRepo, t as fileBaselineStore, u as repoRoot } from "./stop-gate-policy-Dx9c98_d.js";
|
|
14
|
+
import { d as removeAicLedgerFile, f as sweepStaleAicLedgerFiles, n as aicSnapshot, o as formatAicExitSummary, t as aicLedgerPath } from "./aic-ledger-_mvGW2Ev.js";
|
|
15
|
+
import { d as stopGateId, i as captureLaunchBaseline, l as purgeNonRouterHooksForPinnedProfile, n as buildSessionBindHookCommand, r as buildStopHookCommand, s as injectStopHookIntoSettingsFile, t as buildArtifactOpenHookCommand, u as stopGateDisabled } from "./stop-gate-hook-DnLC09Lg.js";
|
|
16
|
+
import { t as liveExec } from "./orchestration-D3-2ulhX.js";
|
|
17
|
+
import { l as guardToolMatcher, n as activeDispatchModes, r as buildWorkerGuardHookCommand } from "./worker-dispatch-B1w2qfjX.js";
|
|
18
|
+
import { a as buildArtifactReviewSkill, c as injectAllowRules, f as injectPeerMcpIntoMirror, g as writePeerMcpRuntimeFiles, h as workersKeyOf, i as writeInjectedSkill, l as planModeAllowRules, m as resolveGroupKeysFromMirror, p as resolveCodexCliBackend, r as injectedSkillsForLaunch, t as injectAttributionSuppressionIntoSettingsFile } from "./attribution-settings-wVzQvIdL.js";
|
|
19
19
|
import { r as hookMcpRuntimeFromEnv } from "./hook-mcp-client-DERIkeR7.js";
|
|
20
|
-
import { i as planReviewEnabled, t as buildPlanReviewHookCommand } from "./plan-review-hook-
|
|
21
|
-
import { a as checksForDescriptor, i as writeDiscoveredGate, n as readDiscoveredGate, o as descriptorHash, r as sourcesHash, s as parseGateDescriptor, t as discoverGateCommands } from "./gate-discovery-
|
|
22
|
-
import { i as assertShapingInstalled, n as buildFirstMateGuardHookCommand, t as FIRST_MATE_GUARD_MATCHER } from "./internal-first-mate-guard-
|
|
23
|
-
import { r as FAST_DISPATCH_TOOL_MATCHER, t as buildFastDispatchGuardHookCommand } from "./internal-fast-dispatch-guard-
|
|
24
|
-
import { i as assertMaxDispatchGuardInstalled, r as MAX_DISPATCH_TOOL_MATCHER, t as buildMaxDispatchGuardHookCommand } from "./internal-max-dispatch-guard-
|
|
25
|
-
import { a as buildOperatingDefaultsDirective, c as prependOperatingDefaultsToMirroredClaudeMd, i as buildOperatingDefaultsDigest, l as prependStyleDirectiveToMirroredClaudeMd, n as appendPeerAwarenessToMirroredClaudeMd, r as appendToolbeltAwarenessToMirroredClaudeMd, s as prependArtifactPanelDirectiveToMirroredClaudeMd } from "./claude-md-injection-
|
|
26
|
-
import { a as injectAicStatusLineIntoSettingsFile, i as buildAicStatusHookCommand, r as AIC_USER_STATUSLINE_ENV, t as AIC_LEDGER_ENV } from "./aic-statusline-settings-
|
|
27
|
-
import { n as formatDiscountedCostTable, t as discountedUsdForSnapshot } from "./copilot-discount-
|
|
20
|
+
import { i as planReviewEnabled, t as buildPlanReviewHookCommand } from "./plan-review-hook-C9K-em4D.js";
|
|
21
|
+
import { a as checksForDescriptor, i as writeDiscoveredGate, n as readDiscoveredGate, o as descriptorHash, r as sourcesHash, s as parseGateDescriptor, t as discoverGateCommands } from "./gate-discovery-CXE-7VcM.js";
|
|
22
|
+
import { i as assertShapingInstalled, n as buildFirstMateGuardHookCommand, t as FIRST_MATE_GUARD_MATCHER } from "./internal-first-mate-guard-GufCUMl3.js";
|
|
23
|
+
import { r as FAST_DISPATCH_TOOL_MATCHER, t as buildFastDispatchGuardHookCommand } from "./internal-fast-dispatch-guard-DbrgO9Ab.js";
|
|
24
|
+
import { i as assertMaxDispatchGuardInstalled, r as MAX_DISPATCH_TOOL_MATCHER, t as buildMaxDispatchGuardHookCommand } from "./internal-max-dispatch-guard-BodVFHRC.js";
|
|
25
|
+
import { a as buildOperatingDefaultsDirective, c as prependOperatingDefaultsToMirroredClaudeMd, i as buildOperatingDefaultsDigest, l as prependStyleDirectiveToMirroredClaudeMd, n as appendPeerAwarenessToMirroredClaudeMd, r as appendToolbeltAwarenessToMirroredClaudeMd, s as prependArtifactPanelDirectiveToMirroredClaudeMd } from "./claude-md-injection-BV4tPUWo.js";
|
|
26
|
+
import { a as injectAicStatusLineIntoSettingsFile, i as buildAicStatusHookCommand, r as AIC_USER_STATUSLINE_ENV, t as AIC_LEDGER_ENV } from "./aic-statusline-settings-B5EMMSFC.js";
|
|
27
|
+
import { n as formatDiscountedCostTable, t as discountedUsdForSnapshot } from "./copilot-discount-BuDbQOHq.js";
|
|
28
28
|
import { defineCommand } from "citty";
|
|
29
29
|
import consola from "consola";
|
|
30
30
|
import path from "node:path";
|
|
@@ -219,7 +219,15 @@ const claudeArgs = {
|
|
|
219
219
|
model: {
|
|
220
220
|
alias: "m",
|
|
221
221
|
type: "string",
|
|
222
|
-
description: "Override the default model for Claude Code. Accepts a profile alias (fast, cheap, cheap1m, cheapest, cheapest2, balanced, balanced2, max), a full slug (e.g. claude-opus-4-7), or an Opus family shorthand (e.g. 4.7, 4.8, 4.6) which expands to the best variant for that family — adding the [1m] suffix when a 1M-context backend is in the catalog."
|
|
222
|
+
description: "Override the default model for Claude Code. Accepts a profile alias (fast, cheap, cheap1m, cheapest, cheapest2, balanced, balanced2, max, local, local2), a full slug (e.g. claude-opus-4-7), or an Opus family shorthand (e.g. 4.7, 4.8, 4.6) which expands to the best variant for that family — adding the [1m] suffix when a 1M-context backend is in the catalog. `local` / `local2` send the main loop to a locally running Anthropic-compatible server instead of Copilot."
|
|
223
|
+
},
|
|
224
|
+
localport: {
|
|
225
|
+
type: "string",
|
|
226
|
+
description: "Port of the LOCAL MODEL SERVER that `-m local` / `-m local2` forward the main loop to (not the proxy's own --port). Default 11111, giving https://localhost:11111/v1. Inert on every other profile."
|
|
227
|
+
},
|
|
228
|
+
localurl: {
|
|
229
|
+
type: "string",
|
|
230
|
+
description: "Full base URL, including the /v1 prefix, of the local inference endpoint for `-m local` / `-m local2` (e.g. http://localhost:11111/v1). Sets scheme/host/path, which --localport cannot. Mutually exclusive with --localport. Inert on every other profile."
|
|
223
231
|
},
|
|
224
232
|
"codex-mcp": {
|
|
225
233
|
type: "boolean",
|
|
@@ -336,6 +344,17 @@ const claude = defineCommand({
|
|
|
336
344
|
}
|
|
337
345
|
const parsed = parseSharedArgs(args);
|
|
338
346
|
const requestedLaunchProfileId = resolveLaunchProfile(args.model);
|
|
347
|
+
try {
|
|
348
|
+
configureLocalEgress({
|
|
349
|
+
...typeof args.localurl === "string" ? { baseUrl: args.localurl } : {},
|
|
350
|
+
...typeof args.localport === "string" ? { port: args.localport } : {},
|
|
351
|
+
profileId: requestedLaunchProfileId
|
|
352
|
+
});
|
|
353
|
+
if (isLocalFamily(requestedLaunchProfileId)) consola.info(`[local] upstream ${localBaseUrl()}`);
|
|
354
|
+
} catch (error) {
|
|
355
|
+
process$1.stderr.write(`${error instanceof Error ? error.message : String(error)}\n`);
|
|
356
|
+
process$1.exit(1);
|
|
357
|
+
}
|
|
339
358
|
const codexMcpEnabled = args["codex-mcp"] !== false;
|
|
340
359
|
const sweEnabled = args["swe"] === true;
|
|
341
360
|
if (requestedLaunchProfileId === "max" && args["codex-cli"]) {
|
|
@@ -440,10 +459,13 @@ const claude = defineCommand({
|
|
|
440
459
|
} else if (isBalancedFamily(launchProfileId)) {
|
|
441
460
|
const prereqCheck = validateBalancedProfilePrerequisites(state.models, {}, launchProfileId);
|
|
442
461
|
if (!prereqCheck.ok) await fastFatal(formatBalancedPrerequisiteFailure(prereqCheck.missing, launchProfileId));
|
|
462
|
+
} else if (isLocalFamily(launchProfileId)) {
|
|
463
|
+
const prereqCheck = validateLocalProfilePrerequisites(state.models, launchProfileId);
|
|
464
|
+
if (!prereqCheck.ok) await fastFatal(formatLocalPrerequisiteFailure(prereqCheck.missing, launchProfileId));
|
|
443
465
|
}
|
|
444
466
|
let chosenSlug = requestedSlug;
|
|
445
|
-
let resolvedSlug = resolveModel(chosenSlug);
|
|
446
|
-
if (usingDefault && state.models) {
|
|
467
|
+
let resolvedSlug = isLocalFamily(launchProfileId) ? chosenSlug : resolveModel(chosenSlug);
|
|
468
|
+
if (usingDefault && state.models && !isLocalFamily(launchProfileId)) {
|
|
447
469
|
const inCache = (slug) => state.models?.data.some((m) => m.id === resolveModel(slug)) ?? false;
|
|
448
470
|
if (!inCache(chosenSlug)) {
|
|
449
471
|
for (const fallback of DEFAULT_CLAUDE_MODEL_FALLBACKS) if (inCache(fallback)) {
|
|
@@ -456,7 +478,7 @@ const claude = defineCommand({
|
|
|
456
478
|
}
|
|
457
479
|
}
|
|
458
480
|
if (resolvedSlug !== chosenSlug) consola.info(`Model "${chosenSlug}" resolved to "${resolvedSlug}"`);
|
|
459
|
-
if (!state.models?.data.find((m) => m.id === resolvedSlug)) {
|
|
481
|
+
if (!(isLocalFamily(launchProfileId) ? void 0 : state.models?.data.find((m) => m.id === resolvedSlug)) && !isLocalFamily(launchProfileId)) {
|
|
460
482
|
const available = listModelsForEndpoint("/v1/messages");
|
|
461
483
|
consola.warn(`Model "${resolvedSlug}" not found. Available claude models: ${available.join(", ")}`);
|
|
462
484
|
}
|
|
@@ -488,7 +510,7 @@ const claude = defineCommand({
|
|
|
488
510
|
consola.warn(`Model-picker settings injection skipped: ${err instanceof Error ? err.message : String(err)}. Use an explicit -m model if the curated rows are unavailable.`);
|
|
489
511
|
}
|
|
490
512
|
const envVars = getClaudeCodeEnvVars(serverUrl, chosenSlug, launchProfileId, pickerModels);
|
|
491
|
-
if (launchProfileId === "cheap" || isCheapestFamily(launchProfileId) || isBalancedFamily(launchProfileId)) {
|
|
513
|
+
if (launchProfileId === "cheap" || isCheapestFamily(launchProfileId) || isBalancedFamily(launchProfileId) || isLocalFamily(launchProfileId)) {
|
|
492
514
|
const suspectKeys = [
|
|
493
515
|
"ANTHROPIC_MODEL",
|
|
494
516
|
"ANTHROPIC_DEFAULT_OPUS_MODEL",
|
|
@@ -537,6 +559,8 @@ const claude = defineCommand({
|
|
|
537
559
|
if (launchProfileId === "fast") extraArgs = withFixedFastAdvisorArg(extraArgs, fastAdvisorClientEnabled(process$1.env));
|
|
538
560
|
else if (launchProfileId === "cheap" || launchProfileId === "cheap1m" || isBalancedFamily(launchProfileId)) extraArgs = withFixedCheapAdvisorArg(extraArgs, cheapAdvisorClientEnabled(process$1.env));
|
|
539
561
|
else if (isCheapestFamily(launchProfileId)) extraArgs = withFixedCheapestAdvisorArg(extraArgs, cheapestAdvisorClientEnabled(process$1.env), cheapestContractFor(launchProfileId).advisorClientModel);
|
|
562
|
+
else if (launchProfileId === "local2") extraArgs = withFixedCheapestAdvisorArg(extraArgs, cheapestAdvisorClientEnabled(process$1.env), local2AdvisorContract().advisorClientModel);
|
|
563
|
+
else if (isLocalFamily(launchProfileId)) extraArgs = withFixedCheapestAdvisorArg(extraArgs, false);
|
|
540
564
|
if (toolbeltEnabled()) {
|
|
541
565
|
provisionToolbelt().catch((err) => consola.debug("Toolbelt provisioning failed:", err));
|
|
542
566
|
const toolbeltLine = buildToolbeltAwareness(availableToolCommands());
|
|
@@ -557,7 +581,7 @@ const claude = defineCommand({
|
|
|
557
581
|
await stopKeepAwake();
|
|
558
582
|
const { disposeBluebirdClients } = await import("./bluebird-client-DGE3WZqh.js");
|
|
559
583
|
await disposeBluebirdClients();
|
|
560
|
-
const { disposeAdoClients } = await import("./ado-tools-
|
|
584
|
+
const { disposeAdoClients } = await import("./ado-tools-rysFZDws.js");
|
|
561
585
|
await disposeAdoClients();
|
|
562
586
|
await removeOwnClaudeConfigMirror();
|
|
563
587
|
await removeAicLedgerFile();
|
|
@@ -569,7 +593,7 @@ const claude = defineCommand({
|
|
|
569
593
|
const isCheapLaunch = launchProfileId === "cheap" || launchProfileId === "cheap1m" || isCheapestFamily(launchProfileId) || isBalancedFamily(launchProfileId);
|
|
570
594
|
let fastWiringComplete = launchProfileId !== "fast" && !isCheapLaunch;
|
|
571
595
|
const astraAvailable = (launchProfileId === "fast" || launchProfileId === "cheap1m") && Boolean(fastAstraModel());
|
|
572
|
-
const browseAgentAvailable = browseAgentEnabled();
|
|
596
|
+
const browseAgentAvailable = browseAgentEnabled() && !isLocalFamily(launchProfileId);
|
|
573
597
|
const directBrowserAvailable = browserToolsEnabled();
|
|
574
598
|
const artifactAvailable = artifactToolsEnabled();
|
|
575
599
|
const resolvedMaxReviewerModel = launchProfileId === "max" ? maxReviewerModel() : void 0;
|
|
@@ -592,6 +616,10 @@ const claude = defineCommand({
|
|
|
592
616
|
Explore: balancedContractFor(launchProfileId).nativeModels.Explore,
|
|
593
617
|
"General-Purpose": balancedContractFor(launchProfileId).nativeModels["General-Purpose"],
|
|
594
618
|
reviewer: balancedReviewerModel(launchProfileId)
|
|
619
|
+
} : isLocalFamily(launchProfileId) ? {
|
|
620
|
+
Explore: localContractFor(launchProfileId).nativeModels.Explore,
|
|
621
|
+
"General-Purpose": localContractFor(launchProfileId).nativeModels["General-Purpose"],
|
|
622
|
+
reviewer: localContractFor(launchProfileId).nativeModels.reviewer
|
|
595
623
|
} : launchProfileId === "max" ? {
|
|
596
624
|
Explore: MAX_PROFILE_MODELS.luna,
|
|
597
625
|
Plan: MAX_PROFILE_MODELS.sol,
|
|
@@ -610,7 +638,7 @@ const claude = defineCommand({
|
|
|
610
638
|
"general-purpose-fast": generalPurposeFastModel()
|
|
611
639
|
};
|
|
612
640
|
const nativeAvailability = {
|
|
613
|
-
scoutAvailable: (launchProfileId === "fast" || launchProfileId === "cheap" || launchProfileId === "cheap1m" || isCheapestFamily(launchProfileId) || isBalancedFamily(launchProfileId) ? nativeAgentModels.Explore : nativeAgentModels.scout) != null,
|
|
641
|
+
scoutAvailable: (launchProfileId === "fast" || launchProfileId === "cheap" || launchProfileId === "cheap1m" || isCheapestFamily(launchProfileId) || isBalancedFamily(launchProfileId) || isLocalFamily(launchProfileId) ? nativeAgentModels.Explore : nativeAgentModels.scout) != null,
|
|
614
642
|
implementerFastAvailable: nativeAgentModels["implementer-fast"] != null,
|
|
615
643
|
reviewerFastAvailable: nativeAgentModels["reviewer-fast"] != null,
|
|
616
644
|
generalPurposeFastAvailable: nativeAgentModels["general-purpose-fast"] != null,
|
|
@@ -627,8 +655,9 @@ const claude = defineCommand({
|
|
|
627
655
|
const isFastProfile = launchProfileId === "fast";
|
|
628
656
|
const isMaxProfile = launchProfileId === "max";
|
|
629
657
|
const isCheapProfile = launchProfileId === "cheap" || launchProfileId === "cheap1m" || isCheapestFamily(launchProfileId) || isBalancedFamily(launchProfileId);
|
|
630
|
-
const
|
|
631
|
-
|
|
658
|
+
const isLocalProfile = isLocalFamily(launchProfileId);
|
|
659
|
+
const isPinnedProfile = isFastProfile || isMaxProfile || isCheapProfile || isLocalProfile;
|
|
660
|
+
if ((isFastProfile || isCheapProfile || isLocalProfile) && requestedCli) process$1.stderr.write("Fast/cheap profile uses its fixed HTTP MCP surface; ignoring --codex-cli.\n");
|
|
632
661
|
const backend = isPinnedProfile ? "http" : resolveCodexCliBackend({
|
|
633
662
|
requested: requestedCli,
|
|
634
663
|
codexInfo: requestedCli ? getCodexVersion() : null
|
|
@@ -644,6 +673,10 @@ const claude = defineCommand({
|
|
|
644
673
|
if (workerToolsEnabled() && !isPinnedProfile) baseGroups.push("workers");
|
|
645
674
|
if (isPinnedProfile && browseAgentAvailable) baseGroups.push("workers");
|
|
646
675
|
const enabledGroups = fastDescriptor.allowedGroups ? baseGroups.filter((g) => fastDescriptor.allowedGroups.has(g)) : baseGroups;
|
|
676
|
+
if (fastDescriptor.personaAllowlist && fastDescriptor.personaAllowlist.size === 0 && !artifactAvailable) {
|
|
677
|
+
const peersIndex = enabledGroups.indexOf("peers");
|
|
678
|
+
if (peersIndex >= 0) enabledGroups.splice(peersIndex, 1);
|
|
679
|
+
}
|
|
647
680
|
if (!isPinnedProfile && standInToolEnabled()) enabledGroups.push("decide");
|
|
648
681
|
if (isMaxProfile && maxOpusModel() !== void 0 && standInToolEnabled({ maxProfile: true })) enabledGroups.push("decide");
|
|
649
682
|
if (directBrowserAvailable && (!fastDescriptor.allowedGroups || fastDescriptor.allowedGroups.has("browser"))) enabledGroups.push("browser");
|
|
@@ -657,7 +690,11 @@ const claude = defineCommand({
|
|
|
657
690
|
if (isMaxProfile && agentToolsEnabled()) enabledGroups.push("first-mate");
|
|
658
691
|
const { keys: groupKeys, skipped: skippedGroups } = await resolveGroupKeysFromMirror(enabledGroups);
|
|
659
692
|
operatingGroupKeys = groupKeys;
|
|
660
|
-
if (
|
|
693
|
+
if (isLocalProfile) {
|
|
694
|
+
const localCheck = validateLocalProfilePrerequisites(state.models, launchProfileId);
|
|
695
|
+
if (!localCheck.ok) throw new Error(formatLocalPrerequisiteFailure(localCheck.missing, launchProfileId));
|
|
696
|
+
}
|
|
697
|
+
if (isPinnedProfile && !isLocalProfile && ((isCheapestFamily(launchProfileId) ? cheapestOracleModel(launchProfileId) : isBalancedFamily(launchProfileId) ? balancedOracleModel(launchProfileId) : isCheapProfile ? cheapOracleModel() : fastOracleModel()) == null || (isBalancedFamily(launchProfileId) ? false : (isCheapestFamily(launchProfileId) ? cheapestAdvisorModel(launchProfileId) : isCheapProfile ? cheapAdvisorModel() : fastAdvisorModel()) == null) || nativeAgentModels.reviewer == null)) {
|
|
661
698
|
if (isCheapestFamily(launchProfileId)) {
|
|
662
699
|
const contract = cheapestContractFor(launchProfileId);
|
|
663
700
|
throw new Error(`${launchProfileId} profile prerequisite drift: exact reviewer (${displayModelName(contract.nativeModels.reviewer)}), oracle (${displayModelName(contract.oracleModel)}), or advisor (${displayModelName(contract.advisorModel)}) model no longer resolves`);
|
|
@@ -683,12 +720,12 @@ const claude = defineCommand({
|
|
|
683
720
|
reviewerModel: nativeAgentModels.reviewer,
|
|
684
721
|
reviewerFastModel: nativeAgentModels["reviewer-fast"],
|
|
685
722
|
brainstormModel: nativeAgentModels.brainstorm,
|
|
686
|
-
scoutModel: isFastProfile || isCheapProfile ? nativeAgentModels.Explore : nativeAgentModels.scout,
|
|
723
|
+
scoutModel: isFastProfile || isCheapProfile || isLocalProfile ? nativeAgentModels.Explore : nativeAgentModels.scout,
|
|
687
724
|
scribeModel: nativeAgentModels.scribe,
|
|
688
725
|
implementerFastModel: nativeAgentModels["implementer-fast"],
|
|
689
726
|
generalPurposeFastModel: nativeAgentModels["general-purpose-fast"],
|
|
690
727
|
nativeRoster: fastDescriptor.nativeRoster,
|
|
691
|
-
personaAllowlist: isFastProfile || isCheapProfile ? void 0 : fastDescriptor.personaAllowlist ? agentNamesForToolAllowlist(fastDescriptor.personaAllowlist) : void 0,
|
|
728
|
+
personaAllowlist: isFastProfile || isCheapProfile || isLocalProfile ? void 0 : fastDescriptor.personaAllowlist ? agentNamesForToolAllowlist(fastDescriptor.personaAllowlist) : void 0,
|
|
692
729
|
includeCoordinator: fastDescriptor.hasCoordinator,
|
|
693
730
|
semanticSearchAvailable: semanticSearchOptedIn() || state.bluebirdEnabled === true,
|
|
694
731
|
bluebirdEnabled: state.bluebirdEnabled === true,
|
|
@@ -708,6 +745,12 @@ const claude = defineCommand({
|
|
|
708
745
|
balancedExploreModel: nativeAgentModels.Explore,
|
|
709
746
|
balancedGeneralPurposeModel: nativeAgentModels["General-Purpose"],
|
|
710
747
|
balancedReviewerModel: nativeAgentModels.reviewer
|
|
748
|
+
} : isLocalProfile ? {
|
|
749
|
+
localProfile: true,
|
|
750
|
+
localExploreModel: nativeAgentModels.Explore,
|
|
751
|
+
localGeneralPurposeModel: nativeAgentModels["General-Purpose"],
|
|
752
|
+
localReviewerModel: nativeAgentModels.reviewer,
|
|
753
|
+
advisorAvailable: launchProfileId === "local2"
|
|
711
754
|
} : isCheapProfile ? {
|
|
712
755
|
cheapProfile: true,
|
|
713
756
|
cheapExploreModel: nativeAgentModels.Explore,
|
|
@@ -748,6 +791,11 @@ const claude = defineCommand({
|
|
|
748
791
|
allowedPersonas: fastDescriptor.personaAllowlist
|
|
749
792
|
});
|
|
750
793
|
if (isPinnedProfile) fastLaunchId = launchEntry.launchId;
|
|
794
|
+
if (isLocalFamily(launchProfileId)) try {
|
|
795
|
+
await writeLaunchBoundSyntheticCredential(launchBoundAccessToken(launchSecret));
|
|
796
|
+
} catch (err) {
|
|
797
|
+
consola.warn(`Could not bind this local launch's synthetic credential (${err instanceof Error ? err.message : String(err)}). Agent-team teammates would send unbound traffic for this session.`);
|
|
798
|
+
}
|
|
751
799
|
envVars.ANTHROPIC_CUSTOM_HEADERS = envVars.ANTHROPIC_CUSTOM_HEADERS ? `${envVars.ANTHROPIC_CUSTOM_HEADERS}\n${LAUNCH_SECRET_HEADER}: ${launchSecret}` : `${LAUNCH_SECRET_HEADER}: ${launchSecret}`;
|
|
752
800
|
envVars.GH_ROUTER_HOOK_MCP_URL = serverUrl;
|
|
753
801
|
envVars.GH_ROUTER_HOOK_NONCE = runtime.nonce;
|
|
@@ -769,7 +817,7 @@ const claude = defineCommand({
|
|
|
769
817
|
};
|
|
770
818
|
let subagentVisibility;
|
|
771
819
|
let injected;
|
|
772
|
-
if (isFastProfile || isCheapProfile) {
|
|
820
|
+
if (isFastProfile || isCheapProfile || isLocalProfile) {
|
|
773
821
|
extraArgs.push("--mcp-config", runtime.mcpConfigPath);
|
|
774
822
|
if (args["codex-mcp-only"] === true) extraArgs.push("--strict-mcp-config");
|
|
775
823
|
subagentVisibility = "role-scoped (lead via --mcp-config; subagents via inline mcpServers)";
|
|
@@ -787,7 +835,7 @@ const claude = defineCommand({
|
|
|
787
835
|
} else if (args["codex-mcp-only"] === true) consola.warn("--codex-mcp-only has no effect when peer MCP is wired via the mirrored .claude.json (the user's existing user-scope MCPs in the snapshot are still visible). Pass --no-codex-mcp to skip peer-MCP wiring entirely.");
|
|
788
836
|
subagentVisibility = injected.ok ? `subagent-visible (mirrored mcpServers: [${injected.serversAdded.join(", ")}])` : `subagent-INVISIBLE (collision on user-side mcpServers: [${injected.conflictingServers.join(", ")}]; parent-only via --mcp-config)`;
|
|
789
837
|
}
|
|
790
|
-
if (isFastProfile || isCheapProfile) {
|
|
838
|
+
if (isFastProfile || isCheapProfile || isLocalProfile) {
|
|
791
839
|
let fastGuardInstalled = false;
|
|
792
840
|
try {
|
|
793
841
|
const settingsPath = path.join(PATHS.CLAUDE_CONFIG_DIR, "settings.json");
|
|
@@ -853,7 +901,7 @@ const claude = defineCommand({
|
|
|
853
901
|
consola.warn(`Could not auto-approve injected tools: ${String(err)}`);
|
|
854
902
|
}
|
|
855
903
|
if (workerSkillsActive || isPinnedProfile && browseAgentAvailable) {
|
|
856
|
-
if (!(isFastProfile || isCheapProfile || injected?.ok === true)) consola.warn("Workers non-blocking guard NOT registered: subagent MCP injection fell back to parent-only (--mcp-config), so worker-* dispatchers cannot reach the workers server. Raw (blocking) worker tools remain usable on the main thread this session.");
|
|
904
|
+
if (!(isFastProfile || isCheapProfile || isLocalProfile || injected?.ok === true)) consola.warn("Workers non-blocking guard NOT registered: subagent MCP injection fell back to parent-only (--mcp-config), so worker-* dispatchers cannot reach the workers server. Raw (blocking) worker tools remain usable on the main thread this session.");
|
|
857
905
|
else if (process$1.env.GH_ROUTER_DISABLE_WORKER_GUARD === "1") consola.info("Workers non-blocking guard disabled via GH_ROUTER_DISABLE_WORKER_GUARD=1 — raw mcp__workers__* is callable on the main thread (blocking); the worker-* background agents remain the steered, non-blocking default.");
|
|
858
906
|
else try {
|
|
859
907
|
const settingsPath = path.join(PATHS.CLAUDE_CONFIG_DIR, "settings.json");
|
|
@@ -909,14 +957,14 @@ const claude = defineCommand({
|
|
|
909
957
|
consola.warn(`Could not register the artifact auto-open hook: ${String(err)}`);
|
|
910
958
|
}
|
|
911
959
|
}
|
|
912
|
-
if (!isFastProfile && !isCheapProfile && hookMcpRuntimeFromEnv(envVars) && planReviewEnabled()) try {
|
|
960
|
+
if (!isFastProfile && !isCheapProfile && !isLocalProfile && hookMcpRuntimeFromEnv(envVars) && planReviewEnabled()) try {
|
|
913
961
|
const settingsPath = path.join(PATHS.CLAUDE_CONFIG_DIR, "settings.json");
|
|
914
962
|
const command = buildPlanReviewHookCommand(selfInvocation);
|
|
915
963
|
await injectStopHookIntoSettingsFile(settingsPath, command, "PostToolUse", void 0, "ExitPlanMode");
|
|
916
964
|
} catch (err) {
|
|
917
965
|
consola.warn(`Could not register the advisory plan-review hook: ${String(err)}`);
|
|
918
966
|
}
|
|
919
|
-
if (!isFastProfile && !isCheapProfile && !isMaxProfile && args["trust-gate"] === true) try {
|
|
967
|
+
if (!isFastProfile && !isCheapProfile && !isLocalProfile && !isMaxProfile && args["trust-gate"] === true) try {
|
|
920
968
|
const root = await trustRepo(sessionCwd);
|
|
921
969
|
process$1.stderr.write(`Structural gate trusted for this repo (${root}); it will run on launch here from now on.\n`);
|
|
922
970
|
} catch (err) {
|
|
@@ -1142,4 +1190,4 @@ const claude = defineCommand({
|
|
|
1142
1190
|
//#endregion
|
|
1143
1191
|
export { claude };
|
|
1144
1192
|
|
|
1145
|
-
//# sourceMappingURL=claude-
|
|
1193
|
+
//# sourceMappingURL=claude-B3pIageM.js.map
|