@wildix/wilma-agents-client 1.0.49 → 1.0.50

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.
@@ -57,6 +57,176 @@ export interface AgentAccess {
57
57
  */
58
58
  grants?: AgentGrantPrincipal[] | undefined;
59
59
  }
60
+ /**
61
+ * A pronunciation rule for one phrase. Belongs to a LANGUAGE, not to the agent: 'Wildix' is
62
+ * respelled differently for an Italian and a German voice, so one list shared ACROSS languages
63
+ * would fight itself. That is why the rules hang off the language and nowhere else — there is no
64
+ * company-wide dictionary above them to inherit from, or to disagree with.
65
+ * @public
66
+ */
67
+ export interface VoicePronunciation {
68
+ /**
69
+ * The phrase as it appears in the text, e.g. 'Wildix'. Bounded because every rule is compiled into ONE regular expression — see the list below.
70
+ * @public
71
+ */
72
+ phrase: string;
73
+ /**
74
+ * Respelling (ALIAS) or phonetic transcription (IPA), e.g. 'Wil-dix'.
75
+ * @public
76
+ */
77
+ as: string;
78
+ /**
79
+ * Defaults to ALIAS.
80
+ * @public
81
+ */
82
+ encoding?: VoicePronunciationEncoding | undefined;
83
+ }
84
+ /**
85
+ * One language the assistant audio channel can recognise and speak. There is deliberately no
86
+ * greeting here: an assistant conversation is already open when its audio call starts, so there
87
+ * is no new conversation to welcome and no initial phrase for the runtime to choose or repeat.
88
+ * @public
89
+ */
90
+ export interface AssistantLanguage {
91
+ /**
92
+ * BCP-47 code with locale, e.g. 'en-US', 'it-IT'. Reuses the channel-neutral language value so assistant and voice configuration accept the same codes without sharing policy structures.
93
+ * @public
94
+ */
95
+ code: string;
96
+ /**
97
+ * Voice this language speaks with. Reuses the channel-neutral URI value so providers and
98
+ * synthesis parameters have the same representation in every channel without coupling their
99
+ * language rules.
100
+ *
101
+ * REQUIRED ONLY FOR THE 'voice' ENGINE, enforced in the service rather than here (at
102
+ * `validateAssistantSpeechSettings`, which reads the engine this contract has no view of).
103
+ * 'gpt-live', 'gemini-live' and 'gemini-live-thinking' hold the audio and speak with the
104
+ * gateway's own voice (see AssistantAudioEngine); a language row for one of them carries no
105
+ * voice, and a caller configuring a gateway agent must not have to invent a synthesis URI
106
+ * nobody will ever hear just to satisfy this member.
107
+ * @public
108
+ */
109
+ voice?: string | undefined;
110
+ /**
111
+ * Marks the language used when the caller's language matches nothing configured.
112
+ *
113
+ * THE FULL RESOLUTION ORDER, because a client author reading only this contract cannot
114
+ * otherwise find it: an exact match on the call's language, then a match on its primary
115
+ * subtag (`fr` finds `fr-FR`), then the language marked here, then a language whose primary
116
+ * subtag is `en`, then the first entry in the list. The same order the voice channel resolves
117
+ * by — the rule belongs to choosing a language, not to a channel.
118
+ *
119
+ * At most one language may carry it. A record with two — reachable through the API, where no
120
+ * form prevents it — resolves to the first marked one in list order: refusing an
121
+ * already-open assistant conversation over configuration drift is worse than serving it.
122
+ * @public
123
+ */
124
+ isDefault?: boolean | undefined;
125
+ /**
126
+ * The rules this language is spoken with, same shape and same per-language ownership as
127
+ * VoiceLanguage.pronunciations — a respelling is about how a synthesized reply SOUNDS, not
128
+ * about how a conversation starts, so the rationale that leaves `greeting` off this structure
129
+ * does not apply here. Absent means no respellings for this language, distinct from the voice
130
+ * channel's OWN configured rules for the same language: an agent's assistant audio does not
131
+ * inherit them, so a name gets fixed once and read once, on whichever channel it is saved.
132
+ *
133
+ * READ ONLY BY THE 'voice' ENGINE, same conditionality as `voice` above and for the same
134
+ * reason: 'gpt-live', 'gemini-live' and 'gemini-live-thinking' hold the audio and speak with
135
+ * the gateway's own voice, never this service's synthesis path, so a rule saved here on a
136
+ * gateway agent configures a respelling nothing will ever apply.
137
+ * @public
138
+ */
139
+ pronunciations?: VoicePronunciation[] | undefined;
140
+ }
141
+ /**
142
+ * Speech-to-text configuration owned by the assistant channel, so changes to assistant
143
+ * recognition policy cannot alter telephony calls.
144
+ *
145
+ * NO `autoDetect` HERE, unlike the voice channel: on this channel configuring a second language
146
+ * IS the request to recognise which one is being spoken — nobody lists two and then asks to be
147
+ * heard in only one — so the server derives identification from the language list and clamps it
148
+ * to false when the recogniser cannot identify among them, or there are too few to identify. The
149
+ * voice channel keeps the switch because a dialplan can hand a call its language, which is a
150
+ * choice an assistant conversation never has to make.
151
+ * @public
152
+ */
153
+ export interface AssistantTranscriptionSettings {
154
+ /**
155
+ * Recogniser used for assistant audio. Absent resolves to the platform default, resolved by the server so exactly one component decides it.
156
+ * @public
157
+ */
158
+ engine?: string | undefined;
159
+ }
160
+ /**
161
+ * Recognition and synthesis policy for assistant audio. This is assistant-owned rather than a
162
+ * VoiceSpeechSettings reuse so telephony and assistant audio can evolve independently. It has no
163
+ * language greeting and no greet-every-language switch because an assistant conversation is
164
+ * already open when its audio call starts, leaving nothing for the channel to greet.
165
+ * @public
166
+ */
167
+ export interface AssistantSpeechSettings {
168
+ /**
169
+ * Languages the assistant audio channel can recognise and speak. The @length bound is a
170
+ * STORAGE ceiling, not a promise about what a recogniser accepts at once — unlike the voice
171
+ * channel, where a caller opts into identification with `autoDetect`, THIS channel derives
172
+ * identification from `languages` and turns it on whenever the recogniser can identify among
173
+ * more than one, so every one of the up to ten rows here can become a live candidate list. The
174
+ * service does not clamp that list to a recogniser's own practical limit today (Amazon
175
+ * Transcribe's documented recommendation for streaming identification is five); a caller
176
+ * configuring more than a recogniser accepts should expect degraded identification or a
177
+ * rejected stream, not a refusal from this contract.
178
+ * @public
179
+ */
180
+ languages: AssistantLanguage[];
181
+ /**
182
+ * Which recogniser listens to assistant audio. Absent uses the platform default recogniser. Whether it identifies the spoken language is derived from `languages` rather than configured — see AssistantTranscriptionSettings.
183
+ * @public
184
+ */
185
+ transcription?: AssistantTranscriptionSettings | undefined;
186
+ }
187
+ /**
188
+ * Switchable audio for the assistant channel. The settings object keeps enablement beside its
189
+ * speech policy, matching the voice channel's switchable blocks so a disabled configuration can
190
+ * be retained without serving audio.
191
+ * @public
192
+ */
193
+ export interface AssistantAudioSettings {
194
+ /**
195
+ * Whether the assistant accepts audio calls. Required so the presence of saved speech configuration is never mistaken for enablement.
196
+ * @public
197
+ */
198
+ enabled: boolean;
199
+ /**
200
+ * Which runtime carries the call. Absent is 'voice'.
201
+ * @public
202
+ */
203
+ engine?: string | undefined;
204
+ /**
205
+ * Voice the gateway speaks with. Read only by 'gpt-live', 'gemini-live' and 'gemini-live-thinking' —
206
+ * the same three engines `AssistantLanguage.voice` is silent for, and for the mirror-image reason:
207
+ * that member is read only by the 'voice' engine, which is the one engine that synthesizes; this one
208
+ * is read only by the gateways, which are the ones with a voice of their own to name. Absent is the
209
+ * gateway's own default voice. Ignored, but kept, by the 'voice' engine — an agent switched back to
210
+ * it keeps whatever was saved here, unused until it is switched to a gateway again.
211
+ *
212
+ * A NAME, NOT A URI, unlike `AssistantLanguage.voice`. A gateway's voice is never synthesized by this
213
+ * stack, so there is no provider scheme to prefix and no synthesis parameter to carry on it — only
214
+ * the vendor's own prebuilt voice name ('marin', 'Kore', ...), exactly as the gateway's own API takes
215
+ * it.
216
+ *
217
+ * VALIDATED AGAINST THE SELECTED GATEWAY'S OWN CATALOG, not a shared one: OpenAI's Realtime voices
218
+ * and Gemini's prebuilt voices do not overlap. Enforced in the service
219
+ * (`validateAssistantLiveVoice`, wilma-common), which reads the engine this contract has no view
220
+ * of — the same split `AssistantLanguage.voice`'s own REQUIRED ONLY FOR note describes.
221
+ * @public
222
+ */
223
+ liveVoice?: string | undefined;
224
+ /**
225
+ * Languages, voices and recognition policy for assistant audio. Absent leaves those choices to platform defaults, including when audio is enabled.
226
+ * @public
227
+ */
228
+ speech?: AssistantSpeechSettings | undefined;
229
+ }
60
230
  /**
61
231
  * A starter prompt offered as a card on an empty thread. Picking it sends `prompt` as the user's first message, so the user never types it.
62
232
  * @public
@@ -116,6 +286,7 @@ export interface AssistantUiSettings {
116
286
  placeholder?: string | undefined;
117
287
  }
118
288
  /**
289
+ * Assistant channel settings. Presence enables the in-app assistant surface; audio remains unavailable unless its separate settings are present and enabled.
119
290
  * @public
120
291
  */
