@mupt-ai/dari-gateway 1.0.360 → 1.0.362
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/dist/ingress/client_harness.d.ts +6 -0
- package/dist/ingress/client_harness.js +17 -1
- package/dist/ingress/models.js +0 -3
- package/dist/models/runtime_overrides.js +5 -0
- package/dist/platform/platform.d.ts +2 -1
- package/dist/platform/routing_contract.d.ts +1 -1
- package/dist/platform/routing_contract.js +3 -3
- package/dist/providers/pi.js +10 -2
- package/dist/runtime/prepare_routed_completion.d.ts +1 -0
- package/dist/runtime/prepare_routed_completion.js +1 -0
- package/dist/runtime/routed_completion.js +2 -0
- package/dist/self_host/connected.d.ts +29 -16
- package/dist/self_host/connected.js +64 -68
- package/dist/self_host/hosted_sync.d.ts +0 -2
- package/dist/self_host/hosted_sync.js +2 -10
- package/dist/self_host/main.d.ts +2 -2
- package/dist/self_host/main.js +10 -9
- package/dist/self_host/resolve.d.ts +7 -4
- package/dist/self_host/resolve.js +72 -18
- package/dist/self_host/subscriptions/http.js +13 -3
- package/dist/self_host/subscriptions/store.d.ts +3 -15
- package/dist/self_host/subscriptions/store.js +11 -27
- package/dist/telemetry/report.js +4 -0
- package/dist/types.d.ts +1 -0
- package/package.json +2 -2
- package/src/ingress/client_harness.ts +18 -1
- package/src/ingress/models.ts +0 -3
- package/src/models/runtime_overrides.ts +4 -0
- package/src/platform/platform.ts +5 -4
- package/src/platform/routing_contract.ts +3 -3
- package/src/providers/pi.ts +10 -2
- package/src/runtime/prepare_routed_completion.ts +2 -0
- package/src/runtime/routed_completion.ts +2 -0
- package/src/self_host/connected.ts +102 -82
- package/src/self_host/hosted_sync.ts +2 -13
- package/src/self_host/main.ts +10 -9
- package/src/self_host/resolve.ts +75 -19
- package/src/self_host/subscriptions/http.ts +12 -3
- package/src/self_host/subscriptions/store.ts +11 -25
- package/src/telemetry/report.ts +3 -0
- package/src/types.ts +2 -0
package/src/telemetry/report.ts
CHANGED
|
@@ -638,8 +638,11 @@ export class RequestReporter {
|
|
|
638
638
|
}),
|
|
639
639
|
};
|
|
640
640
|
|
|
641
|
+
let subscriptionCredentialId: string | undefined;
|
|
642
|
+
if (keySource === "subscription") subscriptionCredentialId = outcome.providerExecution?.subscriptionCredentialId;
|
|
641
643
|
gatewayPlatform().recordRequest({
|
|
642
644
|
...(link === undefined ? {} : { link }),
|
|
645
|
+
...(subscriptionCredentialId === undefined ? {} : { subscriptionCredentialId }),
|
|
643
646
|
router: requestRecordRouter(a.credentials),
|
|
644
647
|
candidates: a.candidates.map(({ model, reasoningEffort }) => ({ model, reasoningEffort })),
|
|
645
648
|
...(a.sessionPinKey === undefined ? {} : { sessionPinKey: a.sessionPinKey }),
|
package/src/types.ts
CHANGED
|
@@ -119,6 +119,8 @@ export type ResolvedRouterModelConfig = {
|
|
|
119
119
|
native_model_id: string;
|
|
120
120
|
api: string;
|
|
121
121
|
base_url?: string | null;
|
|
122
|
+
// Sent with every call to the endpoint.
|
|
123
|
+
headers?: Record<string, string>;
|
|
122
124
|
context_window?: number | null;
|
|
123
125
|
standard_context_limit?: number | null;
|
|
124
126
|
allow_long_context?: boolean;
|