@voltro/ai 0.85.0 → 0.86.0

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.
Files changed (60) hide show
  1. package/CHANGELOG.md +666 -0
  2. package/THIRD-PARTY-NOTICES.md +5 -33
  3. package/dist/agent.js +64 -2
  4. package/dist/agentConstants.js +4 -0
  5. package/dist/agentExecutor.js +51 -0
  6. package/dist/api.js +199 -0
  7. package/dist/appTools.js +80 -0
  8. package/dist/budget.js +201 -0
  9. package/dist/callEvidence.js +51 -0
  10. package/dist/copilot.js +126 -0
  11. package/dist/cost.js +242 -0
  12. package/dist/embed.js +41 -0
  13. package/dist/embeddingProvider.js +51 -0
  14. package/dist/eval.js +130 -0
  15. package/dist/events.d.ts +4 -0
  16. package/dist/events.js +81 -2
  17. package/dist/executableModalities.js +13 -0
  18. package/dist/gateway.js +58 -0
  19. package/dist/gatewayCatalog.js +47 -0
  20. package/dist/gatewayMedia.js +88 -0
  21. package/dist/index.d.ts +11 -0
  22. package/dist/index.js +42 -2750
  23. package/dist/inferenceDispatch.js +493 -0
  24. package/dist/inferenceQueue.js +96 -0
  25. package/dist/jsonOutputValidation.js +27 -0
  26. package/dist/mcpClient.js +332 -0
  27. package/dist/mcpTools.js +80 -0
  28. package/dist/media.js +182 -0
  29. package/dist/mediaBytes.js +19 -0
  30. package/dist/mediaCall.js +13 -0
  31. package/dist/mediaTaskProvider.js +16 -0
  32. package/dist/middleware.js +32 -0
  33. package/dist/observe.js +52 -0
  34. package/dist/prompts.js +103 -0
  35. package/dist/provider.js +303 -0
  36. package/dist/realtimeEvent.js +97 -0
  37. package/dist/realtimeSession.js +154 -0
  38. package/dist/rerank.js +61 -0
  39. package/dist/resumableStream.js +321 -0
  40. package/dist/retrieveReranked.js +16 -0
  41. package/dist/runAndPersist.js +148 -0
  42. package/dist/semanticCache.js +66 -0
  43. package/dist/speechProvider.js +16 -0
  44. package/dist/streamRegistry.js +14 -0
  45. package/dist/streamText.js +170 -0
  46. package/dist/streamTranscribe.js +74 -0
  47. package/dist/streamWakeups.js +44 -0
  48. package/dist/structuredEvidence.js +48 -0
  49. package/dist/test.js +1 -1
  50. package/dist/threads.js +92 -0
  51. package/dist/tools.js +68 -0
  52. package/dist/transcribe.js +64 -0
  53. package/dist/transcriptionEvent.js +46 -0
  54. package/dist/workflow.d.ts +2 -0
  55. package/dist/workflow.js +115 -110
  56. package/package.json +5 -5
  57. package/dist/agentDescriptor-DhoiXVqO.js +0 -63
  58. package/dist/agentEvent-Bl4egdM5.js +0 -211
  59. package/dist/inferenceQueue-DcEulZep.js +0 -1077
  60. package/dist/provider-BnemgE4D.js +0 -409
