feat(pi-condense): vendor source and add summarizer retries

This commit is contained in:
云服务部-叶林立
2026-08-31 15:13:41 +08:00
parent 8002d7c213
commit e80959cc3f
94 changed files with 21327 additions and 185 deletions
+23
View File
@@ -0,0 +1,23 @@
# Upstream source
- Official repository: <https://github.com/jjuraszek/pi-condense>
- Imported tag: `v2.9.1`
- Imported commit: `59c95110aacd8131db71e21296765dd80b72fae8`
- Upstream package version: `2.9.1`
- Imported on: 2026-08-31
The snapshot was cloned from the official Git repository at the tag above. It was not imported from an npm tarball, npm cache, `node_modules`, or a compiled distribution.
## Import filtering
The maintained snapshot keeps the extension source, tests, documentation, changelog, package metadata, image, and MIT license. Upstream repository-local automation and agent state (`.git/`, `.github/`, `.agents/`, `.pi/`, and upstream `AGENTS*.md`) are intentionally excluded. No `node_modules`, coverage, or build artifacts are retained.
The upstream package's host-only `devDependencies` and agent-core check script are omitted from the maintained package metadata. The same packages remain peer dependencies supplied by Pi; omitting the development copies prevents a local `file:` dependency from installing a second Pi runtime into the root bundle.
## Local maintenance changes
- The root bundle depends on this directory through `file:./pi-condense` and loads `pi-condense/index.ts` directly.
- The former bundle wrapper that wrote missing `contextPrune` settings into the user's `settings.json` was removed. Its defaults now live in `pi-condense/src/types.ts`; explicit user settings still take precedence through upstream normalization.
- Transient summarizer failures support configurable bounded retries with exponential backoff. The maintained defaults are two retries, a 1-second base delay, and an 8-second per-wait cap. With a distinct configured summarizer model, the final retry slot is reserved for the existing session-model fallback.
Upstream remains the reference source. Future synchronization must compare these local changes before porting a tagged upstream release; do not overwrite the maintained defaults or retry behavior wholesale.