pi-goosedump 0.12.56 → 0.12.58

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/README.md CHANGED
@@ -57,4 +57,5 @@ npm run check
57
57
 
58
58
  ## Licensing
59
59
 
60
- [Apache 2.0](LICENSE).
60
+ `pi-goosedump` is licensed under the Apache 2.0 license. See [LICENSE](LICENSE)
61
+ for more information.
package/dist/index.ts CHANGED
@@ -139,6 +139,11 @@ var DEFAULT_GOOSEDUMP_SETTINGS = {
139
139
  summaryMaxTokens: 4096,
140
140
  enableMemory: false
141
141
  };
142
+ var GOOSEDUMP_SETTING_LABELS = {
143
+ turnsBeforeCompact: "Turns before compact",
144
+ summaryMaxTokens: "Summary max tokens",
145
+ enableMemory: "Enable memory"
146
+ };
142
147
  var GOOSEDUMP_SESSION_SCHEMA = Type.Object({
143
148
  id: Type.String(),
144
149
  parent: Type.Union([Type.String(), Type.Null()]),
@@ -410,7 +415,7 @@ function resolveNativePackageTable() {
410
415
  break;
411
416
  dir = parent;
412
417
  }
413
- throw new Error("broken pi-goosedump installation: cannot resolve the native package table from @jarkkojs/goosedump");
418
+ throw new Error("broken pi-goosedump installation: cannot resolve the native package table from @jarkkojs/goosedump-api");
414
419
  }
415
420
  function loadNativeGoosedumpPackages() {
416
421
  const table = JSON.parse(readFileSync2(resolveNativePackageTable(), "utf8"));
@@ -433,9 +438,9 @@ function nativeGoosedumpPackage(target) {
433
438
  }
434
439
  function resolveGoosedumpBinary() {
435
440
  try {
436
- return require2.resolve("@jarkkojs/goosedump/bin/goosedump.js");
441
+ return require2.resolve("@jarkkojs/goosedump-api/bin/goosedump.js");
437
442
  } catch (cause) {
438
- throw new Error("broken pi-goosedump installation: cannot resolve the @jarkkojs/goosedump dependency", { cause });
443
+ throw new Error("broken pi-goosedump installation: cannot resolve the @jarkkojs/goosedump-api dependency", { cause });
439
444
  }
440
445
  }
441
446
  var GOOSEDUMP_BINARY_ENV = "GOOSEDUMP_BINARY";
@@ -2178,7 +2183,7 @@ async function runSettingsEditor(ctx) {
2178
2183
  let globalSettings = { ...DEFAULT_GOOSEDUMP_SETTINGS };
2179
2184
  let projectSettings = {};
2180
2185
  function settingLabel(key) {
2181
- return `Project ${key}`;
2186
+ return GOOSEDUMP_SETTING_LABELS[key];
2182
2187
  }
2183
2188
  function reloadSettings() {
2184
2189
  globalSettings = readScopedGoosedumpSettings(location, "global");
@@ -2275,6 +2280,7 @@ async function runSettingsEditor(ctx) {
2275
2280
  const descriptionWidth = Math.max(1, innerW - shortcutWidth - 4);
2276
2281
  content.push(dim(` ${pad("Shortcut", shortcutWidth)} Description`), ...helpRows.map(([shortcut, description]) => ` ${accent(pad(shortcut, shortcutWidth))} ${text(truncateToWidth(description, descriptionWidth))}`));
2277
2282
  } else {
2283
+ const labelWidth = Math.max(...specs.map(({ key }) => visibleWidth(settingLabel(key))));
2278
2284
  for (const [index, entry] of specs.entries()) {
2279
2285
  const selected = index === selectedSetting;
2280
2286
  const inherited = projectSettings[entry.key] === undefined;
@@ -2282,10 +2288,8 @@ async function runSettingsEditor(ctx) {
2282
2288
  const valueText = `[ ${formatSettingDisplayValue(entry.key, value)} ]`;
2283
2289
  const renderedValue = inherited ? dim(valueText) : selected ? accent(valueText) : text(valueText);
2284
2290
  const cursor = selected ? accent("›") : " ";
2285
- content.push(`${cursor} ${renderedValue} ${text(entry.key)}`);
2291
+ content.push(`${cursor} ${text(pad(settingLabel(entry.key), labelWidth))} ${renderedValue}`);
2286
2292
  }
2287
- const effective = resolveGoosedumpSettings(location, projectTrusted);
2288
- content.push("", dim(`Effective: turns=${formatCompactSetting(effective.turnsBeforeCompact)} · summary=${effectiveSummaryMaxTokens(location, projectTrusted)} tokens · memory=${effective.enableMemory ? "on" : "off"}`));
2289
2293
  }
2290
2294
  return [
2291
2295
  overlayHeader(colors, width, "Goosedump Settings"),
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "pi-goosedump",
3
- "version": "0.12.56",
3
+ "version": "0.12.58",
4
4
  "description": "Pi extension for goosedump session search, durable memory, session management, and compaction",
5
5
  "keywords": [
6
6
  "compaction",
@@ -37,7 +37,7 @@
37
37
  "ci:test": "npm test"
38
38
  },
39
39
  "dependencies": {
40
- "@jarkkojs/goosedump": "^0.12.56"
40
+ "@jarkkojs/goosedump-api": "^0.12.58"
41
41
  },
42
42
  "devDependencies": {
43
43
  "@earendil-works/pi-coding-agent": "^0.84.2",