billion-context-pi-lean 0.2.0 → 0.2.1
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 +1 -1
- package/dist/{chunk-PPYOZRUP.js → chunk-EYDKO7YM.js} +2 -2
- package/dist/config-dir.d.ts +4 -29
- package/dist/config.d.ts +0 -33
- package/dist/contract.js +1 -1
- package/dist/index.d.ts +1 -4
- package/dist/index.js +112 -714
- package/dist/index.js.map +1 -1
- package/dist/messages.d.ts +1 -8
- package/dist/reasoning-drop.d.ts +2 -2
- package/dist/runtime.d.ts +6 -36
- package/dist/session-log.d.ts +4 -15
- package/dist/state.d.ts +0 -28
- package/dist/tool-guardrails.d.ts +0 -4
- package/dist/turn-boundary.d.ts +10 -39
- package/dist/user-config.d.ts +1 -2
- package/lean/index.ts +1 -1
- package/package.json +1 -1
- package/dist/compat.d.ts +0 -23
- package/dist/host.d.ts +0 -15
- package/dist/omp.d.ts +0 -19
- package/dist/sequence-match.d.ts +0 -7
- /package/dist/{chunk-PPYOZRUP.js.map → chunk-EYDKO7YM.js.map} +0 -0
package/README.md
CHANGED
|
@@ -59,7 +59,7 @@ With only this extension enabled, its recurring model-facing initialization cont
|
|
|
59
59
|
|
|
60
60
|
| Variant | Tool and prompt contribution | Total |
|
|
61
61
|
| --- | --- | ---: |
|
|
62
|
-
| Lean `billion-context-pi-lean@0.2.
|
|
62
|
+
| Lean `billion-context-pi-lean@0.2.1` | `compress` (231) + `acp_context` (87) + prompt (168) | **486** |
|
|
63
63
|
| Upstream `billion-context-pi@0.1.83` with `promptPack: "lean"` | `compress` (389) + `decompress` (271) + `search_context` (90) + `acp_status` (227) + `acp_cache` (204) + `acp_delegate` (1,452) + `acp_delegate_wait` (342) + `acp_delegate_cancel` (83) + prompt (1,819) | **4,877** |
|
|
64
64
|
| Upstream `billion-context-pi@0.1.83` | `compress` (549) + `decompress` (546) + `search_context` (210) + `acp_status` (339) + `acp_cache` (204) + `acp_delegate` (1,452) + `acp_delegate_wait` (342) + `acp_delegate_cancel` (83) + prompt (4,945) | **8,670** |
|
|
65
65
|
|
|
@@ -7,7 +7,7 @@ var __export = (target, all) => {
|
|
|
7
7
|
// src/contract.ts
|
|
8
8
|
var SIDECAR_SCHEMA_VERSION = 1;
|
|
9
9
|
function sidecarProducer() {
|
|
10
|
-
return `billion-context-pi@${true ? "0.2.
|
|
10
|
+
return `billion-context-pi@${true ? "0.2.1" : "dev"}`;
|
|
11
11
|
}
|
|
12
12
|
|
|
13
13
|
export {
|
|
@@ -15,4 +15,4 @@ export {
|
|
|
15
15
|
SIDECAR_SCHEMA_VERSION,
|
|
16
16
|
sidecarProducer
|
|
17
17
|
};
|
|
18
|
-
//# sourceMappingURL=chunk-
|
|
18
|
+
//# sourceMappingURL=chunk-EYDKO7YM.js.map
|
package/dist/config-dir.d.ts
CHANGED
|
@@ -1,32 +1,7 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
/** Pi's name — the fallback, and what releases before fork-host resolution used on every host. */
|
|
6
|
-
export declare const PI_CONFIG_DIR_NAME = ".pi";
|
|
7
|
-
/**
|
|
8
|
-
* Config directory name, resolved from the host package the extension runs under.
|
|
9
|
-
*
|
|
10
|
-
* Every path in this adapter is `<home|cwd>/<name>/…`, with the agent dir at
|
|
11
|
-
* `~/<name>/agent` — Pi's layout, where CONFIG_DIR_NAME is ".pi". Resolution order:
|
|
12
|
-
* 1. the host's CONFIG_DIR_NAME, if it is a single directory name (Pi);
|
|
13
|
-
* 2. the parent of the host's getAgentDir(), if that is `~/<name>/agent` — Pi forks
|
|
14
|
-
* that do not re-export CONFIG_DIR_NAME, or export it with other semantics (Prime:
|
|
15
|
-
* CONFIG_DIR_NAME ".prime/agent", getAgentDir() ~/.prime/agent → ".prime");
|
|
16
|
-
* 3. ".pi".
|
|
17
|
-
* The namespace import is deliberate: a missing named export fails at link time
|
|
18
|
-
* under plain Node ESM→CJS interop and as `undefined` under loader aliasing (#364).
|
|
19
|
-
* It is the ONLY value import from the pi package. See docs/host-adapter.md §4.
|
|
20
|
-
*/
|
|
21
|
-
export declare function resolveConfigDirName(host: HostConfigSurface, home: string): string;
|
|
22
|
-
export declare const CONFIG_DIR_NAME: string;
|
|
23
|
-
/**
|
|
24
|
-
* `<root>/<name>/<segments>` for a user-authored file (acp.json, prompt packs). When
|
|
25
|
-
* `name` is not ".pi", an existing `<root>/.pi/<segments>` is still used while the
|
|
26
|
-
* host's own path does not exist: earlier releases read ".pi" on every host, and Prime
|
|
27
|
-
* users were told to put acp.json there (#467).
|
|
28
|
-
*/
|
|
29
|
-
export declare function userConfigPathIn(name: string, root: string, ...segments: string[]): string;
|
|
1
|
+
import { CONFIG_DIR_NAME } from "@earendil-works/pi-coding-agent";
|
|
2
|
+
/** Pi's config directory name (".pi"); every path here is `<home|cwd>/.pi/…`. */
|
|
3
|
+
export { CONFIG_DIR_NAME };
|
|
4
|
+
/** `<root>/.pi/<segments>` for a user-authored file (acp.json, prompt packs). */
|
|
30
5
|
export declare function userConfigPath(root: string, ...segments: string[]): string;
|
|
31
6
|
/** Global then project acp.json; later entries override earlier ones. */
|
|
32
7
|
export declare function acpJsonFiles(cwd: string): string[];
|
package/dist/config.d.ts
CHANGED
|
@@ -193,14 +193,6 @@ export interface AdapterConfig {
|
|
|
193
193
|
* boolean shorthand (`false` disables) or an object. Default: enabled,
|
|
194
194
|
* minRun=200. */
|
|
195
195
|
degenerationGuard?: boolean | DegenerationGuardConfig;
|
|
196
|
-
/** Host multi-session turn-boundary policy (#364). Accepts a boolean
|
|
197
|
-
* shorthand (`true` → count host-injected custom_message entries as turn
|
|
198
|
-
* boundaries) or a HostSessionConfig object. Default: off — pi-native
|
|
199
|
-
* behavior where only genuine user-role messages start a turn, so existing
|
|
200
|
-
* single-session users' nudge cadence is unchanged. Enable for inline
|
|
201
|
-
* multi-session hosts (Prime RLM & co.) whose injected agent messages must
|
|
202
|
-
* delimit real turns. See docs/host-adapter.md. */
|
|
203
|
-
hostSession?: boolean | HostSessionConfig;
|
|
204
196
|
/** Persistent-rules feature gate (#526): opt-in `rules: true` in acp.json.
|
|
205
197
|
* Gates the human `/acp-rule` command (list + record + remove + clear — kernel
|
|
206
198
|
* `listRules`/`addRule`/`removeRule`/`clearRules` against the session `.acp.json` sidecar state) and
|
|
@@ -257,31 +249,6 @@ export declare function resolveRepetitionGuard(adapter: AdapterConfig): {
|
|
|
257
249
|
warn: number;
|
|
258
250
|
abort: number;
|
|
259
251
|
};
|
|
260
|
-
/** Host multi-session turn-boundary policy (#364). See TurnBoundaryPolicy in
|
|
261
|
-
* src/turn-boundary.ts for the semantics this resolves. */
|
|
262
|
-
export interface HostSessionConfig {
|
|
263
|
-
/** Count host-injected custom_message entries (agent_message) as turn
|
|
264
|
-
* boundaries. Default: false (pi-native behavior). */
|
|
265
|
-
countCustomMessages?: boolean;
|
|
266
|
-
/** #578: optional customType allowlist refining countCustomMessages — when
|
|
267
|
-
* set (with countCustomMessages:true), only injected entries whose
|
|
268
|
-
* customType is listed start a turn, keeping metadata injections
|
|
269
|
-
* (harness_digest, ipython_state) out of nudge/retry accounting. Ignored
|
|
270
|
-
* unless countCustomMessages:true; malformed values warn and fall back to
|
|
271
|
-
* "all injected types count". */
|
|
272
|
-
customMessageTypes?: string[];
|
|
273
|
-
}
|
|
274
|
-
export interface ResolvedHostSession {
|
|
275
|
-
countCustomMessages: boolean;
|
|
276
|
-
/** Present only when countCustomMessages is on and a valid allowlist was
|
|
277
|
-
* configured (#578). */
|
|
278
|
-
customMessageTypes?: readonly string[];
|
|
279
|
-
}
|
|
280
|
-
/** Resolve the host-session turn-boundary policy from the adapter, handling
|
|
281
|
-
* the boolean shorthand (`true` enables countCustomMessages). Invalid values
|
|
282
|
-
* fall back to the pi-native default (off) with a logged warning — they never
|
|
283
|
-
* fail the session. */
|
|
284
|
-
export declare function resolveHostSession(adapter: AdapterConfig): ResolvedHostSession;
|
|
285
252
|
/** Per-field deepest-wins merge of the three compression levels (global →
|
|
286
253
|
* provider → model). An undefined field at a deeper level does NOT clear a
|
|
287
254
|
* value set at a shallower level — only a defined value overrides. */
|
package/dist/contract.js
CHANGED
package/dist/index.d.ts
CHANGED
|
@@ -1,9 +1,6 @@
|
|
|
1
1
|
import type { ExtensionFactory } from "@earendil-works/pi-coding-agent";
|
|
2
2
|
import type { NudgeDecision } from "acp-kernel";
|
|
3
|
-
import {
|
|
4
|
-
export { createRuntime } from "./runtime.js";
|
|
5
|
-
export type { AcpRuntime, SessionRef } from "./runtime.js";
|
|
6
|
-
export { deriveChildState } from "./state.js";
|
|
3
|
+
import type { AdapterConfig } from "./config.js";
|
|
7
4
|
export declare function createAcpExtension(adapter?: AdapterConfig): ExtensionFactory;
|
|
8
5
|
declare const _default: ExtensionFactory;
|
|
9
6
|
export default _default;
|