codebuff 1.0.308 → 1.0.310

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (56) hide show
  1. package/dist/cli-definitions.js +6 -0
  2. package/dist/cli-definitions.js.map +1 -1
  3. package/dist/cli.d.ts +1 -0
  4. package/dist/cli.js +6 -2
  5. package/dist/cli.js.map +1 -1
  6. package/dist/client.d.ts +2 -1
  7. package/dist/client.js +230 -8
  8. package/dist/client.js.map +1 -1
  9. package/dist/code-map/__mocks__/tree-sitter-typescript.d.ts +12 -0
  10. package/dist/code-map/__mocks__/tree-sitter-typescript.d.ts.map +1 -0
  11. package/dist/code-map/__mocks__/tree-sitter-typescript.js +14 -0
  12. package/dist/code-map/__mocks__/tree-sitter-typescript.js.map +1 -0
  13. package/dist/code-map/jest.config.d.ts +4 -0
  14. package/dist/code-map/jest.config.d.ts.map +1 -0
  15. package/dist/code-map/jest.config.js +18 -0
  16. package/dist/code-map/jest.config.js.map +1 -0
  17. package/dist/code-map/scripts/tree-sitter-test.cjs +27 -0
  18. package/dist/code-map/scripts/tree-sitter-test.cjs.map +1 -0
  19. package/dist/code-map/scripts/tree-sitter-test.d.cts +2 -0
  20. package/dist/code-map/scripts/tree-sitter-test.d.cts.map +1 -0
  21. package/dist/code-map/scripts/tree-sitter-test.d.ts +2 -0
  22. package/dist/code-map/scripts/tree-sitter-test.d.ts.map +1 -0
  23. package/dist/code-map/scripts/tree-sitter-test.js +54 -0
  24. package/dist/code-map/scripts/tree-sitter-test.js.map +1 -0
  25. package/dist/code-map/tsconfig.tsbuildinfo +1 -1
  26. package/dist/common/actions.d.ts +1327 -364
  27. package/dist/common/actions.js +22 -1
  28. package/dist/common/actions.js.map +1 -1
  29. package/dist/common/constants/tools.d.ts +2 -0
  30. package/dist/common/constants/tools.js +3 -0
  31. package/dist/common/constants/tools.js.map +1 -1
  32. package/dist/common/constants.d.ts +4 -0
  33. package/dist/common/constants.js +4 -0
  34. package/dist/common/constants.js.map +1 -1
  35. package/dist/common/json-config/constants.d.ts +13 -13
  36. package/dist/common/json-config/constants.js +1 -0
  37. package/dist/common/json-config/constants.js.map +1 -1
  38. package/dist/common/websockets/websocket-schema.d.ts +2014 -334
  39. package/dist/index.js +9 -4
  40. package/dist/index.js.map +1 -1
  41. package/dist/json-config/hooks.d.ts +4 -1
  42. package/dist/json-config/hooks.js +9 -7
  43. package/dist/json-config/hooks.js.map +1 -1
  44. package/dist/menu.js.map +1 -1
  45. package/dist/tool-handlers.d.ts +5 -1
  46. package/dist/tool-handlers.js +29 -1
  47. package/dist/tool-handlers.js.map +1 -1
  48. package/dist/types.d.ts +1 -0
  49. package/dist/utils/terminal.d.ts +17 -3
  50. package/dist/utils/terminal.js +165 -4
  51. package/dist/utils/terminal.js.map +1 -1
  52. package/dist/utils/tool-renderers.js +6 -0
  53. package/dist/utils/tool-renderers.js.map +1 -1
  54. package/dist/workers/checkpoint-worker.js +2 -0
  55. package/dist/workers/checkpoint-worker.js.map +1 -1
  56. package/package.json +2 -1
@@ -361,263 +361,1350 @@ export declare const CLIENT_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
361
361
  cwd?: string | undefined;
362
362
  repoName?: string | undefined;
