@centerforagenticai/pi-multi-account 0.1.5 → 0.1.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.
- package/README.md +17 -3
- package/package.json +5 -5
- package/packages/pi-anthropic-oauth/package.json +2 -2
- package/packages/pi-anthropic-oauth/src/stream.ts +18 -8
- package/packages/pi-anthropic-oauth/src/transport-activity.ts +59 -0
- package/packages/pi-antigravity/package.json +2 -2
- package/packages/pi-antigravity/src/models/discovery.ts +2 -1
- package/packages/pi-antigravity/src/models/grouping.ts +12 -10
- package/packages/pi-antigravity/src/models/models.ts +11 -4
- package/src/account-group-failure.ts +149 -0
- package/src/account-group-members.ts +139 -0
- package/src/anthropic-adaptive-stream.ts +18 -9
- package/src/anthropic-alias-stream.ts +13 -68
- package/src/codex-adapter.ts +5 -51
- package/src/commands.ts +3 -3
- package/src/config.ts +46 -2
- package/src/diagnostic-store.ts +17 -15
- package/src/diagnostics.ts +97 -35
- package/src/host-final-stop-message.ts +18 -128
- package/src/index.ts +436 -88
- package/src/logical-dispatch.ts +12 -13
- package/src/logical-provider.ts +1239 -407
- package/src/models-declaration.ts +15 -8
- package/src/public-assistant-projection.ts +163 -0
- package/src/recovery-engine.ts +311 -59
- package/src/routing.ts +4 -8
- package/src/runtime-state.ts +7 -0
- package/src/upstream-anthropic.ts +12 -4
- package/src/upstream-antigravity.ts +2 -38
package/src/logical-dispatch.ts
CHANGED
|
@@ -23,15 +23,16 @@
|
|
|
23
23
|
* - `baseUrl` is applied to the **model**, not to the options.
|
|
24
24
|
* - `env` merges auth env under caller env.
|
|
25
25
|
*/
|
|
26
|
-
import
|
|
27
|
-
AnthropicMessagesCompat,
|
|
28
|
-
Api,
|
|
29
|
-
Context,
|
|
30
|
-
Model,
|
|
31
|
-
ModelCost,
|
|
32
|
-
ProviderHeaders,
|
|
33
|
-
SimpleStreamOptions,
|
|
34
|
-
ThinkingLevelMap,
|
|
26
|
+
import {
|
|
27
|
+
type AnthropicMessagesCompat,
|
|
28
|
+
type Api,
|
|
29
|
+
type Context,
|
|
30
|
+
type Model,
|
|
31
|
+
type ModelCost,
|
|
32
|
+
type ProviderHeaders,
|
|
33
|
+
type SimpleStreamOptions,
|
|
34
|
+
type ThinkingLevelMap,
|
|
35
|
+
type TranscriptContext,
|
|
35
36
|
} from "@earendil-works/pi-ai";
|
|
36
37
|
import type { ModelRegistry } from "@earendil-works/pi-coding-agent";
|
|
37
38
|
import type { LogicalDispatchCall } from "./logical-provider.js";
|
|
@@ -150,9 +151,6 @@ function copyAnthropicCompat(
|
|
|
150
151
|
if (value.supportsStrictTools !== undefined) {
|
|
151
152
|
copy.supportsStrictTools = value.supportsStrictTools;
|
|
152
153
|
}
|
|
153
|
-
if (value.supportsToolReferences !== undefined) {
|
|
154
|
-
copy.supportsToolReferences = value.supportsToolReferences;
|
|
155
|
-
}
|
|
156
154
|
return copy;
|
|
157
155
|
}
|
|
158
156
|
|
|
@@ -272,7 +270,8 @@ export function createLogicalDispatch(
|
|
|
272
270
|
|
|
273
271
|
return provider.streamSimple(
|
|
274
272
|
physicalModel,
|
|
275
|
-
|
|
273
|
+
// Forwarded by reference: the host already supplies a transcript context.
|
|
274
|
+
call.context as TranscriptContext,
|
|
276
275
|
physicalOptions as SimpleStreamOptions,
|
|
277
276
|
);
|
|
278
277
|
};
|