@independo/inderun-contracts 0.4.0 → 0.5.0-rc.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/dist/generated/execution-provenance.d.ts +1 -1
- package/dist/generated/execution-provenance.d.ts.map +1 -1
- package/dist/generated/inderun-error.d.ts +1 -1
- package/dist/generated/inderun-error.d.ts.map +1 -1
- package/dist/generated/index.d.ts +3 -0
- package/dist/generated/index.d.ts.map +1 -1
- package/dist/generated/provider-capability-snapshot.d.ts +370 -0
- package/dist/generated/provider-capability-snapshot.d.ts.map +1 -0
- package/dist/generated/provider-capability-snapshot.js +2 -0
- package/dist/generated/provider-descriptor.d.ts +264 -0
- package/dist/generated/provider-descriptor.d.ts.map +1 -0
- package/dist/generated/provider-descriptor.js +2 -0
- package/dist/generated/provider-dynamic-capabilities.d.ts +99 -0
- package/dist/generated/provider-dynamic-capabilities.d.ts.map +1 -0
- package/dist/generated/provider-dynamic-capabilities.js +2 -0
- package/dist/generated/route-plan.d.ts +47 -3
- package/dist/generated/route-plan.d.ts.map +1 -1
- package/dist/generated/route-planner-input.d.ts +417 -32
- package/dist/generated/route-planner-input.d.ts.map +1 -1
- package/dist/generated/schemas.d.ts +458 -85
- package/dist/generated/schemas.d.ts.map +1 -1
- package/dist/generated/schemas.js +549 -104
- package/dist/generated/stream-event.d.ts +1 -1
- package/dist/generated/stream-event.d.ts.map +1 -1
- package/dist/generated/stream-terminal-outcome.d.ts +1 -1
- package/dist/generated/stream-terminal-outcome.d.ts.map +1 -1
- package/dist/generated/task-result.d.ts +1 -1
- package/dist/generated/task-result.d.ts.map +1 -1
- package/dist/index.d.ts +4 -4
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +2 -2
- package/dist/types.d.ts +7 -1
- package/dist/types.d.ts.map +1 -1
- package/dist/validators.d.ts +9 -0
- package/dist/validators.d.ts.map +1 -1
- package/dist/validators.js +24 -1
- package/package.json +1 -1
- package/src/generated/execution-provenance.ts +1 -1
- package/src/generated/inderun-error.ts +1 -1
- package/src/generated/index.ts +3 -0
- package/src/generated/provider-capability-snapshot.ts +388 -0
- package/src/generated/provider-descriptor.ts +278 -0
- package/src/generated/provider-dynamic-capabilities.ts +103 -0
- package/src/generated/route-plan.ts +49 -3
- package/src/generated/route-planner-input.ts +437 -36
- package/src/generated/schemas.ts +552 -104
- package/src/generated/stream-event.ts +1 -1
- package/src/generated/stream-terminal-outcome.ts +1 -1
- package/src/generated/task-result.ts +1 -1
- package/src/index.ts +13 -1
- package/src/types.ts +7 -0
- package/src/validators.ts +39 -0
|
@@ -25,11 +25,15 @@ export type RoutePlannerInput = {
|
|
|
25
25
|
*/
|
|
26
26
|
preferences: Preferences;
|
|
27
27
|
/**
|
|
28
|
-
* Static descriptors plus dynamic capability
|
|
28
|
+
* Static descriptors plus dynamic capability checks for planning. Both shapes are the
|
|
29
|
+
* provider schemas themselves, shared by $ref, so the planner reads exactly what
|
|
30
|
+
* checkCapabilities() reports.
|
|
29
31
|
*/
|
|
30
32
|
providers: Provider[];
|
|
31
33
|
/**
|
|
32
|
-
*
|
|
34
|
+
* Task descriptor for provider task matching: the kind plus the requirements routing can
|
|
35
|
+
* check against declared capabilities. Absent requirement fields are never checked, so a
|
|
36
|
+
* text request carries the kind alone.
|
|
33
37
|
*/
|
|
34
38
|
task: Task;
|
|
35
39
|
[property: string]: unknown;
|
|
@@ -49,7 +53,7 @@ export type Constraints = {
|
|
|
49
53
|
/**
|
|
50
54
|
* Privacy requirement or preference for execution placement.
|
|
51
55
|
*/
|
|
52
|
-
privacy?:
|
|
56
|
+
privacy?: Privacy;
|
|
53
57
|
[property: string]: unknown;
|
|
54
58
|
};
|
|
55
59
|
/**
|
|
@@ -59,7 +63,7 @@ export type Cloud = "forbidden" | "allowed" | "required";
|
|
|
59
63
|
/**
|
|
60
64
|
* Privacy requirement or preference for execution placement.
|
|
61
65
|
*/
|
|
62
|
-
export type
|
|
66
|
+
export type Privacy = "local_required" | "local_preferred" | "cloud_allowed" | "cloud_required";
|
|
63
67
|
/**
|
|
64
68
|
* Interaction mode the caller is requesting. Absent means 'run' (Mode 1), so planner inputs
|
|
65
69
|
* produced before this field existed keep their exact Mode-1 semantics. The mode filters
|
|
@@ -99,74 +103,455 @@ export type Preferences = {
|
|
|
99
103
|
*/
|
|
100
104
|
export type OptimizeFor = "privacy" | "latency" | "cost" | "balanced";
|
|
101
105
|
export type Provider = {
|
|
102
|
-
|
|
103
|
-
|
|
106
|
+
/**
|
|
107
|
+
* The provider's live capability check, already folded by the engine (for example,
|
|
108
|
+
* streamingAvailable is false when the provider declares streaming but does not implement
|
|
109
|
+
* it).
|
|
110
|
+
*/
|
|
111
|
+
capabilities: ProviderDynamicCapabilities;
|
|
112
|
+
/**
|
|
113
|
+
* The provider's static capability declaration.
|
|
114
|
+
*/
|
|
115
|
+
descriptor: ProviderDescriptor;
|
|
104
116
|
[property: string]: unknown;
|
|
105
117
|
};
|
|
106
|
-
|
|
118
|
+
/**
|
|
119
|
+
* The provider's live capability check, already folded by the engine (for example,
|
|
120
|
+
* streamingAvailable is false when the provider declares streaming but does not implement
|
|
121
|
+
* it).
|
|
122
|
+
*
|
|
123
|
+
* A provider's live capability check, evaluated on the current host when routing or when
|
|
124
|
+
* checkCapabilities() is called. Unlike the descriptor it can change between calls.
|
|
125
|
+
*/
|
|
126
|
+
export type ProviderDynamicCapabilities = {
|
|
127
|
+
/**
|
|
128
|
+
* Whether the provider is available and functional on this host right now.
|
|
129
|
+
*/
|
|
107
130
|
available: boolean;
|
|
108
131
|
/**
|
|
109
|
-
* Whether cancellation is honored
|
|
110
|
-
*
|
|
132
|
+
* Whether cancellation is honored on this host right now. Absent inherits the static
|
|
133
|
+
* descriptor.cancel value: any value other than 'none' means available. Never null.
|
|
134
|
+
*/
|
|
135
|
+
cancellationAvailable?: boolean;
|
|
136
|
+
/**
|
|
137
|
+
* Why the provider is unavailable, when available is false.
|
|
138
|
+
*/
|
|
139
|
+
reason?: string;
|
|
140
|
+
/**
|
|
141
|
+
* Whether the provider can stream (Mode 2) on this host right now. Absent inherits the
|
|
142
|
+
* static descriptor.supports.streaming value; only set it when the host takes streaming
|
|
143
|
+
* away from a provider that otherwise declares it. Never null.
|
|
144
|
+
*/
|
|
145
|
+
streamingAvailable?: boolean;
|
|
146
|
+
/**
|
|
147
|
+
* Why streaming is unavailable, when streamingAvailable is false. Absent lets the route
|
|
148
|
+
* planner synthesize a default message.
|
|
149
|
+
*/
|
|
150
|
+
streamingUnavailableReason?: string;
|
|
151
|
+
/**
|
|
152
|
+
* Per-task overrides of the provider-level check, for tasks whose availability differs on
|
|
153
|
+
* this host, e.g. a voice that is not installed. Every field of an entry is optional and
|
|
154
|
+
* absent inherits the provider-level value; a false at either level wins.
|
|
155
|
+
*/
|
|
156
|
+
taskCapabilities?: ProviderTaskAvailability[];
|
|
157
|
+
[property: string]: unknown;
|
|
158
|
+
};
|
|
159
|
+
/**
|
|
160
|
+
* The live check for one task kind.
|
|
161
|
+
*/
|
|
162
|
+
export type ProviderTaskAvailability = {
|
|
163
|
+
/**
|
|
164
|
+
* Whether the task can run on this host right now. Absent inherits the provider-level
|
|
165
|
+
* available. Never null.
|
|
166
|
+
*/
|
|
167
|
+
available?: boolean;
|
|
168
|
+
/**
|
|
169
|
+
* Whether cancellation is honored for this task right now. Absent inherits. Never null.
|
|
111
170
|
*/
|
|
112
171
|
cancellationAvailable?: boolean;
|
|
172
|
+
/**
|
|
173
|
+
* The task kind this entry describes.
|
|
174
|
+
*/
|
|
175
|
+
kind: string;
|
|
176
|
+
/**
|
|
177
|
+
* BCP 47 locales available for this task right now. Absent means the provider cannot
|
|
178
|
+
* enumerate them.
|
|
179
|
+
*/
|
|
180
|
+
locales?: string[];
|
|
181
|
+
/**
|
|
182
|
+
* Why the task is unavailable, when available is false.
|
|
183
|
+
*/
|
|
113
184
|
reason?: string;
|
|
114
185
|
/**
|
|
115
|
-
* Whether the
|
|
116
|
-
* static descriptor.supports.streaming value.
|
|
186
|
+
* Whether the task can stream on this host right now. Absent inherits. Never null.
|
|
117
187
|
*/
|
|
118
188
|
streamingAvailable?: boolean;
|
|
119
189
|
/**
|
|
120
|
-
*
|
|
121
|
-
* synthesize a default message.
|
|
190
|
+
* Why streaming is unavailable for this task, when streamingAvailable is false.
|
|
122
191
|
*/
|
|
123
192
|
streamingUnavailableReason?: string;
|
|
193
|
+
/**
|
|
194
|
+
* Voices available for this task right now. Absent means the provider cannot enumerate
|
|
195
|
+
* them; a request that requires a voice then never routes to it.
|
|
196
|
+
*/
|
|
197
|
+
voices?: ProviderVoice[];
|
|
198
|
+
[property: string]: unknown;
|
|
199
|
+
};
|
|
200
|
+
/**
|
|
201
|
+
* Provider-neutral traits of one available voice. Carries no provider voice identifier.
|
|
202
|
+
*/
|
|
203
|
+
export type ProviderVoice = {
|
|
204
|
+
gender?: VoiceGender;
|
|
205
|
+
/**
|
|
206
|
+
* BCP 47 locale the voice speaks.
|
|
207
|
+
*/
|
|
208
|
+
locale: string;
|
|
209
|
+
/**
|
|
210
|
+
* Whether using the voice sends data off the device. Absent inherits the task's privacy
|
|
211
|
+
* posture.
|
|
212
|
+
*/
|
|
213
|
+
networkRequired?: boolean;
|
|
124
214
|
[property: string]: unknown;
|
|
125
215
|
};
|
|
126
|
-
|
|
216
|
+
/**
|
|
217
|
+
* Perceived gender of a voice, as the platform reports it.
|
|
218
|
+
*/
|
|
219
|
+
export type VoiceGender = "female" | "male" | "neutral";
|
|
220
|
+
/**
|
|
221
|
+
* The provider's static capability declaration.
|
|
222
|
+
*
|
|
223
|
+
* A provider's static capability declaration: identity, placement, transport, supported
|
|
224
|
+
* interaction modes and tasks, cancellation guarantee, resource limits and privacy posture.
|
|
225
|
+
* It does not change while the provider is registered. The route planner,
|
|
226
|
+
* checkCapabilities() and execution provenance all read this one shape.
|
|
227
|
+
*/
|
|
228
|
+
export type ProviderDescriptor = {
|
|
127
229
|
/**
|
|
128
|
-
* Cancellation guarantee
|
|
129
|
-
*
|
|
230
|
+
* Cancellation guarantee: 'hard' stops processing including remote work, 'soft' stops
|
|
231
|
+
* reading locally while remote work may continue, 'none' means cancellation is unsupported.
|
|
232
|
+
* Independently of this value, the engine delivers no event after a cancel.
|
|
233
|
+
*/
|
|
234
|
+
cancel: CancelSemantics;
|
|
235
|
+
/**
|
|
236
|
+
* Unique identifier of the provider instance (a target), e.g. 'apple_foundation_models' or
|
|
237
|
+
* 'openai_compatible_cloud:gpt-5-mini'. Model profiles list targets by this id.
|
|
130
238
|
*/
|
|
131
|
-
cancel?: Cancel;
|
|
132
239
|
id: string;
|
|
133
240
|
/**
|
|
134
|
-
*
|
|
241
|
+
* Optional input and output resource limits.
|
|
242
|
+
*/
|
|
243
|
+
limits?: ProviderLimits;
|
|
244
|
+
/**
|
|
245
|
+
* The model this provider instance is bound to, when it can name one. Cloud providers
|
|
246
|
+
* report the model id they send; platform-managed models report an opaque platform alias
|
|
247
|
+
* rather than a guessed weight name. Absent means the provider cannot name its model.
|
|
248
|
+
*/
|
|
249
|
+
model?: string;
|
|
250
|
+
/**
|
|
251
|
+
* Data-egress posture, used to enforce local and cloud routing rules. Absent means a local
|
|
252
|
+
* or edge provider is treated as keeping data on the device and a cloud provider as sending
|
|
253
|
+
* it off.
|
|
254
|
+
*/
|
|
255
|
+
privacy?: ProviderPrivacy;
|
|
256
|
+
/**
|
|
257
|
+
* How a streaming provider delivers incremental output: individual tokens, larger chunks,
|
|
258
|
+
* or whole snapshots. Absent for providers that do not stream.
|
|
259
|
+
*/
|
|
260
|
+
streamingStyle?: StreamingStyle;
|
|
261
|
+
/**
|
|
262
|
+
* Interaction modes and features the provider statically declares.
|
|
263
|
+
*/
|
|
264
|
+
supports: ProviderSupports;
|
|
265
|
+
/**
|
|
266
|
+
* What the provider can do for each task: accepted inputs, interaction modes, output
|
|
267
|
+
* deliveries and formats, cancellation, locales and privacy. When present it is
|
|
268
|
+
* authoritative for routing and must list every task the provider serves. When absent (a
|
|
269
|
+
* legacy descriptor), routing infers exactly one entry — 'text_to_text' with text input,
|
|
270
|
+
* inline output, run/stream from supports and cancel from cancel — if tasks contains
|
|
271
|
+
* 'text_to_text', and nothing for any other task: a legacy descriptor is never treated as
|
|
272
|
+
* capable of a non-text task.
|
|
273
|
+
*/
|
|
274
|
+
taskCapabilities?: ProviderTaskCapability[];
|
|
275
|
+
/**
|
|
276
|
+
* Task kinds the provider supports, e.g. 'text_to_text'. When taskCapabilities is present
|
|
277
|
+
* it must describe the same kinds and is what routing reads; without it, routing infers
|
|
278
|
+
* capabilities for 'text_to_text' alone (see taskCapabilities).
|
|
135
279
|
*/
|
|
136
|
-
privacy?: PrivacyObject;
|
|
137
|
-
supports: Supports;
|
|
138
280
|
tasks: string[];
|
|
139
|
-
|
|
281
|
+
/**
|
|
282
|
+
* How the engine reaches the provider: in-process runtime, operating-system service,
|
|
283
|
+
* buffered HTTP, server-sent events, or a realtime connection.
|
|
284
|
+
*/
|
|
285
|
+
transport: ProviderTransport;
|
|
286
|
+
/**
|
|
287
|
+
* Execution placement: 'local' (on the device), 'edge', or 'cloud'.
|
|
288
|
+
*/
|
|
289
|
+
type: ProviderType;
|
|
140
290
|
[property: string]: unknown;
|
|
141
291
|
};
|
|
142
292
|
/**
|
|
143
|
-
* Cancellation guarantee
|
|
144
|
-
*
|
|
293
|
+
* Cancellation guarantee: 'hard' stops processing including remote work, 'soft' stops
|
|
294
|
+
* reading locally while remote work may continue, 'none' means cancellation is unsupported.
|
|
295
|
+
* Independently of this value, the engine delivers no event after a cancel.
|
|
296
|
+
*
|
|
297
|
+
* Cancellation guarantee for this task. It may differ from the provider-level cancel, e.g.
|
|
298
|
+
* when stopping playback is immediate but a synthesis request cannot be aborted.
|
|
299
|
+
*/
|
|
300
|
+
export type CancelSemantics = "hard" | "soft" | "none";
|
|
301
|
+
/**
|
|
302
|
+
* Optional input and output resource limits.
|
|
145
303
|
*/
|
|
146
|
-
export type
|
|
304
|
+
export type ProviderLimits = {
|
|
305
|
+
/**
|
|
306
|
+
* Longest accepted or produced audio, in seconds.
|
|
307
|
+
*/
|
|
308
|
+
maxAudioSeconds?: number;
|
|
309
|
+
/**
|
|
310
|
+
* Largest accepted image, in bytes.
|
|
311
|
+
*/
|
|
312
|
+
maxImageBytes?: number;
|
|
313
|
+
/**
|
|
314
|
+
* Largest accepted input, in tokens.
|
|
315
|
+
*/
|
|
316
|
+
maxInputTokens?: number;
|
|
317
|
+
/**
|
|
318
|
+
* Largest output the provider produces, in tokens.
|
|
319
|
+
*/
|
|
320
|
+
maxOutputTokens?: number;
|
|
321
|
+
[property: string]: unknown;
|
|
322
|
+
};
|
|
147
323
|
/**
|
|
148
|
-
*
|
|
324
|
+
* Data-egress posture, used to enforce local and cloud routing rules. Absent means a local
|
|
325
|
+
* or edge provider is treated as keeping data on the device and a cloud provider as sending
|
|
326
|
+
* it off.
|
|
327
|
+
*
|
|
328
|
+
* Data-egress posture for this task when it differs from the provider-level privacy, e.g. a
|
|
329
|
+
* provider whose speech synthesis uses a network service. Absent inherits
|
|
330
|
+
* descriptor.privacy.
|
|
149
331
|
*/
|
|
150
|
-
export type
|
|
332
|
+
export type ProviderPrivacy = {
|
|
333
|
+
/**
|
|
334
|
+
* Whether request content leaves the device.
|
|
335
|
+
*/
|
|
151
336
|
dataLeavesDevice: boolean;
|
|
337
|
+
/**
|
|
338
|
+
* Geographic regions where a cloud provider processes data.
|
|
339
|
+
*/
|
|
152
340
|
regions?: string[];
|
|
153
341
|
[property: string]: unknown;
|
|
154
342
|
};
|
|
155
|
-
|
|
343
|
+
/**
|
|
344
|
+
* How a streaming provider delivers incremental output: individual tokens, larger chunks,
|
|
345
|
+
* or whole snapshots. Absent for providers that do not stream.
|
|
346
|
+
*/
|
|
347
|
+
export type StreamingStyle = "tokens" | "chunks" | "snapshots";
|
|
348
|
+
/**
|
|
349
|
+
* Interaction modes and features the provider statically declares.
|
|
350
|
+
*/
|
|
351
|
+
export type ProviderSupports = {
|
|
352
|
+
/**
|
|
353
|
+
* Whether the provider accepts non-text inputs such as images or audio.
|
|
354
|
+
*/
|
|
355
|
+
multimodal: boolean;
|
|
356
|
+
/**
|
|
357
|
+
* Whether the provider supports Mode 3 realtime sessions. Reserved; no engine implements
|
|
358
|
+
* Mode 3 yet.
|
|
359
|
+
*/
|
|
360
|
+
realtime: boolean;
|
|
361
|
+
/**
|
|
362
|
+
* Whether the provider emits reasoning events alongside content.
|
|
363
|
+
*/
|
|
364
|
+
reasoningEvents: boolean;
|
|
365
|
+
/**
|
|
366
|
+
* Whether the provider supports Mode 1 run (request/response).
|
|
367
|
+
*/
|
|
368
|
+
run: boolean;
|
|
369
|
+
/**
|
|
370
|
+
* Whether the provider supports Mode 2 stream. A provider that declares it must also
|
|
371
|
+
* implement the streaming adapter; the engines report it as unavailable otherwise.
|
|
372
|
+
*/
|
|
373
|
+
streaming: boolean;
|
|
374
|
+
/**
|
|
375
|
+
* Whether the provider supports structured output constrained by a JSON schema.
|
|
376
|
+
*/
|
|
377
|
+
structuredOutput: boolean;
|
|
378
|
+
/**
|
|
379
|
+
* Whether the provider supports tool calling.
|
|
380
|
+
*/
|
|
381
|
+
tools: boolean;
|
|
382
|
+
[property: string]: unknown;
|
|
383
|
+
};
|
|
384
|
+
/**
|
|
385
|
+
* The provider's static capabilities for one task kind.
|
|
386
|
+
*/
|
|
387
|
+
export type ProviderTaskCapability = {
|
|
388
|
+
/**
|
|
389
|
+
* Cancellation guarantee for this task. It may differ from the provider-level cancel, e.g.
|
|
390
|
+
* when stopping playback is immediate but a synthesis request cannot be aborted.
|
|
391
|
+
*/
|
|
392
|
+
cancel: CancelSemantics;
|
|
393
|
+
/**
|
|
394
|
+
* Input media kinds the provider accepts for this task.
|
|
395
|
+
*/
|
|
396
|
+
inputs: [TaskInputKind, ...TaskInputKind[]];
|
|
397
|
+
/**
|
|
398
|
+
* Interaction modes the provider supports for this task.
|
|
399
|
+
*/
|
|
400
|
+
interaction: ProviderTaskInteraction;
|
|
401
|
+
/**
|
|
402
|
+
* The task kind this entry describes, e.g. 'text_to_speech'.
|
|
403
|
+
*/
|
|
404
|
+
kind: string;
|
|
405
|
+
/**
|
|
406
|
+
* BCP 47 locales the provider can serve for this task, when it knows them statically.
|
|
407
|
+
* Absent means unknown; the dynamic check may report them instead.
|
|
408
|
+
*/
|
|
409
|
+
locales?: string[];
|
|
410
|
+
/**
|
|
411
|
+
* How results of this task can be delivered. A provider lists only what it really produces:
|
|
412
|
+
* a provider that can only play audio lists 'playback' and never 'artifact'.
|
|
413
|
+
*/
|
|
414
|
+
outputs: [ProviderTaskOutput, ...ProviderTaskOutput[]];
|
|
415
|
+
/**
|
|
416
|
+
* Data-egress posture for this task when it differs from the provider-level privacy, e.g. a
|
|
417
|
+
* provider whose speech synthesis uses a network service. Absent inherits
|
|
418
|
+
* descriptor.privacy.
|
|
419
|
+
*/
|
|
420
|
+
privacy?: ProviderPrivacy;
|
|
421
|
+
[property: string]: unknown;
|
|
422
|
+
};
|
|
423
|
+
/**
|
|
424
|
+
* A kind of input medium a task consumes.
|
|
425
|
+
*/
|
|
426
|
+
export type TaskInputKind = "text" | "image" | "audio";
|
|
427
|
+
/**
|
|
428
|
+
* Interaction modes the provider supports for this task.
|
|
429
|
+
*/
|
|
430
|
+
export type ProviderTaskInteraction = {
|
|
431
|
+
/**
|
|
432
|
+
* Whether the provider supports Mode 1 run for this task.
|
|
433
|
+
*/
|
|
156
434
|
run: boolean;
|
|
157
435
|
/**
|
|
158
|
-
* Whether the provider
|
|
159
|
-
* descriptor that predates this field cannot be assumed to stream.
|
|
436
|
+
* Whether the provider supports Mode 2 stream for this task.
|
|
160
437
|
*/
|
|
161
|
-
|
|
438
|
+
stream: boolean;
|
|
162
439
|
[property: string]: unknown;
|
|
163
440
|
};
|
|
164
|
-
export type Type = "local" | "edge" | "cloud";
|
|
165
441
|
/**
|
|
166
|
-
*
|
|
442
|
+
* One way the provider can deliver a task's result.
|
|
443
|
+
*/
|
|
444
|
+
export type ProviderTaskOutput = {
|
|
445
|
+
delivery: OutputDelivery;
|
|
446
|
+
/**
|
|
447
|
+
* Media types the provider can produce with this delivery, e.g. 'audio/wav'. Absent means
|
|
448
|
+
* the provider does not declare them; a request that requires specific media types never
|
|
449
|
+
* routes to such an output.
|
|
450
|
+
*/
|
|
451
|
+
mediaTypes?: string[];
|
|
452
|
+
[property: string]: unknown;
|
|
453
|
+
};
|
|
454
|
+
/**
|
|
455
|
+
* How a task's result reaches the application: 'inline' content in the result (text),
|
|
456
|
+
* 'playback' as a managed, audible effect on the device with no retrievable bytes, or
|
|
457
|
+
* 'artifact' as retrievable media.
|
|
458
|
+
*/
|
|
459
|
+
export type OutputDelivery = "inline" | "playback" | "artifact";
|
|
460
|
+
/**
|
|
461
|
+
* How the engine reaches the provider: in-process runtime, operating-system service,
|
|
462
|
+
* buffered HTTP, server-sent events, or a realtime connection.
|
|
463
|
+
*/
|
|
464
|
+
export type ProviderTransport = "in_process" | "system_service" | "http" | "sse" | "realtime";
|
|
465
|
+
/**
|
|
466
|
+
* Execution placement: 'local' (on the device), 'edge', or 'cloud'.
|
|
467
|
+
*/
|
|
468
|
+
export type ProviderType = "local" | "edge" | "cloud";
|
|
469
|
+
/**
|
|
470
|
+
* Task descriptor for provider task matching: the kind plus the requirements routing can
|
|
471
|
+
* check against declared capabilities. Absent requirement fields are never checked, so a
|
|
472
|
+
* text request carries the kind alone.
|
|
167
473
|
*/
|
|
168
474
|
export type Task = {
|
|
475
|
+
/**
|
|
476
|
+
* The output delivery the request requires. Absent for text, whose delivery is implicitly
|
|
477
|
+
* inline.
|
|
478
|
+
*/
|
|
479
|
+
delivery?: DeliveryRequirement;
|
|
480
|
+
/**
|
|
481
|
+
* Input media kinds the request carries. Every one must be accepted by the provider's task
|
|
482
|
+
* capability. The SDKs send ['text'] for text_to_text.
|
|
483
|
+
*/
|
|
484
|
+
inputs?: TaskInputKind[];
|
|
485
|
+
/**
|
|
486
|
+
* The task kind, matched against the providers' task capabilities.
|
|
487
|
+
*/
|
|
169
488
|
kind: string;
|
|
489
|
+
/**
|
|
490
|
+
* The locale the request requires. Under 'language' matching the region is a preference: a
|
|
491
|
+
* provider known to offer the exact tag ranks ahead of an otherwise equal one. A provider
|
|
492
|
+
* that cannot enumerate its locales is not rejected on this basis; it must fail before
|
|
493
|
+
* committing instead.
|
|
494
|
+
*/
|
|
495
|
+
locale?: LocaleRequirement;
|
|
496
|
+
/**
|
|
497
|
+
* Voice traits the request asks for. Only a 'required' voice can reject a provider; a
|
|
498
|
+
* 'preferred' one shapes which listed voice the plan binds a candidate to, always within
|
|
499
|
+
* the request's privacy policy.
|
|
500
|
+
*/
|
|
501
|
+
voice?: VoiceRequirement;
|
|
170
502
|
[property: string]: unknown;
|
|
171
503
|
};
|
|
504
|
+
/**
|
|
505
|
+
* The output delivery the request requires. Absent for text, whose delivery is implicitly
|
|
506
|
+
* inline.
|
|
507
|
+
*/
|
|
508
|
+
export type DeliveryRequirement = {
|
|
509
|
+
/**
|
|
510
|
+
* Acceptable media types; the provider must declare at least one for the requested
|
|
511
|
+
* delivery. Absent means any.
|
|
512
|
+
*/
|
|
513
|
+
mediaTypes?: string[];
|
|
514
|
+
mode: OutputDelivery;
|
|
515
|
+
[property: string]: unknown;
|
|
516
|
+
};
|
|
517
|
+
/**
|
|
518
|
+
* The locale the request requires. Under 'language' matching the region is a preference: a
|
|
519
|
+
* provider known to offer the exact tag ranks ahead of an otherwise equal one. A provider
|
|
520
|
+
* that cannot enumerate its locales is not rejected on this basis; it must fail before
|
|
521
|
+
* committing instead.
|
|
522
|
+
*/
|
|
523
|
+
export type LocaleRequirement = {
|
|
524
|
+
/**
|
|
525
|
+
* 'exact' requires the full tag; 'language' requires only the primary language subtag and
|
|
526
|
+
* treats the region as a preference.
|
|
527
|
+
*/
|
|
528
|
+
match: LocaleMatch;
|
|
529
|
+
/**
|
|
530
|
+
* BCP 47 tag.
|
|
531
|
+
*/
|
|
532
|
+
tag: string;
|
|
533
|
+
[property: string]: unknown;
|
|
534
|
+
};
|
|
535
|
+
/**
|
|
536
|
+
* 'exact' requires the full tag; 'language' requires only the primary language subtag and
|
|
537
|
+
* treats the region as a preference.
|
|
538
|
+
*/
|
|
539
|
+
export type LocaleMatch = "exact" | "language";
|
|
540
|
+
/**
|
|
541
|
+
* Voice traits the request asks for. Only a 'required' voice can reject a provider; a
|
|
542
|
+
* 'preferred' one shapes which listed voice the plan binds a candidate to, always within
|
|
543
|
+
* the request's privacy policy.
|
|
544
|
+
*/
|
|
545
|
+
export type VoiceRequirement = {
|
|
546
|
+
gender?: VoiceGender;
|
|
547
|
+
/**
|
|
548
|
+
* 'required' takes part in routing; 'preferred' does not.
|
|
549
|
+
*/
|
|
550
|
+
requirement: RequirementLevel;
|
|
551
|
+
[property: string]: unknown;
|
|
552
|
+
};
|
|
553
|
+
/**
|
|
554
|
+
* 'required' takes part in routing; 'preferred' does not.
|
|
555
|
+
*/
|
|
556
|
+
export type RequirementLevel = "required" | "preferred";
|
|
172
557
|
//# sourceMappingURL=route-planner-input.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"route-planner-input.d.ts","sourceRoot":"","sources":["../../src/generated/route-planner-input.ts"],"names":[],"mappings":"AAEA;;GAEG;AACH,MAAM,MAAM,iBAAiB,GAAG;IAC5B;;OAEG;IACH,WAAW,EAAE,WAAW,CAAC;IACzB;;;;OAIG;IACH,eAAe,CAAC,EAAE,eAAe,CAAC;IAClC;;;;;;OAMG;IACH,YAAY,CAAC,EAAE,YAAY,CAAC;IAC5B;;OAEG;IACH,WAAW,EAAE,WAAW,CAAC;IACzB
|
|
1
|
+
{"version":3,"file":"route-planner-input.d.ts","sourceRoot":"","sources":["../../src/generated/route-planner-input.ts"],"names":[],"mappings":"AAEA;;GAEG;AACH,MAAM,MAAM,iBAAiB,GAAG;IAC5B;;OAEG;IACH,WAAW,EAAE,WAAW,CAAC;IACzB;;;;OAIG;IACH,eAAe,CAAC,EAAE,eAAe,CAAC;IAClC;;;;;;OAMG;IACH,YAAY,CAAC,EAAE,YAAY,CAAC;IA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