opencode-acp 1.14.15 → 1.14.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/README.md +10 -0
- package/README.zh-CN.md +10 -0
- package/dist/index.js +3 -3
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -492,6 +492,16 @@ For the complete list with root cause analysis, see the [bug tracker](https://gi
|
|
|
492
492
|
|
|
493
493
|
## Changelog
|
|
494
494
|
|
|
495
|
+
### v1.14.16 — Raise context limits to 80%
|
|
496
|
+
|
|
497
|
+
**Problem**: The compression thresholds were `maxContextLimit: 55%` / `minContextLimit: 45%`. The strong "over-limit" nudge fired as soon as context exceeded 55% of the model window. Combined with the fixed 50K growth threshold (v1.14.15), this still engaged compression relatively early, leaving usable context unused.
|
|
498
|
+
|
|
499
|
+
**Fix**: Raise **both** `compress.maxContextLimit` (`"55%"` → `"80%"`) and `compress.minContextLimit` (`"45%"` → `"80%"`) in `lib/config.ts`. Compression now waits until context exceeds 80% before firing the strong "over-limit" nudge. Setting `minContextLimit` equal to `maxContextLimit` removes the legacy 45% early-engagement band entirely — `minContextLimit` only affects the nudge tip *tone* (`tipsVariant`), never whether a nudge fires; the actual nudge decision is `growthSinceLastNudge >= nudgeGrowthTokens || overMaxLimit`, so aligning both at 80% makes behavior uniform and drops the meaningless early tip tone. The `emergencyThresholdPercent: "98%"` backstop is unchanged. Users can override via `compress.maxContextLimit` / `compress.minContextLimit` in their config.
|
|
500
|
+
|
|
501
|
+
Files: `lib/config.ts`. Tests: 976 pass.
|
|
502
|
+
|
|
503
|
+
**Install**: `opencode plugin opencode-acp@latest --global`
|
|
504
|
+
|
|
495
505
|
### v1.14.15 — Pin nudge growth to fixed 50,000 tokens
|
|
496
506
|
|
|
497
507
|
**Problem**: The T2/T3 nudge growth threshold was computed as 5% of the model context window (clamped 20K–50K via `resolveAdaptiveNudgeGrowth` from `context-compress-algorithms`). For sub-1M-context models this produced smaller thresholds (e.g. 10K at 200K, 20K at 400K), causing nudges to fire too eagerly and over-compress.
|
package/README.zh-CN.md
CHANGED
|
@@ -446,6 +446,16 @@ ACP 是 DCP 的直接替代品。迁移步骤:
|
|
|
446
446
|
|
|
447
447
|
## 更新日志
|
|
448
448
|
|
|
449
|
+
### v1.14.16 — 将上下文 limit 提升至 80%
|
|
450
|
+
|
|
451
|
+
**问题**:压缩阈值原为 `maxContextLimit: 55%` / `minContextLimit: 45%`。上下文一旦超过模型窗口的 55% 就会触发强「超限」nudge。配合 v1.14.15 固定的 50K 增长阈值,压缩仍较早介入,可用上下文未被充分利用。
|
|
452
|
+
|
|
453
|
+
**修复**:将 `compress.maxContextLimit`(`"55%"` → `"80%"`)和 `compress.minContextLimit`(`"45%"` → `"80%"`)**同时**提升至 80%(`lib/config.ts`)。压缩现在等到上下文超过 80% 才触发强「超限」nudge。把 `minContextLimit` 设为与 `maxContextLimit` 相同,彻底移除旧的 45% 提前介入区间 —— `minContextLimit` 只影响 nudge 提示语气(`tipsVariant`),不决定是否触发;实际 nudge 判定为 `growthSinceLastNudge >= nudgeGrowthTokens || overMaxLimit`,两者都设 80% 使行为统一,并去掉无意义的早期提示语气。`emergencyThresholdPercent: "98%"` 兜底不变。用户可通过配置中的 `compress.maxContextLimit` / `compress.minContextLimit` 覆盖。
|
|
454
|
+
|
|
455
|
+
文件:`lib/config.ts`。测试:976 通过。
|
|
456
|
+
|
|
457
|
+
**安装**:`opencode plugin opencode-acp@latest --global`
|
|
458
|
+
|
|
449
459
|
### v1.14.15 — 固定 nudge 增长阈值为 50,000 tokens
|
|
450
460
|
|
|
451
461
|
**问题**:T2/T3 nudge 增长阈值按模型上下文窗口的 5% 计算(通过 `context-compress-algorithms` 的 `resolveAdaptiveNudgeGrowth` 钳制在 20K–50K)。对于低于 1M 上下文的模型,这会产生更小的阈值(例如 200K 时为 10K,400K 时为 20K),导致 nudge 触发过于频繁、过度压缩。
|
package/dist/index.js
CHANGED
|
@@ -1484,8 +1484,8 @@ var defaultConfig = {
|
|
|
1484
1484
|
permission: "allow",
|
|
1485
1485
|
showCompression: true,
|
|
1486
1486
|
summaryBuffer: true,
|
|
1487
|
-
maxContextLimit: "
|
|
1488
|
-
minContextLimit: "
|
|
1487
|
+
maxContextLimit: "80%",
|
|
1488
|
+
minContextLimit: "80%",
|
|
1489
1489
|
nudgeFrequency: 5,
|
|
1490
1490
|
minNudgeContextPercent: 15,
|
|
1491
1491
|
iterationNudgeThreshold: 15,
|
|
@@ -8949,7 +8949,7 @@ import { writeFile as writeFile2, mkdir as mkdir2 } from "fs/promises";
|
|
|
8949
8949
|
import { join as join3 } from "path";
|
|
8950
8950
|
import { existsSync as existsSync3 } from "fs";
|
|
8951
8951
|
import { homedir as homedir3 } from "os";
|
|
8952
|
-
var LOG_VERSION = true ? "1.14.
|
|
8952
|
+
var LOG_VERSION = true ? "1.14.16" : "dev";
|
|
8953
8953
|
var Logger = class {
|
|
8954
8954
|
logDir;
|
|
8955
8955
|
enabled;
|