codecane 1.0.181 → 1.0.184
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/dist/checkpoint-file-manager.d.ts +25 -3
- package/dist/checkpoint-file-manager.js +64 -43
- package/dist/checkpoint-file-manager.js.map +1 -1
- package/dist/checkpoints.d.ts +3 -1
- package/dist/checkpoints.js +25 -27
- package/dist/checkpoints.js.map +1 -1
- package/dist/cli.d.ts +1 -1
- package/dist/cli.js +7 -2
- package/dist/cli.js.map +1 -1
- package/dist/client.d.ts +8 -8
- package/dist/client.js +12 -20
- package/dist/client.js.map +1 -1
- package/dist/code-map/tsconfig.tsbuildinfo +1 -1
- package/dist/common/actions.d.ts +195 -195
- package/dist/common/browser-actions.d.ts +48 -48
- package/dist/common/constants.js +1 -8
- package/dist/common/constants.js.map +1 -1
- package/dist/common/types/agent-state.d.ts +20 -20
- package/dist/common/types/message.d.ts +16 -16
- package/dist/common/util/file.d.ts +4 -4
- package/dist/common/util/saxy.js +8 -5
- package/dist/common/util/saxy.js.map +1 -1
- package/dist/common/websockets/websocket-schema.d.ts +518 -518
- package/dist/config.js +1 -1
- package/dist/config.js.map +1 -1
- package/dist/index.js +3 -5
- package/dist/index.js.map +1 -1
- package/dist/project-files.d.ts +2 -2
- package/dist/update-codebuff.js +26 -26
- package/dist/utils/__tests__/xml-stream-parser.test.js +65 -6
- package/dist/utils/__tests__/xml-stream-parser.test.js.map +1 -1
- package/dist/utils/tool-renderers.d.ts +16 -0
- package/dist/utils/tool-renderers.js +105 -0
- package/dist/utils/tool-renderers.js.map +1 -0
- package/dist/utils/xml-stream-parser.d.ts +1 -16
- package/dist/utils/xml-stream-parser.js +3 -104
- package/dist/utils/xml-stream-parser.js.map +1 -1
- package/dist/web-scraper.js +4 -8
- package/dist/web-scraper.js.map +1 -1
- package/dist/worker-script-project-context.js +4 -0
- package/dist/worker-script-project-context.js.map +1 -1
- package/package.json +2 -2
|
@@ -70,14 +70,14 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
70
70
|
type: "ephemeral";
|
|
71
71
|
}>>;
|
|
72
72
|
}, "strip", z.ZodTypeAny, {
|
|
73
|
-
text: string;
|
|
74
73
|
type: "text";
|
|
74
|
+
text: string;
|
|
75
75
|
cache_control?: {
|
|
76
76
|
type: "ephemeral";
|
|
77
77
|
} | undefined;
|
|
78
78
|
}, {
|
|
79
|
-
text: string;
|
|
80
79
|
type: "text";
|
|
80
|
+
text: string;
|
|
81
81
|
cache_control?: {
|
|
82
82
|
type: "ephemeral";
|
|
83
83
|
} | undefined;
|
|
@@ -141,13 +141,13 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
141
141
|
media_type: z.ZodLiteral<"image/jpeg">;
|
|
142
142
|
data: z.ZodString;
|
|
143
143
|
}, "strip", z.ZodTypeAny, {
|
|
144
|
-
data: string;
|
|
145
144
|
type: "base64";
|
|
146
145
|
media_type: "image/jpeg";
|
|
147
|
-
}, {
|
|
148
146
|
data: string;
|
|
147
|
+
}, {
|
|
149
148
|
type: "base64";
|
|
150
149
|
media_type: "image/jpeg";
|
|
150
|
+
data: string;
|
|
151
151
|
}>;
|
|
152
152
|
cache_control: z.ZodOptional<z.ZodObject<{
|
|
153
153
|
type: z.ZodLiteral<"ephemeral">;
|
|
@@ -159,9 +159,9 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
159
159
|
}, "strip", z.ZodTypeAny, {
|
|
160
160
|
type: "image";
|
|
161
161
|
source: {
|
|
162
|
-
data: string;
|
|
163
162
|
type: "base64";
|
|
164
163
|
media_type: "image/jpeg";
|
|
164
|
+
data: string;
|
|
165
165
|
};
|
|
166
166
|
cache_control?: {
|
|
167
167
|
type: "ephemeral";
|
|
@@ -169,9 +169,9 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
169
169
|
}, {
|
|
170
170
|
type: "image";
|
|
171
171
|
source: {
|
|
172
|
-
data: string;
|
|
173
172
|
type: "base64";
|
|
174
173
|
media_type: "image/jpeg";
|
|
174
|
+
data: string;
|
|
175
175
|
};
|
|
176
176
|
cache_control?: {
|
|
177
177
|
type: "ephemeral";
|
|
@@ -179,8 +179,8 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
179
179
|
}>]>, "many">]>;
|
|
180
180
|
}, "strip", z.ZodTypeAny, {
|
|
181
181
|
content: string | ({
|
|
182
|
-
text: string;
|
|
183
182
|
type: "text";
|
|
183
|
+
text: string;
|
|
184
184
|
cache_control?: {
|
|
185
185
|
type: "ephemeral";
|
|
186
186
|
} | undefined;
|
|
@@ -202,9 +202,9 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
202
202
|
} | {
|
|
203
203
|
type: "image";
|
|
204
204
|
source: {
|
|
205
|
-
data: string;
|
|
206
205
|
type: "base64";
|
|
207
206
|
media_type: "image/jpeg";
|
|
207
|
+
data: string;
|
|
208
208
|
};
|
|
209
209
|
cache_control?: {
|
|
210
210
|
type: "ephemeral";
|
|
@@ -213,8 +213,8 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
213
213
|
role: "user" | "assistant";
|
|
214
214
|
}, {
|
|
215
215
|
content: string | ({
|
|
216
|
-
text: string;
|
|
217
216
|
type: "text";
|
|
217
|
+
text: string;
|
|
218
218
|
cache_control?: {
|
|
219
219
|
type: "ephemeral";
|
|
220
220
|
} | undefined;
|
|
@@ -236,9 +236,9 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
236
236
|
} | {
|
|
237
237
|
type: "image";
|
|
238
238
|
source: {
|
|
239
|
-
data: string;
|
|
240
239
|
type: "base64";
|
|
241
240
|
media_type: "image/jpeg";
|
|
241
|
+
data: string;
|
|
242
242
|
};
|
|
243
243
|
cache_control?: {
|
|
244
244
|
type: "ephemeral";
|
|
@@ -258,13 +258,13 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
258
258
|
diffCached: z.ZodString;
|
|
259
259
|
lastCommitMessages: z.ZodString;
|
|
260
260
|
}, "strip", z.ZodTypeAny, {
|
|
261
|
-
status: string;
|
|
262
261
|
diff: string;
|
|
262
|
+
status: string;
|
|
263
263
|
diffCached: string;
|
|
264
264
|
lastCommitMessages: string;
|
|
265
265
|
}, {
|
|
266
|
-
status: string;
|
|
267
266
|
diff: string;
|
|
267
|
+
status: string;
|
|
268
268
|
diffCached: string;
|
|
269
269
|
lastCommitMessages: string;
|
|
270
270
|
}>;
|
|
@@ -308,8 +308,8 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
308
308
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
309
309
|
knowledgeFiles: Record<string, string>;
|
|
310
310
|
gitChanges: {
|
|
311
|
-
status: string;
|
|
312
311
|
diff: string;
|
|
312
|
+
status: string;
|
|
313
313
|
diffCached: string;
|
|
314
314
|
lastCommitMessages: string;
|
|
315
315
|
};
|
|
@@ -334,8 +334,8 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
334
334
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
335
335
|
knowledgeFiles: Record<string, string>;
|
|
336
336
|
gitChanges: {
|
|
337
|
-
status: string;
|
|
338
337
|
diff: string;
|
|
338
|
+
status: string;
|
|
339
339
|
diffCached: string;
|
|
340
340
|
lastCommitMessages: string;
|
|
341
341
|
};
|
|
@@ -360,50 +360,23 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
360
360
|
path: z.ZodString;
|
|
361
361
|
content: z.ZodString;
|
|
362
362
|
}, "strip", z.ZodTypeAny, {
|
|
363
|
+
type: "patch" | "file";
|
|
363
364
|
path: string;
|
|
364
|
-
type: "file" | "patch";
|
|
365
365
|
content: string;
|
|
366
366
|
}, {
|
|
367
|
+
type: "patch" | "file";
|
|
367
368
|
path: string;
|
|
368
|
-
type: "file" | "patch";
|
|
369
369
|
content: string;
|
|
370
370
|
}>, "many">;
|
|
371
371
|
costMode: z.ZodDefault<z.ZodOptional<z.ZodEnum<["lite", "normal", "max"]>>>;
|
|
372
372
|
}, "strip", z.ZodTypeAny, {
|
|
373
373
|
type: "user-input";
|
|
374
|
-
fileContext: {
|
|
375
|
-
currentWorkingDirectory: string;
|
|
376
|
-
fileTree: import("../util/file").FileTreeNode[];
|
|
377
|
-
fileTokenScores: Record<string, Record<string, number>>;
|
|
378
|
-
knowledgeFiles: Record<string, string>;
|
|
379
|
-
gitChanges: {
|
|
380
|
-
status: string;
|
|
381
|
-
diff: string;
|
|
382
|
-
diffCached: string;
|
|
383
|
-
lastCommitMessages: string;
|
|
384
|
-
};
|
|
385
|
-
changesSinceLastChat: Record<string, string>;
|
|
386
|
-
shellConfigFiles: Record<string, string>;
|
|
387
|
-
systemInfo: {
|
|
388
|
-
platform: string;
|
|
389
|
-
shell: string;
|
|
390
|
-
nodeVersion: string;
|
|
391
|
-
arch: string;
|
|
392
|
-
homedir: string;
|
|
393
|
-
cpus: number;
|
|
394
|
-
};
|
|
395
|
-
fileVersions: {
|
|
396
|
-
path: string;
|
|
397
|
-
content: string;
|
|
398
|
-
}[][];
|
|
399
|
-
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
400
|
-
};
|
|
401
374
|
fingerprintId: string;
|
|
402
375
|
userInputId: string;
|
|
403
376
|
messages: {
|
|
404
377
|
content: string | ({
|
|
405
|
-
text: string;
|
|
406
378
|
type: "text";
|
|
379
|
+
text: string;
|
|
407
380
|
cache_control?: {
|
|
408
381
|
type: "ephemeral";
|
|
409
382
|
} | undefined;
|
|
@@ -425,9 +398,9 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
425
398
|
} | {
|
|
426
399
|
type: "image";
|
|
427
400
|
source: {
|
|
428
|
-
data: string;
|
|
429
401
|
type: "base64";
|
|
430
402
|
media_type: "image/jpeg";
|
|
403
|
+
data: string;
|
|
431
404
|
};
|
|
432
405
|
cache_control?: {
|
|
433
406
|
type: "ephemeral";
|
|
@@ -435,23 +408,14 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
435
408
|
})[];
|
|
436
409
|
role: "user" | "assistant";
|
|
437
410
|
}[];
|
|
438
|
-
changesAlreadyApplied: {
|
|
439
|
-
path: string;
|
|
440
|
-
type: "file" | "patch";
|
|
441
|
-
content: string;
|
|
442
|
-
}[];
|
|
443
|
-
costMode: "max" | "lite" | "normal";
|
|
444
|
-
authToken?: string | undefined;
|
|
445
|
-
}, {
|
|
446
|
-
type: "user-input";
|
|
447
411
|
fileContext: {
|
|
448
412
|
currentWorkingDirectory: string;
|
|
449
413
|
fileTree: import("../util/file").FileTreeNode[];
|
|
450
414
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
451
415
|
knowledgeFiles: Record<string, string>;
|
|
452
416
|
gitChanges: {
|
|
453
|
-
status: string;
|
|
454
417
|
diff: string;
|
|
418
|
+
status: string;
|
|
455
419
|
diffCached: string;
|
|
456
420
|
lastCommitMessages: string;
|
|
457
421
|
};
|
|
@@ -471,12 +435,21 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
471
435
|
}[][];
|
|
472
436
|
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
473
437
|
};
|
|
438
|
+
changesAlreadyApplied: {
|
|
439
|
+
type: "patch" | "file";
|
|
440
|
+
path: string;
|
|
441
|
+
content: string;
|
|
442
|
+
}[];
|
|
443
|
+
costMode: "lite" | "normal" | "max";
|
|
444
|
+
authToken?: string | undefined;
|
|
445
|
+
}, {
|
|
446
|
+
type: "user-input";
|
|
474
447
|
fingerprintId: string;
|
|
475
448
|
userInputId: string;
|
|
476
449
|
messages: {
|
|
477
450
|
content: string | ({
|
|
478
|
-
text: string;
|
|
479
451
|
type: "text";
|
|
452
|
+
text: string;
|
|
480
453
|
cache_control?: {
|
|
481
454
|
type: "ephemeral";
|
|
482
455
|
} | undefined;
|
|
@@ -498,9 +471,9 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
498
471
|
} | {
|
|
499
472
|
type: "image";
|
|
500
473
|
source: {
|
|
501
|
-
data: string;
|
|
502
474
|
type: "base64";
|
|
503
475
|
media_type: "image/jpeg";
|
|
476
|
+
data: string;
|
|
504
477
|
};
|
|
505
478
|
cache_control?: {
|
|
506
479
|
type: "ephemeral";
|
|
@@ -508,13 +481,40 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
508
481
|
})[];
|
|
509
482
|
role: "user" | "assistant";
|
|
510
483
|
}[];
|
|
484
|
+
fileContext: {
|
|
485
|
+
currentWorkingDirectory: string;
|
|
486
|
+
fileTree: import("../util/file").FileTreeNode[];
|
|
487
|
+
fileTokenScores: Record<string, Record<string, number>>;
|
|
488
|
+
knowledgeFiles: Record<string, string>;
|
|
489
|
+
gitChanges: {
|
|
490
|
+
diff: string;
|
|
491
|
+
status: string;
|
|
492
|
+
diffCached: string;
|
|
493
|
+
lastCommitMessages: string;
|
|
494
|
+
};
|
|
495
|
+
changesSinceLastChat: Record<string, string>;
|
|
496
|
+
shellConfigFiles: Record<string, string>;
|
|
497
|
+
systemInfo: {
|
|
498
|
+
platform: string;
|
|
499
|
+
shell: string;
|
|
500
|
+
nodeVersion: string;
|
|
501
|
+
arch: string;
|
|
502
|
+
homedir: string;
|
|
503
|
+
cpus: number;
|
|
504
|
+
};
|
|
505
|
+
fileVersions: {
|
|
506
|
+
path: string;
|
|
507
|
+
content: string;
|
|
508
|
+
}[][];
|
|
509
|
+
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
510
|
+
};
|
|
511
511
|
changesAlreadyApplied: {
|
|
512
|
+
type: "patch" | "file";
|
|
512
513
|
path: string;
|
|
513
|
-
type: "file" | "patch";
|
|
514
514
|
content: string;
|
|
515
515
|
}[];
|
|
516
516
|
authToken?: string | undefined;
|
|
517
|
-
costMode?: "
|
|
517
|
+
costMode?: "lite" | "normal" | "max" | undefined;
|
|
518
518
|
}>, z.ZodObject<{
|
|
519
519
|
type: z.ZodLiteral<"prompt">;
|
|
520
520
|
promptId: z.ZodString;
|
|
@@ -536,13 +536,13 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
536
536
|
diffCached: z.ZodString;
|
|
537
537
|
lastCommitMessages: z.ZodString;
|
|
538
538
|
}, "strip", z.ZodTypeAny, {
|
|
539
|
-
status: string;
|
|
540
539
|
diff: string;
|
|
540
|
+
status: string;
|
|
541
541
|
diffCached: string;
|
|
542
542
|
lastCommitMessages: string;
|
|
543
543
|
}, {
|
|
544
|
-
status: string;
|
|
545
544
|
diff: string;
|
|
545
|
+
status: string;
|
|
546
546
|
diffCached: string;
|
|
547
547
|
lastCommitMessages: string;
|
|
548
548
|
}>;
|
|
@@ -586,8 +586,8 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
586
586
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
587
587
|
knowledgeFiles: Record<string, string>;
|
|
588
588
|
gitChanges: {
|
|
589
|
-
status: string;
|
|
590
589
|
diff: string;
|
|
590
|
+
status: string;
|
|
591
591
|
diffCached: string;
|
|
592
592
|
lastCommitMessages: string;
|
|
593
593
|
};
|
|
@@ -612,8 +612,8 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
612
612
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
613
613
|
knowledgeFiles: Record<string, string>;
|
|
614
614
|
gitChanges: {
|
|
615
|
-
status: string;
|
|
616
615
|
diff: string;
|
|
616
|
+
status: string;
|
|
617
617
|
diffCached: string;
|
|
618
618
|
lastCommitMessages: string;
|
|
619
619
|
};
|
|
@@ -646,14 +646,14 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
646
646
|
type: "ephemeral";
|
|
647
647
|
}>>;
|
|
648
648
|
}, "strip", z.ZodTypeAny, {
|
|
649
|
-
text: string;
|
|
650
649
|
type: "text";
|
|
650
|
+
text: string;
|
|
651
651
|
cache_control?: {
|
|
652
652
|
type: "ephemeral";
|
|
653
653
|
} | undefined;
|
|
654
654
|
}, {
|
|
655
|
-
text: string;
|
|
656
655
|
type: "text";
|
|
656
|
+
text: string;
|
|
657
657
|
cache_control?: {
|
|
658
658
|
type: "ephemeral";
|
|
659
659
|
} | undefined;
|
|
@@ -717,13 +717,13 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
717
717
|
media_type: z.ZodLiteral<"image/jpeg">;
|
|
718
718
|
data: z.ZodString;
|
|
719
719
|
}, "strip", z.ZodTypeAny, {
|
|
720
|
-
data: string;
|
|
721
720
|
type: "base64";
|
|
722
721
|
media_type: "image/jpeg";
|
|
723
|
-
}, {
|
|
724
722
|
data: string;
|
|
723
|
+
}, {
|
|
725
724
|
type: "base64";
|
|
726
725
|
media_type: "image/jpeg";
|
|
726
|
+
data: string;
|
|
727
727
|
}>;
|
|
728
728
|
cache_control: z.ZodOptional<z.ZodObject<{
|
|
729
729
|
type: z.ZodLiteral<"ephemeral">;
|
|
@@ -735,9 +735,9 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
735
735
|
}, "strip", z.ZodTypeAny, {
|
|
736
736
|
type: "image";
|
|
737
737
|
source: {
|
|
738
|
-
data: string;
|
|
739
738
|
type: "base64";
|
|
740
739
|
media_type: "image/jpeg";
|
|
740
|
+
data: string;
|
|
741
741
|
};
|
|
742
742
|
cache_control?: {
|
|
743
743
|
type: "ephemeral";
|
|
@@ -745,9 +745,9 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
745
745
|
}, {
|
|
746
746
|
type: "image";
|
|
747
747
|
source: {
|
|
748
|
-
data: string;
|
|
749
748
|
type: "base64";
|
|
750
749
|
media_type: "image/jpeg";
|
|
750
|
+
data: string;
|
|
751
751
|
};
|
|
752
752
|
cache_control?: {
|
|
753
753
|
type: "ephemeral";
|
|
@@ -755,8 +755,8 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
755
755
|
}>]>, "many">]>;
|
|
756
756
|
}, "strip", z.ZodTypeAny, {
|
|
757
757
|
content: string | ({
|
|
758
|
-
text: string;
|
|
759
758
|
type: "text";
|
|
759
|
+
text: string;
|
|
760
760
|
cache_control?: {
|
|
761
761
|
type: "ephemeral";
|
|
762
762
|
} | undefined;
|
|
@@ -778,9 +778,9 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
778
778
|
} | {
|
|
779
779
|
type: "image";
|
|
780
780
|
source: {
|
|
781
|
-
data: string;
|
|
782
781
|
type: "base64";
|
|
783
782
|
media_type: "image/jpeg";
|
|
783
|
+
data: string;
|
|
784
784
|
};
|
|
785
785
|
cache_control?: {
|
|
786
786
|
type: "ephemeral";
|
|
@@ -789,8 +789,8 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
789
789
|
role: "user" | "assistant";
|
|
790
790
|
}, {
|
|
791
791
|
content: string | ({
|
|
792
|
-
text: string;
|
|
793
792
|
type: "text";
|
|
793
|
+
text: string;
|
|
794
794
|
cache_control?: {
|
|
795
795
|
type: "ephemeral";
|
|
796
796
|
} | undefined;
|
|
@@ -812,9 +812,9 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
812
812
|
} | {
|
|
813
813
|
type: "image";
|
|
814
814
|
source: {
|
|
815
|
-
data: string;
|
|
816
815
|
type: "base64";
|
|
817
816
|
media_type: "image/jpeg";
|
|
817
|
+
data: string;
|
|
818
818
|
};
|
|
819
819
|
cache_control?: {
|
|
820
820
|
type: "ephemeral";
|
|
@@ -823,15 +823,14 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
823
823
|
role: "user" | "assistant";
|
|
824
824
|
}>, "many">;
|
|
825
825
|
}, "strip", z.ZodTypeAny, {
|
|
826
|
-
agentContext: string;
|
|
827
826
|
fileContext: {
|
|
828
827
|
currentWorkingDirectory: string;
|
|
829
828
|
fileTree: import("../util/file").FileTreeNode[];
|
|
830
829
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
831
830
|
knowledgeFiles: Record<string, string>;
|
|
832
831
|
gitChanges: {
|
|
833
|
-
status: string;
|
|
834
832
|
diff: string;
|
|
833
|
+
status: string;
|
|
835
834
|
diffCached: string;
|
|
836
835
|
lastCommitMessages: string;
|
|
837
836
|
};
|
|
@@ -851,10 +850,11 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
851
850
|
}[][];
|
|
852
851
|
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
853
852
|
};
|
|
853
|
+
agentContext: string;
|
|
854
854
|
messageHistory: {
|
|
855
855
|
content: string | ({
|
|
856
|
-
text: string;
|
|
857
856
|
type: "text";
|
|
857
|
+
text: string;
|
|
858
858
|
cache_control?: {
|
|
859
859
|
type: "ephemeral";
|
|
860
860
|
} | undefined;
|
|
@@ -876,9 +876,9 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
876
876
|
} | {
|
|
877
877
|
type: "image";
|
|
878
878
|
source: {
|
|
879
|
-
data: string;
|
|
880
879
|
type: "base64";
|
|
881
880
|
media_type: "image/jpeg";
|
|
881
|
+
data: string;
|
|
882
882
|
};
|
|
883
883
|
cache_control?: {
|
|
884
884
|
type: "ephemeral";
|
|
@@ -887,15 +887,14 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
887
887
|
role: "user" | "assistant";
|
|
888
888
|
}[];
|
|
889
889
|
}, {
|
|
890
|
-
agentContext: string;
|
|
891
890
|
fileContext: {
|
|
892
891
|
currentWorkingDirectory: string;
|
|
893
892
|
fileTree: import("../util/file").FileTreeNode[];
|
|
894
893
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
895
894
|
knowledgeFiles: Record<string, string>;
|
|
896
895
|
gitChanges: {
|
|
897
|
-
status: string;
|
|
898
896
|
diff: string;
|
|
897
|
+
status: string;
|
|
899
898
|
diffCached: string;
|
|
900
899
|
lastCommitMessages: string;
|
|
901
900
|
};
|
|
@@ -915,10 +914,11 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
915
914
|
}[][];
|
|
916
915
|
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
917
916
|
};
|
|
917
|
+
agentContext: string;
|
|
918
918
|
messageHistory: {
|
|
919
919
|
content: string | ({
|
|
920
|
-
text: string;
|
|
921
920
|
type: "text";
|
|
921
|
+
text: string;
|
|
922
922
|
cache_control?: {
|
|
923
923
|
type: "ephemeral";
|
|
924
924
|
} | undefined;
|
|
@@ -940,9 +940,9 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
940
940
|
} | {
|
|
941
941
|
type: "image";
|
|
942
942
|
source: {
|
|
943
|
-
data: string;
|
|
944
943
|
type: "base64";
|
|
945
944
|
media_type: "image/jpeg";
|
|
945
|
+
data: string;
|
|
946
946
|
};
|
|
947
947
|
cache_control?: {
|
|
948
948
|
type: "ephemeral";
|
|
@@ -967,18 +967,17 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
967
967
|
}, "strip", z.ZodTypeAny, {
|
|
968
968
|
type: "prompt";
|
|
969
969
|
fingerprintId: string;
|
|
970
|
-
costMode: "
|
|
970
|
+
costMode: "lite" | "normal" | "max";
|
|
971
971
|
promptId: string;
|
|
972
972
|
agentState: {
|
|
973
|
-
agentContext: string;
|
|
974
973
|
fileContext: {
|
|
975
974
|
currentWorkingDirectory: string;
|
|
976
975
|
fileTree: import("../util/file").FileTreeNode[];
|
|
977
976
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
978
977
|
knowledgeFiles: Record<string, string>;
|
|
979
978
|
gitChanges: {
|
|
980
|
-
status: string;
|
|
981
979
|
diff: string;
|
|
980
|
+
status: string;
|
|
982
981
|
diffCached: string;
|
|
983
982
|
lastCommitMessages: string;
|
|
984
983
|
};
|
|
@@ -998,10 +997,11 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
998
997
|
}[][];
|
|
999
998
|
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
1000
999
|
};
|
|
1000
|
+
agentContext: string;
|
|
1001
1001
|
messageHistory: {
|
|
1002
1002
|
content: string | ({
|
|
1003
|
-
text: string;
|
|
1004
1003
|
type: "text";
|
|
1004
|
+
text: string;
|
|
1005
1005
|
cache_control?: {
|
|
1006
1006
|
type: "ephemeral";
|
|
1007
1007
|
} | undefined;
|
|
@@ -1023,9 +1023,9 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
1023
1023
|
} | {
|
|
1024
1024
|
type: "image";
|
|
1025
1025
|
source: {
|
|
1026
|
-
data: string;
|
|
1027
1026
|
type: "base64";
|
|
1028
1027
|
media_type: "image/jpeg";
|
|
1028
|
+
data: string;
|
|
1029
1029
|
};
|
|
1030
1030
|
cache_control?: {
|
|
1031
1031
|
type: "ephemeral";
|
|
@@ -1046,15 +1046,14 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
1046
1046
|
fingerprintId: string;
|
|
1047
1047
|
promptId: string;
|
|
1048
1048
|
agentState: {
|
|
1049
|
-
agentContext: string;
|
|
1050
1049
|
fileContext: {
|
|
1051
1050
|
currentWorkingDirectory: string;
|
|
1052
1051
|
fileTree: import("../util/file").FileTreeNode[];
|
|
1053
1052
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
1054
1053
|
knowledgeFiles: Record<string, string>;
|
|
1055
1054
|
gitChanges: {
|
|
1056
|
-
status: string;
|
|
1057
1055
|
diff: string;
|
|
1056
|
+
status: string;
|
|
1058
1057
|
diffCached: string;
|
|
1059
1058
|
lastCommitMessages: string;
|
|
1060
1059
|
};
|
|
@@ -1074,10 +1073,11 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
1074
1073
|
}[][];
|
|
1075
1074
|
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
1076
1075
|
};
|
|
1076
|
+
agentContext: string;
|
|
1077
1077
|
messageHistory: {
|
|
1078
1078
|
content: string | ({
|
|
1079
|
-
text: string;
|
|
1080
1079
|
type: "text";
|
|
1080
|
+
text: string;
|
|
1081
1081
|
cache_control?: {
|
|
1082
1082
|
type: "ephemeral";
|
|
1083
1083
|
} | undefined;
|
|
@@ -1099,9 +1099,9 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
1099
1099
|
} | {
|
|
1100
1100
|
type: "image";
|
|
1101
1101
|
source: {
|
|
1102
|
-
data: string;
|
|
1103
1102
|
type: "base64";
|
|
1104
1103
|
media_type: "image/jpeg";
|
|
1104
|
+
data: string;
|
|
1105
1105
|
};
|
|
1106
1106
|
cache_control?: {
|
|
1107
1107
|
type: "ephemeral";
|
|
@@ -1116,7 +1116,7 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
1116
1116
|
result: string;
|
|
1117
1117
|
}[];
|
|
1118
1118
|
authToken?: string | undefined;
|
|
1119
|
-
costMode?: "
|
|
1119
|
+
costMode?: "lite" | "normal" | "max" | undefined;
|
|
1120
1120
|
prompt?: string | undefined;
|
|
1121
1121
|
}>, z.ZodObject<{
|
|
1122
1122
|
type: z.ZodLiteral<"read-files-response">;
|
|
@@ -1146,13 +1146,13 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
1146
1146
|
diffCached: z.ZodString;
|
|
1147
1147
|
lastCommitMessages: z.ZodString;
|
|
1148
1148
|
}, "strip", z.ZodTypeAny, {
|
|
1149
|
-
status: string;
|
|
1150
1149
|
diff: string;
|
|
1150
|
+
status: string;
|
|
1151
1151
|
diffCached: string;
|
|
1152
1152
|
lastCommitMessages: string;
|
|
1153
1153
|
}, {
|
|
1154
|
-
status: string;
|
|
1155
1154
|
diff: string;
|
|
1155
|
+
status: string;
|
|
1156
1156
|
diffCached: string;
|
|
1157
1157
|
lastCommitMessages: string;
|
|
1158
1158
|
}>;
|
|
@@ -1196,8 +1196,8 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
1196
1196
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
1197
1197
|
knowledgeFiles: Record<string, string>;
|
|
1198
1198
|
gitChanges: {
|
|
1199
|
-
status: string;
|
|
1200
1199
|
diff: string;
|
|
1200
|
+
status: string;
|
|
1201
1201
|
diffCached: string;
|
|
1202
1202
|
lastCommitMessages: string;
|
|
1203
1203
|
};
|
|
@@ -1222,8 +1222,8 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
1222
1222
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
1223
1223
|
knowledgeFiles: Record<string, string>;
|
|
1224
1224
|
gitChanges: {
|
|
1225
|
-
status: string;
|
|
1226
1225
|
diff: string;
|
|
1226
|
+
status: string;
|
|
1227
1227
|
diffCached: string;
|
|
1228
1228
|
lastCommitMessages: string;
|
|
1229
1229
|
};
|
|
@@ -1245,14 +1245,15 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
1245
1245
|
}>;
|
|
1246
1246
|
}, "strip", z.ZodTypeAny, {
|
|
1247
1247
|
type: "init";
|
|
1248
|
+
fingerprintId: string;
|
|
1248
1249
|
fileContext: {
|
|
1249
1250
|
currentWorkingDirectory: string;
|
|
1250
1251
|
fileTree: import("../util/file").FileTreeNode[];
|
|
1251
1252
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
1252
1253
|
knowledgeFiles: Record<string, string>;
|
|
1253
1254
|
gitChanges: {
|
|
1254
|
-
status: string;
|
|
1255
1255
|
diff: string;
|
|
1256
|
+
status: string;
|
|
1256
1257
|
diffCached: string;
|
|
1257
1258
|
lastCommitMessages: string;
|
|
1258
1259
|
};
|
|
@@ -1272,18 +1273,18 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
1272
1273
|
}[][];
|
|
1273
1274
|
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
1274
1275
|
};
|
|
1275
|
-
fingerprintId: string;
|
|
1276
1276
|
authToken?: string | undefined;
|
|
1277
1277
|
}, {
|
|
1278
1278
|
type: "init";
|
|
1279
|
+
fingerprintId: string;
|
|
1279
1280
|
fileContext: {
|
|
1280
1281
|
currentWorkingDirectory: string;
|
|
1281
1282
|
fileTree: import("../util/file").FileTreeNode[];
|
|
1282
1283
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
1283
1284
|
knowledgeFiles: Record<string, string>;
|
|
1284
1285
|
gitChanges: {
|
|
1285
|
-
status: string;
|
|
1286
1286
|
diff: string;
|
|
1287
|
+
status: string;
|
|
1287
1288
|
diffCached: string;
|
|
1288
1289
|
lastCommitMessages: string;
|
|
1289
1290
|
};
|
|
@@ -1303,7 +1304,6 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
1303
1304
|
}[][];
|
|
1304
1305
|
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
1305
1306
|
};
|
|
1306
|
-
fingerprintId: string;
|
|
1307
1307
|
authToken?: string | undefined;
|
|
1308
1308
|
}>, z.ZodObject<{
|
|
1309
1309
|
type: z.ZodLiteral<"usage">;
|
|
@@ -1334,41 +1334,15 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
1334
1334
|
authToken?: string | undefined;
|
|
1335
1335
|
}>]>;
|
|
1336
1336
|
}, "strip", z.ZodTypeAny, {
|
|
1337
|
+
type: "action";
|
|
1337
1338
|
data: {
|
|
1338
1339
|
type: "user-input";
|
|
1339
|
-
fileContext: {
|
|
1340
|
-
currentWorkingDirectory: string;
|
|
1341
|
-
fileTree: import("../util/file").FileTreeNode[];
|
|
1342
|
-
fileTokenScores: Record<string, Record<string, number>>;
|
|
1343
|
-
knowledgeFiles: Record<string, string>;
|
|
1344
|
-
gitChanges: {
|
|
1345
|
-
status: string;
|
|
1346
|
-
diff: string;
|
|
1347
|
-
diffCached: string;
|
|
1348
|
-
lastCommitMessages: string;
|
|
1349
|
-
};
|
|
1350
|
-
changesSinceLastChat: Record<string, string>;
|
|
1351
|
-
shellConfigFiles: Record<string, string>;
|
|
1352
|
-
systemInfo: {
|
|
1353
|
-
platform: string;
|
|
1354
|
-
shell: string;
|
|
1355
|
-
nodeVersion: string;
|
|
1356
|
-
arch: string;
|
|
1357
|
-
homedir: string;
|
|
1358
|
-
cpus: number;
|
|
1359
|
-
};
|
|
1360
|
-
fileVersions: {
|
|
1361
|
-
path: string;
|
|
1362
|
-
content: string;
|
|
1363
|
-
}[][];
|
|
1364
|
-
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
1365
|
-
};
|
|
1366
1340
|
fingerprintId: string;
|
|
1367
1341
|
userInputId: string;
|
|
1368
1342
|
messages: {
|
|
1369
1343
|
content: string | ({
|
|
1370
|
-
text: string;
|
|
1371
1344
|
type: "text";
|
|
1345
|
+
text: string;
|
|
1372
1346
|
cache_control?: {
|
|
1373
1347
|
type: "ephemeral";
|
|
1374
1348
|
} | undefined;
|
|
@@ -1390,9 +1364,9 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
1390
1364
|
} | {
|
|
1391
1365
|
type: "image";
|
|
1392
1366
|
source: {
|
|
1393
|
-
data: string;
|
|
1394
1367
|
type: "base64";
|
|
1395
1368
|
media_type: "image/jpeg";
|
|
1369
|
+
data: string;
|
|
1396
1370
|
};
|
|
1397
1371
|
cache_control?: {
|
|
1398
1372
|
type: "ephemeral";
|
|
@@ -1400,28 +1374,54 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
1400
1374
|
})[];
|
|
1401
1375
|
role: "user" | "assistant";
|
|
1402
1376
|
}[];
|
|
1377
|
+
fileContext: {
|
|
1378
|
+
currentWorkingDirectory: string;
|
|
1379
|
+
fileTree: import("../util/file").FileTreeNode[];
|
|
1380
|
+
fileTokenScores: Record<string, Record<string, number>>;
|
|
1381
|
+
knowledgeFiles: Record<string, string>;
|
|
1382
|
+
gitChanges: {
|
|
1383
|
+
diff: string;
|
|
1384
|
+
status: string;
|
|
1385
|
+
diffCached: string;
|
|
1386
|
+
lastCommitMessages: string;
|
|
1387
|
+
};
|
|
1388
|
+
changesSinceLastChat: Record<string, string>;
|
|
1389
|
+
shellConfigFiles: Record<string, string>;
|
|
1390
|
+
systemInfo: {
|
|
1391
|
+
platform: string;
|
|
1392
|
+
shell: string;
|
|
1393
|
+
nodeVersion: string;
|
|
1394
|
+
arch: string;
|
|
1395
|
+
homedir: string;
|
|
1396
|
+
cpus: number;
|
|
1397
|
+
};
|
|
1398
|
+
fileVersions: {
|
|
1399
|
+
path: string;
|
|
1400
|
+
content: string;
|
|
1401
|
+
}[][];
|
|
1402
|
+
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
1403
|
+
};
|
|
1403
1404
|
changesAlreadyApplied: {
|
|
1405
|
+
type: "patch" | "file";
|
|
1404
1406
|
path: string;
|
|
1405
|
-
type: "file" | "patch";
|
|
1406
1407
|
content: string;
|
|
1407
1408
|
}[];
|
|
1408
|
-
costMode: "
|
|
1409
|
+
costMode: "lite" | "normal" | "max";
|
|
1409
1410
|
authToken?: string | undefined;
|
|
1410
1411
|
} | {
|
|
1411
1412
|
type: "prompt";
|
|
1412
1413
|
fingerprintId: string;
|
|
1413
|
-
costMode: "
|
|
1414
|
+
costMode: "lite" | "normal" | "max";
|
|
1414
1415
|
promptId: string;
|
|
1415
1416
|
agentState: {
|
|
1416
|
-
agentContext: string;
|
|
1417
1417
|
fileContext: {
|
|
1418
1418
|
currentWorkingDirectory: string;
|
|
1419
1419
|
fileTree: import("../util/file").FileTreeNode[];
|
|
1420
1420
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
1421
1421
|
knowledgeFiles: Record<string, string>;
|
|
1422
1422
|
gitChanges: {
|
|
1423
|
-
status: string;
|
|
1424
1423
|
diff: string;
|
|
1424
|
+
status: string;
|
|
1425
1425
|
diffCached: string;
|
|
1426
1426
|
lastCommitMessages: string;
|
|
1427
1427
|
};
|
|
@@ -1441,10 +1441,11 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
1441
1441
|
}[][];
|
|
1442
1442
|
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
1443
1443
|
};
|
|
1444
|
+
agentContext: string;
|
|
1444
1445
|
messageHistory: {
|
|
1445
1446
|
content: string | ({
|
|
1446
|
-
text: string;
|
|
1447
1447
|
type: "text";
|
|
1448
|
+
text: string;
|
|
1448
1449
|
cache_control?: {
|
|
1449
1450
|
type: "ephemeral";
|
|
1450
1451
|
} | undefined;
|
|
@@ -1466,9 +1467,9 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
1466
1467
|
} | {
|
|
1467
1468
|
type: "image";
|
|
1468
1469
|
source: {
|
|
1469
|
-
data: string;
|
|
1470
1470
|
type: "base64";
|
|
1471
1471
|
media_type: "image/jpeg";
|
|
1472
|
+
data: string;
|
|
1472
1473
|
};
|
|
1473
1474
|
cache_control?: {
|
|
1474
1475
|
type: "ephemeral";
|
|
@@ -1490,14 +1491,15 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
1490
1491
|
requestId?: string | undefined;
|
|
1491
1492
|
} | {
|
|
1492
1493
|
type: "init";
|
|
1494
|
+
fingerprintId: string;
|
|
1493
1495
|
fileContext: {
|
|
1494
1496
|
currentWorkingDirectory: string;
|
|
1495
1497
|
fileTree: import("../util/file").FileTreeNode[];
|
|
1496
1498
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
1497
1499
|
knowledgeFiles: Record<string, string>;
|
|
1498
1500
|
gitChanges: {
|
|
1499
|
-
status: string;
|
|
1500
1501
|
diff: string;
|
|
1502
|
+
status: string;
|
|
1501
1503
|
diffCached: string;
|
|
1502
1504
|
lastCommitMessages: string;
|
|
1503
1505
|
};
|
|
@@ -1517,7 +1519,6 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
1517
1519
|
}[][];
|
|
1518
1520
|
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
1519
1521
|
};
|
|
1520
|
-
fingerprintId: string;
|
|
1521
1522
|
authToken?: string | undefined;
|
|
1522
1523
|
} | {
|
|
1523
1524
|
type: "usage";
|
|
@@ -1529,44 +1530,17 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
1529
1530
|
stagedChanges: string;
|
|
1530
1531
|
authToken?: string | undefined;
|
|
1531
1532
|
};
|
|
1532
|
-
type: "action";
|
|
1533
1533
|
txid: number;
|
|
1534
1534
|
}, {
|
|
1535
|
+
type: "action";
|
|
1535
1536
|
data: {
|
|
1536
1537
|
type: "user-input";
|
|
1537
|
-
fileContext: {
|
|
1538
|
-
currentWorkingDirectory: string;
|
|
1539
|
-
fileTree: import("../util/file").FileTreeNode[];
|
|
1540
|
-
fileTokenScores: Record<string, Record<string, number>>;
|
|
1541
|
-
knowledgeFiles: Record<string, string>;
|
|
1542
|
-
gitChanges: {
|
|
1543
|
-
status: string;
|
|
1544
|
-
diff: string;
|
|
1545
|
-
diffCached: string;
|
|
1546
|
-
lastCommitMessages: string;
|
|
1547
|
-
};
|
|
1548
|
-
changesSinceLastChat: Record<string, string>;
|
|
1549
|
-
shellConfigFiles: Record<string, string>;
|
|
1550
|
-
systemInfo: {
|
|
1551
|
-
platform: string;
|
|
1552
|
-
shell: string;
|
|
1553
|
-
nodeVersion: string;
|
|
1554
|
-
arch: string;
|
|
1555
|
-
homedir: string;
|
|
1556
|
-
cpus: number;
|
|
1557
|
-
};
|
|
1558
|
-
fileVersions: {
|
|
1559
|
-
path: string;
|
|
1560
|
-
content: string;
|
|
1561
|
-
}[][];
|
|
1562
|
-
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
1563
|
-
};
|
|
1564
1538
|
fingerprintId: string;
|
|
1565
1539
|
userInputId: string;
|
|
1566
1540
|
messages: {
|
|
1567
1541
|
content: string | ({
|
|
1568
|
-
text: string;
|
|
1569
1542
|
type: "text";
|
|
1543
|
+
text: string;
|
|
1570
1544
|
cache_control?: {
|
|
1571
1545
|
type: "ephemeral";
|
|
1572
1546
|
} | undefined;
|
|
@@ -1588,9 +1562,9 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
1588
1562
|
} | {
|
|
1589
1563
|
type: "image";
|
|
1590
1564
|
source: {
|
|
1591
|
-
data: string;
|
|
1592
1565
|
type: "base64";
|
|
1593
1566
|
media_type: "image/jpeg";
|
|
1567
|
+
data: string;
|
|
1594
1568
|
};
|
|
1595
1569
|
cache_control?: {
|
|
1596
1570
|
type: "ephemeral";
|
|
@@ -1598,27 +1572,53 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
1598
1572
|
})[];
|
|
1599
1573
|
role: "user" | "assistant";
|
|
1600
1574
|
}[];
|
|
1575
|
+
fileContext: {
|
|
1576
|
+
currentWorkingDirectory: string;
|
|
1577
|
+
fileTree: import("../util/file").FileTreeNode[];
|
|
1578
|
+
fileTokenScores: Record<string, Record<string, number>>;
|
|
1579
|
+
knowledgeFiles: Record<string, string>;
|
|
1580
|
+
gitChanges: {
|
|
1581
|
+
diff: string;
|
|
1582
|
+
status: string;
|
|
1583
|
+
diffCached: string;
|
|
1584
|
+
lastCommitMessages: string;
|
|
1585
|
+
};
|
|
1586
|
+
changesSinceLastChat: Record<string, string>;
|
|
1587
|
+
shellConfigFiles: Record<string, string>;
|
|
1588
|
+
systemInfo: {
|
|
1589
|
+
platform: string;
|
|
1590
|
+
shell: string;
|
|
1591
|
+
nodeVersion: string;
|
|
1592
|
+
arch: string;
|
|
1593
|
+
homedir: string;
|
|
1594
|
+
cpus: number;
|
|
1595
|
+
};
|
|
1596
|
+
fileVersions: {
|
|
1597
|
+
path: string;
|
|
1598
|
+
content: string;
|
|
1599
|
+
}[][];
|
|
1600
|
+
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
1601
|
+
};
|
|
1601
1602
|
changesAlreadyApplied: {
|
|
1603
|
+
type: "patch" | "file";
|
|
1602
1604
|
path: string;
|
|
1603
|
-
type: "file" | "patch";
|
|
1604
1605
|
content: string;
|
|
1605
1606
|
}[];
|
|
1606
1607
|
authToken?: string | undefined;
|
|
1607
|
-
costMode?: "
|
|
1608
|
+
costMode?: "lite" | "normal" | "max" | undefined;
|
|
1608
1609
|
} | {
|
|
1609
1610
|
type: "prompt";
|
|
1610
1611
|
fingerprintId: string;
|
|
1611
1612
|
promptId: string;
|
|
1612
1613
|
agentState: {
|
|
1613
|
-
agentContext: string;
|
|
1614
1614
|
fileContext: {
|
|
1615
1615
|
currentWorkingDirectory: string;
|
|
1616
1616
|
fileTree: import("../util/file").FileTreeNode[];
|
|
1617
1617
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
1618
1618
|
knowledgeFiles: Record<string, string>;
|
|
1619
1619
|
gitChanges: {
|
|
1620
|
-
status: string;
|
|
1621
1620
|
diff: string;
|
|
1621
|
+
status: string;
|
|
1622
1622
|
diffCached: string;
|
|
1623
1623
|
lastCommitMessages: string;
|
|
1624
1624
|
};
|
|
@@ -1638,10 +1638,11 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
1638
1638
|
}[][];
|
|
1639
1639
|
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
1640
1640
|
};
|
|
1641
|
+
agentContext: string;
|
|
1641
1642
|
messageHistory: {
|
|
1642
1643
|
content: string | ({
|
|
1643
|
-
text: string;
|
|
1644
1644
|
type: "text";
|
|
1645
|
+
text: string;
|
|
1645
1646
|
cache_control?: {
|
|
1646
1647
|
type: "ephemeral";
|
|
1647
1648
|
} | undefined;
|
|
@@ -1663,9 +1664,9 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
1663
1664
|
} | {
|
|
1664
1665
|
type: "image";
|
|
1665
1666
|
source: {
|
|
1666
|
-
data: string;
|
|
1667
1667
|
type: "base64";
|
|
1668
1668
|
media_type: "image/jpeg";
|
|
1669
|
+
data: string;
|
|
1669
1670
|
};
|
|
1670
1671
|
cache_control?: {
|
|
1671
1672
|
type: "ephemeral";
|
|
@@ -1680,7 +1681,7 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
1680
1681
|
result: string;
|
|
1681
1682
|
}[];
|
|
1682
1683
|
authToken?: string | undefined;
|
|
1683
|
-
costMode?: "
|
|
1684
|
+
costMode?: "lite" | "normal" | "max" | undefined;
|
|
1684
1685
|
prompt?: string | undefined;
|
|
1685
1686
|
} | {
|
|
1686
1687
|
type: "read-files-response";
|
|
@@ -1688,14 +1689,15 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
1688
1689
|
requestId?: string | undefined;
|
|
1689
1690
|
} | {
|
|
1690
1691
|
type: "init";
|
|
1692
|
+
fingerprintId: string;
|
|
1691
1693
|
fileContext: {
|
|
1692
1694
|
currentWorkingDirectory: string;
|
|
1693
1695
|
fileTree: import("../util/file").FileTreeNode[];
|
|
1694
1696
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
1695
1697
|
knowledgeFiles: Record<string, string>;
|
|
1696
1698
|
gitChanges: {
|
|
1697
|
-
status: string;
|
|
1698
1699
|
diff: string;
|
|
1700
|
+
status: string;
|
|
1699
1701
|
diffCached: string;
|
|
1700
1702
|
lastCommitMessages: string;
|
|
1701
1703
|
};
|
|
@@ -1715,7 +1717,6 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
1715
1717
|
}[][];
|
|
1716
1718
|
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
1717
1719
|
};
|
|
1718
|
-
fingerprintId: string;
|
|
1719
1720
|
authToken?: string | undefined;
|
|
1720
1721
|
} | {
|
|
1721
1722
|
type: "usage";
|
|
@@ -1727,7 +1728,6 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
|
|
|
1727
1728
|
stagedChanges: string;
|
|
1728
1729
|
authToken?: string | undefined;
|
|
1729
1730
|
};
|
|
1730
|
-
type: "action";
|
|
1731
1731
|
txid: number;
|
|
1732
1732
|
}>;
|
|
1733
1733
|
};
|
|
@@ -1797,14 +1797,14 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
1797
1797
|
type: "ephemeral";
|
|
1798
1798
|
}>>;
|
|
1799
1799
|
}, "strip", z.ZodTypeAny, {
|
|
1800
|
-
text: string;
|
|
1801
1800
|
type: "text";
|
|
1801
|
+
text: string;
|
|
1802
1802
|
cache_control?: {
|
|
1803
1803
|
type: "ephemeral";
|
|
1804
1804
|
} | undefined;
|
|
1805
1805
|
}, {
|
|
1806
|
-
text: string;
|
|
1807
1806
|
type: "text";
|
|
1807
|
+
text: string;
|
|
1808
1808
|
cache_control?: {
|
|
1809
1809
|
type: "ephemeral";
|
|
1810
1810
|
} | undefined;
|
|
@@ -1868,13 +1868,13 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
1868
1868
|
media_type: z.ZodLiteral<"image/jpeg">;
|
|
1869
1869
|
data: z.ZodString;
|
|
1870
1870
|
}, "strip", z.ZodTypeAny, {
|
|
1871
|
-
data: string;
|
|
1872
1871
|
type: "base64";
|
|
1873
1872
|
media_type: "image/jpeg";
|
|
1874
|
-
}, {
|
|
1875
1873
|
data: string;
|
|
1874
|
+
}, {
|
|
1876
1875
|
type: "base64";
|
|
1877
1876
|
media_type: "image/jpeg";
|
|
1877
|
+
data: string;
|
|
1878
1878
|
}>;
|
|
1879
1879
|
cache_control: z.ZodOptional<z.ZodObject<{
|
|
1880
1880
|
type: z.ZodLiteral<"ephemeral">;
|
|
@@ -1886,9 +1886,9 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
1886
1886
|
}, "strip", z.ZodTypeAny, {
|
|
1887
1887
|
type: "image";
|
|
1888
1888
|
source: {
|
|
1889
|
-
data: string;
|
|
1890
1889
|
type: "base64";
|
|
1891
1890
|
media_type: "image/jpeg";
|
|
1891
|
+
data: string;
|
|
1892
1892
|
};
|
|
1893
1893
|
cache_control?: {
|
|
1894
1894
|
type: "ephemeral";
|
|
@@ -1896,9 +1896,9 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
1896
1896
|
}, {
|
|
1897
1897
|
type: "image";
|
|
1898
1898
|
source: {
|
|
1899
|
-
data: string;
|
|
1900
1899
|
type: "base64";
|
|
1901
1900
|
media_type: "image/jpeg";
|
|
1901
|
+
data: string;
|
|
1902
1902
|
};
|
|
1903
1903
|
cache_control?: {
|
|
1904
1904
|
type: "ephemeral";
|
|
@@ -1906,8 +1906,8 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
1906
1906
|
}>]>, "many">]>;
|
|
1907
1907
|
}, "strip", z.ZodTypeAny, {
|
|
1908
1908
|
content: string | ({
|
|
1909
|
-
text: string;
|
|
1910
1909
|
type: "text";
|
|
1910
|
+
text: string;
|
|
1911
1911
|
cache_control?: {
|
|
1912
1912
|
type: "ephemeral";
|
|
1913
1913
|
} | undefined;
|
|
@@ -1929,9 +1929,9 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
1929
1929
|
} | {
|
|
1930
1930
|
type: "image";
|
|
1931
1931
|
source: {
|
|
1932
|
-
data: string;
|
|
1933
1932
|
type: "base64";
|
|
1934
1933
|
media_type: "image/jpeg";
|
|
1934
|
+
data: string;
|
|
1935
1935
|
};
|
|
1936
1936
|
cache_control?: {
|
|
1937
1937
|
type: "ephemeral";
|
|
@@ -1940,8 +1940,8 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
1940
1940
|
role: "user" | "assistant";
|
|
1941
1941
|
}, {
|
|
1942
1942
|
content: string | ({
|
|
1943
|
-
text: string;
|
|
1944
1943
|
type: "text";
|
|
1944
|
+
text: string;
|
|
1945
1945
|
cache_control?: {
|
|
1946
1946
|
type: "ephemeral";
|
|
1947
1947
|
} | undefined;
|
|
@@ -1963,9 +1963,9 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
1963
1963
|
} | {
|
|
1964
1964
|
type: "image";
|
|
1965
1965
|
source: {
|
|
1966
|
-
data: string;
|
|
1967
1966
|
type: "base64";
|
|
1968
1967
|
media_type: "image/jpeg";
|
|
1968
|
+
data: string;
|
|
1969
1969
|
};
|
|
1970
1970
|
cache_control?: {
|
|
1971
1971
|
type: "ephemeral";
|
|
@@ -1985,13 +1985,13 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
1985
1985
|
diffCached: z.ZodString;
|
|
1986
1986
|
lastCommitMessages: z.ZodString;
|
|
1987
1987
|
}, "strip", z.ZodTypeAny, {
|
|
1988
|
-
status: string;
|
|
1989
1988
|
diff: string;
|
|
1989
|
+
status: string;
|
|
1990
1990
|
diffCached: string;
|
|
1991
1991
|
lastCommitMessages: string;
|
|
1992
1992
|
}, {
|
|
1993
|
-
status: string;
|
|
1994
1993
|
diff: string;
|
|
1994
|
+
status: string;
|
|
1995
1995
|
diffCached: string;
|
|
1996
1996
|
lastCommitMessages: string;
|
|
1997
1997
|
}>;
|
|
@@ -2035,8 +2035,8 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
2035
2035
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
2036
2036
|
knowledgeFiles: Record<string, string>;
|
|
2037
2037
|
gitChanges: {
|
|
2038
|
-
status: string;
|
|
2039
2038
|
diff: string;
|
|
2039
|
+
status: string;
|
|
2040
2040
|
diffCached: string;
|
|
2041
2041
|
lastCommitMessages: string;
|
|
2042
2042
|
};
|
|
@@ -2061,8 +2061,8 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
2061
2061
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
2062
2062
|
knowledgeFiles: Record<string, string>;
|
|
2063
2063
|
gitChanges: {
|
|
2064
|
-
status: string;
|
|
2065
2064
|
diff: string;
|
|
2065
|
+
status: string;
|
|
2066
2066
|
diffCached: string;
|
|
2067
2067
|
lastCommitMessages: string;
|
|
2068
2068
|
};
|
|
@@ -2087,50 +2087,23 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
2087
2087
|
path: z.ZodString;
|
|
2088
2088
|
content: z.ZodString;
|
|
2089
2089
|
}, "strip", z.ZodTypeAny, {
|
|
2090
|
+
type: "patch" | "file";
|
|
2090
2091
|
path: string;
|
|
2091
|
-
type: "file" | "patch";
|
|
2092
2092
|
content: string;
|
|
2093
2093
|
}, {
|
|
2094
|
+
type: "patch" | "file";
|
|
2094
2095
|
path: string;
|
|
2095
|
-
type: "file" | "patch";
|
|
2096
2096
|
content: string;
|
|
2097
2097
|
}>, "many">;
|
|
2098
2098
|
costMode: z.ZodDefault<z.ZodOptional<z.ZodEnum<["lite", "normal", "max"]>>>;
|
|
2099
2099
|
}, "strip", z.ZodTypeAny, {
|
|
2100
2100
|
type: "user-input";
|
|
2101
|
-
fileContext: {
|
|
2102
|
-
currentWorkingDirectory: string;
|
|
2103
|
-
fileTree: import("../util/file").FileTreeNode[];
|
|
2104
|
-
fileTokenScores: Record<string, Record<string, number>>;
|
|
2105
|
-
knowledgeFiles: Record<string, string>;
|
|
2106
|
-
gitChanges: {
|
|
2107
|
-
status: string;
|
|
2108
|
-
diff: string;
|
|
2109
|
-
diffCached: string;
|
|
2110
|
-
lastCommitMessages: string;
|
|
2111
|
-
};
|
|
2112
|
-
changesSinceLastChat: Record<string, string>;
|
|
2113
|
-
shellConfigFiles: Record<string, string>;
|
|
2114
|
-
systemInfo: {
|
|
2115
|
-
platform: string;
|
|
2116
|
-
shell: string;
|
|
2117
|
-
nodeVersion: string;
|
|
2118
|
-
arch: string;
|
|
2119
|
-
homedir: string;
|
|
2120
|
-
cpus: number;
|
|
2121
|
-
};
|
|
2122
|
-
fileVersions: {
|
|
2123
|
-
path: string;
|
|
2124
|
-
content: string;
|
|
2125
|
-
}[][];
|
|
2126
|
-
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
2127
|
-
};
|
|
2128
2101
|
fingerprintId: string;
|
|
2129
2102
|
userInputId: string;
|
|
2130
2103
|
messages: {
|
|
2131
2104
|
content: string | ({
|
|
2132
|
-
text: string;
|
|
2133
2105
|
type: "text";
|
|
2106
|
+
text: string;
|
|
2134
2107
|
cache_control?: {
|
|
2135
2108
|
type: "ephemeral";
|
|
2136
2109
|
} | undefined;
|
|
@@ -2152,9 +2125,9 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
2152
2125
|
} | {
|
|
2153
2126
|
type: "image";
|
|
2154
2127
|
source: {
|
|
2155
|
-
data: string;
|
|
2156
2128
|
type: "base64";
|
|
2157
2129
|
media_type: "image/jpeg";
|
|
2130
|
+
data: string;
|
|
2158
2131
|
};
|
|
2159
2132
|
cache_control?: {
|
|
2160
2133
|
type: "ephemeral";
|
|
@@ -2162,23 +2135,14 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
2162
2135
|
})[];
|
|
2163
2136
|
role: "user" | "assistant";
|
|
2164
2137
|
}[];
|
|
2165
|
-
changesAlreadyApplied: {
|
|
2166
|
-
path: string;
|
|
2167
|
-
type: "file" | "patch";
|
|
2168
|
-
content: string;
|
|
2169
|
-
}[];
|
|
2170
|
-
costMode: "max" | "lite" | "normal";
|
|
2171
|
-
authToken?: string | undefined;
|
|
2172
|
-
}, {
|
|
2173
|
-
type: "user-input";
|
|
2174
2138
|
fileContext: {
|
|
2175
2139
|
currentWorkingDirectory: string;
|
|
2176
2140
|
fileTree: import("../util/file").FileTreeNode[];
|
|
2177
2141
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
2178
2142
|
knowledgeFiles: Record<string, string>;
|
|
2179
2143
|
gitChanges: {
|
|
2180
|
-
status: string;
|
|
2181
2144
|
diff: string;
|
|
2145
|
+
status: string;
|
|
2182
2146
|
diffCached: string;
|
|
2183
2147
|
lastCommitMessages: string;
|
|
2184
2148
|
};
|
|
@@ -2198,12 +2162,21 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
2198
2162
|
}[][];
|
|
2199
2163
|
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
2200
2164
|
};
|
|
2165
|
+
changesAlreadyApplied: {
|
|
2166
|
+
type: "patch" | "file";
|
|
2167
|
+
path: string;
|
|
2168
|
+
content: string;
|
|
2169
|
+
}[];
|
|
2170
|
+
costMode: "lite" | "normal" | "max";
|
|
2171
|
+
authToken?: string | undefined;
|
|
2172
|
+
}, {
|
|
2173
|
+
type: "user-input";
|
|
2201
2174
|
fingerprintId: string;
|
|
2202
2175
|
userInputId: string;
|
|
2203
2176
|
messages: {
|
|
2204
2177
|
content: string | ({
|
|
2205
|
-
text: string;
|
|
2206
2178
|
type: "text";
|
|
2179
|
+
text: string;
|
|
2207
2180
|
cache_control?: {
|
|
2208
2181
|
type: "ephemeral";
|
|
2209
2182
|
} | undefined;
|
|
@@ -2225,9 +2198,9 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
2225
2198
|
} | {
|
|
2226
2199
|
type: "image";
|
|
2227
2200
|
source: {
|
|
2228
|
-
data: string;
|
|
2229
2201
|
type: "base64";
|
|
2230
2202
|
media_type: "image/jpeg";
|
|
2203
|
+
data: string;
|
|
2231
2204
|
};
|
|
2232
2205
|
cache_control?: {
|
|
2233
2206
|
type: "ephemeral";
|
|
@@ -2235,13 +2208,40 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
2235
2208
|
})[];
|
|
2236
2209
|
role: "user" | "assistant";
|
|
2237
2210
|
}[];
|
|
2211
|
+
fileContext: {
|
|
2212
|
+
currentWorkingDirectory: string;
|
|
2213
|
+
fileTree: import("../util/file").FileTreeNode[];
|
|
2214
|
+
fileTokenScores: Record<string, Record<string, number>>;
|
|
2215
|
+
knowledgeFiles: Record<string, string>;
|
|
2216
|
+
gitChanges: {
|
|
2217
|
+
diff: string;
|
|
2218
|
+
status: string;
|
|
2219
|
+
diffCached: string;
|
|
2220
|
+
lastCommitMessages: string;
|
|
2221
|
+
};
|
|
2222
|
+
changesSinceLastChat: Record<string, string>;
|
|
2223
|
+
shellConfigFiles: Record<string, string>;
|
|
2224
|
+
systemInfo: {
|
|
2225
|
+
platform: string;
|
|
2226
|
+
shell: string;
|
|
2227
|
+
nodeVersion: string;
|
|
2228
|
+
arch: string;
|
|
2229
|
+
homedir: string;
|
|
2230
|
+
cpus: number;
|
|
2231
|
+
};
|
|
2232
|
+
fileVersions: {
|
|
2233
|
+
path: string;
|
|
2234
|
+
content: string;
|
|
2235
|
+
}[][];
|
|
2236
|
+
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
2237
|
+
};
|
|
2238
2238
|
changesAlreadyApplied: {
|
|
2239
|
+
type: "patch" | "file";
|
|
2239
2240
|
path: string;
|
|
2240
|
-
type: "file" | "patch";
|
|
2241
2241
|
content: string;
|
|
2242
2242
|
}[];
|
|
2243
2243
|
authToken?: string | undefined;
|
|
2244
|
-
costMode?: "
|
|
2244
|
+
costMode?: "lite" | "normal" | "max" | undefined;
|
|
2245
2245
|
}>, z.ZodObject<{
|
|
2246
2246
|
type: z.ZodLiteral<"prompt">;
|
|
2247
2247
|
promptId: z.ZodString;
|
|
@@ -2263,13 +2263,13 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
2263
2263
|
diffCached: z.ZodString;
|
|
2264
2264
|
lastCommitMessages: z.ZodString;
|
|
2265
2265
|
}, "strip", z.ZodTypeAny, {
|
|
2266
|
-
status: string;
|
|
2267
2266
|
diff: string;
|
|
2267
|
+
status: string;
|
|
2268
2268
|
diffCached: string;
|
|
2269
2269
|
lastCommitMessages: string;
|
|
2270
2270
|
}, {
|
|
2271
|
-
status: string;
|
|
2272
2271
|
diff: string;
|
|
2272
|
+
status: string;
|
|
2273
2273
|
diffCached: string;
|
|
2274
2274
|
lastCommitMessages: string;
|
|
2275
2275
|
}>;
|
|
@@ -2313,8 +2313,8 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
2313
2313
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
2314
2314
|
knowledgeFiles: Record<string, string>;
|
|
2315
2315
|
gitChanges: {
|
|
2316
|
-
status: string;
|
|
2317
2316
|
diff: string;
|
|
2317
|
+
status: string;
|
|
2318
2318
|
diffCached: string;
|
|
2319
2319
|
lastCommitMessages: string;
|
|
2320
2320
|
};
|
|
@@ -2339,8 +2339,8 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
2339
2339
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
2340
2340
|
knowledgeFiles: Record<string, string>;
|
|
2341
2341
|
gitChanges: {
|
|
2342
|
-
status: string;
|
|
2343
2342
|
diff: string;
|
|
2343
|
+
status: string;
|
|
2344
2344
|
diffCached: string;
|
|
2345
2345
|
lastCommitMessages: string;
|
|
2346
2346
|
};
|
|
@@ -2373,14 +2373,14 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
2373
2373
|
type: "ephemeral";
|
|
2374
2374
|
}>>;
|
|
2375
2375
|
}, "strip", z.ZodTypeAny, {
|
|
2376
|
-
text: string;
|
|
2377
2376
|
type: "text";
|
|
2377
|
+
text: string;
|
|
2378
2378
|
cache_control?: {
|
|
2379
2379
|
type: "ephemeral";
|
|
2380
2380
|
} | undefined;
|
|
2381
2381
|
}, {
|
|
2382
|
-
text: string;
|
|
2383
2382
|
type: "text";
|
|
2383
|
+
text: string;
|
|
2384
2384
|
cache_control?: {
|
|
2385
2385
|
type: "ephemeral";
|
|
2386
2386
|
} | undefined;
|
|
@@ -2444,13 +2444,13 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
2444
2444
|
media_type: z.ZodLiteral<"image/jpeg">;
|
|
2445
2445
|
data: z.ZodString;
|
|
2446
2446
|
}, "strip", z.ZodTypeAny, {
|
|
2447
|
-
data: string;
|
|
2448
2447
|
type: "base64";
|
|
2449
2448
|
media_type: "image/jpeg";
|
|
2450
|
-
}, {
|
|
2451
2449
|
data: string;
|
|
2450
|
+
}, {
|
|
2452
2451
|
type: "base64";
|
|
2453
2452
|
media_type: "image/jpeg";
|
|
2453
|
+
data: string;
|
|
2454
2454
|
}>;
|
|
2455
2455
|
cache_control: z.ZodOptional<z.ZodObject<{
|
|
2456
2456
|
type: z.ZodLiteral<"ephemeral">;
|
|
@@ -2462,9 +2462,9 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
2462
2462
|
}, "strip", z.ZodTypeAny, {
|
|
2463
2463
|
type: "image";
|
|
2464
2464
|
source: {
|
|
2465
|
-
data: string;
|
|
2466
2465
|
type: "base64";
|
|
2467
2466
|
media_type: "image/jpeg";
|
|
2467
|
+
data: string;
|
|
2468
2468
|
};
|
|
2469
2469
|
cache_control?: {
|
|
2470
2470
|
type: "ephemeral";
|
|
@@ -2472,9 +2472,9 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
2472
2472
|
}, {
|
|
2473
2473
|
type: "image";
|
|
2474
2474
|
source: {
|
|
2475
|
-
data: string;
|
|
2476
2475
|
type: "base64";
|
|
2477
2476
|
media_type: "image/jpeg";
|
|
2477
|
+
data: string;
|
|
2478
2478
|
};
|
|
2479
2479
|
cache_control?: {
|
|
2480
2480
|
type: "ephemeral";
|
|
@@ -2482,8 +2482,8 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
2482
2482
|
}>]>, "many">]>;
|
|
2483
2483
|
}, "strip", z.ZodTypeAny, {
|
|
2484
2484
|
content: string | ({
|
|
2485
|
-
text: string;
|
|
2486
2485
|
type: "text";
|
|
2486
|
+
text: string;
|
|
2487
2487
|
cache_control?: {
|
|
2488
2488
|
type: "ephemeral";
|
|
2489
2489
|
} | undefined;
|
|
@@ -2505,9 +2505,9 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
2505
2505
|
} | {
|
|
2506
2506
|
type: "image";
|
|
2507
2507
|
source: {
|
|
2508
|
-
data: string;
|
|
2509
2508
|
type: "base64";
|
|
2510
2509
|
media_type: "image/jpeg";
|
|
2510
|
+
data: string;
|
|
2511
2511
|
};
|
|
2512
2512
|
cache_control?: {
|
|
2513
2513
|
type: "ephemeral";
|
|
@@ -2516,8 +2516,8 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
2516
2516
|
role: "user" | "assistant";
|
|
2517
2517
|
}, {
|
|
2518
2518
|
content: string | ({
|
|
2519
|
-
text: string;
|
|
2520
2519
|
type: "text";
|
|
2520
|
+
text: string;
|
|
2521
2521
|
cache_control?: {
|
|
2522
2522
|
type: "ephemeral";
|
|
2523
2523
|
} | undefined;
|
|
@@ -2539,9 +2539,9 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
2539
2539
|
} | {
|
|
2540
2540
|
type: "image";
|
|
2541
2541
|
source: {
|
|
2542
|
-
data: string;
|
|
2543
2542
|
type: "base64";
|
|
2544
2543
|
media_type: "image/jpeg";
|
|
2544
|
+
data: string;
|
|
2545
2545
|
};
|
|
2546
2546
|
cache_control?: {
|
|
2547
2547
|
type: "ephemeral";
|
|
@@ -2550,15 +2550,14 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
2550
2550
|
role: "user" | "assistant";
|
|
2551
2551
|
}>, "many">;
|
|
2552
2552
|
}, "strip", z.ZodTypeAny, {
|
|
2553
|
-
agentContext: string;
|
|
2554
2553
|
fileContext: {
|
|
2555
2554
|
currentWorkingDirectory: string;
|
|
2556
2555
|
fileTree: import("../util/file").FileTreeNode[];
|
|
2557
2556
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
2558
2557
|
knowledgeFiles: Record<string, string>;
|
|
2559
2558
|
gitChanges: {
|
|
2560
|
-
status: string;
|
|
2561
2559
|
diff: string;
|
|
2560
|
+
status: string;
|
|
2562
2561
|
diffCached: string;
|
|
2563
2562
|
lastCommitMessages: string;
|
|
2564
2563
|
};
|
|
@@ -2578,10 +2577,11 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
2578
2577
|
}[][];
|
|
2579
2578
|
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
2580
2579
|
};
|
|
2580
|
+
agentContext: string;
|
|
2581
2581
|
messageHistory: {
|
|
2582
2582
|
content: string | ({
|
|
2583
|
-
text: string;
|
|
2584
2583
|
type: "text";
|
|
2584
|
+
text: string;
|
|
2585
2585
|
cache_control?: {
|
|
2586
2586
|
type: "ephemeral";
|
|
2587
2587
|
} | undefined;
|
|
@@ -2603,9 +2603,9 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
2603
2603
|
} | {
|
|
2604
2604
|
type: "image";
|
|
2605
2605
|
source: {
|
|
2606
|
-
data: string;
|
|
2607
2606
|
type: "base64";
|
|
2608
2607
|
media_type: "image/jpeg";
|
|
2608
|
+
data: string;
|
|
2609
2609
|
};
|
|
2610
2610
|
cache_control?: {
|
|
2611
2611
|
type: "ephemeral";
|
|
@@ -2614,15 +2614,14 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
2614
2614
|
role: "user" | "assistant";
|
|
2615
2615
|
}[];
|
|
2616
2616
|
}, {
|
|
2617
|
-
agentContext: string;
|
|
2618
2617
|
fileContext: {
|
|
2619
2618
|
currentWorkingDirectory: string;
|
|
2620
2619
|
fileTree: import("../util/file").FileTreeNode[];
|
|
2621
2620
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
2622
2621
|
knowledgeFiles: Record<string, string>;
|
|
2623
2622
|
gitChanges: {
|
|
2624
|
-
status: string;
|
|
2625
2623
|
diff: string;
|
|
2624
|
+
status: string;
|
|
2626
2625
|
diffCached: string;
|
|
2627
2626
|
lastCommitMessages: string;
|
|
2628
2627
|
};
|
|
@@ -2642,10 +2641,11 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
2642
2641
|
}[][];
|
|
2643
2642
|
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
2644
2643
|
};
|
|
2644
|
+
agentContext: string;
|
|
2645
2645
|
messageHistory: {
|
|
2646
2646
|
content: string | ({
|
|
2647
|
-
text: string;
|
|
2648
2647
|
type: "text";
|
|
2648
|
+
text: string;
|
|
2649
2649
|
cache_control?: {
|
|
2650
2650
|
type: "ephemeral";
|
|
2651
2651
|
} | undefined;
|
|
@@ -2667,9 +2667,9 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
2667
2667
|
} | {
|
|
2668
2668
|
type: "image";
|
|
2669
2669
|
source: {
|
|
2670
|
-
data: string;
|
|
2671
2670
|
type: "base64";
|
|
2672
2671
|
media_type: "image/jpeg";
|
|
2672
|
+
data: string;
|
|
2673
2673
|
};
|
|
2674
2674
|
cache_control?: {
|
|
2675
2675
|
type: "ephemeral";
|
|
@@ -2694,18 +2694,17 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
2694
2694
|
}, "strip", z.ZodTypeAny, {
|
|
2695
2695
|
type: "prompt";
|
|
2696
2696
|
fingerprintId: string;
|
|
2697
|
-
costMode: "
|
|
2697
|
+
costMode: "lite" | "normal" | "max";
|
|
2698
2698
|
promptId: string;
|
|
2699
2699
|
agentState: {
|
|
2700
|
-
agentContext: string;
|
|
2701
2700
|
fileContext: {
|
|
2702
2701
|
currentWorkingDirectory: string;
|
|
2703
2702
|
fileTree: import("../util/file").FileTreeNode[];
|
|
2704
2703
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
2705
2704
|
knowledgeFiles: Record<string, string>;
|
|
2706
2705
|
gitChanges: {
|
|
2707
|
-
status: string;
|
|
2708
2706
|
diff: string;
|
|
2707
|
+
status: string;
|
|
2709
2708
|
diffCached: string;
|
|
2710
2709
|
lastCommitMessages: string;
|
|
2711
2710
|
};
|
|
@@ -2725,10 +2724,11 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
2725
2724
|
}[][];
|
|
2726
2725
|
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
2727
2726
|
};
|
|
2727
|
+
agentContext: string;
|
|
2728
2728
|
messageHistory: {
|
|
2729
2729
|
content: string | ({
|
|
2730
|
-
text: string;
|
|
2731
2730
|
type: "text";
|
|
2731
|
+
text: string;
|
|
2732
2732
|
cache_control?: {
|
|
2733
2733
|
type: "ephemeral";
|
|
2734
2734
|
} | undefined;
|
|
@@ -2750,9 +2750,9 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
2750
2750
|
} | {
|
|
2751
2751
|
type: "image";
|
|
2752
2752
|
source: {
|
|
2753
|
-
data: string;
|
|
2754
2753
|
type: "base64";
|
|
2755
2754
|
media_type: "image/jpeg";
|
|
2755
|
+
data: string;
|
|
2756
2756
|
};
|
|
2757
2757
|
cache_control?: {
|
|
2758
2758
|
type: "ephemeral";
|
|
@@ -2773,15 +2773,14 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
2773
2773
|
fingerprintId: string;
|
|
2774
2774
|
promptId: string;
|
|
2775
2775
|
agentState: {
|
|
2776
|
-
agentContext: string;
|
|
2777
2776
|
fileContext: {
|
|
2778
2777
|
currentWorkingDirectory: string;
|
|
2779
2778
|
fileTree: import("../util/file").FileTreeNode[];
|
|
2780
2779
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
2781
2780
|
knowledgeFiles: Record<string, string>;
|
|
2782
2781
|
gitChanges: {
|
|
2783
|
-
status: string;
|
|
2784
2782
|
diff: string;
|
|
2783
|
+
status: string;
|
|
2785
2784
|
diffCached: string;
|
|
2786
2785
|
lastCommitMessages: string;
|
|
2787
2786
|
};
|
|
@@ -2801,10 +2800,11 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
2801
2800
|
}[][];
|
|
2802
2801
|
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
2803
2802
|
};
|
|
2803
|
+
agentContext: string;
|
|
2804
2804
|
messageHistory: {
|
|
2805
2805
|
content: string | ({
|
|
2806
|
-
text: string;
|
|
2807
2806
|
type: "text";
|
|
2807
|
+
text: string;
|
|
2808
2808
|
cache_control?: {
|
|
2809
2809
|
type: "ephemeral";
|
|
2810
2810
|
} | undefined;
|
|
@@ -2826,9 +2826,9 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
2826
2826
|
} | {
|
|
2827
2827
|
type: "image";
|
|
2828
2828
|
source: {
|
|
2829
|
-
data: string;
|
|
2830
2829
|
type: "base64";
|
|
2831
2830
|
media_type: "image/jpeg";
|
|
2831
|
+
data: string;
|
|
2832
2832
|
};
|
|
2833
2833
|
cache_control?: {
|
|
2834
2834
|
type: "ephemeral";
|
|
@@ -2843,7 +2843,7 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
2843
2843
|
result: string;
|
|
2844
2844
|
}[];
|
|
2845
2845
|
authToken?: string | undefined;
|
|
2846
|
-
costMode?: "
|
|
2846
|
+
costMode?: "lite" | "normal" | "max" | undefined;
|
|
2847
2847
|
prompt?: string | undefined;
|
|
2848
2848
|
}>, z.ZodObject<{
|
|
2849
2849
|
type: z.ZodLiteral<"read-files-response">;
|
|
@@ -2873,13 +2873,13 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
2873
2873
|
diffCached: z.ZodString;
|
|
2874
2874
|
lastCommitMessages: z.ZodString;
|
|
2875
2875
|
}, "strip", z.ZodTypeAny, {
|
|
2876
|
-
status: string;
|
|
2877
2876
|
diff: string;
|
|
2877
|
+
status: string;
|
|
2878
2878
|
diffCached: string;
|
|
2879
2879
|
lastCommitMessages: string;
|
|
2880
2880
|
}, {
|
|
2881
|
-
status: string;
|
|
2882
2881
|
diff: string;
|
|
2882
|
+
status: string;
|
|
2883
2883
|
diffCached: string;
|
|
2884
2884
|
lastCommitMessages: string;
|
|
2885
2885
|
}>;
|
|
@@ -2923,8 +2923,8 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
2923
2923
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
2924
2924
|
knowledgeFiles: Record<string, string>;
|
|
2925
2925
|
gitChanges: {
|
|
2926
|
-
status: string;
|
|
2927
2926
|
diff: string;
|
|
2927
|
+
status: string;
|
|
2928
2928
|
diffCached: string;
|
|
2929
2929
|
lastCommitMessages: string;
|
|
2930
2930
|
};
|
|
@@ -2949,8 +2949,8 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
2949
2949
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
2950
2950
|
knowledgeFiles: Record<string, string>;
|
|
2951
2951
|
gitChanges: {
|
|
2952
|
-
status: string;
|
|
2953
2952
|
diff: string;
|
|
2953
|
+
status: string;
|
|
2954
2954
|
diffCached: string;
|
|
2955
2955
|
lastCommitMessages: string;
|
|
2956
2956
|
};
|
|
@@ -2972,14 +2972,15 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
2972
2972
|
}>;
|
|
2973
2973
|
}, "strip", z.ZodTypeAny, {
|
|
2974
2974
|
type: "init";
|
|
2975
|
+
fingerprintId: string;
|
|
2975
2976
|
fileContext: {
|
|
2976
2977
|
currentWorkingDirectory: string;
|
|
2977
2978
|
fileTree: import("../util/file").FileTreeNode[];
|
|
2978
2979
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
2979
2980
|
knowledgeFiles: Record<string, string>;
|
|
2980
2981
|
gitChanges: {
|
|
2981
|
-
status: string;
|
|
2982
2982
|
diff: string;
|
|
2983
|
+
status: string;
|
|
2983
2984
|
diffCached: string;
|
|
2984
2985
|
lastCommitMessages: string;
|
|
2985
2986
|
};
|
|
@@ -2999,18 +3000,18 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
2999
3000
|
}[][];
|
|
3000
3001
|
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
3001
3002
|
};
|
|
3002
|
-
fingerprintId: string;
|
|
3003
3003
|
authToken?: string | undefined;
|
|
3004
3004
|
}, {
|
|
3005
3005
|
type: "init";
|
|
3006
|
+
fingerprintId: string;
|
|
3006
3007
|
fileContext: {
|
|
3007
3008
|
currentWorkingDirectory: string;
|
|
3008
3009
|
fileTree: import("../util/file").FileTreeNode[];
|
|
3009
3010
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
3010
3011
|
knowledgeFiles: Record<string, string>;
|
|
3011
3012
|
gitChanges: {
|
|
3012
|
-
status: string;
|
|
3013
3013
|
diff: string;
|
|
3014
|
+
status: string;
|
|
3014
3015
|
diffCached: string;
|
|
3015
3016
|
lastCommitMessages: string;
|
|
3016
3017
|
};
|
|
@@ -3030,7 +3031,6 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
3030
3031
|
}[][];
|
|
3031
3032
|
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
3032
3033
|
};
|
|
3033
|
-
fingerprintId: string;
|
|
3034
3034
|
authToken?: string | undefined;
|
|
3035
3035
|
}>, z.ZodObject<{
|
|
3036
3036
|
type: z.ZodLiteral<"usage">;
|
|
@@ -3061,41 +3061,15 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
3061
3061
|
authToken?: string | undefined;
|
|
3062
3062
|
}>]>;
|
|
3063
3063
|
}, "strip", z.ZodTypeAny, {
|
|
3064
|
+
type: "action";
|
|
3064
3065
|
data: {
|
|
3065
3066
|
type: "user-input";
|
|
3066
|
-
fileContext: {
|
|
3067
|
-
currentWorkingDirectory: string;
|
|
3068
|
-
fileTree: import("../util/file").FileTreeNode[];
|
|
3069
|
-
fileTokenScores: Record<string, Record<string, number>>;
|
|
3070
|
-
knowledgeFiles: Record<string, string>;
|
|
3071
|
-
gitChanges: {
|
|
3072
|
-
status: string;
|
|
3073
|
-
diff: string;
|
|
3074
|
-
diffCached: string;
|
|
3075
|
-
lastCommitMessages: string;
|
|
3076
|
-
};
|
|
3077
|
-
changesSinceLastChat: Record<string, string>;
|
|
3078
|
-
shellConfigFiles: Record<string, string>;
|
|
3079
|
-
systemInfo: {
|
|
3080
|
-
platform: string;
|
|
3081
|
-
shell: string;
|
|
3082
|
-
nodeVersion: string;
|
|
3083
|
-
arch: string;
|
|
3084
|
-
homedir: string;
|
|
3085
|
-
cpus: number;
|
|
3086
|
-
};
|
|
3087
|
-
fileVersions: {
|
|
3088
|
-
path: string;
|
|
3089
|
-
content: string;
|
|
3090
|
-
}[][];
|
|
3091
|
-
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
3092
|
-
};
|
|
3093
3067
|
fingerprintId: string;
|
|
3094
3068
|
userInputId: string;
|
|
3095
3069
|
messages: {
|
|
3096
3070
|
content: string | ({
|
|
3097
|
-
text: string;
|
|
3098
3071
|
type: "text";
|
|
3072
|
+
text: string;
|
|
3099
3073
|
cache_control?: {
|
|
3100
3074
|
type: "ephemeral";
|
|
3101
3075
|
} | undefined;
|
|
@@ -3117,9 +3091,9 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
3117
3091
|
} | {
|
|
3118
3092
|
type: "image";
|
|
3119
3093
|
source: {
|
|
3120
|
-
data: string;
|
|
3121
3094
|
type: "base64";
|
|
3122
3095
|
media_type: "image/jpeg";
|
|
3096
|
+
data: string;
|
|
3123
3097
|
};
|
|
3124
3098
|
cache_control?: {
|
|
3125
3099
|
type: "ephemeral";
|
|
@@ -3127,28 +3101,54 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
3127
3101
|
})[];
|
|
3128
3102
|
role: "user" | "assistant";
|
|
3129
3103
|
}[];
|
|
3104
|
+
fileContext: {
|
|
3105
|
+
currentWorkingDirectory: string;
|
|
3106
|
+
fileTree: import("../util/file").FileTreeNode[];
|
|
3107
|
+
fileTokenScores: Record<string, Record<string, number>>;
|
|
3108
|
+
knowledgeFiles: Record<string, string>;
|
|
3109
|
+
gitChanges: {
|
|
3110
|
+
diff: string;
|
|
3111
|
+
status: string;
|
|
3112
|
+
diffCached: string;
|
|
3113
|
+
lastCommitMessages: string;
|
|
3114
|
+
};
|
|
3115
|
+
changesSinceLastChat: Record<string, string>;
|
|
3116
|
+
shellConfigFiles: Record<string, string>;
|
|
3117
|
+
systemInfo: {
|
|
3118
|
+
platform: string;
|
|
3119
|
+
shell: string;
|
|
3120
|
+
nodeVersion: string;
|
|
3121
|
+
arch: string;
|
|
3122
|
+
homedir: string;
|
|
3123
|
+
cpus: number;
|
|
3124
|
+
};
|
|
3125
|
+
fileVersions: {
|
|
3126
|
+
path: string;
|
|
3127
|
+
content: string;
|
|
3128
|
+
}[][];
|
|
3129
|
+
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
3130
|
+
};
|
|
3130
3131
|
changesAlreadyApplied: {
|
|
3132
|
+
type: "patch" | "file";
|
|
3131
3133
|
path: string;
|
|
3132
|
-
type: "file" | "patch";
|
|
3133
3134
|
content: string;
|
|
3134
3135
|
}[];
|
|
3135
|
-
costMode: "
|
|
3136
|
+
costMode: "lite" | "normal" | "max";
|
|
3136
3137
|
authToken?: string | undefined;
|
|
3137
3138
|
} | {
|
|
3138
3139
|
type: "prompt";
|
|
3139
3140
|
fingerprintId: string;
|
|
3140
|
-
costMode: "
|
|
3141
|
+
costMode: "lite" | "normal" | "max";
|
|
3141
3142
|
promptId: string;
|
|
3142
3143
|
agentState: {
|
|
3143
|
-
agentContext: string;
|
|
3144
3144
|
fileContext: {
|
|
3145
3145
|
currentWorkingDirectory: string;
|
|
3146
3146
|
fileTree: import("../util/file").FileTreeNode[];
|
|
3147
3147
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
3148
3148
|
knowledgeFiles: Record<string, string>;
|
|
3149
3149
|
gitChanges: {
|
|
3150
|
-
status: string;
|
|
3151
3150
|
diff: string;
|
|
3151
|
+
status: string;
|
|
3152
3152
|
diffCached: string;
|
|
3153
3153
|
lastCommitMessages: string;
|
|
3154
3154
|
};
|
|
@@ -3168,10 +3168,11 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
3168
3168
|
}[][];
|
|
3169
3169
|
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
3170
3170
|
};
|
|
3171
|
+
agentContext: string;
|
|
3171
3172
|
messageHistory: {
|
|
3172
3173
|
content: string | ({
|
|
3173
|
-
text: string;
|
|
3174
3174
|
type: "text";
|
|
3175
|
+
text: string;
|
|
3175
3176
|
cache_control?: {
|
|
3176
3177
|
type: "ephemeral";
|
|
3177
3178
|
} | undefined;
|
|
@@ -3193,9 +3194,9 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
3193
3194
|
} | {
|
|
3194
3195
|
type: "image";
|
|
3195
3196
|
source: {
|
|
3196
|
-
data: string;
|
|
3197
3197
|
type: "base64";
|
|
3198
3198
|
media_type: "image/jpeg";
|
|
3199
|
+
data: string;
|
|
3199
3200
|
};
|
|
3200
3201
|
cache_control?: {
|
|
3201
3202
|
type: "ephemeral";
|
|
@@ -3217,14 +3218,15 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
3217
3218
|
requestId?: string | undefined;
|
|
3218
3219
|
} | {
|
|
3219
3220
|
type: "init";
|
|
3221
|
+
fingerprintId: string;
|
|
3220
3222
|
fileContext: {
|
|
3221
3223
|
currentWorkingDirectory: string;
|
|
3222
3224
|
fileTree: import("../util/file").FileTreeNode[];
|
|
3223
3225
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
3224
3226
|
knowledgeFiles: Record<string, string>;
|
|
3225
3227
|
gitChanges: {
|
|
3226
|
-
status: string;
|
|
3227
3228
|
diff: string;
|
|
3229
|
+
status: string;
|
|
3228
3230
|
diffCached: string;
|
|
3229
3231
|
lastCommitMessages: string;
|
|
3230
3232
|
};
|
|
@@ -3244,7 +3246,6 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
3244
3246
|
}[][];
|
|
3245
3247
|
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
3246
3248
|
};
|
|
3247
|
-
fingerprintId: string;
|
|
3248
3249
|
authToken?: string | undefined;
|
|
3249
3250
|
} | {
|
|
3250
3251
|
type: "usage";
|
|
@@ -3256,44 +3257,17 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
3256
3257
|
stagedChanges: string;
|
|
3257
3258
|
authToken?: string | undefined;
|
|
3258
3259
|
};
|
|
3259
|
-
type: "action";
|
|
3260
3260
|
txid: number;
|
|
3261
3261
|
}, {
|
|
3262
|
+
type: "action";
|
|
3262
3263
|
data: {
|
|
3263
3264
|
type: "user-input";
|
|
3264
|
-
fileContext: {
|
|
3265
|
-
currentWorkingDirectory: string;
|
|
3266
|
-
fileTree: import("../util/file").FileTreeNode[];
|
|
3267
|
-
fileTokenScores: Record<string, Record<string, number>>;
|
|
3268
|
-
knowledgeFiles: Record<string, string>;
|
|
3269
|
-
gitChanges: {
|
|
3270
|
-
status: string;
|
|
3271
|
-
diff: string;
|
|
3272
|
-
diffCached: string;
|
|
3273
|
-
lastCommitMessages: string;
|
|
3274
|
-
};
|
|
3275
|
-
changesSinceLastChat: Record<string, string>;
|
|
3276
|
-
shellConfigFiles: Record<string, string>;
|
|
3277
|
-
systemInfo: {
|
|
3278
|
-
platform: string;
|
|
3279
|
-
shell: string;
|
|
3280
|
-
nodeVersion: string;
|
|
3281
|
-
arch: string;
|
|
3282
|
-
homedir: string;
|
|
3283
|
-
cpus: number;
|
|
3284
|
-
};
|
|
3285
|
-
fileVersions: {
|
|
3286
|
-
path: string;
|
|
3287
|
-
content: string;
|
|
3288
|
-
}[][];
|
|
3289
|
-
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
3290
|
-
};
|
|
3291
3265
|
fingerprintId: string;
|
|
3292
3266
|
userInputId: string;
|
|
3293
3267
|
messages: {
|
|
3294
3268
|
content: string | ({
|
|
3295
|
-
text: string;
|
|
3296
3269
|
type: "text";
|
|
3270
|
+
text: string;
|
|
3297
3271
|
cache_control?: {
|
|
3298
3272
|
type: "ephemeral";
|
|
3299
3273
|
} | undefined;
|
|
@@ -3315,9 +3289,9 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
3315
3289
|
} | {
|
|
3316
3290
|
type: "image";
|
|
3317
3291
|
source: {
|
|
3318
|
-
data: string;
|
|
3319
3292
|
type: "base64";
|
|
3320
3293
|
media_type: "image/jpeg";
|
|
3294
|
+
data: string;
|
|
3321
3295
|
};
|
|
3322
3296
|
cache_control?: {
|
|
3323
3297
|
type: "ephemeral";
|
|
@@ -3325,27 +3299,53 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
3325
3299
|
})[];
|
|
3326
3300
|
role: "user" | "assistant";
|
|
3327
3301
|
}[];
|
|
3302
|
+
fileContext: {
|
|
3303
|
+
currentWorkingDirectory: string;
|
|
3304
|
+
fileTree: import("../util/file").FileTreeNode[];
|
|
3305
|
+
fileTokenScores: Record<string, Record<string, number>>;
|
|
3306
|
+
knowledgeFiles: Record<string, string>;
|
|
3307
|
+
gitChanges: {
|
|
3308
|
+
diff: string;
|
|
3309
|
+
status: string;
|
|
3310
|
+
diffCached: string;
|
|
3311
|
+
lastCommitMessages: string;
|
|
3312
|
+
};
|
|
3313
|
+
changesSinceLastChat: Record<string, string>;
|
|
3314
|
+
shellConfigFiles: Record<string, string>;
|
|
3315
|
+
systemInfo: {
|
|
3316
|
+
platform: string;
|
|
3317
|
+
shell: string;
|
|
3318
|
+
nodeVersion: string;
|
|
3319
|
+
arch: string;
|
|
3320
|
+
homedir: string;
|
|
3321
|
+
cpus: number;
|
|
3322
|
+
};
|
|
3323
|
+
fileVersions: {
|
|
3324
|
+
path: string;
|
|
3325
|
+
content: string;
|
|
3326
|
+
}[][];
|
|
3327
|
+
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
3328
|
+
};
|
|
3328
3329
|
changesAlreadyApplied: {
|
|
3330
|
+
type: "patch" | "file";
|
|
3329
3331
|
path: string;
|
|
3330
|
-
type: "file" | "patch";
|
|
3331
3332
|
content: string;
|
|
3332
3333
|
}[];
|
|
3333
3334
|
authToken?: string | undefined;
|
|
3334
|
-
costMode?: "
|
|
3335
|
+
costMode?: "lite" | "normal" | "max" | undefined;
|
|
3335
3336
|
} | {
|
|
3336
3337
|
type: "prompt";
|
|
3337
3338
|
fingerprintId: string;
|
|
3338
3339
|
promptId: string;
|
|
3339
3340
|
agentState: {
|
|
3340
|
-
agentContext: string;
|
|
3341
3341
|
fileContext: {
|
|
3342
3342
|
currentWorkingDirectory: string;
|
|
3343
3343
|
fileTree: import("../util/file").FileTreeNode[];
|
|
3344
3344
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
3345
3345
|
knowledgeFiles: Record<string, string>;
|
|
3346
3346
|
gitChanges: {
|
|
3347
|
-
status: string;
|
|
3348
3347
|
diff: string;
|
|
3348
|
+
status: string;
|
|
3349
3349
|
diffCached: string;
|
|
3350
3350
|
lastCommitMessages: string;
|
|
3351
3351
|
};
|
|
@@ -3365,10 +3365,11 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
3365
3365
|
}[][];
|
|
3366
3366
|
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
3367
3367
|
};
|
|
3368
|
+
agentContext: string;
|
|
3368
3369
|
messageHistory: {
|
|
3369
3370
|
content: string | ({
|
|
3370
|
-
text: string;
|
|
3371
3371
|
type: "text";
|
|
3372
|
+
text: string;
|
|
3372
3373
|
cache_control?: {
|
|
3373
3374
|
type: "ephemeral";
|
|
3374
3375
|
} | undefined;
|
|
@@ -3390,9 +3391,9 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
3390
3391
|
} | {
|
|
3391
3392
|
type: "image";
|
|
3392
3393
|
source: {
|
|
3393
|
-
data: string;
|
|
3394
3394
|
type: "base64";
|
|
3395
3395
|
media_type: "image/jpeg";
|
|
3396
|
+
data: string;
|
|
3396
3397
|
};
|
|
3397
3398
|
cache_control?: {
|
|
3398
3399
|
type: "ephemeral";
|
|
@@ -3407,7 +3408,7 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
3407
3408
|
result: string;
|
|
3408
3409
|
}[];
|
|
3409
3410
|
authToken?: string | undefined;
|
|
3410
|
-
costMode?: "
|
|
3411
|
+
costMode?: "lite" | "normal" | "max" | undefined;
|
|
3411
3412
|
prompt?: string | undefined;
|
|
3412
3413
|
} | {
|
|
3413
3414
|
type: "read-files-response";
|
|
@@ -3415,14 +3416,15 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
3415
3416
|
requestId?: string | undefined;
|
|
3416
3417
|
} | {
|
|
3417
3418
|
type: "init";
|
|
3419
|
+
fingerprintId: string;
|
|
3418
3420
|
fileContext: {
|
|
3419
3421
|
currentWorkingDirectory: string;
|
|
3420
3422
|
fileTree: import("../util/file").FileTreeNode[];
|
|
3421
3423
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
3422
3424
|
knowledgeFiles: Record<string, string>;
|
|
3423
3425
|
gitChanges: {
|
|
3424
|
-
status: string;
|
|
3425
3426
|
diff: string;
|
|
3427
|
+
status: string;
|
|
3426
3428
|
diffCached: string;
|
|
3427
3429
|
lastCommitMessages: string;
|
|
3428
3430
|
};
|
|
@@ -3442,7 +3444,6 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
3442
3444
|
}[][];
|
|
3443
3445
|
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
3444
3446
|
};
|
|
3445
|
-
fingerprintId: string;
|
|
3446
3447
|
authToken?: string | undefined;
|
|
3447
3448
|
} | {
|
|
3448
3449
|
type: "usage";
|
|
@@ -3454,7 +3455,6 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
3454
3455
|
stagedChanges: string;
|
|
3455
3456
|
authToken?: string | undefined;
|
|
3456
3457
|
};
|
|
3457
|
-
type: "action";
|
|
3458
3458
|
txid: number;
|
|
3459
3459
|
}>]>;
|
|
3460
3460
|
export type ClientMessageType = keyof typeof CLIENT_MESSAGE_SCHEMAS;
|
|
@@ -3468,13 +3468,13 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
|
|
|
3468
3468
|
}, "strip", z.ZodTypeAny, {
|
|
3469
3469
|
type: "ack";
|
|
3470
3470
|
success: boolean;
|
|
3471
|
-
error?: string | undefined;
|
|
3472
3471
|
txid?: number | undefined;
|
|
3472
|
+
error?: string | undefined;
|
|
3473
3473
|
}, {
|
|
3474
3474
|
type: "ack";
|
|
3475
3475
|
success: boolean;
|
|
3476
|
-
error?: string | undefined;
|
|
3477
3476
|
txid?: number | undefined;
|
|
3477
|
+
error?: string | undefined;
|
|
3478
3478
|
}>;
|
|
3479
3479
|
action: z.ZodObject<{
|
|
3480
3480
|
type: z.ZodLiteral<"action">;
|
|
@@ -3499,12 +3499,12 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
|
|
|
3499
3499
|
path: z.ZodString;
|
|
3500
3500
|
content: z.ZodString;
|
|
3501
3501
|
}, "strip", z.ZodTypeAny, {
|
|
3502
|
+
type: "patch" | "file";
|
|
3502
3503
|
path: string;
|
|
3503
|
-
type: "file" | "patch";
|
|
3504
3504
|
content: string;
|
|
3505
3505
|
}, {
|
|
3506
|
+
type: "patch" | "file";
|
|
3506
3507
|
path: string;
|
|
3507
|
-
type: "file" | "patch";
|
|
3508
3508
|
content: string;
|
|
3509
3509
|
}>, "many">;
|
|
3510
3510
|
changesAlreadyApplied: z.ZodArray<z.ZodObject<{
|
|
@@ -3512,12 +3512,12 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
|
|
|
3512
3512
|
path: z.ZodString;
|
|
3513
3513
|
content: z.ZodString;
|
|
3514
3514
|
}, "strip", z.ZodTypeAny, {
|
|
3515
|
+
type: "patch" | "file";
|
|
3515
3516
|
path: string;
|
|
3516
|
-
type: "file" | "patch";
|
|
3517
3517
|
content: string;
|
|
3518
3518
|
}, {
|
|
3519
|
+
type: "patch" | "file";
|
|
3519
3520
|
path: string;
|
|
3520
|
-
type: "file" | "patch";
|
|
3521
3521
|
content: string;
|
|
3522
3522
|
}>, "many">;
|
|
3523
3523
|
addedFileVersions: z.ZodArray<z.ZodObject<{
|
|
@@ -3542,14 +3542,14 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
|
|
|
3542
3542
|
type: "response-complete";
|
|
3543
3543
|
userInputId: string;
|
|
3544
3544
|
changesAlreadyApplied: {
|
|
3545
|
+
type: "patch" | "file";
|
|
3545
3546
|
path: string;
|
|
3546
|
-
type: "file" | "patch";
|
|
3547
3547
|
content: string;
|
|
3548
3548
|
}[];
|
|
3549
3549
|
response: string;
|
|
3550
3550
|
changes: {
|
|
3551
|
+
type: "patch" | "file";
|
|
3551
3552
|
path: string;
|
|
3552
|
-
type: "file" | "patch";
|
|
3553
3553
|
content: string;
|
|
3554
3554
|
}[];
|
|
3555
3555
|
addedFileVersions: {
|
|
@@ -3567,14 +3567,14 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
|
|
|
3567
3567
|
type: "response-complete";
|
|
3568
3568
|
userInputId: string;
|
|
3569
3569
|
changesAlreadyApplied: {
|
|
3570
|
+
type: "patch" | "file";
|
|
3570
3571
|
path: string;
|
|
3571
|
-
type: "file" | "patch";
|
|
3572
3572
|
content: string;
|
|
3573
3573
|
}[];
|
|
3574
3574
|
response: string;
|
|
3575
3575
|
changes: {
|
|
3576
|
+
type: "patch" | "file";
|
|
3576
3577
|
path: string;
|
|
3577
|
-
type: "file" | "patch";
|
|
3578
3578
|
content: string;
|
|
3579
3579
|
}[];
|
|
3580
3580
|
addedFileVersions: {
|
|
@@ -3605,13 +3605,13 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
|
|
|
3605
3605
|
diffCached: z.ZodString;
|
|
3606
3606
|
lastCommitMessages: z.ZodString;
|
|
3607
3607
|
}, "strip", z.ZodTypeAny, {
|
|
3608
|
-
status: string;
|
|
3609
3608
|
diff: string;
|
|
3609
|
+
status: string;
|
|
3610
3610
|
diffCached: string;
|
|
3611
3611
|
lastCommitMessages: string;
|
|
3612
3612
|
}, {
|
|
3613
|
-
status: string;
|
|
3614
3613
|
diff: string;
|
|
3614
|
+
status: string;
|
|
3615
3615
|
diffCached: string;
|
|
3616
3616
|
lastCommitMessages: string;
|
|
3617
3617
|
}>;
|
|
@@ -3655,8 +3655,8 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
|
|
|
3655
3655
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
3656
3656
|
knowledgeFiles: Record<string, string>;
|
|
3657
3657
|
gitChanges: {
|
|
3658
|
-
status: string;
|
|
3659
3658
|
diff: string;
|
|
3659
|
+
status: string;
|
|
3660
3660
|
diffCached: string;
|
|
3661
3661
|
lastCommitMessages: string;
|
|
3662
3662
|
};
|
|
@@ -3681,8 +3681,8 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
|
|
|
3681
3681
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
3682
3682
|
knowledgeFiles: Record<string, string>;
|
|
3683
3683
|
gitChanges: {
|
|
3684
|
-
status: string;
|
|
3685
3684
|
diff: string;
|
|
3685
|
+
status: string;
|
|
3686
3686
|
diffCached: string;
|
|
3687
3687
|
lastCommitMessages: string;
|
|
3688
3688
|
};
|
|
@@ -3715,14 +3715,14 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
|
|
|
3715
3715
|
type: "ephemeral";
|
|
3716
3716
|
}>>;
|
|
3717
3717
|
}, "strip", z.ZodTypeAny, {
|
|
3718
|
-
text: string;
|
|
3719
3718
|
type: "text";
|
|
3719
|
+
text: string;
|
|
3720
3720
|
cache_control?: {
|
|
3721
3721
|
type: "ephemeral";
|
|
3722
3722
|
} | undefined;
|
|
3723
3723
|
}, {
|
|
3724
|
-
text: string;
|
|
3725
3724
|
type: "text";
|
|
3725
|
+
text: string;
|
|
3726
3726
|
cache_control?: {
|
|
3727
3727
|
type: "ephemeral";
|
|
3728
3728
|
} | undefined;
|
|
@@ -3786,13 +3786,13 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
|
|
|
3786
3786
|
media_type: z.ZodLiteral<"image/jpeg">;
|
|
3787
3787
|
data: z.ZodString;
|
|
3788
3788
|
}, "strip", z.ZodTypeAny, {
|
|
3789
|
-
data: string;
|
|
3790
3789
|
type: "base64";
|
|
3791
3790
|
media_type: "image/jpeg";
|
|
3792
|
-
}, {
|
|
3793
3791
|
data: string;
|
|
3792
|
+
}, {
|
|
3794
3793
|
type: "base64";
|
|
3795
3794
|
media_type: "image/jpeg";
|
|
3795
|
+
data: string;
|
|
3796
3796
|
}>;
|
|
3797
3797
|
cache_control: z.ZodOptional<z.ZodObject<{
|
|
3798
3798
|
type: z.ZodLiteral<"ephemeral">;
|
|
@@ -3804,9 +3804,9 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
|
|
|
3804
3804
|
}, "strip", z.ZodTypeAny, {
|
|
3805
3805
|
type: "image";
|
|
3806
3806
|
source: {
|
|
3807
|
-
data: string;
|
|
3808
3807
|
type: "base64";
|
|
3809
3808
|
media_type: "image/jpeg";
|
|
3809
|
+
data: string;
|
|
3810
3810
|
};
|
|
3811
3811
|
cache_control?: {
|
|
3812
3812
|
type: "ephemeral";
|
|
@@ -3814,9 +3814,9 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
|
|
|
3814
3814
|
}, {
|
|
3815
3815
|
type: "image";
|
|
3816
3816
|
source: {
|
|
3817
|
-
data: string;
|
|
3818
3817
|
type: "base64";
|
|
3819
3818
|
media_type: "image/jpeg";
|
|
3819
|
+
data: string;
|
|
3820
3820
|
};
|
|
3821
3821
|
cache_control?: {
|
|
3822
3822
|
type: "ephemeral";
|
|
@@ -3824,8 +3824,8 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
|
|
|
3824
3824
|
}>]>, "many">]>;
|
|
3825
3825
|
}, "strip", z.ZodTypeAny, {
|
|
3826
3826
|
content: string | ({
|
|
3827
|
-
text: string;
|
|
3828
3827
|
type: "text";
|
|
3828
|
+
text: string;
|
|
3829
3829
|
cache_control?: {
|
|
3830
3830
|
type: "ephemeral";
|
|
3831
3831
|
} | undefined;
|
|
@@ -3847,9 +3847,9 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
|
|
|
3847
3847
|
} | {
|
|
3848
3848
|
type: "image";
|
|
3849
3849
|
source: {
|
|
3850
|
-
data: string;
|
|
3851
3850
|
type: "base64";
|
|
3852
3851
|
media_type: "image/jpeg";
|
|
3852
|
+
data: string;
|
|
3853
3853
|
};
|
|
3854
3854
|
cache_control?: {
|
|
3855
3855
|
type: "ephemeral";
|
|
@@ -3858,8 +3858,8 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
|
|
|
3858
3858
|
role: "user" | "assistant";
|
|
3859
3859
|
}, {
|
|
3860
3860
|
content: string | ({
|
|
3861
|
-
text: string;
|
|
3862
3861
|
type: "text";
|
|
3862
|
+
text: string;
|
|
3863
3863
|
cache_control?: {
|
|
3864
3864
|
type: "ephemeral";
|
|
3865
3865
|
} | undefined;
|
|
@@ -3881,9 +3881,9 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
|
|
|
3881
3881
|
} | {
|
|
3882
3882
|
type: "image";
|
|
3883
3883
|
source: {
|
|
3884
|
-
data: string;
|
|
3885
3884
|
type: "base64";
|
|
3886
3885
|
media_type: "image/jpeg";
|
|
3886
|
+
data: string;
|
|
3887
3887
|
};
|
|
3888
3888
|
cache_control?: {
|
|
3889
3889
|
type: "ephemeral";
|
|
@@ -3892,15 +3892,14 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
|
|
|
3892
3892
|
role: "user" | "assistant";
|
|
3893
3893
|
}>, "many">;
|
|
3894
3894
|
}, "strip", z.ZodTypeAny, {
|
|
3895
|
-
agentContext: string;
|
|
3896
3895
|
fileContext: {
|
|
3897
3896
|
currentWorkingDirectory: string;
|
|
3898
3897
|
fileTree: import("../util/file").FileTreeNode[];
|
|
3899
3898
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
3900
3899
|
knowledgeFiles: Record<string, string>;
|
|
3901
3900
|
gitChanges: {
|
|
3902
|
-
status: string;
|
|
3903
3901
|
diff: string;
|
|
3902
|
+
status: string;
|
|
3904
3903
|
diffCached: string;
|
|
3905
3904
|
lastCommitMessages: string;
|
|
3906
3905
|
};
|
|
@@ -3920,10 +3919,11 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
|
|
|
3920
3919
|
}[][];
|
|
3921
3920
|
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
3922
3921
|
};
|
|
3922
|
+
agentContext: string;
|
|
3923
3923
|
messageHistory: {
|
|
3924
3924
|
content: string | ({
|
|
3925
|
-
text: string;
|
|
3926
3925
|
type: "text";
|
|
3926
|
+
text: string;
|
|
3927
3927
|
cache_control?: {
|
|
3928
3928
|
type: "ephemeral";
|
|
3929
3929
|
} | undefined;
|
|
@@ -3945,9 +3945,9 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
|
|
|
3945
3945
|
} | {
|
|
3946
3946
|
type: "image";
|
|
3947
3947
|
source: {
|
|
3948
|
-
data: string;
|
|
3949
3948
|
type: "base64";
|
|
3950
3949
|
media_type: "image/jpeg";
|
|
3950
|
+
data: string;
|
|
3951
3951
|
};
|
|
3952
3952
|
cache_control?: {
|
|
3953
3953
|
type: "ephemeral";
|
|
@@ -3956,15 +3956,14 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
|
|
|
3956
3956
|
role: "user" | "assistant";
|
|
3957
3957
|
}[];
|
|
3958
3958
|
}, {
|
|
3959
|
-
agentContext: string;
|
|
3960
3959
|
fileContext: {
|
|
3961
3960
|
currentWorkingDirectory: string;
|
|
3962
3961
|
fileTree: import("../util/file").FileTreeNode[];
|
|
3963
3962
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
3964
3963
|
knowledgeFiles: Record<string, string>;
|
|
3965
3964
|
gitChanges: {
|
|
3966
|
-
status: string;
|
|
3967
3965
|
diff: string;
|
|
3966
|
+
status: string;
|
|
3968
3967
|
diffCached: string;
|
|
3969
3968
|
lastCommitMessages: string;
|
|
3970
3969
|
};
|
|
@@ -3984,10 +3983,11 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
|
|
|
3984
3983
|
}[][];
|
|
3985
3984
|
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
3986
3985
|
};
|
|
3986
|
+
agentContext: string;
|
|
3987
3987
|
messageHistory: {
|
|
3988
3988
|
content: string | ({
|
|
3989
|
-
text: string;
|
|
3990
3989
|
type: "text";
|
|
3990
|
+
text: string;
|
|
3991
3991
|
cache_control?: {
|
|
3992
3992
|
type: "ephemeral";
|
|
3993
3993
|
} | undefined;
|
|
@@ -4009,9 +4009,9 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
|
|
|
4009
4009
|
} | {
|
|
4010
4010
|
type: "image";
|
|
4011
4011
|
source: {
|
|
4012
|
-
data: string;
|
|
4013
4012
|
type: "base64";
|
|
4014
4013
|
media_type: "image/jpeg";
|
|
4014
|
+
data: string;
|
|
4015
4015
|
};
|
|
4016
4016
|
cache_control?: {
|
|
4017
4017
|
type: "ephemeral";
|
|
@@ -4057,15 +4057,14 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
|
|
|
4057
4057
|
type: "prompt-response";
|
|
4058
4058
|
promptId: string;
|
|
4059
4059
|
agentState: {
|
|
4060
|
-
agentContext: string;
|
|
4061
4060
|
fileContext: {
|
|
4062
4061
|
currentWorkingDirectory: string;
|
|
4063
4062
|
fileTree: import("../util/file").FileTreeNode[];
|
|
4064
4063
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
4065
4064
|
knowledgeFiles: Record<string, string>;
|
|
4066
4065
|
gitChanges: {
|
|
4067
|
-
status: string;
|
|
4068
4066
|
diff: string;
|
|
4067
|
+
status: string;
|
|
4069
4068
|
diffCached: string;
|
|
4070
4069
|
lastCommitMessages: string;
|
|
4071
4070
|
};
|
|
@@ -4085,10 +4084,11 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
|
|
|
4085
4084
|
}[][];
|
|
4086
4085
|
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
4087
4086
|
};
|
|
4087
|
+
agentContext: string;
|
|
4088
4088
|
messageHistory: {
|
|
4089
4089
|
content: string | ({
|
|
4090
|
-
text: string;
|
|
4091
4090
|
type: "text";
|
|
4091
|
+
text: string;
|
|
4092
4092
|
cache_control?: {
|
|
4093
4093
|
type: "ephemeral";
|
|
4094
4094
|
} | undefined;
|
|
@@ -4110,9 +4110,9 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
|
|
|
4110
4110
|
} | {
|
|
4111
4111
|
type: "image";
|
|
4112
4112
|
source: {
|
|
4113
|
-
data: string;
|
|
4114
4113
|
type: "base64";
|
|
4115
4114
|
media_type: "image/jpeg";
|
|
4115
|
+
data: string;
|
|
4116
4116
|
};
|
|
4117
4117
|
cache_control?: {
|
|
4118
4118
|
type: "ephemeral";
|
|
@@ -4141,15 +4141,14 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
|
|
|
4141
4141
|
type: "prompt-response";
|
|
4142
4142
|
promptId: string;
|
|
4143
4143
|
agentState: {
|
|
4144
|
-
agentContext: string;
|
|
4145
4144
|
fileContext: {
|
|
4146
4145
|
currentWorkingDirectory: string;
|
|
4147
4146
|
fileTree: import("../util/file").FileTreeNode[];
|
|
4148
4147
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
4149
4148
|
knowledgeFiles: Record<string, string>;
|
|
4150
4149
|
gitChanges: {
|
|
4151
|
-
status: string;
|
|
4152
4150
|
diff: string;
|
|
4151
|
+
status: string;
|
|
4153
4152
|
diffCached: string;
|
|
4154
4153
|
lastCommitMessages: string;
|
|
4155
4154
|
};
|
|
@@ -4169,10 +4168,11 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
|
|
|
4169
4168
|
}[][];
|
|
4170
4169
|
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
4171
4170
|
};
|
|
4171
|
+
agentContext: string;
|
|
4172
4172
|
messageHistory: {
|
|
4173
4173
|
content: string | ({
|
|
4174
|
-
text: string;
|
|
4175
4174
|
type: "text";
|
|
4175
|
+
text: string;
|
|
4176
4176
|
cache_control?: {
|
|
4177
4177
|
type: "ephemeral";
|
|
4178
4178
|
} | undefined;
|
|
@@ -4194,9 +4194,9 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
|
|
|
4194
4194
|
} | {
|
|
4195
4195
|
type: "image";
|
|
4196
4196
|
source: {
|
|
4197
|
-
data: string;
|
|
4198
4197
|
type: "base64";
|
|
4199
4198
|
media_type: "image/jpeg";
|
|
4199
|
+
data: string;
|
|
4200
4200
|
};
|
|
4201
4201
|
cache_control?: {
|
|
4202
4202
|
type: "ephemeral";
|
|
@@ -4255,12 +4255,12 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
|
|
|
4255
4255
|
path: z.ZodString;
|
|
4256
4256
|
content: z.ZodString;
|
|
4257
4257
|
}, "strip", z.ZodTypeAny, {
|
|
4258
|
+
type: "patch" | "file";
|
|
4258
4259
|
path: string;
|
|
4259
|
-
type: "file" | "patch";
|
|
4260
4260
|
content: string;
|
|
4261
4261
|
}, {
|
|
4262
|
+
type: "patch" | "file";
|
|
4262
4263
|
path: string;
|
|
4263
|
-
type: "file" | "patch";
|
|
4264
4264
|
content: string;
|
|
4265
4265
|
}>, "many">;
|
|
4266
4266
|
changesAlreadyApplied: z.ZodArray<z.ZodObject<{
|
|
@@ -4268,12 +4268,12 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
|
|
|
4268
4268
|
path: z.ZodString;
|
|
4269
4269
|
content: z.ZodString;
|
|
4270
4270
|
}, "strip", z.ZodTypeAny, {
|
|
4271
|
+
type: "patch" | "file";
|
|
4271
4272
|
path: string;
|
|
4272
|
-
type: "file" | "patch";
|
|
4273
4273
|
content: string;
|
|
4274
4274
|
}, {
|
|
4275
|
+
type: "patch" | "file";
|
|
4275
4276
|
path: string;
|
|
4276
|
-
type: "file" | "patch";
|
|
4277
4277
|
content: string;
|
|
4278
4278
|
}>, "many">;
|
|
4279
4279
|
addedFileVersions: z.ZodArray<z.ZodObject<{
|
|
@@ -4288,22 +4288,22 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
|
|
|
4288
4288
|
}>, "many">;
|
|
4289
4289
|
resetFileVersions: z.ZodBoolean;
|
|
4290
4290
|
}, "strip", z.ZodTypeAny, {
|
|
4291
|
+
type: "tool-call";
|
|
4292
|
+
userInputId: string;
|
|
4291
4293
|
data: {
|
|
4292
4294
|
name: string;
|
|
4293
4295
|
id: string;
|
|
4294
4296
|
input: Record<string, any>;
|
|
4295
4297
|
};
|
|
4296
|
-
type: "tool-call";
|
|
4297
|
-
userInputId: string;
|
|
4298
4298
|
changesAlreadyApplied: {
|
|
4299
|
+
type: "patch" | "file";
|
|
4299
4300
|
path: string;
|
|
4300
|
-
type: "file" | "patch";
|
|
4301
4301
|
content: string;
|
|
4302
4302
|
}[];
|
|
4303
4303
|
response: string;
|
|
4304
4304
|
changes: {
|
|
4305
|
+
type: "patch" | "file";
|
|
4305
4306
|
path: string;
|
|
4306
|
-
type: "file" | "patch";
|
|
4307
4307
|
content: string;
|
|
4308
4308
|
}[];
|
|
4309
4309
|
addedFileVersions: {
|
|
@@ -4312,22 +4312,22 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
|
|
|
4312
4312
|
}[];
|
|
4313
4313
|
resetFileVersions: boolean;
|
|
4314
4314
|
}, {
|
|
4315
|
+
type: "tool-call";
|
|
4316
|
+
userInputId: string;
|
|
4315
4317
|
data: {
|
|
4316
4318
|
name: string;
|
|
4317
4319
|
id: string;
|
|
4318
4320
|
input: Record<string, any>;
|
|
4319
4321
|
};
|
|
4320
|
-
type: "tool-call";
|
|
4321
|
-
userInputId: string;
|
|
4322
4322
|
changesAlreadyApplied: {
|
|
4323
|
+
type: "patch" | "file";
|
|
4323
4324
|
path: string;
|
|
4324
|
-
type: "file" | "patch";
|
|
4325
4325
|
content: string;
|
|
4326
4326
|
}[];
|
|
4327
4327
|
response: string;
|
|
4328
4328
|
changes: {
|
|
4329
|
+
type: "patch" | "file";
|
|
4329
4330
|
path: string;
|
|
4330
|
-
type: "file" | "patch";
|
|
4331
4331
|
content: string;
|
|
4332
4332
|
}[];
|
|
4333
4333
|
addedFileVersions: {
|
|
@@ -4341,12 +4341,12 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
|
|
|
4341
4341
|
result: z.ZodString;
|
|
4342
4342
|
}, "strip", z.ZodTypeAny, {
|
|
4343
4343
|
type: "terminal-command-result";
|
|
4344
|
-
result: string;
|
|
4345
4344
|
userInputId: string;
|
|
4345
|
+
result: string;
|
|
4346
4346
|
}, {
|
|
4347
4347
|
type: "terminal-command-result";
|
|
4348
|
-
result: string;
|
|
4349
4348
|
userInputId: string;
|
|
4349
|
+
result: string;
|
|
4350
4350
|
}>, z.ZodObject<{
|
|
4351
4351
|
type: z.ZodLiteral<"npm-version-status">;
|
|
4352
4352
|
isUpToDate: z.ZodBoolean;
|
|
@@ -4413,11 +4413,11 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
|
|
|
4413
4413
|
type: z.ZodLiteral<"action-error">;
|
|
4414
4414
|
message: z.ZodString;
|
|
4415
4415
|
}, "strip", z.ZodTypeAny, {
|
|
4416
|
-
message: string;
|
|
4417
4416
|
type: "action-error";
|
|
4418
|
-
}, {
|
|
4419
4417
|
message: string;
|
|
4418
|
+
}, {
|
|
4420
4419
|
type: "action-error";
|
|
4420
|
+
message: string;
|
|
4421
4421
|
}>, z.ZodObject<{
|
|
4422
4422
|
type: z.ZodLiteral<"commit-message-response">;
|
|
4423
4423
|
commitMessage: z.ZodString;
|
|
@@ -4429,6 +4429,7 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
|
|
|
4429
4429
|
commitMessage: string;
|
|
4430
4430
|
}>]>;
|
|
4431
4431
|
}, "strip", z.ZodTypeAny, {
|
|
4432
|
+
type: "action";
|
|
4432
4433
|
data: {
|
|
4433
4434
|
type: "usage-response";
|
|
4434
4435
|
usage: number;
|
|
@@ -4449,14 +4450,14 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
|
|
|
4449
4450
|
type: "response-complete";
|
|
4450
4451
|
userInputId: string;
|
|
4451
4452
|
changesAlreadyApplied: {
|
|
4453
|
+
type: "patch" | "file";
|
|
4452
4454
|
path: string;
|
|
4453
|
-
type: "file" | "patch";
|
|
4454
4455
|
content: string;
|
|
4455
4456
|
}[];
|
|
4456
4457
|
response: string;
|
|
4457
4458
|
changes: {
|
|
4459
|
+
type: "patch" | "file";
|
|
4458
4460
|
path: string;
|
|
4459
|
-
type: "file" | "patch";
|
|
4460
4461
|
content: string;
|
|
4461
4462
|
}[];
|
|
4462
4463
|
addedFileVersions: {
|
|
@@ -4474,15 +4475,14 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
|
|
|
4474
4475
|
type: "prompt-response";
|
|
4475
4476
|
promptId: string;
|
|
4476
4477
|
agentState: {
|
|
4477
|
-
agentContext: string;
|
|
4478
4478
|
fileContext: {
|
|
4479
4479
|
currentWorkingDirectory: string;
|
|
4480
4480
|
fileTree: import("../util/file").FileTreeNode[];
|
|
4481
4481
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
4482
4482
|
knowledgeFiles: Record<string, string>;
|
|
4483
4483
|
gitChanges: {
|
|
4484
|
-
status: string;
|
|
4485
4484
|
diff: string;
|
|
4485
|
+
status: string;
|
|
4486
4486
|
diffCached: string;
|
|
4487
4487
|
lastCommitMessages: string;
|
|
4488
4488
|
};
|
|
@@ -4502,10 +4502,11 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
|
|
|
4502
4502
|
}[][];
|
|
4503
4503
|
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
4504
4504
|
};
|
|
4505
|
+
agentContext: string;
|
|
4505
4506
|
messageHistory: {
|
|
4506
4507
|
content: string | ({
|
|
4507
|
-
text: string;
|
|
4508
4508
|
type: "text";
|
|
4509
|
+
text: string;
|
|
4509
4510
|
cache_control?: {
|
|
4510
4511
|
type: "ephemeral";
|
|
4511
4512
|
} | undefined;
|
|
@@ -4527,9 +4528,9 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
|
|
|
4527
4528
|
} | {
|
|
4528
4529
|
type: "image";
|
|
4529
4530
|
source: {
|
|
4530
|
-
data: string;
|
|
4531
4531
|
type: "base64";
|
|
4532
4532
|
media_type: "image/jpeg";
|
|
4533
|
+
data: string;
|
|
4533
4534
|
};
|
|
4534
4535
|
cache_control?: {
|
|
4535
4536
|
type: "ephemeral";
|
|
@@ -4563,22 +4564,22 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
|
|
|
4563
4564
|
requestId: string;
|
|
4564
4565
|
filePaths: string[];
|
|
4565
4566
|
} | {
|
|
4567
|
+
type: "tool-call";
|
|
4568
|
+
userInputId: string;
|
|
4566
4569
|
data: {
|
|
4567
4570
|
name: string;
|
|
4568
4571
|
id: string;
|
|
4569
4572
|
input: Record<string, any>;
|
|
4570
4573
|
};
|
|
4571
|
-
type: "tool-call";
|
|
4572
|
-
userInputId: string;
|
|
4573
4574
|
changesAlreadyApplied: {
|
|
4575
|
+
type: "patch" | "file";
|
|
4574
4576
|
path: string;
|
|
4575
|
-
type: "file" | "patch";
|
|
4576
4577
|
content: string;
|
|
4577
4578
|
}[];
|
|
4578
4579
|
response: string;
|
|
4579
4580
|
changes: {
|
|
4581
|
+
type: "patch" | "file";
|
|
4580
4582
|
path: string;
|
|
4581
|
-
type: "file" | "patch";
|
|
4582
4583
|
content: string;
|
|
4583
4584
|
}[];
|
|
4584
4585
|
addedFileVersions: {
|
|
@@ -4588,21 +4589,21 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
|
|
|
4588
4589
|
resetFileVersions: boolean;
|
|
4589
4590
|
} | {
|
|
4590
4591
|
type: "terminal-command-result";
|
|
4591
|
-
result: string;
|
|
4592
4592
|
userInputId: string;
|
|
4593
|
+
result: string;
|
|
4593
4594
|
} | {
|
|
4594
4595
|
type: "npm-version-status";
|
|
4595
4596
|
isUpToDate: boolean;
|
|
4596
4597
|
latestVersion: string;
|
|
4597
4598
|
} | {
|
|
4598
|
-
message: string;
|
|
4599
4599
|
type: "action-error";
|
|
4600
|
+
message: string;
|
|
4600
4601
|
} | {
|
|
4601
4602
|
type: "commit-message-response";
|
|
4602
4603
|
commitMessage: string;
|
|
4603
4604
|
};
|
|
4604
|
-
type: "action";
|
|
4605
4605
|
}, {
|
|
4606
|
+
type: "action";
|
|
4606
4607
|
data: {
|
|
4607
4608
|
type: "usage-response";
|
|
4608
4609
|
usage: number;
|
|
@@ -4623,14 +4624,14 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
|
|
|
4623
4624
|
type: "response-complete";
|
|
4624
4625
|
userInputId: string;
|
|
4625
4626
|
changesAlreadyApplied: {
|
|
4627
|
+
type: "patch" | "file";
|
|
4626
4628
|
path: string;
|
|
4627
|
-
type: "file" | "patch";
|
|
4628
4629
|
content: string;
|
|
4629
4630
|
}[];
|
|
4630
4631
|
response: string;
|
|
4631
4632
|
changes: {
|
|
4633
|
+
type: "patch" | "file";
|
|
4632
4634
|
path: string;
|
|
4633
|
-
type: "file" | "patch";
|
|
4634
4635
|
content: string;
|
|
4635
4636
|
}[];
|
|
4636
4637
|
addedFileVersions: {
|
|
@@ -4648,15 +4649,14 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
|
|
|
4648
4649
|
type: "prompt-response";
|
|
4649
4650
|
promptId: string;
|
|
4650
4651
|
agentState: {
|
|
4651
|
-
agentContext: string;
|
|
4652
4652
|
fileContext: {
|
|
4653
4653
|
currentWorkingDirectory: string;
|
|
4654
4654
|
fileTree: import("../util/file").FileTreeNode[];
|
|
4655
4655
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
4656
4656
|
knowledgeFiles: Record<string, string>;
|
|
4657
4657
|
gitChanges: {
|
|
4658
|
-
status: string;
|
|
4659
4658
|
diff: string;
|
|
4659
|
+
status: string;
|
|
4660
4660
|
diffCached: string;
|
|
4661
4661
|
lastCommitMessages: string;
|
|
4662
4662
|
};
|
|
@@ -4676,10 +4676,11 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
|
|
|
4676
4676
|
}[][];
|
|
4677
4677
|
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
4678
4678
|
};
|
|
4679
|
+
agentContext: string;
|
|
4679
4680
|
messageHistory: {
|
|
4680
4681
|
content: string | ({
|
|
4681
|
-
text: string;
|
|
4682
4682
|
type: "text";
|
|
4683
|
+
text: string;
|
|
4683
4684
|
cache_control?: {
|
|
4684
4685
|
type: "ephemeral";
|
|
4685
4686
|
} | undefined;
|
|
@@ -4701,9 +4702,9 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
|
|
|
4701
4702
|
} | {
|
|
4702
4703
|
type: "image";
|
|
4703
4704
|
source: {
|
|
4704
|
-
data: string;
|
|
4705
4705
|
type: "base64";
|
|
4706
4706
|
media_type: "image/jpeg";
|
|
4707
|
+
data: string;
|
|
4707
4708
|
};
|
|
4708
4709
|
cache_control?: {
|
|
4709
4710
|
type: "ephemeral";
|
|
@@ -4737,22 +4738,22 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
|
|
|
4737
4738
|
requestId: string;
|
|
4738
4739
|
filePaths: string[];
|
|
4739
4740
|
} | {
|
|
4741
|
+
type: "tool-call";
|
|
4742
|
+
userInputId: string;
|
|
4740
4743
|
data: {
|
|
4741
4744
|
name: string;
|
|
4742
4745
|
id: string;
|
|
4743
4746
|
input: Record<string, any>;
|
|
4744
4747
|
};
|
|
4745
|
-
type: "tool-call";
|
|
4746
|
-
userInputId: string;
|
|
4747
4748
|
changesAlreadyApplied: {
|
|
4749
|
+
type: "patch" | "file";
|
|
4748
4750
|
path: string;
|
|
4749
|
-
type: "file" | "patch";
|
|
4750
4751
|
content: string;
|
|
4751
4752
|
}[];
|
|
4752
4753
|
response: string;
|
|
4753
4754
|
changes: {
|
|
4755
|
+
type: "patch" | "file";
|
|
4754
4756
|
path: string;
|
|
4755
|
-
type: "file" | "patch";
|
|
4756
4757
|
content: string;
|
|
4757
4758
|
}[];
|
|
4758
4759
|
addedFileVersions: {
|
|
@@ -4762,20 +4763,19 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
|
|
|
4762
4763
|
resetFileVersions: boolean;
|
|
4763
4764
|
} | {
|
|
4764
4765
|
type: "terminal-command-result";
|
|
4765
|
-
result: string;
|
|
4766
4766
|
userInputId: string;
|
|
4767
|
+
result: string;
|
|
4767
4768
|
} | {
|
|
4768
4769
|
type: "npm-version-status";
|
|
4769
4770
|
isUpToDate: boolean;
|
|
4770
4771
|
latestVersion: string;
|
|
4771
4772
|
} | {
|
|
4772
|
-
message: string;
|
|
4773
4773
|
type: "action-error";
|
|
4774
|
+
message: string;
|
|
4774
4775
|
} | {
|
|
4775
4776
|
type: "commit-message-response";
|
|
4776
4777
|
commitMessage: string;
|
|
4777
4778
|
};
|
|
4778
|
-
type: "action";
|
|
4779
4779
|
}>;
|
|
4780
4780
|
};
|
|
4781
4781
|
export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
@@ -4786,13 +4786,13 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
4786
4786
|
}, "strip", z.ZodTypeAny, {
|
|
4787
4787
|
type: "ack";
|
|
4788
4788
|
success: boolean;
|
|
4789
|
-
error?: string | undefined;
|
|
4790
4789
|
txid?: number | undefined;
|
|
4790
|
+
error?: string | undefined;
|
|
4791
4791
|
}, {
|
|
4792
4792
|
type: "ack";
|
|
4793
4793
|
success: boolean;
|
|
4794
|
-
error?: string | undefined;
|
|
4795
4794
|
txid?: number | undefined;
|
|
4795
|
+
error?: string | undefined;
|
|
4796
4796
|
}>, z.ZodObject<{
|
|
4797
4797
|
type: z.ZodLiteral<"action">;
|
|
4798
4798
|
data: z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
|
|
@@ -4816,12 +4816,12 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
4816
4816
|
path: z.ZodString;
|
|
4817
4817
|
content: z.ZodString;
|
|
4818
4818
|
}, "strip", z.ZodTypeAny, {
|
|
4819
|
+
type: "patch" | "file";
|
|
4819
4820
|
path: string;
|
|
4820
|
-
type: "file" | "patch";
|
|
4821
4821
|
content: string;
|
|
4822
4822
|
}, {
|
|
4823
|
+
type: "patch" | "file";
|
|
4823
4824
|
path: string;
|
|
4824
|
-
type: "file" | "patch";
|
|
4825
4825
|
content: string;
|
|
4826
4826
|
}>, "many">;
|
|
4827
4827
|
changesAlreadyApplied: z.ZodArray<z.ZodObject<{
|
|
@@ -4829,12 +4829,12 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
4829
4829
|
path: z.ZodString;
|
|
4830
4830
|
content: z.ZodString;
|
|
4831
4831
|
}, "strip", z.ZodTypeAny, {
|
|
4832
|
+
type: "patch" | "file";
|
|
4832
4833
|
path: string;
|
|
4833
|
-
type: "file" | "patch";
|
|
4834
4834
|
content: string;
|
|
4835
4835
|
}, {
|
|
4836
|
+
type: "patch" | "file";
|
|
4836
4837
|
path: string;
|
|
4837
|
-
type: "file" | "patch";
|
|
4838
4838
|
content: string;
|
|
4839
4839
|
}>, "many">;
|
|
4840
4840
|
addedFileVersions: z.ZodArray<z.ZodObject<{
|
|
@@ -4859,14 +4859,14 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
4859
4859
|
type: "response-complete";
|
|
4860
4860
|
userInputId: string;
|
|
4861
4861
|
changesAlreadyApplied: {
|
|
4862
|
+
type: "patch" | "file";
|
|
4862
4863
|
path: string;
|
|
4863
|
-
type: "file" | "patch";
|
|
4864
4864
|
content: string;
|
|
4865
4865
|
}[];
|
|
4866
4866
|
response: string;
|
|
4867
4867
|
changes: {
|
|
4868
|
+
type: "patch" | "file";
|
|
4868
4869
|
path: string;
|
|
4869
|
-
type: "file" | "patch";
|
|
4870
4870
|
content: string;
|
|
4871
4871
|
}[];
|
|
4872
4872
|
addedFileVersions: {
|
|
@@ -4884,14 +4884,14 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
4884
4884
|
type: "response-complete";
|
|
4885
4885
|
userInputId: string;
|
|
4886
4886
|
changesAlreadyApplied: {
|
|
4887
|
+
type: "patch" | "file";
|
|
4887
4888
|
path: string;
|
|
4888
|
-
type: "file" | "patch";
|
|
4889
4889
|
content: string;
|
|
4890
4890
|
}[];
|
|
4891
4891
|
response: string;
|
|
4892
4892
|
changes: {
|
|
4893
|
+
type: "patch" | "file";
|
|
4893
4894
|
path: string;
|
|
4894
|
-
type: "file" | "patch";
|
|
4895
4895
|
content: string;
|
|
4896
4896
|
}[];
|
|
4897
4897
|
addedFileVersions: {
|
|
@@ -4922,13 +4922,13 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
4922
4922
|
diffCached: z.ZodString;
|
|
4923
4923
|
lastCommitMessages: z.ZodString;
|
|
4924
4924
|
}, "strip", z.ZodTypeAny, {
|
|
4925
|
-
status: string;
|
|
4926
4925
|
diff: string;
|
|
4926
|
+
status: string;
|
|
4927
4927
|
diffCached: string;
|
|
4928
4928
|
lastCommitMessages: string;
|
|
4929
4929
|
}, {
|
|
4930
|
-
status: string;
|
|
4931
4930
|
diff: string;
|
|
4931
|
+
status: string;
|
|
4932
4932
|
diffCached: string;
|
|
4933
4933
|
lastCommitMessages: string;
|
|
4934
4934
|
}>;
|
|
@@ -4972,8 +4972,8 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
4972
4972
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
4973
4973
|
knowledgeFiles: Record<string, string>;
|
|
4974
4974
|
gitChanges: {
|
|
4975
|
-
status: string;
|
|
4976
4975
|
diff: string;
|
|
4976
|
+
status: string;
|
|
4977
4977
|
diffCached: string;
|
|
4978
4978
|
lastCommitMessages: string;
|
|
4979
4979
|
};
|
|
@@ -4998,8 +4998,8 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
4998
4998
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
4999
4999
|
knowledgeFiles: Record<string, string>;
|
|
5000
5000
|
gitChanges: {
|
|
5001
|
-
status: string;
|
|
5002
5001
|
diff: string;
|
|
5002
|
+
status: string;
|
|
5003
5003
|
diffCached: string;
|
|
5004
5004
|
lastCommitMessages: string;
|
|
5005
5005
|
};
|
|
@@ -5032,14 +5032,14 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
5032
5032
|
type: "ephemeral";
|
|
5033
5033
|
}>>;
|
|
5034
5034
|
}, "strip", z.ZodTypeAny, {
|
|
5035
|
-
text: string;
|
|
5036
5035
|
type: "text";
|
|
5036
|
+
text: string;
|
|
5037
5037
|
cache_control?: {
|
|
5038
5038
|
type: "ephemeral";
|
|
5039
5039
|
} | undefined;
|
|
5040
5040
|
}, {
|
|
5041
|
-
text: string;
|
|
5042
5041
|
type: "text";
|
|
5042
|
+
text: string;
|
|
5043
5043
|
cache_control?: {
|
|
5044
5044
|
type: "ephemeral";
|
|
5045
5045
|
} | undefined;
|
|
@@ -5103,13 +5103,13 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
5103
5103
|
media_type: z.ZodLiteral<"image/jpeg">;
|
|
5104
5104
|
data: z.ZodString;
|
|
5105
5105
|
}, "strip", z.ZodTypeAny, {
|
|
5106
|
-
data: string;
|
|
5107
5106
|
type: "base64";
|
|
5108
5107
|
media_type: "image/jpeg";
|
|
5109
|
-
}, {
|
|
5110
5108
|
data: string;
|
|
5109
|
+
}, {
|
|
5111
5110
|
type: "base64";
|
|
5112
5111
|
media_type: "image/jpeg";
|
|
5112
|
+
data: string;
|
|
5113
5113
|
}>;
|
|
5114
5114
|
cache_control: z.ZodOptional<z.ZodObject<{
|
|
5115
5115
|
type: z.ZodLiteral<"ephemeral">;
|
|
@@ -5121,9 +5121,9 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
5121
5121
|
}, "strip", z.ZodTypeAny, {
|
|
5122
5122
|
type: "image";
|
|
5123
5123
|
source: {
|
|
5124
|
-
data: string;
|
|
5125
5124
|
type: "base64";
|
|
5126
5125
|
media_type: "image/jpeg";
|
|
5126
|
+
data: string;
|
|
5127
5127
|
};
|
|
5128
5128
|
cache_control?: {
|
|
5129
5129
|
type: "ephemeral";
|
|
@@ -5131,9 +5131,9 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
5131
5131
|
}, {
|
|
5132
5132
|
type: "image";
|
|
5133
5133
|
source: {
|
|
5134
|
-
data: string;
|
|
5135
5134
|
type: "base64";
|
|
5136
5135
|
media_type: "image/jpeg";
|
|
5136
|
+
data: string;
|
|
5137
5137
|
};
|
|
5138
5138
|
cache_control?: {
|
|
5139
5139
|
type: "ephemeral";
|
|
@@ -5141,8 +5141,8 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
5141
5141
|
}>]>, "many">]>;
|
|
5142
5142
|
}, "strip", z.ZodTypeAny, {
|
|
5143
5143
|
content: string | ({
|
|
5144
|
-
text: string;
|
|
5145
5144
|
type: "text";
|
|
5145
|
+
text: string;
|
|
5146
5146
|
cache_control?: {
|
|
5147
5147
|
type: "ephemeral";
|
|
5148
5148
|
} | undefined;
|
|
@@ -5164,9 +5164,9 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
5164
5164
|
} | {
|
|
5165
5165
|
type: "image";
|
|
5166
5166
|
source: {
|
|
5167
|
-
data: string;
|
|
5168
5167
|
type: "base64";
|
|
5169
5168
|
media_type: "image/jpeg";
|
|
5169
|
+
data: string;
|
|
5170
5170
|
};
|
|
5171
5171
|
cache_control?: {
|
|
5172
5172
|
type: "ephemeral";
|
|
@@ -5175,8 +5175,8 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
5175
5175
|
role: "user" | "assistant";
|
|
5176
5176
|
}, {
|
|
5177
5177
|
content: string | ({
|
|
5178
|
-
text: string;
|
|
5179
5178
|
type: "text";
|
|
5179
|
+
text: string;
|
|
5180
5180
|
cache_control?: {
|
|
5181
5181
|
type: "ephemeral";
|
|
5182
5182
|
} | undefined;
|
|
@@ -5198,9 +5198,9 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
5198
5198
|
} | {
|
|
5199
5199
|
type: "image";
|
|
5200
5200
|
source: {
|
|
5201
|
-
data: string;
|
|
5202
5201
|
type: "base64";
|
|
5203
5202
|
media_type: "image/jpeg";
|
|
5203
|
+
data: string;
|
|
5204
5204
|
};
|
|
5205
5205
|
cache_control?: {
|
|
5206
5206
|
type: "ephemeral";
|
|
@@ -5209,15 +5209,14 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
5209
5209
|
role: "user" | "assistant";
|
|
5210
5210
|
}>, "many">;
|
|
5211
5211
|
}, "strip", z.ZodTypeAny, {
|
|
5212
|
-
agentContext: string;
|
|
5213
5212
|
fileContext: {
|
|
5214
5213
|
currentWorkingDirectory: string;
|
|
5215
5214
|
fileTree: import("../util/file").FileTreeNode[];
|
|
5216
5215
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
5217
5216
|
knowledgeFiles: Record<string, string>;
|
|
5218
5217
|
gitChanges: {
|
|
5219
|
-
status: string;
|
|
5220
5218
|
diff: string;
|
|
5219
|
+
status: string;
|
|
5221
5220
|
diffCached: string;
|
|
5222
5221
|
lastCommitMessages: string;
|
|
5223
5222
|
};
|
|
@@ -5237,10 +5236,11 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
5237
5236
|
}[][];
|
|
5238
5237
|
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
5239
5238
|
};
|
|
5239
|
+
agentContext: string;
|
|
5240
5240
|
messageHistory: {
|
|
5241
5241
|
content: string | ({
|
|
5242
|
-
text: string;
|
|
5243
5242
|
type: "text";
|
|
5243
|
+
text: string;
|
|
5244
5244
|
cache_control?: {
|
|
5245
5245
|
type: "ephemeral";
|
|
5246
5246
|
} | undefined;
|
|
@@ -5262,9 +5262,9 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
5262
5262
|
} | {
|
|
5263
5263
|
type: "image";
|
|
5264
5264
|
source: {
|
|
5265
|
-
data: string;
|
|
5266
5265
|
type: "base64";
|
|
5267
5266
|
media_type: "image/jpeg";
|
|
5267
|
+
data: string;
|
|
5268
5268
|
};
|
|
5269
5269
|
cache_control?: {
|
|
5270
5270
|
type: "ephemeral";
|
|
@@ -5273,15 +5273,14 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
5273
5273
|
role: "user" | "assistant";
|
|
5274
5274
|
}[];
|
|
5275
5275
|
}, {
|
|
5276
|
-
agentContext: string;
|
|
5277
5276
|
fileContext: {
|
|
5278
5277
|
currentWorkingDirectory: string;
|
|
5279
5278
|
fileTree: import("../util/file").FileTreeNode[];
|
|
5280
5279
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
5281
5280
|
knowledgeFiles: Record<string, string>;
|
|
5282
5281
|
gitChanges: {
|
|
5283
|
-
status: string;
|
|
5284
5282
|
diff: string;
|
|
5283
|
+
status: string;
|
|
5285
5284
|
diffCached: string;
|
|
5286
5285
|
lastCommitMessages: string;
|
|
5287
5286
|
};
|
|
@@ -5301,10 +5300,11 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
5301
5300
|
}[][];
|
|
5302
5301
|
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
5303
5302
|
};
|
|
5303
|
+
agentContext: string;
|
|
5304
5304
|
messageHistory: {
|
|
5305
5305
|
content: string | ({
|
|
5306
|
-
text: string;
|
|
5307
5306
|
type: "text";
|
|
5307
|
+
text: string;
|
|
5308
5308
|
cache_control?: {
|
|
5309
5309
|
type: "ephemeral";
|
|
5310
5310
|
} | undefined;
|
|
@@ -5326,9 +5326,9 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
5326
5326
|
} | {
|
|
5327
5327
|
type: "image";
|
|
5328
5328
|
source: {
|
|
5329
|
-
data: string;
|
|
5330
5329
|
type: "base64";
|
|
5331
5330
|
media_type: "image/jpeg";
|
|
5331
|
+
data: string;
|
|
5332
5332
|
};
|
|
5333
5333
|
cache_control?: {
|
|
5334
5334
|
type: "ephemeral";
|
|
@@ -5374,15 +5374,14 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
5374
5374
|
type: "prompt-response";
|
|
5375
5375
|
promptId: string;
|
|
5376
5376
|
agentState: {
|
|
5377
|
-
agentContext: string;
|
|
5378
5377
|
fileContext: {
|
|
5379
5378
|
currentWorkingDirectory: string;
|
|
5380
5379
|
fileTree: import("../util/file").FileTreeNode[];
|
|
5381
5380
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
5382
5381
|
knowledgeFiles: Record<string, string>;
|
|
5383
5382
|
gitChanges: {
|
|
5384
|
-
status: string;
|
|
5385
5383
|
diff: string;
|
|
5384
|
+
status: string;
|
|
5386
5385
|
diffCached: string;
|
|
5387
5386
|
lastCommitMessages: string;
|
|
5388
5387
|
};
|
|
@@ -5402,10 +5401,11 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
5402
5401
|
}[][];
|
|
5403
5402
|
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
5404
5403
|
};
|
|
5404
|
+
agentContext: string;
|
|
5405
5405
|
messageHistory: {
|
|
5406
5406
|
content: string | ({
|
|
5407
|
-
text: string;
|
|
5408
5407
|
type: "text";
|
|
5408
|
+
text: string;
|
|
5409
5409
|
cache_control?: {
|
|
5410
5410
|
type: "ephemeral";
|
|
5411
5411
|
} | undefined;
|
|
@@ -5427,9 +5427,9 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
5427
5427
|
} | {
|
|
5428
5428
|
type: "image";
|
|
5429
5429
|
source: {
|
|
5430
|
-
data: string;
|
|
5431
5430
|
type: "base64";
|
|
5432
5431
|
media_type: "image/jpeg";
|
|
5432
|
+
data: string;
|
|
5433
5433
|
};
|
|
5434
5434
|
cache_control?: {
|
|
5435
5435
|
type: "ephemeral";
|
|
@@ -5458,15 +5458,14 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
5458
5458
|
type: "prompt-response";
|
|
5459
5459
|
promptId: string;
|
|
5460
5460
|
agentState: {
|
|
5461
|
-
agentContext: string;
|
|
5462
5461
|
fileContext: {
|
|
5463
5462
|
currentWorkingDirectory: string;
|
|
5464
5463
|
fileTree: import("../util/file").FileTreeNode[];
|
|
5465
5464
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
5466
5465
|
knowledgeFiles: Record<string, string>;
|
|
5467
5466
|
gitChanges: {
|
|
5468
|
-
status: string;
|
|
5469
5467
|
diff: string;
|
|
5468
|
+
status: string;
|
|
5470
5469
|
diffCached: string;
|
|
5471
5470
|
lastCommitMessages: string;
|
|
5472
5471
|
};
|
|
@@ -5486,10 +5485,11 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
5486
5485
|
}[][];
|
|
5487
5486
|
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
5488
5487
|
};
|
|
5488
|
+
agentContext: string;
|
|
5489
5489
|
messageHistory: {
|
|
5490
5490
|
content: string | ({
|
|
5491
|
-
text: string;
|
|
5492
5491
|
type: "text";
|
|
5492
|
+
text: string;
|
|
5493
5493
|
cache_control?: {
|
|
5494
5494
|
type: "ephemeral";
|
|
5495
5495
|
} | undefined;
|
|
@@ -5511,9 +5511,9 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
5511
5511
|
} | {
|
|
5512
5512
|
type: "image";
|
|
5513
5513
|
source: {
|
|
5514
|
-
data: string;
|
|
5515
5514
|
type: "base64";
|
|
5516
5515
|
media_type: "image/jpeg";
|
|
5516
|
+
data: string;
|
|
5517
5517
|
};
|
|
5518
5518
|
cache_control?: {
|
|
5519
5519
|
type: "ephemeral";
|
|
@@ -5572,12 +5572,12 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
5572
5572
|
path: z.ZodString;
|
|
5573
5573
|
content: z.ZodString;
|
|
5574
5574
|
}, "strip", z.ZodTypeAny, {
|
|
5575
|
+
type: "patch" | "file";
|
|
5575
5576
|
path: string;
|
|
5576
|
-
type: "file" | "patch";
|
|
5577
5577
|
content: string;
|
|
5578
5578
|
}, {
|
|
5579
|
+
type: "patch" | "file";
|
|
5579
5580
|
path: string;
|
|
5580
|
-
type: "file" | "patch";
|
|
5581
5581
|
content: string;
|
|
5582
5582
|
}>, "many">;
|
|
5583
5583
|
changesAlreadyApplied: z.ZodArray<z.ZodObject<{
|
|
@@ -5585,12 +5585,12 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
5585
5585
|
path: z.ZodString;
|
|
5586
5586
|
content: z.ZodString;
|
|
5587
5587
|
}, "strip", z.ZodTypeAny, {
|
|
5588
|
+
type: "patch" | "file";
|
|
5588
5589
|
path: string;
|
|
5589
|
-
type: "file" | "patch";
|
|
5590
5590
|
content: string;
|
|
5591
5591
|
}, {
|
|
5592
|
+
type: "patch" | "file";
|
|
5592
5593
|
path: string;
|
|
5593
|
-
type: "file" | "patch";
|
|
5594
5594
|
content: string;
|
|
5595
5595
|
}>, "many">;
|
|
5596
5596
|
addedFileVersions: z.ZodArray<z.ZodObject<{
|
|
@@ -5605,22 +5605,22 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
5605
5605
|
}>, "many">;
|
|
5606
5606
|
resetFileVersions: z.ZodBoolean;
|
|
5607
5607
|
}, "strip", z.ZodTypeAny, {
|
|
5608
|
+
type: "tool-call";
|
|
5609
|
+
userInputId: string;
|
|
5608
5610
|
data: {
|
|
5609
5611
|
name: string;
|
|
5610
5612
|
id: string;
|
|
5611
5613
|
input: Record<string, any>;
|
|
5612
5614
|
};
|
|
5613
|
-
type: "tool-call";
|
|
5614
|
-
userInputId: string;
|
|
5615
5615
|
changesAlreadyApplied: {
|
|
5616
|
+
type: "patch" | "file";
|
|
5616
5617
|
path: string;
|
|
5617
|
-
type: "file" | "patch";
|
|
5618
5618
|
content: string;
|
|
5619
5619
|
}[];
|
|
5620
5620
|
response: string;
|
|
5621
5621
|
changes: {
|
|
5622
|
+
type: "patch" | "file";
|
|
5622
5623
|
path: string;
|
|
5623
|
-
type: "file" | "patch";
|
|
5624
5624
|
content: string;
|
|
5625
5625
|
}[];
|
|
5626
5626
|
addedFileVersions: {
|
|
@@ -5629,22 +5629,22 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
5629
5629
|
}[];
|
|
5630
5630
|
resetFileVersions: boolean;
|
|
5631
5631
|
}, {
|
|
5632
|
+
type: "tool-call";
|
|
5633
|
+
userInputId: string;
|
|
5632
5634
|
data: {
|
|
5633
5635
|
name: string;
|
|
5634
5636
|
id: string;
|
|
5635
5637
|
input: Record<string, any>;
|
|
5636
5638
|
};
|
|
5637
|
-
type: "tool-call";
|
|
5638
|
-
userInputId: string;
|
|
5639
5639
|
changesAlreadyApplied: {
|
|
5640
|
+
type: "patch" | "file";
|
|
5640
5641
|
path: string;
|
|
5641
|
-
type: "file" | "patch";
|
|
5642
5642
|
content: string;
|
|
5643
5643
|
}[];
|
|
5644
5644
|
response: string;
|
|
5645
5645
|
changes: {
|
|
5646
|
+
type: "patch" | "file";
|
|
5646
5647
|
path: string;
|
|
5647
|
-
type: "file" | "patch";
|
|
5648
5648
|
content: string;
|
|
5649
5649
|
}[];
|
|
5650
5650
|
addedFileVersions: {
|
|
@@ -5658,12 +5658,12 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
5658
5658
|
result: z.ZodString;
|
|
5659
5659
|
}, "strip", z.ZodTypeAny, {
|
|
5660
5660
|
type: "terminal-command-result";
|
|
5661
|
-
result: string;
|
|
5662
5661
|
userInputId: string;
|
|
5662
|
+
result: string;
|
|
5663
5663
|
}, {
|
|
5664
5664
|
type: "terminal-command-result";
|
|
5665
|
-
result: string;
|
|
5666
5665
|
userInputId: string;
|
|
5666
|
+
result: string;
|
|
5667
5667
|
}>, z.ZodObject<{
|
|
5668
5668
|
type: z.ZodLiteral<"npm-version-status">;
|
|
5669
5669
|
isUpToDate: z.ZodBoolean;
|
|
@@ -5730,11 +5730,11 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
5730
5730
|
type: z.ZodLiteral<"action-error">;
|
|
5731
5731
|
message: z.ZodString;
|
|
5732
5732
|
}, "strip", z.ZodTypeAny, {
|
|
5733
|
-
message: string;
|
|
5734
5733
|
type: "action-error";
|
|
5735
|
-
}, {
|
|
5736
5734
|
message: string;
|
|
5735
|
+
}, {
|
|
5737
5736
|
type: "action-error";
|
|
5737
|
+
message: string;
|
|
5738
5738
|
}>, z.ZodObject<{
|
|
5739
5739
|
type: z.ZodLiteral<"commit-message-response">;
|
|
5740
5740
|
commitMessage: z.ZodString;
|
|
@@ -5746,6 +5746,7 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
5746
5746
|
commitMessage: string;
|
|
5747
5747
|
}>]>;
|
|
5748
5748
|
}, "strip", z.ZodTypeAny, {
|
|
5749
|
+
type: "action";
|
|
5749
5750
|
data: {
|
|
5750
5751
|
type: "usage-response";
|
|
5751
5752
|
usage: number;
|
|
@@ -5766,14 +5767,14 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
5766
5767
|
type: "response-complete";
|
|
5767
5768
|
userInputId: string;
|
|
5768
5769
|
changesAlreadyApplied: {
|
|
5770
|
+
type: "patch" | "file";
|
|
5769
5771
|
path: string;
|
|
5770
|
-
type: "file" | "patch";
|
|
5771
5772
|
content: string;
|
|
5772
5773
|
}[];
|
|
5773
5774
|
response: string;
|
|
5774
5775
|
changes: {
|
|
5776
|
+
type: "patch" | "file";
|
|
5775
5777
|
path: string;
|
|
5776
|
-
type: "file" | "patch";
|
|
5777
5778
|
content: string;
|
|
5778
5779
|
}[];
|
|
5779
5780
|
addedFileVersions: {
|
|
@@ -5791,15 +5792,14 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
5791
5792
|
type: "prompt-response";
|
|
5792
5793
|
promptId: string;
|
|
5793
5794
|
agentState: {
|
|
5794
|
-
agentContext: string;
|
|
5795
5795
|
fileContext: {
|
|
5796
5796
|
currentWorkingDirectory: string;
|
|
5797
5797
|
fileTree: import("../util/file").FileTreeNode[];
|
|
5798
5798
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
5799
5799
|
knowledgeFiles: Record<string, string>;
|
|
5800
5800
|
gitChanges: {
|
|
5801
|
-
status: string;
|
|
5802
5801
|
diff: string;
|
|
5802
|
+
status: string;
|
|
5803
5803
|
diffCached: string;
|
|
5804
5804
|
lastCommitMessages: string;
|
|
5805
5805
|
};
|
|
@@ -5819,10 +5819,11 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
5819
5819
|
}[][];
|
|
5820
5820
|
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
5821
5821
|
};
|
|
5822
|
+
agentContext: string;
|
|
5822
5823
|
messageHistory: {
|
|
5823
5824
|
content: string | ({
|
|
5824
|
-
text: string;
|
|
5825
5825
|
type: "text";
|
|
5826
|
+
text: string;
|
|
5826
5827
|
cache_control?: {
|
|
5827
5828
|
type: "ephemeral";
|
|
5828
5829
|
} | undefined;
|
|
@@ -5844,9 +5845,9 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
5844
5845
|
} | {
|
|
5845
5846
|
type: "image";
|
|
5846
5847
|
source: {
|
|
5847
|
-
data: string;
|
|
5848
5848
|
type: "base64";
|
|
5849
5849
|
media_type: "image/jpeg";
|
|
5850
|
+
data: string;
|
|
5850
5851
|
};
|
|
5851
5852
|
cache_control?: {
|
|
5852
5853
|
type: "ephemeral";
|
|
@@ -5880,22 +5881,22 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
5880
5881
|
requestId: string;
|
|
5881
5882
|
filePaths: string[];
|
|
5882
5883
|
} | {
|
|
5884
|
+
type: "tool-call";
|
|
5885
|
+
userInputId: string;
|
|
5883
5886
|
data: {
|
|
5884
5887
|
name: string;
|
|
5885
5888
|
id: string;
|
|
5886
5889
|
input: Record<string, any>;
|
|
5887
5890
|
};
|
|
5888
|
-
type: "tool-call";
|
|
5889
|
-
userInputId: string;
|
|
5890
5891
|
changesAlreadyApplied: {
|
|
5892
|
+
type: "patch" | "file";
|
|
5891
5893
|
path: string;
|
|
5892
|
-
type: "file" | "patch";
|
|
5893
5894
|
content: string;
|
|
5894
5895
|
}[];
|
|
5895
5896
|
response: string;
|
|
5896
5897
|
changes: {
|
|
5898
|
+
type: "patch" | "file";
|
|
5897
5899
|
path: string;
|
|
5898
|
-
type: "file" | "patch";
|
|
5899
5900
|
content: string;
|
|
5900
5901
|
}[];
|
|
5901
5902
|
addedFileVersions: {
|
|
@@ -5905,21 +5906,21 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
5905
5906
|
resetFileVersions: boolean;
|
|
5906
5907
|
} | {
|
|
5907
5908
|
type: "terminal-command-result";
|
|
5908
|
-
result: string;
|
|
5909
5909
|
userInputId: string;
|
|
5910
|
+
result: string;
|
|
5910
5911
|
} | {
|
|
5911
5912
|
type: "npm-version-status";
|
|
5912
5913
|
isUpToDate: boolean;
|
|
5913
5914
|
latestVersion: string;
|
|
5914
5915
|
} | {
|
|
5915
|
-
message: string;
|
|
5916
5916
|
type: "action-error";
|
|
5917
|
+
message: string;
|
|
5917
5918
|
} | {
|
|
5918
5919
|
type: "commit-message-response";
|
|
5919
5920
|
commitMessage: string;
|
|
5920
5921
|
};
|
|
5921
|
-
type: "action";
|
|
5922
5922
|
}, {
|
|
5923
|
+
type: "action";
|
|
5923
5924
|
data: {
|
|
5924
5925
|
type: "usage-response";
|
|
5925
5926
|
usage: number;
|
|
@@ -5940,14 +5941,14 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
5940
5941
|
type: "response-complete";
|
|
5941
5942
|
userInputId: string;
|
|
5942
5943
|
changesAlreadyApplied: {
|
|
5944
|
+
type: "patch" | "file";
|
|
5943
5945
|
path: string;
|
|
5944
|
-
type: "file" | "patch";
|
|
5945
5946
|
content: string;
|
|
5946
5947
|
}[];
|
|
5947
5948
|
response: string;
|
|
5948
5949
|
changes: {
|
|
5950
|
+
type: "patch" | "file";
|
|
5949
5951
|
path: string;
|
|
5950
|
-
type: "file" | "patch";
|
|
5951
5952
|
content: string;
|
|
5952
5953
|
}[];
|
|
5953
5954
|
addedFileVersions: {
|
|
@@ -5965,15 +5966,14 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
5965
5966
|
type: "prompt-response";
|
|
5966
5967
|
promptId: string;
|
|
5967
5968
|
agentState: {
|
|
5968
|
-
agentContext: string;
|
|
5969
5969
|
fileContext: {
|
|
5970
5970
|
currentWorkingDirectory: string;
|
|
5971
5971
|
fileTree: import("../util/file").FileTreeNode[];
|
|
5972
5972
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
5973
5973
|
knowledgeFiles: Record<string, string>;
|
|
5974
5974
|
gitChanges: {
|
|
5975
|
-
status: string;
|
|
5976
5975
|
diff: string;
|
|
5976
|
+
status: string;
|
|
5977
5977
|
diffCached: string;
|
|
5978
5978
|
lastCommitMessages: string;
|
|
5979
5979
|
};
|
|
@@ -5993,10 +5993,11 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
5993
5993
|
}[][];
|
|
5994
5994
|
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
5995
5995
|
};
|
|
5996
|
+
agentContext: string;
|
|
5996
5997
|
messageHistory: {
|
|
5997
5998
|
content: string | ({
|
|
5998
|
-
text: string;
|
|
5999
5999
|
type: "text";
|
|
6000
|
+
text: string;
|
|
6000
6001
|
cache_control?: {
|
|
6001
6002
|
type: "ephemeral";
|
|
6002
6003
|
} | undefined;
|
|
@@ -6018,9 +6019,9 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
6018
6019
|
} | {
|
|
6019
6020
|
type: "image";
|
|
6020
6021
|
source: {
|
|
6021
|
-
data: string;
|
|
6022
6022
|
type: "base64";
|
|
6023
6023
|
media_type: "image/jpeg";
|
|
6024
|
+
data: string;
|
|
6024
6025
|
};
|
|
6025
6026
|
cache_control?: {
|
|
6026
6027
|
type: "ephemeral";
|
|
@@ -6054,22 +6055,22 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
6054
6055
|
requestId: string;
|
|
6055
6056
|
filePaths: string[];
|
|
6056
6057
|
} | {
|
|
6058
|
+
type: "tool-call";
|
|
6059
|
+
userInputId: string;
|
|
6057
6060
|
data: {
|
|
6058
6061
|
name: string;
|
|
6059
6062
|
id: string;
|
|
6060
6063
|
input: Record<string, any>;
|
|
6061
6064
|
};
|
|
6062
|
-
type: "tool-call";
|
|
6063
|
-
userInputId: string;
|
|
6064
6065
|
changesAlreadyApplied: {
|
|
6066
|
+
type: "patch" | "file";
|
|
6065
6067
|
path: string;
|
|
6066
|
-
type: "file" | "patch";
|
|
6067
6068
|
content: string;
|
|
6068
6069
|
}[];
|
|
6069
6070
|
response: string;
|
|
6070
6071
|
changes: {
|
|
6072
|
+
type: "patch" | "file";
|
|
6071
6073
|
path: string;
|
|
6072
|
-
type: "file" | "patch";
|
|
6073
6074
|
content: string;
|
|
6074
6075
|
}[];
|
|
6075
6076
|
addedFileVersions: {
|
|
@@ -6079,20 +6080,19 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
|
|
|
6079
6080
|
resetFileVersions: boolean;
|
|
6080
6081
|
} | {
|
|
6081
6082
|
type: "terminal-command-result";
|
|
6082
|
-
result: string;
|
|
6083
6083
|
userInputId: string;
|
|
6084
|
+
result: string;
|
|
6084
6085
|
} | {
|
|
6085
6086
|
type: "npm-version-status";
|
|
6086
6087
|
isUpToDate: boolean;
|
|
6087
6088
|
latestVersion: string;
|
|
6088
6089
|
} | {
|
|
6089
|
-
message: string;
|
|
6090
6090
|
type: "action-error";
|
|
6091
|
+
message: string;
|
|
6091
6092
|
} | {
|
|
6092
6093
|
type: "commit-message-response";
|
|
6093
6094
|
commitMessage: string;
|
|
6094
6095
|
};
|
|
6095
|
-
type: "action";
|
|
6096
6096
|
}>]>;
|
|
6097
6097
|
export type ServerMessageType = keyof typeof SERVER_MESSAGE_SCHEMAS;
|
|
6098
6098
|
export type ServerMessage<T extends ServerMessageType = ServerMessageType> = z.infer<(typeof SERVER_MESSAGE_SCHEMAS)[T]>;
|