pi-smart-compact 9.5.0 → 9.6.1
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/ARCHITECTURE.md +7 -5
- package/CHANGELOG.md +40 -0
- package/README.md +35 -19
- package/dist/app/global-settings-runtime.d.ts +7 -0
- package/dist/app/global-settings-runtime.d.ts.map +1 -0
- package/dist/app/register-context-tools.d.ts +4 -1
- package/dist/app/register-context-tools.d.ts.map +1 -1
- package/dist/app/register-smart-compact-command.d.ts +3 -1
- package/dist/app/register-smart-compact-command.d.ts.map +1 -1
- package/dist/app/run-context.d.ts +3 -3
- package/dist/app/run-context.d.ts.map +1 -1
- package/dist/app/smart-compact-policy.d.ts +4 -1
- package/dist/app/smart-compact-policy.d.ts.map +1 -1
- package/dist/app/steps/tier.d.ts +5 -4
- package/dist/app/steps/tier.d.ts.map +1 -1
- package/dist/constants.d.ts +43 -1
- package/dist/constants.d.ts.map +1 -1
- package/dist/domain/tool-semantics.d.ts.map +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1830 -560
- package/dist/infra/ai-messages.d.ts.map +1 -1
- package/dist/infra/fs.d.ts +2 -1
- package/dist/infra/fs.d.ts.map +1 -1
- package/dist/phases/explore.d.ts.map +1 -1
- package/dist/phases/synthesize.d.ts +5 -0
- package/dist/phases/synthesize.d.ts.map +1 -1
- package/dist/phases/verify.d.ts.map +1 -1
- package/dist/provider-eval.js +157 -54
- package/dist/provider-scenario-eval.js +162 -57
- package/dist/telemetry-report.js +125 -22
- package/dist/ui/overlays.d.ts.map +1 -1
- package/dist/ui/settings-complex.d.ts +9 -0
- package/dist/ui/settings-complex.d.ts.map +1 -0
- package/dist/ui/settings-overlay.d.ts +43 -3
- package/dist/ui/settings-overlay.d.ts.map +1 -1
- package/dist/utils/config.d.ts +14 -1
- package/dist/utils/config.d.ts.map +1 -1
- package/dist/utils/file-needles.d.ts +24 -0
- package/dist/utils/file-needles.d.ts.map +1 -1
- package/dist/utils/file-ref-detect.d.ts +6 -1
- package/dist/utils/file-ref-detect.d.ts.map +1 -1
- package/dist/utils/helpers.d.ts +1 -0
- package/dist/utils/helpers.d.ts.map +1 -1
- package/package.json +5 -3
package/dist/telemetry-report.js
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
var __require = import.meta.require;
|
|
3
3
|
|
|
4
4
|
// src/constants.ts
|
|
5
|
-
var VERSION = "9.
|
|
5
|
+
var VERSION = "9.6.1";
|
|
6
6
|
var SETTLED_TRIGGER_COOLDOWN_MS = 10 * 60000;
|
|
7
7
|
var COMPACT_SYSTEM_PREFIX = "You are an expert conversation summarizer for a coding agent. " + "Produce structured markdown summaries. " + "Follow output format exactly. " + "Use EXACT names \u2014 never paraphrase code identifiers. " + "Trust deterministic extraction data over intuition.";
|
|
8
8
|
var PROFILES = {
|
|
@@ -803,38 +803,117 @@ function buildPathNeedles(filePath) {
|
|
|
803
803
|
}
|
|
804
804
|
return needles;
|
|
805
805
|
}
|
|
806
|
-
|
|
807
|
-
|
|
806
|
+
var MAX_INDEXED_SUFFIX_CHARS = 1024;
|
|
807
|
+
function buildPathNeedleOwnershipIndex(allPaths) {
|
|
808
|
+
const owners = new Map;
|
|
809
|
+
const normalizedPaths = allPaths.map(normalizePath);
|
|
810
|
+
let hasUnindexedSuffixes = false;
|
|
811
|
+
for (const normalized of normalizedPaths) {
|
|
812
|
+
const suffixes = new Set([normalized]);
|
|
813
|
+
for (let index = 0;index < normalized.length; index++) {
|
|
814
|
+
if (normalized[index] !== "/")
|
|
815
|
+
continue;
|
|
816
|
+
if (normalized.length - index - 1 <= MAX_INDEXED_SUFFIX_CHARS) {
|
|
817
|
+
suffixes.add(normalized.slice(index + 1));
|
|
818
|
+
} else {
|
|
819
|
+
hasUnindexedSuffixes = true;
|
|
820
|
+
}
|
|
821
|
+
}
|
|
822
|
+
for (const suffix of suffixes) {
|
|
823
|
+
owners.set(suffix, (owners.get(suffix) ?? 0) + 1);
|
|
824
|
+
}
|
|
825
|
+
}
|
|
826
|
+
return { counts: owners, normalizedPaths, hasUnindexedSuffixes };
|
|
827
|
+
}
|
|
828
|
+
function buildUniquePathNeedlesFromIndex(filePath, owners) {
|
|
808
829
|
return buildPathNeedles(filePath).filter((needle) => {
|
|
809
|
-
|
|
810
|
-
|
|
830
|
+
if (!owners.hasUnindexedSuffixes)
|
|
831
|
+
return owners.counts.get(needle) === 1;
|
|
832
|
+
let count = 0;
|
|
833
|
+
for (const candidate of owners.normalizedPaths) {
|
|
811
834
|
if (candidate === needle || candidate.endsWith("/" + needle))
|
|
812
|
-
|
|
813
|
-
if (
|
|
835
|
+
count++;
|
|
836
|
+
if (count > 1)
|
|
814
837
|
return false;
|
|
815
838
|
}
|
|
816
|
-
return
|
|
839
|
+
return count === 1;
|
|
817
840
|
});
|
|
818
841
|
}
|
|
819
|
-
|
|
820
|
-
|
|
821
|
-
|
|
822
|
-
|
|
823
|
-
const
|
|
824
|
-
|
|
842
|
+
var PATH_CANDIDATE_CHAR_RE = /[\w./-]/;
|
|
843
|
+
function buildKnownPathReferenceIndex(knownPaths) {
|
|
844
|
+
const segmentSuffixes = new Set;
|
|
845
|
+
const boundarySuffixes = new Set;
|
|
846
|
+
const normalizedPaths = [];
|
|
847
|
+
let hasUnindexedSuffixes = false;
|
|
848
|
+
for (const path2 of knownPaths) {
|
|
825
849
|
const normalizedPath = normalizePath(path2).replace(/^\/+/, "");
|
|
850
|
+
if (!normalizedPath)
|
|
851
|
+
continue;
|
|
852
|
+
normalizedPaths.push(normalizedPath);
|
|
853
|
+
segmentSuffixes.add(normalizedPath);
|
|
854
|
+
for (let index = 0;index < normalizedPath.length; index++) {
|
|
855
|
+
if (normalizedPath[index] === "/") {
|
|
856
|
+
if (normalizedPath.length - index - 1 <= MAX_INDEXED_SUFFIX_CHARS) {
|
|
857
|
+
segmentSuffixes.add(normalizedPath.slice(index + 1));
|
|
858
|
+
} else {
|
|
859
|
+
hasUnindexedSuffixes = true;
|
|
860
|
+
}
|
|
861
|
+
}
|
|
862
|
+
if (index > 0 && !PATH_CANDIDATE_CHAR_RE.test(normalizedPath[index - 1])) {
|
|
863
|
+
if (normalizedPath.length - index <= MAX_INDEXED_SUFFIX_CHARS) {
|
|
864
|
+
boundarySuffixes.add(normalizedPath.slice(index));
|
|
865
|
+
} else {
|
|
866
|
+
hasUnindexedSuffixes = true;
|
|
867
|
+
}
|
|
868
|
+
}
|
|
869
|
+
}
|
|
870
|
+
}
|
|
871
|
+
return {
|
|
872
|
+
segmentSuffixes,
|
|
873
|
+
sortedSegmentSuffixes: [...segmentSuffixes].sort(),
|
|
874
|
+
boundarySuffixes,
|
|
875
|
+
normalizedPaths,
|
|
876
|
+
hasUnindexedSuffixes
|
|
877
|
+
};
|
|
878
|
+
}
|
|
879
|
+
function matchesKnownPathReference(normalizedRef, normalizedPaths) {
|
|
880
|
+
const pathShaped = normalizedRef.includes("/");
|
|
881
|
+
return normalizedPaths.some((normalizedPath) => {
|
|
826
882
|
if (normalizedPath === normalizedRef || normalizedPath.endsWith("/" + normalizedRef))
|
|
827
883
|
return true;
|
|
828
884
|
if (normalizedPath.endsWith(normalizedRef)) {
|
|
829
885
|
const boundary = normalizedPath[normalizedPath.length - normalizedRef.length - 1];
|
|
830
|
-
if (boundary &&
|
|
886
|
+
if (boundary && !PATH_CANDIDATE_CHAR_RE.test(boundary))
|
|
831
887
|
return true;
|
|
832
888
|
}
|
|
833
889
|
if (!pathShaped)
|
|
834
890
|
return false;
|
|
835
|
-
return normalizedPath.
|
|
891
|
+
return normalizedPath.startsWith(normalizedRef + "/") || normalizedPath.includes("/" + normalizedRef + "/");
|
|
836
892
|
});
|
|
837
893
|
}
|
|
894
|
+
function sortedHasPrefix(values, prefix) {
|
|
895
|
+
let low = 0;
|
|
896
|
+
let high = values.length;
|
|
897
|
+
while (low < high) {
|
|
898
|
+
const middle = low + high >>> 1;
|
|
899
|
+
if (values[middle] < prefix)
|
|
900
|
+
low = middle + 1;
|
|
901
|
+
else
|
|
902
|
+
high = middle;
|
|
903
|
+
}
|
|
904
|
+
return values[low]?.startsWith(prefix) ?? false;
|
|
905
|
+
}
|
|
906
|
+
function isKnownPathReferenceInIndex(ref, index) {
|
|
907
|
+
const normalizedRef = normalizePath(ref).replace(/^\/+/, "");
|
|
908
|
+
if (!normalizedRef)
|
|
909
|
+
return false;
|
|
910
|
+
if (index.segmentSuffixes.has(normalizedRef) || index.boundarySuffixes.has(normalizedRef)) {
|
|
911
|
+
return true;
|
|
912
|
+
}
|
|
913
|
+
if (normalizedRef.includes("/") && sortedHasPrefix(index.sortedSegmentSuffixes, normalizedRef + "/"))
|
|
914
|
+
return true;
|
|
915
|
+
return index.hasUnindexedSuffixes ? matchesKnownPathReference(normalizedRef, index.normalizedPaths) : false;
|
|
916
|
+
}
|
|
838
917
|
|
|
839
918
|
// src/domain/tool-semantics.ts
|
|
840
919
|
var PATH_KEYS = [
|
|
@@ -906,7 +985,12 @@ function classifyToolOperation(args, toolName) {
|
|
|
906
985
|
// src/utils/file-ref-detect.ts
|
|
907
986
|
var CODE_EXT_RE = /\.(ts|tsx|js|jsx|mjs|cjs|rs|py|go|java|rb|cs|cpp|c|h|hpp|swift|kt|scala|php|css|scss|html|json|yaml|yml|toml|md|mdx|sh|sql|tf|ini|env|lock|gradle|xml)$/i;
|
|
908
987
|
var VERSION_RE = /^v?\d+(?:\.\d+)+(?:[-+][\w.-]+)?$/i;
|
|
909
|
-
|
|
988
|
+
function isAsciiWordCode(code) {
|
|
989
|
+
return code >= 48 && code <= 57 || code >= 65 && code <= 90 || code === 95 || code >= 97 && code <= 122;
|
|
990
|
+
}
|
|
991
|
+
function isCandidateCode(code) {
|
|
992
|
+
return isAsciiWordCode(code) || code === 45 || code === 46 || code === 47;
|
|
993
|
+
}
|
|
910
994
|
function isLikelyFileRef(candidate) {
|
|
911
995
|
if (candidate.startsWith("//") || VERSION_RE.test(candidate))
|
|
912
996
|
return false;
|
|
@@ -917,13 +1001,32 @@ function isLikelyFileRef(candidate) {
|
|
|
917
1001
|
return CODE_EXT_RE.test(candidate);
|
|
918
1002
|
}
|
|
919
1003
|
function extractFileRefs(summary) {
|
|
920
|
-
const matcher = new RegExp(FILE_REF_CANDIDATE_RE.source, FILE_REF_CANDIDATE_RE.flags);
|
|
921
1004
|
const refs = [];
|
|
922
|
-
|
|
923
|
-
|
|
1005
|
+
let cursor = 0;
|
|
1006
|
+
while (cursor < summary.length) {
|
|
1007
|
+
while (cursor < summary.length && !isCandidateCode(summary.charCodeAt(cursor)))
|
|
1008
|
+
cursor++;
|
|
1009
|
+
const runStart = cursor;
|
|
1010
|
+
while (cursor < summary.length && isCandidateCode(summary.charCodeAt(cursor)))
|
|
1011
|
+
cursor++;
|
|
1012
|
+
const runEnd = cursor;
|
|
1013
|
+
let extensionDot = -1;
|
|
1014
|
+
for (let index = runStart + 1;index + 1 < runEnd; index++) {
|
|
1015
|
+
if (summary.charCodeAt(index) === 46 && isAsciiWordCode(summary.charCodeAt(index + 1))) {
|
|
1016
|
+
extensionDot = index;
|
|
1017
|
+
}
|
|
1018
|
+
}
|
|
1019
|
+
if (extensionDot < 0)
|
|
1020
|
+
continue;
|
|
1021
|
+
let matchEnd = extensionDot + 2;
|
|
1022
|
+
while (matchEnd < runEnd && isAsciiWordCode(summary.charCodeAt(matchEnd))) {
|
|
1023
|
+
matchEnd++;
|
|
1024
|
+
}
|
|
1025
|
+
const candidate = summary.slice(runStart, matchEnd);
|
|
1026
|
+
if (/[\\/]/.test(summary[matchEnd] ?? ""))
|
|
924
1027
|
continue;
|
|
925
|
-
if (isLikelyFileRef(
|
|
926
|
-
refs.push(
|
|
1028
|
+
if (isLikelyFileRef(candidate))
|
|
1029
|
+
refs.push(candidate);
|
|
927
1030
|
}
|
|
928
1031
|
return refs;
|
|
929
1032
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"overlays.d.ts","sourceRoot":"","sources":["../../src/ui/overlays.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,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AC9B,IAAI,GAAE;IAAE,QAAQ,CAAC,EAAE,OAAO,CAAC;IAAC,OAAO,CAAC,EAAE,MAAM,CAAA;CAAO,GAClD,OAAO,CAAC,OAAO,GAAG,QAAQ,GAAG,QAAQ,CAAC,CA+iBxC;AAED,wBAAsB,aAAa,CACjC,GAAG,EAAE,uBAAuB,EAC5B,IAAI,EAAE;IACJ,aAAa,EAAE,MAAM,CAAC;IACtB,cAAc,EAAE,MAAM,CAAC;IACvB,gBAAgB,EAAE,MAAM,CAAC;IACzB,iBAAiB,EAAE,MAAM,CAAC;IAC1B,MAAM,EAAE,aAAa,CAAC;CACvB,GACA,OAAO,CAAC;IAAE,KAAK,EAAE,WAAW,CAAC;IAAC,IAAI,EAAE,cAAc,CAAA;CAAE,GAAG,IAAI,CAAC,CAkQ9D;AAED,OAAO,EACL,gBAAgB,EAChB,iBAAiB,EACjB,iBAAiB,GAClB,MAAM,sBAAsB,CAAC;AAC9B,OAAO,EAAE,eAAe,EAAE,MAAM,yBAAyB,CAAC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type { ExtensionCommandContext } from "@earendil-works/pi-coding-agent";
|
|
2
|
+
import { type SettingItem } from "@earendil-works/pi-tui";
|
|
3
|
+
import type { CompactConfig } from "../types.ts";
|
|
4
|
+
import { type GlobalConfigPath, type GlobalConfigValue } from "../utils/config.ts";
|
|
5
|
+
export type GlobalConfigWriter = (path: GlobalConfigPath, value: GlobalConfigValue) => Promise<CompactConfig>;
|
|
6
|
+
export declare function modelSettingsItems(ctx: ExtensionCommandContext, requestRender: () => void, writeConfig?: GlobalConfigWriter): SettingItem[];
|
|
7
|
+
export declare function complexSettingsCategories(ctx: ExtensionCommandContext, requestRender: () => void, writeConfig?: GlobalConfigWriter): SettingItem[];
|
|
8
|
+
export declare function complexConfigPaths(): GlobalConfigPath[];
|
|
9
|
+
//# sourceMappingURL=settings-complex.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"settings-complex.d.ts","sourceRoot":"","sources":["../../src/ui/settings-complex.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,iCAAiC,CAAC;AAE/E,OAAO,EAQL,KAAK,WAAW,EAGjB,MAAM,wBAAwB,CAAC;AAOhC,OAAO,KAAK,EAAE,aAAa,EAAsB,MAAM,aAAa,CAAC;AACrE,OAAO,EACL,KAAK,gBAAgB,EACrB,KAAK,iBAAiB,EAIvB,MAAM,oBAAoB,CAAC;AAE5B,MAAM,MAAM,kBAAkB,GAAG,CAC/B,IAAI,EAAE,gBAAgB,EACtB,KAAK,EAAE,iBAAiB,KACrB,OAAO,CAAC,aAAa,CAAC,CAAC;AAgZ5B,wBAAgB,kBAAkB,CAChC,GAAG,EAAE,uBAAuB,EAC5B,aAAa,EAAE,MAAM,IAAI,EACzB,WAAW,GAAE,kBAA2C,GACvD,WAAW,EAAE,CAgEf;AAED,wBAAgB,yBAAyB,CACvC,GAAG,EAAE,uBAAuB,EAC5B,aAAa,EAAE,MAAM,IAAI,EACzB,WAAW,GAAE,kBAA2C,GACvD,WAAW,EAAE,CAuEf;AAED,wBAAgB,kBAAkB,IAAI,gBAAgB,EAAE,CASvD"}
|
|
@@ -1,5 +1,45 @@
|
|
|
1
1
|
import { type ExtensionCommandContext } from "@earendil-works/pi-coding-agent";
|
|
2
|
-
import type
|
|
3
|
-
|
|
4
|
-
|
|
2
|
+
import { type Component, type Focusable, SettingsList, type SettingItem } from "@earendil-works/pi-tui";
|
|
3
|
+
import { type GlobalConfigPath } from "../utils/config.ts";
|
|
4
|
+
import type { CompactConfig } from "../types.ts";
|
|
5
|
+
import { type GlobalConfigWriter } from "./settings-complex.ts";
|
|
6
|
+
import type { SmartCompactPolicy, SmartCompactPolicySnapshot } from "../app/smart-compact-policy.ts";
|
|
7
|
+
type GlobalChoiceGroup = "behavior" | "reasoning" | "safety" | "advanced";
|
|
8
|
+
type GlobalSettingWriter = typeof updateGlobalChoiceSetting;
|
|
9
|
+
export type GlobalSettingApplied = (path: GlobalConfigPath, config: CompactConfig) => void | Promise<void>;
|
|
10
|
+
interface GlobalSettingState {
|
|
11
|
+
display: string;
|
|
12
|
+
config?: CompactConfig;
|
|
13
|
+
}
|
|
14
|
+
export declare class GlobalSettingsCoordinator {
|
|
15
|
+
private readonly writer;
|
|
16
|
+
private queue;
|
|
17
|
+
private readonly confirmed;
|
|
18
|
+
private confirmedConfig;
|
|
19
|
+
private readonly pending;
|
|
20
|
+
private readonly listeners;
|
|
21
|
+
constructor(writer?: GlobalSettingWriter);
|
|
22
|
+
display(id: GlobalConfigPath): string;
|
|
23
|
+
subscribe(ids: readonly GlobalConfigPath[], listener: (id: GlobalConfigPath, state: GlobalSettingState) => void): () => void;
|
|
24
|
+
submit(group: GlobalChoiceGroup, id: GlobalConfigPath, display: string, onError: (message: string) => void, onApplied?: GlobalSettingApplied): void;
|
|
25
|
+
settled(): Promise<void>;
|
|
26
|
+
private emit;
|
|
27
|
+
}
|
|
28
|
+
export declare function globalChoiceSettingsItems(group: GlobalChoiceGroup, config: CompactConfig, coordinator?: GlobalSettingsCoordinator): SettingItem[];
|
|
29
|
+
export declare function updateGlobalChoiceSetting(group: GlobalChoiceGroup, id: string, display: string): Promise<CompactConfig>;
|
|
30
|
+
export declare function sessionSettingsItems(policy: SmartCompactPolicy): SettingItem[];
|
|
31
|
+
export declare function updateSessionSetting(policy: SmartCompactPolicy, ctx: ExtensionCommandContext, id: string, value: string): {
|
|
32
|
+
ok: true;
|
|
33
|
+
policy: SmartCompactPolicySnapshot;
|
|
34
|
+
} | {
|
|
35
|
+
ok: false;
|
|
36
|
+
policy: SmartCompactPolicySnapshot;
|
|
37
|
+
error: string;
|
|
38
|
+
};
|
|
39
|
+
export declare function settingsCategoryItems(policy: SmartCompactPolicy, ctx: ExtensionCommandContext, requestRender?: () => void, coordinator?: GlobalSettingsCoordinator, onApplied?: GlobalSettingApplied, writeConfig?: GlobalConfigWriter): SettingItem[];
|
|
40
|
+
export declare function createSettingsRoot(policy: SmartCompactPolicy, ctx: ExtensionCommandContext, onCancel: () => void, requestRender?: () => void, coordinator?: GlobalSettingsCoordinator, onApplied?: GlobalSettingApplied, writeConfig?: GlobalConfigWriter): SettingsList;
|
|
41
|
+
export declare function createSettingsController(root: SettingsList, display: Component, requestRender: () => void): Component & Focusable;
|
|
42
|
+
/** Open the unified Smart Compact settings panel. */
|
|
43
|
+
export declare function showSmartCompactSettings(ctx: ExtensionCommandContext, policy: SmartCompactPolicy, coordinator?: GlobalSettingsCoordinator, onApplied?: GlobalSettingApplied): Promise<void>;
|
|
44
|
+
export {};
|
|
5
45
|
//# sourceMappingURL=settings-overlay.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"settings-overlay.d.ts","sourceRoot":"","sources":["../../src/ui/settings-overlay.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,KAAK,uBAAuB,EAC7B,MAAM,iCAAiC,CAAC;
|
|
1
|
+
{"version":3,"file":"settings-overlay.d.ts","sourceRoot":"","sources":["../../src/ui/settings-overlay.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,KAAK,uBAAuB,EAC7B,MAAM,iCAAiC,CAAC;AACzC,OAAO,EACL,KAAK,SAAS,EAEd,KAAK,SAAS,EACd,YAAY,EACZ,KAAK,WAAW,EAEjB,MAAM,wBAAwB,CAAC;AAChC,OAAO,EAGL,KAAK,gBAAgB,EAGtB,MAAM,oBAAoB,CAAC;AAC5B,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AACjD,OAAO,EAEL,KAAK,kBAAkB,EACxB,MAAM,uBAAuB,CAAC;AAC/B,OAAO,KAAK,EACV,kBAAkB,EAElB,0BAA0B,EAC3B,MAAM,gCAAgC,CAAC;AAaxC,KAAK,iBAAiB,GAClB,UAAU,GACV,WAAW,GACX,QAAQ,GACR,UAAU,CAAC;AAEf,KAAK,mBAAmB,GAAG,OAAO,yBAAyB,CAAC;AAC5D,MAA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AAC,aAAa,CAAC,CAMxB;AAWD,wBAAgB,oBAAoB,CAClC,MAAM,EAAE,kBAAkB,GACzB,WAAW,EAAE,CAgCf;AAaD,wBAAgB,oBAAoB,CAClC,MAAM,EAAE,kBAAkB,EAC1B,GAAG,EAAE,uBAAuB,EAC5B,EAAE,EAAE,MAAM,EACV,KAAK,EAAE,MAAM;;;;;;;EAed;AA8FD,wBAAgB,qBAAqB,CACnC,MAAM,EAAE,kBAAkB,EAC1B,GAAG,EAAE,uBAAuB,EAC5B,aAAa,GAAE,MAAM,IAAe,EACpC,WAAW,GAAE,yBAA2D,EACxE,SAAS,GAAE,oBAA+B,EAC1C,WAAW,GAAE,kBAA2C,GACvD,WAAW,EAAE,CA0Bf;AAED,wBAAgB,kBAAkB,CAChC,MAAM,EAAE,kBAAkB,EAC1B,GAAG,EAAE,uBAAuB,EAC5B,QAAQ,EAAE,MAAM,IAAI,EACpB,aAAa,GAAE,MAAM,IAAe,EACpC,WAAW,GAAE,yBAA2D,EACxE,SAAS,GAAE,oBAA+B,EAC1C,WAAW,GAAE,kBAA2C,GACvD,YAAY,CAed;AAoBD,wBAAgB,wBAAwB,CACtC,IAAI,EAAE,YAAY,EAClB,OAAO,EAAE,SAAS,EAClB,aAAa,EAAE,MAAM,IAAI,GACxB,SAAS,GAAG,SAAS,CA8BvB;AAED,qDAAqD;AACrD,wBAAsB,wBAAwB,CAC5C,GAAG,EAAE,uBAAuB,EAC5B,MAAM,EAAE,kBAAkB,EAC1B,WAAW,GAAE,yBAA2D,EACxE,SAAS,GAAE,oBAA+B,GACzC,OAAO,CAAC,IAAI,CAAC,CA8Cf"}
|
package/dist/utils/config.d.ts
CHANGED
|
@@ -1,7 +1,20 @@
|
|
|
1
|
-
import type { CompactConfig } from "../types.ts";
|
|
1
|
+
import type { CompactConfig, CompressionProfile, ProfileConfig } from "../types.ts";
|
|
2
|
+
declare const PROFILE_NUMERIC_KEYS: readonly ["summaryBudgetTokens", "keepRecentTokens", "minChunkTokens", "maxChunkTokens", "singlePassMaxTokens", "batchMaxTokens"];
|
|
3
|
+
type TopLevelConfigKey = Exclude<keyof CompactConfig, "profiles">;
|
|
4
|
+
type ProfileNumericKey = (typeof PROFILE_NUMERIC_KEYS)[number];
|
|
5
|
+
export type GlobalConfigPath = TopLevelConfigKey | `profiles.${CompressionProfile}.${ProfileNumericKey}`;
|
|
6
|
+
export type GlobalConfigValue = CompactConfig[TopLevelConfigKey] | ProfileConfig[ProfileNumericKey] | undefined;
|
|
7
|
+
export declare function readGlobalConfigValue(configPath: GlobalConfigPath): GlobalConfigValue;
|
|
2
8
|
/** Remove invalid user values so the defaults merge remains authoritative. */
|
|
3
9
|
export declare function validateSmartCompactConfig(sc: Record<string, unknown>): void;
|
|
10
|
+
/**
|
|
11
|
+
* Persist one extension-owned global setting without replacing other Pi or
|
|
12
|
+
* extension settings. Passing undefined removes the override so the built-in
|
|
13
|
+
* default becomes effective again.
|
|
14
|
+
*/
|
|
15
|
+
export declare function writeGlobalConfigValue(configPath: GlobalConfigPath, value: GlobalConfigValue): Promise<CompactConfig>;
|
|
4
16
|
/** Test helper — forces the next loadConfig() to re-read settings.json. */
|
|
5
17
|
export declare function resetConfigCache(): void;
|
|
6
18
|
export declare function loadConfig(): CompactConfig;
|
|
19
|
+
export {};
|
|
7
20
|
//# sourceMappingURL=config.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../../src/utils/config.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../../src/utils/config.ts"],"names":[],"mappings":"AAWA,OAAO,KAAK,EACV,aAAa,EACb,kBAAkB,EAClB,aAAa,EACd,MAAM,aAAa,CAAC;AAqCrB,QAAA,MAAM,oBAAoB,YACxB,qBAAqB,EACrB,kBAAkB,EAClB,gBAAgB,EAChB,gBAAgB,EAChB,qBAAqB,EACrB,gBAAgB,CACR,CAAC;AACX,KAAK,iBAAiB,GAAG,OAAO,CAAC,MAAM,aAAa,EAAE,UAAU,CAAC,CAAC;AAClE,KAAK,iBAAiB,GAAG,CAAC,OAAO,oBAAoB,CAAC,CAAC,MAAM,CAAC,CAAC;AAC/D,MAAM,MAAM,gBAAgB,GACxB,iBAAiB,GACjB,YAAY,kBAAkB,IAAI,iBAAiB,EAAE,CAAC;AAC1D,MAAM,MAAM,iBAAiB,GACzB,aAAa,CAAC,iBAAiB,CAAC,GAChC,aAAa,CAAC,iBAAiB,CAAC,GAChC,SAAS,CAAC;AAEd,wBAAgB,qBAAqB,CACnC,UAAU,EAAE,gBAAgB,GAC3B,iBAAiB,CASnB;AA6bD,8EAA8E;AAC9E,wBAAgB,0BAA0B,CAAC,EAAE,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,IAAI,CAI5E;AAED;;;;GAIG;AACH,wBAAsB,sBAAsB,CAC1C,UAAU,EAAE,gBAAgB,EAC5B,KAAK,EAAE,iBAAiB,GACvB,OAAO,CAAC,aAAa,CAAC,CAyBxB;AAMD,2EAA2E;AAC3E,wBAAgB,gBAAgB,IAAI,IAAI,CAIvC;AAED,wBAAgB,UAAU,IAAI,aAAa,CAoD1C"}
|
|
@@ -48,6 +48,30 @@ export declare function buildPathNeedles(filePath: string): string[];
|
|
|
48
48
|
* satisfy verification for every sibling package that owns an `auth.ts`.
|
|
49
49
|
*/
|
|
50
50
|
export declare function buildUniquePathNeedles(filePath: string, allPaths: readonly string[]): string[];
|
|
51
|
+
export interface PathNeedleOwnershipIndex {
|
|
52
|
+
readonly counts: ReadonlyMap<string, number>;
|
|
53
|
+
readonly normalizedPaths: readonly string[];
|
|
54
|
+
readonly hasUnindexedSuffixes: boolean;
|
|
55
|
+
}
|
|
56
|
+
/** Count owners for every slash-boundary suffix once per supplied path. */
|
|
57
|
+
export declare function buildPathNeedleOwnershipIndex(allPaths: readonly string[]): PathNeedleOwnershipIndex;
|
|
58
|
+
/** Hot-loop variant that reuses suffix ownership counts across many files. */
|
|
59
|
+
export declare function buildUniquePathNeedlesFromIndex(filePath: string, owners: PathNeedleOwnershipIndex): string[];
|
|
60
|
+
export interface KnownPathReferenceIndex {
|
|
61
|
+
/** Full paths and every slash-boundary suffix. */
|
|
62
|
+
readonly segmentSuffixes: ReadonlySet<string>;
|
|
63
|
+
/** Sorted view used for prefix lookups of complete parent paths. */
|
|
64
|
+
readonly sortedSegmentSuffixes: readonly string[];
|
|
65
|
+
/** Suffixes beginning after a character the coarse file regex cannot consume. */
|
|
66
|
+
readonly boundarySuffixes: ReadonlySet<string>;
|
|
67
|
+
/** Normalized source paths retained for exact fallback on oversized suffixes. */
|
|
68
|
+
readonly normalizedPaths: readonly string[];
|
|
69
|
+
readonly hasUnindexedSuffixes: boolean;
|
|
70
|
+
}
|
|
71
|
+
/** Precompute every lookup shape accepted by `isKnownPathReference`. */
|
|
72
|
+
export declare function buildKnownPathReferenceIndex(knownPaths: readonly string[]): KnownPathReferenceIndex;
|
|
73
|
+
/** Indexed variant for hot loops that check many references against one path set. */
|
|
74
|
+
export declare function isKnownPathReferenceInIndex(ref: string, index: KnownPathReferenceIndex): boolean;
|
|
51
75
|
/** Whether an extracted file reference can refer to at least one known path. */
|
|
52
76
|
export declare function isKnownPathReference(ref: string, knownPaths: readonly string[]): boolean;
|
|
53
77
|
//# sourceMappingURL=file-needles.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"file-needles.d.ts","sourceRoot":"","sources":["../../src/utils/file-needles.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AAEH;;;;;;;GAOG;AACH,eAAO,MAAM,iBAAiB,EAAE,WAAW,CAAC,MAAM,CAahD,CAAC;AAEH,6EAA6E;AAC7E,eAAO,MAAM,qBAAqB,IAAI,CAAC;AAEvC;;;;;GAKG;AACH,wBAAgB,aAAa,CAAC,QAAQ,EAAE,MAAM,GAAG,MAAM,CAEtD;AAED,wBAAgB,gBAAgB,CAAC,QAA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UV;AAED,MAAM,WAAW,uBAAuB;IACvC,kDAAkD;IAClD,QAAQ,CAAC,eAAe,EAAE,WAAW,CAAC,MAAM,CAAC,CAAC;IAC9C,oEAAoE;IACpE,QAAQ,CAAC,qBAAqB,EAAE,SAAS,MAAM,EAAE,CAAC;IAClD,iFAAiF;IACjF,QAAQ,CAAC,gBAAgB,EAAE,WAAW,CAAC,MAAM,CAAC,CAAC;IAC/C,iFAAiF;IACjF,QAAQ,CAAC,eAAe,EAAE,SAAS,MAAM,EAAE,CAAC;IAC5C,QAAQ,CAAC,oBAAoB,EAAE,OAAO,CAAC;CACvC;AAID,wEAAwE;AACxE,wBAAgB,4BAA4B,CAC3C,UAAU,EAAE,SAAS,MAAM,EAAE,GAC3B,uBAAuB,CAwCzB;AAqCD,qFAAqF;AACrF,wBAAgB,2BAA2B,CAC1C,GAAG,EAAE,MAAM,EACX,KAAK,EAAE,uBAAuB,GAC5B,OAAO,CAgBT;AAED,gFAAgF;AAChF,wBAAgB,oBAAoB,CACnC,GAAG,EAAE,MAAM,EACX,UAAU,EAAE,SAAS,MAAM,EAAE,GAC3B,OAAO,CAOT"}
|
|
@@ -30,7 +30,12 @@ export declare const CODE_EXT_RE: RegExp;
|
|
|
30
30
|
* survive the file-ref filter.
|
|
31
31
|
*/
|
|
32
32
|
export declare const VERSION_RE: RegExp;
|
|
33
|
-
/**
|
|
33
|
+
/**
|
|
34
|
+
* Coarse-grained `word.ext` matcher retained as the public candidate grammar.
|
|
35
|
+
* `extractFileRefs` implements the same match semantics with a linear scanner:
|
|
36
|
+
* running this greedy expression directly has quadratic backtracking on long
|
|
37
|
+
* dotless tokens.
|
|
38
|
+
*/
|
|
34
39
|
export declare const FILE_REF_CANDIDATE_RE: RegExp;
|
|
35
40
|
/**
|
|
36
41
|
* Decide whether a candidate token (already produced by
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"file-ref-detect.d.ts","sourceRoot":"","sources":["../../src/utils/file-ref-detect.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAEH;;;;GAIG;AACH,eAAO,MAAM,WAAW,QACoI,CAAC;AAE7J;;;;GAIG;AACH,eAAO,MAAM,UAAU,QAAuC,CAAC;AAE/D
|
|
1
|
+
{"version":3,"file":"file-ref-detect.d.ts","sourceRoot":"","sources":["../../src/utils/file-ref-detect.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAEH;;;;GAIG;AACH,eAAO,MAAM,WAAW,QACoI,CAAC;AAE7J;;;;GAIG;AACH,eAAO,MAAM,UAAU,QAAuC,CAAC;AAE/D;;;;;GAKG;AACH,eAAO,MAAM,qBAAqB,QAAsB,CAAC;AAezD;;;;;;GAMG;AACH,wBAAgB,eAAe,CAAC,SAAS,EAAE,MAAM,GAAG,OAAO,CAa1D;AAED;;;;;GAKG;AACH,wBAAgB,eAAe,CAAC,OAAO,EAAE,MAAM,GAAG,MAAM,EAAE,CAuCzD"}
|
package/dist/utils/helpers.d.ts
CHANGED
|
@@ -48,6 +48,7 @@ export declare function buildExtractionContext(extraction: StructuredExtraction,
|
|
|
48
48
|
* Mirrors pi-toolkit's context hook logic for consistent tier decisions.
|
|
49
49
|
*/
|
|
50
50
|
export declare function computeToolCharPercentage(branchEntries: readonly unknown[]): number;
|
|
51
|
+
/** Admission result plus context-pressure label; modes own execution depth. */
|
|
51
52
|
export type CompactionTier = "none" | "light" | "full";
|
|
52
53
|
export declare function selectCompactionTier(contextPercent: number, totalTokens: number, minThreshold: number, minContextPercent?: number): CompactionTier;
|
|
53
54
|
export declare function inferSessionType(extraction: StructuredExtraction, report: ExplorationReport | null): SessionType;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"helpers.d.ts","sourceRoot":"","sources":["../../src/utils/helpers.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,KAAK,EACV,YAAY,EACZ,iBAAiB,EACjB,QAAQ,EACR,mBAAmB,EACnB,WAAW,EACX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QAAQ,CAAC,EAAE;IAAE,KAAK,EAAE,MAAM,CAAC;IAAC,GAAG,EAAE,MAAM,CAAA;CAAE,GACxC,MAAM,CA+DR;AA4BD;;;GAGG;AACH,wBAAgB,yBAAyB,CACvC,aAAa,EAAE,SAAS,OAAO,EAAE,GAChC,MAAM,CAqBR;AAED,+EAA+E;AAC/E,MAAM,MAAM,cAAc,GAAG,MAAM,GAAG,OAAO,GAAG,MAAM,CAAC;AAEvD,wBAAgB,oBAAoB,CAClC,cAAc,EAAE,MAAM,EACtB,WAAW,EAAE,MAAM,EACnB,YAAY,EAAE,MAAM,EACpB,iBAAiB,GAAE,MAAW,GAC7B,cAAc,CAMhB;AAED,wBAAgB,gBAAgB,CAC9B,UAAU,EAAE,oBAAoB,EAChC,MAAM,EAAE,iBAAiB,GAAG,IAAI,GAC/B,WAAW,CAiBb;AAED,wBAAgB,uBAAuB,CAAC,MAAM,EAAE,iBAAiB,GAAG,MAAM,CA6BzE"}
|
package/package.json
CHANGED
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "pi-smart-compact",
|
|
3
|
-
"version": "9.
|
|
3
|
+
"version": "9.6.1",
|
|
4
4
|
"description": "Verification-oriented smart compaction extension for Pi Coding Agent — deterministic extraction, exploration, synthesis, verification, metrics, and safety checks.",
|
|
5
|
-
"
|
|
5
|
+
"type": "module",
|
|
6
|
+
"packageManager": "bun@1.4.0",
|
|
6
7
|
"engines": {
|
|
7
8
|
"node": ">=22.19.0"
|
|
8
9
|
},
|
|
@@ -75,7 +76,8 @@
|
|
|
75
76
|
"typebox": "*"
|
|
76
77
|
},
|
|
77
78
|
"devDependencies": {
|
|
78
|
-
"@
|
|
79
|
+
"@earendil-works/pi-server": "*",
|
|
80
|
+
"@types/bun": "1.4.0",
|
|
79
81
|
"@types/node": "^26.3.0",
|
|
80
82
|
"typescript": "^7.0.2"
|
|
81
83
|
},
|