pi-condense 2.11.4 → 2.11.5
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/CHANGELOG.md +6 -0
- package/PRUNING.md +3 -3
- package/package.json +1 -1
- package/src/commands.ts +1 -1
- package/src/types.ts +3 -3
package/CHANGELOG.md
CHANGED
|
@@ -7,6 +7,12 @@ Published to npm as [`pi-condense`](https://www.npmjs.com/package/pi-condense) (
|
|
|
7
7
|
Pushing a `vX.Y.Z` tag triggers `.github/workflows/release.yml`, which runs the tests and
|
|
8
8
|
publishes via OIDC trusted publishing. See `.agents/skills/release/SKILL.md`.
|
|
9
9
|
|
|
10
|
+
## [2.11.5] - 2026-10-08
|
|
11
|
+
|
|
12
|
+
### Changed
|
|
13
|
+
|
|
14
|
+
- `minBatchChars` defaults to 2000 (was 1000): batches under 2,000 raw chars compress to only about 44% of their size when summarized, so they now stay verbatim and skip the summarizer call. Set `contextPrune.minBatchChars` explicitly to keep the old threshold.
|
|
15
|
+
|
|
10
16
|
## [2.11.4] - 2026-10-08
|
|
11
17
|
|
|
12
18
|
### Fixed
|
package/PRUNING.md
CHANGED
|
@@ -600,7 +600,7 @@ captured batches (from turn_end or session scan)
|
|
|
600
600
|
│ identical (toolName, normalize(resultText)) → alias of original;
|
|
601
601
|
│ no LLM call; persist as context-prune-dedup-alias
|
|
602
602
|
│
|
|
603
|
-
├─ 5. Trivial-batch skip (config: minBatchChars, default
|
|
603
|
+
├─ 5. Trivial-batch skip (config: minBatchChars, default 2000)
|
|
604
604
|
│ batches whose remaining raw chars < threshold → skip; no LLM call;
|
|
605
605
|
│ leave originals in context; advance frontier
|
|
606
606
|
│
|
|
@@ -677,11 +677,11 @@ Why a window and not the whole result: summarizer input is paid on every flush,
|
|
|
677
677
|
|
|
678
678
|
### Trivial-batch skip (minBatchChars)
|
|
679
679
|
|
|
680
|
-
`minBatchChars: number` (default `
|
|
680
|
+
`minBatchChars: number` (default `2000`) is a pre-flush guard against "summary would be roughly the same size as the input" cases. If the total raw `resultText` across a batch is below the threshold, the batch is skipped: no summarizer LLM call, no `context-prune-index` entry, no `context-prune-summary` injection. The frontier still advances, so the same tool calls are not reconsidered next flush.
|
|
681
681
|
|
|
682
682
|
Why it exists: a short LLM summary like "Tool X did Y" is itself ~50–150 chars per call. For a 200-byte file read or an `ls` of a short directory, the summary is the same size or larger than the input — the post-call `skipped-oversized` mechanism would catch it anyway, but only after the LLM round-trip and the cost. `minBatchChars` short-circuits the obvious cases at zero LLM cost.
|
|
683
683
|
|
|
684
|
-
Set `minBatchChars: 0` to disable. The default `
|
|
684
|
+
Set `minBatchChars: 0` to disable. The default `2000` skips obvious trivial batches (`git status`, small file reads, short directory listings) without affecting realistic tool outputs; batches under 2,000 chars compress to only about 44% of their size when summarized (the per-call bullet scaffolding dominates), against about 7% for a typical session, so summarizing them costs an LLM call for little context saved. Edit with `/pruner min-batch-chars <n>` or via the settings overlay.
|
|
685
685
|
|
|
686
686
|
### Content-hash dedup
|
|
687
687
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "pi-condense",
|
|
3
|
-
"version": "2.11.
|
|
3
|
+
"version": "2.11.5",
|
|
4
4
|
"description": "Pi coding-agent extension that summarizes completed tool-call batches, replaces raw outputs with short stubs, compresses closed tool-call chains, and recovers any original on demand via context_tree_query.",
|
|
5
5
|
"author": "Jacek Juraszek",
|
|
6
6
|
"license": "MIT",
|
package/src/commands.ts
CHANGED
|
@@ -591,7 +591,7 @@ export function registerCommands(
|
|
|
591
591
|
values: MIN_BATCH_CHARS_PRESETS.map((p) => p.value),
|
|
592
592
|
currentValue: MIN_BATCH_CHARS_PRESETS.some((p) => p.value === String(config.minBatchChars))
|
|
593
593
|
? String(config.minBatchChars)
|
|
594
|
-
: MIN_BATCH_CHARS_PRESETS[
|
|
594
|
+
: MIN_BATCH_CHARS_PRESETS[3].value, // fall back to "2000" if a custom value isn't in the preset cycle
|
|
595
595
|
description: minBatchCharsDescription(config),
|
|
596
596
|
},
|
|
597
597
|
{
|
package/src/types.ts
CHANGED
|
@@ -194,8 +194,8 @@ export const ROLLING_WINDOW_PRESETS: { value: string; label: string }[] = [
|
|
|
194
194
|
export const MIN_BATCH_CHARS_PRESETS: { value: string; label: string }[] = [
|
|
195
195
|
{ value: "0", label: "0 (disabled)" },
|
|
196
196
|
{ value: "500", label: "500" },
|
|
197
|
-
{ value: "1000", label: "1000
|
|
198
|
-
{ value: "2000", label: "2000" },
|
|
197
|
+
{ value: "1000", label: "1000" },
|
|
198
|
+
{ value: "2000", label: "2000 (default)" },
|
|
199
199
|
{ value: "5000", label: "5000" },
|
|
200
200
|
];
|
|
201
201
|
|
|
@@ -567,7 +567,7 @@ export const DEFAULT_CONFIG: ContextPruneConfig = {
|
|
|
567
567
|
pruneOn: "agent-message",
|
|
568
568
|
batchingMode: "turn",
|
|
569
569
|
quietOversizedSkips: false,
|
|
570
|
-
minBatchChars:
|
|
570
|
+
minBatchChars: 2000,
|
|
571
571
|
recoveryGraceTurns: 3,
|
|
572
572
|
summarizerIdleTimeoutMs: 20000,
|
|
573
573
|
summarizerMaxTimeoutMs: 180000,
|