121
292
  export interface AssistantChannelSettings {
@@ -129,6 +300,11 @@ export interface AssistantChannelSettings {
129
300
  * @public
130
301
  */
131
302
  ui?: AssistantUiSettings | undefined;
303
+ /**
304
+ * Audio configuration owned by the assistant channel. Absent means the assistant has no audio at all, preserving the behaviour of every existing agent without consulting `channels.voice`.
305
+ * @public
306
+ */
307
+ audio?: AssistantAudioSettings | undefined;
132
308
  }
133
309
  /**
134
310
  * @public
@@ -331,30 +507,6 @@ export interface VoiceSilenceTimeoutSettings {
331
507
  seconds: number;
332
508
  action: VoiceTerminateAction;
333
509
  }
334
- /**
335
- * A pronunciation rule for one phrase. Belongs to a LANGUAGE, not to the agent: 'Wildix' is
336
- * respelled differently for an Italian and a German voice, so one list shared ACROSS languages
337
- * would fight itself. That is why the rules hang off the language and nowhere else — there is no
338
- * company-wide dictionary above them to inherit from, or to disagree with.
339
- * @public
340
- */
341
- export interface VoicePronunciation {
342
- /**
343
- * The phrase as it appears in the text, e.g. 'Wildix'. Bounded because every rule is compiled into ONE regular expression — see the list below.
344
- * @public
345
- */
346
- phrase: string;
347
- /**
348
- * Respelling (ALIAS) or phonetic transcription (IPA), e.g. 'Wil-dix'.
349
- * @public
350
- */
351
- as: string;
352
- /**
353
- * Defaults to ALIAS.
354
- * @public
355
- */
356
- encoding?: VoicePronunciationEncoding | undefined;
357
- }
358
510
  /**
359
511
  * One configured language: its voice, its initial phrase and its pronunciation rules.
360
512
  * @public
@@ -453,9 +605,14 @@ export interface VoiceTranscriptionSettings {
453
605
  */
454
606
  export interface VoiceSpeechSettings {
455
607
  /**
456
- * Configured languages. The @length bound is a STORAGE ceiling, not the product rule: the real
457
- * cap is the recogniser's own candidate limit (five for Amazon Transcribe), enforced in the
458
- * service so a recogniser with a different limit needs no model change.
608
+ * Configured languages. The @length bound is a STORAGE ceiling, not a promise about what a
609
+ * recogniser accepts at once: automatic detection here is opt-in (`transcription.autoDetect`),
610
+ * and once a caller turns it on, the service does not clamp the resulting candidate list to a
611
+ * recogniser's own practical limit today (Amazon Transcribe's documented recommendation for
612
+ * streaming identification is five) — a caller who both opts in and configures more than a
613
+ * recogniser accepts should expect degraded identification or a rejected stream, not a refusal
614
+ * from this contract. With detection off, only the single resolved language is ever sent, so
615
+ * the ceiling never becomes a candidate-list problem at all.
459
616
  * @public
460
617
  */
461
618
  languages: VoiceLanguage[];
@@ -521,6 +678,10 @@ export interface AgentChannels {
521
678
  */
522
679
  voice?: VoiceChannelSettings | undefined;
523
680
  chat?: ChatChannelSettings | undefined;
681
+ /**
682
+ * Assistant channel settings. Presence enables the in-app assistant surface; audio remains unavailable unless its separate settings are present and enabled.
683
+ * @public
684
+ */
524
685
  assistant?: AssistantChannelSettings | undefined;
525
686
  }
526
687
  /**
@@ -1031,17 +1192,17 @@ export interface AgentKnowledgeBase {
1031
1192
  annotations?: AgentToolAnnotation[] | undefined;
1032
1193
  }
1033
1194
  /**
1034
- * Sandbox configured inline on the agent, without a pre-built snapshot.
1195
+ * Sandbox launched from a pre-built snapshot managed by the wilma-sandbox service.
1035
1196
  * @public
1036
1197
  */
1037
- export interface AgentInlineSandboxOptions {
1198
+ export interface AgentSnapshotSandboxOptions {
1038
1199
  /**
1039
- * Platform CPU, memory and workspace allocation. Defaults to SMALL; see SandboxSize.
1200
+ * Snapshot to launch sandboxes from. Managed in the wilma-sandbox service; must be READY.
1040
1201
  * @public
1041
1202
  */
1042
- size?: SandboxSize | undefined;
1203
+ snapshotId: string;
1043
1204
  /**
1044
- * Network access. Defaults to deny-all.
1205
+ * Override the snapshot's network policy for this agent. Defaults to the snapshot's policy.
1045
1206
  * @public
1046
1207
  */
1047
1208
  network?: SandboxNetworkAccess | undefined;
@@ -1050,19 +1211,24 @@ export interface AgentInlineSandboxOptions {
1050
1211
  * @public
1051
1212
  */
1052
1213
  allowedDomains?: string[] | undefined;
1214
+ /**
1215
+ * Override the compute size for this agent. Defaults to the snapshot's size.
1216
+ * @public
1217
+ */
1218
+ size?: SandboxSize | undefined;
1053
1219
  }
1054
1220
  /**
1055
- * Sandbox launched from a pre-built snapshot managed by the wilma-sandbox service.
1221
+ * Vercel Sandbox configuration.
1056
1222
  * @public
1057
1223
  */
1058
- export interface AgentSnapshotSandboxOptions {
1224
+ export interface AgentVercelSandboxOptions {
1059
1225
  /**
1060
- * Snapshot to launch sandboxes from. Managed in the wilma-sandbox service; must be READY.
1226
+ * Number of vCPUs to allocate (2048 MB memory each).
1061
1227
  * @public
1062
1228
  */
1063
- snapshotId: string;
1229
+ vcpus?: number | undefined;
1064
1230
  /**
1065
- * Override the snapshot's network policy for this agent. Defaults to the snapshot's policy.
1231
+ * Network access. Defaults to deny-all.
1066
1232
  * @public
1067
1233
  */
1068
1234
  network?: SandboxNetworkAccess | undefined;
@@ -1071,27 +1237,22 @@ export interface AgentSnapshotSandboxOptions {
1071
1237
  * @public
1072
1238
  */
1073
1239
  allowedDomains?: string[] | undefined;
1074
- /**
1075
- * Defaults to the snapshot's built size. If supplied, must match that size: prepared images cannot be resized at launch. Build a separate snapshot to use another size.
1076
- * @public
1077
- */
1078
- size?: SandboxSize | undefined;
1079
1240
  }
1080
1241
  /**
1081
1242
  * Embedded sandbox: shell + file tools backed by an execution environment. The only capability with no `channels` list — being a union it has nowhere to carry one — so it is offered on every channel the agent serves.
1082
1243
  * @public
1083
1244
  */
1084
- export type AgentSandboxCapability = AgentSandboxCapability.InlineMember | AgentSandboxCapability.SnapshotMember | AgentSandboxCapability.$UnknownMember;
1245
+ export type AgentSandboxCapability = AgentSandboxCapability.SnapshotMember | AgentSandboxCapability.VercelMember | AgentSandboxCapability.$UnknownMember;
1085
1246
  /**
1086
1247
  * @public
1087
1248
  */
1088
1249
  export declare namespace AgentSandboxCapability {
1089
1250
  /**
1090
- * Ad-hoc sandbox configured inline on the agent.
1251
+ * Ad-hoc Vercel Sandbox configured inline on the agent.
1091
1252
  * @public
1092
1253
  */
1093
- interface InlineMember {
1094
- inline: AgentInlineSandboxOptions;
1254
+ interface VercelMember {
1255
+ vercel: AgentVercelSandboxOptions;
1095
1256
  snapshot?: never;
1096
1257
  $unknown?: never;
1097
1258
  }
@@ -1100,7 +1261,7 @@ export declare namespace AgentSandboxCapability {
1100
1261
  * @public
1101
1262
  */
1102
1263
  interface SnapshotMember {
1103
- inline?: never;
1264
+ vercel?: never;
1104
1265
  snapshot: AgentSnapshotSandboxOptions;
1105
1266
  $unknown?: never;
1106
1267
  }
@@ -1108,7 +1269,7 @@ export declare namespace AgentSandboxCapability {
1108
1269
  * @public
1109
1270
  */
1110
1271
  interface $UnknownMember {
1111
- inline?: never;
1272
+ vercel?: never;
1112
1273
  snapshot?: never;
1113
1274
  $unknown: [string, any];
1114
1275
  }
@@ -1117,7 +1278,7 @@ export declare namespace AgentSandboxCapability {
1117
1278
  *
1118
1279
  */
1119
1280
  interface Visitor<T> {
1120
- inline: (value: AgentInlineSandboxOptions) => T;
1281
+ vercel: (value: AgentVercelSandboxOptions) => T;
1121
1282
  snapshot: (value: AgentSnapshotSandboxOptions) => T;
1122
1283
  _: (name: string, value: any) => T;
1123
1284
  }
@@ -3440,6 +3601,11 @@ export interface AgentInfo {
3440
3601
  * @public
3441
3602
  */
3442
3603
  speechConfigured?: boolean | undefined;
3604
+ /**
3605
+ * Whether an end-user client should offer a microphone for this agent: `channels.assistant.audio.enabled` of the definition the agent CURRENTLY RUNS — the deployment's routed version, else the latest published version, else the draft only when nothing was ever published — never an unpublished draft edit. That is the same definition the assistant voice socket resolves and gates on, so `true` here means a call will be accepted; the console preview, which dials `agentDraft=true`, decides from its own form state instead. `ChannelType.ASSISTANT` on `channels` says the assistant surface is served; this is the one bit end-user clients need on top of it, since `channels.assistant.audio` itself carries speech policy an end user must not see. Named for the flag it carries rather than the block it is read from — `assistant` two members below is the whole `AssistantUiSettings` structure, and a name that read like another one of those would point a reader at the wrong shape. Absent is read as false.
3606
+ * @public
3607
+ */
3608
+ assistantAudioEnabled?: boolean | undefined;
3443
3609
  /**
3444
3610
  * Ids of the skills attached to this agent. Always active in this agent's sessions; user skill preferences cannot disable them.
3445
3611
  * @public
@@ -36,7 +36,6 @@ export declare var AgentHandoverPipeline$: StaticStructureSchema;
36
36
  export declare var AgentHangupCapability$: StaticStructureSchema;
37
37
  export declare var AgentHangupPipeline$: StaticStructureSchema;
38
38
  export declare var AgentInfo$: StaticStructureSchema;
39
- export declare var AgentInlineSandboxOptions$: StaticStructureSchema;
40
39
  export declare var AgentKnowledgeBase$: StaticStructureSchema;
41
40
  export declare var AgentSettings$: StaticStructureSchema;
42
41
  export declare var AgentSnapshotSandboxOptions$: StaticStructureSchema;
@@ -60,6 +59,7 @@ export declare var AgentToolVariablesAnnotation$: StaticStructureSchema;
60
59
  export declare var AgentTransferCapability$: StaticStructureSchema;
61
60
  export declare var AgentTransferPipeline$: StaticStructureSchema;
62
61
  export declare var AgentVariable$: StaticStructureSchema;
62
+ export declare var AgentVercelSandboxOptions$: StaticStructureSchema;
63
63
  export declare var AgentVersion$: StaticStructureSchema;
64
64
  export declare var AgentVersionChange$: StaticStructureSchema;
65
65
  export declare var AgentVersionInfo$: StaticStructureSchema;
@@ -96,8 +96,12 @@ export declare var AgentWorkflowStep$: StaticStructureSchema;
96
96
  export declare var AgentWorkflowStepPosition$: StaticStructureSchema;
97
97
  export declare var AgentWorkflowTransition$: StaticStructureSchema;
98
98
  export declare var AgentWorkflowVariablesHandler$: StaticStructureSchema;
99
+ export declare var AssistantAudioSettings$: StaticStructureSchema;
99
100
  export declare var AssistantChannelSettings$: StaticStructureSchema;
101
+ export declare var AssistantLanguage$: StaticStructureSchema;
100
102
  export declare var AssistantQuickCommand$: StaticStructureSchema;
103
+ export declare var AssistantSpeechSettings$: StaticStructureSchema;
104
+ export declare var AssistantTranscriptionSettings$: StaticStructureSchema;
101
105
  export declare var AssistantUiSettings$: StaticStructureSchema;
102
106
  export declare var AssistantWelcomeSettings$: StaticStructureSchema;
103
107
  export declare var ChatChannelSettings$: StaticStructureSchema;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@wildix/wilma-agents-client",
3
3
  "description": "@wildix/wilma-agents-client client",
4
- "version": "1.0.49",
4
+ "version": "1.0.50",
5
5
  "scripts": {
6
6
  "build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types'",
7
7
  "build:cjs": "tsc -p tsconfig.cjs.json",
@@ -56,4 +56,4 @@
56
56
  "browser": {
57
57
  "./dist-es/runtimeConfig": "./dist-es/runtimeConfig.browser"
58
58
  }
59
- }
59
+ }