363
363
  }>, z.ZodObject<{
364
- type: z.ZodLiteral<"read-files-response">;
365
- files: z.ZodRecord<z.ZodString, z.ZodUnion<[z.ZodString, z.ZodNull]>>;
366
- requestId: z.ZodOptional<z.ZodString>;
367
- }, "strip", z.ZodTypeAny, {
368
- type: "read-files-response";
369
- files: Record<string, string | null>;
370
- requestId?: string | undefined;
371
- }, {
372
- type: "read-files-response";
373
- files: Record<string, string | null>;
374
- requestId?: string | undefined;
375
- }>, z.ZodObject<{
376
- type: z.ZodLiteral<"init">;
377
- fingerprintId: z.ZodString;
378
- authToken: z.ZodOptional<z.ZodString>;
379
- fileContext: z.ZodObject<{
380
- currentWorkingDirectory: z.ZodString;
381
- fileTree: z.ZodArray<z.ZodType<import("./util/file").FileTreeNode, z.ZodTypeDef, import("./util/file").FileTreeNode>, "many">;
382
- fileTokenScores: z.ZodRecord<z.ZodString, z.ZodRecord<z.ZodString, z.ZodNumber>>;
383
- tokenCallers: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodRecord<z.ZodString, z.ZodArray<z.ZodString, "many">>>>;
384
- knowledgeFiles: z.ZodRecord<z.ZodString, z.ZodString>;
385
- userKnowledgeFiles: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
386
- gitChanges: z.ZodObject<{
387
- status: z.ZodString;
388
- diff: z.ZodString;
389
- diffCached: z.ZodString;
390
- lastCommitMessages: z.ZodString;
364
+ type: z.ZodLiteral<"manager-prompt">;
365
+ promptId: z.ZodString;
366
+ prompt: z.ZodOptional<z.ZodString>;
367
+ agentState: z.ZodObject<{
368
+ agentContext: z.ZodString;
369
+ fileContext: z.ZodObject<{
370
+ currentWorkingDirectory: z.ZodString;
371
+ fileTree: z.ZodArray<z.ZodType<import("./util/file").FileTreeNode, z.ZodTypeDef, import("./util/file").FileTreeNode>, "many">;
372
+ fileTokenScores: z.ZodRecord<z.ZodString, z.ZodRecord<z.ZodString, z.ZodNumber>>;
373
+ tokenCallers: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodRecord<z.ZodString, z.ZodArray<z.ZodString, "many">>>>;
374
+ knowledgeFiles: z.ZodRecord<z.ZodString, z.ZodString>;
375
+ userKnowledgeFiles: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
376
+ gitChanges: z.ZodObject<{
377
+ status: z.ZodString;
378
+ diff: z.ZodString;
379
+ diffCached: z.ZodString;
380
+ lastCommitMessages: z.ZodString;
381
+ }, "strip", z.ZodTypeAny, {
382
+ status: string;
383
+ diff: string;
384
+ diffCached: string;
385
+ lastCommitMessages: string;
386
+ }, {
387
+ status: string;
388
+ diff: string;
389
+ diffCached: string;
390
+ lastCommitMessages: string;
391
+ }>;
392
+ changesSinceLastChat: z.ZodRecord<z.ZodString, z.ZodString>;
393
+ shellConfigFiles: z.ZodRecord<z.ZodString, z.ZodString>;
394
+ systemInfo: z.ZodObject<{
395
+ platform: z.ZodString;
396
+ shell: z.ZodString;
397
+ nodeVersion: z.ZodString;
398
+ arch: z.ZodString;
399
+ homedir: z.ZodString;
400
+ cpus: z.ZodNumber;
401
+ }, "strip", z.ZodTypeAny, {
402
+ platform: string;
403
+ shell: string;
404
+ nodeVersion: string;
405
+ arch: string;
406
+ homedir: string;
407
+ cpus: number;
408
+ }, {
409
+ platform: string;
410
+ shell: string;
411
+ nodeVersion: string;
412
+ arch: string;
413
+ homedir: string;
414
+ cpus: number;
415
+ }>;
416
+ fileVersions: z.ZodOptional<z.ZodArray<z.ZodArray<z.ZodObject<{
417
+ path: z.ZodString;
418
+ content: z.ZodString;
419
+ }, "strip", z.ZodTypeAny, {
420
+ path: string;
421
+ content: string;
422
+ }, {
423
+ path: string;
424
+ content: string;
425
+ }>, "many">, "many">>;
391
426
  }, "strip", z.ZodTypeAny, {
392
- status: string;
393
- diff: string;
394
- diffCached: string;
395
- lastCommitMessages: string;
427
+ currentWorkingDirectory: string;
428
+ fileTree: import("./util/file").FileTreeNode[];
429
+ fileTokenScores: Record<string, Record<string, number>>;
430
+ knowledgeFiles: Record<string, string>;
431
+ gitChanges: {
432
+ status: string;
433
+ diff: string;
434
+ diffCached: string;
435
+ lastCommitMessages: string;
436
+ };
437
+ changesSinceLastChat: Record<string, string>;
438
+ shellConfigFiles: Record<string, string>;
439
+ systemInfo: {
440
+ platform: string;
441
+ shell: string;
442
+ nodeVersion: string;
443
+ arch: string;
444
+ homedir: string;
445
+ cpus: number;
446
+ };
447
+ tokenCallers?: Record<string, Record<string, string[]>> | undefined;
448
+ userKnowledgeFiles?: Record<string, string> | undefined;
449
+ fileVersions?: {
450
+ path: string;
451
+ content: string;
452
+ }[][] | undefined;
396
453
  }, {
397
- status: string;
398
- diff: string;
399
- diffCached: string;
400
- lastCommitMessages: string;
454
+ currentWorkingDirectory: string;
455
+ fileTree: import("./util/file").FileTreeNode[];
456
+ fileTokenScores: Record<string, Record<string, number>>;
457
+ knowledgeFiles: Record<string, string>;
458
+ gitChanges: {
459
+ status: string;
460
+ diff: string;
461
+ diffCached: string;
462
+ lastCommitMessages: string;
463
+ };
464
+ changesSinceLastChat: Record<string, string>;
465
+ shellConfigFiles: Record<string, string>;
466
+ systemInfo: {
467
+ platform: string;
468
+ shell: string;
469
+ nodeVersion: string;
470
+ arch: string;
471
+ homedir: string;
472
+ cpus: number;
473
+ };
474
+ tokenCallers?: Record<string, Record<string, string[]>> | undefined;
475
+ userKnowledgeFiles?: Record<string, string> | undefined;
476
+ fileVersions?: {
477
+ path: string;
478
+ content: string;
479
+ }[][] | undefined;
401
480
  }>;
402
- changesSinceLastChat: z.ZodRecord<z.ZodString, z.ZodString>;
403
- shellConfigFiles: z.ZodRecord<z.ZodString, z.ZodString>;
404
- systemInfo: z.ZodObject<{
405
- platform: z.ZodString;
406
- shell: z.ZodString;
407
- nodeVersion: z.ZodString;
408
- arch: z.ZodString;
409
- homedir: z.ZodString;
410
- cpus: z.ZodNumber;
481
+ messageHistory: z.ZodArray<z.ZodIntersection<z.ZodType<import("ai").CoreMessage, z.ZodTypeDef, import("ai").CoreMessage>, z.ZodObject<{
482
+ timeToLive: z.ZodOptional<z.ZodUnion<[z.ZodLiteral<"agentStep">, z.ZodLiteral<"userPrompt">]>>;
411
483
  }, "strip", z.ZodTypeAny, {
412
- platform: string;
413
- shell: string;
414
- nodeVersion: string;
415
- arch: string;
416
- homedir: string;
417
- cpus: number;
484
+ timeToLive?: "agentStep" | "userPrompt" | undefined;
418
485
  }, {
419
- platform: string;
420
- shell: string;
421
- nodeVersion: string;
422
- arch: string;
423
- homedir: string;
424
- cpus: number;
486
+ timeToLive?: "agentStep" | "userPrompt" | undefined;
487
+ }>>, "many">;
488
+ consecutiveAssistantMessages: z.ZodOptional<z.ZodNumber>;
489
+ agentStepsRemaining: z.ZodOptional<z.ZodNumber>;
490
+ }, "strip", z.ZodTypeAny, {
491
+ agentContext: string;
492
+ fileContext: {
493
+ currentWorkingDirectory: string;
494
+ fileTree: import("./util/file").FileTreeNode[];
495
+ fileTokenScores: Record<string, Record<string, number>>;
496
+ knowledgeFiles: Record<string, string>;
497
+ gitChanges: {
498
+ status: string;
499
+ diff: string;
500
+ diffCached: string;
501
+ lastCommitMessages: string;
502
+ };
503
+ changesSinceLastChat: Record<string, string>;
504
+ shellConfigFiles: Record<string, string>;
505
+ systemInfo: {
506
+ platform: string;
507
+ shell: string;
508
+ nodeVersion: string;
509
+ arch: string;
510
+ homedir: string;
511
+ cpus: number;
512
+ };
513
+ tokenCallers?: Record<string, Record<string, string[]>> | undefined;
514
+ userKnowledgeFiles?: Record<string, string> | undefined;
515
+ fileVersions?: {
516
+ path: string;
517
+ content: string;
518
+ }[][] | undefined;
519
+ };
520
+ messageHistory: (import("ai").CoreMessage & {
521
+ timeToLive?: "agentStep" | "userPrompt" | undefined;
522
+ })[];
523
+ consecutiveAssistantMessages?: number | undefined;
524
+ agentStepsRemaining?: number | undefined;
525
+ }, {
526
+ agentContext: string;
527
+ fileContext: {
528
+ currentWorkingDirectory: string;
529
+ fileTree: import("./util/file").FileTreeNode[];
530
+ fileTokenScores: Record<string, Record<string, number>>;
531
+ knowledgeFiles: Record<string, string>;
532
+ gitChanges: {
533
+ status: string;
534
+ diff: string;
535
+ diffCached: string;
536
+ lastCommitMessages: string;
537
+ };
538
+ changesSinceLastChat: Record<string, string>;
539
+ shellConfigFiles: Record<string, string>;
540
+ systemInfo: {
541
+ platform: string;
542
+ shell: string;
543
+ nodeVersion: string;
544
+ arch: string;
545
+ homedir: string;
546
+ cpus: number;
547
+ };
548
+ tokenCallers?: Record<string, Record<string, string[]>> | undefined;
549
+ userKnowledgeFiles?: Record<string, string> | undefined;
550
+ fileVersions?: {
551
+ path: string;
552
+ content: string;
553
+ }[][] | undefined;
554
+ };
555
+ messageHistory: (import("ai").CoreMessage & {
556
+ timeToLive?: "agentStep" | "userPrompt" | undefined;
557
+ })[];
558
+ consecutiveAssistantMessages?: number | undefined;
559
+ agentStepsRemaining?: number | undefined;
560
+ }>;
561
+ toolResults: z.ZodArray<z.ZodObject<{
562
+ name: z.ZodString;
563
+ result: z.ZodString;
564
+ id: z.ZodString;
565
+ }, "strip", z.ZodTypeAny, {
566
+ name: string;
567
+ id: string;
568
+ result: string;
569
+ }, {
570
+ name: string;
571
+ id: string;
572
+ result: string;
573
+ }>, "many">;
574
+ fingerprintId: z.ZodString;
575
+ authToken: z.ZodOptional<z.ZodString>;
576
+ costMode: z.ZodDefault<z.ZodOptional<z.ZodEnum<["lite", "normal", "max", "experimental", "ask"]>>>;
577
+ model: z.ZodOptional<z.ZodString>;
578
+ cwd: z.ZodOptional<z.ZodString>;
579
+ repoName: z.ZodOptional<z.ZodString>;
580
+ }, "strip", z.ZodTypeAny, {
581
+ type: "manager-prompt";
582
+ promptId: string;
583
+ fingerprintId: string;
584
+ costMode: "lite" | "normal" | "max" | "experimental" | "ask";
585
+ agentState: {
586
+ agentContext: string;
587
+ fileContext: {
588
+ currentWorkingDirectory: string;
589
+ fileTree: import("./util/file").FileTreeNode[];
590
+ fileTokenScores: Record<string, Record<string, number>>;
591
+ knowledgeFiles: Record<string, string>;
592
+ gitChanges: {
593
+ status: string;
594
+ diff: string;
595
+ diffCached: string;
596
+ lastCommitMessages: string;
597
+ };
598
+ changesSinceLastChat: Record<string, string>;
599
+ shellConfigFiles: Record<string, string>;
600
+ systemInfo: {
601
+ platform: string;
602
+ shell: string;
603
+ nodeVersion: string;
604
+ arch: string;
605
+ homedir: string;
606
+ cpus: number;
607
+ };
608
+ tokenCallers?: Record<string, Record<string, string[]>> | undefined;
609
+ userKnowledgeFiles?: Record<string, string> | undefined;
610
+ fileVersions?: {
611
+ path: string;
612
+ content: string;
613
+ }[][] | undefined;
614
+ };
615
+ messageHistory: (import("ai").CoreMessage & {
616
+ timeToLive?: "agentStep" | "userPrompt" | undefined;
617
+ })[];
618
+ consecutiveAssistantMessages?: number | undefined;
619
+ agentStepsRemaining?: number | undefined;
620
+ };
621
+ toolResults: {
622
+ name: string;
623
+ id: string;
624
+ result: string;
625
+ }[];
626
+ prompt?: string | undefined;
627
+ authToken?: string | undefined;
628
+ model?: string | undefined;
629
+ cwd?: string | undefined;
630
+ repoName?: string | undefined;
631
+ }, {
632
+ type: "manager-prompt";
633
+ promptId: string;
634
+ fingerprintId: string;
635
+ agentState: {
636
+ agentContext: string;
637
+ fileContext: {
638
+ currentWorkingDirectory: string;
639
+ fileTree: import("./util/file").FileTreeNode[];
640
+ fileTokenScores: Record<string, Record<string, number>>;
641
+ knowledgeFiles: Record<string, string>;
642
+ gitChanges: {
643
+ status: string;
644
+ diff: string;
645
+ diffCached: string;
646
+ lastCommitMessages: string;
647
+ };
648
+ changesSinceLastChat: Record<string, string>;
649
+ shellConfigFiles: Record<string, string>;
650
+ systemInfo: {
651
+ platform: string;
652
+ shell: string;
653
+ nodeVersion: string;
654
+ arch: string;
655
+ homedir: string;
656
+ cpus: number;
657
+ };
658
+ tokenCallers?: Record<string, Record<string, string[]>> | undefined;
659
+ userKnowledgeFiles?: Record<string, string> | undefined;
660
+ fileVersions?: {
661
+ path: string;
662
+ content: string;
663
+ }[][] | undefined;
664
+ };
665
+ messageHistory: (import("ai").CoreMessage & {
666
+ timeToLive?: "agentStep" | "userPrompt" | undefined;
667
+ })[];
668
+ consecutiveAssistantMessages?: number | undefined;
669
+ agentStepsRemaining?: number | undefined;
670
+ };
671
+ toolResults: {
672
+ name: string;
673
+ id: string;
674
+ result: string;
675
+ }[];
676
+ prompt?: string | undefined;
677
+ authToken?: string | undefined;
678
+ costMode?: "lite" | "normal" | "max" | "experimental" | "ask" | undefined;
679
+ model?: string | undefined;
680
+ cwd?: string | undefined;
681
+ repoName?: string | undefined;
682
+ }>, z.ZodObject<{
683
+ type: z.ZodLiteral<"read-files-response">;
684
+ files: z.ZodRecord<z.ZodString, z.ZodUnion<[z.ZodString, z.ZodNull]>>;
685
+ requestId: z.ZodOptional<z.ZodString>;
686
+ }, "strip", z.ZodTypeAny, {
687
+ type: "read-files-response";
688
+ files: Record<string, string | null>;
689
+ requestId?: string | undefined;
690
+ }, {
691
+ type: "read-files-response";
692
+ files: Record<string, string | null>;
693
+ requestId?: string | undefined;
694
+ }>, z.ZodObject<{
695
+ type: z.ZodLiteral<"init">;
696
+ fingerprintId: z.ZodString;
697
+ authToken: z.ZodOptional<z.ZodString>;
698
+ fileContext: z.ZodObject<{
699
+ currentWorkingDirectory: z.ZodString;
700
+ fileTree: z.ZodArray<z.ZodType<import("./util/file").FileTreeNode, z.ZodTypeDef, import("./util/file").FileTreeNode>, "many">;
701
+ fileTokenScores: z.ZodRecord<z.ZodString, z.ZodRecord<z.ZodString, z.ZodNumber>>;
702
+ tokenCallers: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodRecord<z.ZodString, z.ZodArray<z.ZodString, "many">>>>;
703
+ knowledgeFiles: z.ZodRecord<z.ZodString, z.ZodString>;
704
+ userKnowledgeFiles: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
705
+ gitChanges: z.ZodObject<{
706
+ status: z.ZodString;
707
+ diff: z.ZodString;
708
+ diffCached: z.ZodString;
709
+ lastCommitMessages: z.ZodString;
710
+ }, "strip", z.ZodTypeAny, {
711
+ status: string;
712
+ diff: string;
713
+ diffCached: string;
714
+ lastCommitMessages: string;
715
+ }, {
716
+ status: string;
717
+ diff: string;
718
+ diffCached: string;
719
+ lastCommitMessages: string;
720
+ }>;
721
+ changesSinceLastChat: z.ZodRecord<z.ZodString, z.ZodString>;
722
+ shellConfigFiles: z.ZodRecord<z.ZodString, z.ZodString>;
723
+ systemInfo: z.ZodObject<{
724
+ platform: z.ZodString;
725
+ shell: z.ZodString;
726
+ nodeVersion: z.ZodString;
727
+ arch: z.ZodString;
728
+ homedir: z.ZodString;
729
+ cpus: z.ZodNumber;
730
+ }, "strip", z.ZodTypeAny, {
731
+ platform: string;
732
+ shell: string;
733
+ nodeVersion: string;
734
+ arch: string;
735
+ homedir: string;
736
+ cpus: number;
737
+ }, {
738
+ platform: string;
739
+ shell: string;
740
+ nodeVersion: string;
741
+ arch: string;
742
+ homedir: string;
743
+ cpus: number;
744
+ }>;
745
+ fileVersions: z.ZodOptional<z.ZodArray<z.ZodArray<z.ZodObject<{
746
+ path: z.ZodString;
747
+ content: z.ZodString;
748
+ }, "strip", z.ZodTypeAny, {
749
+ path: string;
750
+ content: string;
751
+ }, {
752
+ path: string;
753
+ content: string;
754
+ }>, "many">, "many">>;
755
+ }, "strip", z.ZodTypeAny, {
756
+ currentWorkingDirectory: string;
757
+ fileTree: import("./util/file").FileTreeNode[];
758
+ fileTokenScores: Record<string, Record<string, number>>;
759
+ knowledgeFiles: Record<string, string>;
760
+ gitChanges: {
761
+ status: string;
762
+ diff: string;
763
+ diffCached: string;
764
+ lastCommitMessages: string;
765
+ };
766
+ changesSinceLastChat: Record<string, string>;
767
+ shellConfigFiles: Record<string, string>;
768
+ systemInfo: {
769
+ platform: string;
770
+ shell: string;
771
+ nodeVersion: string;
772
+ arch: string;
773
+ homedir: string;
774
+ cpus: number;
775
+ };
776
+ tokenCallers?: Record<string, Record<string, string[]>> | undefined;
777
+ userKnowledgeFiles?: Record<string, string> | undefined;
778
+ fileVersions?: {
779
+ path: string;
780
+ content: string;
781
+ }[][] | undefined;
782
+ }, {
783
+ currentWorkingDirectory: string;
784
+ fileTree: import("./util/file").FileTreeNode[];
785
+ fileTokenScores: Record<string, Record<string, number>>;
786
+ knowledgeFiles: Record<string, string>;
787
+ gitChanges: {
788
+ status: string;
789
+ diff: string;
790
+ diffCached: string;
791
+ lastCommitMessages: string;
792
+ };
793
+ changesSinceLastChat: Record<string, string>;
794
+ shellConfigFiles: Record<string, string>;
795
+ systemInfo: {
796
+ platform: string;
797
+ shell: string;
798
+ nodeVersion: string;
799
+ arch: string;
800
+ homedir: string;
801
+ cpus: number;
802
+ };
803
+ tokenCallers?: Record<string, Record<string, string[]>> | undefined;
804
+ userKnowledgeFiles?: Record<string, string> | undefined;
805
+ fileVersions?: {
806
+ path: string;
807
+ content: string;
808
+ }[][] | undefined;
809
+ }>;
810
+ }, "strip", z.ZodTypeAny, {
811
+ type: "init";
812
+ fileContext: {
813
+ currentWorkingDirectory: string;
814
+ fileTree: import("./util/file").FileTreeNode[];
815
+ fileTokenScores: Record<string, Record<string, number>>;
816
+ knowledgeFiles: Record<string, string>;
817
+ gitChanges: {
818
+ status: string;
819
+ diff: string;
820
+ diffCached: string;
821
+ lastCommitMessages: string;
822
+ };
823
+ changesSinceLastChat: Record<string, string>;
824
+ shellConfigFiles: Record<string, string>;
825
+ systemInfo: {
826
+ platform: string;
827
+ shell: string;
828
+ nodeVersion: string;
829
+ arch: string;
830
+ homedir: string;
831
+ cpus: number;
832
+ };
833
+ tokenCallers?: Record<string, Record<string, string[]>> | undefined;
834
+ userKnowledgeFiles?: Record<string, string> | undefined;
835
+ fileVersions?: {
836
+ path: string;
837
+ content: string;
838
+ }[][] | undefined;
839
+ };
840
+ fingerprintId: string;
841
+ authToken?: string | undefined;
842
+ }, {
843
+ type: "init";
844
+ fileContext: {
845
+ currentWorkingDirectory: string;
846
+ fileTree: import("./util/file").FileTreeNode[];
847
+ fileTokenScores: Record<string, Record<string, number>>;
848
+ knowledgeFiles: Record<string, string>;
849
+ gitChanges: {
850
+ status: string;
851
+ diff: string;
852
+ diffCached: string;
853
+ lastCommitMessages: string;
854
+ };
855
+ changesSinceLastChat: Record<string, string>;
856
+ shellConfigFiles: Record<string, string>;
857
+ systemInfo: {
858
+ platform: string;
859
+ shell: string;
860
+ nodeVersion: string;
861
+ arch: string;
862
+ homedir: string;
863
+ cpus: number;
864
+ };
865
+ tokenCallers?: Record<string, Record<string, string[]>> | undefined;
866
+ userKnowledgeFiles?: Record<string, string> | undefined;
867
+ fileVersions?: {
868
+ path: string;
869
+ content: string;
870
+ }[][] | undefined;
871
+ };
872
+ fingerprintId: string;
873
+ authToken?: string | undefined;
874
+ }>, z.ZodObject<{
875
+ type: z.ZodLiteral<"generate-commit-message">;
876
+ fingerprintId: z.ZodString;
877
+ authToken: z.ZodOptional<z.ZodString>;
878
+ stagedChanges: z.ZodString;
879
+ }, "strip", z.ZodTypeAny, {
880
+ type: "generate-commit-message";
881
+ fingerprintId: string;
882
+ stagedChanges: string;
883
+ authToken?: string | undefined;
884
+ }, {
885
+ type: "generate-commit-message";
886
+ fingerprintId: string;
887
+ stagedChanges: string;
888
+ authToken?: string | undefined;
889
+ }>]>;
890
+ export type ClientAction = z.infer<typeof CLIENT_ACTION_SCHEMA>;
891
+ export declare const UsageReponseSchema: z.ZodObject<{
892
+ type: z.ZodLiteral<"usage-response">;
893
+ usage: z.ZodNumber;
894
+ remainingBalance: z.ZodNumber;
895
+ balanceBreakdown: z.ZodOptional<z.ZodRecord<z.ZodEnum<["free", ...("free" | "referral" | "purchase" | "admin")[]]>, z.ZodNumber>>;
896
+ next_quota_reset: z.ZodNullable<z.ZodDate>;
897
+ autoTopupAdded: z.ZodOptional<z.ZodNumber>;
898
+ }, "strip", z.ZodTypeAny, {
899
+ type: "usage-response";
900
+ usage: number;
901
+ remainingBalance: number;
902
+ next_quota_reset: Date | null;
903
+ balanceBreakdown?: Partial<Record<"free" | "referral" | "purchase" | "admin", number>> | undefined;
904
+ autoTopupAdded?: number | undefined;
905
+ }, {
906
+ type: "usage-response";
907
+ usage: number;
908
+ remainingBalance: number;
909
+ next_quota_reset: Date | null;
910
+ balanceBreakdown?: Partial<Record<"free" | "referral" | "purchase" | "admin", number>> | undefined;
911
+ autoTopupAdded?: number | undefined;
912
+ }>;
913
+ export type UsageResponse = z.infer<typeof UsageReponseSchema>;
914
+ export declare const InitResponseSchema: z.ZodObject<z.objectUtil.extendShape<{
915
+ type: z.ZodLiteral<"init-response">;
916
+ }, Omit<{
917
+ type: z.ZodLiteral<"usage-response">;
918
+ usage: z.ZodNumber;
919
+ remainingBalance: z.ZodNumber;
920
+ balanceBreakdown: z.ZodOptional<z.ZodRecord<z.ZodEnum<["free", ...("free" | "referral" | "purchase" | "admin")[]]>, z.ZodNumber>>;
921
+ next_quota_reset: z.ZodNullable<z.ZodDate>;
922
+ autoTopupAdded: z.ZodOptional<z.ZodNumber>;
923
+ }, "type">>, "strip", z.ZodTypeAny, {
924
+ type: "init-response";
925
+ usage: number;
926
+ remainingBalance: number;
927
+ next_quota_reset: Date | null;
928
+ balanceBreakdown?: Partial<Record<"free" | "referral" | "purchase" | "admin", number>> | undefined;
929
+ autoTopupAdded?: number | undefined;
930
+ }, {
931
+ type: "init-response";
932
+ usage: number;
933
+ remainingBalance: number;
934
+ next_quota_reset: Date | null;
935
+ balanceBreakdown?: Partial<Record<"free" | "referral" | "purchase" | "admin", number>> | undefined;
936
+ autoTopupAdded?: number | undefined;
937
+ }>;
938
+ export type InitResponse = z.infer<typeof InitResponseSchema>;
939
+ export declare const ResponseCompleteSchema: z.ZodObject<z.objectUtil.extendShape<{
940
+ type: z.ZodLiteral<"response-complete">;
941
+ userInputId: z.ZodString;
942
+ response: z.ZodString;
943
+ changes: z.ZodArray<z.ZodObject<{
944
+ type: z.ZodEnum<["patch", "file"]>;
945
+ path: z.ZodString;
946
+ content: z.ZodString;
947
+ }, "strip", z.ZodTypeAny, {
948
+ path: string;
949
+ type: "file" | "patch";
950
+ content: string;
951
+ }, {
952
+ path: string;
953
+ type: "file" | "patch";
954
+ content: string;
955
+ }>, "many">;
956
+ changesAlreadyApplied: z.ZodArray<z.ZodObject<{
957
+ type: z.ZodEnum<["patch", "file"]>;
958
+ path: z.ZodString;
959
+ content: z.ZodString;
960
+ }, "strip", z.ZodTypeAny, {
961
+ path: string;
962
+ type: "file" | "patch";
963
+ content: string;
964
+ }, {
965
+ path: string;
966
+ type: "file" | "patch";
967
+ content: string;
968
+ }>, "many">;
969
+ addedFileVersions: z.ZodArray<z.ZodObject<{
970
+ path: z.ZodString;
971
+ content: z.ZodString;
972
+ }, "strip", z.ZodTypeAny, {
973
+ path: string;
974
+ content: string;
975
+ }, {
976
+ path: string;
977
+ content: string;
978
+ }>, "many">;
979
+ resetFileVersions: z.ZodBoolean;
980
+ }, {
981
+ usage: z.ZodOptional<z.ZodNumber>;
982
+ remainingBalance: z.ZodOptional<z.ZodNumber>;
983
+ balanceBreakdown: z.ZodOptional<z.ZodOptional<z.ZodRecord<z.ZodEnum<["free", ...("free" | "referral" | "purchase" | "admin")[]]>, z.ZodNumber>>>;
984
+ next_quota_reset: z.ZodOptional<z.ZodNullable<z.ZodDate>>;
985
+ autoTopupAdded: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
986
+ }>, "strip", z.ZodTypeAny, {
987
+ type: "response-complete";
988
+ userInputId: string;
989
+ response: string;
990
+ changes: {
991
+ path: string;
992
+ type: "file" | "patch";
993
+ content: string;
994
+ }[];
995
+ changesAlreadyApplied: {
996
+ path: string;
997
+ type: "file" | "patch";
998
+ content: string;
999
+ }[];
1000
+ addedFileVersions: {
1001
+ path: string;
1002
+ content: string;
1003
+ }[];
1004
+ resetFileVersions: boolean;
1005
+ usage?: number | undefined;
1006
+ remainingBalance?: number | undefined;
1007
+ balanceBreakdown?: Partial<Record<"free" | "referral" | "purchase" | "admin", number>> | undefined;
1008
+ next_quota_reset?: Date | null | undefined;
1009
+ autoTopupAdded?: number | undefined;
1010
+ }, {
1011
+ type: "response-complete";
1012
+ userInputId: string;
1013
+ response: string;
1014
+ changes: {
1015
+ path: string;
1016
+ type: "file" | "patch";
1017
+ content: string;
1018
+ }[];
1019
+ changesAlreadyApplied: {
1020
+ path: string;
1021
+ type: "file" | "patch";
1022
+ content: string;
1023
+ }[];
1024
+ addedFileVersions: {
1025
+ path: string;
1026
+ content: string;
1027
+ }[];
1028
+ resetFileVersions: boolean;
1029
+ usage?: number | undefined;
1030
+ remainingBalance?: number | undefined;
1031
+ balanceBreakdown?: Partial<Record<"free" | "referral" | "purchase" | "admin", number>> | undefined;
1032
+ next_quota_reset?: Date | null | undefined;
1033
+ autoTopupAdded?: number | undefined;
1034
+ }>;
1035
+ export declare const MessageCostResponseSchema: z.ZodObject<{
1036
+ type: z.ZodLiteral<"message-cost-response">;
1037
+ promptId: z.ZodString;
1038
+ credits: z.ZodNumber;
1039
+ }, "strip", z.ZodTypeAny, {
1040
+ type: "message-cost-response";
1041
+ promptId: string;
1042
+ credits: number;
1043
+ }, {
1044
+ type: "message-cost-response";
1045
+ promptId: string;
1046
+ credits: number;
1047
+ }>;
1048
+ export type MessageCostResponse = z.infer<typeof MessageCostResponseSchema>;
1049
+ export declare const PromptResponseSchema: z.ZodObject<{
1050
+ type: z.ZodLiteral<"prompt-response">;
1051
+ promptId: z.ZodString;
1052
+ agentState: z.ZodObject<{
1053
+ agentContext: z.ZodString;
1054
+ fileContext: z.ZodObject<{
1055
+ currentWorkingDirectory: z.ZodString;
1056
+ fileTree: z.ZodArray<z.ZodType<import("./util/file").FileTreeNode, z.ZodTypeDef, import("./util/file").FileTreeNode>, "many">;
1057
+ fileTokenScores: z.ZodRecord<z.ZodString, z.ZodRecord<z.ZodString, z.ZodNumber>>;
1058
+ tokenCallers: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodRecord<z.ZodString, z.ZodArray<z.ZodString, "many">>>>;
1059
+ knowledgeFiles: z.ZodRecord<z.ZodString, z.ZodString>;
1060
+ userKnowledgeFiles: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
1061
+ gitChanges: z.ZodObject<{
1062
+ status: z.ZodString;
1063
+ diff: z.ZodString;
1064
+ diffCached: z.ZodString;
1065
+ lastCommitMessages: z.ZodString;
1066
+ }, "strip", z.ZodTypeAny, {
1067
+ status: string;
1068
+ diff: string;
1069
+ diffCached: string;
1070
+ lastCommitMessages: string;
1071
+ }, {
1072
+ status: string;
1073
+ diff: string;
1074
+ diffCached: string;
1075
+ lastCommitMessages: string;
1076
+ }>;
1077
+ changesSinceLastChat: z.ZodRecord<z.ZodString, z.ZodString>;
1078
+ shellConfigFiles: z.ZodRecord<z.ZodString, z.ZodString>;
1079
+ systemInfo: z.ZodObject<{
1080
+ platform: z.ZodString;
1081
+ shell: z.ZodString;
1082
+ nodeVersion: z.ZodString;
1083
+ arch: z.ZodString;
1084
+ homedir: z.ZodString;
1085
+ cpus: z.ZodNumber;
1086
+ }, "strip", z.ZodTypeAny, {
1087
+ platform: string;
1088
+ shell: string;
1089
+ nodeVersion: string;
1090
+ arch: string;
1091
+ homedir: string;
1092
+ cpus: number;
1093
+ }, {
1094
+ platform: string;
1095
+ shell: string;
1096
+ nodeVersion: string;
1097
+ arch: string;
1098
+ homedir: string;
1099
+ cpus: number;
1100
+ }>;
1101
+ fileVersions: z.ZodOptional<z.ZodArray<z.ZodArray<z.ZodObject<{
1102
+ path: z.ZodString;
1103
+ content: z.ZodString;
1104
+ }, "strip", z.ZodTypeAny, {
1105
+ path: string;
1106
+ content: string;
1107
+ }, {
1108
+ path: string;
1109
+ content: string;
1110
+ }>, "many">, "many">>;
1111
+ }, "strip", z.ZodTypeAny, {
1112
+ currentWorkingDirectory: string;
1113
+ fileTree: import("./util/file").FileTreeNode[];
1114
+ fileTokenScores: Record<string, Record<string, number>>;
1115
+ knowledgeFiles: Record<string, string>;
1116
+ gitChanges: {
1117
+ status: string;
1118
+ diff: string;
1119
+ diffCached: string;
1120
+ lastCommitMessages: string;
1121
+ };
1122
+ changesSinceLastChat: Record<string, string>;
1123
+ shellConfigFiles: Record<string, string>;
1124
+ systemInfo: {
1125
+ platform: string;
1126
+ shell: string;
1127
+ nodeVersion: string;
1128
+ arch: string;
1129
+ homedir: string;
1130
+ cpus: number;
1131
+ };
1132
+ tokenCallers?: Record<string, Record<string, string[]>> | undefined;
1133
+ userKnowledgeFiles?: Record<string, string> | undefined;
1134
+ fileVersions?: {
1135
+ path: string;
1136
+ content: string;
1137
+ }[][] | undefined;
1138
+ }, {
1139
+ currentWorkingDirectory: string;
1140
+ fileTree: import("./util/file").FileTreeNode[];
1141
+ fileTokenScores: Record<string, Record<string, number>>;
1142
+ knowledgeFiles: Record<string, string>;
1143
+ gitChanges: {
1144
+ status: string;
1145
+ diff: string;
1146
+ diffCached: string;
1147
+ lastCommitMessages: string;
1148
+ };
1149
+ changesSinceLastChat: Record<string, string>;
1150
+ shellConfigFiles: Record<string, string>;
1151
+ systemInfo: {
1152
+ platform: string;
1153
+ shell: string;
1154
+ nodeVersion: string;
1155
+ arch: string;
1156
+ homedir: string;
1157
+ cpus: number;
1158
+ };
1159
+ tokenCallers?: Record<string, Record<string, string[]>> | undefined;
1160
+ userKnowledgeFiles?: Record<string, string> | undefined;
1161
+ fileVersions?: {
1162
+ path: string;
1163
+ content: string;
1164
+ }[][] | undefined;
1165
+ }>;
1166
+ messageHistory: z.ZodArray<z.ZodIntersection<z.ZodType<import("ai").CoreMessage, z.ZodTypeDef, import("ai").CoreMessage>, z.ZodObject<{
1167
+ timeToLive: z.ZodOptional<z.ZodUnion<[z.ZodLiteral<"agentStep">, z.ZodLiteral<"userPrompt">]>>;
1168
+ }, "strip", z.ZodTypeAny, {
1169
+ timeToLive?: "agentStep" | "userPrompt" | undefined;
1170
+ }, {
1171
+ timeToLive?: "agentStep" | "userPrompt" | undefined;
1172
+ }>>, "many">;
1173
+ consecutiveAssistantMessages: z.ZodOptional<z.ZodNumber>;
1174
+ agentStepsRemaining: z.ZodOptional<z.ZodNumber>;
1175
+ }, "strip", z.ZodTypeAny, {
1176
+ agentContext: string;
1177
+ fileContext: {
1178
+ currentWorkingDirectory: string;
1179
+ fileTree: import("./util/file").FileTreeNode[];
1180
+ fileTokenScores: Record<string, Record<string, number>>;
1181
+ knowledgeFiles: Record<string, string>;
1182
+ gitChanges: {
1183
+ status: string;
1184
+ diff: string;
1185
+ diffCached: string;
1186
+ lastCommitMessages: string;
1187
+ };
1188
+ changesSinceLastChat: Record<string, string>;
1189
+ shellConfigFiles: Record<string, string>;
1190
+ systemInfo: {
1191
+ platform: string;
1192
+ shell: string;
1193
+ nodeVersion: string;
1194
+ arch: string;
1195
+ homedir: string;
1196
+ cpus: number;
1197
+ };
1198
+ tokenCallers?: Record<string, Record<string, string[]>> | undefined;
1199
+ userKnowledgeFiles?: Record<string, string> | undefined;
1200
+ fileVersions?: {
1201
+ path: string;
1202
+ content: string;
1203
+ }[][] | undefined;
1204
+ };
1205
+ messageHistory: (import("ai").CoreMessage & {
1206
+ timeToLive?: "agentStep" | "userPrompt" | undefined;
1207
+ })[];
1208
+ consecutiveAssistantMessages?: number | undefined;
1209
+ agentStepsRemaining?: number | undefined;
1210
+ }, {
1211
+ agentContext: string;
1212
+ fileContext: {
1213
+ currentWorkingDirectory: string;
1214
+ fileTree: import("./util/file").FileTreeNode[];
1215
+ fileTokenScores: Record<string, Record<string, number>>;
1216
+ knowledgeFiles: Record<string, string>;
1217
+ gitChanges: {
1218
+ status: string;
1219
+ diff: string;
1220
+ diffCached: string;
1221
+ lastCommitMessages: string;
1222
+ };
1223
+ changesSinceLastChat: Record<string, string>;
1224
+ shellConfigFiles: Record<string, string>;
1225
+ systemInfo: {
1226
+ platform: string;
1227
+ shell: string;
1228
+ nodeVersion: string;
1229
+ arch: string;
1230
+ homedir: string;
1231
+ cpus: number;
1232
+ };
1233
+ tokenCallers?: Record<string, Record<string, string[]>> | undefined;
1234
+ userKnowledgeFiles?: Record<string, string> | undefined;
1235
+ fileVersions?: {
1236
+ path: string;
1237
+ content: string;
1238
+ }[][] | undefined;
1239
+ };
1240
+ messageHistory: (import("ai").CoreMessage & {
1241
+ timeToLive?: "agentStep" | "userPrompt" | undefined;
1242
+ })[];
1243
+ consecutiveAssistantMessages?: number | undefined;
1244
+ agentStepsRemaining?: number | undefined;
1245
+ }>;
1246
+ toolCalls: z.ZodArray<z.ZodObject<{
1247
+ name: z.ZodString;
1248
+ parameters: z.ZodRecord<z.ZodString, z.ZodString>;
1249
+ id: z.ZodString;
1250
+ }, "strip", z.ZodTypeAny, {
1251
+ name: string;
1252
+ id: string;
1253
+ parameters: Record<string, string>;
1254
+ }, {
1255
+ name: string;
1256
+ id: string;
1257
+ parameters: Record<string, string>;
1258
+ }>, "many">;
1259
+ toolResults: z.ZodArray<z.ZodObject<{
1260
+ name: z.ZodString;
1261
+ result: z.ZodString;
1262
+ id: z.ZodString;
1263
+ }, "strip", z.ZodTypeAny, {
1264
+ name: string;
1265
+ id: string;
1266
+ result: string;
1267
+ }, {
1268
+ name: string;
1269
+ id: string;
1270
+ result: string;
1271
+ }>, "many">;
1272
+ }, "strip", z.ZodTypeAny, {
1273
+ type: "prompt-response";
1274
+ promptId: string;
1275
+ agentState: {
1276
+ agentContext: string;
1277
+ fileContext: {
1278
+ currentWorkingDirectory: string;
1279
+ fileTree: import("./util/file").FileTreeNode[];
1280
+ fileTokenScores: Record<string, Record<string, number>>;
1281
+ knowledgeFiles: Record<string, string>;
1282
+ gitChanges: {
1283
+ status: string;
1284
+ diff: string;
1285
+ diffCached: string;
1286
+ lastCommitMessages: string;
1287
+ };
1288
+ changesSinceLastChat: Record<string, string>;
1289
+ shellConfigFiles: Record<string, string>;
1290
+ systemInfo: {
1291
+ platform: string;
1292
+ shell: string;
1293
+ nodeVersion: string;
1294
+ arch: string;
1295
+ homedir: string;
1296
+ cpus: number;
1297
+ };
1298
+ tokenCallers?: Record<string, Record<string, string[]>> | undefined;
1299
+ userKnowledgeFiles?: Record<string, string> | undefined;
1300
+ fileVersions?: {
1301
+ path: string;
1302
+ content: string;
1303
+ }[][] | undefined;
1304
+ };
1305
+ messageHistory: (import("ai").CoreMessage & {
1306
+ timeToLive?: "agentStep" | "userPrompt" | undefined;
1307
+ })[];
1308
+ consecutiveAssistantMessages?: number | undefined;
1309
+ agentStepsRemaining?: number | undefined;
1310
+ };
1311
+ toolResults: {
1312
+ name: string;
1313
+ id: string;
1314
+ result: string;
1315
+ }[];
1316
+ toolCalls: {
1317
+ name: string;
1318
+ id: string;
1319
+ parameters: Record<string, string>;
1320
+ }[];
1321
+ }, {
1322
+ type: "prompt-response";
1323
+ promptId: string;
1324
+ agentState: {
1325
+ agentContext: string;
1326
+ fileContext: {
1327
+ currentWorkingDirectory: string;
1328
+ fileTree: import("./util/file").FileTreeNode[];
1329
+ fileTokenScores: Record<string, Record<string, number>>;
1330
+ knowledgeFiles: Record<string, string>;
1331
+ gitChanges: {
1332
+ status: string;
1333
+ diff: string;
1334
+ diffCached: string;
1335
+ lastCommitMessages: string;
1336
+ };
1337
+ changesSinceLastChat: Record<string, string>;
1338
+ shellConfigFiles: Record<string, string>;
1339
+ systemInfo: {
1340
+ platform: string;
1341
+ shell: string;
1342
+ nodeVersion: string;
1343
+ arch: string;
1344
+ homedir: string;
1345
+ cpus: number;
1346
+ };
1347
+ tokenCallers?: Record<string, Record<string, string[]>> | undefined;
1348
+ userKnowledgeFiles?: Record<string, string> | undefined;
1349
+ fileVersions?: {
1350
+ path: string;
1351
+ content: string;
1352
+ }[][] | undefined;
1353
+ };
1354
+ messageHistory: (import("ai").CoreMessage & {
1355
+ timeToLive?: "agentStep" | "userPrompt" | undefined;
1356
+ })[];
1357
+ consecutiveAssistantMessages?: number | undefined;
1358
+ agentStepsRemaining?: number | undefined;
1359
+ };
1360
+ toolResults: {
1361
+ name: string;
1362
+ id: string;
1363
+ result: string;
1364
+ }[];
1365
+ toolCalls: {
1366
+ name: string;
1367
+ id: string;
1368
+ parameters: Record<string, string>;
1369
+ }[];
1370
+ }>;
1371
+ export type PromptResponse = z.infer<typeof PromptResponseSchema>;
1372
+ export declare const ManagerPromptResponseSchema: z.ZodObject<{
1373
+ type: z.ZodLiteral<"manager-prompt-response">;
1374
+ promptId: z.ZodString;
1375
+ agentState: z.ZodObject<{
1376
+ agentContext: z.ZodString;
1377
+ fileContext: z.ZodObject<{
1378
+ currentWorkingDirectory: z.ZodString;
1379
+ fileTree: z.ZodArray<z.ZodType<import("./util/file").FileTreeNode, z.ZodTypeDef, import("./util/file").FileTreeNode>, "many">;
1380
+ fileTokenScores: z.ZodRecord<z.ZodString, z.ZodRecord<z.ZodString, z.ZodNumber>>;
1381
+ tokenCallers: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodRecord<z.ZodString, z.ZodArray<z.ZodString, "many">>>>;
1382
+ knowledgeFiles: z.ZodRecord<z.ZodString, z.ZodString>;
1383
+ userKnowledgeFiles: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
1384
+ gitChanges: z.ZodObject<{
1385
+ status: z.ZodString;
1386
+ diff: z.ZodString;
1387
+ diffCached: z.ZodString;
1388
+ lastCommitMessages: z.ZodString;
1389
+ }, "strip", z.ZodTypeAny, {
1390
+ status: string;
1391
+ diff: string;
1392
+ diffCached: string;
1393
+ lastCommitMessages: string;
1394
+ }, {
1395
+ status: string;
1396
+ diff: string;
1397
+ diffCached: string;
1398
+ lastCommitMessages: string;
1399
+ }>;
1400
+ changesSinceLastChat: z.ZodRecord<z.ZodString, z.ZodString>;
1401
+ shellConfigFiles: z.ZodRecord<z.ZodString, z.ZodString>;
1402
+ systemInfo: z.ZodObject<{
1403
+ platform: z.ZodString;
1404
+ shell: z.ZodString;
1405
+ nodeVersion: z.ZodString;
1406
+ arch: z.ZodString;
1407
+ homedir: z.ZodString;
1408
+ cpus: z.ZodNumber;
1409
+ }, "strip", z.ZodTypeAny, {
1410
+ platform: string;
1411
+ shell: string;
1412
+ nodeVersion: string;
1413
+ arch: string;
1414
+ homedir: string;
1415
+ cpus: number;
1416
+ }, {
1417
+ platform: string;
1418
+ shell: string;
1419
+ nodeVersion: string;
1420
+ arch: string;
1421
+ homedir: string;
1422
+ cpus: number;
1423
+ }>;
1424
+ fileVersions: z.ZodOptional<z.ZodArray<z.ZodArray<z.ZodObject<{
1425
+ path: z.ZodString;
1426
+ content: z.ZodString;
1427
+ }, "strip", z.ZodTypeAny, {
1428
+ path: string;
1429
+ content: string;
1430
+ }, {
1431
+ path: string;
1432
+ content: string;
1433
+ }>, "many">, "many">>;
1434
+ }, "strip", z.ZodTypeAny, {
1435
+ currentWorkingDirectory: string;
1436
+ fileTree: import("./util/file").FileTreeNode[];
1437
+ fileTokenScores: Record<string, Record<string, number>>;
1438
+ knowledgeFiles: Record<string, string>;
1439
+ gitChanges: {
1440
+ status: string;
1441
+ diff: string;
1442
+ diffCached: string;
1443
+ lastCommitMessages: string;
1444
+ };
1445
+ changesSinceLastChat: Record<string, string>;
1446
+ shellConfigFiles: Record<string, string>;
1447
+ systemInfo: {
1448
+ platform: string;
1449
+ shell: string;
1450
+ nodeVersion: string;
1451
+ arch: string;
1452
+ homedir: string;
1453
+ cpus: number;
1454
+ };
1455
+ tokenCallers?: Record<string, Record<string, string[]>> | undefined;
1456
+ userKnowledgeFiles?: Record<string, string> | undefined;
1457
+ fileVersions?: {
1458
+ path: string;
1459
+ content: string;
1460
+ }[][] | undefined;
1461
+ }, {
1462
+ currentWorkingDirectory: string;
1463
+ fileTree: import("./util/file").FileTreeNode[];
1464
+ fileTokenScores: Record<string, Record<string, number>>;
1465
+ knowledgeFiles: Record<string, string>;
1466
+ gitChanges: {
1467
+ status: string;
1468
+ diff: string;
1469
+ diffCached: string;
1470
+ lastCommitMessages: string;
1471
+ };
1472
+ changesSinceLastChat: Record<string, string>;
1473
+ shellConfigFiles: Record<string, string>;
1474
+ systemInfo: {
1475
+ platform: string;
1476
+ shell: string;
1477
+ nodeVersion: string;
1478
+ arch: string;
1479
+ homedir: string;
1480
+ cpus: number;
1481
+ };
1482
+ tokenCallers?: Record<string, Record<string, string[]>> | undefined;
1483
+ userKnowledgeFiles?: Record<string, string> | undefined;
1484
+ fileVersions?: {
1485
+ path: string;
1486
+ content: string;
1487
+ }[][] | undefined;
425
1488
  }>;
426
- fileVersions: z.ZodOptional<z.ZodArray<z.ZodArray<z.ZodObject<{
427
- path: z.ZodString;
428
- content: z.ZodString;
1489
+ messageHistory: z.ZodArray<z.ZodIntersection<z.ZodType<import("ai").CoreMessage, z.ZodTypeDef, import("ai").CoreMessage>, z.ZodObject<{
1490
+ timeToLive: z.ZodOptional<z.ZodUnion<[z.ZodLiteral<"agentStep">, z.ZodLiteral<"userPrompt">]>>;
429
1491
  }, "strip", z.ZodTypeAny, {
430
- path: string;
431
- content: string;
1492
+ timeToLive?: "agentStep" | "userPrompt" | undefined;
432
1493
  }, {
433
- path: string;
434
- content: string;
435
- }>, "many">, "many">>;
1494
+ timeToLive?: "agentStep" | "userPrompt" | undefined;
1495
+ }>>, "many">;
1496
+ consecutiveAssistantMessages: z.ZodOptional<z.ZodNumber>;
1497
+ agentStepsRemaining: z.ZodOptional<z.ZodNumber>;
436
1498
  }, "strip", z.ZodTypeAny, {
437
- currentWorkingDirectory: string;
438
- fileTree: import("./util/file").FileTreeNode[];
439
- fileTokenScores: Record<string, Record<string, number>>;
440
- knowledgeFiles: Record<string, string>;
441
- gitChanges: {
442
- status: string;
443
- diff: string;
444
- diffCached: string;
445
- lastCommitMessages: string;
446
- };
447
- changesSinceLastChat: Record<string, string>;
448
- shellConfigFiles: Record<string, string>;
449
- systemInfo: {
450
- platform: string;
451
- shell: string;
452
- nodeVersion: string;
453
- arch: string;
454
- homedir: string;
455
- cpus: number;
1499
+ agentContext: string;
1500
+ fileContext: {
1501
+ currentWorkingDirectory: string;
1502
+ fileTree: import("./util/file").FileTreeNode[];
1503
+ fileTokenScores: Record<string, Record<string, number>>;
1504
+ knowledgeFiles: Record<string, string>;
1505
+ gitChanges: {
1506
+ status: string;
1507
+ diff: string;
1508
+ diffCached: string;
1509
+ lastCommitMessages: string;
1510
+ };
1511
+ changesSinceLastChat: Record<string, string>;
1512
+ shellConfigFiles: Record<string, string>;
1513
+ systemInfo: {
1514
+ platform: string;
1515
+ shell: string;
1516
+ nodeVersion: string;
1517
+ arch: string;
1518
+ homedir: string;
1519
+ cpus: number;
1520
+ };
1521
+ tokenCallers?: Record<string, Record<string, string[]>> | undefined;
1522
+ userKnowledgeFiles?: Record<string, string> | undefined;
1523
+ fileVersions?: {
1524
+ path: string;
1525
+ content: string;
1526
+ }[][] | undefined;
456
1527
  };
457
- tokenCallers?: Record<string, Record<string, string[]>> | undefined;
458
- userKnowledgeFiles?: Record<string, string> | undefined;
459
- fileVersions?: {
460
- path: string;
461
- content: string;
462
- }[][] | undefined;
1528
+ messageHistory: (import("ai").CoreMessage & {
1529
+ timeToLive?: "agentStep" | "userPrompt" | undefined;
1530
+ })[];
1531
+ consecutiveAssistantMessages?: number | undefined;
1532
+ agentStepsRemaining?: number | undefined;
463
1533
  }, {
464
- currentWorkingDirectory: string;
465
- fileTree: import("./util/file").FileTreeNode[];
466
- fileTokenScores: Record<string, Record<string, number>>;
467
- knowledgeFiles: Record<string, string>;
468
- gitChanges: {
469
- status: string;
470
- diff: string;
471
- diffCached: string;
472
- lastCommitMessages: string;
473
- };
474
- changesSinceLastChat: Record<string, string>;
475
- shellConfigFiles: Record<string, string>;
476
- systemInfo: {
477
- platform: string;
478
- shell: string;
479
- nodeVersion: string;
480
- arch: string;
481
- homedir: string;
482
- cpus: number;
1534
+ agentContext: string;
1535
+ fileContext: {
1536
+ currentWorkingDirectory: string;
1537
+ fileTree: import("./util/file").FileTreeNode[];
1538
+ fileTokenScores: Record<string, Record<string, number>>;
1539
+ knowledgeFiles: Record<string, string>;
1540
+ gitChanges: {
1541
+ status: string;
1542
+ diff: string;
1543
+ diffCached: string;
1544
+ lastCommitMessages: string;
1545
+ };
1546
+ changesSinceLastChat: Record<string, string>;
1547
+ shellConfigFiles: Record<string, string>;
1548
+ systemInfo: {
1549
+ platform: string;
1550
+ shell: string;
1551
+ nodeVersion: string;
1552
+ arch: string;
1553
+ homedir: string;
1554
+ cpus: number;
1555
+ };
1556
+ tokenCallers?: Record<string, Record<string, string[]>> | undefined;
1557
+ userKnowledgeFiles?: Record<string, string> | undefined;
1558
+ fileVersions?: {
1559
+ path: string;
1560
+ content: string;
1561
+ }[][] | undefined;
483
1562
  };
484
- tokenCallers?: Record<string, Record<string, string[]>> | undefined;
485
- userKnowledgeFiles?: Record<string, string> | undefined;
486
- fileVersions?: {
487
- path: string;
488
- content: string;
489
- }[][] | undefined;
1563
+ messageHistory: (import("ai").CoreMessage & {
1564
+ timeToLive?: "agentStep" | "userPrompt" | undefined;
1565
+ })[];
1566
+ consecutiveAssistantMessages?: number | undefined;
1567
+ agentStepsRemaining?: number | undefined;
490
1568
  }>;
1569
+ toolCalls: z.ZodArray<z.ZodObject<{
1570
+ name: z.ZodString;
1571
+ parameters: z.ZodRecord<z.ZodString, z.ZodString>;
1572
+ id: z.ZodString;
1573
+ }, "strip", z.ZodTypeAny, {
1574
+ name: string;
1575
+ id: string;
1576
+ parameters: Record<string, string>;
1577
+ }, {
1578
+ name: string;
1579
+ id: string;
1580
+ parameters: Record<string, string>;
1581
+ }>, "many">;
1582
+ toolResults: z.ZodArray<z.ZodObject<{
1583
+ name: z.ZodString;
1584
+ result: z.ZodString;
1585
+ id: z.ZodString;
1586
+ }, "strip", z.ZodTypeAny, {
1587
+ name: string;
1588
+ id: string;
1589
+ result: string;
1590
+ }, {
1591
+ name: string;
1592
+ id: string;
1593
+ result: string;
1594
+ }>, "many">;
491
1595
  }, "strip", z.ZodTypeAny, {
492
- type: "init";
493
- fileContext: {
494
- currentWorkingDirectory: string;
495
- fileTree: import("./util/file").FileTreeNode[];
496
- fileTokenScores: Record<string, Record<string, number>>;
497
- knowledgeFiles: Record<string, string>;
498
- gitChanges: {
499
- status: string;
500
- diff: string;
501
- diffCached: string;
502
- lastCommitMessages: string;
503
- };
504
- changesSinceLastChat: Record<string, string>;
505
- shellConfigFiles: Record<string, string>;
506
- systemInfo: {
507
- platform: string;
508
- shell: string;
509
- nodeVersion: string;
510
- arch: string;
511
- homedir: string;
512
- cpus: number;
1596
+ type: "manager-prompt-response";
1597
+ promptId: string;
1598
+ agentState: {
1599
+ agentContext: string;
1600
+ fileContext: {
1601
+ currentWorkingDirectory: string;
1602
+ fileTree: import("./util/file").FileTreeNode[];
1603
+ fileTokenScores: Record<string, Record<string, number>>;
1604
+ knowledgeFiles: Record<string, string>;
1605
+ gitChanges: {
1606
+ status: string;
1607
+ diff: string;
1608
+ diffCached: string;
1609
+ lastCommitMessages: string;
1610
+ };
1611
+ changesSinceLastChat: Record<string, string>;
1612
+ shellConfigFiles: Record<string, string>;
1613
+ systemInfo: {
1614
+ platform: string;
1615
+ shell: string;
1616
+ nodeVersion: string;
1617
+ arch: string;
1618
+ homedir: string;
1619
+ cpus: number;
1620
+ };
1621
+ tokenCallers?: Record<string, Record<string, string[]>> | undefined;
1622
+ userKnowledgeFiles?: Record<string, string> | undefined;
1623
+ fileVersions?: {
1624
+ path: string;
1625
+ content: string;
1626
+ }[][] | undefined;
513
1627
  };
514
- tokenCallers?: Record<string, Record<string, string[]>> | undefined;
515
- userKnowledgeFiles?: Record<string, string> | undefined;
516
- fileVersions?: {
517
- path: string;
518
- content: string;
519
- }[][] | undefined;
1628
+ messageHistory: (import("ai").CoreMessage & {
1629
+ timeToLive?: "agentStep" | "userPrompt" | undefined;
1630
+ })[];
1631
+ consecutiveAssistantMessages?: number | undefined;
1632
+ agentStepsRemaining?: number | undefined;
520
1633
  };
521
- fingerprintId: string;
522
- authToken?: string | undefined;
1634
+ toolResults: {
1635
+ name: string;
1636
+ id: string;
1637
+ result: string;
1638
+ }[];
1639
+ toolCalls: {
1640
+ name: string;
1641
+ id: string;
1642
+ parameters: Record<string, string>;
1643
+ }[];
523
1644
  }, {
524
- type: "init";
525
- fileContext: {
526
- currentWorkingDirectory: string;
527
- fileTree: import("./util/file").FileTreeNode[];
528
- fileTokenScores: Record<string, Record<string, number>>;
529
- knowledgeFiles: Record<string, string>;
530
- gitChanges: {
531
- status: string;
532
- diff: string;
533
- diffCached: string;
534
- lastCommitMessages: string;
535
- };
536
- changesSinceLastChat: Record<string, string>;
537
- shellConfigFiles: Record<string, string>;
538
- systemInfo: {
539
- platform: string;
540
- shell: string;
541
- nodeVersion: string;
542
- arch: string;
543
- homedir: string;
544
- cpus: number;
1645
+ type: "manager-prompt-response";
1646
+ promptId: string;
1647
+ agentState: {
1648
+ agentContext: string;
1649
+ fileContext: {
1650
+ currentWorkingDirectory: string;
1651
+ fileTree: import("./util/file").FileTreeNode[];
1652
+ fileTokenScores: Record<string, Record<string, number>>;
1653
+ knowledgeFiles: Record<string, string>;
1654
+ gitChanges: {
1655
+ status: string;
1656
+ diff: string;
1657
+ diffCached: string;
1658
+ lastCommitMessages: string;
1659
+ };
1660
+ changesSinceLastChat: Record<string, string>;
1661
+ shellConfigFiles: Record<string, string>;
1662
+ systemInfo: {
1663
+ platform: string;
1664
+ shell: string;
1665
+ nodeVersion: string;
1666
+ arch: string;
1667
+ homedir: string;
1668
+ cpus: number;
1669
+ };
1670
+ tokenCallers?: Record<string, Record<string, string[]>> | undefined;
1671
+ userKnowledgeFiles?: Record<string, string> | undefined;
1672
+ fileVersions?: {
1673
+ path: string;
1674
+ content: string;
1675
+ }[][] | undefined;
545
1676
  };
546
- tokenCallers?: Record<string, Record<string, string[]>> | undefined;
547
- userKnowledgeFiles?: Record<string, string> | undefined;
548
- fileVersions?: {
549
- path: string;
550
- content: string;
551
- }[][] | undefined;
1677
+ messageHistory: (import("ai").CoreMessage & {
1678
+ timeToLive?: "agentStep" | "userPrompt" | undefined;
1679
+ })[];
1680
+ consecutiveAssistantMessages?: number | undefined;
1681
+ agentStepsRemaining?: number | undefined;
552
1682
  };
553
- fingerprintId: string;
554
- authToken?: string | undefined;
555
- }>, z.ZodObject<{
556
- type: z.ZodLiteral<"generate-commit-message">;
557
- fingerprintId: z.ZodString;
558
- authToken: z.ZodOptional<z.ZodString>;
559
- stagedChanges: z.ZodString;
560
- }, "strip", z.ZodTypeAny, {
561
- type: "generate-commit-message";
562
- fingerprintId: string;
563
- stagedChanges: string;
564
- authToken?: string | undefined;
565
- }, {
566
- type: "generate-commit-message";
567
- fingerprintId: string;
568
- stagedChanges: string;
569
- authToken?: string | undefined;
570
- }>]>;
571
- export type ClientAction = z.infer<typeof CLIENT_ACTION_SCHEMA>;
572
- export declare const UsageReponseSchema: z.ZodObject<{
573
- type: z.ZodLiteral<"usage-response">;
574
- usage: z.ZodNumber;
575
- remainingBalance: z.ZodNumber;
576
- balanceBreakdown: z.ZodOptional<z.ZodRecord<z.ZodEnum<["free", ...("free" | "referral" | "purchase" | "admin")[]]>, z.ZodNumber>>;
577
- next_quota_reset: z.ZodNullable<z.ZodDate>;
578
- autoTopupAdded: z.ZodOptional<z.ZodNumber>;
579
- }, "strip", z.ZodTypeAny, {
580
- type: "usage-response";
581
- usage: number;
582
- remainingBalance: number;
583
- next_quota_reset: Date | null;
584
- balanceBreakdown?: Partial<Record<"free" | "referral" | "purchase" | "admin", number>> | undefined;
585
- autoTopupAdded?: number | undefined;
586
- }, {
587
- type: "usage-response";
588
- usage: number;
589
- remainingBalance: number;
590
- next_quota_reset: Date | null;
591
- balanceBreakdown?: Partial<Record<"free" | "referral" | "purchase" | "admin", number>> | undefined;
592
- autoTopupAdded?: number | undefined;
1683
+ toolResults: {
1684
+ name: string;
1685
+ id: string;
1686
+ result: string;
1687
+ }[];
1688
+ toolCalls: {
1689
+ name: string;
1690
+ id: string;
1691
+ parameters: Record<string, string>;
1692
+ }[];
593
1693
  }>;
594
- export type UsageResponse = z.infer<typeof UsageReponseSchema>;
595
- export declare const InitResponseSchema: z.ZodObject<z.objectUtil.extendShape<{
596
- type: z.ZodLiteral<"init-response">;
597
- }, Omit<{
598
- type: z.ZodLiteral<"usage-response">;
599
- usage: z.ZodNumber;
600
- remainingBalance: z.ZodNumber;
601
- balanceBreakdown: z.ZodOptional<z.ZodRecord<z.ZodEnum<["free", ...("free" | "referral" | "purchase" | "admin")[]]>, z.ZodNumber>>;
602
- next_quota_reset: z.ZodNullable<z.ZodDate>;
603
- autoTopupAdded: z.ZodOptional<z.ZodNumber>;
604
- }, "type">>, "strip", z.ZodTypeAny, {
605
- type: "init-response";
606
- usage: number;
607
- remainingBalance: number;
608
- next_quota_reset: Date | null;
609
- balanceBreakdown?: Partial<Record<"free" | "referral" | "purchase" | "admin", number>> | undefined;
610
- autoTopupAdded?: number | undefined;
1694
+ export type ManagerPromptResponse = z.infer<typeof ManagerPromptResponseSchema>;
1695
+ export declare const SERVER_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
1696
+ type: z.ZodLiteral<"response-chunk">;
1697
+ userInputId: z.ZodString;
1698
+ chunk: z.ZodString;
1699
+ }, "strip", z.ZodTypeAny, {
1700
+ type: "response-chunk";
1701
+ userInputId: string;
1702
+ chunk: string;
611
1703
  }, {
612
- type: "init-response";
613
- usage: number;
614
- remainingBalance: number;
615
- next_quota_reset: Date | null;
616
- balanceBreakdown?: Partial<Record<"free" | "referral" | "purchase" | "admin", number>> | undefined;
617
- autoTopupAdded?: number | undefined;
618
- }>;
619
- export type InitResponse = z.infer<typeof InitResponseSchema>;
620
- export declare const ResponseCompleteSchema: z.ZodObject<z.objectUtil.extendShape<{
1704
+ type: "response-chunk";
1705
+ userInputId: string;
1706
+ chunk: string;
1707
+ }>, z.ZodObject<z.objectUtil.extendShape<{
621
1708
  type: z.ZodLiteral<"response-complete">;
622
1709
  userInputId: z.ZodString;
623
1710
  response: z.ZodString;
@@ -712,22 +1799,7 @@ export declare const ResponseCompleteSchema: z.ZodObject<z.objectUtil.extendShap
712
1799
  balanceBreakdown?: Partial<Record<"free" | "referral" | "purchase" | "admin", number>> | undefined;
713
1800
  next_quota_reset?: Date | null | undefined;
714
1801
  autoTopupAdded?: number | undefined;
715
- }>;
716
- export declare const MessageCostResponseSchema: z.ZodObject<{
717
- type: z.ZodLiteral<"message-cost-response">;
718
- promptId: z.ZodString;
719
- credits: z.ZodNumber;
720
- }, "strip", z.ZodTypeAny, {
721
- type: "message-cost-response";
722
- promptId: string;
723
- credits: number;
724
- }, {
725
- type: "message-cost-response";
726
- promptId: string;
727
- credits: number;
728
- }>;
729
- export type MessageCostResponse = z.infer<typeof MessageCostResponseSchema>;
730
- export declare const PromptResponseSchema: z.ZodObject<{
1802
+ }>, z.ZodObject<{
731
1803
  type: z.ZodLiteral<"prompt-response">;
732
1804
  promptId: z.ZodString;
733
1805
  agentState: z.ZodObject<{
@@ -1048,117 +2120,8 @@ export declare const PromptResponseSchema: z.ZodObject<{
1048
2120
  id: string;
1049
2121
  parameters: Record<string, string>;
1050
2122
  }[];
1051
- }>;
1052
- export type PromptResponse = z.infer<typeof PromptResponseSchema>;
1053
- export declare const SERVER_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
1054
- type: z.ZodLiteral<"response-chunk">;
1055
- userInputId: z.ZodString;
1056
- chunk: z.ZodString;
1057
- }, "strip", z.ZodTypeAny, {
1058
- type: "response-chunk";
1059
- userInputId: string;
1060
- chunk: string;
1061
- }, {
1062
- type: "response-chunk";
1063
- userInputId: string;
1064
- chunk: string;
1065
- }>, z.ZodObject<z.objectUtil.extendShape<{
1066
- type: z.ZodLiteral<"response-complete">;
1067
- userInputId: z.ZodString;
1068
- response: z.ZodString;
1069
- changes: z.ZodArray<z.ZodObject<{
1070
- type: z.ZodEnum<["patch", "file"]>;
1071
- path: z.ZodString;
1072
- content: z.ZodString;
1073
- }, "strip", z.ZodTypeAny, {
1074
- path: string;
1075
- type: "file" | "patch";
1076
- content: string;
1077
- }, {
1078
- path: string;
1079
- type: "file" | "patch";
1080
- content: string;
1081
- }>, "many">;
1082
- changesAlreadyApplied: z.ZodArray<z.ZodObject<{
1083
- type: z.ZodEnum<["patch", "file"]>;
1084
- path: z.ZodString;
1085
- content: z.ZodString;
1086
- }, "strip", z.ZodTypeAny, {
1087
- path: string;
1088
- type: "file" | "patch";
1089
- content: string;
1090
- }, {
1091
- path: string;
1092
- type: "file" | "patch";
1093
- content: string;
1094
- }>, "many">;
1095
- addedFileVersions: z.ZodArray<z.ZodObject<{
1096
- path: z.ZodString;
1097
- content: z.ZodString;
1098
- }, "strip", z.ZodTypeAny, {
1099
- path: string;
1100
- content: string;
1101
- }, {
1102
- path: string;
1103
- content: string;
1104
- }>, "many">;
1105
- resetFileVersions: z.ZodBoolean;
1106
- }, {
1107
- usage: z.ZodOptional<z.ZodNumber>;
1108
- remainingBalance: z.ZodOptional<z.ZodNumber>;
1109
- balanceBreakdown: z.ZodOptional<z.ZodOptional<z.ZodRecord<z.ZodEnum<["free", ...("free" | "referral" | "purchase" | "admin")[]]>, z.ZodNumber>>>;
1110
- next_quota_reset: z.ZodOptional<z.ZodNullable<z.ZodDate>>;
1111
- autoTopupAdded: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
1112
- }>, "strip", z.ZodTypeAny, {
1113
- type: "response-complete";
1114
- userInputId: string;
1115
- response: string;
1116
- changes: {
1117
- path: string;
1118
- type: "file" | "patch";
1119
- content: string;
1120
- }[];
1121
- changesAlreadyApplied: {
1122
- path: string;
1123
- type: "file" | "patch";
1124
- content: string;
1125
- }[];
1126
- addedFileVersions: {
1127
- path: string;
1128
- content: string;
1129
- }[];
1130
- resetFileVersions: boolean;
1131
- usage?: number | undefined;
1132
- remainingBalance?: number | undefined;
1133
- balanceBreakdown?: Partial<Record<"free" | "referral" | "purchase" | "admin", number>> | undefined;
1134
- next_quota_reset?: Date | null | undefined;
1135
- autoTopupAdded?: number | undefined;
1136
- }, {
1137
- type: "response-complete";
1138
- userInputId: string;
1139
- response: string;
1140
- changes: {
1141
- path: string;
1142
- type: "file" | "patch";
1143
- content: string;
1144
- }[];
1145
- changesAlreadyApplied: {
1146
- path: string;
1147
- type: "file" | "patch";
1148
- content: string;
1149
- }[];
1150
- addedFileVersions: {
1151
- path: string;
1152
- content: string;
1153
- }[];
1154
- resetFileVersions: boolean;
1155
- usage?: number | undefined;
1156
- remainingBalance?: number | undefined;
1157
- balanceBreakdown?: Partial<Record<"free" | "referral" | "purchase" | "admin", number>> | undefined;
1158
- next_quota_reset?: Date | null | undefined;
1159
- autoTopupAdded?: number | undefined;
1160
2123
  }>, z.ZodObject<{
1161
- type: z.ZodLiteral<"prompt-response">;
2124
+ type: z.ZodLiteral<"manager-prompt-response">;
1162
2125
  promptId: z.ZodString;
1163
2126
  agentState: z.ZodObject<{
1164
2127
  agentContext: z.ZodString;
@@ -1381,7 +2344,7 @@ export declare const SERVER_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
1381
2344
  result: string;
1382
2345
  }>, "many">;
1383
2346
  }, "strip", z.ZodTypeAny, {
1384
- type: "prompt-response";
2347
+ type: "manager-prompt-response";
1385
2348
  promptId: string;
1386
2349
  agentState: {
1387
2350
  agentContext: string;
@@ -1430,7 +2393,7 @@ export declare const SERVER_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
1430
2393
  parameters: Record<string, string>;
1431
2394
  }[];
1432
2395
  }, {
1433
- type: "prompt-response";
2396
+ type: "manager-prompt-response";
1434
2397
  promptId: string;
1435
2398
  agentState: {
1436
2399
  agentContext: string;