@agimon-ai/doompi-cache 0.0.1-alpha.6 → 0.0.1-alpha.7

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.
Files changed (2) hide show
  1. package/README.md +29 -12
  2. package/package.json +4 -4
package/README.md CHANGED
@@ -1,35 +1,50 @@
1
1
  # @agimon-ai/doompi-cache
2
2
 
3
- Provider prompt cache policy and deterministic routing for DoomPi
3
+ Provider prompt-cache policy and deterministic routing for DoomPi.
4
4
 
5
- This package is a composable [DoomPi](https://www.npmjs.com/package/@agimon-ai/doompi) subsystem. Use it with the distribution or install it independently in [Pi](https://www.npmjs.com/package/@earendil-works/pi-coding-agent).
5
+ DoomPi loads this package as fixed core. It derives stable provider cache keys from the active
6
+ session composition and applies them only to supported provider requests. The package can also run
7
+ as a standalone [Pi](https://www.npmjs.com/package/@earendil-works/pi-coding-agent) extension.
8
+
9
+ > **Alpha:** cache routing and provider integration may change between releases.
6
10
 
7
11
  ## Requirements
8
12
 
9
13
  - Node.js 22.19.0 or newer
10
- - `@earendil-works/pi-coding-agent` 0.84.3
14
+ - Pi 0.84.3 for standalone extension use
11
15
 
12
16
  ## Install
13
17
 
18
+ A DoomPi installation already includes this package. Do not add it to `.doom/modes.yaml`.
19
+
20
+ To load it directly in Pi:
21
+
14
22
  ```bash
15
23
  pi install npm:@agimon-ai/doompi-cache
16
24
  ```
17
25
 
18
- The package declares its Pi extension entry, so Pi loads it after installation. DoomPi users can include the package through their normal profile and domain composition instead.
26
+ Pi reads the extension entry from `package.json.pi.extensions` and loads it after installation.
19
27
 
20
28
  ## Package behavior
21
29
 
22
- DoomPi derives an opaque provider cache key from stable model-visible state, including the composition fingerprint, ordered domains, profile, persona, active minor modes, effective model, and child prompt projection. Returning to equivalent state restores the same key, but provider expiry or eviction can still make that namespace cold.
30
+ DoomPi derives an opaque provider cache key from stable model-visible state: the composition
31
+ fingerprint, ordered domains, profile, persona, active minor modes, effective model, and child prompt
32
+ projection. Returning to equivalent state restores the same key. Provider expiry or eviction can
33
+ still make the cache cold.
23
34
 
24
- The Pi extension rewrites only a nonblank cache key already emitted for an allowlisted OpenAI-family wire API. It preserves supported retention and provider cache markers, avoids adding unsupported fields to proxies, and reports only provider-observed token usage. Telemetry always reports current provider residency as `unknown`.
35
+ The Pi extension rewrites only a nonblank cache key already emitted for an allowlisted OpenAI-family
36
+ wire API. It preserves supported retention and provider cache markers, does not add unsupported
37
+ fields to proxies, and reports only provider-observed token usage. Telemetry reports current
38
+ provider residency as `unknown`.
25
39
 
26
40
  ## Help
27
41
 
28
- The published package includes `llms.txt` and the package-owned `src/prompts/doompi-use-cache/SKILL.md`. When the DoomPi Help minor mode is active, the extension contributes `doompi-use-cache` to its live Help catalog. The contribution follows Help provider replacement and is withdrawn when the extension shuts down.
29
-
30
- Help remains optional. Loading the standalone Pi extension does not require DoomPi Help or any other DoomPi runtime service.
42
+ The published package includes `llms.txt` and `src/prompts/doompi-use-cache/SKILL.md`. While DoomPi
43
+ Help is active, the extension adds `doompi-use-cache` to the live Help catalog. The contribution
44
+ follows Help provider replacement and is removed when the extension shuts down.
31
45
 
32
- To add another package-owned Help prompt, use the `scaffold-doom-prompt` feature with a `doompi-author-*` or `doompi-use-*` name and a concise description. Then link the generated `SKILL.md` from `llms.txt` and register a matching descriptor through the optional `DOOM_HELP_SERVICE` injection in the Pi adapter. Keep prompts as published resources under `src/prompts`; do not export them or copy them into `dist`.
46
+ Help is optional. The standalone Pi extension does not require DoomPi Help or another DoomPi runtime
47
+ service.
33
48
 
34
49
  ## Public API
35
50
 
@@ -46,7 +61,8 @@ import {
46
61
  } from '@agimon-ai/doompi-cache/env';
47
62
  ```
48
63
 
49
- The Pi host entry is available at `@agimon-ai/doompi-cache/extensions/pi`. The root API has no import-time extension side effects.
64
+ The Pi host entry is `@agimon-ai/doompi-cache/extensions/pi`. Importing the root API does not install
65
+ the extension.
50
66
 
51
67
  ## Development
52
68
 
@@ -59,7 +75,8 @@ pnpm exec vibe-lint check .
59
75
  npm pack --dry-run
60
76
  ```
61
77
 
62
- The official OpenAI canary is opt-in and reports provider `cached_tokens` without treating a cold result as a deterministic failure:
78
+ The live OpenAI canary is opt-in. It reports provider `cached_tokens`; a cold result does not fail
79
+ the test deterministically:
63
80
 
64
81
  ```bash
65
82
  DOOMPI_CACHE_LIVE_OPENAI=1 \
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@agimon-ai/doompi-cache",
3
- "version": "0.0.1-alpha.6",
3
+ "version": "0.0.1-alpha.7",
4
4
  "description": "Provider prompt cache policy and deterministic routing for DoomPi",
5
5
  "keywords": [
6
6
  "ai",
@@ -60,8 +60,8 @@
60
60
  "dependencies": {
61
61
  "@deepseek-ai/cordis": "4.0.1",
62
62
  "pi-cache-optimizer": "2.8.3",
63
- "@agimon-ai/doompi-config": "0.0.1-alpha.39",
64
- "@agimon-ai/doompi-extension-contracts": "0.0.1-alpha.39"
63
+ "@agimon-ai/doompi-config": "0.0.1-alpha.40",
64
+ "@agimon-ai/doompi-extension-contracts": "0.0.1-alpha.40"
65
65
  },
66
66
  "devDependencies": {
67
67
  "@earendil-works/pi-coding-agent": "0.84.3",
@@ -70,7 +70,7 @@
70
70
  "tsdown": "0.22.14",
71
71
  "typescript": "7.0.2",
72
72
  "vitest": "4.1.11",
73
- "@agimon-ai/vibe-lint-plugin-doom-extension": "0.0.1-alpha.37"
73
+ "@agimon-ai/vibe-lint-plugin-doom-extension": "0.0.1-alpha.38"
74
74
  },
75
75
  "peerDependencies": {
76
76
  "@earendil-works/pi-coding-agent": "0.84.3"