codecane 1.0.148 → 1.0.150
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/README.md +1 -1
- package/dist/__tests__/browser-runner.test.d.ts +1 -0
- package/dist/__tests__/browser-runner.test.js +15 -0
- package/dist/__tests__/browser-runner.test.js.map +1 -0
- package/dist/browser-runner.d.ts +33 -0
- package/dist/browser-runner.js +599 -0
- package/dist/browser-runner.js.map +1 -0
- package/dist/chat-storage.d.ts +2 -4
- package/dist/chat-storage.js +74 -44
- package/dist/chat-storage.js.map +1 -1
- package/dist/cli.d.ts +2 -1
- package/dist/cli.js +64 -22
- package/dist/cli.js.map +1 -1
- package/dist/client.d.ts +7 -3
- package/dist/client.js +55 -37
- package/dist/client.js.map +1 -1
- package/dist/code-map/languages.js +7 -17
- package/dist/code-map/languages.js.map +1 -1
- package/dist/code-map/parse.js +7 -17
- package/dist/code-map/parse.js.map +1 -1
- package/dist/code-map/tsconfig.tsbuildinfo +1 -1
- package/dist/common/actions.d.ts +100 -81
- package/dist/common/actions.js +4 -0
- package/dist/common/actions.js.map +1 -1
- package/dist/common/advanced-analyzer.d.ts +19 -0
- package/dist/common/advanced-analyzer.js +140 -0
- package/dist/common/advanced-analyzer.js.map +1 -0
- package/dist/common/browser-actions.d.ts +4335 -0
- package/dist/common/browser-actions.js +330 -0
- package/dist/common/browser-actions.js.map +1 -0
- package/dist/common/constants.d.ts +3 -1
- package/dist/common/constants.js +5 -3
- package/dist/common/constants.js.map +1 -1
- package/dist/common/util/credentials.d.ts +2 -2
- package/dist/common/util/file.d.ts +3 -0
- package/dist/common/util/file.js +1 -0
- package/dist/common/util/file.js.map +1 -1
- package/dist/common/websockets/websocket-schema.d.ts +216 -158
- package/dist/index.js +17 -22
- package/dist/index.js.map +1 -1
- package/dist/menu.d.ts +2 -0
- package/dist/menu.js +29 -18
- package/dist/menu.js.map +1 -1
- package/dist/project-files.d.ts +6 -0
- package/dist/project-files.js +64 -22
- package/dist/project-files.js.map +1 -1
- package/dist/tool-handlers.d.ts +1 -0
- package/dist/tool-handlers.js +67 -6
- package/dist/tool-handlers.js.map +1 -1
- package/dist/utils/terminal.js +15 -25
- package/dist/utils/terminal.js.map +1 -1
- package/package.json +4 -3
- package/dist/common/util/helpers.d.ts +0 -1
- package/dist/common/util/helpers.js +0 -6
- package/dist/common/util/helpers.js.map +0 -1
package/dist/common/actions.d.ts
CHANGED
|
@@ -35,16 +35,16 @@ declare const MessageContentObjectSchema: z.ZodUnion<[z.ZodObject<{
|
|
|
35
35
|
}>>;
|
|
36
36
|
}, "strip", z.ZodTypeAny, {
|
|
37
37
|
type: "tool_use";
|
|
38
|
-
id: string;
|
|
39
38
|
name: string;
|
|
39
|
+
id: string;
|
|
40
40
|
input: Record<string, any>;
|
|
41
41
|
cache_control?: {
|
|
42
42
|
type: "ephemeral";
|
|
43
43
|
} | undefined;
|
|
44
44
|
}, {
|
|
45
45
|
type: "tool_use";
|
|
46
|
-
id: string;
|
|
47
46
|
name: string;
|
|
47
|
+
id: string;
|
|
48
48
|
input: Record<string, any>;
|
|
49
49
|
cache_control?: {
|
|
50
50
|
type: "ephemeral";
|
|
@@ -62,15 +62,15 @@ declare const MessageContentObjectSchema: z.ZodUnion<[z.ZodObject<{
|
|
|
62
62
|
}>>;
|
|
63
63
|
}, "strip", z.ZodTypeAny, {
|
|
64
64
|
type: "tool_result";
|
|
65
|
-
tool_use_id: string;
|
|
66
65
|
content: string;
|
|
66
|
+
tool_use_id: string;
|
|
67
67
|
cache_control?: {
|
|
68
68
|
type: "ephemeral";
|
|
69
69
|
} | undefined;
|
|
70
70
|
}, {
|
|
71
71
|
type: "tool_result";
|
|
72
|
-
tool_use_id: string;
|
|
73
72
|
content: string;
|
|
73
|
+
tool_use_id: string;
|
|
74
74
|
cache_control?: {
|
|
75
75
|
type: "ephemeral";
|
|
76
76
|
} | undefined;
|
|
@@ -113,16 +113,16 @@ declare const MessageSchema: z.ZodObject<{
|
|
|
113
113
|
}>>;
|
|
114
114
|
}, "strip", z.ZodTypeAny, {
|
|
115
115
|
type: "tool_use";
|
|
116
|
-
id: string;
|
|
117
116
|
name: string;
|
|
117
|
+
id: string;
|
|
118
118
|
input: Record<string, any>;
|
|
119
119
|
cache_control?: {
|
|
120
120
|
type: "ephemeral";
|
|
121
121
|
} | undefined;
|
|
122
122
|
}, {
|
|
123
123
|
type: "tool_use";
|
|
124
|
-
id: string;
|
|
125
124
|
name: string;
|
|
125
|
+
id: string;
|
|
126
126
|
input: Record<string, any>;
|
|
127
127
|
cache_control?: {
|
|
128
128
|
type: "ephemeral";
|
|
@@ -140,15 +140,15 @@ declare const MessageSchema: z.ZodObject<{
|
|
|
140
140
|
}>>;
|
|
141
141
|
}, "strip", z.ZodTypeAny, {
|
|
142
142
|
type: "tool_result";
|
|
143
|
-
tool_use_id: string;
|
|
144
143
|
content: string;
|
|
144
|
+
tool_use_id: string;
|
|
145
145
|
cache_control?: {
|
|
146
146
|
type: "ephemeral";
|
|
147
147
|
} | undefined;
|
|
148
148
|
}, {
|
|
149
149
|
type: "tool_result";
|
|
150
|
-
tool_use_id: string;
|
|
151
150
|
content: string;
|
|
151
|
+
tool_use_id: string;
|
|
152
152
|
cache_control?: {
|
|
153
153
|
type: "ephemeral";
|
|
154
154
|
} | undefined;
|
|
@@ -162,16 +162,16 @@ declare const MessageSchema: z.ZodObject<{
|
|
|
162
162
|
} | undefined;
|
|
163
163
|
} | {
|
|
164
164
|
type: "tool_use";
|
|
165
|
-
id: string;
|
|
166
165
|
name: string;
|
|
166
|
+
id: string;
|
|
167
167
|
input: Record<string, any>;
|
|
168
168
|
cache_control?: {
|
|
169
169
|
type: "ephemeral";
|
|
170
170
|
} | undefined;
|
|
171
171
|
} | {
|
|
172
172
|
type: "tool_result";
|
|
173
|
-
tool_use_id: string;
|
|
174
173
|
content: string;
|
|
174
|
+
tool_use_id: string;
|
|
175
175
|
cache_control?: {
|
|
176
176
|
type: "ephemeral";
|
|
177
177
|
} | undefined;
|
|
@@ -186,16 +186,16 @@ declare const MessageSchema: z.ZodObject<{
|
|
|
186
186
|
} | undefined;
|
|
187
187
|
} | {
|
|
188
188
|
type: "tool_use";
|
|
189
|
-
id: string;
|
|
190
189
|
name: string;
|
|
190
|
+
id: string;
|
|
191
191
|
input: Record<string, any>;
|
|
192
192
|
cache_control?: {
|
|
193
193
|
type: "ephemeral";
|
|
194
194
|
} | undefined;
|
|
195
195
|
} | {
|
|
196
196
|
type: "tool_result";
|
|
197
|
-
tool_use_id: string;
|
|
198
197
|
content: string;
|
|
198
|
+
tool_use_id: string;
|
|
199
199
|
cache_control?: {
|
|
200
200
|
type: "ephemeral";
|
|
201
201
|
} | undefined;
|
|
@@ -210,12 +210,12 @@ export declare const FileChangeSchema: z.ZodObject<{
|
|
|
210
210
|
content: z.ZodString;
|
|
211
211
|
}, "strip", z.ZodTypeAny, {
|
|
212
212
|
type: "patch" | "file";
|
|
213
|
-
content: string;
|
|
214
213
|
filePath: string;
|
|
214
|
+
content: string;
|
|
215
215
|
}, {
|
|
216
216
|
type: "patch" | "file";
|
|
217
|
-
content: string;
|
|
218
217
|
filePath: string;
|
|
218
|
+
content: string;
|
|
219
219
|
}>;
|
|
220
220
|
export type FileChange = z.infer<typeof FileChangeSchema>;
|
|
221
221
|
export declare const CHANGES: z.ZodArray<z.ZodObject<{
|
|
@@ -224,12 +224,12 @@ export declare const CHANGES: z.ZodArray<z.ZodObject<{
|
|
|
224
224
|
content: z.ZodString;
|
|
225
225
|
}, "strip", z.ZodTypeAny, {
|
|
226
226
|
type: "patch" | "file";
|
|
227
|
-
content: string;
|
|
228
227
|
filePath: string;
|
|
228
|
+
content: string;
|
|
229
229
|
}, {
|
|
230
230
|
type: "patch" | "file";
|
|
231
|
-
content: string;
|
|
232
231
|
filePath: string;
|
|
232
|
+
content: string;
|
|
233
233
|
}>, "many">;
|
|
234
234
|
export type FileChanges = z.infer<typeof CHANGES>;
|
|
235
235
|
export declare const ToolCallSchema: z.ZodObject<{
|
|
@@ -237,12 +237,12 @@ export declare const ToolCallSchema: z.ZodObject<{
|
|
|
237
237
|
id: z.ZodString;
|
|
238
238
|
input: z.ZodRecord<z.ZodString, z.ZodAny>;
|
|
239
239
|
}, "strip", z.ZodTypeAny, {
|
|
240
|
-
id: string;
|
|
241
240
|
name: string;
|
|
241
|
+
id: string;
|
|
242
242
|
input: Record<string, any>;
|
|
243
243
|
}, {
|
|
244
|
-
id: string;
|
|
245
244
|
name: string;
|
|
245
|
+
id: string;
|
|
246
246
|
input: Record<string, any>;
|
|
247
247
|
}>;
|
|
248
248
|
export type ToolCall = z.infer<typeof ToolCallSchema>;
|
|
@@ -289,16 +289,16 @@ export declare const CLIENT_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
|
|
|
289
289
|
}>>;
|
|
290
290
|
}, "strip", z.ZodTypeAny, {
|
|
291
291
|
type: "tool_use";
|
|
292
|
-
id: string;
|
|
293
292
|
name: string;
|
|
293
|
+
id: string;
|
|
294
294
|
input: Record<string, any>;
|
|
295
295
|
cache_control?: {
|
|
296
296
|
type: "ephemeral";
|
|
297
297
|
} | undefined;
|
|
298
298
|
}, {
|
|
299
299
|
type: "tool_use";
|
|
300
|
-
id: string;
|
|
301
300
|
name: string;
|
|
301
|
+
id: string;
|
|
302
302
|
input: Record<string, any>;
|
|
303
303
|
cache_control?: {
|
|
304
304
|
type: "ephemeral";
|
|
@@ -316,15 +316,15 @@ export declare const CLIENT_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
|
|
|
316
316
|
}>>;
|
|
317
317
|
}, "strip", z.ZodTypeAny, {
|
|
318
318
|
type: "tool_result";
|
|
319
|
-
tool_use_id: string;
|
|
320
319
|
content: string;
|
|
320
|
+
tool_use_id: string;
|
|
321
321
|
cache_control?: {
|
|
322
322
|
type: "ephemeral";
|
|
323
323
|
} | undefined;
|
|
324
324
|
}, {
|
|
325
325
|
type: "tool_result";
|
|
326
|
-
tool_use_id: string;
|
|
327
326
|
content: string;
|
|
327
|
+
tool_use_id: string;
|
|
328
328
|
cache_control?: {
|
|
329
329
|
type: "ephemeral";
|
|
330
330
|
} | undefined;
|
|
@@ -338,16 +338,16 @@ export declare const CLIENT_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
|
|
|
338
338
|
} | undefined;
|
|
339
339
|
} | {
|
|
340
340
|
type: "tool_use";
|
|
341
|
-
id: string;
|
|
342
341
|
name: string;
|
|
342
|
+
id: string;
|
|
343
343
|
input: Record<string, any>;
|
|
344
344
|
cache_control?: {
|
|
345
345
|
type: "ephemeral";
|
|
346
346
|
} | undefined;
|
|
347
347
|
} | {
|
|
348
348
|
type: "tool_result";
|
|
349
|
-
tool_use_id: string;
|
|
350
349
|
content: string;
|
|
350
|
+
tool_use_id: string;
|
|
351
351
|
cache_control?: {
|
|
352
352
|
type: "ephemeral";
|
|
353
353
|
} | undefined;
|
|
@@ -362,16 +362,16 @@ export declare const CLIENT_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
|
|
|
362
362
|
} | undefined;
|
|
363
363
|
} | {
|
|
364
364
|
type: "tool_use";
|
|
365
|
-
id: string;
|
|
366
365
|
name: string;
|
|
366
|
+
id: string;
|
|
367
367
|
input: Record<string, any>;
|
|
368
368
|
cache_control?: {
|
|
369
369
|
type: "ephemeral";
|
|
370
370
|
} | undefined;
|
|
371
371
|
} | {
|
|
372
372
|
type: "tool_result";
|
|
373
|
-
tool_use_id: string;
|
|
374
373
|
content: string;
|
|
374
|
+
tool_use_id: string;
|
|
375
375
|
cache_control?: {
|
|
376
376
|
type: "ephemeral";
|
|
377
377
|
} | undefined;
|
|
@@ -383,19 +383,20 @@ export declare const CLIENT_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
|
|
|
383
383
|
fileTree: z.ZodArray<z.ZodType<import("./util/file").FileTreeNode, z.ZodTypeDef, import("./util/file").FileTreeNode>, "many">;
|
|
384
384
|
fileTokenScores: z.ZodRecord<z.ZodString, z.ZodRecord<z.ZodString, z.ZodNumber>>;
|
|
385
385
|
knowledgeFiles: z.ZodRecord<z.ZodString, z.ZodString>;
|
|
386
|
+
userKnowledgeFiles: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
386
387
|
gitChanges: z.ZodObject<{
|
|
387
388
|
status: z.ZodString;
|
|
388
389
|
diff: z.ZodString;
|
|
389
390
|
diffCached: z.ZodString;
|
|
390
391
|
lastCommitMessages: z.ZodString;
|
|
391
392
|
}, "strip", z.ZodTypeAny, {
|
|
392
|
-
diff: string;
|
|
393
393
|
status: string;
|
|
394
|
+
diff: string;
|
|
394
395
|
diffCached: string;
|
|
395
396
|
lastCommitMessages: string;
|
|
396
397
|
}, {
|
|
397
|
-
diff: string;
|
|
398
398
|
status: string;
|
|
399
|
+
diff: string;
|
|
399
400
|
diffCached: string;
|
|
400
401
|
lastCommitMessages: string;
|
|
401
402
|
}>;
|
|
@@ -439,8 +440,8 @@ export declare const CLIENT_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
|
|
|
439
440
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
440
441
|
knowledgeFiles: Record<string, string>;
|
|
441
442
|
gitChanges: {
|
|
442
|
-
diff: string;
|
|
443
443
|
status: string;
|
|
444
|
+
diff: string;
|
|
444
445
|
diffCached: string;
|
|
445
446
|
lastCommitMessages: string;
|
|
446
447
|
};
|
|
@@ -458,14 +459,15 @@ export declare const CLIENT_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
|
|
|
458
459
|
path: string;
|
|
459
460
|
content: string;
|
|
460
461
|
}[][];
|
|
462
|
+
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
461
463
|
}, {
|
|
462
464
|
currentWorkingDirectory: string;
|
|
463
465
|
fileTree: import("./util/file").FileTreeNode[];
|
|
464
466
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
465
467
|
knowledgeFiles: Record<string, string>;
|
|
466
468
|
gitChanges: {
|
|
467
|
-
diff: string;
|
|
468
469
|
status: string;
|
|
470
|
+
diff: string;
|
|
469
471
|
diffCached: string;
|
|
470
472
|
lastCommitMessages: string;
|
|
471
473
|
};
|
|
@@ -483,6 +485,7 @@ export declare const CLIENT_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
|
|
|
483
485
|
path: string;
|
|
484
486
|
content: string;
|
|
485
487
|
}[][];
|
|
488
|
+
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
486
489
|
}>;
|
|
487
490
|
changesAlreadyApplied: z.ZodArray<z.ZodObject<{
|
|
488
491
|
type: z.ZodEnum<["patch", "file"]>;
|
|
@@ -490,14 +493,14 @@ export declare const CLIENT_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
|
|
|
490
493
|
content: z.ZodString;
|
|
491
494
|
}, "strip", z.ZodTypeAny, {
|
|
492
495
|
type: "patch" | "file";
|
|
493
|
-
content: string;
|
|
494
496
|
filePath: string;
|
|
497
|
+
content: string;
|
|
495
498
|
}, {
|
|
496
499
|
type: "patch" | "file";
|
|
497
|
-
content: string;
|
|
498
500
|
filePath: string;
|
|
501
|
+
content: string;
|
|
499
502
|
}>, "many">;
|
|
500
|
-
costMode: z.ZodDefault<z.ZodOptional<z.ZodEnum<["lite", "normal", "
|
|
503
|
+
costMode: z.ZodDefault<z.ZodOptional<z.ZodEnum<["lite", "normal", "max"]>>>;
|
|
501
504
|
}, "strip", z.ZodTypeAny, {
|
|
502
505
|
type: "user-input";
|
|
503
506
|
fingerprintId: string;
|
|
@@ -511,16 +514,16 @@ export declare const CLIENT_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
|
|
|
511
514
|
} | undefined;
|
|
512
515
|
} | {
|
|
513
516
|
type: "tool_use";
|
|
514
|
-
id: string;
|
|
515
517
|
name: string;
|
|
518
|
+
id: string;
|
|
516
519
|
input: Record<string, any>;
|
|
517
520
|
cache_control?: {
|
|
518
521
|
type: "ephemeral";
|
|
519
522
|
} | undefined;
|
|
520
523
|
} | {
|
|
521
524
|
type: "tool_result";
|
|
522
|
-
tool_use_id: string;
|
|
523
525
|
content: string;
|
|
526
|
+
tool_use_id: string;
|
|
524
527
|
cache_control?: {
|
|
525
528
|
type: "ephemeral";
|
|
526
529
|
} | undefined;
|
|
@@ -533,8 +536,8 @@ export declare const CLIENT_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
|
|
|
533
536
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
534
537
|
knowledgeFiles: Record<string, string>;
|
|
535
538
|
gitChanges: {
|
|
536
|
-
diff: string;
|
|
537
539
|
status: string;
|
|
540
|
+
diff: string;
|
|
538
541
|
diffCached: string;
|
|
539
542
|
lastCommitMessages: string;
|
|
540
543
|
};
|
|
@@ -552,13 +555,14 @@ export declare const CLIENT_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
|
|
|
552
555
|
path: string;
|
|
553
556
|
content: string;
|
|
554
557
|
}[][];
|
|
558
|
+
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
555
559
|
};
|
|
556
560
|
changesAlreadyApplied: {
|
|
557
561
|
type: "patch" | "file";
|
|
558
|
-
content: string;
|
|
559
562
|
filePath: string;
|
|
563
|
+
content: string;
|
|
560
564
|
}[];
|
|
561
|
-
costMode: "
|
|
565
|
+
costMode: "max" | "lite" | "normal";
|
|
562
566
|
authToken?: string | undefined;
|
|
563
567
|
}, {
|
|
564
568
|
type: "user-input";
|
|
@@ -573,16 +577,16 @@ export declare const CLIENT_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
|
|
|
573
577
|
} | undefined;
|
|
574
578
|
} | {
|
|
575
579
|
type: "tool_use";
|
|
576
|
-
id: string;
|
|
577
580
|
name: string;
|
|
581
|
+
id: string;
|
|
578
582
|
input: Record<string, any>;
|
|
579
583
|
cache_control?: {
|
|
580
584
|
type: "ephemeral";
|
|
581
585
|
} | undefined;
|
|
582
586
|
} | {
|
|
583
587
|
type: "tool_result";
|
|
584
|
-
tool_use_id: string;
|
|
585
588
|
content: string;
|
|
589
|
+
tool_use_id: string;
|
|
586
590
|
cache_control?: {
|
|
587
591
|
type: "ephemeral";
|
|
588
592
|
} | undefined;
|
|
@@ -595,8 +599,8 @@ export declare const CLIENT_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
|
|
|
595
599
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
596
600
|
knowledgeFiles: Record<string, string>;
|
|
597
601
|
gitChanges: {
|
|
598
|
-
diff: string;
|
|
599
602
|
status: string;
|
|
603
|
+
diff: string;
|
|
600
604
|
diffCached: string;
|
|
601
605
|
lastCommitMessages: string;
|
|
602
606
|
};
|
|
@@ -614,14 +618,15 @@ export declare const CLIENT_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
|
|
|
614
618
|
path: string;
|
|
615
619
|
content: string;
|
|
616
620
|
}[][];
|
|
621
|
+
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
617
622
|
};
|
|
618
623
|
changesAlreadyApplied: {
|
|
619
624
|
type: "patch" | "file";
|
|
620
|
-
content: string;
|
|
621
625
|
filePath: string;
|
|
626
|
+
content: string;
|
|
622
627
|
}[];
|
|
623
628
|
authToken?: string | undefined;
|
|
624
|
-
costMode?: "
|
|
629
|
+
costMode?: "max" | "lite" | "normal" | undefined;
|
|
625
630
|
}>, z.ZodObject<{
|
|
626
631
|
type: z.ZodLiteral<"read-files-response">;
|
|
627
632
|
files: z.ZodRecord<z.ZodString, z.ZodUnion<[z.ZodString, z.ZodNull]>>;
|
|
@@ -640,19 +645,20 @@ export declare const CLIENT_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
|
|
|
640
645
|
fileTree: z.ZodArray<z.ZodType<import("./util/file").FileTreeNode, z.ZodTypeDef, import("./util/file").FileTreeNode>, "many">;
|
|
641
646
|
fileTokenScores: z.ZodRecord<z.ZodString, z.ZodRecord<z.ZodString, z.ZodNumber>>;
|
|
642
647
|
knowledgeFiles: z.ZodRecord<z.ZodString, z.ZodString>;
|
|
648
|
+
userKnowledgeFiles: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
643
649
|
gitChanges: z.ZodObject<{
|
|
644
650
|
status: z.ZodString;
|
|
645
651
|
diff: z.ZodString;
|
|
646
652
|
diffCached: z.ZodString;
|
|
647
653
|
lastCommitMessages: z.ZodString;
|
|
648
654
|
}, "strip", z.ZodTypeAny, {
|
|
649
|
-
diff: string;
|
|
650
655
|
status: string;
|
|
656
|
+
diff: string;
|
|
651
657
|
diffCached: string;
|
|
652
658
|
lastCommitMessages: string;
|
|
653
659
|
}, {
|
|
654
|
-
diff: string;
|
|
655
660
|
status: string;
|
|
661
|
+
diff: string;
|
|
656
662
|
diffCached: string;
|
|
657
663
|
lastCommitMessages: string;
|
|
658
664
|
}>;
|
|
@@ -696,8 +702,8 @@ export declare const CLIENT_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
|
|
|
696
702
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
697
703
|
knowledgeFiles: Record<string, string>;
|
|
698
704
|
gitChanges: {
|
|
699
|
-
diff: string;
|
|
700
705
|
status: string;
|
|
706
|
+
diff: string;
|
|
701
707
|
diffCached: string;
|
|
702
708
|
lastCommitMessages: string;
|
|
703
709
|
};
|
|
@@ -715,14 +721,15 @@ export declare const CLIENT_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
|
|
|
715
721
|
path: string;
|
|
716
722
|
content: string;
|
|
717
723
|
}[][];
|
|
724
|
+
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
718
725
|
}, {
|
|
719
726
|
currentWorkingDirectory: string;
|
|
720
727
|
fileTree: import("./util/file").FileTreeNode[];
|
|
721
728
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
722
729
|
knowledgeFiles: Record<string, string>;
|
|
723
730
|
gitChanges: {
|
|
724
|
-
diff: string;
|
|
725
731
|
status: string;
|
|
732
|
+
diff: string;
|
|
726
733
|
diffCached: string;
|
|
727
734
|
lastCommitMessages: string;
|
|
728
735
|
};
|
|
@@ -740,6 +747,7 @@ export declare const CLIENT_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
|
|
|
740
747
|
path: string;
|
|
741
748
|
content: string;
|
|
742
749
|
}[][];
|
|
750
|
+
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
743
751
|
}>;
|
|
744
752
|
}, "strip", z.ZodTypeAny, {
|
|
745
753
|
type: "init";
|
|
@@ -750,8 +758,8 @@ export declare const CLIENT_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
|
|
|
750
758
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
751
759
|
knowledgeFiles: Record<string, string>;
|
|
752
760
|
gitChanges: {
|
|
753
|
-
diff: string;
|
|
754
761
|
status: string;
|
|
762
|
+
diff: string;
|
|
755
763
|
diffCached: string;
|
|
756
764
|
lastCommitMessages: string;
|
|
757
765
|
};
|
|
@@ -769,6 +777,7 @@ export declare const CLIENT_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
|
|
|
769
777
|
path: string;
|
|
770
778
|
content: string;
|
|
771
779
|
}[][];
|
|
780
|
+
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
772
781
|
};
|
|
773
782
|
authToken?: string | undefined;
|
|
774
783
|
}, {
|
|
@@ -780,8 +789,8 @@ export declare const CLIENT_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
|
|
|
780
789
|
fileTokenScores: Record<string, Record<string, number>>;
|
|
781
790
|
knowledgeFiles: Record<string, string>;
|
|
782
791
|
gitChanges: {
|
|
783
|
-
diff: string;
|
|
784
792
|
status: string;
|
|
793
|
+
diff: string;
|
|
785
794
|
diffCached: string;
|
|
786
795
|
lastCommitMessages: string;
|
|
787
796
|
};
|
|
@@ -799,6 +808,7 @@ export declare const CLIENT_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
|
|
|
799
808
|
path: string;
|
|
800
809
|
content: string;
|
|
801
810
|
}[][];
|
|
811
|
+
userKnowledgeFiles?: Record<string, string> | undefined;
|
|
802
812
|
};
|
|
803
813
|
authToken?: string | undefined;
|
|
804
814
|
}>, z.ZodObject<{
|
|
@@ -936,12 +946,12 @@ export declare const ResponseCompleteSchema: z.ZodObject<z.objectUtil.extendShap
|
|
|
936
946
|
content: z.ZodString;
|
|
937
947
|
}, "strip", z.ZodTypeAny, {
|
|
938
948
|
type: "patch" | "file";
|
|
939
|
-
content: string;
|
|
940
949
|
filePath: string;
|
|
950
|
+
content: string;
|
|
941
951
|
}, {
|
|
942
952
|
type: "patch" | "file";
|
|
943
|
-
content: string;
|
|
944
953
|
filePath: string;
|
|
954
|
+
content: string;
|
|
945
955
|
}>, "many">;
|
|
946
956
|
changesAlreadyApplied: z.ZodArray<z.ZodObject<{
|
|
947
957
|
type: z.ZodEnum<["patch", "file"]>;
|
|
@@ -949,12 +959,12 @@ export declare const ResponseCompleteSchema: z.ZodObject<z.objectUtil.extendShap
|
|
|
949
959
|
content: z.ZodString;
|
|
950
960
|
}, "strip", z.ZodTypeAny, {
|
|
951
961
|
type: "patch" | "file";
|
|
952
|
-
content: string;
|
|
953
962
|
filePath: string;
|
|
963
|
+
content: string;
|
|
954
964
|
}, {
|
|
955
965
|
type: "patch" | "file";
|
|
956
|
-
content: string;
|
|
957
966
|
filePath: string;
|
|
967
|
+
content: string;
|
|
958
968
|
}>, "many">;
|
|
959
969
|
addedFileVersions: z.ZodArray<z.ZodObject<{
|
|
960
970
|
path: z.ZodString;
|
|
@@ -979,14 +989,14 @@ export declare const ResponseCompleteSchema: z.ZodObject<z.objectUtil.extendShap
|
|
|
979
989
|
userInputId: string;
|
|
980
990
|
changesAlreadyApplied: {
|
|
981
991
|
type: "patch" | "file";
|
|
982
|
-
content: string;
|
|
983
992
|
filePath: string;
|
|
993
|
+
content: string;
|
|
984
994
|
}[];
|
|
985
995
|
response: string;
|
|
986
996
|
changes: {
|
|
987
997
|
type: "patch" | "file";
|
|
988
|
-
content: string;
|
|
989
998
|
filePath: string;
|
|
999
|
+
content: string;
|
|
990
1000
|
}[];
|
|
991
1001
|
addedFileVersions: {
|
|
992
1002
|
path: string;
|
|
@@ -1004,14 +1014,14 @@ export declare const ResponseCompleteSchema: z.ZodObject<z.objectUtil.extendShap
|
|
|
1004
1014
|
userInputId: string;
|
|
1005
1015
|
changesAlreadyApplied: {
|
|
1006
1016
|
type: "patch" | "file";
|
|
1007
|
-
content: string;
|
|
1008
1017
|
filePath: string;
|
|
1018
|
+
content: string;
|
|
1009
1019
|
}[];
|
|
1010
1020
|
response: string;
|
|
1011
1021
|
changes: {
|
|
1012
1022
|
type: "patch" | "file";
|
|
1013
|
-
content: string;
|
|
1014
1023
|
filePath: string;
|
|
1024
|
+
content: string;
|
|
1015
1025
|
}[];
|
|
1016
1026
|
addedFileVersions: {
|
|
1017
1027
|
path: string;
|
|
@@ -1026,6 +1036,15 @@ export declare const ResponseCompleteSchema: z.ZodObject<z.objectUtil.extendShap
|
|
|
1026
1036
|
session_credits_used?: number | undefined;
|
|
1027
1037
|
}>;
|
|
1028
1038
|
export declare const SERVER_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
|
|
1039
|
+
type: z.ZodLiteral<"read-files-response">;
|
|
1040
|
+
files: z.ZodRecord<z.ZodString, z.ZodNullable<z.ZodString>>;
|
|
1041
|
+
}, "strip", z.ZodTypeAny, {
|
|
1042
|
+
type: "read-files-response";
|
|
1043
|
+
files: Record<string, string | null>;
|
|
1044
|
+
}, {
|
|
1045
|
+
type: "read-files-response";
|
|
1046
|
+
files: Record<string, string | null>;
|
|
1047
|
+
}>, z.ZodObject<{
|
|
1029
1048
|
type: z.ZodLiteral<"response-chunk">;
|
|
1030
1049
|
userInputId: z.ZodString;
|
|
1031
1050
|
chunk: z.ZodString;
|
|
@@ -1047,12 +1066,12 @@ export declare const SERVER_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
|
|
|
1047
1066
|
content: z.ZodString;
|
|
1048
1067
|
}, "strip", z.ZodTypeAny, {
|
|
1049
1068
|
type: "patch" | "file";
|
|
1050
|
-
content: string;
|
|
1051
1069
|
filePath: string;
|
|
1070
|
+
content: string;
|
|
1052
1071
|
}, {
|
|
1053
1072
|
type: "patch" | "file";
|
|
1054
|
-
content: string;
|
|
1055
1073
|
filePath: string;
|
|
1074
|
+
content: string;
|
|
1056
1075
|
}>, "many">;
|
|
1057
1076
|
changesAlreadyApplied: z.ZodArray<z.ZodObject<{
|
|
1058
1077
|
type: z.ZodEnum<["patch", "file"]>;
|
|
@@ -1060,12 +1079,12 @@ export declare const SERVER_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
|
|
|
1060
1079
|
content: z.ZodString;
|
|
1061
1080
|
}, "strip", z.ZodTypeAny, {
|
|
1062
1081
|
type: "patch" | "file";
|
|
1063
|
-
content: string;
|
|
1064
1082
|
filePath: string;
|
|
1083
|
+
content: string;
|
|
1065
1084
|
}, {
|
|
1066
1085
|
type: "patch" | "file";
|
|
1067
|
-
content: string;
|
|
1068
1086
|
filePath: string;
|
|
1087
|
+
content: string;
|
|
1069
1088
|
}>, "many">;
|
|
1070
1089
|
addedFileVersions: z.ZodArray<z.ZodObject<{
|
|
1071
1090
|
path: z.ZodString;
|
|
@@ -1090,14 +1109,14 @@ export declare const SERVER_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
|
|
|
1090
1109
|
userInputId: string;
|
|
1091
1110
|
changesAlreadyApplied: {
|
|
1092
1111
|
type: "patch" | "file";
|
|
1093
|
-
content: string;
|
|
1094
1112
|
filePath: string;
|
|
1113
|
+
content: string;
|
|
1095
1114
|
}[];
|
|
1096
1115
|
response: string;
|
|
1097
1116
|
changes: {
|
|
1098
1117
|
type: "patch" | "file";
|
|
1099
|
-
content: string;
|
|
1100
1118
|
filePath: string;
|
|
1119
|
+
content: string;
|
|
1101
1120
|
}[];
|
|
1102
1121
|
addedFileVersions: {
|
|
1103
1122
|
path: string;
|
|
@@ -1115,14 +1134,14 @@ export declare const SERVER_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
|
|
|
1115
1134
|
userInputId: string;
|
|
1116
1135
|
changesAlreadyApplied: {
|
|
1117
1136
|
type: "patch" | "file";
|
|
1118
|
-
content: string;
|
|
1119
1137
|
filePath: string;
|
|
1138
|
+
content: string;
|
|
1120
1139
|
}[];
|
|
1121
1140
|
response: string;
|
|
1122
1141
|
changes: {
|
|
1123
1142
|
type: "patch" | "file";
|
|
1124
|
-
content: string;
|
|
1125
1143
|
filePath: string;
|
|
1144
|
+
content: string;
|
|
1126
1145
|
}[];
|
|
1127
1146
|
addedFileVersions: {
|
|
1128
1147
|
path: string;
|
|
@@ -1153,12 +1172,12 @@ export declare const SERVER_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
|
|
|
1153
1172
|
id: z.ZodString;
|
|
1154
1173
|
input: z.ZodRecord<z.ZodString, z.ZodAny>;
|
|
1155
1174
|
}, "strip", z.ZodTypeAny, {
|
|
1156
|
-
id: string;
|
|
1157
1175
|
name: string;
|
|
1176
|
+
id: string;
|
|
1158
1177
|
input: Record<string, any>;
|
|
1159
1178
|
}, {
|
|
1160
|
-
id: string;
|
|
1161
1179
|
name: string;
|
|
1180
|
+
id: string;
|
|
1162
1181
|
input: Record<string, any>;
|
|
1163
1182
|
}>;
|
|
1164
1183
|
changes: z.ZodArray<z.ZodObject<{
|
|
@@ -1167,12 +1186,12 @@ export declare const SERVER_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
|
|
|
1167
1186
|
content: z.ZodString;
|
|
1168
1187
|
}, "strip", z.ZodTypeAny, {
|
|
1169
1188
|
type: "patch" | "file";
|
|
1170
|
-
content: string;
|
|
1171
1189
|
filePath: string;
|
|
1190
|
+
content: string;
|
|
1172
1191
|
}, {
|
|
1173
1192
|
type: "patch" | "file";
|
|
1174
|
-
content: string;
|
|
1175
1193
|
filePath: string;
|
|
1194
|
+
content: string;
|
|
1176
1195
|
}>, "many">;
|
|
1177
1196
|
changesAlreadyApplied: z.ZodArray<z.ZodObject<{
|
|
1178
1197
|
type: z.ZodEnum<["patch", "file"]>;
|
|
@@ -1180,12 +1199,12 @@ export declare const SERVER_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
|
|
|
1180
1199
|
content: z.ZodString;
|
|
1181
1200
|
}, "strip", z.ZodTypeAny, {
|
|
1182
1201
|
type: "patch" | "file";
|
|
1183
|
-
content: string;
|
|
1184
1202
|
filePath: string;
|
|
1203
|
+
content: string;
|
|
1185
1204
|
}, {
|
|
1186
1205
|
type: "patch" | "file";
|
|
1187
|
-
content: string;
|
|
1188
1206
|
filePath: string;
|
|
1207
|
+
content: string;
|
|
1189
1208
|
}>, "many">;
|
|
1190
1209
|
addedFileVersions: z.ZodArray<z.ZodObject<{
|
|
1191
1210
|
path: z.ZodString;
|
|
@@ -1203,14 +1222,14 @@ export declare const SERVER_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
|
|
|
1203
1222
|
userInputId: string;
|
|
1204
1223
|
changesAlreadyApplied: {
|
|
1205
1224
|
type: "patch" | "file";
|
|
1206
|
-
content: string;
|
|
1207
1225
|
filePath: string;
|
|
1226
|
+
content: string;
|
|
1208
1227
|
}[];
|
|
1209
1228
|
response: string;
|
|
1210
1229
|
changes: {
|
|
1211
1230
|
type: "patch" | "file";
|
|
1212
|
-
content: string;
|
|
1213
1231
|
filePath: string;
|
|
1232
|
+
content: string;
|
|
1214
1233
|
}[];
|
|
1215
1234
|
addedFileVersions: {
|
|
1216
1235
|
path: string;
|
|
@@ -1218,8 +1237,8 @@ export declare const SERVER_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
|
|
|
1218
1237
|
}[];
|
|
1219
1238
|
resetFileVersions: boolean;
|
|
1220
1239
|
data: {
|
|
1221
|
-
id: string;
|
|
1222
1240
|
name: string;
|
|
1241
|
+
id: string;
|
|
1223
1242
|
input: Record<string, any>;
|
|
1224
1243
|
};
|
|
1225
1244
|
}, {
|
|
@@ -1227,14 +1246,14 @@ export declare const SERVER_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
|
|
|
1227
1246
|
userInputId: string;
|
|
1228
1247
|
changesAlreadyApplied: {
|
|
1229
1248
|
type: "patch" | "file";
|
|
1230
|
-
content: string;
|
|
1231
1249
|
filePath: string;
|
|
1250
|
+
content: string;
|
|
1232
1251
|
}[];
|
|
1233
1252
|
response: string;
|
|
1234
1253
|
changes: {
|
|
1235
1254
|
type: "patch" | "file";
|
|
1236
|
-
content: string;
|
|
1237
1255
|
filePath: string;
|
|
1256
|
+
content: string;
|
|
1238
1257
|
}[];
|
|
1239
1258
|
addedFileVersions: {
|
|
1240
1259
|
path: string;
|
|
@@ -1242,8 +1261,8 @@ export declare const SERVER_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
|
|
|
1242
1261
|
}[];
|
|
1243
1262
|
resetFileVersions: boolean;
|
|
1244
1263
|
data: {
|
|
1245
|
-
id: string;
|
|
1246
1264
|
name: string;
|
|
1265
|
+
id: string;
|
|
1247
1266
|
input: Record<string, any>;
|
|
1248
1267
|
};
|
|
1249
1268
|
}>, z.ZodObject<{
|
|
@@ -1306,15 +1325,15 @@ export declare const SERVER_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
|
|
|
1306
1325
|
fingerprintId: z.ZodString;
|
|
1307
1326
|
fingerprintHash: z.ZodString;
|
|
1308
1327
|
}, "strip", z.ZodTypeAny, {
|
|
1309
|
-
id: string;
|
|
1310
1328
|
name: string | null;
|
|
1329
|
+
id: string;
|
|
1311
1330
|
fingerprintId: string;
|
|
1312
1331
|
authToken: string;
|
|
1313
1332
|
email: string;
|
|
1314
1333
|
fingerprintHash: string;
|
|
1315
1334
|
}, {
|
|
1316
|
-
id: string;
|
|
1317
1335
|
name: string | null;
|
|
1336
|
+
id: string;
|
|
1318
1337
|
fingerprintId: string;
|
|
1319
1338
|
authToken: string;
|
|
1320
1339
|
email: string;
|
|
@@ -1325,8 +1344,8 @@ export declare const SERVER_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
|
|
|
1325
1344
|
type: "auth-result";
|
|
1326
1345
|
message: string;
|
|
1327
1346
|
user?: {
|
|
1328
|
-
id: string;
|
|
1329
1347
|
name: string | null;
|
|
1348
|
+
id: string;
|
|
1330
1349
|
fingerprintId: string;
|
|
1331
1350
|
authToken: string;
|
|
1332
1351
|
email: string;
|
|
@@ -1336,8 +1355,8 @@ export declare const SERVER_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
|
|
|
1336
1355
|
type: "auth-result";
|
|
1337
1356
|
message: string;
|
|
1338
1357
|
user?: {
|
|
1339
|
-
id: string;
|
|
1340
1358
|
name: string | null;
|
|
1359
|
+
id: string;
|
|
1341
1360
|
fingerprintId: string;
|
|
1342
1361
|
authToken: string;
|
|
1343
1362
|
email: string;
|