@agimon-ai/doompi-autocompact 0.0.1-alpha.21 → 0.0.1-alpha.23
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 +45 -21
- package/package.json +12 -10
package/README.md
CHANGED
|
@@ -1,40 +1,64 @@
|
|
|
1
1
|
# @agimon-ai/doompi-autocompact
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
Staged checkpoint summarization and iterative context compaction for DoomPi.
|
|
4
4
|
|
|
5
|
-
|
|
6
|
-
session. Doompi checkpoints the work before that cliff, then carries the live plan, task
|
|
7
|
-
graph, and team state beside the prose instead of asking a later model to reconstruct them.
|
|
5
|
+
Part of the [DoomPi distribution](https://www.npmjs.com/package/@agimon-ai/doompi).
|
|
8
6
|
|
|
9
|
-
|
|
7
|
+
Instead of waiting for one final summary near the context limit, Autocompact creates up to three asynchronous checkpoints and combines each checkpoint with subsequent messages.
|
|
10
8
|
|
|
11
|
-
|
|
12
|
-
2. Combine that checkpoint with later messages; let the model decide whether it is ready
|
|
13
|
-
to compact.
|
|
14
|
-
3. Combine the next checkpoint with later messages and force compaction.
|
|
9
|
+
> **Alpha:** thresholds and compaction steering may change between releases.
|
|
15
10
|
|
|
16
|
-
|
|
11
|
+
## Requirements
|
|
17
12
|
|
|
18
|
-
|
|
19
|
-
|
|
13
|
+
- Node.js 22.19.0 or newer
|
|
14
|
+
- Pi 0.84.2
|
|
15
|
+
- Authentication for the active Pi model used to summarize
|
|
20
16
|
|
|
21
17
|
## Install
|
|
22
18
|
|
|
19
|
+
DoomPi loads Autocompact as core. For direct Pi installation:
|
|
20
|
+
|
|
23
21
|
```bash
|
|
24
|
-
|
|
22
|
+
pi install npm:@agimon-ai/doompi-autocompact
|
|
23
|
+
```
|
|
24
|
+
|
|
25
|
+
The extension entry is `@agimon-ai/doompi-autocompact/extensions/pi`.
|
|
26
|
+
|
|
27
|
+
## Checkpoint ladder
|
|
28
|
+
|
|
29
|
+
The standard adapter uses thresholds around 50%, 75%, and 95% of the usable context window, subject to token caps and Pi's native-compaction clamp:
|
|
30
|
+
|
|
31
|
+
1. create an initial compact summary;
|
|
32
|
+
2. combine it with later messages and allow the model to decide whether compaction is ready;
|
|
33
|
+
3. combine again and force compaction on the final pass.
|
|
34
|
+
|
|
35
|
+
Summarization runs in a worker thread so the foreground session can continue. Checkpoints are persisted as hidden session entries and used for later steering.
|
|
36
|
+
|
|
37
|
+
The standard adapter uses the active Pi model. Each checkpoint can therefore make another provider request, consume quota, and require the corresponding API credentials. Provider errors or missing authentication affect checkpoint generation rather than granting a free local summary.
|
|
38
|
+
|
|
39
|
+
## Coordination state
|
|
40
|
+
|
|
41
|
+
Autocompact does not own Task or Team persistence. In the standard adapter, Task and Team snapshot fields supplied to summarization are empty. Task's `tasks.json` and Team's run/intercom state continue to be owned by those packages and must not be inferred from an Autocompact summary.
|
|
42
|
+
|
|
43
|
+
## Public API
|
|
44
|
+
|
|
45
|
+
```ts
|
|
46
|
+
import { registerAutocompactExtension, thresholdTokens } from '@agimon-ai/doompi-autocompact';
|
|
47
|
+
import type { AutocompactPass } from '@agimon-ai/doompi-autocompact';
|
|
25
48
|
```
|
|
26
49
|
|
|
27
|
-
|
|
50
|
+
`thresholdTokens` exposes the threshold policy for hosts that need to preview or test checkpoint boundaries.
|
|
28
51
|
|
|
29
|
-
|
|
30
|
-
`.doom/modes.yaml`. The bare package name follows its Pi manifest and loads the Pi adapter.
|
|
52
|
+
## Development
|
|
31
53
|
|
|
32
|
-
|
|
54
|
+
```bash
|
|
55
|
+
pnpm build
|
|
56
|
+
pnpm typecheck
|
|
57
|
+
pnpm test
|
|
58
|
+
pnpm lint
|
|
59
|
+
```
|
|
33
60
|
|
|
34
|
-
|
|
35
|
-
| --------------------------------------------- | ------------------------ |
|
|
36
|
-
| `@agimon-ai/doompi-autocompact` | Library API |
|
|
37
|
-
| `@agimon-ai/doompi-autocompact/extensions/pi` | Pi extension entry point |
|
|
61
|
+
Maintained by [Agimon](https://agimon.ai/about).
|
|
38
62
|
|
|
39
63
|
## License
|
|
40
64
|
|
package/package.json
CHANGED
|
@@ -1,13 +1,15 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@agimon-ai/doompi-autocompact",
|
|
3
|
-
"version": "0.0.1-alpha.
|
|
4
|
-
"description": "
|
|
3
|
+
"version": "0.0.1-alpha.23",
|
|
4
|
+
"description": "Iterative context compaction and checkpoint summaries for Pi and DoomPi agent sessions.",
|
|
5
5
|
"keywords": [
|
|
6
|
-
"ai",
|
|
7
6
|
"coding-agent",
|
|
8
|
-
"
|
|
7
|
+
"context-compaction",
|
|
8
|
+
"context-window",
|
|
9
9
|
"doompi",
|
|
10
|
-
"pi-
|
|
10
|
+
"pi-coding-agent",
|
|
11
|
+
"pi-extension",
|
|
12
|
+
"summarization"
|
|
11
13
|
],
|
|
12
14
|
"homepage": "https://agimon.ai",
|
|
13
15
|
"license": "MIT",
|
|
@@ -27,11 +29,11 @@
|
|
|
27
29
|
"access": "public"
|
|
28
30
|
},
|
|
29
31
|
"dependencies": {
|
|
30
|
-
"@agimon-ai/doompi-
|
|
31
|
-
"@agimon-ai/doompi-
|
|
32
|
-
"@agimon-ai/doompi-
|
|
33
|
-
"@agimon-ai/doompi-task": "0.0.1-alpha.
|
|
34
|
-
"@agimon-ai/doompi-
|
|
32
|
+
"@agimon-ai/doompi-ui": "0.0.1-alpha.23",
|
|
33
|
+
"@agimon-ai/doompi-config": "0.0.1-alpha.23",
|
|
34
|
+
"@agimon-ai/doompi-team": "0.0.1-alpha.23",
|
|
35
|
+
"@agimon-ai/doompi-task": "0.0.1-alpha.23",
|
|
36
|
+
"@agimon-ai/doompi-telemetry": "0.0.1-alpha.23"
|
|
35
37
|
},
|
|
36
38
|
"devDependencies": {
|
|
37
39
|
"@earendil-works/pi-coding-agent": "0.84.2",
|