github-router 0.3.327 → 0.3.328
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/{aic-ledger-DRU89gJg.js → aic-ledger-CsBx1crE.js} +2 -2
- package/dist/{aic-ledger-DRU89gJg.js.map → aic-ledger-CsBx1crE.js.map} +1 -1
- package/dist/{attribution-settings-FdE6tYAl.js → attribution-settings-CF1ZV58z.js} +10 -10
- package/dist/attribution-settings-CF1ZV58z.js.map +1 -0
- package/dist/{auth-DSLN1arH.js → auth-xgFZGZbf.js} +3 -3
- package/dist/{auth-DSLN1arH.js.map → auth-xgFZGZbf.js.map} +1 -1
- package/dist/browser-ext/manifest.json +1 -1
- package/dist/{check-usage-B_12ALvf.js → check-usage-vUDk6oV7.js} +4 -4
- package/dist/{check-usage-B_12ALvf.js.map → check-usage-vUDk6oV7.js.map} +1 -1
- package/dist/{claude-C6Ddvt8L.js → claude-BdJupNy4.js} +21 -21
- package/dist/{claude-C6Ddvt8L.js.map → claude-BdJupNy4.js.map} +1 -1
- package/dist/{codex-DikHPpLj.js → codex-DgEG2i_w.js} +6 -6
- package/dist/{codex-DikHPpLj.js.map → codex-DgEG2i_w.js.map} +1 -1
- package/dist/{copilot-discount-D8t7Q3Tp.js → copilot-discount-0lG67i9O.js} +2 -2
- package/dist/{copilot-discount-D8t7Q3Tp.js.map → copilot-discount-0lG67i9O.js.map} +1 -1
- package/dist/{debug-D8iD6G4O.js → debug-a737qcCC.js} +2 -2
- package/dist/{debug-D8iD6G4O.js.map → debug-a737qcCC.js.map} +1 -1
- package/dist/engine-C3SnOV1U.js +2 -0
- package/dist/{gate-discovery-CBna9eP-.js → gate-discovery-ufkJQE8V.js} +5 -5
- package/dist/{gate-discovery-CBna9eP-.js.map → gate-discovery-ufkJQE8V.js.map} +1 -1
- package/dist/{get-copilot-usage-Bs-FEPMf.js → get-copilot-usage-VKU2IvuE.js} +2 -2
- package/dist/{get-copilot-usage-Bs-FEPMf.js.map → get-copilot-usage-VKU2IvuE.js.map} +1 -1
- package/dist/{index-cmd-BnIqDmBT.js → index-cmd-mPy73hig.js} +4 -4
- package/dist/{index-cmd-BnIqDmBT.js.map → index-cmd-mPy73hig.js.map} +1 -1
- package/dist/{internal-aic-status-BaUKlisM.js → internal-aic-status-Cfl5HiAN.js} +3 -3
- package/dist/{internal-aic-status-BaUKlisM.js.map → internal-aic-status-Cfl5HiAN.js.map} +1 -1
- package/dist/{internal-artifact-open-U-Ht7R-O.js → internal-artifact-open-CX2fRP_D.js} +2 -2
- package/dist/{internal-artifact-open-U-Ht7R-O.js.map → internal-artifact-open-CX2fRP_D.js.map} +1 -1
- package/dist/{internal-fast-dispatch-guard-Dnjoj0pV.js → internal-fast-dispatch-guard-BoTxjO6b.js} +2 -2
- package/dist/{internal-fast-dispatch-guard-Dnjoj0pV.js.map → internal-fast-dispatch-guard-BoTxjO6b.js.map} +1 -1
- package/dist/{internal-fast-dispatch-guard-uztSu0c8.js → internal-fast-dispatch-guard-Cxattkm4.js} +1 -1
- package/dist/{internal-first-mate-guard-ZqPHrYlh.js → internal-first-mate-guard-97qsseTP.js} +1 -1
- package/dist/{internal-first-mate-guard-Cj_g7RFr.js → internal-first-mate-guard-D_JFcrl_.js} +3 -3
- package/dist/{internal-first-mate-guard-Cj_g7RFr.js.map → internal-first-mate-guard-D_JFcrl_.js.map} +1 -1
- package/dist/{internal-max-dispatch-guard-Sp_rCYk_.js → internal-max-dispatch-guard-Cxe8h12x.js} +2 -2
- package/dist/{internal-max-dispatch-guard-Sp_rCYk_.js.map → internal-max-dispatch-guard-Cxe8h12x.js.map} +1 -1
- package/dist/{internal-max-dispatch-guard-CxG_c3cc.js → internal-max-dispatch-guard-DQMyOds8.js} +1 -1
- package/dist/{internal-plan-review-Co01iHOW.js → internal-plan-review-DM-Zycyn.js} +3 -3
- package/dist/{internal-plan-review-Co01iHOW.js.map → internal-plan-review-DM-Zycyn.js.map} +1 -1
- package/dist/{internal-prompt-submit-dflz0bqH.js → internal-prompt-submit-6AKy89nq.js} +4 -4
- package/dist/{internal-prompt-submit-dflz0bqH.js.map → internal-prompt-submit-6AKy89nq.js.map} +1 -1
- package/dist/{internal-session-bind-BVQy7Vd4.js → internal-session-bind-CHIOd5ys.js} +2 -2
- package/dist/{internal-session-bind-BVQy7Vd4.js.map → internal-session-bind-CHIOd5ys.js.map} +1 -1
- package/dist/{internal-stop-hook-DNfS5cxB.js → internal-stop-hook-CWwkeyf_.js} +5 -5
- package/dist/{internal-stop-hook-DNfS5cxB.js.map → internal-stop-hook-CWwkeyf_.js.map} +1 -1
- package/dist/{internal-stop-review-CrnG4IJo.js → internal-stop-review-CPk66wwo.js} +2 -2
- package/dist/{internal-stop-review-CrnG4IJo.js.map → internal-stop-review-CPk66wwo.js.map} +1 -1
- package/dist/{internal-worker-guard-Dd14aDXQ.js → internal-worker-guard-BY5seBqp.js} +2 -2
- package/dist/{internal-worker-guard-Dd14aDXQ.js.map → internal-worker-guard-BY5seBqp.js.map} +1 -1
- package/dist/{internal-workspace-header-booLOzwD.js → internal-workspace-header-CPZNphnk.js} +2 -2
- package/dist/{internal-workspace-header-booLOzwD.js.map → internal-workspace-header-CPZNphnk.js.map} +1 -1
- package/dist/lifecycle-B2eB8nRg.js +2 -0
- package/dist/{lifecycle-C1LDvDD6.js → lifecycle-D8vQXfeC.js} +7 -3
- package/dist/{lifecycle-C1LDvDD6.js.map → lifecycle-D8vQXfeC.js.map} +1 -1
- package/dist/lifecycle-Dz-Rq8pD.js +2 -0
- package/dist/{lifecycle-BYPEqFdV.js → lifecycle-MmpJWRcl.js} +2 -2
- package/dist/{lifecycle-BYPEqFdV.js.map → lifecycle-MmpJWRcl.js.map} +1 -1
- package/dist/main.js +21 -21
- package/dist/{mcp-workspace-header-BIW0SRgs.js → mcp-workspace-header-DX_mD0JT.js} +2 -2
- package/dist/{mcp-workspace-header-BIW0SRgs.js.map → mcp-workspace-header-DX_mD0JT.js.map} +1 -1
- package/dist/{models-B9tdaM6B.js → models-BjCRO0AC.js} +3 -3
- package/dist/{models-B9tdaM6B.js.map → models-BjCRO0AC.js.map} +1 -1
- package/dist/{orchestration-DvsdorFq.js → orchestration-Dn5v8c0a.js} +2 -2
- package/dist/{orchestration-DvsdorFq.js.map → orchestration-Dn5v8c0a.js.map} +1 -1
- package/dist/paths-DVXBtLyo.js +2 -0
- package/dist/{paths-BnZwolac.js → paths-P5ajjpzU.js} +3 -3
- package/dist/{paths-BnZwolac.js.map → paths-P5ajjpzU.js.map} +1 -1
- package/dist/{peer-mcp-personas-Cs7qXWA7.js → peer-mcp-personas-Dg2LJ0GF.js} +1005 -21
- package/dist/peer-mcp-personas-Dg2LJ0GF.js.map +1 -0
- package/dist/{plan-review-hook-BlsGnG02.js → plan-review-hook-ChuywYy_.js} +3 -3
- package/dist/{plan-review-hook-BlsGnG02.js.map → plan-review-hook-ChuywYy_.js.map} +1 -1
- package/dist/{prompt-submit-hook-BJFLzCaT.js → prompt-submit-hook-C0ZospPT.js} +3 -3
- package/dist/{prompt-submit-hook-BJFLzCaT.js.map → prompt-submit-hook-C0ZospPT.js.map} +1 -1
- package/dist/{provision-5FSlDXXk.js → provision-l0THw3kO.js} +5 -5
- package/dist/{provision-5FSlDXXk.js.map → provision-l0THw3kO.js.map} +1 -1
- package/dist/{runner-CFR2seH4.js → runner-BoJPRQsK.js} +154 -16
- package/dist/runner-BoJPRQsK.js.map +1 -0
- package/dist/{self-invocation-opSXHEs0.js → self-invocation-DBWyjvGm.js} +2 -2
- package/dist/{self-invocation-opSXHEs0.js.map → self-invocation-DBWyjvGm.js.map} +1 -1
- package/dist/{serve-DPeyTjn0.js → serve-DZY93dBo.js} +13 -13
- package/dist/{serve-DPeyTjn0.js.map → serve-DZY93dBo.js.map} +1 -1
- package/dist/{server-setup-Bymo8rfd.js → server-setup-Bv7TGDC7.js} +8 -8
- package/dist/{server-setup-Bymo8rfd.js.map → server-setup-Bv7TGDC7.js.map} +1 -1
- package/dist/{start-RwIzqSUq.js → start-2SrUerLA.js} +4 -4
- package/dist/{start-RwIzqSUq.js.map → start-2SrUerLA.js.map} +1 -1
- package/dist/{stop-gate-hook-DvNM8zFf.js → stop-gate-hook-BACb8dlj.js} +3 -3
- package/dist/{stop-gate-hook-DvNM8zFf.js.map → stop-gate-hook-BACb8dlj.js.map} +1 -1
- package/dist/{stop-gate-policy-C5pXbY59.js → stop-gate-policy-D6jIeOXB.js} +2 -2
- package/dist/{stop-gate-policy-C5pXbY59.js.map → stop-gate-policy-D6jIeOXB.js.map} +1 -1
- package/dist/{token-Css-ARGL.js → token-Dlb_84hW.js} +2 -2
- package/dist/{token-Css-ARGL.js.map → token-Dlb_84hW.js.map} +1 -1
- package/dist/{worker-dispatch-CcQygiAA.js → worker-dispatch-DtjQchvM.js} +2 -2
- package/dist/{worker-dispatch-CcQygiAA.js.map → worker-dispatch-DtjQchvM.js.map} +1 -1
- package/package.json +1 -1
- package/dist/attribution-settings-FdE6tYAl.js.map +0 -1
- package/dist/engine-CNDZ4OP_.js +0 -2
- package/dist/lifecycle-Cz99P30h.js +0 -2
- package/dist/lifecycle-DqTFEJpS.js +0 -2
- package/dist/paths-BzM6uxmd.js +0 -2
- package/dist/peer-mcp-personas-Cs7qXWA7.js.map +0 -1
- package/dist/runner-CFR2seH4.js.map +0 -1
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { t as PATHS } from "./paths-
|
|
1
|
+
import { t as PATHS } from "./paths-P5ajjpzU.js";
|
|
2
2
|
import { l as runManagedExeCapture, o as resolveExecutable, u as spawnTaskkillBestEffort } from "./exec-COUT4QsS.js";
|
|
3
|
-
import { n as isPidAlive, s as trackChild, t as getColbertInstanceUuid } from "./lifecycle-
|
|
3
|
+
import { n as isPidAlive, s as trackChild, t as getColbertInstanceUuid } from "./lifecycle-D8vQXfeC.js";
|
|
4
4
|
import { createRequire } from "node:module";
|
|
5
5
|
import consola from "consola";
|
|
6
6
|
import { existsSync, mkdirSync, readFileSync, readdirSync, realpathSync, renameSync, rmSync, statSync, writeFileSync } from "node:fs";
|
|
@@ -193,6 +193,48 @@ function stableTreeSitterAssetsComplete() {
|
|
|
193
193
|
}
|
|
194
194
|
});
|
|
195
195
|
}
|
|
196
|
+
//#endregion
|
|
197
|
+
//#region src/lib/tree-sitter-grammars.ts
|
|
198
|
+
/**
|
|
199
|
+
* Shared tree-sitter grammar layer.
|
|
200
|
+
*
|
|
201
|
+
* This module is the pure grammar-loading + constant-table layer
|
|
202
|
+
* extracted from `src/lib/code-search.ts`. It owns:
|
|
203
|
+
*
|
|
204
|
+
* - the extension → language and language → wasm-filename tables,
|
|
205
|
+
* - the per-language definition-node-type sets and the shared
|
|
206
|
+
* identifier-node-type set,
|
|
207
|
+
* - the lazy `web-tree-sitter` `Parser.init()` + grammar-load cache
|
|
208
|
+
* (`getGrammarBundle`), pre-warmed at module import time, and
|
|
209
|
+
* - `outlineFile`, a compact navigational outline of a single file.
|
|
210
|
+
*
|
|
211
|
+
* The BM25F scoring, the structural-confirmation pass, and the parsed-
|
|
212
|
+
* tree LRU stay in `code-search.ts` — they are tightly coupled to the
|
|
213
|
+
* ranking flow and would not survive a clean move. `code-search.ts`
|
|
214
|
+
* imports the symbols here and continues to call the same functions, so
|
|
215
|
+
* the extraction is behavior-preserving for the structural pass.
|
|
216
|
+
*
|
|
217
|
+
* There is exactly ONE `Parser.init()` and ONE grammar cache across the
|
|
218
|
+
* whole process: every caller (the structural pass, `outlineFile`)
|
|
219
|
+
* awaits the same `getGrammarBundle().ready` promise.
|
|
220
|
+
*
|
|
221
|
+
* Version pin note (evaluated 2026-09): web-tree-sitter stays at 0.25.10
|
|
222
|
+
* with tree-sitter-wasms 0.1.13 prebuilts. Upgrading the runtime to 0.27.0
|
|
223
|
+
* was spike-tested — all 9 prebuilt grammars fail to load (WASM
|
|
224
|
+
* dynamic-linking format mismatch). The migration path is web-tree-sitter
|
|
225
|
+
* 0.27.0 + tree-sitter-wasm 1.1.3 (verified: all 9 load + parse), but that
|
|
226
|
+
* swaps grammar builds too, so DEFINITION_NODE_TYPES needs node-type
|
|
227
|
+
* parity validation per language before it ships. Deferred until the
|
|
228
|
+
* semantic-service work lands; the cost of staying is only the
|
|
229
|
+
* check-between-files (not mid-parse) structural budget.
|
|
230
|
+
*/
|
|
231
|
+
/**
|
|
232
|
+
* Cap the per-file size we'll parse. 1MB of source covers all
|
|
233
|
+
* reasonable hand-written files; bigger files are almost always
|
|
234
|
+
* generated code or vendored bundles whose AST signal is worthless
|
|
235
|
+
* for ranking real definitions.
|
|
236
|
+
*/
|
|
237
|
+
const STRUCTURAL_MAX_FILE_BYTES = 1048576;
|
|
196
238
|
/**
|
|
197
239
|
* Extension → grammar key. Grammars not in this map skip structural
|
|
198
240
|
* parsing (the hit falls back to the regex SYMBOL_REGEX heuristic for
|
|
@@ -3344,7 +3386,7 @@ async function searchCode(rawInput, externalSignal) {
|
|
|
3344
3386
|
const outlineStartMs = Date.now();
|
|
3345
3387
|
const wantScan = rawInput.scan === true;
|
|
3346
3388
|
const scanDeadline = Date.now() + WALL_TIME_MS;
|
|
3347
|
-
if (rawInput.summary
|
|
3389
|
+
if (rawInput.summary === true || wantScan) {
|
|
3348
3390
|
let distinct;
|
|
3349
3391
|
if (wantScan) {
|
|
3350
3392
|
const enumed = await enumerateWorkspaceFiles({
|
|
@@ -3543,6 +3585,68 @@ function modelDirName() {
|
|
|
3543
3585
|
}
|
|
3544
3586
|
/** Short model id used in the sidecar metadata `model` field. */
|
|
3545
3587
|
const MODEL_ID = "LateOn-Code-edge";
|
|
3588
|
+
/** next-plaid-api release tag these server binaries are promoted from. */
|
|
3589
|
+
const NEXTPLAID_SERVER_TAG = "next-plaid-server-v1.7.0";
|
|
3590
|
+
function nextPlaidServerUrl(asset) {
|
|
3591
|
+
return `https://github.com/animeshkundu/github-router/releases/download/${NEXTPLAID_SERVER_TAG}/${asset}`;
|
|
3592
|
+
}
|
|
3593
|
+
/**
|
|
3594
|
+
* next-plaid-api server binaries, keyed `<platform>-<arch>-<variant>`.
|
|
3595
|
+
* Built by .github/workflows/next-plaid-server.yml from the pinned
|
|
3596
|
+
* upstream tag: cpu = OpenBLAS-static (Linux/Windows) / Accelerate
|
|
3597
|
+
* (macOS); cuda = + CUDA execution provider (Linux/Windows x64 only).
|
|
3598
|
+
* macOS has no cuda variant (no NVIDIA target); linux-arm64 and
|
|
3599
|
+
* win-arm64 have no entries (unsupported → lexical fallback).
|
|
3600
|
+
*/
|
|
3601
|
+
const NEXTPLAID_SERVER = {
|
|
3602
|
+
"linux-x64-cpu": {
|
|
3603
|
+
url: nextPlaidServerUrl("next-plaid-api-x86_64-unknown-linux-gnu"),
|
|
3604
|
+
sha256: "799b69de51c8f9978ea6537315da4ad63f9c2fd6f0b50f3ea8021d7ffdbc0aa3",
|
|
3605
|
+
archive: "raw",
|
|
3606
|
+
variant: "cpu"
|
|
3607
|
+
},
|
|
3608
|
+
"linux-x64-cuda": {
|
|
3609
|
+
url: nextPlaidServerUrl("next-plaid-api-x86_64-unknown-linux-gnu-cuda"),
|
|
3610
|
+
sha256: "94adc97569abc4ea58d411cb23e6692c70b23e18eef0071d08fe97bc159a12d6",
|
|
3611
|
+
archive: "raw",
|
|
3612
|
+
variant: "cuda",
|
|
3613
|
+
cudaVersion: "12.8"
|
|
3614
|
+
},
|
|
3615
|
+
"win32-x64-cpu": {
|
|
3616
|
+
url: nextPlaidServerUrl("next-plaid-api-x86_64-pc-windows-msvc.exe"),
|
|
3617
|
+
sha256: "86c243c15f84ff32186f6fe04e98c2d71d922e13a2fdaa9b95da3ac2df8ff7a1",
|
|
3618
|
+
archive: "raw",
|
|
3619
|
+
variant: "cpu"
|
|
3620
|
+
},
|
|
3621
|
+
"win32-x64-cuda": {
|
|
3622
|
+
url: nextPlaidServerUrl("next-plaid-api-x86_64-pc-windows-msvc-cuda.exe"),
|
|
3623
|
+
sha256: "f235faf71fbcec0a28024cb416e3060c62f035f446a4eb3a1024220be0666edc",
|
|
3624
|
+
archive: "raw",
|
|
3625
|
+
variant: "cuda",
|
|
3626
|
+
cudaVersion: "12.8"
|
|
3627
|
+
},
|
|
3628
|
+
"darwin-arm64-cpu": {
|
|
3629
|
+
url: nextPlaidServerUrl("next-plaid-api-aarch64-apple-darwin"),
|
|
3630
|
+
sha256: "04d8d8ab6a49617076e1c0f4ff7756a555efd159890d5c3ea1adf54bae0238bb",
|
|
3631
|
+
archive: "raw",
|
|
3632
|
+
variant: "cpu"
|
|
3633
|
+
},
|
|
3634
|
+
"darwin-x64-cpu": {
|
|
3635
|
+
url: nextPlaidServerUrl("next-plaid-api-x86_64-apple-darwin"),
|
|
3636
|
+
sha256: "f3bca729db0043c7b609731ea095685fc2a72f0c2f58571b33c4fa52691fbe98",
|
|
3637
|
+
archive: "raw",
|
|
3638
|
+
variant: "cpu"
|
|
3639
|
+
}
|
|
3640
|
+
};
|
|
3641
|
+
/** Server asset for this platform-arch-variant, or undefined if unsupported. */
|
|
3642
|
+
function nextPlaidServerAsset(variant, platform = process.platform, arch = process.arch) {
|
|
3643
|
+
return NEXTPLAID_SERVER[`${platformArchKey(platform, arch)}-${variant}`];
|
|
3644
|
+
}
|
|
3645
|
+
/** True iff a promoted (SHA-pinned) server binary exists for this variant. */
|
|
3646
|
+
function nextPlaidServerPromoted(variant, platform = process.platform, arch = process.arch) {
|
|
3647
|
+
const asset = nextPlaidServerAsset(variant, platform, arch);
|
|
3648
|
+
return asset !== void 0 && asset.sha256.length > 0;
|
|
3649
|
+
}
|
|
3546
3650
|
//#endregion
|
|
3547
3651
|
//#region src/lib/toolbelt/extract.ts
|
|
3548
3652
|
/**
|
|
@@ -3783,6 +3887,36 @@ function colbertModelDir() {
|
|
|
3783
3887
|
function canonicalColbertModelDir() {
|
|
3784
3888
|
return path.resolve(colbertModelDir());
|
|
3785
3889
|
}
|
|
3890
|
+
/** Absolute path a provisioned next-plaid-api server binary lives at. */
|
|
3891
|
+
function nextPlaidServerBinaryPath(variant) {
|
|
3892
|
+
const suffix = variant === "cuda" ? "-cuda" : "";
|
|
3893
|
+
return path.join(PATHS.COLBERT_BIN_DIR, `next-plaid-api${suffix}${EXE_EXT}`);
|
|
3894
|
+
}
|
|
3895
|
+
/**
|
|
3896
|
+
* Provision the next-plaid-api server binary for the requested variant.
|
|
3897
|
+
* Lazy and separate from `provisionColbert()` (which owns the
|
|
3898
|
+
* colgrep/ORT/model trio): only the service backend calls this, so the
|
|
3899
|
+
* default colgrep path never pays for a server download.
|
|
3900
|
+
*
|
|
3901
|
+
* Fail-closed: unknown platform, unpromoted SHA (empty digest), or any
|
|
3902
|
+
* download/verify failure all report `reason` instead of throwing — the
|
|
3903
|
+
* caller falls back (cuda → cpu variant → colgrep → lexical).
|
|
3904
|
+
*/
|
|
3905
|
+
async function provisionNextPlaidServer(variant) {
|
|
3906
|
+
const asset = nextPlaidServerAsset(variant);
|
|
3907
|
+
if (!asset) return { reason: "no server asset for this platform" };
|
|
3908
|
+
if (asset.sha256.length === 0) return { reason: "server binary not yet promoted for this variant" };
|
|
3909
|
+
const dest = nextPlaidServerBinaryPath(variant);
|
|
3910
|
+
try {
|
|
3911
|
+
await withInstallLock("colbert-provision.lock", async () => {
|
|
3912
|
+
await provisionBinary(asset, dest);
|
|
3913
|
+
});
|
|
3914
|
+
return { path: dest };
|
|
3915
|
+
} catch (err) {
|
|
3916
|
+
consola.debug(`colbert: server provision failed (${variant}):`, err);
|
|
3917
|
+
return { reason: "server download/verify failed" };
|
|
3918
|
+
}
|
|
3919
|
+
}
|
|
3786
3920
|
/** Absolute path the provisioned ORT dylib lives at. */
|
|
3787
3921
|
function colbertOrtDylibPath() {
|
|
3788
3922
|
const lib = ortLibAsset()?.member ?? "libonnxruntime.so";
|
|
@@ -4672,6 +4806,10 @@ async function freshnessVerdict(workspace) {
|
|
|
4672
4806
|
* and current HEAD (when the head moved) UNION the working-tree porcelain
|
|
4673
4807
|
* set. Capped at DELTA_ENUM_CAP (beyond → truncated). Fail-closed: any git
|
|
4674
4808
|
* failure yields truncated (unprovably-small), so servability refuses.
|
|
4809
|
+
*
|
|
4810
|
+
* Exported for the service backend, which computes its own servability
|
|
4811
|
+
* against its own sidecar (it must NOT reuse `freshnessVerdict` — that
|
|
4812
|
+
* verdict describes the colgrep sidecar's state, not the service index's).
|
|
4675
4813
|
*/
|
|
4676
4814
|
async function gitDeltaFiles(workspace, baseHead, currentHead) {
|
|
4677
4815
|
const files = /* @__PURE__ */ new Set();
|
|
@@ -4984,7 +5122,7 @@ async function runSemanticSearch(opts) {
|
|
|
4984
5122
|
return {
|
|
4985
5123
|
status: "unavailable",
|
|
4986
5124
|
isError: true,
|
|
4987
|
-
notice: "no semantic index
|
|
5125
|
+
notice: "no semantic index yet — build started; retry mode:\"semantic\" in minutes or use code_search"
|
|
4988
5126
|
};
|
|
4989
5127
|
case "failed": return handleFailure(workspace, fresh.meta, false);
|
|
4990
5128
|
case "crashed": return handleFailure(workspace, fresh.meta, true);
|
|
@@ -4994,12 +5132,12 @@ async function runSemanticSearch(opts) {
|
|
|
4994
5132
|
kickBackgroundInit(workspace);
|
|
4995
5133
|
return {
|
|
4996
5134
|
status: "building",
|
|
4997
|
-
notice: "semantic index build
|
|
5135
|
+
notice: "semantic index build interrupted — rebuild started; retry mode:\"semantic\" in minutes"
|
|
4998
5136
|
};
|
|
4999
5137
|
}
|
|
5000
5138
|
return {
|
|
5001
5139
|
status: "building",
|
|
5002
|
-
notice: "semantic index
|
|
5140
|
+
notice: "semantic index building; retry mode:\"semantic\" in minutes or use code_search"
|
|
5003
5141
|
};
|
|
5004
5142
|
case "stale":
|
|
5005
5143
|
if (opts.serveStale && isServableVerdict(fresh)) {
|
|
@@ -5085,7 +5223,7 @@ async function repairCorruptIndex(workspace, meta) {
|
|
|
5085
5223
|
};
|
|
5086
5224
|
if (_searchIndexInFlight.has(wsKey) || isInitInFlight(workspace)) return {
|
|
5087
5225
|
status: "building",
|
|
5088
|
-
notice: "semantic index
|
|
5226
|
+
notice: "semantic index corrupt, writer active — results disabled until it exits"
|
|
5089
5227
|
};
|
|
5090
5228
|
const projectDir = await colbertProjectDir(workspace);
|
|
5091
5229
|
if (!projectDir) {
|
|
@@ -5093,7 +5231,7 @@ async function repairCorruptIndex(workspace, meta) {
|
|
|
5093
5231
|
return {
|
|
5094
5232
|
status: "unavailable",
|
|
5095
5233
|
isError: true,
|
|
5096
|
-
notice: "no semantic index
|
|
5234
|
+
notice: "no semantic index yet — build started; retry mode:\"semantic\" in minutes or use code_search"
|
|
5097
5235
|
};
|
|
5098
5236
|
}
|
|
5099
5237
|
if (!await quarantineProjectDir(projectDir)) {
|
|
@@ -5101,7 +5239,7 @@ async function repairCorruptIndex(workspace, meta) {
|
|
|
5101
5239
|
return {
|
|
5102
5240
|
status: "failed",
|
|
5103
5241
|
isError: true,
|
|
5104
|
-
notice: "semantic index
|
|
5242
|
+
notice: "semantic index corrupt, quarantine failed — close active colgrep processes and retry"
|
|
5105
5243
|
};
|
|
5106
5244
|
}
|
|
5107
5245
|
await writeColbertMeta(failedMeta).catch(() => {});
|
|
@@ -5109,7 +5247,7 @@ async function repairCorruptIndex(workspace, meta) {
|
|
|
5109
5247
|
return {
|
|
5110
5248
|
status: "failed",
|
|
5111
5249
|
isError: true,
|
|
5112
|
-
notice: attempts < 2 ? "semantic index
|
|
5250
|
+
notice: attempts < 2 ? "semantic index corrupt and quarantined — rebuild started; retry mode:\"semantic\" in minutes" : "semantic index repeatedly corrupt — rebuild capped, do NOT retry mode:\"semantic\"; use code_search"
|
|
5113
5251
|
};
|
|
5114
5252
|
}
|
|
5115
5253
|
/**
|
|
@@ -5171,7 +5309,7 @@ async function handleFailure(workspace, meta, crashedVerdict) {
|
|
|
5171
5309
|
return {
|
|
5172
5310
|
status: "failed",
|
|
5173
5311
|
isError: true,
|
|
5174
|
-
notice: backoffElapsed ? "semantic index
|
|
5312
|
+
notice: backoffElapsed ? "semantic index failed (inputs changed) — rebuild started; retry mode:\"semantic\" in minutes" : "semantic index failed — rebuild pending; retry mode:\"semantic\" in minutes"
|
|
5175
5313
|
};
|
|
5176
5314
|
}
|
|
5177
5315
|
const attempts = crashedVerdict ? (meta?.failedAttempts ?? 0) + 1 : meta?.failedAttempts ?? 1;
|
|
@@ -5201,13 +5339,13 @@ async function handleFailure(workspace, meta, crashedVerdict) {
|
|
|
5201
5339
|
return {
|
|
5202
5340
|
status: "failed",
|
|
5203
5341
|
isError: true,
|
|
5204
|
-
notice: "semantic index
|
|
5342
|
+
notice: "semantic index failed — re-index started; retry mode:\"semantic\" in minutes"
|
|
5205
5343
|
};
|
|
5206
5344
|
}
|
|
5207
5345
|
if (attempts < cap) return {
|
|
5208
5346
|
status: "failed",
|
|
5209
5347
|
isError: true,
|
|
5210
|
-
notice: "semantic index unavailable (recent build failure)
|
|
5348
|
+
notice: "semantic index unavailable (recent build failure) — retry mode:\"semantic\" in minutes"
|
|
5211
5349
|
};
|
|
5212
5350
|
consola.warn(`colbert: index ${cls}, giving up (attempts=${attempts}) for ${workspace}`);
|
|
5213
5351
|
return {
|
|
@@ -5286,7 +5424,7 @@ async function spawnSearch(opts) {
|
|
|
5286
5424
|
consola.debug(`colbert: search detached (indexing) for ${opts.workspace}`);
|
|
5287
5425
|
return {
|
|
5288
5426
|
status: "building",
|
|
5289
|
-
notice: "semantic index
|
|
5427
|
+
notice: "semantic index updating in background; retry mode:\"semantic\" in minutes"
|
|
5290
5428
|
};
|
|
5291
5429
|
}
|
|
5292
5430
|
if (raced.kind === "error") {
|
|
@@ -5619,6 +5757,6 @@ async function runInit(workspace) {
|
|
|
5619
5757
|
await writeColbertMeta(finalMeta).catch(() => {});
|
|
5620
5758
|
}
|
|
5621
5759
|
//#endregion
|
|
5622
|
-
export {
|
|
5760
|
+
export { recommendedRgThreads as A, extractZipMember as C, validateWorkspace as D, searchCode as E, getGrammarBundle as F, getLanguageKeyForPath as I, outlineFile as L, DEFINITION_NODE_TYPES as M, STRUCTURAL_MAX_FILE_BYTES as N, confineToWorkspaceResult as O, collectUnitNodes as P, provisionTreeSitterAssets as R, extractTarGzMember as S, resolveRipgrep as T, colbertOrtDylibPath as _, canonicalWorkspace as a, provisionColbert as b, freshnessVerdict as c, indexDirSignature as d, readColbertMeta as f, colbertArtifactsPresent as g, canonicalColbertModelDir as h, waitForInit as i, warmTreeSitterPool as j, isSensitivePath as k, gitDeltaFiles as l, validateIndexIntegrity as m, runSemanticSearch as n, colbertProjectDir as o, serveStaleMaxFiles as p, startupKickAllowed as r, completedIndexOnDisk as s, kickBackgroundInit as t, gitState as u, colbertSmokeOk as v, nextPlaidServerPromoted as w, provisionNextPlaidServer as x, nextPlaidServerBinaryPath as y, withInstallLock as z };
|
|
5623
5761
|
|
|
5624
|
-
//# sourceMappingURL=runner-
|
|
5762
|
+
//# sourceMappingURL=runner-BoJPRQsK.js.map
|