@harny/vercel-ai-provider 0.0.0-stage → 0.1.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.
@@ -0,0 +1,676 @@
1
+ import type { HarnyClient } from './client.js';
2
+ import type { RecallLevel } from './types.js';
3
+ export interface ToolSettings {
4
+ /** The end user the tools act for. Defaults to the `user` given to createHarny. */
5
+ user?: string;
6
+ /** Evidence size for harny_recall. Default 'low'. */
7
+ level?: RecallLevel;
8
+ /** Most results harny_recall returns. Default 10. */
9
+ limit?: number;
10
+ }
11
+ /**
12
+ * Two tools to put in a tool set: `harny_remember` stores a fact or preference, `harny_recall` looks something up.
13
+ * The person is fixed by you (settings or createHarny), never chosen by the model.
14
+ */
15
+ export declare function createTools(client: HarnyClient, settings?: ToolSettings): {
16
+ harny_remember: ({
17
+ deferLoading?: boolean;
18
+ title?: string;
19
+ providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
20
+ metadata?: import("@ai-sdk/provider").JSONObject;
21
+ inputSchema: import("ai").FlexibleSchema<{
22
+ content: string;
23
+ label?: string;
24
+ id?: string;
25
+ timestamp?: string;
26
+ }>;
27
+ contextSchema?: import("ai").FlexibleSchema<import("@ai-sdk/provider-utils").Context> | undefined;
28
+ needsApproval?: boolean | import("@ai-sdk/provider-utils").ToolNeedsApprovalFunction<{
29
+ content: string;
30
+ label?: string;
31
+ id?: string;
32
+ timestamp?: string;
33
+ }, NoInfer<import("@ai-sdk/provider-utils").Context>> | undefined;
34
+ onInputStart?: ((options: import("ai").ToolExecutionOptions<NoInfer<import("@ai-sdk/provider-utils").Context>>) => void | PromiseLike<void>) | undefined;
35
+ onInputDelta?: ((options: {
36
+ inputTextDelta: string;
37
+ } & import("ai").ToolExecutionOptions<NoInfer<import("@ai-sdk/provider-utils").Context>>) => void | PromiseLike<void>) | undefined;
38
+ onInputAvailable?: ((options: {
39
+ input: {
40
+ content: string;
41
+ label?: string;
42
+ id?: string;
43
+ timestamp?: string;
44
+ };
45
+ } & import("ai").ToolExecutionOptions<NoInfer<import("@ai-sdk/provider-utils").Context>>) => void | PromiseLike<void>) | undefined;
46
+ toModelOutput?: ((options: {
47
+ toolCallId: string;
48
+ input: {
49
+ content: string;
50
+ label?: string;
51
+ id?: string;
52
+ timestamp?: string;
53
+ };
54
+ output: NoInfer<{
55
+ status: "queued" | "completed";
56
+ ingestionId: string;
57
+ sourceId: string;
58
+ }>;
59
+ }) => import("@ai-sdk/provider-utils").ToolResultOutput | PromiseLike<import("@ai-sdk/provider-utils").ToolResultOutput>) | undefined;
60
+ } & {
61
+ outputSchema?: import("ai").FlexibleSchema<{
62
+ status: "queued" | "completed";
63
+ ingestionId: string;
64
+ sourceId: string;
65
+ }> | undefined;
66
+ execute: import("ai").ToolExecuteFunction<{
67
+ content: string;
68
+ label?: string;
69
+ id?: string;
70
+ timestamp?: string;
71
+ }, {
72
+ status: "queued" | "completed";
73
+ ingestionId: string;
74
+ sourceId: string;
75
+ }, NoInfer<import("@ai-sdk/provider-utils").Context>>;
76
+ } & {
77
+ description?: string | ((options: {
78
+ context: NoInfer<import("@ai-sdk/provider-utils").Context>;
79
+ experimental_sandbox?: import("ai").Experimental_SandboxSession;
80
+ }) => string) | undefined;
81
+ strict?: boolean;
82
+ inputExamples?: {
83
+ input: NoInfer<{
84
+ content: string;
85
+ label?: string;
86
+ id?: string;
87
+ timestamp?: string;
88
+ }>;
89
+ }[] | undefined;
90
+ id?: never;
91
+ isProviderExecuted?: never;
92
+ args?: never;
93
+ supportsDeferredResults?: never;
94
+ } & {
95
+ type?: undefined | "function";
96
+ } & {
97
+ execute: import("ai").ToolExecuteFunction<{
98
+ content: string;
99
+ label?: string;
100
+ id?: string;
101
+ timestamp?: string;
102
+ }, {
103
+ status: "queued" | "completed";
104
+ ingestionId: string;
105
+ sourceId: string;
106
+ }, NoInfer<import("@ai-sdk/provider-utils").Context>>;
107
+ }) | ({
108
+ deferLoading?: boolean;
109
+ title?: string;
110
+ providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
111
+ metadata?: import("@ai-sdk/provider").JSONObject;
112
+ inputSchema: import("ai").FlexibleSchema<{
113
+ content: string;
114
+ label?: string;
115
+ id?: string;
116
+ timestamp?: string;
117
+ }>;
118
+ contextSchema?: import("ai").FlexibleSchema<import("@ai-sdk/provider-utils").Context> | undefined;
119
+ needsApproval?: boolean | import("@ai-sdk/provider-utils").ToolNeedsApprovalFunction<{
120
+ content: string;
121
+ label?: string;
122
+ id?: string;
123
+ timestamp?: string;
124
+ }, NoInfer<import("@ai-sdk/provider-utils").Context>> | undefined;
125
+ onInputStart?: ((options: import("ai").ToolExecutionOptions<NoInfer<import("@ai-sdk/provider-utils").Context>>) => void | PromiseLike<void>) | undefined;
126
+ onInputDelta?: ((options: {
127
+ inputTextDelta: string;
128
+ } & import("ai").ToolExecutionOptions<NoInfer<import("@ai-sdk/provider-utils").Context>>) => void | PromiseLike<void>) | undefined;
129
+ onInputAvailable?: ((options: {
130
+ input: {
131
+ content: string;
132
+ label?: string;
133
+ id?: string;
134
+ timestamp?: string;
135
+ };
136
+ } & import("ai").ToolExecutionOptions<NoInfer<import("@ai-sdk/provider-utils").Context>>) => void | PromiseLike<void>) | undefined;
137
+ toModelOutput?: ((options: {
138
+ toolCallId: string;
139
+ input: {
140
+ content: string;
141
+ label?: string;
142
+ id?: string;
143
+ timestamp?: string;
144
+ };
145
+ output: NoInfer<{
146
+ status: "queued" | "completed";
147
+ ingestionId: string;
148
+ sourceId: string;
149
+ }>;
150
+ }) => import("@ai-sdk/provider-utils").ToolResultOutput | PromiseLike<import("@ai-sdk/provider-utils").ToolResultOutput>) | undefined;
151
+ } & {
152
+ outputSchema?: import("ai").FlexibleSchema<{
153
+ status: "queued" | "completed";
154
+ ingestionId: string;
155
+ sourceId: string;
156
+ }> | undefined;
157
+ execute: import("ai").ToolExecuteFunction<{
158
+ content: string;
159
+ label?: string;
160
+ id?: string;
161
+ timestamp?: string;
162
+ }, {
163
+ status: "queued" | "completed";
164
+ ingestionId: string;
165
+ sourceId: string;
166
+ }, NoInfer<import("@ai-sdk/provider-utils").Context>>;
167
+ } & {
168
+ description?: string | ((options: {
169
+ context: NoInfer<import("@ai-sdk/provider-utils").Context>;
170
+ experimental_sandbox?: import("ai").Experimental_SandboxSession;
171
+ }) => string) | undefined;
172
+ strict?: boolean;
173
+ inputExamples?: {
174
+ input: NoInfer<{
175
+ content: string;
176
+ label?: string;
177
+ id?: string;
178
+ timestamp?: string;
179
+ }>;
180
+ }[] | undefined;
181
+ id?: never;
182
+ isProviderExecuted?: never;
183
+ args?: never;
184
+ supportsDeferredResults?: never;
185
+ } & {
186
+ type: "dynamic";
187
+ } & {
188
+ execute: import("ai").ToolExecuteFunction<{
189
+ content: string;
190
+ label?: string;
191
+ id?: string;
192
+ timestamp?: string;
193
+ }, {
194
+ status: "queued" | "completed";
195
+ ingestionId: string;
196
+ sourceId: string;
197
+ }, NoInfer<import("@ai-sdk/provider-utils").Context>>;
198
+ }) | ({
199
+ deferLoading?: boolean;
200
+ title?: string;
201
+ providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
202
+ metadata?: import("@ai-sdk/provider").JSONObject;
203
+ inputSchema: import("ai").FlexibleSchema<{
204
+ content: string;
205
+ label?: string;
206
+ id?: string;
207
+ timestamp?: string;
208
+ }>;
209
+ contextSchema?: import("ai").FlexibleSchema<import("@ai-sdk/provider-utils").Context> | undefined;
210
+ needsApproval?: boolean | import("@ai-sdk/provider-utils").ToolNeedsApprovalFunction<{
211
+ content: string;
212
+ label?: string;
213
+ id?: string;
214
+ timestamp?: string;
215
+ }, NoInfer<import("@ai-sdk/provider-utils").Context>> | undefined;
216
+ onInputStart?: ((options: import("ai").ToolExecutionOptions<NoInfer<import("@ai-sdk/provider-utils").Context>>) => void | PromiseLike<void>) | undefined;
217
+ onInputDelta?: ((options: {
218
+ inputTextDelta: string;
219
+ } & import("ai").ToolExecutionOptions<NoInfer<import("@ai-sdk/provider-utils").Context>>) => void | PromiseLike<void>) | undefined;
220
+ onInputAvailable?: ((options: {
221
+ input: {
222
+ content: string;
223
+ label?: string;
224
+ id?: string;
225
+ timestamp?: string;
226
+ };
227
+ } & import("ai").ToolExecutionOptions<NoInfer<import("@ai-sdk/provider-utils").Context>>) => void | PromiseLike<void>) | undefined;
228
+ toModelOutput?: ((options: {
229
+ toolCallId: string;
230
+ input: {
231
+ content: string;
232
+ label?: string;
233
+ id?: string;
234
+ timestamp?: string;
235
+ };
236
+ output: NoInfer<{
237
+ status: "queued" | "completed";
238
+ ingestionId: string;
239
+ sourceId: string;
240
+ }>;
241
+ }) => import("@ai-sdk/provider-utils").ToolResultOutput | PromiseLike<import("@ai-sdk/provider-utils").ToolResultOutput>) | undefined;
242
+ } & {
243
+ outputSchema?: import("ai").FlexibleSchema<{
244
+ status: "queued" | "completed";
245
+ ingestionId: string;
246
+ sourceId: string;
247
+ }> | undefined;
248
+ execute: import("ai").ToolExecuteFunction<{
249
+ content: string;
250
+ label?: string;
251
+ id?: string;
252
+ timestamp?: string;
253
+ }, {
254
+ status: "queued" | "completed";
255
+ ingestionId: string;
256
+ sourceId: string;
257
+ }, NoInfer<import("@ai-sdk/provider-utils").Context>>;
258
+ } & {
259
+ type: "provider";
260
+ id: `${string}.${string}`;
261
+ args: Record<string, unknown>;
262
+ description?: never;
263
+ strict?: never;
264
+ inputExamples?: never;
265
+ } & {
266
+ isProviderExecuted: false;
267
+ supportsDeferredResults?: never;
268
+ } & {
269
+ execute: import("ai").ToolExecuteFunction<{
270
+ content: string;
271
+ label?: string;
272
+ id?: string;
273
+ timestamp?: string;
274
+ }, {
275
+ status: "queued" | "completed";
276
+ ingestionId: string;
277
+ sourceId: string;
278
+ }, NoInfer<import("@ai-sdk/provider-utils").Context>>;
279
+ }) | ({
280
+ deferLoading?: boolean;
281
+ title?: string;
282
+ providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
283
+ metadata?: import("@ai-sdk/provider").JSONObject;
284
+ inputSchema: import("ai").FlexibleSchema<{
285
+ content: string;
286
+ label?: string;
287
+ id?: string;
288
+ timestamp?: string;
289
+ }>;
290
+ contextSchema?: import("ai").FlexibleSchema<import("@ai-sdk/provider-utils").Context> | undefined;
291
+ needsApproval?: boolean | import("@ai-sdk/provider-utils").ToolNeedsApprovalFunction<{
292
+ content: string;
293
+ label?: string;
294
+ id?: string;
295
+ timestamp?: string;
296
+ }, NoInfer<import("@ai-sdk/provider-utils").Context>> | undefined;
297
+ onInputStart?: ((options: import("ai").ToolExecutionOptions<NoInfer<import("@ai-sdk/provider-utils").Context>>) => void | PromiseLike<void>) | undefined;
298
+ onInputDelta?: ((options: {
299
+ inputTextDelta: string;
300
+ } & import("ai").ToolExecutionOptions<NoInfer<import("@ai-sdk/provider-utils").Context>>) => void | PromiseLike<void>) | undefined;
301
+ onInputAvailable?: ((options: {
302
+ input: {
303
+ content: string;
304
+ label?: string;
305
+ id?: string;
306
+ timestamp?: string;
307
+ };
308
+ } & import("ai").ToolExecutionOptions<NoInfer<import("@ai-sdk/provider-utils").Context>>) => void | PromiseLike<void>) | undefined;
309
+ toModelOutput?: ((options: {
310
+ toolCallId: string;
311
+ input: {
312
+ content: string;
313
+ label?: string;
314
+ id?: string;
315
+ timestamp?: string;
316
+ };
317
+ output: NoInfer<{
318
+ status: "queued" | "completed";
319
+ ingestionId: string;
320
+ sourceId: string;
321
+ }>;
322
+ }) => import("@ai-sdk/provider-utils").ToolResultOutput | PromiseLike<import("@ai-sdk/provider-utils").ToolResultOutput>) | undefined;
323
+ } & {
324
+ outputSchema?: import("ai").FlexibleSchema<{
325
+ status: "queued" | "completed";
326
+ ingestionId: string;
327
+ sourceId: string;
328
+ }> | undefined;
329
+ execute: import("ai").ToolExecuteFunction<{
330
+ content: string;
331
+ label?: string;
332
+ id?: string;
333
+ timestamp?: string;
334
+ }, {
335
+ status: "queued" | "completed";
336
+ ingestionId: string;
337
+ sourceId: string;
338
+ }, NoInfer<import("@ai-sdk/provider-utils").Context>>;
339
+ } & {
340
+ type: "provider";
341
+ id: `${string}.${string}`;
342
+ args: Record<string, unknown>;
343
+ description?: never;
344
+ strict?: never;
345
+ inputExamples?: never;
346
+ } & {
347
+ isProviderExecuted: true;
348
+ supportsDeferredResults?: boolean;
349
+ } & {
350
+ execute: import("ai").ToolExecuteFunction<{
351
+ content: string;
352
+ label?: string;
353
+ id?: string;
354
+ timestamp?: string;
355
+ }, {
356
+ status: "queued" | "completed";
357
+ ingestionId: string;
358
+ sourceId: string;
359
+ }, NoInfer<import("@ai-sdk/provider-utils").Context>>;
360
+ });
361
+ harny_recall: ({
362
+ deferLoading?: boolean;
363
+ title?: string;
364
+ providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
365
+ metadata?: import("@ai-sdk/provider").JSONObject;
366
+ inputSchema: import("ai").FlexibleSchema<{
367
+ query: string;
368
+ }>;
369
+ contextSchema?: import("ai").FlexibleSchema<import("@ai-sdk/provider-utils").Context> | undefined;
370
+ needsApproval?: boolean | import("@ai-sdk/provider-utils").ToolNeedsApprovalFunction<{
371
+ query: string;
372
+ }, NoInfer<import("@ai-sdk/provider-utils").Context>> | undefined;
373
+ onInputStart?: ((options: import("ai").ToolExecutionOptions<NoInfer<import("@ai-sdk/provider-utils").Context>>) => void | PromiseLike<void>) | undefined;
374
+ onInputDelta?: ((options: {
375
+ inputTextDelta: string;
376
+ } & import("ai").ToolExecutionOptions<NoInfer<import("@ai-sdk/provider-utils").Context>>) => void | PromiseLike<void>) | undefined;
377
+ onInputAvailable?: ((options: {
378
+ input: {
379
+ query: string;
380
+ };
381
+ } & import("ai").ToolExecutionOptions<NoInfer<import("@ai-sdk/provider-utils").Context>>) => void | PromiseLike<void>) | undefined;
382
+ toModelOutput?: ((options: {
383
+ toolCallId: string;
384
+ input: {
385
+ query: string;
386
+ };
387
+ output: NoInfer<{
388
+ pending?: string | undefined;
389
+ results: {
390
+ content: string;
391
+ occurredAt: string | null;
392
+ sourceIds: string[];
393
+ }[];
394
+ }>;
395
+ }) => import("@ai-sdk/provider-utils").ToolResultOutput | PromiseLike<import("@ai-sdk/provider-utils").ToolResultOutput>) | undefined;
396
+ } & {
397
+ outputSchema?: import("ai").FlexibleSchema<{
398
+ pending?: string | undefined;
399
+ results: {
400
+ content: string;
401
+ occurredAt: string | null;
402
+ sourceIds: string[];
403
+ }[];
404
+ }> | undefined;
405
+ execute: import("ai").ToolExecuteFunction<{
406
+ query: string;
407
+ }, {
408
+ pending?: string | undefined;
409
+ results: {
410
+ content: string;
411
+ occurredAt: string | null;
412
+ sourceIds: string[];
413
+ }[];
414
+ }, NoInfer<import("@ai-sdk/provider-utils").Context>>;
415
+ } & {
416
+ description?: string | ((options: {
417
+ context: NoInfer<import("@ai-sdk/provider-utils").Context>;
418
+ experimental_sandbox?: import("ai").Experimental_SandboxSession;
419
+ }) => string) | undefined;
420
+ strict?: boolean;
421
+ inputExamples?: {
422
+ input: NoInfer<{
423
+ query: string;
424
+ }>;
425
+ }[] | undefined;
426
+ id?: never;
427
+ isProviderExecuted?: never;
428
+ args?: never;
429
+ supportsDeferredResults?: never;
430
+ } & {
431
+ type?: undefined | "function";
432
+ } & {
433
+ execute: import("ai").ToolExecuteFunction<{
434
+ query: string;
435
+ }, {
436
+ pending?: string | undefined;
437
+ results: {
438
+ content: string;
439
+ occurredAt: string | null;
440
+ sourceIds: string[];
441
+ }[];
442
+ }, NoInfer<import("@ai-sdk/provider-utils").Context>>;
443
+ }) | ({
444
+ deferLoading?: boolean;
445
+ title?: string;
446
+ providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
447
+ metadata?: import("@ai-sdk/provider").JSONObject;
448
+ inputSchema: import("ai").FlexibleSchema<{
449
+ query: string;
450
+ }>;
451
+ contextSchema?: import("ai").FlexibleSchema<import("@ai-sdk/provider-utils").Context> | undefined;
452
+ needsApproval?: boolean | import("@ai-sdk/provider-utils").ToolNeedsApprovalFunction<{
453
+ query: string;
454
+ }, NoInfer<import("@ai-sdk/provider-utils").Context>> | undefined;
455
+ onInputStart?: ((options: import("ai").ToolExecutionOptions<NoInfer<import("@ai-sdk/provider-utils").Context>>) => void | PromiseLike<void>) | undefined;
456
+ onInputDelta?: ((options: {
457
+ inputTextDelta: string;
458
+ } & import("ai").ToolExecutionOptions<NoInfer<import("@ai-sdk/provider-utils").Context>>) => void | PromiseLike<void>) | undefined;
459
+ onInputAvailable?: ((options: {
460
+ input: {
461
+ query: string;
462
+ };
463
+ } & import("ai").ToolExecutionOptions<NoInfer<import("@ai-sdk/provider-utils").Context>>) => void | PromiseLike<void>) | undefined;
464
+ toModelOutput?: ((options: {
465
+ toolCallId: string;
466
+ input: {
467
+ query: string;
468
+ };
469
+ output: NoInfer<{
470
+ pending?: string | undefined;
471
+ results: {
472
+ content: string;
473
+ occurredAt: string | null;
474
+ sourceIds: string[];
475
+ }[];
476
+ }>;
477
+ }) => import("@ai-sdk/provider-utils").ToolResultOutput | PromiseLike<import("@ai-sdk/provider-utils").ToolResultOutput>) | undefined;
478
+ } & {
479
+ outputSchema?: import("ai").FlexibleSchema<{
480
+ pending?: string | undefined;
481
+ results: {
482
+ content: string;
483
+ occurredAt: string | null;
484
+ sourceIds: string[];
485
+ }[];
486
+ }> | undefined;
487
+ execute: import("ai").ToolExecuteFunction<{
488
+ query: string;
489
+ }, {
490
+ pending?: string | undefined;
491
+ results: {
492
+ content: string;
493
+ occurredAt: string | null;
494
+ sourceIds: string[];
495
+ }[];
496
+ }, NoInfer<import("@ai-sdk/provider-utils").Context>>;
497
+ } & {
498
+ description?: string | ((options: {
499
+ context: NoInfer<import("@ai-sdk/provider-utils").Context>;
500
+ experimental_sandbox?: import("ai").Experimental_SandboxSession;
501
+ }) => string) | undefined;
502
+ strict?: boolean;
503
+ inputExamples?: {
504
+ input: NoInfer<{
505
+ query: string;
506
+ }>;
507
+ }[] | undefined;
508
+ id?: never;
509
+ isProviderExecuted?: never;
510
+ args?: never;
511
+ supportsDeferredResults?: never;
512
+ } & {
513
+ type: "dynamic";
514
+ } & {
515
+ execute: import("ai").ToolExecuteFunction<{
516
+ query: string;
517
+ }, {
518
+ pending?: string | undefined;
519
+ results: {
520
+ content: string;
521
+ occurredAt: string | null;
522
+ sourceIds: string[];
523
+ }[];
524
+ }, NoInfer<import("@ai-sdk/provider-utils").Context>>;
525
+ }) | ({
526
+ deferLoading?: boolean;
527
+ title?: string;
528
+ providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
529
+ metadata?: import("@ai-sdk/provider").JSONObject;
530
+ inputSchema: import("ai").FlexibleSchema<{
531
+ query: string;
532
+ }>;
533
+ contextSchema?: import("ai").FlexibleSchema<import("@ai-sdk/provider-utils").Context> | undefined;
534
+ needsApproval?: boolean | import("@ai-sdk/provider-utils").ToolNeedsApprovalFunction<{
535
+ query: string;
536
+ }, NoInfer<import("@ai-sdk/provider-utils").Context>> | undefined;
537
+ onInputStart?: ((options: import("ai").ToolExecutionOptions<NoInfer<import("@ai-sdk/provider-utils").Context>>) => void | PromiseLike<void>) | undefined;
538
+ onInputDelta?: ((options: {
539
+ inputTextDelta: string;
540
+ } & import("ai").ToolExecutionOptions<NoInfer<import("@ai-sdk/provider-utils").Context>>) => void | PromiseLike<void>) | undefined;
541
+ onInputAvailable?: ((options: {
542
+ input: {
543
+ query: string;
544
+ };
545
+ } & import("ai").ToolExecutionOptions<NoInfer<import("@ai-sdk/provider-utils").Context>>) => void | PromiseLike<void>) | undefined;
546
+ toModelOutput?: ((options: {
547
+ toolCallId: string;
548
+ input: {
549
+ query: string;
550
+ };
551
+ output: NoInfer<{
552
+ pending?: string | undefined;
553
+ results: {
554
+ content: string;
555
+ occurredAt: string | null;
556
+ sourceIds: string[];
557
+ }[];
558
+ }>;
559
+ }) => import("@ai-sdk/provider-utils").ToolResultOutput | PromiseLike<import("@ai-sdk/provider-utils").ToolResultOutput>) | undefined;
560
+ } & {
561
+ outputSchema?: import("ai").FlexibleSchema<{
562
+ pending?: string | undefined;
563
+ results: {
564
+ content: string;
565
+ occurredAt: string | null;
566
+ sourceIds: string[];
567
+ }[];
568
+ }> | undefined;
569
+ execute: import("ai").ToolExecuteFunction<{
570
+ query: string;
571
+ }, {
572
+ pending?: string | undefined;
573
+ results: {
574
+ content: string;
575
+ occurredAt: string | null;
576
+ sourceIds: string[];
577
+ }[];
578
+ }, NoInfer<import("@ai-sdk/provider-utils").Context>>;
579
+ } & {
580
+ type: "provider";
581
+ id: `${string}.${string}`;
582
+ args: Record<string, unknown>;
583
+ description?: never;
584
+ strict?: never;
585
+ inputExamples?: never;
586
+ } & {
587
+ isProviderExecuted: false;
588
+ supportsDeferredResults?: never;
589
+ } & {
590
+ execute: import("ai").ToolExecuteFunction<{
591
+ query: string;
592
+ }, {
593
+ pending?: string | undefined;
594
+ results: {
595
+ content: string;
596
+ occurredAt: string | null;
597
+ sourceIds: string[];
598
+ }[];
599
+ }, NoInfer<import("@ai-sdk/provider-utils").Context>>;
600
+ }) | ({
601
+ deferLoading?: boolean;
602
+ title?: string;
603
+ providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
604
+ metadata?: import("@ai-sdk/provider").JSONObject;
605
+ inputSchema: import("ai").FlexibleSchema<{
606
+ query: string;
607
+ }>;
608
+ contextSchema?: import("ai").FlexibleSchema<import("@ai-sdk/provider-utils").Context> | undefined;
609
+ needsApproval?: boolean | import("@ai-sdk/provider-utils").ToolNeedsApprovalFunction<{
610
+ query: string;
611
+ }, NoInfer<import("@ai-sdk/provider-utils").Context>> | undefined;
612
+ onInputStart?: ((options: import("ai").ToolExecutionOptions<NoInfer<import("@ai-sdk/provider-utils").Context>>) => void | PromiseLike<void>) | undefined;
613
+ onInputDelta?: ((options: {
614
+ inputTextDelta: string;
615
+ } & import("ai").ToolExecutionOptions<NoInfer<import("@ai-sdk/provider-utils").Context>>) => void | PromiseLike<void>) | undefined;
616
+ onInputAvailable?: ((options: {
617
+ input: {
618
+ query: string;
619
+ };
620
+ } & import("ai").ToolExecutionOptions<NoInfer<import("@ai-sdk/provider-utils").Context>>) => void | PromiseLike<void>) | undefined;
621
+ toModelOutput?: ((options: {
622
+ toolCallId: string;
623
+ input: {
624
+ query: string;
625
+ };
626
+ output: NoInfer<{
627
+ pending?: string | undefined;
628
+ results: {
629
+ content: string;
630
+ occurredAt: string | null;
631
+ sourceIds: string[];
632
+ }[];
633
+ }>;
634
+ }) => import("@ai-sdk/provider-utils").ToolResultOutput | PromiseLike<import("@ai-sdk/provider-utils").ToolResultOutput>) | undefined;
635
+ } & {
636
+ outputSchema?: import("ai").FlexibleSchema<{
637
+ pending?: string | undefined;
638
+ results: {
639
+ content: string;
640
+ occurredAt: string | null;
641
+ sourceIds: string[];
642
+ }[];
643
+ }> | undefined;
644
+ execute: import("ai").ToolExecuteFunction<{
645
+ query: string;
646
+ }, {
647
+ pending?: string | undefined;
648
+ results: {
649
+ content: string;
650
+ occurredAt: string | null;
651
+ sourceIds: string[];
652
+ }[];
653
+ }, NoInfer<import("@ai-sdk/provider-utils").Context>>;
654
+ } & {
655
+ type: "provider";
656
+ id: `${string}.${string}`;
657
+ args: Record<string, unknown>;
658
+ description?: never;
659
+ strict?: never;
660
+ inputExamples?: never;
661
+ } & {
662
+ isProviderExecuted: true;
663
+ supportsDeferredResults?: boolean;
664
+ } & {
665
+ execute: import("ai").ToolExecuteFunction<{
666
+ query: string;
667
+ }, {
668
+ pending?: string | undefined;
669
+ results: {
670
+ content: string;
671
+ occurredAt: string | null;
672
+ sourceIds: string[];
673
+ }[];
674
+ }, NoInfer<import("@ai-sdk/provider-utils").Context>>;
675
+ });
676
+ };