@vellumai/assistant 0.10.9-dev.202607161831.8c8f521 → 0.10.9-dev.202607162023.cfcbc5d
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/openapi.yaml +416 -28
- package/package.json +1 -1
- package/scripts/generate-openapi.ts +8 -0
- package/src/__tests__/call-controller.test.ts +291 -0
- package/src/__tests__/call-site-routing-connection-auto-resolve.test.ts +165 -0
- package/src/__tests__/media-stream-output.test.ts +259 -3
- package/src/__tests__/media-stream-server-integration.test.ts +22 -1
- package/src/__tests__/media-stream-stt-session.test.ts +47 -0
- package/src/__tests__/provider-connections-backfill.test.ts +138 -0
- package/src/__tests__/telemetry-routes.test.ts +32 -4
- package/src/calls/call-constants.ts +5 -0
- package/src/calls/call-controller.ts +100 -32
- package/src/calls/call-transport.ts +9 -0
- package/src/calls/media-stream-output.ts +107 -4
- package/src/calls/media-stream-server.ts +29 -9
- package/src/calls/media-stream-stt-session.ts +7 -1
- package/src/calls/voice-session-bridge.ts +19 -1
- package/src/cli/commands/__tests__/notifications.test.ts +24 -3
- package/src/cli/commands/notifications.help.ts +10 -10
- package/src/cli/commands/oauth/connect-surface-guidance.test.ts +40 -0
- package/src/cli/commands/oauth/connect-surface-guidance.ts +54 -0
- package/src/cli/commands/oauth/connect.test.ts +126 -0
- package/src/cli/commands/oauth/connect.ts +29 -6
- package/src/cli/commands/oauth/index.help.ts +7 -1
- package/src/cli/commands/oauth/status.test.ts +69 -3
- package/src/cli/commands/oauth/status.ts +50 -12
- package/src/cli/lib/bundled-marketplace.json +14 -0
- package/src/live-voice/__tests__/live-voice-vad.test.ts +145 -0
- package/src/live-voice/live-voice-session.ts +109 -18
- package/src/providers/call-site-routing.ts +19 -10
- package/src/providers/inference/backfill.ts +36 -1
- package/src/runtime/routes/telemetry-routes.ts +75 -55
- package/src/telemetry/telemetry-wire-validation.ts +30 -3
- package/src/telemetry/types.ts +0 -31
package/openapi.yaml
CHANGED
|
@@ -29081,13 +29081,13 @@ paths:
|
|
|
29081
29081
|
/v1/telemetry/ingest:
|
|
29082
29082
|
post:
|
|
29083
29083
|
operationId: telemetry_ingest_post
|
|
29084
|
-
summary: Record
|
|
29084
|
+
summary: Record an outbox-backed telemetry event
|
|
29085
29085
|
description:
|
|
29086
|
-
|
|
29087
|
-
|
|
29088
|
-
|
|
29089
|
-
share_analytics consent like every other outbox-backed event; the platform re-checks the
|
|
29090
|
-
server-side at ingest.
|
|
29086
|
+
Record any outbox-backed telemetry event by its wire `type` + `fields`. For events a client observes and
|
|
29087
|
+
the daemon can't detect on its own (e.g. onboarding_research). The type must be an outbox-backed event — the
|
|
29088
|
+
watermark types (turn, llm_usage, tool_executed) have no variant — and the payload must pass the platform wire
|
|
29089
|
+
schema. Gated on share_analytics consent like every other outbox-backed event; the platform re-checks the
|
|
29090
|
+
owner's consent server-side at ingest.
|
|
29091
29091
|
tags:
|
|
29092
29092
|
- telemetry
|
|
29093
29093
|
requestBody:
|
|
@@ -29095,29 +29095,403 @@ paths:
|
|
|
29095
29095
|
content:
|
|
29096
29096
|
application/json:
|
|
29097
29097
|
schema:
|
|
29098
|
+
oneOf:
|
|
29099
|
+
- type: object
|
|
29100
|
+
properties:
|
|
29101
|
+
type:
|
|
29102
|
+
type: string
|
|
29103
|
+
const: lifecycle
|
|
29104
|
+
fields:
|
|
29105
|
+
type: object
|
|
29106
|
+
properties:
|
|
29107
|
+
event_name:
|
|
29108
|
+
type: string
|
|
29109
|
+
minLength: 1
|
|
29110
|
+
maxLength: 64
|
|
29111
|
+
required:
|
|
29112
|
+
- event_name
|
|
29113
|
+
description:
|
|
29114
|
+
Wire event fields, excluding the daemon-stamped base fields (type, daemon_event_id, recorded_at,
|
|
29115
|
+
assistant_version).
|
|
29116
|
+
daemon_event_id:
|
|
29117
|
+
description:
|
|
29118
|
+
"Optional collapse key: rows sharing an id collapse downstream (e.g. a retried report). Defaults to a fresh
|
|
29119
|
+
per-row id."
|
|
29120
|
+
type: string
|
|
29121
|
+
minLength: 1
|
|
29122
|
+
maxLength: 128
|
|
29123
|
+
required:
|
|
29124
|
+
- type
|
|
29125
|
+
- fields
|
|
29126
|
+
- type: object
|
|
29127
|
+
properties:
|
|
29128
|
+
type:
|
|
29129
|
+
type: string
|
|
29130
|
+
const: onboarding
|
|
29131
|
+
fields:
|
|
29132
|
+
type: object
|
|
29133
|
+
properties:
|
|
29134
|
+
screen:
|
|
29135
|
+
type: string
|
|
29136
|
+
minLength: 1
|
|
29137
|
+
maxLength: 64
|
|
29138
|
+
tools:
|
|
29139
|
+
type: array
|
|
29140
|
+
items:
|
|
29141
|
+
type: string
|
|
29142
|
+
minLength: 1
|
|
29143
|
+
maxLength: 128
|
|
29144
|
+
tasks:
|
|
29145
|
+
type: array
|
|
29146
|
+
items:
|
|
29147
|
+
type: string
|
|
29148
|
+
minLength: 1
|
|
29149
|
+
maxLength: 128
|
|
29150
|
+
tone:
|
|
29151
|
+
type: string
|
|
29152
|
+
minLength: 1
|
|
29153
|
+
maxLength: 64
|
|
29154
|
+
google_connected:
|
|
29155
|
+
type: boolean
|
|
29156
|
+
google_scopes:
|
|
29157
|
+
type: array
|
|
29158
|
+
items:
|
|
29159
|
+
type: string
|
|
29160
|
+
minLength: 1
|
|
29161
|
+
maxLength: 256
|
|
29162
|
+
ab_variant:
|
|
29163
|
+
type: string
|
|
29164
|
+
minLength: 1
|
|
29165
|
+
maxLength: 64
|
|
29166
|
+
session_id:
|
|
29167
|
+
type: string
|
|
29168
|
+
minLength: 1
|
|
29169
|
+
maxLength: 128
|
|
29170
|
+
step_name:
|
|
29171
|
+
type: string
|
|
29172
|
+
minLength: 1
|
|
29173
|
+
maxLength: 128
|
|
29174
|
+
step_index:
|
|
29175
|
+
type: integer
|
|
29176
|
+
minimum: 0
|
|
29177
|
+
maximum: 9007199254740991
|
|
29178
|
+
completed_at:
|
|
29179
|
+
type: string
|
|
29180
|
+
minLength: 1
|
|
29181
|
+
maxLength: 64
|
|
29182
|
+
funnel_version:
|
|
29183
|
+
type: string
|
|
29184
|
+
minLength: 1
|
|
29185
|
+
maxLength: 128
|
|
29186
|
+
user_id:
|
|
29187
|
+
anyOf:
|
|
29188
|
+
- type: string
|
|
29189
|
+
minLength: 1
|
|
29190
|
+
maxLength: 64
|
|
29191
|
+
- type: "null"
|
|
29192
|
+
outcome:
|
|
29193
|
+
type: string
|
|
29194
|
+
minLength: 1
|
|
29195
|
+
maxLength: 32
|
|
29196
|
+
description:
|
|
29197
|
+
Wire event fields, excluding the daemon-stamped base fields (type, daemon_event_id, recorded_at,
|
|
29198
|
+
assistant_version).
|
|
29199
|
+
daemon_event_id:
|
|
29200
|
+
description:
|
|
29201
|
+
"Optional collapse key: rows sharing an id collapse downstream (e.g. a retried report). Defaults to a fresh
|
|
29202
|
+
per-row id."
|
|
29203
|
+
type: string
|
|
29204
|
+
minLength: 1
|
|
29205
|
+
maxLength: 128
|
|
29206
|
+
required:
|
|
29207
|
+
- type
|
|
29208
|
+
- fields
|
|
29209
|
+
- type: object
|
|
29210
|
+
properties:
|
|
29211
|
+
type:
|
|
29212
|
+
type: string
|
|
29213
|
+
const: auth_fallback
|
|
29214
|
+
fields:
|
|
29215
|
+
type: object
|
|
29216
|
+
properties:
|
|
29217
|
+
guard:
|
|
29218
|
+
type: string
|
|
29219
|
+
minLength: 1
|
|
29220
|
+
maxLength: 64
|
|
29221
|
+
failure_kind:
|
|
29222
|
+
type: string
|
|
29223
|
+
minLength: 1
|
|
29224
|
+
maxLength: 64
|
|
29225
|
+
path:
|
|
29226
|
+
type: string
|
|
29227
|
+
minLength: 1
|
|
29228
|
+
maxLength: 2048
|
|
29229
|
+
count:
|
|
29230
|
+
type: integer
|
|
29231
|
+
minimum: 0
|
|
29232
|
+
maximum: 9007199254740991
|
|
29233
|
+
window_start:
|
|
29234
|
+
type: integer
|
|
29235
|
+
minimum: 0
|
|
29236
|
+
maximum: 9007199254740991
|
|
29237
|
+
window_end:
|
|
29238
|
+
type: integer
|
|
29239
|
+
minimum: 0
|
|
29240
|
+
maximum: 9007199254740991
|
|
29241
|
+
required:
|
|
29242
|
+
- guard
|
|
29243
|
+
- failure_kind
|
|
29244
|
+
- path
|
|
29245
|
+
- count
|
|
29246
|
+
- window_start
|
|
29247
|
+
- window_end
|
|
29248
|
+
description:
|
|
29249
|
+
Wire event fields, excluding the daemon-stamped base fields (type, daemon_event_id, recorded_at,
|
|
29250
|
+
assistant_version).
|
|
29251
|
+
daemon_event_id:
|
|
29252
|
+
description:
|
|
29253
|
+
"Optional collapse key: rows sharing an id collapse downstream (e.g. a retried report). Defaults to a fresh
|
|
29254
|
+
per-row id."
|
|
29255
|
+
type: string
|
|
29256
|
+
minLength: 1
|
|
29257
|
+
maxLength: 128
|
|
29258
|
+
required:
|
|
29259
|
+
- type
|
|
29260
|
+
- fields
|
|
29261
|
+
- type: object
|
|
29262
|
+
properties:
|
|
29263
|
+
type:
|
|
29264
|
+
type: string
|
|
29265
|
+
const: skill_loaded
|
|
29266
|
+
fields:
|
|
29267
|
+
type: object
|
|
29268
|
+
properties:
|
|
29269
|
+
provider:
|
|
29270
|
+
anyOf:
|
|
29271
|
+
- type: string
|
|
29272
|
+
minLength: 1
|
|
29273
|
+
maxLength: 64
|
|
29274
|
+
- type: "null"
|
|
29275
|
+
model:
|
|
29276
|
+
anyOf:
|
|
29277
|
+
- type: string
|
|
29278
|
+
minLength: 1
|
|
29279
|
+
maxLength: 128
|
|
29280
|
+
- type: "null"
|
|
29281
|
+
inference_profile:
|
|
29282
|
+
anyOf:
|
|
29283
|
+
- type: string
|
|
29284
|
+
minLength: 1
|
|
29285
|
+
maxLength: 255
|
|
29286
|
+
- type: "null"
|
|
29287
|
+
inference_profile_source:
|
|
29288
|
+
anyOf:
|
|
29289
|
+
- type: string
|
|
29290
|
+
minLength: 1
|
|
29291
|
+
maxLength: 255
|
|
29292
|
+
- type: "null"
|
|
29293
|
+
skill_name:
|
|
29294
|
+
type: string
|
|
29295
|
+
minLength: 1
|
|
29296
|
+
maxLength: 255
|
|
29297
|
+
skill_updated_at:
|
|
29298
|
+
anyOf:
|
|
29299
|
+
- type: string
|
|
29300
|
+
minLength: 1
|
|
29301
|
+
maxLength: 64
|
|
29302
|
+
- type: "null"
|
|
29303
|
+
conversation_id:
|
|
29304
|
+
anyOf:
|
|
29305
|
+
- type: string
|
|
29306
|
+
minLength: 1
|
|
29307
|
+
maxLength: 128
|
|
29308
|
+
- type: "null"
|
|
29309
|
+
required:
|
|
29310
|
+
- skill_name
|
|
29311
|
+
description:
|
|
29312
|
+
Wire event fields, excluding the daemon-stamped base fields (type, daemon_event_id, recorded_at,
|
|
29313
|
+
assistant_version).
|
|
29314
|
+
daemon_event_id:
|
|
29315
|
+
description:
|
|
29316
|
+
"Optional collapse key: rows sharing an id collapse downstream (e.g. a retried report). Defaults to a fresh
|
|
29317
|
+
per-row id."
|
|
29318
|
+
type: string
|
|
29319
|
+
minLength: 1
|
|
29320
|
+
maxLength: 128
|
|
29321
|
+
required:
|
|
29322
|
+
- type
|
|
29323
|
+
- fields
|
|
29324
|
+
- type: object
|
|
29325
|
+
properties:
|
|
29326
|
+
type:
|
|
29327
|
+
type: string
|
|
29328
|
+
const: watchdog
|
|
29329
|
+
fields:
|
|
29330
|
+
type: object
|
|
29331
|
+
properties:
|
|
29332
|
+
check_name:
|
|
29333
|
+
type: string
|
|
29334
|
+
minLength: 1
|
|
29335
|
+
maxLength: 128
|
|
29336
|
+
value:
|
|
29337
|
+
anyOf:
|
|
29338
|
+
- type: number
|
|
29339
|
+
- type: "null"
|
|
29340
|
+
detail:
|
|
29341
|
+
anyOf:
|
|
29342
|
+
- $ref: "#/components/schemas/TelemetryJsonValue"
|
|
29343
|
+
- type: "null"
|
|
29344
|
+
required:
|
|
29345
|
+
- check_name
|
|
29346
|
+
description:
|
|
29347
|
+
Wire event fields, excluding the daemon-stamped base fields (type, daemon_event_id, recorded_at,
|
|
29348
|
+
assistant_version).
|
|
29349
|
+
daemon_event_id:
|
|
29350
|
+
description:
|
|
29351
|
+
"Optional collapse key: rows sharing an id collapse downstream (e.g. a retried report). Defaults to a fresh
|
|
29352
|
+
per-row id."
|
|
29353
|
+
type: string
|
|
29354
|
+
minLength: 1
|
|
29355
|
+
maxLength: 128
|
|
29356
|
+
required:
|
|
29357
|
+
- type
|
|
29358
|
+
- fields
|
|
29359
|
+
- type: object
|
|
29360
|
+
properties:
|
|
29361
|
+
type:
|
|
29362
|
+
type: string
|
|
29363
|
+
const: config_setting
|
|
29364
|
+
fields:
|
|
29365
|
+
type: object
|
|
29366
|
+
properties:
|
|
29367
|
+
config_key:
|
|
29368
|
+
type: string
|
|
29369
|
+
minLength: 1
|
|
29370
|
+
maxLength: 128
|
|
29371
|
+
config_value:
|
|
29372
|
+
type: string
|
|
29373
|
+
minLength: 1
|
|
29374
|
+
maxLength: 256
|
|
29375
|
+
required:
|
|
29376
|
+
- config_key
|
|
29377
|
+
- config_value
|
|
29378
|
+
description:
|
|
29379
|
+
Wire event fields, excluding the daemon-stamped base fields (type, daemon_event_id, recorded_at,
|
|
29380
|
+
assistant_version).
|
|
29381
|
+
daemon_event_id:
|
|
29382
|
+
description:
|
|
29383
|
+
"Optional collapse key: rows sharing an id collapse downstream (e.g. a retried report). Defaults to a fresh
|
|
29384
|
+
per-row id."
|
|
29385
|
+
type: string
|
|
29386
|
+
minLength: 1
|
|
29387
|
+
maxLength: 128
|
|
29388
|
+
required:
|
|
29389
|
+
- type
|
|
29390
|
+
- fields
|
|
29391
|
+
- type: object
|
|
29392
|
+
properties:
|
|
29393
|
+
type:
|
|
29394
|
+
type: string
|
|
29395
|
+
const: onboarding_research
|
|
29396
|
+
fields:
|
|
29397
|
+
type: object
|
|
29398
|
+
properties:
|
|
29399
|
+
conversation_id:
|
|
29400
|
+
anyOf:
|
|
29401
|
+
- type: string
|
|
29402
|
+
minLength: 1
|
|
29403
|
+
maxLength: 64
|
|
29404
|
+
- type: "null"
|
|
29405
|
+
status:
|
|
29406
|
+
type: string
|
|
29407
|
+
minLength: 1
|
|
29408
|
+
maxLength: 32
|
|
29409
|
+
self_reported_occupation:
|
|
29410
|
+
anyOf:
|
|
29411
|
+
- type: string
|
|
29412
|
+
maxLength: 256
|
|
29413
|
+
- type: "null"
|
|
29414
|
+
self_reported_hobbies:
|
|
29415
|
+
maxItems: 32
|
|
29416
|
+
type: array
|
|
29417
|
+
items:
|
|
29418
|
+
type: string
|
|
29419
|
+
minLength: 1
|
|
29420
|
+
maxLength: 128
|
|
29421
|
+
self_reported_timezone:
|
|
29422
|
+
anyOf:
|
|
29423
|
+
- type: string
|
|
29424
|
+
maxLength: 64
|
|
29425
|
+
- type: "null"
|
|
29426
|
+
claims:
|
|
29427
|
+
maxItems: 20
|
|
29428
|
+
type: array
|
|
29429
|
+
items:
|
|
29430
|
+
$ref: "#/components/schemas/TelemetryJsonValue"
|
|
29431
|
+
claim_count:
|
|
29432
|
+
type: integer
|
|
29433
|
+
minimum: 0
|
|
29434
|
+
maximum: 9007199254740991
|
|
29435
|
+
claims_confident:
|
|
29436
|
+
type: integer
|
|
29437
|
+
minimum: 0
|
|
29438
|
+
maximum: 9007199254740991
|
|
29439
|
+
claims_maybe:
|
|
29440
|
+
type: integer
|
|
29441
|
+
minimum: 0
|
|
29442
|
+
maximum: 9007199254740991
|
|
29443
|
+
claims_guessing:
|
|
29444
|
+
type: integer
|
|
29445
|
+
minimum: 0
|
|
29446
|
+
maximum: 9007199254740991
|
|
29447
|
+
suggestions:
|
|
29448
|
+
maxItems: 20
|
|
29449
|
+
type: array
|
|
29450
|
+
items:
|
|
29451
|
+
$ref: "#/components/schemas/TelemetryJsonValue"
|
|
29452
|
+
suggestion_count:
|
|
29453
|
+
type: integer
|
|
29454
|
+
minimum: 0
|
|
29455
|
+
maximum: 9007199254740991
|
|
29456
|
+
plugins:
|
|
29457
|
+
maxItems: 20
|
|
29458
|
+
type: array
|
|
29459
|
+
items:
|
|
29460
|
+
type: string
|
|
29461
|
+
minLength: 1
|
|
29462
|
+
maxLength: 128
|
|
29463
|
+
installed_plugins:
|
|
29464
|
+
maxItems: 20
|
|
29465
|
+
type: array
|
|
29466
|
+
items:
|
|
29467
|
+
type: string
|
|
29468
|
+
minLength: 1
|
|
29469
|
+
maxLength: 128
|
|
29470
|
+
required:
|
|
29471
|
+
- status
|
|
29472
|
+
- claims
|
|
29473
|
+
- claim_count
|
|
29474
|
+
- claims_confident
|
|
29475
|
+
- claims_maybe
|
|
29476
|
+
- claims_guessing
|
|
29477
|
+
- suggestions
|
|
29478
|
+
- suggestion_count
|
|
29479
|
+
- plugins
|
|
29480
|
+
- installed_plugins
|
|
29481
|
+
description:
|
|
29482
|
+
Wire event fields, excluding the daemon-stamped base fields (type, daemon_event_id, recorded_at,
|
|
29483
|
+
assistant_version).
|
|
29484
|
+
daemon_event_id:
|
|
29485
|
+
description:
|
|
29486
|
+
"Optional collapse key: rows sharing an id collapse downstream (e.g. a retried report). Defaults to a fresh
|
|
29487
|
+
per-row id."
|
|
29488
|
+
type: string
|
|
29489
|
+
minLength: 1
|
|
29490
|
+
maxLength: 128
|
|
29491
|
+
required:
|
|
29492
|
+
- type
|
|
29493
|
+
- fields
|
|
29098
29494
|
type: object
|
|
29099
|
-
properties:
|
|
29100
|
-
type:
|
|
29101
|
-
type: string
|
|
29102
|
-
description: Wire event type; must be a client-reportable telemetry event.
|
|
29103
|
-
fields:
|
|
29104
|
-
type: object
|
|
29105
|
-
propertyNames:
|
|
29106
|
-
type: string
|
|
29107
|
-
additionalProperties: {}
|
|
29108
|
-
description:
|
|
29109
|
-
Wire event fields, excluding the daemon-stamped base fields (type, daemon_event_id, recorded_at,
|
|
29110
|
-
assistant_version).
|
|
29111
|
-
daemon_event_id:
|
|
29112
|
-
description:
|
|
29113
|
-
"Optional collapse key: rows sharing an id collapse downstream (e.g. a retried report). Defaults to a fresh
|
|
29114
|
-
per-row id."
|
|
29115
|
-
type: string
|
|
29116
|
-
minLength: 1
|
|
29117
|
-
maxLength: 128
|
|
29118
|
-
required:
|
|
29119
|
-
- type
|
|
29120
|
-
- fields
|
|
29121
29495
|
responses:
|
|
29122
29496
|
"200":
|
|
29123
29497
|
description: Successful response
|
|
@@ -32039,6 +32413,20 @@ components:
|
|
|
32039
32413
|
minLength: 1
|
|
32040
32414
|
required:
|
|
32041
32415
|
- id
|
|
32416
|
+
TelemetryJsonValue:
|
|
32417
|
+
anyOf:
|
|
32418
|
+
- type: string
|
|
32419
|
+
- type: number
|
|
32420
|
+
- type: boolean
|
|
32421
|
+
- type: "null"
|
|
32422
|
+
- type: array
|
|
32423
|
+
items:
|
|
32424
|
+
$ref: "#/components/schemas/TelemetryJsonValue"
|
|
32425
|
+
- type: object
|
|
32426
|
+
propertyNames:
|
|
32427
|
+
type: string
|
|
32428
|
+
additionalProperties:
|
|
32429
|
+
$ref: "#/components/schemas/TelemetryJsonValue"
|
|
32042
32430
|
ConfigGetResponse:
|
|
32043
32431
|
type: object
|
|
32044
32432
|
properties:
|
package/package.json
CHANGED
|
@@ -30,6 +30,14 @@ import type {
|
|
|
30
30
|
} from "zod-openapi";
|
|
31
31
|
import { createDocument } from "zod-openapi";
|
|
32
32
|
|
|
33
|
+
import { jsonValueSchema } from "../src/telemetry/telemetry-wire.generated.js";
|
|
34
|
+
|
|
35
|
+
// The recursive wire JSON-value schema (`claims`/`suggestions` item type) must
|
|
36
|
+
// be hoisted into a named component so it can `$ref` itself; without a
|
|
37
|
+
// registered id zod-openapi falls back to an anonymous `__schema0`. Name it
|
|
38
|
+
// explicitly so the spec + generated SDK read as `TelemetryJsonValue`.
|
|
39
|
+
z.globalRegistry.add(jsonValueSchema, { id: "TelemetryJsonValue" });
|
|
40
|
+
|
|
33
41
|
const ROOT = resolve(import.meta.dir, "..");
|
|
34
42
|
const ROUTES_DIR = join(ROOT, "src/runtime/routes");
|
|
35
43
|
const PLUGIN_DEFAULTS_DIR = join(ROOT, "src/plugins/defaults");
|