@@ -1,211 +0,0 @@
1
- import { Schema as e } from "effect";
2
- //#region src/transcriptionEvent.ts
3
- var t = class extends e.TaggedError()("TranscriptionStreamError", {
4
- reason: e.Literals([
5
- "input",
6
- "unsupported",
7
- "provider",
8
- "cancelled"
9
- ]),
10
- message: e.String
11
- }) {}, n = e.Struct({
12
- text: e.String,
13
- start: e.Number,
14
- end: e.Number
15
- }), r = { id: e.optional(e.String) }, i = e.Union([
16
- e.Struct({
17
- type: e.Literal("transcript-delta"),
18
- ...r,
19
- delta: e.String
20
- }),
21
- e.Struct({
22
- type: e.Literal("transcript-partial"),
23
- ...r,
24
- text: e.String,
25
- startSecond: e.optional(e.Number),
26
- durationInSeconds: e.optional(e.Number),
27
- channelIndex: e.optional(e.Number)
28
- }),
29
- e.Struct({
30
- type: e.Literal("transcript-final"),
31
- ...r,
32
- text: e.String,
33
- startSecond: e.optional(e.Number),
34
- endSecond: e.optional(e.Number),
35
- channelIndex: e.optional(e.Number)
36
- }),
37
- e.Struct({
38
- type: e.Literal("finish"),
39
- text: e.String,
40
- segments: e.Array(n),
41
- language: e.optional(e.String),
42
- durationSec: e.optional(e.Number)
43
- })
44
- ]), a = e.String.pipe(e.check(e.isPattern(/^(?:[A-Za-z0-9+/]{4})*(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=)?$/))), o = e.Number.pipe(e.check(e.isFinite()), e.check(e.isGreaterThanOrEqualTo(0))), s = e.Union([
45
- e.Struct({
46
- type: e.Literal("input-audio-append"),
47
- audio: a
48
- }),
49
- e.Struct({ type: e.Literals([
50
- "input-audio-commit",
51
- "input-audio-clear",
52
- "response-create",
53
- "response-cancel"
54
- ]) }),
55
- e.Struct({
56
- type: e.Literal("conversation-item-create"),
57
- item: e.Struct({
58
- type: e.Literal("text-message"),
59
- role: e.Literal("user"),
60
- text: e.String
61
- })
62
- }),
63
- e.Struct({
64
- type: e.Literal("conversation-item-truncate"),
65
- itemId: e.String,
66
- contentIndex: o.pipe(e.check(e.isInt())),
67
- audioEndMs: o
68
- })
69
- ]), c = { itemId: e.String }, l = {
70
- responseId: e.String,
71
- ...c
72
- }, u = e.Union([
73
- e.Struct({ type: e.Literal("ready") }),
74
- e.Struct({
75
- type: e.Literal("session-created"),
76
- sessionId: e.optional(e.String)
77
- }),
78
- e.Struct({ type: e.Literal("session-updated") }),
79
- e.Struct({
80
- type: e.Literals(["speech-started", "speech-stopped"]),
81
- itemId: e.optional(e.String)
82
- }),
83
- e.Struct({
84
- type: e.Literal("audio-committed"),
85
- itemId: e.optional(e.String),
86
- previousItemId: e.optional(e.String)
87
- }),
88
- e.Struct({
89
- type: e.Literal("conversation-item-added"),
90
- ...c
91
- }),
92
- e.Struct({
93
- type: e.Literal("input-transcription-completed"),
94
- ...c,
95
- transcript: e.String
96
- }),
97
- e.Struct({
98
- type: e.Literal("response-created"),
99
- responseId: e.String
100
- }),
101
- e.Struct({
102
- type: e.Literal("response-done"),
103
- responseId: e.String,
104
- status: e.String
105
- }),
106
- e.Struct({
107
- type: e.Literals([
108
- "output-item-added",
109
- "output-item-done",
110
- "content-part-added",
111
- "content-part-done",
112
- "audio-done"
113
- ]),
114
- ...l
115
- }),
116
- e.Struct({
117
- type: e.Literal("audio-delta"),
118
- ...l,
119
- delta: a
120
- }),
121
- e.Struct({
122
- type: e.Literals(["text-delta", "audio-transcript-delta"]),
123
- ...l,
124
- delta: e.String
125
- }),
126
- e.Struct({
127
- type: e.Literal("text-done"),
128
- ...l,
129
- text: e.optional(e.String)
130
- }),
131
- e.Struct({
132
- type: e.Literal("audio-transcript-done"),
133
- ...l,
134
- transcript: e.optional(e.String)
135
- })
136
- ]), d = e.Literals([
137
- "provider",
138
- "tool",
139
- "timeout",
140
- "cancelled",
141
- "decode",
142
- "internal"
143
- ]), f = e.Struct({
144
- inputTokens: e.optional(e.Number),
145
- outputTokens: e.optional(e.Number),
146
- totalTokens: e.optional(e.Number)
147
- }), p = e.Union([
148
- e.Struct({
149
- _tag: e.Literal("token"),
150
- text: e.String
151
- }),
152
- e.Struct({
153
- _tag: e.Literal("reasoning"),
154
- text: e.String
155
- }),
156
- e.Struct({
157
- _tag: e.Literal("toolCall"),
158
- id: e.String,
159
- name: e.String,
160
- input: e.Unknown
161
- }),
162
- e.Struct({
163
- _tag: e.Literal("toolResult"),
164
- id: e.String,
165
- name: e.String,
166
- output: e.optional(e.Unknown),
167
- error: e.optional(e.String)
168
- }),
169
- e.Struct({
170
- _tag: e.Literal("source"),
171
- sourceType: e.Literals(["url", "document"]),
172
- id: e.String,
173
- url: e.optional(e.String),
174
- title: e.optional(e.String),
175
- mediaType: e.optional(e.String),
176
- filename: e.optional(e.String),
177
- providerMetadata: e.optional(e.Unknown)
178
- }),
179
- e.Struct({
180
- _tag: e.Literal("file"),
181
- mediaType: e.String,
182
- data: e.String,
183
- providerMetadata: e.optional(e.Unknown)
184
- }),
185
- e.Struct({
186
- _tag: e.Literal("stepMetadata"),
187
- step: e.Int.pipe(e.check(e.isGreaterThanOrEqualTo(0))),
188
- providerMetadata: e.Unknown
189
- }),
190
- e.Struct({
191
- _tag: e.Literal("message"),
192
- role: e.String,
193
- content: e.String
194
- }),
195
- e.Struct({
196
- _tag: e.Literal("error"),
197
- code: d,
198
- message: e.String,
199
- retryable: e.Boolean
200
- }),
201
- e.Struct({
202
- _tag: e.Literal("done"),
203
- finishReason: e.String,
204
- usage: f
205
- })
206
- ]), m = e.Struct({
207
- seq: e.Number,
208
- event: p
209
- });
210
- //#endregion
211
- export { u as a, s as i, p as n, t as o, m as r, i as s, d as t };