token-goat 2.9.15 → 2.9.16
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/{token-goat-chunk-ASYEPR3S.mjs → token-goat-chunk-2IEIBVVD.mjs} +7 -3
- package/dist/{token-goat-chunk-LCZBPOIN.mjs → token-goat-chunk-2PCFAQAS.mjs} +66 -51
- package/dist/{token-goat-chunk-PM76YS22.mjs → token-goat-chunk-3H6FQT62.mjs} +1 -1
- package/dist/{token-goat-chunk-C5JIO6HK.mjs → token-goat-chunk-4DC6DDIB.mjs} +5 -5
- package/dist/{token-goat-chunk-YQ7WI2CO.mjs → token-goat-chunk-5USHO7B6.mjs} +393 -3957
- package/dist/{token-goat-chunk-2X2EBBC6.mjs → token-goat-chunk-63QWJ6UM.mjs} +2 -2
- package/dist/{token-goat-chunk-NDRP4KJQ.mjs → token-goat-chunk-BFNTLGVA.mjs} +226 -50
- package/dist/token-goat-chunk-BGHSSJUA.mjs +102 -0
- package/dist/{token-goat-chunk-IVUQLQWN.mjs → token-goat-chunk-DMQ32ZSR.mjs} +5 -3
- package/dist/{token-goat-chunk-SFAS46RE.mjs → token-goat-chunk-EJCY6KHO.mjs} +2 -2
- package/dist/{token-goat-chunk-Z6UXPYJA.mjs → token-goat-chunk-F2ARFHLJ.mjs} +1 -1
- package/dist/{token-goat-chunk-YKG35VHC.mjs → token-goat-chunk-GIMGT34T.mjs} +1 -1
- package/dist/{token-goat-chunk-SZWYESBS.mjs → token-goat-chunk-GMXBQS6O.mjs} +155 -54
- package/dist/{token-goat-chunk-S4XRY446.mjs → token-goat-chunk-H3DXI6VD.mjs} +4 -3
- package/dist/{token-goat-chunk-6DLVZDB6.mjs → token-goat-chunk-LJL6FGDS.mjs} +13 -12
- package/dist/{token-goat-chunk-NEI4NC54.mjs → token-goat-chunk-LKSXAMJB.mjs} +7 -2
- package/dist/{token-goat-chunk-A4JYKD5H.mjs → token-goat-chunk-M2R4UQ3B.mjs} +2 -2
- package/dist/{token-goat-chunk-MZDIJJ3R.mjs → token-goat-chunk-MA5BZ2KI.mjs} +40 -3
- package/dist/{token-goat-chunk-GIIHUSZX.mjs → token-goat-chunk-MIL62GMN.mjs} +41 -11
- package/dist/{token-goat-chunk-NU7TLMQK.mjs → token-goat-chunk-NAMH252H.mjs} +10 -7
- package/dist/{token-goat-chunk-DQ4J5AFF.mjs → token-goat-chunk-NOBZV7PM.mjs} +69 -18
- package/dist/{token-goat-chunk-5V7DAC7V.mjs → token-goat-chunk-NQZCSVN2.mjs} +10 -3
- package/dist/{token-goat-chunk-7ZYK25AO.mjs → token-goat-chunk-OCI25AXY.mjs} +4 -4
- package/dist/{token-goat-chunk-NDPO7GAH.mjs → token-goat-chunk-QMZMHQRR.mjs} +21 -20
- package/dist/{token-goat-chunk-K7F2BFIK.mjs → token-goat-chunk-R3X5TCPB.mjs} +1 -1
- package/dist/token-goat-chunk-RRNZMM3A.mjs +3364 -0
- package/dist/{token-goat-chunk-ATIFTMRC.mjs → token-goat-chunk-ULA4WCED.mjs} +7 -7
- package/dist/{token-goat-chunk-OUGNPMDA.mjs → token-goat-chunk-UMXD2M7O.mjs} +30 -14
- package/dist/{token-goat-chunk-YZX7EFG4.mjs → token-goat-chunk-UXHDBVUR.mjs} +1 -1
- package/dist/{token-goat-chunk-LT7JRU6K.mjs → token-goat-chunk-VVIYEFBI.mjs} +4 -4
- package/dist/{token-goat-chunk-BL5LNGBG.mjs → token-goat-chunk-XOHTFRDH.mjs} +2966 -3869
- package/dist/{token-goat-chunk-XEPXYDPI.mjs → token-goat-chunk-YPS64ACE.mjs} +11 -2
- package/dist/{token-goat-chunk-GMQQA7E4.mjs → token-goat-chunk-Z5VPAXTC.mjs} +2442 -722
- package/dist/{token-goat-chunk-3NSDDTGL.mjs → token-goat-chunk-ZEHFYJ7Z.mjs} +5 -5
- package/dist/token-goat-hook.mjs +13 -12
- package/dist/token-goat.core.mjs +21 -20
- package/package.json +1 -1
|
@@ -3,7 +3,7 @@ const require = __cjsRequire(import.meta.url);
|
|
|
3
3
|
import {
|
|
4
4
|
deliveredOutputBytes,
|
|
5
5
|
wrappedShell
|
|
6
|
-
} from "./token-goat-chunk-
|
|
6
|
+
} from "./token-goat-chunk-UXHDBVUR.mjs";
|
|
7
7
|
import {
|
|
8
8
|
ToolFilter,
|
|
9
9
|
capTokens,
|
|
@@ -14,18 +14,18 @@ import {
|
|
|
14
14
|
selectFilter,
|
|
15
15
|
shlexSplit,
|
|
16
16
|
storeBashOutputSync
|
|
17
|
-
} from "./token-goat-chunk-
|
|
18
|
-
import "./token-goat-chunk-2X2EBBC6.mjs";
|
|
17
|
+
} from "./token-goat-chunk-5USHO7B6.mjs";
|
|
19
18
|
import {
|
|
20
19
|
recordStat
|
|
21
|
-
} from "./token-goat-chunk-
|
|
22
|
-
import "./token-goat-chunk-
|
|
20
|
+
} from "./token-goat-chunk-DMQ32ZSR.mjs";
|
|
21
|
+
import "./token-goat-chunk-63QWJ6UM.mjs";
|
|
22
|
+
import "./token-goat-chunk-R3X5TCPB.mjs";
|
|
23
23
|
import {
|
|
24
24
|
loadConfig
|
|
25
|
-
} from "./token-goat-chunk-
|
|
25
|
+
} from "./token-goat-chunk-H3DXI6VD.mjs";
|
|
26
26
|
import "./token-goat-chunk-EEIDFMEM.mjs";
|
|
27
27
|
import "./token-goat-chunk-OSUFN2FV.mjs";
|
|
28
|
-
import "./token-goat-chunk-
|
|
28
|
+
import "./token-goat-chunk-3H6FQT62.mjs";
|
|
29
29
|
import "./token-goat-chunk-ERTXEKB6.mjs";
|
|
30
30
|
import "./token-goat-chunk-GMOUBOX4.mjs";
|
|
31
31
|
import {
|
|
@@ -2,32 +2,33 @@ import { createRequire as __cjsRequire } from 'node:module';
|
|
|
2
2
|
const require = __cjsRequire(import.meta.url);
|
|
3
3
|
import {
|
|
4
4
|
enqueueDirtyPathSafe,
|
|
5
|
+
getToolName,
|
|
5
6
|
getTrackedFiles
|
|
6
|
-
} from "./token-goat-chunk-
|
|
7
|
+
} from "./token-goat-chunk-XOHTFRDH.mjs";
|
|
7
8
|
import {
|
|
8
|
-
getToolName,
|
|
9
9
|
indexRecallEntry
|
|
10
|
-
} from "./token-goat-chunk-
|
|
11
|
-
import {
|
|
12
|
-
PARSER_FINGERPRINT
|
|
13
|
-
} from "./token-goat-chunk-NDRP4KJQ.mjs";
|
|
14
|
-
import {
|
|
15
|
-
getProjectFileEntries
|
|
16
|
-
} from "./token-goat-chunk-2X2EBBC6.mjs";
|
|
10
|
+
} from "./token-goat-chunk-5USHO7B6.mjs";
|
|
17
11
|
import {
|
|
18
12
|
isBlobStale,
|
|
19
13
|
loadBlob,
|
|
20
14
|
redactSecrets,
|
|
21
15
|
storeBlob
|
|
22
|
-
} from "./token-goat-chunk-
|
|
16
|
+
} from "./token-goat-chunk-DMQ32ZSR.mjs";
|
|
17
|
+
import {
|
|
18
|
+
PARSER_FINGERPRINT
|
|
19
|
+
} from "./token-goat-chunk-BFNTLGVA.mjs";
|
|
20
|
+
import {
|
|
21
|
+
getProjectFileEntries,
|
|
22
|
+
projectScopeClause
|
|
23
|
+
} from "./token-goat-chunk-63QWJ6UM.mjs";
|
|
23
24
|
import {
|
|
24
25
|
getDb
|
|
25
|
-
} from "./token-goat-chunk-
|
|
26
|
+
} from "./token-goat-chunk-R3X5TCPB.mjs";
|
|
26
27
|
import {
|
|
27
28
|
fingerprintFile,
|
|
28
29
|
getDisplayRoot,
|
|
29
30
|
shortFingerprint
|
|
30
|
-
} from "./token-goat-chunk-
|
|
31
|
+
} from "./token-goat-chunk-H3DXI6VD.mjs";
|
|
31
32
|
import {
|
|
32
33
|
registerReset
|
|
33
34
|
} from "./token-goat-chunk-EEIDFMEM.mjs";
|
|
@@ -37,7 +38,7 @@ import {
|
|
|
37
38
|
extractErrorMessage,
|
|
38
39
|
foldPath,
|
|
39
40
|
globalDbPath
|
|
40
|
-
} from "./token-goat-chunk-
|
|
41
|
+
} from "./token-goat-chunk-3H6FQT62.mjs";
|
|
41
42
|
import {
|
|
42
43
|
displaySafeJson,
|
|
43
44
|
normalizePath,
|
|
@@ -815,6 +816,10 @@ function runReconcile(opts = {}) {
|
|
|
815
816
|
const reparseVerb = opts.dryRun === true ? "would reparse" : "queued for reparse";
|
|
816
817
|
lines.push(`${countNoun(result.parserStale, "file")} of the above ${result.parserStale === 1 ? "was" : "were"} unchanged on disk but indexed by an older parser (${reparseVerb}).`);
|
|
817
818
|
}
|
|
819
|
+
if (result.embedStale > 0) {
|
|
820
|
+
const reembedVerb = opts.dryRun === true ? "would re-embed" : "queued for re-embedding";
|
|
821
|
+
lines.push(`${countNoun(result.embedStale, "file")} of the above ${result.embedStale === 1 ? "was" : "were"} unchanged on disk but held out-of-date embeddings (${reembedVerb}).`);
|
|
822
|
+
}
|
|
818
823
|
if (result.trackedUnavailable) {
|
|
819
824
|
lines.push("This project has an index but git listed no files in it, so nothing could be compared and no deletions were computed. Run token-goat inside the repository, or reindex with --walk if this directory is deliberately not under git.");
|
|
820
825
|
}
|
|
@@ -836,6 +841,10 @@ function reconcileProject(opts = {}) {
|
|
|
836
841
|
const tracked = getTrackedFiles(cwd);
|
|
837
842
|
const projectRoot = resolveIndexPath(".", cwd);
|
|
838
843
|
const indexed = getProjectFileEntries(projectRoot, dbPath);
|
|
844
|
+
const chunkScope = projectScopeClause("file_path");
|
|
845
|
+
const chunked = new Set(
|
|
846
|
+
getDb(dbPath).prepare(`SELECT DISTINCT file_path FROM chunks WHERE ${chunkScope.clause}`).pluck().all(...chunkScope.params(projectRoot)).map((p) => foldPath(normalizePath(p)))
|
|
847
|
+
);
|
|
839
848
|
let scanOrder = tracked;
|
|
840
849
|
const cursorPath = tracked.length > 0 ? readReconcileCursor(dbPath, projectRoot) : null;
|
|
841
850
|
if (cursorPath !== null) {
|
|
@@ -850,6 +859,7 @@ function reconcileProject(opts = {}) {
|
|
|
850
859
|
const seenOnDisk = /* @__PURE__ */ new Set();
|
|
851
860
|
let mtimeOnly = 0;
|
|
852
861
|
let parserStale = 0;
|
|
862
|
+
let embedStale = 0;
|
|
853
863
|
let scanned = 0;
|
|
854
864
|
let budgetExhausted = false;
|
|
855
865
|
let lastScanned = null;
|
|
@@ -872,6 +882,11 @@ function reconcileProject(opts = {}) {
|
|
|
872
882
|
parserStale++;
|
|
873
883
|
continue;
|
|
874
884
|
}
|
|
885
|
+
if (entry.embedSha === "" && chunked.has(folded)) {
|
|
886
|
+
changed.push(file);
|
|
887
|
+
embedStale++;
|
|
888
|
+
continue;
|
|
889
|
+
}
|
|
875
890
|
let mtimeMs;
|
|
876
891
|
try {
|
|
877
892
|
mtimeMs = fs2.statSync(file).mtimeMs;
|
|
@@ -879,7 +894,7 @@ function reconcileProject(opts = {}) {
|
|
|
879
894
|
changed.push(file);
|
|
880
895
|
continue;
|
|
881
896
|
}
|
|
882
|
-
if (entry.mtime !== 0 && mtimeMs === entry.mtime) continue;
|
|
897
|
+
if (entry.mtime !== 0 && mtimeMs / 1e3 === entry.mtime) continue;
|
|
883
898
|
const diskSha = fingerprintFile(file);
|
|
884
899
|
if (diskSha === null) {
|
|
885
900
|
changed.push(file);
|
|
@@ -927,6 +942,7 @@ function reconcileProject(opts = {}) {
|
|
|
927
942
|
removed,
|
|
928
943
|
mtimeOnly,
|
|
929
944
|
parserStale,
|
|
945
|
+
embedStale,
|
|
930
946
|
budgetExhausted,
|
|
931
947
|
trackedUnavailable,
|
|
932
948
|
unscanned: Math.max(0, tracked.length - scanned),
|
|
@@ -2,7 +2,7 @@ import { createRequire as __cjsRequire } from 'node:module';
|
|
|
2
2
|
const require = __cjsRequire(import.meta.url);
|
|
3
3
|
import {
|
|
4
4
|
detectHarness
|
|
5
|
-
} from "./token-goat-chunk-
|
|
5
|
+
} from "./token-goat-chunk-H3DXI6VD.mjs";
|
|
6
6
|
import {
|
|
7
7
|
init_define_import_meta_env
|
|
8
8
|
} from "./token-goat-chunk-A37V4PBF.mjs";
|
|
@@ -5,13 +5,13 @@ import {
|
|
|
5
5
|
docxTables,
|
|
6
6
|
docxText,
|
|
7
7
|
formatDocxTables
|
|
8
|
-
} from "./token-goat-chunk-
|
|
9
|
-
import "./token-goat-chunk-
|
|
8
|
+
} from "./token-goat-chunk-NQZCSVN2.mjs";
|
|
9
|
+
import "./token-goat-chunk-MA5BZ2KI.mjs";
|
|
10
10
|
import "./token-goat-chunk-XTQAOTSO.mjs";
|
|
11
11
|
import "./token-goat-chunk-AH6QILZM.mjs";
|
|
12
|
-
import "./token-goat-chunk-
|
|
13
|
-
import "./token-goat-chunk-PM76YS22.mjs";
|
|
12
|
+
import "./token-goat-chunk-3H6FQT62.mjs";
|
|
14
13
|
import "./token-goat-chunk-ERTXEKB6.mjs";
|
|
14
|
+
import "./token-goat-chunk-Y4AFKTHK.mjs";
|
|
15
15
|
import "./token-goat-chunk-GMOUBOX4.mjs";
|
|
16
16
|
import "./token-goat-chunk-A37V4PBF.mjs";
|
|
17
17
|
export {
|