@polka-codes/core 0.8.17 → 0.8.19

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.
@@ -170,13 +170,13 @@ export declare namespace allTools {
170
170
  _default_5 as executeCommand,
171
171
  _default_6 as listFiles,
172
172
  _default_7 as readFile,
173
- _default_8 as searchFiles,
174
- _default_9 as updateKnowledge,
175
- _default_10 as writeToFile,
176
- _default_11 as handOver,
177
- _default_12 as removeFile,
178
- _default_13 as renameFile,
179
- _default_14 as editFile
173
+ _default_8 as replaceInFile,
174
+ _default_9 as searchFiles,
175
+ _default_10 as updateKnowledge,
176
+ _default_11 as writeToFile,
177
+ _default_12 as handOver,
178
+ _default_13 as removeFile,
179
+ _default_14 as renameFile
180
180
  }
181
181
  }
182
182
 
@@ -799,62 +799,300 @@ export declare class DeepSeekService extends AiServiceBase {
799
799
 
800
800
  declare const _default: {
801
801
  handler: ToolHandler<{
802
- readonly name: "replace_in_file";
803
- readonly description: "Request to replace sections of content in an existing file using SEARCH/REPLACE blocks that define exact changes to specific parts of the file. This tool should be used when you need to make targeted changes to specific parts of a file.";
802
+ readonly name: "edit_file";
803
+ readonly description: "Request to edit file contents using search/replace operations. Supports multiple edit operations in a single call.";
804
804
  readonly parameters: [{
805
805
  readonly name: "path";
806
- readonly description: "The path of the file to modify";
806
+ readonly description: "The path of the file to edit";
807
807
  readonly required: true;
808
808
  readonly usageValue: "File path here";
809
809
  }, {
810
- readonly name: "diff";
811
- readonly description: "One or more SEARCH/REPLACE blocks following this exact format:\n ```\n <<<<<<< SEARCH\n [exact content to find]\n =======\n [new content to replace with]\n >>>>>>> REPLACE\n ```\n Critical rules:\n 1. SEARCH content must match the associated file section to find EXACTLY:\n * Match character-for-character including whitespace, indentation, line endings\n * Include all comments, docstrings, etc.\n 2. SEARCH/REPLACE blocks will ONLY replace the first match occurrence.\n * Including multiple unique SEARCH/REPLACE blocks if you need to make multiple changes.\n * Include *just* enough lines in each SEARCH section to uniquely match each set of lines that need to change.\n * When using multiple SEARCH/REPLACE blocks, list them in the order they appear in the file.\n 3. Keep SEARCH/REPLACE blocks concise:\n * Break large SEARCH/REPLACE blocks into a series of smaller blocks that each change a small portion of the file.\n * Include just the changing lines, and a few surrounding lines if needed for uniqueness.\n * Do not include long runs of unchanging lines in SEARCH/REPLACE blocks.\n * Each line must be complete. Never truncate lines mid-way through as this can cause matching failures.\n 4. Special operations:\n * To move code: Use two SEARCH/REPLACE blocks (one to delete from original + one to insert at new location)\n * To delete code: Use empty REPLACE section";
810
+ readonly name: "operations";
811
+ readonly description: "Edit operation with search and replace parameters";
812
812
  readonly required: true;
813
- readonly usageValue: "Search and replace blocks here";
813
+ readonly allowMultiple: true;
814
+ readonly children: [{
815
+ readonly name: "search";
816
+ readonly description: "Text to search for and replace (use <<<START_OF_FILE>>> to insert at file start, <<<END_OF_FILE>>> to insert at file end)";
817
+ readonly required: true;
818
+ readonly usageValue: "Text to find and replace";
819
+ }, {
820
+ readonly name: "replace";
821
+ readonly description: "Text to replace the search text with";
822
+ readonly required: true;
823
+ readonly usageValue: "Replacement text";
824
+ }];
825
+ readonly usageValue: "operations here";
814
826
  }];
815
827
  readonly examples: [{
816
- readonly description: "Request to replace sections of content in a file";
828
+ readonly description: "Replace specific text";
817
829
  readonly parameters: [{
818
830
  readonly name: "path";
819
- readonly value: "src/main.js";
831
+ readonly value: "src/main.ts";
820
832
  }, {
821
- readonly name: "diff";
822
- readonly value: "\n<<<<<<< SEARCH\nimport React from 'react';\n=======\nimport React, { useState } from 'react';\n>>>>>>> REPLACE\n\n<<<<<<< SEARCH\nfunction handleSubmit() {\n saveData();\n setLoading(false);\n}\n\n=======\n>>>>>>> REPLACE\n\n<<<<<<< SEARCH\nreturn (\n <div>\n=======\nfunction handleSubmit() {\n saveData();\n setLoading(false);\n}\n\nreturn (\n <div>\n>>>>>>> REPLACE\n";
833
+ readonly name: "operations";
834
+ readonly value: {
835
+ readonly search: "function oldFunction() {\n return 42;\n}";
836
+ readonly replace: "function newFunction() {\n return \"new implementation\";\n}";
837
+ };
838
+ }];
839
+ }, {
840
+ readonly description: "Insert at start of file";
841
+ readonly parameters: [{
842
+ readonly name: "path";
843
+ readonly value: "src/header.ts";
844
+ }, {
845
+ readonly name: "operations";
846
+ readonly value: {
847
+ readonly search: "<<<START_OF_FILE>>>";
848
+ readonly replace: "// File header comment\n";
849
+ };
850
+ }];
851
+ }, {
852
+ readonly description: "Multiple operations in one call";
853
+ readonly parameters: [{
854
+ readonly name: "path";
855
+ readonly value: "src/utils.ts";
856
+ }, {
857
+ readonly name: "operations";
858
+ readonly value: [{
859
+ readonly search: "import React from \"react\"";
860
+ readonly replace: "import React, { useState } from \"react\"";
861
+ }, {
862
+ readonly search: "function Component() {\n return (";
863
+ readonly replace: "function Component() {\n const [state, setState] = useState(false);\n return (";
864
+ }];
865
+ }];
866
+ }, {
867
+ readonly description: "Append content at end of file";
868
+ readonly parameters: [{
869
+ readonly name: "path";
870
+ readonly value: "src/footer.ts";
871
+ }, {
872
+ readonly name: "operations";
873
+ readonly value: {
874
+ readonly search: "<<<END_OF_FILE>>>";
875
+ readonly replace: "\n// End of file appended comment\n";
876
+ };
823
877
  }];
824
878
  }];
825
879
  readonly permissionLevel: PermissionLevel.Write;
826
880
  }, FilesystemProvider>;
827
881
  isAvailable: (provider: FilesystemProvider) => boolean;
828
- name: "replace_in_file";
829
- description: "Request to replace sections of content in an existing file using SEARCH/REPLACE blocks that define exact changes to specific parts of the file. This tool should be used when you need to make targeted changes to specific parts of a file.";
882
+ name: "edit_file";
883
+ description: "Request to edit file contents using search/replace operations. Supports multiple edit operations in a single call.";
830
884
  parameters: [{
831
885
  readonly name: "path";
832
- readonly description: "The path of the file to modify";
886
+ readonly description: "The path of the file to edit";
833
887
  readonly required: true;
834
888
  readonly usageValue: "File path here";
835
889
  }, {
836
- readonly name: "diff";
837
- readonly description: "One or more SEARCH/REPLACE blocks following this exact format:\n ```\n <<<<<<< SEARCH\n [exact content to find]\n =======\n [new content to replace with]\n >>>>>>> REPLACE\n ```\n Critical rules:\n 1. SEARCH content must match the associated file section to find EXACTLY:\n * Match character-for-character including whitespace, indentation, line endings\n * Include all comments, docstrings, etc.\n 2. SEARCH/REPLACE blocks will ONLY replace the first match occurrence.\n * Including multiple unique SEARCH/REPLACE blocks if you need to make multiple changes.\n * Include *just* enough lines in each SEARCH section to uniquely match each set of lines that need to change.\n * When using multiple SEARCH/REPLACE blocks, list them in the order they appear in the file.\n 3. Keep SEARCH/REPLACE blocks concise:\n * Break large SEARCH/REPLACE blocks into a series of smaller blocks that each change a small portion of the file.\n * Include just the changing lines, and a few surrounding lines if needed for uniqueness.\n * Do not include long runs of unchanging lines in SEARCH/REPLACE blocks.\n * Each line must be complete. Never truncate lines mid-way through as this can cause matching failures.\n 4. Special operations:\n * To move code: Use two SEARCH/REPLACE blocks (one to delete from original + one to insert at new location)\n * To delete code: Use empty REPLACE section";
890
+ readonly name: "operations";
891
+ readonly description: "Edit operation with search and replace parameters";
838
892
  readonly required: true;
839
- readonly usageValue: "Search and replace blocks here";
893
+ readonly allowMultiple: true;
894
+ readonly children: [{
895
+ readonly name: "search";
896
+ readonly description: "Text to search for and replace (use <<<START_OF_FILE>>> to insert at file start, <<<END_OF_FILE>>> to insert at file end)";
897
+ readonly required: true;
898
+ readonly usageValue: "Text to find and replace";
899
+ }, {
900
+ readonly name: "replace";
901
+ readonly description: "Text to replace the search text with";
902
+ readonly required: true;
903
+ readonly usageValue: "Replacement text";
904
+ }];
905
+ readonly usageValue: "operations here";
840
906
  }];
841
907
  examples: [{
842
- readonly description: "Request to replace sections of content in a file";
908
+ readonly description: "Replace specific text";
843
909
  readonly parameters: [{
844
910
  readonly name: "path";
845
- readonly value: "src/main.js";
911
+ readonly value: "src/main.ts";
846
912
  }, {
847
- readonly name: "diff";
848
- readonly value: "\n<<<<<<< SEARCH\nimport React from 'react';\n=======\nimport React, { useState } from 'react';\n>>>>>>> REPLACE\n\n<<<<<<< SEARCH\nfunction handleSubmit() {\n saveData();\n setLoading(false);\n}\n\n=======\n>>>>>>> REPLACE\n\n<<<<<<< SEARCH\nreturn (\n <div>\n=======\nfunction handleSubmit() {\n saveData();\n setLoading(false);\n}\n\nreturn (\n <div>\n>>>>>>> REPLACE\n";
913
+ readonly name: "operations";
914
+ readonly value: {
915
+ readonly search: "function oldFunction() {\n return 42;\n}";
916
+ readonly replace: "function newFunction() {\n return \"new implementation\";\n}";
917
+ };
918
+ }];
919
+ }, {
920
+ readonly description: "Insert at start of file";
921
+ readonly parameters: [{
922
+ readonly name: "path";
923
+ readonly value: "src/header.ts";
924
+ }, {
925
+ readonly name: "operations";
926
+ readonly value: {
927
+ readonly search: "<<<START_OF_FILE>>>";
928
+ readonly replace: "// File header comment\n";
929
+ };
930
+ }];
931
+ }, {
932
+ readonly description: "Multiple operations in one call";
933
+ readonly parameters: [{
934
+ readonly name: "path";
935
+ readonly value: "src/utils.ts";
936
+ }, {
937
+ readonly name: "operations";
938
+ readonly value: [{
939
+ readonly search: "import React from \"react\"";
940
+ readonly replace: "import React, { useState } from \"react\"";
941
+ }, {
942
+ readonly search: "function Component() {\n return (";
943
+ readonly replace: "function Component() {\n const [state, setState] = useState(false);\n return (";
944
+ }];
945
+ }];
946
+ }, {
947
+ readonly description: "Append content at end of file";
948
+ readonly parameters: [{
949
+ readonly name: "path";
950
+ readonly value: "src/footer.ts";
951
+ }, {
952
+ readonly name: "operations";
953
+ readonly value: {
954
+ readonly search: "<<<END_OF_FILE>>>";
955
+ readonly replace: "\n// End of file appended comment\n";
956
+ };
849
957
  }];
850
958
  }];
851
959
  permissionLevel: PermissionLevel.Write;
852
960
  };
853
- export { _default as default_alias_14 }
854
- export { _default as replaceInFile }
855
- export { _default as replaceInFile_alias_1 }
961
+ export { _default as default_alias_7 }
962
+ export { _default as editFile }
963
+ export { _default as editFile_alias_1 }
856
964
 
857
965
  declare const _default_10: {
966
+ handler: ToolHandler<{
967
+ readonly name: "update_knowledge";
968
+ readonly description: "Update knowledge in a knowledge.ai.yml file with smart merging capabilities. This tool lets you add, update, or remove information using path-based updates and special directives.";
969
+ readonly parameters: [{
970
+ readonly name: "path";
971
+ readonly description: "Directory containing (or where to create) the knowledge.ai.yml file";
972
+ readonly required: true;
973
+ readonly usageValue: "Directory path here";
974
+ }, {
975
+ readonly name: "knowledge";
976
+ readonly description: "YAML content to merge into the knowledge file";
977
+ readonly required: true;
978
+ readonly usageValue: "YAML content with knowledge to update";
979
+ }];
980
+ readonly examples: [{
981
+ readonly description: "Add a new file entry";
982
+ readonly parameters: [{
983
+ readonly name: "path";
984
+ readonly value: "src/utils";
985
+ }, {
986
+ readonly name: "knowledge";
987
+ readonly value: "files:\n \"newFile.ts\":\n description: \"A new utility file\"\n api:\n functions:\n 1:\n name: \"processData\"\n params:\n 1: { name: \"data\", type: \"object\" }\n returns: \"object\"";
988
+ }];
989
+ }, {
990
+ readonly description: "Update an existing file description";
991
+ readonly parameters: [{
992
+ readonly name: "path";
993
+ readonly value: "src/utils";
994
+ }, {
995
+ readonly name: "knowledge";
996
+ readonly value: "files:\n \"existingFile.ts\":\n description: \"Updated description for the file\"";
997
+ }];
998
+ }, {
999
+ readonly description: "Add a new rule";
1000
+ readonly parameters: [{
1001
+ readonly name: "path";
1002
+ readonly value: "src";
1003
+ }, {
1004
+ readonly name: "knowledge";
1005
+ readonly value: "rules:\n 10: \"New rule to follow\"";
1006
+ }];
1007
+ }, {
1008
+ readonly description: "Remove a rule";
1009
+ readonly parameters: [{
1010
+ readonly name: "path";
1011
+ readonly value: "src";
1012
+ }, {
1013
+ readonly name: "knowledge";
1014
+ readonly value: "rules:\n 5: null";
1015
+ }];
1016
+ }, {
1017
+ readonly description: "Update nested properties using dot notation";
1018
+ readonly parameters: [{
1019
+ readonly name: "path";
1020
+ readonly value: "src/components";
1021
+ }, {
1022
+ readonly name: "knowledge";
1023
+ readonly value: "files.Button.tsx.api.functions.1.description: \"Updated function description\"";
1024
+ }];
1025
+ }];
1026
+ readonly permissionLevel: PermissionLevel.Write;
1027
+ }, FilesystemProvider>;
1028
+ isAvailable: (provider: FilesystemProvider) => boolean;
1029
+ name: "update_knowledge";
1030
+ description: "Update knowledge in a knowledge.ai.yml file with smart merging capabilities. This tool lets you add, update, or remove information using path-based updates and special directives.";
1031
+ parameters: [{
1032
+ readonly name: "path";
1033
+ readonly description: "Directory containing (or where to create) the knowledge.ai.yml file";
1034
+ readonly required: true;
1035
+ readonly usageValue: "Directory path here";
1036
+ }, {
1037
+ readonly name: "knowledge";
1038
+ readonly description: "YAML content to merge into the knowledge file";
1039
+ readonly required: true;
1040
+ readonly usageValue: "YAML content with knowledge to update";
1041
+ }];
1042
+ examples: [{
1043
+ readonly description: "Add a new file entry";
1044
+ readonly parameters: [{
1045
+ readonly name: "path";
1046
+ readonly value: "src/utils";
1047
+ }, {
1048
+ readonly name: "knowledge";
1049
+ readonly value: "files:\n \"newFile.ts\":\n description: \"A new utility file\"\n api:\n functions:\n 1:\n name: \"processData\"\n params:\n 1: { name: \"data\", type: \"object\" }\n returns: \"object\"";
1050
+ }];
1051
+ }, {
1052
+ readonly description: "Update an existing file description";
1053
+ readonly parameters: [{
1054
+ readonly name: "path";
1055
+ readonly value: "src/utils";
1056
+ }, {
1057
+ readonly name: "knowledge";
1058
+ readonly value: "files:\n \"existingFile.ts\":\n description: \"Updated description for the file\"";
1059
+ }];
1060
+ }, {
1061
+ readonly description: "Add a new rule";
1062
+ readonly parameters: [{
1063
+ readonly name: "path";
1064
+ readonly value: "src";
1065
+ }, {
1066
+ readonly name: "knowledge";
1067
+ readonly value: "rules:\n 10: \"New rule to follow\"";
1068
+ }];
1069
+ }, {
1070
+ readonly description: "Remove a rule";
1071
+ readonly parameters: [{
1072
+ readonly name: "path";
1073
+ readonly value: "src";
1074
+ }, {
1075
+ readonly name: "knowledge";
1076
+ readonly value: "rules:\n 5: null";
1077
+ }];
1078
+ }, {
1079
+ readonly description: "Update nested properties using dot notation";
1080
+ readonly parameters: [{
1081
+ readonly name: "path";
1082
+ readonly value: "src/components";
1083
+ }, {
1084
+ readonly name: "knowledge";
1085
+ readonly value: "files.Button.tsx.api.functions.1.description: \"Updated function description\"";
1086
+ }];
1087
+ }];
1088
+ permissionLevel: PermissionLevel.Write;
1089
+ };
1090
+ export { _default_10 as default_alias_16 }
1091
+ export { _default_10 as updateKnowledge }
1092
+ export { _default_10 as updateKnowledge_alias_1 }
1093
+ export { _default_10 as updateKnowledge_alias_2 }
1094
+
1095
+ declare const _default_11: {
858
1096
  handler: ToolHandler<{
859
1097
  readonly name: "write_to_file";
860
1098
  readonly description: "Request to write content to a file at the specified path. If the file exists, it will be overwritten with the provided content. If the file doesn't exist, it will be created. This tool will automatically create any directories needed to write the file. Ensure that the output content does not include incorrect escaped character patterns such as `&lt;` and `&gt;`.";
@@ -907,12 +1145,12 @@ declare const _default_10: {
907
1145
  }];
908
1146
  permissionLevel: PermissionLevel.Write;
909
1147
  };
910
- export { _default_10 as default_alias_17 }
911
- export { _default_10 as writeToFile }
912
- export { _default_10 as writeToFile_alias_1 }
913
- export { _default_10 as writeToFile_alias_2 }
1148
+ export { _default_11 as default_alias_17 }
1149
+ export { _default_11 as writeToFile }
1150
+ export { _default_11 as writeToFile_alias_1 }
1151
+ export { _default_11 as writeToFile_alias_2 }
914
1152
 
915
- declare const _default_11: {
1153
+ declare const _default_12: {
916
1154
  handler: ToolHandler<{
917
1155
  readonly name: "hand_over";
918
1156
  readonly description: "Hand over the current task to another agent to complete. This tool MUST NOT to be used with any other tool.";
@@ -997,12 +1235,12 @@ declare const _default_11: {
997
1235
  }];
998
1236
  permissionLevel: PermissionLevel.None;
999
1237
  };
1000
- export { _default_11 as default_alias_9 }
1001
- export { _default_11 as handOver }
1002
- export { _default_11 as handOver_alias_1 }
1003
- export { _default_11 as handOver_alias_2 }
1238
+ export { _default_12 as default_alias_9 }
1239
+ export { _default_12 as handOver }
1240
+ export { _default_12 as handOver_alias_1 }
1241
+ export { _default_12 as handOver_alias_2 }
1004
1242
 
1005
- declare const _default_12: {
1243
+ declare const _default_13: {
1006
1244
  handler: ToolHandler<{
1007
1245
  readonly name: "remove_file";
1008
1246
  readonly description: "Request to remove a file at the specified path.";
@@ -1039,12 +1277,12 @@ declare const _default_12: {
1039
1277
  }];
1040
1278
  permissionLevel: PermissionLevel.Write;
1041
1279
  };
1042
- export { _default_12 as default_alias_12 }
1043
- export { _default_12 as removeFile }
1044
- export { _default_12 as removeFile_alias_1 }
1045
- export { _default_12 as removeFile_alias_2 }
1280
+ export { _default_13 as default_alias_12 }
1281
+ export { _default_13 as removeFile }
1282
+ export { _default_13 as removeFile_alias_1 }
1283
+ export { _default_13 as removeFile_alias_2 }
1046
1284
 
1047
- declare const _default_13: {
1285
+ declare const _default_14: {
1048
1286
  handler: ToolHandler<{
1049
1287
  readonly name: "rename_file";
1050
1288
  readonly description: "Request to rename a file from source path to target path.";
@@ -1066,221 +1304,41 @@ declare const _default_13: {
1066
1304
  readonly value: "src/old-name.js";
1067
1305
  }, {
1068
1306
  readonly name: "target_path";
1069
- readonly value: "src/new-name.js";
1070
- }];
1071
- }];
1072
- readonly permissionLevel: PermissionLevel.Write;
1073
- }, FilesystemProvider>;
1074
- isAvailable: (provider: FilesystemProvider) => boolean;
1075
- name: "rename_file";
1076
- description: "Request to rename a file from source path to target path.";
1077
- parameters: [{
1078
- readonly name: "source_path";
1079
- readonly description: "The current path of the file";
1080
- readonly required: true;
1081
- readonly usageValue: "Source file path here";
1082
- }, {
1083
- readonly name: "target_path";
1084
- readonly description: "The new path for the file";
1085
- readonly required: true;
1086
- readonly usageValue: "Target file path here";
1087
- }];
1088
- examples: [{
1089
- readonly description: "Request to rename a file";
1090
- readonly parameters: [{
1091
- readonly name: "source_path";
1092
- readonly value: "src/old-name.js";
1093
- }, {
1094
- readonly name: "target_path";
1095
- readonly value: "src/new-name.js";
1096
- }];
1097
- }];
1098
- permissionLevel: PermissionLevel.Write;
1099
- };
1100
- export { _default_13 as default_alias_13 }
1101
- export { _default_13 as renameFile }
1102
- export { _default_13 as renameFile_alias_1 }
1103
- export { _default_13 as renameFile_alias_2 }
1104
-
1105
- declare const _default_14: {
1106
- handler: ToolHandler<{
1107
- readonly name: "edit_file";
1108
- readonly description: "Request to edit file contents using before/after text anchors with flexible operations. Supports multiple edit operations in a single call.";
1109
- readonly parameters: [{
1110
- readonly name: "path";
1111
- readonly description: "The path of the file to edit";
1112
- readonly required: true;
1113
- readonly usageValue: "File path here";
1114
- }, {
1115
- readonly name: "operations";
1116
- readonly description: "Edit operation with start_anchor, end_anchor, new_text, and optional line range hints";
1117
- readonly required: true;
1118
- readonly allowMultiple: true;
1119
- readonly children: [{
1120
- readonly name: "start_anchor";
1121
- readonly description: "Text to find as the start anchor (use <<<START_OF_FILE>>> for file start)";
1122
- readonly required: false;
1123
- readonly usageValue: "Text before the edit location";
1124
- }, {
1125
- readonly name: "end_anchor";
1126
- readonly description: "Text to find as the end anchor (use <<<END_OF_FILE>>> for file end)";
1127
- readonly required: false;
1128
- readonly usageValue: "Text after the edit location";
1129
- }, {
1130
- readonly name: "new_text";
1131
- readonly description: "Text to replace the content between start_anchor and end_anchor";
1132
- readonly required: true;
1133
- readonly usageValue: "New text content";
1134
- }, {
1135
- readonly name: "start_anchor_line_start";
1136
- readonly description: "Optional line number hint for start_anchor location (1-based)";
1137
- readonly required: false;
1138
- readonly usageValue: "10";
1139
- }, {
1140
- readonly name: "end_anchor_line_start";
1141
- readonly description: "Optional line number hint for end_anchor location (1-based)";
1142
- readonly required: false;
1143
- readonly usageValue: "20";
1144
- }];
1145
- readonly usageValue: "operations here";
1146
- }];
1147
- readonly examples: [{
1148
- readonly description: "Replace content between two text anchors";
1149
- readonly parameters: [{
1150
- readonly name: "path";
1151
- readonly value: "src/main.ts";
1152
- }, {
1153
- readonly name: "operations";
1154
- readonly value: {
1155
- readonly start_anchor: "function oldFunction() {";
1156
- readonly end_anchor: "}";
1157
- readonly new_text: "\n return \"new implementation\";\n";
1158
- };
1159
- }];
1160
- }, {
1161
- readonly description: "Insert at start of file";
1162
- readonly parameters: [{
1163
- readonly name: "path";
1164
- readonly value: "src/header.ts";
1165
- }, {
1166
- readonly name: "operations";
1167
- readonly value: {
1168
- readonly start_anchor: "<<<START_OF_FILE>>>";
1169
- readonly end_anchor: "export";
1170
- readonly new_text: "// File header comment\n";
1171
- };
1172
- }];
1173
- }, {
1174
- readonly description: "Multiple operations in one call";
1175
- readonly parameters: [{
1176
- readonly name: "path";
1177
- readonly value: "src/utils.ts";
1178
- }, {
1179
- readonly name: "operations";
1180
- readonly value: [{
1181
- readonly start_anchor: "import React";
1182
- readonly end_anchor: "from \"react\"";
1183
- readonly new_text: ", { useState }";
1184
- }, {
1185
- readonly start_anchor: "function Component() {";
1186
- readonly end_anchor: "return (";
1187
- readonly new_text: "\n const [state, setState] = useState(false);\n ";
1188
- }];
1307
+ readonly value: "src/new-name.js";
1189
1308
  }];
1190
1309
  }];
1191
1310
  readonly permissionLevel: PermissionLevel.Write;
1192
1311
  }, FilesystemProvider>;
1193
1312
  isAvailable: (provider: FilesystemProvider) => boolean;
1194
- name: "edit_file";
1195
- description: "Request to edit file contents using before/after text anchors with flexible operations. Supports multiple edit operations in a single call.";
1313
+ name: "rename_file";
1314
+ description: "Request to rename a file from source path to target path.";
1196
1315
  parameters: [{
1197
- readonly name: "path";
1198
- readonly description: "The path of the file to edit";
1316
+ readonly name: "source_path";
1317
+ readonly description: "The current path of the file";
1199
1318
  readonly required: true;
1200
- readonly usageValue: "File path here";
1319
+ readonly usageValue: "Source file path here";
1201
1320
  }, {
1202
- readonly name: "operations";
1203
- readonly description: "Edit operation with start_anchor, end_anchor, new_text, and optional line range hints";
1321
+ readonly name: "target_path";
1322
+ readonly description: "The new path for the file";
1204
1323
  readonly required: true;
1205
- readonly allowMultiple: true;
1206
- readonly children: [{
1207
- readonly name: "start_anchor";
1208
- readonly description: "Text to find as the start anchor (use <<<START_OF_FILE>>> for file start)";
1209
- readonly required: false;
1210
- readonly usageValue: "Text before the edit location";
1211
- }, {
1212
- readonly name: "end_anchor";
1213
- readonly description: "Text to find as the end anchor (use <<<END_OF_FILE>>> for file end)";
1214
- readonly required: false;
1215
- readonly usageValue: "Text after the edit location";
1216
- }, {
1217
- readonly name: "new_text";
1218
- readonly description: "Text to replace the content between start_anchor and end_anchor";
1219
- readonly required: true;
1220
- readonly usageValue: "New text content";
1221
- }, {
1222
- readonly name: "start_anchor_line_start";
1223
- readonly description: "Optional line number hint for start_anchor location (1-based)";
1224
- readonly required: false;
1225
- readonly usageValue: "10";
1226
- }, {
1227
- readonly name: "end_anchor_line_start";
1228
- readonly description: "Optional line number hint for end_anchor location (1-based)";
1229
- readonly required: false;
1230
- readonly usageValue: "20";
1231
- }];
1232
- readonly usageValue: "operations here";
1324
+ readonly usageValue: "Target file path here";
1233
1325
  }];
1234
1326
  examples: [{
1235
- readonly description: "Replace content between two text anchors";
1236
- readonly parameters: [{
1237
- readonly name: "path";
1238
- readonly value: "src/main.ts";
1239
- }, {
1240
- readonly name: "operations";
1241
- readonly value: {
1242
- readonly start_anchor: "function oldFunction() {";
1243
- readonly end_anchor: "}";
1244
- readonly new_text: "\n return \"new implementation\";\n";
1245
- };
1246
- }];
1247
- }, {
1248
- readonly description: "Insert at start of file";
1249
- readonly parameters: [{
1250
- readonly name: "path";
1251
- readonly value: "src/header.ts";
1252
- }, {
1253
- readonly name: "operations";
1254
- readonly value: {
1255
- readonly start_anchor: "<<<START_OF_FILE>>>";
1256
- readonly end_anchor: "export";
1257
- readonly new_text: "// File header comment\n";
1258
- };
1259
- }];
1260
- }, {
1261
- readonly description: "Multiple operations in one call";
1327
+ readonly description: "Request to rename a file";
1262
1328
  readonly parameters: [{
1263
- readonly name: "path";
1264
- readonly value: "src/utils.ts";
1329
+ readonly name: "source_path";
1330
+ readonly value: "src/old-name.js";
1265
1331
  }, {
1266
- readonly name: "operations";
1267
- readonly value: [{
1268
- readonly start_anchor: "import React";
1269
- readonly end_anchor: "from \"react\"";
1270
- readonly new_text: ", { useState }";
1271
- }, {
1272
- readonly start_anchor: "function Component() {";
1273
- readonly end_anchor: "return (";
1274
- readonly new_text: "\n const [state, setState] = useState(false);\n ";
1275
- }];
1332
+ readonly name: "target_path";
1333
+ readonly value: "src/new-name.js";
1276
1334
  }];
1277
1335
  }];
1278
1336
  permissionLevel: PermissionLevel.Write;
1279
1337
  };
1280
- export { _default_14 as default_alias_7 }
1281
- export { _default_14 as editFile }
1282
- export { _default_14 as editFile_alias_1 }
1283
- export { _default_14 as editFile_alias_2 }
1338
+ export { _default_14 as default_alias_13 }
1339
+ export { _default_14 as renameFile }
1340
+ export { _default_14 as renameFile_alias_1 }
1341
+ export { _default_14 as renameFile_alias_2 }
1284
1342
 
1285
1343
  declare const _default_2: {
1286
1344
  handler: ToolHandler<{
@@ -1725,6 +1783,64 @@ export { _default_7 as readFile_alias_1 }
1725
1783
  export { _default_7 as readFile_alias_2 }
1726
1784
 
1727
1785
  declare const _default_8: {
1786
+ handler: ToolHandler<{
1787
+ readonly name: "replace_in_file";
1788
+ readonly description: "Request to replace sections of content in an existing file using SEARCH/REPLACE blocks that define exact changes to specific parts of the file. This tool should be used when you need to make targeted changes to specific parts of a file.";
1789
+ readonly parameters: [{
1790
+ readonly name: "path";
1791
+ readonly description: "The path of the file to modify";
1792
+ readonly required: true;
1793
+ readonly usageValue: "File path here";
1794
+ }, {
1795
+ readonly name: "diff";
1796
+ readonly description: "One or more SEARCH/REPLACE blocks following this exact format:\n ```\n <<<<<<< SEARCH\n [exact content to find]\n =======\n [new content to replace with]\n >>>>>>> REPLACE\n ```\n Critical rules:\n 1. SEARCH content must match the associated file section to find EXACTLY:\n * Match character-for-character including whitespace, indentation, line endings\n * Include all comments, docstrings, etc.\n 2. SEARCH/REPLACE blocks will ONLY replace the first match occurrence.\n * Including multiple unique SEARCH/REPLACE blocks if you need to make multiple changes.\n * Include *just* enough lines in each SEARCH section to uniquely match each set of lines that need to change.\n * When using multiple SEARCH/REPLACE blocks, list them in the order they appear in the file.\n 3. Keep SEARCH/REPLACE blocks concise:\n * Break large SEARCH/REPLACE blocks into a series of smaller blocks that each change a small portion of the file.\n * Include just the changing lines, and a few surrounding lines if needed for uniqueness.\n * Do not include long runs of unchanging lines in SEARCH/REPLACE blocks.\n * Each line must be complete. Never truncate lines mid-way through as this can cause matching failures.\n 4. Special operations:\n * To move code: Use two SEARCH/REPLACE blocks (one to delete from original + one to insert at new location)\n * To delete code: Use empty REPLACE section";
1797
+ readonly required: true;
1798
+ readonly usageValue: "Search and replace blocks here";
1799
+ }];
1800
+ readonly examples: [{
1801
+ readonly description: "Request to replace sections of content in a file";
1802
+ readonly parameters: [{
1803
+ readonly name: "path";
1804
+ readonly value: "src/main.js";
1805
+ }, {
1806
+ readonly name: "diff";
1807
+ readonly value: "\n<<<<<<< SEARCH\nimport React from 'react';\n=======\nimport React, { useState } from 'react';\n>>>>>>> REPLACE\n\n<<<<<<< SEARCH\nfunction handleSubmit() {\n saveData();\n setLoading(false);\n}\n\n=======\n>>>>>>> REPLACE\n\n<<<<<<< SEARCH\nreturn (\n <div>\n=======\nfunction handleSubmit() {\n saveData();\n setLoading(false);\n}\n\nreturn (\n <div>\n>>>>>>> REPLACE\n";
1808
+ }];
1809
+ }];
1810
+ readonly permissionLevel: PermissionLevel.Write;
1811
+ }, FilesystemProvider>;
1812
+ isAvailable: (provider: FilesystemProvider) => boolean;
1813
+ name: "replace_in_file";
1814
+ description: "Request to replace sections of content in an existing file using SEARCH/REPLACE blocks that define exact changes to specific parts of the file. This tool should be used when you need to make targeted changes to specific parts of a file.";
1815
+ parameters: [{
1816
+ readonly name: "path";
1817
+ readonly description: "The path of the file to modify";
1818
+ readonly required: true;
1819
+ readonly usageValue: "File path here";
1820
+ }, {
1821
+ readonly name: "diff";
1822
+ readonly description: "One or more SEARCH/REPLACE blocks following this exact format:\n ```\n <<<<<<< SEARCH\n [exact content to find]\n =======\n [new content to replace with]\n >>>>>>> REPLACE\n ```\n Critical rules:\n 1. SEARCH content must match the associated file section to find EXACTLY:\n * Match character-for-character including whitespace, indentation, line endings\n * Include all comments, docstrings, etc.\n 2. SEARCH/REPLACE blocks will ONLY replace the first match occurrence.\n * Including multiple unique SEARCH/REPLACE blocks if you need to make multiple changes.\n * Include *just* enough lines in each SEARCH section to uniquely match each set of lines that need to change.\n * When using multiple SEARCH/REPLACE blocks, list them in the order they appear in the file.\n 3. Keep SEARCH/REPLACE blocks concise:\n * Break large SEARCH/REPLACE blocks into a series of smaller blocks that each change a small portion of the file.\n * Include just the changing lines, and a few surrounding lines if needed for uniqueness.\n * Do not include long runs of unchanging lines in SEARCH/REPLACE blocks.\n * Each line must be complete. Never truncate lines mid-way through as this can cause matching failures.\n 4. Special operations:\n * To move code: Use two SEARCH/REPLACE blocks (one to delete from original + one to insert at new location)\n * To delete code: Use empty REPLACE section";
1823
+ readonly required: true;
1824
+ readonly usageValue: "Search and replace blocks here";
1825
+ }];
1826
+ examples: [{
1827
+ readonly description: "Request to replace sections of content in a file";
1828
+ readonly parameters: [{
1829
+ readonly name: "path";
1830
+ readonly value: "src/main.js";
1831
+ }, {
1832
+ readonly name: "diff";
1833
+ readonly value: "\n<<<<<<< SEARCH\nimport React from 'react';\n=======\nimport React, { useState } from 'react';\n>>>>>>> REPLACE\n\n<<<<<<< SEARCH\nfunction handleSubmit() {\n saveData();\n setLoading(false);\n}\n\n=======\n>>>>>>> REPLACE\n\n<<<<<<< SEARCH\nreturn (\n <div>\n=======\nfunction handleSubmit() {\n saveData();\n setLoading(false);\n}\n\nreturn (\n <div>\n>>>>>>> REPLACE\n";
1834
+ }];
1835
+ }];
1836
+ permissionLevel: PermissionLevel.Write;
1837
+ };
1838
+ export { _default_8 as default_alias_14 }
1839
+ export { _default_8 as replaceInFile }
1840
+ export { _default_8 as replaceInFile_alias_1 }
1841
+ export { _default_8 as replaceInFile_alias_2 }
1842
+
1843
+ declare const _default_9: {
1728
1844
  handler: ToolHandler<{
1729
1845
  readonly name: "search_files";
1730
1846
  readonly description: "Request to perform a regex search across files in a specified directory, outputting context-rich results that include surrounding lines. This tool searches for patterns or specific content across multiple files, displaying each match with encapsulating context.";
@@ -1793,140 +1909,10 @@ declare const _default_8: {
1793
1909
  }];
1794
1910
  permissionLevel: PermissionLevel.Read;
1795
1911
  };
1796
- export { _default_8 as default_alias_15 }
1797
- export { _default_8 as searchFiles }
1798
- export { _default_8 as searchFiles_alias_1 }
1799
- export { _default_8 as searchFiles_alias_2 }
1800
-
1801
- declare const _default_9: {
1802
- handler: ToolHandler<{
1803
- readonly name: "update_knowledge";
1804
- readonly description: "Update knowledge in a knowledge.ai.yml file with smart merging capabilities. This tool lets you add, update, or remove information using path-based updates and special directives.";
1805
- readonly parameters: [{
1806
- readonly name: "path";
1807
- readonly description: "Directory containing (or where to create) the knowledge.ai.yml file";
1808
- readonly required: true;
1809
- readonly usageValue: "Directory path here";
1810
- }, {
1811
- readonly name: "knowledge";
1812
- readonly description: "YAML content to merge into the knowledge file";
1813
- readonly required: true;
1814
- readonly usageValue: "YAML content with knowledge to update";
1815
- }];
1816
- readonly examples: [{
1817
- readonly description: "Add a new file entry";
1818
- readonly parameters: [{
1819
- readonly name: "path";
1820
- readonly value: "src/utils";
1821
- }, {
1822
- readonly name: "knowledge";
1823
- readonly value: "files:\n \"newFile.ts\":\n description: \"A new utility file\"\n api:\n functions:\n 1:\n name: \"processData\"\n params:\n 1: { name: \"data\", type: \"object\" }\n returns: \"object\"";
1824
- }];
1825
- }, {
1826
- readonly description: "Update an existing file description";
1827
- readonly parameters: [{
1828
- readonly name: "path";
1829
- readonly value: "src/utils";
1830
- }, {
1831
- readonly name: "knowledge";
1832
- readonly value: "files:\n \"existingFile.ts\":\n description: \"Updated description for the file\"";
1833
- }];
1834
- }, {
1835
- readonly description: "Add a new rule";
1836
- readonly parameters: [{
1837
- readonly name: "path";
1838
- readonly value: "src";
1839
- }, {
1840
- readonly name: "knowledge";
1841
- readonly value: "rules:\n 10: \"New rule to follow\"";
1842
- }];
1843
- }, {
1844
- readonly description: "Remove a rule";
1845
- readonly parameters: [{
1846
- readonly name: "path";
1847
- readonly value: "src";
1848
- }, {
1849
- readonly name: "knowledge";
1850
- readonly value: "rules:\n 5: null";
1851
- }];
1852
- }, {
1853
- readonly description: "Update nested properties using dot notation";
1854
- readonly parameters: [{
1855
- readonly name: "path";
1856
- readonly value: "src/components";
1857
- }, {
1858
- readonly name: "knowledge";
1859
- readonly value: "files.Button.tsx.api.functions.1.description: \"Updated function description\"";
1860
- }];
1861
- }];
1862
- readonly permissionLevel: PermissionLevel.Write;
1863
- }, FilesystemProvider>;
1864
- isAvailable: (provider: FilesystemProvider) => boolean;
1865
- name: "update_knowledge";
1866
- description: "Update knowledge in a knowledge.ai.yml file with smart merging capabilities. This tool lets you add, update, or remove information using path-based updates and special directives.";
1867
- parameters: [{
1868
- readonly name: "path";
1869
- readonly description: "Directory containing (or where to create) the knowledge.ai.yml file";
1870
- readonly required: true;
1871
- readonly usageValue: "Directory path here";
1872
- }, {
1873
- readonly name: "knowledge";
1874
- readonly description: "YAML content to merge into the knowledge file";
1875
- readonly required: true;
1876
- readonly usageValue: "YAML content with knowledge to update";
1877
- }];
1878
- examples: [{
1879
- readonly description: "Add a new file entry";
1880
- readonly parameters: [{
1881
- readonly name: "path";
1882
- readonly value: "src/utils";
1883
- }, {
1884
- readonly name: "knowledge";
1885
- readonly value: "files:\n \"newFile.ts\":\n description: \"A new utility file\"\n api:\n functions:\n 1:\n name: \"processData\"\n params:\n 1: { name: \"data\", type: \"object\" }\n returns: \"object\"";
1886
- }];
1887
- }, {
1888
- readonly description: "Update an existing file description";
1889
- readonly parameters: [{
1890
- readonly name: "path";
1891
- readonly value: "src/utils";
1892
- }, {
1893
- readonly name: "knowledge";
1894
- readonly value: "files:\n \"existingFile.ts\":\n description: \"Updated description for the file\"";
1895
- }];
1896
- }, {
1897
- readonly description: "Add a new rule";
1898
- readonly parameters: [{
1899
- readonly name: "path";
1900
- readonly value: "src";
1901
- }, {
1902
- readonly name: "knowledge";
1903
- readonly value: "rules:\n 10: \"New rule to follow\"";
1904
- }];
1905
- }, {
1906
- readonly description: "Remove a rule";
1907
- readonly parameters: [{
1908
- readonly name: "path";
1909
- readonly value: "src";
1910
- }, {
1911
- readonly name: "knowledge";
1912
- readonly value: "rules:\n 5: null";
1913
- }];
1914
- }, {
1915
- readonly description: "Update nested properties using dot notation";
1916
- readonly parameters: [{
1917
- readonly name: "path";
1918
- readonly value: "src/components";
1919
- }, {
1920
- readonly name: "knowledge";
1921
- readonly value: "files.Button.tsx.api.functions.1.description: \"Updated function description\"";
1922
- }];
1923
- }];
1924
- permissionLevel: PermissionLevel.Write;
1925
- };
1926
- export { _default_9 as default_alias_16 }
1927
- export { _default_9 as updateKnowledge }
1928
- export { _default_9 as updateKnowledge_alias_1 }
1929
- export { _default_9 as updateKnowledge_alias_2 }
1912
+ export { _default_9 as default_alias_15 }
1913
+ export { _default_9 as searchFiles }
1914
+ export { _default_9 as searchFiles_alias_1 }
1915
+ export { _default_9 as searchFiles_alias_2 }
1930
1916
 
1931
1917
  /**
1932
1918
  * AI tool for creating new projects based on user specifications.
@@ -1983,24 +1969,24 @@ export { defaultModels }
1983
1969
  export { defaultModels as defaultModels_alias_1 }
1984
1970
 
1985
1971
  /**
1986
- * Apply multiple edit operations to file content using before/after text anchors
1972
+ * Apply multiple edit operations to file content using search/replace pattern.
1987
1973
  * @param fileContent - The original file content
1988
1974
  * @param operations - Array of edit operations to apply
1989
1975
  * @returns The modified file content
1990
1976
  */
1991
1977
  declare const editFile_2: (fileContent: string, operations: EditOperation[]) => Promise<string>;
1992
1978
  export { editFile_2 as editFileHelper }
1979
+ export { editFile_2 as editFile_alias_2 }
1993
1980
  export { editFile_2 as editFile_alias_3 }
1994
- export { editFile_2 as editFile_alias_4 }
1995
1981
 
1996
1982
  export declare const editingFilesPrompt: (toolNamePrefix: string) => string;
1997
1983
 
1984
+ /**
1985
+ * Edit operation using search/replace pattern
1986
+ */
1998
1987
  declare interface EditOperation {
1999
- start_anchor?: string;
2000
- end_anchor?: string;
2001
- new_text: string;
2002
- start_anchor_line_start?: number;
2003
- end_anchor_line_start?: number;
1988
+ search: string;
1989
+ replace: string;
2004
1990
  }
2005
1991
  export { EditOperation }
2006
1992
  export { EditOperation as EditOperation_alias_1 }
@@ -2540,6 +2526,7 @@ declare class MultiAgent {
2540
2526
  startTask(options: {
2541
2527
  agentName: string;
2542
2528
  task: string;
2529
+ context: string;
2543
2530
  }): Promise<ExitReason>;
2544
2531
  continueTask(userMessage: string): Promise<ExitReason>;
2545
2532
  get hasActiveAgent(): boolean;
@@ -2680,8 +2667,8 @@ export { Policies as Policies_alias_1 }
2680
2667
 
2681
2668
  declare const replaceInFile_2: (fileContent: string, diff: string) => Promise<string>;
2682
2669
  export { replaceInFile_2 as replaceInFileHelper }
2683
- export { replaceInFile_2 as replaceInFile_alias_2 }
2684
2670
  export { replaceInFile_2 as replaceInFile_alias_3 }
2671
+ export { replaceInFile_2 as replaceInFile_alias_4 }
2685
2672
 
2686
2673
  declare const responsePrompts: {
2687
2674
  readonly errorInvokeTool: (tool: string, error: unknown) => string;
@@ -2852,7 +2839,6 @@ declare interface TaskEventToolHandOverDelegate extends TaskEventBase {
2852
2839
  task: string;
2853
2840
  context?: string;
2854
2841
  files?: string[];
2855
- originalTask?: string;
2856
2842
  }
2857
2843
  export { TaskEventToolHandOverDelegate }
2858
2844
  export { TaskEventToolHandOverDelegate as TaskEventToolHandOverDelegate_alias_1 }
@@ -3198,7 +3184,7 @@ export declare const toolInfo_alias_2: {
3198
3184
 
3199
3185
  export declare const toolInfo_alias_3: {
3200
3186
  readonly name: "edit_file";
3201
- readonly description: "Request to edit file contents using before/after text anchors with flexible operations. Supports multiple edit operations in a single call.";
3187
+ readonly description: "Request to edit file contents using search/replace operations. Supports multiple edit operations in a single call.";
3202
3188
  readonly parameters: [{
3203
3189
  readonly name: "path";
3204
3190
  readonly description: "The path of the file to edit";
@@ -3206,48 +3192,32 @@ export declare const toolInfo_alias_3: {
3206
3192
  readonly usageValue: "File path here";
3207
3193
  }, {
3208
3194
  readonly name: "operations";
3209
- readonly description: "Edit operation with start_anchor, end_anchor, new_text, and optional line range hints";
3195
+ readonly description: "Edit operation with search and replace parameters";
3210
3196
  readonly required: true;
3211
3197
  readonly allowMultiple: true;
3212
3198
  readonly children: [{
3213
- readonly name: "start_anchor";
3214
- readonly description: "Text to find as the start anchor (use <<<START_OF_FILE>>> for file start)";
3215
- readonly required: false;
3216
- readonly usageValue: "Text before the edit location";
3217
- }, {
3218
- readonly name: "end_anchor";
3219
- readonly description: "Text to find as the end anchor (use <<<END_OF_FILE>>> for file end)";
3220
- readonly required: false;
3221
- readonly usageValue: "Text after the edit location";
3222
- }, {
3223
- readonly name: "new_text";
3224
- readonly description: "Text to replace the content between start_anchor and end_anchor";
3199
+ readonly name: "search";
3200
+ readonly description: "Text to search for and replace (use <<<START_OF_FILE>>> to insert at file start, <<<END_OF_FILE>>> to insert at file end)";
3225
3201
  readonly required: true;
3226
- readonly usageValue: "New text content";
3202
+ readonly usageValue: "Text to find and replace";
3227
3203
  }, {
3228
- readonly name: "start_anchor_line_start";
3229
- readonly description: "Optional line number hint for start_anchor location (1-based)";
3230
- readonly required: false;
3231
- readonly usageValue: "10";
3232
- }, {
3233
- readonly name: "end_anchor_line_start";
3234
- readonly description: "Optional line number hint for end_anchor location (1-based)";
3235
- readonly required: false;
3236
- readonly usageValue: "20";
3204
+ readonly name: "replace";
3205
+ readonly description: "Text to replace the search text with";
3206
+ readonly required: true;
3207
+ readonly usageValue: "Replacement text";
3237
3208
  }];
3238
3209
  readonly usageValue: "operations here";
3239
3210
  }];
3240
3211
  readonly examples: [{
3241
- readonly description: "Replace content between two text anchors";
3212
+ readonly description: "Replace specific text";
3242
3213
  readonly parameters: [{
3243
3214
  readonly name: "path";
3244
3215
  readonly value: "src/main.ts";
3245
3216
  }, {
3246
3217
  readonly name: "operations";
3247
3218
  readonly value: {
3248
- readonly start_anchor: "function oldFunction() {";
3249
- readonly end_anchor: "}";
3250
- readonly new_text: "\n return \"new implementation\";\n";
3219
+ readonly search: "function oldFunction() {\n return 42;\n}";
3220
+ readonly replace: "function newFunction() {\n return \"new implementation\";\n}";
3251
3221
  };
3252
3222
  }];
3253
3223
  }, {
@@ -3258,9 +3228,8 @@ export declare const toolInfo_alias_3: {
3258
3228
  }, {
3259
3229
  readonly name: "operations";
3260
3230
  readonly value: {
3261
- readonly start_anchor: "<<<START_OF_FILE>>>";
3262
- readonly end_anchor: "export";
3263
- readonly new_text: "// File header comment\n";
3231
+ readonly search: "<<<START_OF_FILE>>>";
3232
+ readonly replace: "// File header comment\n";
3264
3233
  };
3265
3234
  }];
3266
3235
  }, {
@@ -3271,15 +3240,25 @@ export declare const toolInfo_alias_3: {
3271
3240
  }, {
3272
3241
  readonly name: "operations";
3273
3242
  readonly value: [{
3274
- readonly start_anchor: "import React";
3275
- readonly end_anchor: "from \"react\"";
3276
- readonly new_text: ", { useState }";
3243
+ readonly search: "import React from \"react\"";
3244
+ readonly replace: "import React, { useState } from \"react\"";
3277
3245
  }, {
3278
- readonly start_anchor: "function Component() {";
3279
- readonly end_anchor: "return (";
3280
- readonly new_text: "\n const [state, setState] = useState(false);\n ";
3246
+ readonly search: "function Component() {\n return (";
3247
+ readonly replace: "function Component() {\n const [state, setState] = useState(false);\n return (";
3281
3248
  }];
3282
3249
  }];
3250
+ }, {
3251
+ readonly description: "Append content at end of file";
3252
+ readonly parameters: [{
3253
+ readonly name: "path";
3254
+ readonly value: "src/footer.ts";
3255
+ }, {
3256
+ readonly name: "operations";
3257
+ readonly value: {
3258
+ readonly search: "<<<END_OF_FILE>>>";
3259
+ readonly replace: "\n// End of file appended comment\n";
3260
+ };
3261
+ }];
3283
3262
  }];
3284
3263
  readonly permissionLevel: PermissionLevel.Write;
3285
3264
  };
@@ -3489,7 +3468,6 @@ declare type ToolResponseDelegate = {
3489
3468
  task: string;
3490
3469
  context?: string;
3491
3470
  files?: string[];
3492
- originalTask?: string;
3493
3471
  };
3494
3472
  export { ToolResponseDelegate }
3495
3473
  export { ToolResponseDelegate as ToolResponseDelegate_alias_1 }
@@ -3516,7 +3494,6 @@ declare type ToolResponseHandOver = {
3516
3494
  task: string;
3517
3495
  context?: string;
3518
3496
  files?: string[];
3519
- originalTask?: string;
3520
3497
  };
3521
3498
  export { ToolResponseHandOver }
3522
3499
  export { ToolResponseHandOver as ToolResponseHandOver_alias_1 }