@rce-mcp/contracts 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,778 @@
1
+ import { z } from "zod";
2
+ export declare const API_VERSION: "v1";
3
+ export declare const PublicToolNameSchema: z.ZodEnum<["search_context", "enhance_prompt"]>;
4
+ export type PublicToolName = z.infer<typeof PublicToolNameSchema>;
5
+ export declare const ErrorCodeSchema: z.ZodEnum<["INVALID_ARGUMENT", "UNAUTHENTICATED", "FORBIDDEN", "NOT_FOUND", "RATE_LIMITED", "CONFLICT", "UPSTREAM_FAILURE", "INTERNAL"]>;
6
+ export type ErrorCode = z.infer<typeof ErrorCodeSchema>;
7
+ export declare const ErrorEnvelopeSchema: z.ZodObject<{
8
+ error: z.ZodObject<{
9
+ code: z.ZodEnum<["INVALID_ARGUMENT", "UNAUTHENTICATED", "FORBIDDEN", "NOT_FOUND", "RATE_LIMITED", "CONFLICT", "UPSTREAM_FAILURE", "INTERNAL"]>;
10
+ message: z.ZodString;
11
+ retryable: z.ZodBoolean;
12
+ trace_id: z.ZodString;
13
+ details: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
14
+ }, "strict", z.ZodTypeAny, {
15
+ code: "INVALID_ARGUMENT" | "UNAUTHENTICATED" | "FORBIDDEN" | "NOT_FOUND" | "RATE_LIMITED" | "CONFLICT" | "UPSTREAM_FAILURE" | "INTERNAL";
16
+ message: string;
17
+ retryable: boolean;
18
+ trace_id: string;
19
+ details?: Record<string, unknown> | undefined;
20
+ }, {
21
+ code: "INVALID_ARGUMENT" | "UNAUTHENTICATED" | "FORBIDDEN" | "NOT_FOUND" | "RATE_LIMITED" | "CONFLICT" | "UPSTREAM_FAILURE" | "INTERNAL";
22
+ message: string;
23
+ retryable: boolean;
24
+ trace_id: string;
25
+ details?: Record<string, unknown> | undefined;
26
+ }>;
27
+ }, "strict", z.ZodTypeAny, {
28
+ error: {
29
+ code: "INVALID_ARGUMENT" | "UNAUTHENTICATED" | "FORBIDDEN" | "NOT_FOUND" | "RATE_LIMITED" | "CONFLICT" | "UPSTREAM_FAILURE" | "INTERNAL";
30
+ message: string;
31
+ retryable: boolean;
32
+ trace_id: string;
33
+ details?: Record<string, unknown> | undefined;
34
+ };
35
+ }, {
36
+ error: {
37
+ code: "INVALID_ARGUMENT" | "UNAUTHENTICATED" | "FORBIDDEN" | "NOT_FOUND" | "RATE_LIMITED" | "CONFLICT" | "UPSTREAM_FAILURE" | "INTERNAL";
38
+ message: string;
39
+ retryable: boolean;
40
+ trace_id: string;
41
+ details?: Record<string, unknown> | undefined;
42
+ };
43
+ }>;
44
+ export type ErrorEnvelope = z.infer<typeof ErrorEnvelopeSchema>;
45
+ export declare const SearchContextFiltersSchema: z.ZodObject<{
46
+ language: z.ZodOptional<z.ZodString>;
47
+ path_prefix: z.ZodOptional<z.ZodString>;
48
+ glob: z.ZodOptional<z.ZodString>;
49
+ }, "strict", z.ZodTypeAny, {
50
+ language?: string | undefined;
51
+ path_prefix?: string | undefined;
52
+ glob?: string | undefined;
53
+ }, {
54
+ language?: string | undefined;
55
+ path_prefix?: string | undefined;
56
+ glob?: string | undefined;
57
+ }>;
58
+ export declare const SearchContextInputSchema: z.ZodObject<{
59
+ project_root_path: z.ZodString;
60
+ query: z.ZodString;
61
+ top_k: z.ZodDefault<z.ZodNumber>;
62
+ filters: z.ZodOptional<z.ZodObject<{
63
+ language: z.ZodOptional<z.ZodString>;
64
+ path_prefix: z.ZodOptional<z.ZodString>;
65
+ glob: z.ZodOptional<z.ZodString>;
66
+ }, "strict", z.ZodTypeAny, {
67
+ language?: string | undefined;
68
+ path_prefix?: string | undefined;
69
+ glob?: string | undefined;
70
+ }, {
71
+ language?: string | undefined;
72
+ path_prefix?: string | undefined;
73
+ glob?: string | undefined;
74
+ }>>;
75
+ }, "strict", z.ZodTypeAny, {
76
+ project_root_path: string;
77
+ query: string;
78
+ top_k: number;
79
+ filters?: {
80
+ language?: string | undefined;
81
+ path_prefix?: string | undefined;
82
+ glob?: string | undefined;
83
+ } | undefined;
84
+ }, {
85
+ project_root_path: string;
86
+ query: string;
87
+ top_k?: number | undefined;
88
+ filters?: {
89
+ language?: string | undefined;
90
+ path_prefix?: string | undefined;
91
+ glob?: string | undefined;
92
+ } | undefined;
93
+ }>;
94
+ export type SearchContextInput = z.infer<typeof SearchContextInputSchema>;
95
+ export declare const SearchContextResultSchema: z.ZodObject<{
96
+ path: z.ZodString;
97
+ start_line: z.ZodNumber;
98
+ end_line: z.ZodNumber;
99
+ snippet: z.ZodString;
100
+ score: z.ZodNumber;
101
+ reason: z.ZodString;
102
+ }, "strict", z.ZodTypeAny, {
103
+ path: string;
104
+ start_line: number;
105
+ end_line: number;
106
+ snippet: string;
107
+ score: number;
108
+ reason: string;
109
+ }, {
110
+ path: string;
111
+ start_line: number;
112
+ end_line: number;
113
+ snippet: string;
114
+ score: number;
115
+ reason: string;
116
+ }>;
117
+ export declare const SearchContextOutputSchema: z.ZodObject<{
118
+ trace_id: z.ZodString;
119
+ results: z.ZodArray<z.ZodObject<{
120
+ path: z.ZodString;
121
+ start_line: z.ZodNumber;
122
+ end_line: z.ZodNumber;
123
+ snippet: z.ZodString;
124
+ score: z.ZodNumber;
125
+ reason: z.ZodString;
126
+ }, "strict", z.ZodTypeAny, {
127
+ path: string;
128
+ start_line: number;
129
+ end_line: number;
130
+ snippet: string;
131
+ score: number;
132
+ reason: string;
133
+ }, {
134
+ path: string;
135
+ start_line: number;
136
+ end_line: number;
137
+ snippet: string;
138
+ score: number;
139
+ reason: string;
140
+ }>, "many">;
141
+ search_metadata: z.ZodObject<{
142
+ latency_ms: z.ZodNumber;
143
+ retrieval_mode: z.ZodEnum<["hybrid", "vector", "lexical"]>;
144
+ index_version: z.ZodString;
145
+ }, "strict", z.ZodTypeAny, {
146
+ latency_ms: number;
147
+ retrieval_mode: "hybrid" | "vector" | "lexical";
148
+ index_version: string;
149
+ }, {
150
+ latency_ms: number;
151
+ retrieval_mode: "hybrid" | "vector" | "lexical";
152
+ index_version: string;
153
+ }>;
154
+ }, "strict", z.ZodTypeAny, {
155
+ trace_id: string;
156
+ results: {
157
+ path: string;
158
+ start_line: number;
159
+ end_line: number;
160
+ snippet: string;
161
+ score: number;
162
+ reason: string;
163
+ }[];
164
+ search_metadata: {
165
+ latency_ms: number;
166
+ retrieval_mode: "hybrid" | "vector" | "lexical";
167
+ index_version: string;
168
+ };
169
+ }, {
170
+ trace_id: string;
171
+ results: {
172
+ path: string;
173
+ start_line: number;
174
+ end_line: number;
175
+ snippet: string;
176
+ score: number;
177
+ reason: string;
178
+ }[];
179
+ search_metadata: {
180
+ latency_ms: number;
181
+ retrieval_mode: "hybrid" | "vector" | "lexical";
182
+ index_version: string;
183
+ };
184
+ }>;
185
+ export type SearchContextOutput = z.infer<typeof SearchContextOutputSchema>;
186
+ export declare const SyncPushFileSchema: z.ZodObject<{
187
+ path: z.ZodString;
188
+ content: z.ZodString;
189
+ language: z.ZodOptional<z.ZodString>;
190
+ generated: z.ZodOptional<z.ZodBoolean>;
191
+ binary: z.ZodOptional<z.ZodBoolean>;
192
+ updated_at: z.ZodOptional<z.ZodString>;
193
+ }, "strict", z.ZodTypeAny, {
194
+ path: string;
195
+ content: string;
196
+ language?: string | undefined;
197
+ generated?: boolean | undefined;
198
+ binary?: boolean | undefined;
199
+ updated_at?: string | undefined;
200
+ }, {
201
+ path: string;
202
+ content: string;
203
+ language?: string | undefined;
204
+ generated?: boolean | undefined;
205
+ binary?: boolean | undefined;
206
+ updated_at?: string | undefined;
207
+ }>;
208
+ export type SyncPushFile = z.infer<typeof SyncPushFileSchema>;
209
+ export declare const SyncPushInputSchema: z.ZodObject<{
210
+ project_root_path: z.ZodString;
211
+ workspace_id: z.ZodOptional<z.ZodString>;
212
+ index_version: z.ZodOptional<z.ZodString>;
213
+ files: z.ZodArray<z.ZodObject<{
214
+ path: z.ZodString;
215
+ content: z.ZodString;
216
+ language: z.ZodOptional<z.ZodString>;
217
+ generated: z.ZodOptional<z.ZodBoolean>;
218
+ binary: z.ZodOptional<z.ZodBoolean>;
219
+ updated_at: z.ZodOptional<z.ZodString>;
220
+ }, "strict", z.ZodTypeAny, {
221
+ path: string;
222
+ content: string;
223
+ language?: string | undefined;
224
+ generated?: boolean | undefined;
225
+ binary?: boolean | undefined;
226
+ updated_at?: string | undefined;
227
+ }, {
228
+ path: string;
229
+ content: string;
230
+ language?: string | undefined;
231
+ generated?: boolean | undefined;
232
+ binary?: boolean | undefined;
233
+ updated_at?: string | undefined;
234
+ }>, "many">;
235
+ }, "strict", z.ZodTypeAny, {
236
+ project_root_path: string;
237
+ files: {
238
+ path: string;
239
+ content: string;
240
+ language?: string | undefined;
241
+ generated?: boolean | undefined;
242
+ binary?: boolean | undefined;
243
+ updated_at?: string | undefined;
244
+ }[];
245
+ index_version?: string | undefined;
246
+ workspace_id?: string | undefined;
247
+ }, {
248
+ project_root_path: string;
249
+ files: {
250
+ path: string;
251
+ content: string;
252
+ language?: string | undefined;
253
+ generated?: boolean | undefined;
254
+ binary?: boolean | undefined;
255
+ updated_at?: string | undefined;
256
+ }[];
257
+ index_version?: string | undefined;
258
+ workspace_id?: string | undefined;
259
+ }>;
260
+ export type SyncPushInput = z.infer<typeof SyncPushInputSchema>;
261
+ export declare const SyncPushDeltaInputSchema: z.ZodEffects<z.ZodObject<{
262
+ project_root_path: z.ZodString;
263
+ workspace_id: z.ZodOptional<z.ZodString>;
264
+ base_index_version: z.ZodOptional<z.ZodString>;
265
+ upsert_files: z.ZodDefault<z.ZodArray<z.ZodObject<{
266
+ path: z.ZodString;
267
+ content: z.ZodString;
268
+ language: z.ZodOptional<z.ZodString>;
269
+ generated: z.ZodOptional<z.ZodBoolean>;
270
+ binary: z.ZodOptional<z.ZodBoolean>;
271
+ updated_at: z.ZodOptional<z.ZodString>;
272
+ }, "strict", z.ZodTypeAny, {
273
+ path: string;
274
+ content: string;
275
+ language?: string | undefined;
276
+ generated?: boolean | undefined;
277
+ binary?: boolean | undefined;
278
+ updated_at?: string | undefined;
279
+ }, {
280
+ path: string;
281
+ content: string;
282
+ language?: string | undefined;
283
+ generated?: boolean | undefined;
284
+ binary?: boolean | undefined;
285
+ updated_at?: string | undefined;
286
+ }>, "many">>;
287
+ deleted_paths: z.ZodDefault<z.ZodArray<z.ZodString, "many">>;
288
+ }, "strict", z.ZodTypeAny, {
289
+ project_root_path: string;
290
+ upsert_files: {
291
+ path: string;
292
+ content: string;
293
+ language?: string | undefined;
294
+ generated?: boolean | undefined;
295
+ binary?: boolean | undefined;
296
+ updated_at?: string | undefined;
297
+ }[];
298
+ deleted_paths: string[];
299
+ workspace_id?: string | undefined;
300
+ base_index_version?: string | undefined;
301
+ }, {
302
+ project_root_path: string;
303
+ workspace_id?: string | undefined;
304
+ base_index_version?: string | undefined;
305
+ upsert_files?: {
306
+ path: string;
307
+ content: string;
308
+ language?: string | undefined;
309
+ generated?: boolean | undefined;
310
+ binary?: boolean | undefined;
311
+ updated_at?: string | undefined;
312
+ }[] | undefined;
313
+ deleted_paths?: string[] | undefined;
314
+ }>, {
315
+ project_root_path: string;
316
+ upsert_files: {
317
+ path: string;
318
+ content: string;
319
+ language?: string | undefined;
320
+ generated?: boolean | undefined;
321
+ binary?: boolean | undefined;
322
+ updated_at?: string | undefined;
323
+ }[];
324
+ deleted_paths: string[];
325
+ workspace_id?: string | undefined;
326
+ base_index_version?: string | undefined;
327
+ }, {
328
+ project_root_path: string;
329
+ workspace_id?: string | undefined;
330
+ base_index_version?: string | undefined;
331
+ upsert_files?: {
332
+ path: string;
333
+ content: string;
334
+ language?: string | undefined;
335
+ generated?: boolean | undefined;
336
+ binary?: boolean | undefined;
337
+ updated_at?: string | undefined;
338
+ }[] | undefined;
339
+ deleted_paths?: string[] | undefined;
340
+ }>;
341
+ export type SyncPushDeltaInput = z.infer<typeof SyncPushDeltaInputSchema>;
342
+ export declare const SyncPushReportSchema: z.ZodObject<{
343
+ status: z.ZodString;
344
+ counts: z.ZodObject<{
345
+ added: z.ZodNumber;
346
+ modified: z.ZodNumber;
347
+ deleted: z.ZodNumber;
348
+ unchanged: z.ZodNumber;
349
+ skipped: z.ZodNumber;
350
+ }, "strict", z.ZodTypeAny, {
351
+ added: number;
352
+ modified: number;
353
+ deleted: number;
354
+ unchanged: number;
355
+ skipped: number;
356
+ }, {
357
+ added: number;
358
+ modified: number;
359
+ deleted: number;
360
+ unchanged: number;
361
+ skipped: number;
362
+ }>;
363
+ }, "strict", z.ZodTypeAny, {
364
+ status: string;
365
+ counts: {
366
+ added: number;
367
+ modified: number;
368
+ deleted: number;
369
+ unchanged: number;
370
+ skipped: number;
371
+ };
372
+ }, {
373
+ status: string;
374
+ counts: {
375
+ added: number;
376
+ modified: number;
377
+ deleted: number;
378
+ unchanged: number;
379
+ skipped: number;
380
+ };
381
+ }>;
382
+ export type SyncPushReport = z.infer<typeof SyncPushReportSchema>;
383
+ export declare const SyncPushResponseSchema: z.ZodObject<{
384
+ trace_id: z.ZodString;
385
+ tenant_id: z.ZodString;
386
+ workspace_id: z.ZodString;
387
+ project_root_path: z.ZodString;
388
+ index_version: z.ZodString;
389
+ workspace_created: z.ZodBoolean;
390
+ report: z.ZodObject<{
391
+ status: z.ZodString;
392
+ counts: z.ZodObject<{
393
+ added: z.ZodNumber;
394
+ modified: z.ZodNumber;
395
+ deleted: z.ZodNumber;
396
+ unchanged: z.ZodNumber;
397
+ skipped: z.ZodNumber;
398
+ }, "strict", z.ZodTypeAny, {
399
+ added: number;
400
+ modified: number;
401
+ deleted: number;
402
+ unchanged: number;
403
+ skipped: number;
404
+ }, {
405
+ added: number;
406
+ modified: number;
407
+ deleted: number;
408
+ unchanged: number;
409
+ skipped: number;
410
+ }>;
411
+ }, "strict", z.ZodTypeAny, {
412
+ status: string;
413
+ counts: {
414
+ added: number;
415
+ modified: number;
416
+ deleted: number;
417
+ unchanged: number;
418
+ skipped: number;
419
+ };
420
+ }, {
421
+ status: string;
422
+ counts: {
423
+ added: number;
424
+ modified: number;
425
+ deleted: number;
426
+ unchanged: number;
427
+ skipped: number;
428
+ };
429
+ }>;
430
+ }, "strict", z.ZodTypeAny, {
431
+ trace_id: string;
432
+ project_root_path: string;
433
+ index_version: string;
434
+ workspace_id: string;
435
+ tenant_id: string;
436
+ workspace_created: boolean;
437
+ report: {
438
+ status: string;
439
+ counts: {
440
+ added: number;
441
+ modified: number;
442
+ deleted: number;
443
+ unchanged: number;
444
+ skipped: number;
445
+ };
446
+ };
447
+ }, {
448
+ trace_id: string;
449
+ project_root_path: string;
450
+ index_version: string;
451
+ workspace_id: string;
452
+ tenant_id: string;
453
+ workspace_created: boolean;
454
+ report: {
455
+ status: string;
456
+ counts: {
457
+ added: number;
458
+ modified: number;
459
+ deleted: number;
460
+ unchanged: number;
461
+ skipped: number;
462
+ };
463
+ };
464
+ }>;
465
+ export type SyncPushResponse = z.infer<typeof SyncPushResponseSchema>;
466
+ export declare const SyncPushDeltaResponseSchema: z.ZodObject<{
467
+ trace_id: z.ZodString;
468
+ tenant_id: z.ZodString;
469
+ workspace_id: z.ZodString;
470
+ project_root_path: z.ZodString;
471
+ index_version: z.ZodString;
472
+ workspace_created: z.ZodBoolean;
473
+ report: z.ZodObject<{
474
+ status: z.ZodString;
475
+ counts: z.ZodObject<{
476
+ added: z.ZodNumber;
477
+ modified: z.ZodNumber;
478
+ deleted: z.ZodNumber;
479
+ unchanged: z.ZodNumber;
480
+ skipped: z.ZodNumber;
481
+ }, "strict", z.ZodTypeAny, {
482
+ added: number;
483
+ modified: number;
484
+ deleted: number;
485
+ unchanged: number;
486
+ skipped: number;
487
+ }, {
488
+ added: number;
489
+ modified: number;
490
+ deleted: number;
491
+ unchanged: number;
492
+ skipped: number;
493
+ }>;
494
+ }, "strict", z.ZodTypeAny, {
495
+ status: string;
496
+ counts: {
497
+ added: number;
498
+ modified: number;
499
+ deleted: number;
500
+ unchanged: number;
501
+ skipped: number;
502
+ };
503
+ }, {
504
+ status: string;
505
+ counts: {
506
+ added: number;
507
+ modified: number;
508
+ deleted: number;
509
+ unchanged: number;
510
+ skipped: number;
511
+ };
512
+ }>;
513
+ } & {
514
+ base_index_version: z.ZodNullable<z.ZodString>;
515
+ applied_delta: z.ZodObject<{
516
+ upsert_files: z.ZodNumber;
517
+ deleted_paths: z.ZodNumber;
518
+ }, "strict", z.ZodTypeAny, {
519
+ upsert_files: number;
520
+ deleted_paths: number;
521
+ }, {
522
+ upsert_files: number;
523
+ deleted_paths: number;
524
+ }>;
525
+ }, "strict", z.ZodTypeAny, {
526
+ trace_id: string;
527
+ project_root_path: string;
528
+ index_version: string;
529
+ workspace_id: string;
530
+ base_index_version: string | null;
531
+ tenant_id: string;
532
+ workspace_created: boolean;
533
+ report: {
534
+ status: string;
535
+ counts: {
536
+ added: number;
537
+ modified: number;
538
+ deleted: number;
539
+ unchanged: number;
540
+ skipped: number;
541
+ };
542
+ };
543
+ applied_delta: {
544
+ upsert_files: number;
545
+ deleted_paths: number;
546
+ };
547
+ }, {
548
+ trace_id: string;
549
+ project_root_path: string;
550
+ index_version: string;
551
+ workspace_id: string;
552
+ base_index_version: string | null;
553
+ tenant_id: string;
554
+ workspace_created: boolean;
555
+ report: {
556
+ status: string;
557
+ counts: {
558
+ added: number;
559
+ modified: number;
560
+ deleted: number;
561
+ unchanged: number;
562
+ skipped: number;
563
+ };
564
+ };
565
+ applied_delta: {
566
+ upsert_files: number;
567
+ deleted_paths: number;
568
+ };
569
+ }>;
570
+ export type SyncPushDeltaResponse = z.infer<typeof SyncPushDeltaResponseSchema>;
571
+ export declare const ConversationMessageSchema: z.ZodObject<{
572
+ role: z.ZodEnum<["user", "assistant", "system"]>;
573
+ content: z.ZodString;
574
+ }, "strict", z.ZodTypeAny, {
575
+ content: string;
576
+ role: "user" | "assistant" | "system";
577
+ }, {
578
+ content: string;
579
+ role: "user" | "assistant" | "system";
580
+ }>;
581
+ export declare const EnhancePromptInputSchema: z.ZodObject<{
582
+ prompt: z.ZodString;
583
+ conversation_history: z.ZodArray<z.ZodObject<{
584
+ role: z.ZodEnum<["user", "assistant", "system"]>;
585
+ content: z.ZodString;
586
+ }, "strict", z.ZodTypeAny, {
587
+ content: string;
588
+ role: "user" | "assistant" | "system";
589
+ }, {
590
+ content: string;
591
+ role: "user" | "assistant" | "system";
592
+ }>, "many">;
593
+ project_root_path: z.ZodOptional<z.ZodString>;
594
+ }, "strict", z.ZodTypeAny, {
595
+ prompt: string;
596
+ conversation_history: {
597
+ content: string;
598
+ role: "user" | "assistant" | "system";
599
+ }[];
600
+ project_root_path?: string | undefined;
601
+ }, {
602
+ prompt: string;
603
+ conversation_history: {
604
+ content: string;
605
+ role: "user" | "assistant" | "system";
606
+ }[];
607
+ project_root_path?: string | undefined;
608
+ }>;
609
+ export type EnhancePromptInput = z.infer<typeof EnhancePromptInputSchema>;
610
+ export declare const ContextRefSchema: z.ZodObject<{
611
+ path: z.ZodString;
612
+ start_line: z.ZodNumber;
613
+ end_line: z.ZodNumber;
614
+ reason: z.ZodString;
615
+ }, "strict", z.ZodTypeAny, {
616
+ path: string;
617
+ start_line: number;
618
+ end_line: number;
619
+ reason: string;
620
+ }, {
621
+ path: string;
622
+ start_line: number;
623
+ end_line: number;
624
+ reason: string;
625
+ }>;
626
+ export declare const EnhancePromptOutputSchema: z.ZodObject<{
627
+ trace_id: z.ZodString;
628
+ enhanced_prompt: z.ZodString;
629
+ context_refs: z.ZodArray<z.ZodObject<{
630
+ path: z.ZodString;
631
+ start_line: z.ZodNumber;
632
+ end_line: z.ZodNumber;
633
+ reason: z.ZodString;
634
+ }, "strict", z.ZodTypeAny, {
635
+ path: string;
636
+ start_line: number;
637
+ end_line: number;
638
+ reason: string;
639
+ }, {
640
+ path: string;
641
+ start_line: number;
642
+ end_line: number;
643
+ reason: string;
644
+ }>, "many">;
645
+ warnings: z.ZodArray<z.ZodString, "many">;
646
+ questions: z.ZodArray<z.ZodString, "many">;
647
+ }, "strict", z.ZodTypeAny, {
648
+ trace_id: string;
649
+ enhanced_prompt: string;
650
+ context_refs: {
651
+ path: string;
652
+ start_line: number;
653
+ end_line: number;
654
+ reason: string;
655
+ }[];
656
+ warnings: string[];
657
+ questions: string[];
658
+ }, {
659
+ trace_id: string;
660
+ enhanced_prompt: string;
661
+ context_refs: {
662
+ path: string;
663
+ start_line: number;
664
+ end_line: number;
665
+ reason: string;
666
+ }[];
667
+ warnings: string[];
668
+ questions: string[];
669
+ }>;
670
+ export type EnhancePromptOutput = z.infer<typeof EnhancePromptOutputSchema>;
671
+ export declare const RetrievalBenchmarkRepoSchema: z.ZodObject<{
672
+ id: z.ZodString;
673
+ git_url: z.ZodString;
674
+ commit: z.ZodString;
675
+ split: z.ZodEnum<["train", "dev", "test"]>;
676
+ language: z.ZodOptional<z.ZodString>;
677
+ notes: z.ZodOptional<z.ZodString>;
678
+ }, "strict", z.ZodTypeAny, {
679
+ id: string;
680
+ git_url: string;
681
+ commit: string;
682
+ split: "train" | "dev" | "test";
683
+ language?: string | undefined;
684
+ notes?: string | undefined;
685
+ }, {
686
+ id: string;
687
+ git_url: string;
688
+ commit: string;
689
+ split: "train" | "dev" | "test";
690
+ language?: string | undefined;
691
+ notes?: string | undefined;
692
+ }>;
693
+ export type RetrievalBenchmarkRepo = z.infer<typeof RetrievalBenchmarkRepoSchema>;
694
+ export declare const RetrievalBenchmarkManifestSchema: z.ZodObject<{
695
+ schema_version: z.ZodLiteral<"v1">;
696
+ generated_at: z.ZodOptional<z.ZodString>;
697
+ repos: z.ZodArray<z.ZodObject<{
698
+ id: z.ZodString;
699
+ git_url: z.ZodString;
700
+ commit: z.ZodString;
701
+ split: z.ZodEnum<["train", "dev", "test"]>;
702
+ language: z.ZodOptional<z.ZodString>;
703
+ notes: z.ZodOptional<z.ZodString>;
704
+ }, "strict", z.ZodTypeAny, {
705
+ id: string;
706
+ git_url: string;
707
+ commit: string;
708
+ split: "train" | "dev" | "test";
709
+ language?: string | undefined;
710
+ notes?: string | undefined;
711
+ }, {
712
+ id: string;
713
+ git_url: string;
714
+ commit: string;
715
+ split: "train" | "dev" | "test";
716
+ language?: string | undefined;
717
+ notes?: string | undefined;
718
+ }>, "many">;
719
+ }, "strict", z.ZodTypeAny, {
720
+ schema_version: "v1";
721
+ repos: {
722
+ id: string;
723
+ git_url: string;
724
+ commit: string;
725
+ split: "train" | "dev" | "test";
726
+ language?: string | undefined;
727
+ notes?: string | undefined;
728
+ }[];
729
+ generated_at?: string | undefined;
730
+ }, {
731
+ schema_version: "v1";
732
+ repos: {
733
+ id: string;
734
+ git_url: string;
735
+ commit: string;
736
+ split: "train" | "dev" | "test";
737
+ language?: string | undefined;
738
+ notes?: string | undefined;
739
+ }[];
740
+ generated_at?: string | undefined;
741
+ }>;
742
+ export type RetrievalBenchmarkManifest = z.infer<typeof RetrievalBenchmarkManifestSchema>;
743
+ export declare const RetrievalBenchmarkQuerySchema: z.ZodObject<{
744
+ id: z.ZodString;
745
+ repo_id: z.ZodString;
746
+ tool: z.ZodDefault<z.ZodEnum<["search_context", "enhance_prompt"]>>;
747
+ query: z.ZodString;
748
+ expected_paths: z.ZodArray<z.ZodString, "many">;
749
+ tags: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
750
+ notes: z.ZodOptional<z.ZodString>;
751
+ }, "strict", z.ZodTypeAny, {
752
+ query: string;
753
+ id: string;
754
+ repo_id: string;
755
+ tool: "search_context" | "enhance_prompt";
756
+ expected_paths: string[];
757
+ notes?: string | undefined;
758
+ tags?: string[] | undefined;
759
+ }, {
760
+ query: string;
761
+ id: string;
762
+ repo_id: string;
763
+ expected_paths: string[];
764
+ notes?: string | undefined;
765
+ tool?: "search_context" | "enhance_prompt" | undefined;
766
+ tags?: string[] | undefined;
767
+ }>;
768
+ export type RetrievalBenchmarkQuery = z.infer<typeof RetrievalBenchmarkQuerySchema>;
769
+ export declare function isPublicToolName(value: string): value is PublicToolName;
770
+ export declare function toValidationDetails(error: z.ZodError): Record<string, unknown>;
771
+ export declare function makeErrorEnvelope(input: {
772
+ code: ErrorCode;
773
+ message: string;
774
+ trace_id: string;
775
+ retryable?: boolean;
776
+ details?: Record<string, unknown>;
777
+ }): ErrorEnvelope;
778
+ export declare function errorCodeToHttpStatus(code: ErrorCode): number;