@denizokcu/haze 1.2.0 → 1.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +53 -0
- package/README.md +18 -10
- package/SECURITY.md +1 -1
- package/bin/haze.js +27 -7
- package/dist/buildInfo.json +3 -3
- package/dist/cli/chat/inputSuggestions.js +3 -0
- package/dist/cli/chat/liveMessages.d.ts +36 -0
- package/dist/cli/chat/liveMessages.js +64 -0
- package/dist/cli/chat/sessionLifecycle.d.ts +2 -1
- package/dist/cli/chat/sessionLifecycle.js +23 -2
- package/dist/cli/chat/wizard/sessionThemeHandlers.d.ts +1 -1
- package/dist/cli/chat/wizard/sessionThemeHandlers.js +16 -1
- package/dist/cli/commands/chat.js +39 -34
- package/dist/cli/commands/commandHelp.js +2 -0
- package/dist/cli/commands/commands.js +2 -0
- package/dist/cli/commands/formatters.js +5 -1
- package/dist/cli/commands/ndjsonSink.d.ts +12 -0
- package/dist/cli/commands/ndjsonSink.js +29 -0
- package/dist/cli/commands/reasoningCommand.d.ts +35 -0
- package/dist/cli/commands/reasoningCommand.js +46 -0
- package/dist/cli/commands/runCommand.d.ts +14 -0
- package/dist/cli/commands/runCommand.js +37 -11
- package/dist/cli/commands/settingsSummary.js +2 -0
- package/dist/cli/commands/streaming/agentAttempt.d.ts +3 -0
- package/dist/cli/commands/streaming/agentAttempt.js +2 -2
- package/dist/cli/commands/streaming/assistantSegments.d.ts +0 -7
- package/dist/cli/commands/streaming/assistantSegments.js +1 -1
- package/dist/cli/commands/streaming/attemptLifecycle.js +13 -9
- package/dist/cli/commands/streaming/attemptOutcome.js +13 -3
- package/dist/cli/commands/streaming/attemptSetup.d.ts +3 -0
- package/dist/cli/commands/streaming/attemptSetup.js +11 -3
- package/dist/cli/commands/streaming/goalCheckpoint.d.ts +6 -0
- package/dist/cli/commands/streaming/goalCheckpoint.js +1 -0
- package/dist/cli/commands/streaming/goalSupervisor.d.ts +5 -0
- package/dist/cli/commands/streaming/goalSupervisor.js +9 -4
- package/dist/cli/commands/streaming/prepareStep.d.ts +0 -3
- package/dist/cli/commands/streaming/prepareStep.js +8 -3
- package/dist/cli/commands/streaming.d.ts +7 -2
- package/dist/cli/commands/streaming.js +24 -5
- package/dist/cli/commands/wizardFlow.d.ts +7 -0
- package/dist/cli/commands/wizardFlow.js +22 -0
- package/dist/cli/index.js +5 -1
- package/dist/config/modelDiscovery.js +68 -5
- package/dist/config/settings.d.ts +8 -4
- package/dist/config/settings.js +8 -1
- package/dist/core/agent/budgets.d.ts +0 -2
- package/dist/core/agent/budgets.js +0 -2
- package/dist/core/agent/completionController.d.ts +8 -0
- package/dist/core/agent/completionController.js +32 -0
- package/dist/core/agent/events.d.ts +2 -1
- package/dist/core/agent/goalPolicy.d.ts +7 -0
- package/dist/core/agent/goalPolicy.js +9 -0
- package/dist/core/agent/reasoningPolicy.d.ts +45 -9
- package/dist/core/agent/reasoningPolicy.js +49 -9
- package/dist/core/agent/toolCapabilities.d.ts +3 -3
- package/dist/core/agent/toolCapabilities.js +31 -7
- package/dist/core/agent/workState.d.ts +6 -4
- package/dist/core/agent/workState.js +40 -28
- package/dist/core/deadline.js +22 -24
- package/dist/core/safety/secretPaths.js +10 -7
- package/dist/core/safety/shellClassifier.d.ts +2 -0
- package/dist/core/safety/shellClassifier.js +9 -1
- package/dist/core/session/sessionSlimming.d.ts +2 -0
- package/dist/core/session/sessionSlimming.js +50 -1
- package/dist/core/session/sessionStore.d.ts +4 -8
- package/dist/core/session/sessionStore.js +53 -32
- package/dist/core/shellOutput/reducers/git.js +7 -2
- package/dist/core/shellOutput/reducers/validation.d.ts +1 -1
- package/dist/core/shellOutput/reducers/validation.js +14 -1
- package/dist/core/shellOutput/registry.js +3 -2
- package/dist/core/subagent/contracts.d.ts +8 -1
- package/dist/core/subagent/subagentRunner.d.ts +4 -0
- package/dist/core/subagent/subagentRunner.js +33 -25
- package/dist/core/tasks/taskStorage.js +8 -1
- package/dist/core/validation/outputParser.js +24 -0
- package/dist/llm/client.d.ts +2 -1
- package/dist/llm/client.js +20 -10
- package/dist/llm/hazeTools.d.ts +2039 -16
- package/dist/llm/hazeTools.js +43 -2
- package/dist/llm/lsp/client.d.ts +7 -1
- package/dist/llm/lsp/client.js +58 -9
- package/dist/llm/lsp/pool.d.ts +11 -0
- package/dist/llm/lsp/pool.js +61 -4
- package/dist/llm/lsp/protocol.d.ts +6 -23
- package/dist/llm/lsp/requests.d.ts +54 -60
- package/dist/llm/lsp/requests.js +152 -28
- package/dist/llm/lsp/symbols.d.ts +16 -0
- package/dist/llm/lsp/symbols.js +70 -0
- package/dist/llm/lsp/workspaceEdit.d.ts +43 -0
- package/dist/llm/lsp/workspaceEdit.js +117 -0
- package/dist/llm/lspTools.d.ts +7518 -2859
- package/dist/llm/lspTools.js +195 -110
- package/dist/llm/requestContext.d.ts +3 -2
- package/dist/llm/requestContext.js +8 -4
- package/dist/llm/systemPrompt.js +2 -2
- package/dist/llm/tools/fetchTool.d.ts +4 -0
- package/dist/llm/tools/processTool.d.ts +4 -0
- package/dist/llm/tools/replaceInFiles.d.ts +105 -0
- package/dist/llm/tools/replaceInFiles.js +131 -0
- package/dist/llm/tools/shellTool.d.ts +4 -0
- package/dist/llm/tools/storedOutputTool.d.ts +4 -0
- package/dist/llm/tools/taskTool.d.ts +4 -0
- package/dist/llm/tools/toolContext.d.ts +3 -0
- package/dist/llm/tools/toolContext.js +26 -4
- package/dist/skills/SkillLoader.js +27 -1
- package/dist/ui/components/useInputSuggestions.js +18 -6
- package/dist/utils/buildInfo.js +29 -8
- package/dist/utils/fs.js +5 -1
- package/package.json +19 -19
package/dist/llm/hazeTools.d.ts
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import type { ToolDiffLine } from './toolResultTypes.js';
|
|
2
2
|
export declare const hazeTools: {
|
|
3
3
|
listFiles: ({
|
|
4
|
+
deferLoading?: boolean;
|
|
4
5
|
title?: string;
|
|
5
6
|
providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
|
|
6
7
|
metadata?: import("@ai-sdk/provider").JSONObject;
|
|
@@ -74,7 +75,15 @@ export declare const hazeTools: {
|
|
|
74
75
|
truncated: boolean;
|
|
75
76
|
} & {
|
|
76
77
|
applicableProjectInstructions?: import("../config/contextFiles.js").ContextFile[];
|
|
77
|
-
})
|
|
78
|
+
}) | {
|
|
79
|
+
ok: boolean;
|
|
80
|
+
toolName: string;
|
|
81
|
+
path: string;
|
|
82
|
+
error: string;
|
|
83
|
+
reasonCode: "outside_workspace";
|
|
84
|
+
recoverable: boolean;
|
|
85
|
+
suggestedNextStep: string;
|
|
86
|
+
}>;
|
|
78
87
|
}) => import("@ai-sdk/provider-utils").ToolResultOutput | PromiseLike<import("@ai-sdk/provider-utils").ToolResultOutput>) | undefined;
|
|
79
88
|
} & {
|
|
80
89
|
outputSchema?: import("ai").FlexibleSchema<{
|
|
@@ -106,7 +115,15 @@ export declare const hazeTools: {
|
|
|
106
115
|
truncated: boolean;
|
|
107
116
|
} & {
|
|
108
117
|
applicableProjectInstructions?: import("../config/contextFiles.js").ContextFile[];
|
|
109
|
-
})
|
|
118
|
+
}) | {
|
|
119
|
+
ok: boolean;
|
|
120
|
+
toolName: string;
|
|
121
|
+
path: string;
|
|
122
|
+
error: string;
|
|
123
|
+
reasonCode: "outside_workspace";
|
|
124
|
+
recoverable: boolean;
|
|
125
|
+
suggestedNextStep: string;
|
|
126
|
+
}> | undefined;
|
|
110
127
|
execute: import("ai").ToolExecuteFunction<{
|
|
111
128
|
path: string;
|
|
112
129
|
recursive: boolean;
|
|
@@ -143,7 +160,15 @@ export declare const hazeTools: {
|
|
|
143
160
|
truncated: boolean;
|
|
144
161
|
} & {
|
|
145
162
|
applicableProjectInstructions?: import("../config/contextFiles.js").ContextFile[];
|
|
146
|
-
})
|
|
163
|
+
}) | {
|
|
164
|
+
ok: boolean;
|
|
165
|
+
toolName: string;
|
|
166
|
+
path: string;
|
|
167
|
+
error: string;
|
|
168
|
+
reasonCode: "outside_workspace";
|
|
169
|
+
recoverable: boolean;
|
|
170
|
+
suggestedNextStep: string;
|
|
171
|
+
}, NoInfer<import("./tools/toolContext.js").HazeToolContext>>;
|
|
147
172
|
} & {
|
|
148
173
|
description?: string | ((options: {
|
|
149
174
|
context: NoInfer<import("./tools/toolContext.js").HazeToolContext>;
|
|
@@ -203,8 +228,17 @@ export declare const hazeTools: {
|
|
|
203
228
|
truncated: boolean;
|
|
204
229
|
} & {
|
|
205
230
|
applicableProjectInstructions?: import("../config/contextFiles.js").ContextFile[];
|
|
206
|
-
})
|
|
231
|
+
}) | {
|
|
232
|
+
ok: boolean;
|
|
233
|
+
toolName: string;
|
|
234
|
+
path: string;
|
|
235
|
+
error: string;
|
|
236
|
+
reasonCode: "outside_workspace";
|
|
237
|
+
recoverable: boolean;
|
|
238
|
+
suggestedNextStep: string;
|
|
239
|
+
}, NoInfer<import("./tools/toolContext.js").HazeToolContext>>;
|
|
207
240
|
}) | ({
|
|
241
|
+
deferLoading?: boolean;
|
|
208
242
|
title?: string;
|
|
209
243
|
providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
|
|
210
244
|
metadata?: import("@ai-sdk/provider").JSONObject;
|
|
@@ -278,7 +312,15 @@ export declare const hazeTools: {
|
|
|
278
312
|
truncated: boolean;
|
|
279
313
|
} & {
|
|
280
314
|
applicableProjectInstructions?: import("../config/contextFiles.js").ContextFile[];
|
|
281
|
-
})
|
|
315
|
+
}) | {
|
|
316
|
+
ok: boolean;
|
|
317
|
+
toolName: string;
|
|
318
|
+
path: string;
|
|
319
|
+
error: string;
|
|
320
|
+
reasonCode: "outside_workspace";
|
|
321
|
+
recoverable: boolean;
|
|
322
|
+
suggestedNextStep: string;
|
|
323
|
+
}>;
|
|
282
324
|
}) => import("@ai-sdk/provider-utils").ToolResultOutput | PromiseLike<import("@ai-sdk/provider-utils").ToolResultOutput>) | undefined;
|
|
283
325
|
} & {
|
|
284
326
|
outputSchema?: import("ai").FlexibleSchema<{
|
|
@@ -310,7 +352,15 @@ export declare const hazeTools: {
|
|
|
310
352
|
truncated: boolean;
|
|
311
353
|
} & {
|
|
312
354
|
applicableProjectInstructions?: import("../config/contextFiles.js").ContextFile[];
|
|
313
|
-
})
|
|
355
|
+
}) | {
|
|
356
|
+
ok: boolean;
|
|
357
|
+
toolName: string;
|
|
358
|
+
path: string;
|
|
359
|
+
error: string;
|
|
360
|
+
reasonCode: "outside_workspace";
|
|
361
|
+
recoverable: boolean;
|
|
362
|
+
suggestedNextStep: string;
|
|
363
|
+
}> | undefined;
|
|
314
364
|
execute: import("ai").ToolExecuteFunction<{
|
|
315
365
|
path: string;
|
|
316
366
|
recursive: boolean;
|
|
@@ -347,7 +397,15 @@ export declare const hazeTools: {
|
|
|
347
397
|
truncated: boolean;
|
|
348
398
|
} & {
|
|
349
399
|
applicableProjectInstructions?: import("../config/contextFiles.js").ContextFile[];
|
|
350
|
-
})
|
|
400
|
+
}) | {
|
|
401
|
+
ok: boolean;
|
|
402
|
+
toolName: string;
|
|
403
|
+
path: string;
|
|
404
|
+
error: string;
|
|
405
|
+
reasonCode: "outside_workspace";
|
|
406
|
+
recoverable: boolean;
|
|
407
|
+
suggestedNextStep: string;
|
|
408
|
+
}, NoInfer<import("./tools/toolContext.js").HazeToolContext>>;
|
|
351
409
|
} & {
|
|
352
410
|
description?: string | ((options: {
|
|
353
411
|
context: NoInfer<import("./tools/toolContext.js").HazeToolContext>;
|
|
@@ -407,8 +465,17 @@ export declare const hazeTools: {
|
|
|
407
465
|
truncated: boolean;
|
|
408
466
|
} & {
|
|
409
467
|
applicableProjectInstructions?: import("../config/contextFiles.js").ContextFile[];
|
|
410
|
-
})
|
|
468
|
+
}) | {
|
|
469
|
+
ok: boolean;
|
|
470
|
+
toolName: string;
|
|
471
|
+
path: string;
|
|
472
|
+
error: string;
|
|
473
|
+
reasonCode: "outside_workspace";
|
|
474
|
+
recoverable: boolean;
|
|
475
|
+
suggestedNextStep: string;
|
|
476
|
+
}, NoInfer<import("./tools/toolContext.js").HazeToolContext>>;
|
|
411
477
|
}) | ({
|
|
478
|
+
deferLoading?: boolean;
|
|
412
479
|
title?: string;
|
|
413
480
|
providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
|
|
414
481
|
metadata?: import("@ai-sdk/provider").JSONObject;
|
|
@@ -482,7 +549,15 @@ export declare const hazeTools: {
|
|
|
482
549
|
truncated: boolean;
|
|
483
550
|
} & {
|
|
484
551
|
applicableProjectInstructions?: import("../config/contextFiles.js").ContextFile[];
|
|
485
|
-
})
|
|
552
|
+
}) | {
|
|
553
|
+
ok: boolean;
|
|
554
|
+
toolName: string;
|
|
555
|
+
path: string;
|
|
556
|
+
error: string;
|
|
557
|
+
reasonCode: "outside_workspace";
|
|
558
|
+
recoverable: boolean;
|
|
559
|
+
suggestedNextStep: string;
|
|
560
|
+
}>;
|
|
486
561
|
}) => import("@ai-sdk/provider-utils").ToolResultOutput | PromiseLike<import("@ai-sdk/provider-utils").ToolResultOutput>) | undefined;
|
|
487
562
|
} & {
|
|
488
563
|
outputSchema?: import("ai").FlexibleSchema<{
|
|
@@ -514,7 +589,15 @@ export declare const hazeTools: {
|
|
|
514
589
|
truncated: boolean;
|
|
515
590
|
} & {
|
|
516
591
|
applicableProjectInstructions?: import("../config/contextFiles.js").ContextFile[];
|
|
517
|
-
})
|
|
592
|
+
}) | {
|
|
593
|
+
ok: boolean;
|
|
594
|
+
toolName: string;
|
|
595
|
+
path: string;
|
|
596
|
+
error: string;
|
|
597
|
+
reasonCode: "outside_workspace";
|
|
598
|
+
recoverable: boolean;
|
|
599
|
+
suggestedNextStep: string;
|
|
600
|
+
}> | undefined;
|
|
518
601
|
execute: import("ai").ToolExecuteFunction<{
|
|
519
602
|
path: string;
|
|
520
603
|
recursive: boolean;
|
|
@@ -551,7 +634,15 @@ export declare const hazeTools: {
|
|
|
551
634
|
truncated: boolean;
|
|
552
635
|
} & {
|
|
553
636
|
applicableProjectInstructions?: import("../config/contextFiles.js").ContextFile[];
|
|
554
|
-
})
|
|
637
|
+
}) | {
|
|
638
|
+
ok: boolean;
|
|
639
|
+
toolName: string;
|
|
640
|
+
path: string;
|
|
641
|
+
error: string;
|
|
642
|
+
reasonCode: "outside_workspace";
|
|
643
|
+
recoverable: boolean;
|
|
644
|
+
suggestedNextStep: string;
|
|
645
|
+
}, NoInfer<import("./tools/toolContext.js").HazeToolContext>>;
|
|
555
646
|
} & {
|
|
556
647
|
type: "provider";
|
|
557
648
|
id: `${string}.${string}`;
|
|
@@ -599,8 +690,17 @@ export declare const hazeTools: {
|
|
|
599
690
|
truncated: boolean;
|
|
600
691
|
} & {
|
|
601
692
|
applicableProjectInstructions?: import("../config/contextFiles.js").ContextFile[];
|
|
602
|
-
})
|
|
693
|
+
}) | {
|
|
694
|
+
ok: boolean;
|
|
695
|
+
toolName: string;
|
|
696
|
+
path: string;
|
|
697
|
+
error: string;
|
|
698
|
+
reasonCode: "outside_workspace";
|
|
699
|
+
recoverable: boolean;
|
|
700
|
+
suggestedNextStep: string;
|
|
701
|
+
}, NoInfer<import("./tools/toolContext.js").HazeToolContext>>;
|
|
603
702
|
}) | ({
|
|
703
|
+
deferLoading?: boolean;
|
|
604
704
|
title?: string;
|
|
605
705
|
providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
|
|
606
706
|
metadata?: import("@ai-sdk/provider").JSONObject;
|
|
@@ -674,7 +774,15 @@ export declare const hazeTools: {
|
|
|
674
774
|
truncated: boolean;
|
|
675
775
|
} & {
|
|
676
776
|
applicableProjectInstructions?: import("../config/contextFiles.js").ContextFile[];
|
|
677
|
-
})
|
|
777
|
+
}) | {
|
|
778
|
+
ok: boolean;
|
|
779
|
+
toolName: string;
|
|
780
|
+
path: string;
|
|
781
|
+
error: string;
|
|
782
|
+
reasonCode: "outside_workspace";
|
|
783
|
+
recoverable: boolean;
|
|
784
|
+
suggestedNextStep: string;
|
|
785
|
+
}>;
|
|
678
786
|
}) => import("@ai-sdk/provider-utils").ToolResultOutput | PromiseLike<import("@ai-sdk/provider-utils").ToolResultOutput>) | undefined;
|
|
679
787
|
} & {
|
|
680
788
|
outputSchema?: import("ai").FlexibleSchema<{
|
|
@@ -706,7 +814,15 @@ export declare const hazeTools: {
|
|
|
706
814
|
truncated: boolean;
|
|
707
815
|
} & {
|
|
708
816
|
applicableProjectInstructions?: import("../config/contextFiles.js").ContextFile[];
|
|
709
|
-
})
|
|
817
|
+
}) | {
|
|
818
|
+
ok: boolean;
|
|
819
|
+
toolName: string;
|
|
820
|
+
path: string;
|
|
821
|
+
error: string;
|
|
822
|
+
reasonCode: "outside_workspace";
|
|
823
|
+
recoverable: boolean;
|
|
824
|
+
suggestedNextStep: string;
|
|
825
|
+
}> | undefined;
|
|
710
826
|
execute: import("ai").ToolExecuteFunction<{
|
|
711
827
|
path: string;
|
|
712
828
|
recursive: boolean;
|
|
@@ -743,7 +859,15 @@ export declare const hazeTools: {
|
|
|
743
859
|
truncated: boolean;
|
|
744
860
|
} & {
|
|
745
861
|
applicableProjectInstructions?: import("../config/contextFiles.js").ContextFile[];
|
|
746
|
-
})
|
|
862
|
+
}) | {
|
|
863
|
+
ok: boolean;
|
|
864
|
+
toolName: string;
|
|
865
|
+
path: string;
|
|
866
|
+
error: string;
|
|
867
|
+
reasonCode: "outside_workspace";
|
|
868
|
+
recoverable: boolean;
|
|
869
|
+
suggestedNextStep: string;
|
|
870
|
+
}, NoInfer<import("./tools/toolContext.js").HazeToolContext>>;
|
|
747
871
|
} & {
|
|
748
872
|
type: "provider";
|
|
749
873
|
id: `${string}.${string}`;
|
|
@@ -791,9 +915,18 @@ export declare const hazeTools: {
|
|
|
791
915
|
truncated: boolean;
|
|
792
916
|
} & {
|
|
793
917
|
applicableProjectInstructions?: import("../config/contextFiles.js").ContextFile[];
|
|
794
|
-
})
|
|
918
|
+
}) | {
|
|
919
|
+
ok: boolean;
|
|
920
|
+
toolName: string;
|
|
921
|
+
path: string;
|
|
922
|
+
error: string;
|
|
923
|
+
reasonCode: "outside_workspace";
|
|
924
|
+
recoverable: boolean;
|
|
925
|
+
suggestedNextStep: string;
|
|
926
|
+
}, NoInfer<import("./tools/toolContext.js").HazeToolContext>>;
|
|
795
927
|
});
|
|
796
928
|
readFile: ({
|
|
929
|
+
deferLoading?: boolean;
|
|
797
930
|
title?: string;
|
|
798
931
|
providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
|
|
799
932
|
metadata?: import("@ai-sdk/provider").JSONObject;
|
|
@@ -1003,6 +1136,7 @@ export declare const hazeTools: {
|
|
|
1003
1136
|
applicableProjectInstructions?: import("../config/contextFiles.js").ContextFile[];
|
|
1004
1137
|
}), NoInfer<import("./tools/toolContext.js").HazeToolContext>>;
|
|
1005
1138
|
}) | ({
|
|
1139
|
+
deferLoading?: boolean;
|
|
1006
1140
|
title?: string;
|
|
1007
1141
|
providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
|
|
1008
1142
|
metadata?: import("@ai-sdk/provider").JSONObject;
|
|
@@ -1212,6 +1346,7 @@ export declare const hazeTools: {
|
|
|
1212
1346
|
applicableProjectInstructions?: import("../config/contextFiles.js").ContextFile[];
|
|
1213
1347
|
}), NoInfer<import("./tools/toolContext.js").HazeToolContext>>;
|
|
1214
1348
|
}) | ({
|
|
1349
|
+
deferLoading?: boolean;
|
|
1215
1350
|
title?: string;
|
|
1216
1351
|
providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
|
|
1217
1352
|
metadata?: import("@ai-sdk/provider").JSONObject;
|
|
@@ -1410,6 +1545,7 @@ export declare const hazeTools: {
|
|
|
1410
1545
|
applicableProjectInstructions?: import("../config/contextFiles.js").ContextFile[];
|
|
1411
1546
|
}), NoInfer<import("./tools/toolContext.js").HazeToolContext>>;
|
|
1412
1547
|
}) | ({
|
|
1548
|
+
deferLoading?: boolean;
|
|
1413
1549
|
title?: string;
|
|
1414
1550
|
providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
|
|
1415
1551
|
metadata?: import("@ai-sdk/provider").JSONObject;
|
|
@@ -1609,6 +1745,7 @@ export declare const hazeTools: {
|
|
|
1609
1745
|
}), NoInfer<import("./tools/toolContext.js").HazeToolContext>>;
|
|
1610
1746
|
});
|
|
1611
1747
|
grep: ({
|
|
1748
|
+
deferLoading?: boolean;
|
|
1612
1749
|
title?: string;
|
|
1613
1750
|
providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
|
|
1614
1751
|
metadata?: import("@ai-sdk/provider").JSONObject;
|
|
@@ -1936,6 +2073,7 @@ export declare const hazeTools: {
|
|
|
1936
2073
|
applicableProjectInstructions?: import("../config/contextFiles.js").ContextFile[];
|
|
1937
2074
|
}), NoInfer<import("./tools/toolContext.js").HazeToolContext>>;
|
|
1938
2075
|
}) | ({
|
|
2076
|
+
deferLoading?: boolean;
|
|
1939
2077
|
title?: string;
|
|
1940
2078
|
providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
|
|
1941
2079
|
metadata?: import("@ai-sdk/provider").JSONObject;
|
|
@@ -2263,6 +2401,7 @@ export declare const hazeTools: {
|
|
|
2263
2401
|
applicableProjectInstructions?: import("../config/contextFiles.js").ContextFile[];
|
|
2264
2402
|
}), NoInfer<import("./tools/toolContext.js").HazeToolContext>>;
|
|
2265
2403
|
}) | ({
|
|
2404
|
+
deferLoading?: boolean;
|
|
2266
2405
|
title?: string;
|
|
2267
2406
|
providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
|
|
2268
2407
|
metadata?: import("@ai-sdk/provider").JSONObject;
|
|
@@ -2577,6 +2716,7 @@ export declare const hazeTools: {
|
|
|
2577
2716
|
applicableProjectInstructions?: import("../config/contextFiles.js").ContextFile[];
|
|
2578
2717
|
}), NoInfer<import("./tools/toolContext.js").HazeToolContext>>;
|
|
2579
2718
|
}) | ({
|
|
2719
|
+
deferLoading?: boolean;
|
|
2580
2720
|
title?: string;
|
|
2581
2721
|
providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
|
|
2582
2722
|
metadata?: import("@ai-sdk/provider").JSONObject;
|
|
@@ -2891,7 +3031,1859 @@ export declare const hazeTools: {
|
|
|
2891
3031
|
applicableProjectInstructions?: import("../config/contextFiles.js").ContextFile[];
|
|
2892
3032
|
}), NoInfer<import("./tools/toolContext.js").HazeToolContext>>;
|
|
2893
3033
|
});
|
|
3034
|
+
replaceInFiles: ({
|
|
3035
|
+
deferLoading?: boolean;
|
|
3036
|
+
title?: string;
|
|
3037
|
+
providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
|
|
3038
|
+
metadata?: import("@ai-sdk/provider").JSONObject;
|
|
3039
|
+
inputSchema: import("ai").FlexibleSchema<{
|
|
3040
|
+
path: string;
|
|
3041
|
+
needle: string;
|
|
3042
|
+
replacement: string;
|
|
3043
|
+
mode: "literal" | "regex";
|
|
3044
|
+
dryRun: boolean;
|
|
3045
|
+
includeGlob?: string | undefined;
|
|
3046
|
+
excludeGlob?: string | undefined;
|
|
3047
|
+
occurrenceIds?: string[] | undefined;
|
|
3048
|
+
expectedCount?: number | undefined;
|
|
3049
|
+
}>;
|
|
3050
|
+
contextSchema?: import("ai").FlexibleSchema<import("./tools/toolContext.js").HazeToolContext> | undefined;
|
|
3051
|
+
needsApproval?: boolean | import("@ai-sdk/provider-utils").ToolNeedsApprovalFunction<{
|
|
3052
|
+
path: string;
|
|
3053
|
+
needle: string;
|
|
3054
|
+
replacement: string;
|
|
3055
|
+
mode: "literal" | "regex";
|
|
3056
|
+
dryRun: boolean;
|
|
3057
|
+
includeGlob?: string | undefined;
|
|
3058
|
+
excludeGlob?: string | undefined;
|
|
3059
|
+
occurrenceIds?: string[] | undefined;
|
|
3060
|
+
expectedCount?: number | undefined;
|
|
3061
|
+
}, NoInfer<import("./tools/toolContext.js").HazeToolContext>> | undefined;
|
|
3062
|
+
onInputStart?: ((options: import("ai").ToolExecutionOptions<NoInfer<import("./tools/toolContext.js").HazeToolContext>>) => void | PromiseLike<void>) | undefined;
|
|
3063
|
+
onInputDelta?: ((options: {
|
|
3064
|
+
inputTextDelta: string;
|
|
3065
|
+
} & import("ai").ToolExecutionOptions<NoInfer<import("./tools/toolContext.js").HazeToolContext>>) => void | PromiseLike<void>) | undefined;
|
|
3066
|
+
onInputAvailable?: ((options: {
|
|
3067
|
+
input: {
|
|
3068
|
+
path: string;
|
|
3069
|
+
needle: string;
|
|
3070
|
+
replacement: string;
|
|
3071
|
+
mode: "literal" | "regex";
|
|
3072
|
+
dryRun: boolean;
|
|
3073
|
+
includeGlob?: string | undefined;
|
|
3074
|
+
excludeGlob?: string | undefined;
|
|
3075
|
+
occurrenceIds?: string[] | undefined;
|
|
3076
|
+
expectedCount?: number | undefined;
|
|
3077
|
+
};
|
|
3078
|
+
} & import("ai").ToolExecutionOptions<NoInfer<import("./tools/toolContext.js").HazeToolContext>>) => void | PromiseLike<void>) | undefined;
|
|
3079
|
+
toModelOutput?: ((options: {
|
|
3080
|
+
toolCallId: string;
|
|
3081
|
+
input: {
|
|
3082
|
+
path: string;
|
|
3083
|
+
needle: string;
|
|
3084
|
+
replacement: string;
|
|
3085
|
+
mode: "literal" | "regex";
|
|
3086
|
+
dryRun: boolean;
|
|
3087
|
+
includeGlob?: string | undefined;
|
|
3088
|
+
excludeGlob?: string | undefined;
|
|
3089
|
+
occurrenceIds?: string[] | undefined;
|
|
3090
|
+
expectedCount?: number | undefined;
|
|
3091
|
+
};
|
|
3092
|
+
output: NoInfer<{
|
|
3093
|
+
suggestedPaths?: string[] | undefined;
|
|
3094
|
+
ok: boolean;
|
|
3095
|
+
toolName: string;
|
|
3096
|
+
path: string | undefined;
|
|
3097
|
+
error: string;
|
|
3098
|
+
reasonCode: import("./toolResultTypes.js").ToolFailureReasonCode | undefined;
|
|
3099
|
+
recoverable: boolean;
|
|
3100
|
+
suggestedNextStep: string;
|
|
3101
|
+
recoveryTool: string | undefined;
|
|
3102
|
+
recoveryInput: unknown;
|
|
3103
|
+
} | {
|
|
3104
|
+
ok: boolean;
|
|
3105
|
+
toolName: string;
|
|
3106
|
+
path: string;
|
|
3107
|
+
error: string;
|
|
3108
|
+
reasonCode: "scoped_instructions_discovered";
|
|
3109
|
+
recoverable: boolean;
|
|
3110
|
+
suggestedNextStep: string;
|
|
3111
|
+
applicableProjectInstructions: import("../config/contextFiles.js").ContextFile[];
|
|
3112
|
+
} | {
|
|
3113
|
+
ok: true;
|
|
3114
|
+
duplicateSkipped: true;
|
|
3115
|
+
toolName: string;
|
|
3116
|
+
reason: string;
|
|
3117
|
+
} | {
|
|
3118
|
+
occurrenceHandle?: string | undefined;
|
|
3119
|
+
skippedFiles: number;
|
|
3120
|
+
occurrences: {
|
|
3121
|
+
before: string;
|
|
3122
|
+
after: string;
|
|
3123
|
+
id: string;
|
|
3124
|
+
path: string;
|
|
3125
|
+
line: number;
|
|
3126
|
+
}[];
|
|
3127
|
+
occurrencesTruncated: boolean;
|
|
3128
|
+
ok: boolean;
|
|
3129
|
+
dryRun: boolean;
|
|
3130
|
+
occurrenceCount: number;
|
|
3131
|
+
fileCount: number;
|
|
3132
|
+
error?: undefined;
|
|
3133
|
+
staleOccurrenceIds?: undefined;
|
|
3134
|
+
recoverable?: undefined;
|
|
3135
|
+
suggestedNextStep?: undefined;
|
|
3136
|
+
changedPaths?: undefined;
|
|
3137
|
+
uncertainPaths?: undefined;
|
|
3138
|
+
} | {
|
|
3139
|
+
ok: boolean;
|
|
3140
|
+
error: string;
|
|
3141
|
+
staleOccurrenceIds: string[];
|
|
3142
|
+
recoverable: boolean;
|
|
3143
|
+
suggestedNextStep: string;
|
|
3144
|
+
changedPaths?: undefined;
|
|
3145
|
+
uncertainPaths?: undefined;
|
|
3146
|
+
} | {
|
|
3147
|
+
ok: boolean;
|
|
3148
|
+
error: string;
|
|
3149
|
+
recoverable: boolean;
|
|
3150
|
+
staleOccurrenceIds?: undefined;
|
|
3151
|
+
suggestedNextStep?: undefined;
|
|
3152
|
+
changedPaths?: undefined;
|
|
3153
|
+
uncertainPaths?: undefined;
|
|
3154
|
+
} | {
|
|
3155
|
+
ok: boolean;
|
|
3156
|
+
changedPaths: string[];
|
|
3157
|
+
uncertainPaths: string[];
|
|
3158
|
+
error: string;
|
|
3159
|
+
recoverable: boolean;
|
|
3160
|
+
suggestedNextStep: string;
|
|
3161
|
+
staleOccurrenceIds?: undefined;
|
|
3162
|
+
} | {
|
|
3163
|
+
diffHandle?: string | undefined;
|
|
3164
|
+
ok: boolean;
|
|
3165
|
+
dryRun: boolean;
|
|
3166
|
+
changedPaths: string[];
|
|
3167
|
+
noChange: boolean;
|
|
3168
|
+
occurrenceCount: number;
|
|
3169
|
+
fileCount: number;
|
|
3170
|
+
diffLineCount: number;
|
|
3171
|
+
files: {
|
|
3172
|
+
diff: ToolDiffLine[];
|
|
3173
|
+
addedLines: number;
|
|
3174
|
+
removedLines: number;
|
|
3175
|
+
path: string;
|
|
3176
|
+
}[];
|
|
3177
|
+
error?: undefined;
|
|
3178
|
+
staleOccurrenceIds?: undefined;
|
|
3179
|
+
recoverable?: undefined;
|
|
3180
|
+
suggestedNextStep?: undefined;
|
|
3181
|
+
uncertainPaths?: undefined;
|
|
3182
|
+
}>;
|
|
3183
|
+
}) => import("@ai-sdk/provider-utils").ToolResultOutput | PromiseLike<import("@ai-sdk/provider-utils").ToolResultOutput>) | undefined;
|
|
3184
|
+
} & {
|
|
3185
|
+
outputSchema?: import("ai").FlexibleSchema<{
|
|
3186
|
+
suggestedPaths?: string[] | undefined;
|
|
3187
|
+
ok: boolean;
|
|
3188
|
+
toolName: string;
|
|
3189
|
+
path: string | undefined;
|
|
3190
|
+
error: string;
|
|
3191
|
+
reasonCode: import("./toolResultTypes.js").ToolFailureReasonCode | undefined;
|
|
3192
|
+
recoverable: boolean;
|
|
3193
|
+
suggestedNextStep: string;
|
|
3194
|
+
recoveryTool: string | undefined;
|
|
3195
|
+
recoveryInput: unknown;
|
|
3196
|
+
} | {
|
|
3197
|
+
ok: boolean;
|
|
3198
|
+
toolName: string;
|
|
3199
|
+
path: string;
|
|
3200
|
+
error: string;
|
|
3201
|
+
reasonCode: "scoped_instructions_discovered";
|
|
3202
|
+
recoverable: boolean;
|
|
3203
|
+
suggestedNextStep: string;
|
|
3204
|
+
applicableProjectInstructions: import("../config/contextFiles.js").ContextFile[];
|
|
3205
|
+
} | {
|
|
3206
|
+
ok: true;
|
|
3207
|
+
duplicateSkipped: true;
|
|
3208
|
+
toolName: string;
|
|
3209
|
+
reason: string;
|
|
3210
|
+
} | {
|
|
3211
|
+
occurrenceHandle?: string | undefined;
|
|
3212
|
+
skippedFiles: number;
|
|
3213
|
+
occurrences: {
|
|
3214
|
+
before: string;
|
|
3215
|
+
after: string;
|
|
3216
|
+
id: string;
|
|
3217
|
+
path: string;
|
|
3218
|
+
line: number;
|
|
3219
|
+
}[];
|
|
3220
|
+
occurrencesTruncated: boolean;
|
|
3221
|
+
ok: boolean;
|
|
3222
|
+
dryRun: boolean;
|
|
3223
|
+
occurrenceCount: number;
|
|
3224
|
+
fileCount: number;
|
|
3225
|
+
error?: undefined;
|
|
3226
|
+
staleOccurrenceIds?: undefined;
|
|
3227
|
+
recoverable?: undefined;
|
|
3228
|
+
suggestedNextStep?: undefined;
|
|
3229
|
+
changedPaths?: undefined;
|
|
3230
|
+
uncertainPaths?: undefined;
|
|
3231
|
+
} | {
|
|
3232
|
+
ok: boolean;
|
|
3233
|
+
error: string;
|
|
3234
|
+
staleOccurrenceIds: string[];
|
|
3235
|
+
recoverable: boolean;
|
|
3236
|
+
suggestedNextStep: string;
|
|
3237
|
+
changedPaths?: undefined;
|
|
3238
|
+
uncertainPaths?: undefined;
|
|
3239
|
+
} | {
|
|
3240
|
+
ok: boolean;
|
|
3241
|
+
error: string;
|
|
3242
|
+
recoverable: boolean;
|
|
3243
|
+
staleOccurrenceIds?: undefined;
|
|
3244
|
+
suggestedNextStep?: undefined;
|
|
3245
|
+
changedPaths?: undefined;
|
|
3246
|
+
uncertainPaths?: undefined;
|
|
3247
|
+
} | {
|
|
3248
|
+
ok: boolean;
|
|
3249
|
+
changedPaths: string[];
|
|
3250
|
+
uncertainPaths: string[];
|
|
3251
|
+
error: string;
|
|
3252
|
+
recoverable: boolean;
|
|
3253
|
+
suggestedNextStep: string;
|
|
3254
|
+
staleOccurrenceIds?: undefined;
|
|
3255
|
+
} | {
|
|
3256
|
+
diffHandle?: string | undefined;
|
|
3257
|
+
ok: boolean;
|
|
3258
|
+
dryRun: boolean;
|
|
3259
|
+
changedPaths: string[];
|
|
3260
|
+
noChange: boolean;
|
|
3261
|
+
occurrenceCount: number;
|
|
3262
|
+
fileCount: number;
|
|
3263
|
+
diffLineCount: number;
|
|
3264
|
+
files: {
|
|
3265
|
+
diff: ToolDiffLine[];
|
|
3266
|
+
addedLines: number;
|
|
3267
|
+
removedLines: number;
|
|
3268
|
+
path: string;
|
|
3269
|
+
}[];
|
|
3270
|
+
error?: undefined;
|
|
3271
|
+
staleOccurrenceIds?: undefined;
|
|
3272
|
+
recoverable?: undefined;
|
|
3273
|
+
suggestedNextStep?: undefined;
|
|
3274
|
+
uncertainPaths?: undefined;
|
|
3275
|
+
}> | undefined;
|
|
3276
|
+
execute: import("ai").ToolExecuteFunction<{
|
|
3277
|
+
path: string;
|
|
3278
|
+
needle: string;
|
|
3279
|
+
replacement: string;
|
|
3280
|
+
mode: "literal" | "regex";
|
|
3281
|
+
dryRun: boolean;
|
|
3282
|
+
includeGlob?: string | undefined;
|
|
3283
|
+
excludeGlob?: string | undefined;
|
|
3284
|
+
occurrenceIds?: string[] | undefined;
|
|
3285
|
+
expectedCount?: number | undefined;
|
|
3286
|
+
}, {
|
|
3287
|
+
suggestedPaths?: string[] | undefined;
|
|
3288
|
+
ok: boolean;
|
|
3289
|
+
toolName: string;
|
|
3290
|
+
path: string | undefined;
|
|
3291
|
+
error: string;
|
|
3292
|
+
reasonCode: import("./toolResultTypes.js").ToolFailureReasonCode | undefined;
|
|
3293
|
+
recoverable: boolean;
|
|
3294
|
+
suggestedNextStep: string;
|
|
3295
|
+
recoveryTool: string | undefined;
|
|
3296
|
+
recoveryInput: unknown;
|
|
3297
|
+
} | {
|
|
3298
|
+
ok: boolean;
|
|
3299
|
+
toolName: string;
|
|
3300
|
+
path: string;
|
|
3301
|
+
error: string;
|
|
3302
|
+
reasonCode: "scoped_instructions_discovered";
|
|
3303
|
+
recoverable: boolean;
|
|
3304
|
+
suggestedNextStep: string;
|
|
3305
|
+
applicableProjectInstructions: import("../config/contextFiles.js").ContextFile[];
|
|
3306
|
+
} | {
|
|
3307
|
+
ok: true;
|
|
3308
|
+
duplicateSkipped: true;
|
|
3309
|
+
toolName: string;
|
|
3310
|
+
reason: string;
|
|
3311
|
+
} | {
|
|
3312
|
+
occurrenceHandle?: string | undefined;
|
|
3313
|
+
skippedFiles: number;
|
|
3314
|
+
occurrences: {
|
|
3315
|
+
before: string;
|
|
3316
|
+
after: string;
|
|
3317
|
+
id: string;
|
|
3318
|
+
path: string;
|
|
3319
|
+
line: number;
|
|
3320
|
+
}[];
|
|
3321
|
+
occurrencesTruncated: boolean;
|
|
3322
|
+
ok: boolean;
|
|
3323
|
+
dryRun: boolean;
|
|
3324
|
+
occurrenceCount: number;
|
|
3325
|
+
fileCount: number;
|
|
3326
|
+
error?: undefined;
|
|
3327
|
+
staleOccurrenceIds?: undefined;
|
|
3328
|
+
recoverable?: undefined;
|
|
3329
|
+
suggestedNextStep?: undefined;
|
|
3330
|
+
changedPaths?: undefined;
|
|
3331
|
+
uncertainPaths?: undefined;
|
|
3332
|
+
} | {
|
|
3333
|
+
ok: boolean;
|
|
3334
|
+
error: string;
|
|
3335
|
+
staleOccurrenceIds: string[];
|
|
3336
|
+
recoverable: boolean;
|
|
3337
|
+
suggestedNextStep: string;
|
|
3338
|
+
changedPaths?: undefined;
|
|
3339
|
+
uncertainPaths?: undefined;
|
|
3340
|
+
} | {
|
|
3341
|
+
ok: boolean;
|
|
3342
|
+
error: string;
|
|
3343
|
+
recoverable: boolean;
|
|
3344
|
+
staleOccurrenceIds?: undefined;
|
|
3345
|
+
suggestedNextStep?: undefined;
|
|
3346
|
+
changedPaths?: undefined;
|
|
3347
|
+
uncertainPaths?: undefined;
|
|
3348
|
+
} | {
|
|
3349
|
+
ok: boolean;
|
|
3350
|
+
changedPaths: string[];
|
|
3351
|
+
uncertainPaths: string[];
|
|
3352
|
+
error: string;
|
|
3353
|
+
recoverable: boolean;
|
|
3354
|
+
suggestedNextStep: string;
|
|
3355
|
+
staleOccurrenceIds?: undefined;
|
|
3356
|
+
} | {
|
|
3357
|
+
diffHandle?: string | undefined;
|
|
3358
|
+
ok: boolean;
|
|
3359
|
+
dryRun: boolean;
|
|
3360
|
+
changedPaths: string[];
|
|
3361
|
+
noChange: boolean;
|
|
3362
|
+
occurrenceCount: number;
|
|
3363
|
+
fileCount: number;
|
|
3364
|
+
diffLineCount: number;
|
|
3365
|
+
files: {
|
|
3366
|
+
diff: ToolDiffLine[];
|
|
3367
|
+
addedLines: number;
|
|
3368
|
+
removedLines: number;
|
|
3369
|
+
path: string;
|
|
3370
|
+
}[];
|
|
3371
|
+
error?: undefined;
|
|
3372
|
+
staleOccurrenceIds?: undefined;
|
|
3373
|
+
recoverable?: undefined;
|
|
3374
|
+
suggestedNextStep?: undefined;
|
|
3375
|
+
uncertainPaths?: undefined;
|
|
3376
|
+
}, NoInfer<import("./tools/toolContext.js").HazeToolContext>>;
|
|
3377
|
+
} & {
|
|
3378
|
+
description?: string | ((options: {
|
|
3379
|
+
context: NoInfer<import("./tools/toolContext.js").HazeToolContext>;
|
|
3380
|
+
experimental_sandbox?: import("ai").Experimental_SandboxSession;
|
|
3381
|
+
}) => string) | undefined;
|
|
3382
|
+
strict?: boolean;
|
|
3383
|
+
inputExamples?: {
|
|
3384
|
+
input: NoInfer<{
|
|
3385
|
+
path: string;
|
|
3386
|
+
needle: string;
|
|
3387
|
+
replacement: string;
|
|
3388
|
+
mode: "literal" | "regex";
|
|
3389
|
+
dryRun: boolean;
|
|
3390
|
+
includeGlob?: string | undefined;
|
|
3391
|
+
excludeGlob?: string | undefined;
|
|
3392
|
+
occurrenceIds?: string[] | undefined;
|
|
3393
|
+
expectedCount?: number | undefined;
|
|
3394
|
+
}>;
|
|
3395
|
+
}[] | undefined;
|
|
3396
|
+
id?: never;
|
|
3397
|
+
isProviderExecuted?: never;
|
|
3398
|
+
args?: never;
|
|
3399
|
+
supportsDeferredResults?: never;
|
|
3400
|
+
} & {
|
|
3401
|
+
type?: undefined | "function";
|
|
3402
|
+
} & {
|
|
3403
|
+
execute: import("ai").ToolExecuteFunction<{
|
|
3404
|
+
path: string;
|
|
3405
|
+
needle: string;
|
|
3406
|
+
replacement: string;
|
|
3407
|
+
mode: "literal" | "regex";
|
|
3408
|
+
dryRun: boolean;
|
|
3409
|
+
includeGlob?: string | undefined;
|
|
3410
|
+
excludeGlob?: string | undefined;
|
|
3411
|
+
occurrenceIds?: string[] | undefined;
|
|
3412
|
+
expectedCount?: number | undefined;
|
|
3413
|
+
}, {
|
|
3414
|
+
suggestedPaths?: string[] | undefined;
|
|
3415
|
+
ok: boolean;
|
|
3416
|
+
toolName: string;
|
|
3417
|
+
path: string | undefined;
|
|
3418
|
+
error: string;
|
|
3419
|
+
reasonCode: import("./toolResultTypes.js").ToolFailureReasonCode | undefined;
|
|
3420
|
+
recoverable: boolean;
|
|
3421
|
+
suggestedNextStep: string;
|
|
3422
|
+
recoveryTool: string | undefined;
|
|
3423
|
+
recoveryInput: unknown;
|
|
3424
|
+
} | {
|
|
3425
|
+
ok: boolean;
|
|
3426
|
+
toolName: string;
|
|
3427
|
+
path: string;
|
|
3428
|
+
error: string;
|
|
3429
|
+
reasonCode: "scoped_instructions_discovered";
|
|
3430
|
+
recoverable: boolean;
|
|
3431
|
+
suggestedNextStep: string;
|
|
3432
|
+
applicableProjectInstructions: import("../config/contextFiles.js").ContextFile[];
|
|
3433
|
+
} | {
|
|
3434
|
+
ok: true;
|
|
3435
|
+
duplicateSkipped: true;
|
|
3436
|
+
toolName: string;
|
|
3437
|
+
reason: string;
|
|
3438
|
+
} | {
|
|
3439
|
+
occurrenceHandle?: string | undefined;
|
|
3440
|
+
skippedFiles: number;
|
|
3441
|
+
occurrences: {
|
|
3442
|
+
before: string;
|
|
3443
|
+
after: string;
|
|
3444
|
+
id: string;
|
|
3445
|
+
path: string;
|
|
3446
|
+
line: number;
|
|
3447
|
+
}[];
|
|
3448
|
+
occurrencesTruncated: boolean;
|
|
3449
|
+
ok: boolean;
|
|
3450
|
+
dryRun: boolean;
|
|
3451
|
+
occurrenceCount: number;
|
|
3452
|
+
fileCount: number;
|
|
3453
|
+
error?: undefined;
|
|
3454
|
+
staleOccurrenceIds?: undefined;
|
|
3455
|
+
recoverable?: undefined;
|
|
3456
|
+
suggestedNextStep?: undefined;
|
|
3457
|
+
changedPaths?: undefined;
|
|
3458
|
+
uncertainPaths?: undefined;
|
|
3459
|
+
} | {
|
|
3460
|
+
ok: boolean;
|
|
3461
|
+
error: string;
|
|
3462
|
+
staleOccurrenceIds: string[];
|
|
3463
|
+
recoverable: boolean;
|
|
3464
|
+
suggestedNextStep: string;
|
|
3465
|
+
changedPaths?: undefined;
|
|
3466
|
+
uncertainPaths?: undefined;
|
|
3467
|
+
} | {
|
|
3468
|
+
ok: boolean;
|
|
3469
|
+
error: string;
|
|
3470
|
+
recoverable: boolean;
|
|
3471
|
+
staleOccurrenceIds?: undefined;
|
|
3472
|
+
suggestedNextStep?: undefined;
|
|
3473
|
+
changedPaths?: undefined;
|
|
3474
|
+
uncertainPaths?: undefined;
|
|
3475
|
+
} | {
|
|
3476
|
+
ok: boolean;
|
|
3477
|
+
changedPaths: string[];
|
|
3478
|
+
uncertainPaths: string[];
|
|
3479
|
+
error: string;
|
|
3480
|
+
recoverable: boolean;
|
|
3481
|
+
suggestedNextStep: string;
|
|
3482
|
+
staleOccurrenceIds?: undefined;
|
|
3483
|
+
} | {
|
|
3484
|
+
diffHandle?: string | undefined;
|
|
3485
|
+
ok: boolean;
|
|
3486
|
+
dryRun: boolean;
|
|
3487
|
+
changedPaths: string[];
|
|
3488
|
+
noChange: boolean;
|
|
3489
|
+
occurrenceCount: number;
|
|
3490
|
+
fileCount: number;
|
|
3491
|
+
diffLineCount: number;
|
|
3492
|
+
files: {
|
|
3493
|
+
diff: ToolDiffLine[];
|
|
3494
|
+
addedLines: number;
|
|
3495
|
+
removedLines: number;
|
|
3496
|
+
path: string;
|
|
3497
|
+
}[];
|
|
3498
|
+
error?: undefined;
|
|
3499
|
+
staleOccurrenceIds?: undefined;
|
|
3500
|
+
recoverable?: undefined;
|
|
3501
|
+
suggestedNextStep?: undefined;
|
|
3502
|
+
uncertainPaths?: undefined;
|
|
3503
|
+
}, NoInfer<import("./tools/toolContext.js").HazeToolContext>>;
|
|
3504
|
+
}) | ({
|
|
3505
|
+
deferLoading?: boolean;
|
|
3506
|
+
title?: string;
|
|
3507
|
+
providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
|
|
3508
|
+
metadata?: import("@ai-sdk/provider").JSONObject;
|
|
3509
|
+
inputSchema: import("ai").FlexibleSchema<{
|
|
3510
|
+
path: string;
|
|
3511
|
+
needle: string;
|
|
3512
|
+
replacement: string;
|
|
3513
|
+
mode: "literal" | "regex";
|
|
3514
|
+
dryRun: boolean;
|
|
3515
|
+
includeGlob?: string | undefined;
|
|
3516
|
+
excludeGlob?: string | undefined;
|
|
3517
|
+
occurrenceIds?: string[] | undefined;
|
|
3518
|
+
expectedCount?: number | undefined;
|
|
3519
|
+
}>;
|
|
3520
|
+
contextSchema?: import("ai").FlexibleSchema<import("./tools/toolContext.js").HazeToolContext> | undefined;
|
|
3521
|
+
needsApproval?: boolean | import("@ai-sdk/provider-utils").ToolNeedsApprovalFunction<{
|
|
3522
|
+
path: string;
|
|
3523
|
+
needle: string;
|
|
3524
|
+
replacement: string;
|
|
3525
|
+
mode: "literal" | "regex";
|
|
3526
|
+
dryRun: boolean;
|
|
3527
|
+
includeGlob?: string | undefined;
|
|
3528
|
+
excludeGlob?: string | undefined;
|
|
3529
|
+
occurrenceIds?: string[] | undefined;
|
|
3530
|
+
expectedCount?: number | undefined;
|
|
3531
|
+
}, NoInfer<import("./tools/toolContext.js").HazeToolContext>> | undefined;
|
|
3532
|
+
onInputStart?: ((options: import("ai").ToolExecutionOptions<NoInfer<import("./tools/toolContext.js").HazeToolContext>>) => void | PromiseLike<void>) | undefined;
|
|
3533
|
+
onInputDelta?: ((options: {
|
|
3534
|
+
inputTextDelta: string;
|
|
3535
|
+
} & import("ai").ToolExecutionOptions<NoInfer<import("./tools/toolContext.js").HazeToolContext>>) => void | PromiseLike<void>) | undefined;
|
|
3536
|
+
onInputAvailable?: ((options: {
|
|
3537
|
+
input: {
|
|
3538
|
+
path: string;
|
|
3539
|
+
needle: string;
|
|
3540
|
+
replacement: string;
|
|
3541
|
+
mode: "literal" | "regex";
|
|
3542
|
+
dryRun: boolean;
|
|
3543
|
+
includeGlob?: string | undefined;
|
|
3544
|
+
excludeGlob?: string | undefined;
|
|
3545
|
+
occurrenceIds?: string[] | undefined;
|
|
3546
|
+
expectedCount?: number | undefined;
|
|
3547
|
+
};
|
|
3548
|
+
} & import("ai").ToolExecutionOptions<NoInfer<import("./tools/toolContext.js").HazeToolContext>>) => void | PromiseLike<void>) | undefined;
|
|
3549
|
+
toModelOutput?: ((options: {
|
|
3550
|
+
toolCallId: string;
|
|
3551
|
+
input: {
|
|
3552
|
+
path: string;
|
|
3553
|
+
needle: string;
|
|
3554
|
+
replacement: string;
|
|
3555
|
+
mode: "literal" | "regex";
|
|
3556
|
+
dryRun: boolean;
|
|
3557
|
+
includeGlob?: string | undefined;
|
|
3558
|
+
excludeGlob?: string | undefined;
|
|
3559
|
+
occurrenceIds?: string[] | undefined;
|
|
3560
|
+
expectedCount?: number | undefined;
|
|
3561
|
+
};
|
|
3562
|
+
output: NoInfer<{
|
|
3563
|
+
suggestedPaths?: string[] | undefined;
|
|
3564
|
+
ok: boolean;
|
|
3565
|
+
toolName: string;
|
|
3566
|
+
path: string | undefined;
|
|
3567
|
+
error: string;
|
|
3568
|
+
reasonCode: import("./toolResultTypes.js").ToolFailureReasonCode | undefined;
|
|
3569
|
+
recoverable: boolean;
|
|
3570
|
+
suggestedNextStep: string;
|
|
3571
|
+
recoveryTool: string | undefined;
|
|
3572
|
+
recoveryInput: unknown;
|
|
3573
|
+
} | {
|
|
3574
|
+
ok: boolean;
|
|
3575
|
+
toolName: string;
|
|
3576
|
+
path: string;
|
|
3577
|
+
error: string;
|
|
3578
|
+
reasonCode: "scoped_instructions_discovered";
|
|
3579
|
+
recoverable: boolean;
|
|
3580
|
+
suggestedNextStep: string;
|
|
3581
|
+
applicableProjectInstructions: import("../config/contextFiles.js").ContextFile[];
|
|
3582
|
+
} | {
|
|
3583
|
+
ok: true;
|
|
3584
|
+
duplicateSkipped: true;
|
|
3585
|
+
toolName: string;
|
|
3586
|
+
reason: string;
|
|
3587
|
+
} | {
|
|
3588
|
+
occurrenceHandle?: string | undefined;
|
|
3589
|
+
skippedFiles: number;
|
|
3590
|
+
occurrences: {
|
|
3591
|
+
before: string;
|
|
3592
|
+
after: string;
|
|
3593
|
+
id: string;
|
|
3594
|
+
path: string;
|
|
3595
|
+
line: number;
|
|
3596
|
+
}[];
|
|
3597
|
+
occurrencesTruncated: boolean;
|
|
3598
|
+
ok: boolean;
|
|
3599
|
+
dryRun: boolean;
|
|
3600
|
+
occurrenceCount: number;
|
|
3601
|
+
fileCount: number;
|
|
3602
|
+
error?: undefined;
|
|
3603
|
+
staleOccurrenceIds?: undefined;
|
|
3604
|
+
recoverable?: undefined;
|
|
3605
|
+
suggestedNextStep?: undefined;
|
|
3606
|
+
changedPaths?: undefined;
|
|
3607
|
+
uncertainPaths?: undefined;
|
|
3608
|
+
} | {
|
|
3609
|
+
ok: boolean;
|
|
3610
|
+
error: string;
|
|
3611
|
+
staleOccurrenceIds: string[];
|
|
3612
|
+
recoverable: boolean;
|
|
3613
|
+
suggestedNextStep: string;
|
|
3614
|
+
changedPaths?: undefined;
|
|
3615
|
+
uncertainPaths?: undefined;
|
|
3616
|
+
} | {
|
|
3617
|
+
ok: boolean;
|
|
3618
|
+
error: string;
|
|
3619
|
+
recoverable: boolean;
|
|
3620
|
+
staleOccurrenceIds?: undefined;
|
|
3621
|
+
suggestedNextStep?: undefined;
|
|
3622
|
+
changedPaths?: undefined;
|
|
3623
|
+
uncertainPaths?: undefined;
|
|
3624
|
+
} | {
|
|
3625
|
+
ok: boolean;
|
|
3626
|
+
changedPaths: string[];
|
|
3627
|
+
uncertainPaths: string[];
|
|
3628
|
+
error: string;
|
|
3629
|
+
recoverable: boolean;
|
|
3630
|
+
suggestedNextStep: string;
|
|
3631
|
+
staleOccurrenceIds?: undefined;
|
|
3632
|
+
} | {
|
|
3633
|
+
diffHandle?: string | undefined;
|
|
3634
|
+
ok: boolean;
|
|
3635
|
+
dryRun: boolean;
|
|
3636
|
+
changedPaths: string[];
|
|
3637
|
+
noChange: boolean;
|
|
3638
|
+
occurrenceCount: number;
|
|
3639
|
+
fileCount: number;
|
|
3640
|
+
diffLineCount: number;
|
|
3641
|
+
files: {
|
|
3642
|
+
diff: ToolDiffLine[];
|
|
3643
|
+
addedLines: number;
|
|
3644
|
+
removedLines: number;
|
|
3645
|
+
path: string;
|
|
3646
|
+
}[];
|
|
3647
|
+
error?: undefined;
|
|
3648
|
+
staleOccurrenceIds?: undefined;
|
|
3649
|
+
recoverable?: undefined;
|
|
3650
|
+
suggestedNextStep?: undefined;
|
|
3651
|
+
uncertainPaths?: undefined;
|
|
3652
|
+
}>;
|
|
3653
|
+
}) => import("@ai-sdk/provider-utils").ToolResultOutput | PromiseLike<import("@ai-sdk/provider-utils").ToolResultOutput>) | undefined;
|
|
3654
|
+
} & {
|
|
3655
|
+
outputSchema?: import("ai").FlexibleSchema<{
|
|
3656
|
+
suggestedPaths?: string[] | undefined;
|
|
3657
|
+
ok: boolean;
|
|
3658
|
+
toolName: string;
|
|
3659
|
+
path: string | undefined;
|
|
3660
|
+
error: string;
|
|
3661
|
+
reasonCode: import("./toolResultTypes.js").ToolFailureReasonCode | undefined;
|
|
3662
|
+
recoverable: boolean;
|
|
3663
|
+
suggestedNextStep: string;
|
|
3664
|
+
recoveryTool: string | undefined;
|
|
3665
|
+
recoveryInput: unknown;
|
|
3666
|
+
} | {
|
|
3667
|
+
ok: boolean;
|
|
3668
|
+
toolName: string;
|
|
3669
|
+
path: string;
|
|
3670
|
+
error: string;
|
|
3671
|
+
reasonCode: "scoped_instructions_discovered";
|
|
3672
|
+
recoverable: boolean;
|
|
3673
|
+
suggestedNextStep: string;
|
|
3674
|
+
applicableProjectInstructions: import("../config/contextFiles.js").ContextFile[];
|
|
3675
|
+
} | {
|
|
3676
|
+
ok: true;
|
|
3677
|
+
duplicateSkipped: true;
|
|
3678
|
+
toolName: string;
|
|
3679
|
+
reason: string;
|
|
3680
|
+
} | {
|
|
3681
|
+
occurrenceHandle?: string | undefined;
|
|
3682
|
+
skippedFiles: number;
|
|
3683
|
+
occurrences: {
|
|
3684
|
+
before: string;
|
|
3685
|
+
after: string;
|
|
3686
|
+
id: string;
|
|
3687
|
+
path: string;
|
|
3688
|
+
line: number;
|
|
3689
|
+
}[];
|
|
3690
|
+
occurrencesTruncated: boolean;
|
|
3691
|
+
ok: boolean;
|
|
3692
|
+
dryRun: boolean;
|
|
3693
|
+
occurrenceCount: number;
|
|
3694
|
+
fileCount: number;
|
|
3695
|
+
error?: undefined;
|
|
3696
|
+
staleOccurrenceIds?: undefined;
|
|
3697
|
+
recoverable?: undefined;
|
|
3698
|
+
suggestedNextStep?: undefined;
|
|
3699
|
+
changedPaths?: undefined;
|
|
3700
|
+
uncertainPaths?: undefined;
|
|
3701
|
+
} | {
|
|
3702
|
+
ok: boolean;
|
|
3703
|
+
error: string;
|
|
3704
|
+
staleOccurrenceIds: string[];
|
|
3705
|
+
recoverable: boolean;
|
|
3706
|
+
suggestedNextStep: string;
|
|
3707
|
+
changedPaths?: undefined;
|
|
3708
|
+
uncertainPaths?: undefined;
|
|
3709
|
+
} | {
|
|
3710
|
+
ok: boolean;
|
|
3711
|
+
error: string;
|
|
3712
|
+
recoverable: boolean;
|
|
3713
|
+
staleOccurrenceIds?: undefined;
|
|
3714
|
+
suggestedNextStep?: undefined;
|
|
3715
|
+
changedPaths?: undefined;
|
|
3716
|
+
uncertainPaths?: undefined;
|
|
3717
|
+
} | {
|
|
3718
|
+
ok: boolean;
|
|
3719
|
+
changedPaths: string[];
|
|
3720
|
+
uncertainPaths: string[];
|
|
3721
|
+
error: string;
|
|
3722
|
+
recoverable: boolean;
|
|
3723
|
+
suggestedNextStep: string;
|
|
3724
|
+
staleOccurrenceIds?: undefined;
|
|
3725
|
+
} | {
|
|
3726
|
+
diffHandle?: string | undefined;
|
|
3727
|
+
ok: boolean;
|
|
3728
|
+
dryRun: boolean;
|
|
3729
|
+
changedPaths: string[];
|
|
3730
|
+
noChange: boolean;
|
|
3731
|
+
occurrenceCount: number;
|
|
3732
|
+
fileCount: number;
|
|
3733
|
+
diffLineCount: number;
|
|
3734
|
+
files: {
|
|
3735
|
+
diff: ToolDiffLine[];
|
|
3736
|
+
addedLines: number;
|
|
3737
|
+
removedLines: number;
|
|
3738
|
+
path: string;
|
|
3739
|
+
}[];
|
|
3740
|
+
error?: undefined;
|
|
3741
|
+
staleOccurrenceIds?: undefined;
|
|
3742
|
+
recoverable?: undefined;
|
|
3743
|
+
suggestedNextStep?: undefined;
|
|
3744
|
+
uncertainPaths?: undefined;
|
|
3745
|
+
}> | undefined;
|
|
3746
|
+
execute: import("ai").ToolExecuteFunction<{
|
|
3747
|
+
path: string;
|
|
3748
|
+
needle: string;
|
|
3749
|
+
replacement: string;
|
|
3750
|
+
mode: "literal" | "regex";
|
|
3751
|
+
dryRun: boolean;
|
|
3752
|
+
includeGlob?: string | undefined;
|
|
3753
|
+
excludeGlob?: string | undefined;
|
|
3754
|
+
occurrenceIds?: string[] | undefined;
|
|
3755
|
+
expectedCount?: number | undefined;
|
|
3756
|
+
}, {
|
|
3757
|
+
suggestedPaths?: string[] | undefined;
|
|
3758
|
+
ok: boolean;
|
|
3759
|
+
toolName: string;
|
|
3760
|
+
path: string | undefined;
|
|
3761
|
+
error: string;
|
|
3762
|
+
reasonCode: import("./toolResultTypes.js").ToolFailureReasonCode | undefined;
|
|
3763
|
+
recoverable: boolean;
|
|
3764
|
+
suggestedNextStep: string;
|
|
3765
|
+
recoveryTool: string | undefined;
|
|
3766
|
+
recoveryInput: unknown;
|
|
3767
|
+
} | {
|
|
3768
|
+
ok: boolean;
|
|
3769
|
+
toolName: string;
|
|
3770
|
+
path: string;
|
|
3771
|
+
error: string;
|
|
3772
|
+
reasonCode: "scoped_instructions_discovered";
|
|
3773
|
+
recoverable: boolean;
|
|
3774
|
+
suggestedNextStep: string;
|
|
3775
|
+
applicableProjectInstructions: import("../config/contextFiles.js").ContextFile[];
|
|
3776
|
+
} | {
|
|
3777
|
+
ok: true;
|
|
3778
|
+
duplicateSkipped: true;
|
|
3779
|
+
toolName: string;
|
|
3780
|
+
reason: string;
|
|
3781
|
+
} | {
|
|
3782
|
+
occurrenceHandle?: string | undefined;
|
|
3783
|
+
skippedFiles: number;
|
|
3784
|
+
occurrences: {
|
|
3785
|
+
before: string;
|
|
3786
|
+
after: string;
|
|
3787
|
+
id: string;
|
|
3788
|
+
path: string;
|
|
3789
|
+
line: number;
|
|
3790
|
+
}[];
|
|
3791
|
+
occurrencesTruncated: boolean;
|
|
3792
|
+
ok: boolean;
|
|
3793
|
+
dryRun: boolean;
|
|
3794
|
+
occurrenceCount: number;
|
|
3795
|
+
fileCount: number;
|
|
3796
|
+
error?: undefined;
|
|
3797
|
+
staleOccurrenceIds?: undefined;
|
|
3798
|
+
recoverable?: undefined;
|
|
3799
|
+
suggestedNextStep?: undefined;
|
|
3800
|
+
changedPaths?: undefined;
|
|
3801
|
+
uncertainPaths?: undefined;
|
|
3802
|
+
} | {
|
|
3803
|
+
ok: boolean;
|
|
3804
|
+
error: string;
|
|
3805
|
+
staleOccurrenceIds: string[];
|
|
3806
|
+
recoverable: boolean;
|
|
3807
|
+
suggestedNextStep: string;
|
|
3808
|
+
changedPaths?: undefined;
|
|
3809
|
+
uncertainPaths?: undefined;
|
|
3810
|
+
} | {
|
|
3811
|
+
ok: boolean;
|
|
3812
|
+
error: string;
|
|
3813
|
+
recoverable: boolean;
|
|
3814
|
+
staleOccurrenceIds?: undefined;
|
|
3815
|
+
suggestedNextStep?: undefined;
|
|
3816
|
+
changedPaths?: undefined;
|
|
3817
|
+
uncertainPaths?: undefined;
|
|
3818
|
+
} | {
|
|
3819
|
+
ok: boolean;
|
|
3820
|
+
changedPaths: string[];
|
|
3821
|
+
uncertainPaths: string[];
|
|
3822
|
+
error: string;
|
|
3823
|
+
recoverable: boolean;
|
|
3824
|
+
suggestedNextStep: string;
|
|
3825
|
+
staleOccurrenceIds?: undefined;
|
|
3826
|
+
} | {
|
|
3827
|
+
diffHandle?: string | undefined;
|
|
3828
|
+
ok: boolean;
|
|
3829
|
+
dryRun: boolean;
|
|
3830
|
+
changedPaths: string[];
|
|
3831
|
+
noChange: boolean;
|
|
3832
|
+
occurrenceCount: number;
|
|
3833
|
+
fileCount: number;
|
|
3834
|
+
diffLineCount: number;
|
|
3835
|
+
files: {
|
|
3836
|
+
diff: ToolDiffLine[];
|
|
3837
|
+
addedLines: number;
|
|
3838
|
+
removedLines: number;
|
|
3839
|
+
path: string;
|
|
3840
|
+
}[];
|
|
3841
|
+
error?: undefined;
|
|
3842
|
+
staleOccurrenceIds?: undefined;
|
|
3843
|
+
recoverable?: undefined;
|
|
3844
|
+
suggestedNextStep?: undefined;
|
|
3845
|
+
uncertainPaths?: undefined;
|
|
3846
|
+
}, NoInfer<import("./tools/toolContext.js").HazeToolContext>>;
|
|
3847
|
+
} & {
|
|
3848
|
+
description?: string | ((options: {
|
|
3849
|
+
context: NoInfer<import("./tools/toolContext.js").HazeToolContext>;
|
|
3850
|
+
experimental_sandbox?: import("ai").Experimental_SandboxSession;
|
|
3851
|
+
}) => string) | undefined;
|
|
3852
|
+
strict?: boolean;
|
|
3853
|
+
inputExamples?: {
|
|
3854
|
+
input: NoInfer<{
|
|
3855
|
+
path: string;
|
|
3856
|
+
needle: string;
|
|
3857
|
+
replacement: string;
|
|
3858
|
+
mode: "literal" | "regex";
|
|
3859
|
+
dryRun: boolean;
|
|
3860
|
+
includeGlob?: string | undefined;
|
|
3861
|
+
excludeGlob?: string | undefined;
|
|
3862
|
+
occurrenceIds?: string[] | undefined;
|
|
3863
|
+
expectedCount?: number | undefined;
|
|
3864
|
+
}>;
|
|
3865
|
+
}[] | undefined;
|
|
3866
|
+
id?: never;
|
|
3867
|
+
isProviderExecuted?: never;
|
|
3868
|
+
args?: never;
|
|
3869
|
+
supportsDeferredResults?: never;
|
|
3870
|
+
} & {
|
|
3871
|
+
type: "dynamic";
|
|
3872
|
+
} & {
|
|
3873
|
+
execute: import("ai").ToolExecuteFunction<{
|
|
3874
|
+
path: string;
|
|
3875
|
+
needle: string;
|
|
3876
|
+
replacement: string;
|
|
3877
|
+
mode: "literal" | "regex";
|
|
3878
|
+
dryRun: boolean;
|
|
3879
|
+
includeGlob?: string | undefined;
|
|
3880
|
+
excludeGlob?: string | undefined;
|
|
3881
|
+
occurrenceIds?: string[] | undefined;
|
|
3882
|
+
expectedCount?: number | undefined;
|
|
3883
|
+
}, {
|
|
3884
|
+
suggestedPaths?: string[] | undefined;
|
|
3885
|
+
ok: boolean;
|
|
3886
|
+
toolName: string;
|
|
3887
|
+
path: string | undefined;
|
|
3888
|
+
error: string;
|
|
3889
|
+
reasonCode: import("./toolResultTypes.js").ToolFailureReasonCode | undefined;
|
|
3890
|
+
recoverable: boolean;
|
|
3891
|
+
suggestedNextStep: string;
|
|
3892
|
+
recoveryTool: string | undefined;
|
|
3893
|
+
recoveryInput: unknown;
|
|
3894
|
+
} | {
|
|
3895
|
+
ok: boolean;
|
|
3896
|
+
toolName: string;
|
|
3897
|
+
path: string;
|
|
3898
|
+
error: string;
|
|
3899
|
+
reasonCode: "scoped_instructions_discovered";
|
|
3900
|
+
recoverable: boolean;
|
|
3901
|
+
suggestedNextStep: string;
|
|
3902
|
+
applicableProjectInstructions: import("../config/contextFiles.js").ContextFile[];
|
|
3903
|
+
} | {
|
|
3904
|
+
ok: true;
|
|
3905
|
+
duplicateSkipped: true;
|
|
3906
|
+
toolName: string;
|
|
3907
|
+
reason: string;
|
|
3908
|
+
} | {
|
|
3909
|
+
occurrenceHandle?: string | undefined;
|
|
3910
|
+
skippedFiles: number;
|
|
3911
|
+
occurrences: {
|
|
3912
|
+
before: string;
|
|
3913
|
+
after: string;
|
|
3914
|
+
id: string;
|
|
3915
|
+
path: string;
|
|
3916
|
+
line: number;
|
|
3917
|
+
}[];
|
|
3918
|
+
occurrencesTruncated: boolean;
|
|
3919
|
+
ok: boolean;
|
|
3920
|
+
dryRun: boolean;
|
|
3921
|
+
occurrenceCount: number;
|
|
3922
|
+
fileCount: number;
|
|
3923
|
+
error?: undefined;
|
|
3924
|
+
staleOccurrenceIds?: undefined;
|
|
3925
|
+
recoverable?: undefined;
|
|
3926
|
+
suggestedNextStep?: undefined;
|
|
3927
|
+
changedPaths?: undefined;
|
|
3928
|
+
uncertainPaths?: undefined;
|
|
3929
|
+
} | {
|
|
3930
|
+
ok: boolean;
|
|
3931
|
+
error: string;
|
|
3932
|
+
staleOccurrenceIds: string[];
|
|
3933
|
+
recoverable: boolean;
|
|
3934
|
+
suggestedNextStep: string;
|
|
3935
|
+
changedPaths?: undefined;
|
|
3936
|
+
uncertainPaths?: undefined;
|
|
3937
|
+
} | {
|
|
3938
|
+
ok: boolean;
|
|
3939
|
+
error: string;
|
|
3940
|
+
recoverable: boolean;
|
|
3941
|
+
staleOccurrenceIds?: undefined;
|
|
3942
|
+
suggestedNextStep?: undefined;
|
|
3943
|
+
changedPaths?: undefined;
|
|
3944
|
+
uncertainPaths?: undefined;
|
|
3945
|
+
} | {
|
|
3946
|
+
ok: boolean;
|
|
3947
|
+
changedPaths: string[];
|
|
3948
|
+
uncertainPaths: string[];
|
|
3949
|
+
error: string;
|
|
3950
|
+
recoverable: boolean;
|
|
3951
|
+
suggestedNextStep: string;
|
|
3952
|
+
staleOccurrenceIds?: undefined;
|
|
3953
|
+
} | {
|
|
3954
|
+
diffHandle?: string | undefined;
|
|
3955
|
+
ok: boolean;
|
|
3956
|
+
dryRun: boolean;
|
|
3957
|
+
changedPaths: string[];
|
|
3958
|
+
noChange: boolean;
|
|
3959
|
+
occurrenceCount: number;
|
|
3960
|
+
fileCount: number;
|
|
3961
|
+
diffLineCount: number;
|
|
3962
|
+
files: {
|
|
3963
|
+
diff: ToolDiffLine[];
|
|
3964
|
+
addedLines: number;
|
|
3965
|
+
removedLines: number;
|
|
3966
|
+
path: string;
|
|
3967
|
+
}[];
|
|
3968
|
+
error?: undefined;
|
|
3969
|
+
staleOccurrenceIds?: undefined;
|
|
3970
|
+
recoverable?: undefined;
|
|
3971
|
+
suggestedNextStep?: undefined;
|
|
3972
|
+
uncertainPaths?: undefined;
|
|
3973
|
+
}, NoInfer<import("./tools/toolContext.js").HazeToolContext>>;
|
|
3974
|
+
}) | ({
|
|
3975
|
+
deferLoading?: boolean;
|
|
3976
|
+
title?: string;
|
|
3977
|
+
providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
|
|
3978
|
+
metadata?: import("@ai-sdk/provider").JSONObject;
|
|
3979
|
+
inputSchema: import("ai").FlexibleSchema<{
|
|
3980
|
+
path: string;
|
|
3981
|
+
needle: string;
|
|
3982
|
+
replacement: string;
|
|
3983
|
+
mode: "literal" | "regex";
|
|
3984
|
+
dryRun: boolean;
|
|
3985
|
+
includeGlob?: string | undefined;
|
|
3986
|
+
excludeGlob?: string | undefined;
|
|
3987
|
+
occurrenceIds?: string[] | undefined;
|
|
3988
|
+
expectedCount?: number | undefined;
|
|
3989
|
+
}>;
|
|
3990
|
+
contextSchema?: import("ai").FlexibleSchema<import("./tools/toolContext.js").HazeToolContext> | undefined;
|
|
3991
|
+
needsApproval?: boolean | import("@ai-sdk/provider-utils").ToolNeedsApprovalFunction<{
|
|
3992
|
+
path: string;
|
|
3993
|
+
needle: string;
|
|
3994
|
+
replacement: string;
|
|
3995
|
+
mode: "literal" | "regex";
|
|
3996
|
+
dryRun: boolean;
|
|
3997
|
+
includeGlob?: string | undefined;
|
|
3998
|
+
excludeGlob?: string | undefined;
|
|
3999
|
+
occurrenceIds?: string[] | undefined;
|
|
4000
|
+
expectedCount?: number | undefined;
|
|
4001
|
+
}, NoInfer<import("./tools/toolContext.js").HazeToolContext>> | undefined;
|
|
4002
|
+
onInputStart?: ((options: import("ai").ToolExecutionOptions<NoInfer<import("./tools/toolContext.js").HazeToolContext>>) => void | PromiseLike<void>) | undefined;
|
|
4003
|
+
onInputDelta?: ((options: {
|
|
4004
|
+
inputTextDelta: string;
|
|
4005
|
+
} & import("ai").ToolExecutionOptions<NoInfer<import("./tools/toolContext.js").HazeToolContext>>) => void | PromiseLike<void>) | undefined;
|
|
4006
|
+
onInputAvailable?: ((options: {
|
|
4007
|
+
input: {
|
|
4008
|
+
path: string;
|
|
4009
|
+
needle: string;
|
|
4010
|
+
replacement: string;
|
|
4011
|
+
mode: "literal" | "regex";
|
|
4012
|
+
dryRun: boolean;
|
|
4013
|
+
includeGlob?: string | undefined;
|
|
4014
|
+
excludeGlob?: string | undefined;
|
|
4015
|
+
occurrenceIds?: string[] | undefined;
|
|
4016
|
+
expectedCount?: number | undefined;
|
|
4017
|
+
};
|
|
4018
|
+
} & import("ai").ToolExecutionOptions<NoInfer<import("./tools/toolContext.js").HazeToolContext>>) => void | PromiseLike<void>) | undefined;
|
|
4019
|
+
toModelOutput?: ((options: {
|
|
4020
|
+
toolCallId: string;
|
|
4021
|
+
input: {
|
|
4022
|
+
path: string;
|
|
4023
|
+
needle: string;
|
|
4024
|
+
replacement: string;
|
|
4025
|
+
mode: "literal" | "regex";
|
|
4026
|
+
dryRun: boolean;
|
|
4027
|
+
includeGlob?: string | undefined;
|
|
4028
|
+
excludeGlob?: string | undefined;
|
|
4029
|
+
occurrenceIds?: string[] | undefined;
|
|
4030
|
+
expectedCount?: number | undefined;
|
|
4031
|
+
};
|
|
4032
|
+
output: NoInfer<{
|
|
4033
|
+
suggestedPaths?: string[] | undefined;
|
|
4034
|
+
ok: boolean;
|
|
4035
|
+
toolName: string;
|
|
4036
|
+
path: string | undefined;
|
|
4037
|
+
error: string;
|
|
4038
|
+
reasonCode: import("./toolResultTypes.js").ToolFailureReasonCode | undefined;
|
|
4039
|
+
recoverable: boolean;
|
|
4040
|
+
suggestedNextStep: string;
|
|
4041
|
+
recoveryTool: string | undefined;
|
|
4042
|
+
recoveryInput: unknown;
|
|
4043
|
+
} | {
|
|
4044
|
+
ok: boolean;
|
|
4045
|
+
toolName: string;
|
|
4046
|
+
path: string;
|
|
4047
|
+
error: string;
|
|
4048
|
+
reasonCode: "scoped_instructions_discovered";
|
|
4049
|
+
recoverable: boolean;
|
|
4050
|
+
suggestedNextStep: string;
|
|
4051
|
+
applicableProjectInstructions: import("../config/contextFiles.js").ContextFile[];
|
|
4052
|
+
} | {
|
|
4053
|
+
ok: true;
|
|
4054
|
+
duplicateSkipped: true;
|
|
4055
|
+
toolName: string;
|
|
4056
|
+
reason: string;
|
|
4057
|
+
} | {
|
|
4058
|
+
occurrenceHandle?: string | undefined;
|
|
4059
|
+
skippedFiles: number;
|
|
4060
|
+
occurrences: {
|
|
4061
|
+
before: string;
|
|
4062
|
+
after: string;
|
|
4063
|
+
id: string;
|
|
4064
|
+
path: string;
|
|
4065
|
+
line: number;
|
|
4066
|
+
}[];
|
|
4067
|
+
occurrencesTruncated: boolean;
|
|
4068
|
+
ok: boolean;
|
|
4069
|
+
dryRun: boolean;
|
|
4070
|
+
occurrenceCount: number;
|
|
4071
|
+
fileCount: number;
|
|
4072
|
+
error?: undefined;
|
|
4073
|
+
staleOccurrenceIds?: undefined;
|
|
4074
|
+
recoverable?: undefined;
|
|
4075
|
+
suggestedNextStep?: undefined;
|
|
4076
|
+
changedPaths?: undefined;
|
|
4077
|
+
uncertainPaths?: undefined;
|
|
4078
|
+
} | {
|
|
4079
|
+
ok: boolean;
|
|
4080
|
+
error: string;
|
|
4081
|
+
staleOccurrenceIds: string[];
|
|
4082
|
+
recoverable: boolean;
|
|
4083
|
+
suggestedNextStep: string;
|
|
4084
|
+
changedPaths?: undefined;
|
|
4085
|
+
uncertainPaths?: undefined;
|
|
4086
|
+
} | {
|
|
4087
|
+
ok: boolean;
|
|
4088
|
+
error: string;
|
|
4089
|
+
recoverable: boolean;
|
|
4090
|
+
staleOccurrenceIds?: undefined;
|
|
4091
|
+
suggestedNextStep?: undefined;
|
|
4092
|
+
changedPaths?: undefined;
|
|
4093
|
+
uncertainPaths?: undefined;
|
|
4094
|
+
} | {
|
|
4095
|
+
ok: boolean;
|
|
4096
|
+
changedPaths: string[];
|
|
4097
|
+
uncertainPaths: string[];
|
|
4098
|
+
error: string;
|
|
4099
|
+
recoverable: boolean;
|
|
4100
|
+
suggestedNextStep: string;
|
|
4101
|
+
staleOccurrenceIds?: undefined;
|
|
4102
|
+
} | {
|
|
4103
|
+
diffHandle?: string | undefined;
|
|
4104
|
+
ok: boolean;
|
|
4105
|
+
dryRun: boolean;
|
|
4106
|
+
changedPaths: string[];
|
|
4107
|
+
noChange: boolean;
|
|
4108
|
+
occurrenceCount: number;
|
|
4109
|
+
fileCount: number;
|
|
4110
|
+
diffLineCount: number;
|
|
4111
|
+
files: {
|
|
4112
|
+
diff: ToolDiffLine[];
|
|
4113
|
+
addedLines: number;
|
|
4114
|
+
removedLines: number;
|
|
4115
|
+
path: string;
|
|
4116
|
+
}[];
|
|
4117
|
+
error?: undefined;
|
|
4118
|
+
staleOccurrenceIds?: undefined;
|
|
4119
|
+
recoverable?: undefined;
|
|
4120
|
+
suggestedNextStep?: undefined;
|
|
4121
|
+
uncertainPaths?: undefined;
|
|
4122
|
+
}>;
|
|
4123
|
+
}) => import("@ai-sdk/provider-utils").ToolResultOutput | PromiseLike<import("@ai-sdk/provider-utils").ToolResultOutput>) | undefined;
|
|
4124
|
+
} & {
|
|
4125
|
+
outputSchema?: import("ai").FlexibleSchema<{
|
|
4126
|
+
suggestedPaths?: string[] | undefined;
|
|
4127
|
+
ok: boolean;
|
|
4128
|
+
toolName: string;
|
|
4129
|
+
path: string | undefined;
|
|
4130
|
+
error: string;
|
|
4131
|
+
reasonCode: import("./toolResultTypes.js").ToolFailureReasonCode | undefined;
|
|
4132
|
+
recoverable: boolean;
|
|
4133
|
+
suggestedNextStep: string;
|
|
4134
|
+
recoveryTool: string | undefined;
|
|
4135
|
+
recoveryInput: unknown;
|
|
4136
|
+
} | {
|
|
4137
|
+
ok: boolean;
|
|
4138
|
+
toolName: string;
|
|
4139
|
+
path: string;
|
|
4140
|
+
error: string;
|
|
4141
|
+
reasonCode: "scoped_instructions_discovered";
|
|
4142
|
+
recoverable: boolean;
|
|
4143
|
+
suggestedNextStep: string;
|
|
4144
|
+
applicableProjectInstructions: import("../config/contextFiles.js").ContextFile[];
|
|
4145
|
+
} | {
|
|
4146
|
+
ok: true;
|
|
4147
|
+
duplicateSkipped: true;
|
|
4148
|
+
toolName: string;
|
|
4149
|
+
reason: string;
|
|
4150
|
+
} | {
|
|
4151
|
+
occurrenceHandle?: string | undefined;
|
|
4152
|
+
skippedFiles: number;
|
|
4153
|
+
occurrences: {
|
|
4154
|
+
before: string;
|
|
4155
|
+
after: string;
|
|
4156
|
+
id: string;
|
|
4157
|
+
path: string;
|
|
4158
|
+
line: number;
|
|
4159
|
+
}[];
|
|
4160
|
+
occurrencesTruncated: boolean;
|
|
4161
|
+
ok: boolean;
|
|
4162
|
+
dryRun: boolean;
|
|
4163
|
+
occurrenceCount: number;
|
|
4164
|
+
fileCount: number;
|
|
4165
|
+
error?: undefined;
|
|
4166
|
+
staleOccurrenceIds?: undefined;
|
|
4167
|
+
recoverable?: undefined;
|
|
4168
|
+
suggestedNextStep?: undefined;
|
|
4169
|
+
changedPaths?: undefined;
|
|
4170
|
+
uncertainPaths?: undefined;
|
|
4171
|
+
} | {
|
|
4172
|
+
ok: boolean;
|
|
4173
|
+
error: string;
|
|
4174
|
+
staleOccurrenceIds: string[];
|
|
4175
|
+
recoverable: boolean;
|
|
4176
|
+
suggestedNextStep: string;
|
|
4177
|
+
changedPaths?: undefined;
|
|
4178
|
+
uncertainPaths?: undefined;
|
|
4179
|
+
} | {
|
|
4180
|
+
ok: boolean;
|
|
4181
|
+
error: string;
|
|
4182
|
+
recoverable: boolean;
|
|
4183
|
+
staleOccurrenceIds?: undefined;
|
|
4184
|
+
suggestedNextStep?: undefined;
|
|
4185
|
+
changedPaths?: undefined;
|
|
4186
|
+
uncertainPaths?: undefined;
|
|
4187
|
+
} | {
|
|
4188
|
+
ok: boolean;
|
|
4189
|
+
changedPaths: string[];
|
|
4190
|
+
uncertainPaths: string[];
|
|
4191
|
+
error: string;
|
|
4192
|
+
recoverable: boolean;
|
|
4193
|
+
suggestedNextStep: string;
|
|
4194
|
+
staleOccurrenceIds?: undefined;
|
|
4195
|
+
} | {
|
|
4196
|
+
diffHandle?: string | undefined;
|
|
4197
|
+
ok: boolean;
|
|
4198
|
+
dryRun: boolean;
|
|
4199
|
+
changedPaths: string[];
|
|
4200
|
+
noChange: boolean;
|
|
4201
|
+
occurrenceCount: number;
|
|
4202
|
+
fileCount: number;
|
|
4203
|
+
diffLineCount: number;
|
|
4204
|
+
files: {
|
|
4205
|
+
diff: ToolDiffLine[];
|
|
4206
|
+
addedLines: number;
|
|
4207
|
+
removedLines: number;
|
|
4208
|
+
path: string;
|
|
4209
|
+
}[];
|
|
4210
|
+
error?: undefined;
|
|
4211
|
+
staleOccurrenceIds?: undefined;
|
|
4212
|
+
recoverable?: undefined;
|
|
4213
|
+
suggestedNextStep?: undefined;
|
|
4214
|
+
uncertainPaths?: undefined;
|
|
4215
|
+
}> | undefined;
|
|
4216
|
+
execute: import("ai").ToolExecuteFunction<{
|
|
4217
|
+
path: string;
|
|
4218
|
+
needle: string;
|
|
4219
|
+
replacement: string;
|
|
4220
|
+
mode: "literal" | "regex";
|
|
4221
|
+
dryRun: boolean;
|
|
4222
|
+
includeGlob?: string | undefined;
|
|
4223
|
+
excludeGlob?: string | undefined;
|
|
4224
|
+
occurrenceIds?: string[] | undefined;
|
|
4225
|
+
expectedCount?: number | undefined;
|
|
4226
|
+
}, {
|
|
4227
|
+
suggestedPaths?: string[] | undefined;
|
|
4228
|
+
ok: boolean;
|
|
4229
|
+
toolName: string;
|
|
4230
|
+
path: string | undefined;
|
|
4231
|
+
error: string;
|
|
4232
|
+
reasonCode: import("./toolResultTypes.js").ToolFailureReasonCode | undefined;
|
|
4233
|
+
recoverable: boolean;
|
|
4234
|
+
suggestedNextStep: string;
|
|
4235
|
+
recoveryTool: string | undefined;
|
|
4236
|
+
recoveryInput: unknown;
|
|
4237
|
+
} | {
|
|
4238
|
+
ok: boolean;
|
|
4239
|
+
toolName: string;
|
|
4240
|
+
path: string;
|
|
4241
|
+
error: string;
|
|
4242
|
+
reasonCode: "scoped_instructions_discovered";
|
|
4243
|
+
recoverable: boolean;
|
|
4244
|
+
suggestedNextStep: string;
|
|
4245
|
+
applicableProjectInstructions: import("../config/contextFiles.js").ContextFile[];
|
|
4246
|
+
} | {
|
|
4247
|
+
ok: true;
|
|
4248
|
+
duplicateSkipped: true;
|
|
4249
|
+
toolName: string;
|
|
4250
|
+
reason: string;
|
|
4251
|
+
} | {
|
|
4252
|
+
occurrenceHandle?: string | undefined;
|
|
4253
|
+
skippedFiles: number;
|
|
4254
|
+
occurrences: {
|
|
4255
|
+
before: string;
|
|
4256
|
+
after: string;
|
|
4257
|
+
id: string;
|
|
4258
|
+
path: string;
|
|
4259
|
+
line: number;
|
|
4260
|
+
}[];
|
|
4261
|
+
occurrencesTruncated: boolean;
|
|
4262
|
+
ok: boolean;
|
|
4263
|
+
dryRun: boolean;
|
|
4264
|
+
occurrenceCount: number;
|
|
4265
|
+
fileCount: number;
|
|
4266
|
+
error?: undefined;
|
|
4267
|
+
staleOccurrenceIds?: undefined;
|
|
4268
|
+
recoverable?: undefined;
|
|
4269
|
+
suggestedNextStep?: undefined;
|
|
4270
|
+
changedPaths?: undefined;
|
|
4271
|
+
uncertainPaths?: undefined;
|
|
4272
|
+
} | {
|
|
4273
|
+
ok: boolean;
|
|
4274
|
+
error: string;
|
|
4275
|
+
staleOccurrenceIds: string[];
|
|
4276
|
+
recoverable: boolean;
|
|
4277
|
+
suggestedNextStep: string;
|
|
4278
|
+
changedPaths?: undefined;
|
|
4279
|
+
uncertainPaths?: undefined;
|
|
4280
|
+
} | {
|
|
4281
|
+
ok: boolean;
|
|
4282
|
+
error: string;
|
|
4283
|
+
recoverable: boolean;
|
|
4284
|
+
staleOccurrenceIds?: undefined;
|
|
4285
|
+
suggestedNextStep?: undefined;
|
|
4286
|
+
changedPaths?: undefined;
|
|
4287
|
+
uncertainPaths?: undefined;
|
|
4288
|
+
} | {
|
|
4289
|
+
ok: boolean;
|
|
4290
|
+
changedPaths: string[];
|
|
4291
|
+
uncertainPaths: string[];
|
|
4292
|
+
error: string;
|
|
4293
|
+
recoverable: boolean;
|
|
4294
|
+
suggestedNextStep: string;
|
|
4295
|
+
staleOccurrenceIds?: undefined;
|
|
4296
|
+
} | {
|
|
4297
|
+
diffHandle?: string | undefined;
|
|
4298
|
+
ok: boolean;
|
|
4299
|
+
dryRun: boolean;
|
|
4300
|
+
changedPaths: string[];
|
|
4301
|
+
noChange: boolean;
|
|
4302
|
+
occurrenceCount: number;
|
|
4303
|
+
fileCount: number;
|
|
4304
|
+
diffLineCount: number;
|
|
4305
|
+
files: {
|
|
4306
|
+
diff: ToolDiffLine[];
|
|
4307
|
+
addedLines: number;
|
|
4308
|
+
removedLines: number;
|
|
4309
|
+
path: string;
|
|
4310
|
+
}[];
|
|
4311
|
+
error?: undefined;
|
|
4312
|
+
staleOccurrenceIds?: undefined;
|
|
4313
|
+
recoverable?: undefined;
|
|
4314
|
+
suggestedNextStep?: undefined;
|
|
4315
|
+
uncertainPaths?: undefined;
|
|
4316
|
+
}, NoInfer<import("./tools/toolContext.js").HazeToolContext>>;
|
|
4317
|
+
} & {
|
|
4318
|
+
type: "provider";
|
|
4319
|
+
id: `${string}.${string}`;
|
|
4320
|
+
args: Record<string, unknown>;
|
|
4321
|
+
description?: never;
|
|
4322
|
+
strict?: never;
|
|
4323
|
+
inputExamples?: never;
|
|
4324
|
+
} & {
|
|
4325
|
+
isProviderExecuted: false;
|
|
4326
|
+
supportsDeferredResults?: never;
|
|
4327
|
+
} & {
|
|
4328
|
+
execute: import("ai").ToolExecuteFunction<{
|
|
4329
|
+
path: string;
|
|
4330
|
+
needle: string;
|
|
4331
|
+
replacement: string;
|
|
4332
|
+
mode: "literal" | "regex";
|
|
4333
|
+
dryRun: boolean;
|
|
4334
|
+
includeGlob?: string | undefined;
|
|
4335
|
+
excludeGlob?: string | undefined;
|
|
4336
|
+
occurrenceIds?: string[] | undefined;
|
|
4337
|
+
expectedCount?: number | undefined;
|
|
4338
|
+
}, {
|
|
4339
|
+
suggestedPaths?: string[] | undefined;
|
|
4340
|
+
ok: boolean;
|
|
4341
|
+
toolName: string;
|
|
4342
|
+
path: string | undefined;
|
|
4343
|
+
error: string;
|
|
4344
|
+
reasonCode: import("./toolResultTypes.js").ToolFailureReasonCode | undefined;
|
|
4345
|
+
recoverable: boolean;
|
|
4346
|
+
suggestedNextStep: string;
|
|
4347
|
+
recoveryTool: string | undefined;
|
|
4348
|
+
recoveryInput: unknown;
|
|
4349
|
+
} | {
|
|
4350
|
+
ok: boolean;
|
|
4351
|
+
toolName: string;
|
|
4352
|
+
path: string;
|
|
4353
|
+
error: string;
|
|
4354
|
+
reasonCode: "scoped_instructions_discovered";
|
|
4355
|
+
recoverable: boolean;
|
|
4356
|
+
suggestedNextStep: string;
|
|
4357
|
+
applicableProjectInstructions: import("../config/contextFiles.js").ContextFile[];
|
|
4358
|
+
} | {
|
|
4359
|
+
ok: true;
|
|
4360
|
+
duplicateSkipped: true;
|
|
4361
|
+
toolName: string;
|
|
4362
|
+
reason: string;
|
|
4363
|
+
} | {
|
|
4364
|
+
occurrenceHandle?: string | undefined;
|
|
4365
|
+
skippedFiles: number;
|
|
4366
|
+
occurrences: {
|
|
4367
|
+
before: string;
|
|
4368
|
+
after: string;
|
|
4369
|
+
id: string;
|
|
4370
|
+
path: string;
|
|
4371
|
+
line: number;
|
|
4372
|
+
}[];
|
|
4373
|
+
occurrencesTruncated: boolean;
|
|
4374
|
+
ok: boolean;
|
|
4375
|
+
dryRun: boolean;
|
|
4376
|
+
occurrenceCount: number;
|
|
4377
|
+
fileCount: number;
|
|
4378
|
+
error?: undefined;
|
|
4379
|
+
staleOccurrenceIds?: undefined;
|
|
4380
|
+
recoverable?: undefined;
|
|
4381
|
+
suggestedNextStep?: undefined;
|
|
4382
|
+
changedPaths?: undefined;
|
|
4383
|
+
uncertainPaths?: undefined;
|
|
4384
|
+
} | {
|
|
4385
|
+
ok: boolean;
|
|
4386
|
+
error: string;
|
|
4387
|
+
staleOccurrenceIds: string[];
|
|
4388
|
+
recoverable: boolean;
|
|
4389
|
+
suggestedNextStep: string;
|
|
4390
|
+
changedPaths?: undefined;
|
|
4391
|
+
uncertainPaths?: undefined;
|
|
4392
|
+
} | {
|
|
4393
|
+
ok: boolean;
|
|
4394
|
+
error: string;
|
|
4395
|
+
recoverable: boolean;
|
|
4396
|
+
staleOccurrenceIds?: undefined;
|
|
4397
|
+
suggestedNextStep?: undefined;
|
|
4398
|
+
changedPaths?: undefined;
|
|
4399
|
+
uncertainPaths?: undefined;
|
|
4400
|
+
} | {
|
|
4401
|
+
ok: boolean;
|
|
4402
|
+
changedPaths: string[];
|
|
4403
|
+
uncertainPaths: string[];
|
|
4404
|
+
error: string;
|
|
4405
|
+
recoverable: boolean;
|
|
4406
|
+
suggestedNextStep: string;
|
|
4407
|
+
staleOccurrenceIds?: undefined;
|
|
4408
|
+
} | {
|
|
4409
|
+
diffHandle?: string | undefined;
|
|
4410
|
+
ok: boolean;
|
|
4411
|
+
dryRun: boolean;
|
|
4412
|
+
changedPaths: string[];
|
|
4413
|
+
noChange: boolean;
|
|
4414
|
+
occurrenceCount: number;
|
|
4415
|
+
fileCount: number;
|
|
4416
|
+
diffLineCount: number;
|
|
4417
|
+
files: {
|
|
4418
|
+
diff: ToolDiffLine[];
|
|
4419
|
+
addedLines: number;
|
|
4420
|
+
removedLines: number;
|
|
4421
|
+
path: string;
|
|
4422
|
+
}[];
|
|
4423
|
+
error?: undefined;
|
|
4424
|
+
staleOccurrenceIds?: undefined;
|
|
4425
|
+
recoverable?: undefined;
|
|
4426
|
+
suggestedNextStep?: undefined;
|
|
4427
|
+
uncertainPaths?: undefined;
|
|
4428
|
+
}, NoInfer<import("./tools/toolContext.js").HazeToolContext>>;
|
|
4429
|
+
}) | ({
|
|
4430
|
+
deferLoading?: boolean;
|
|
4431
|
+
title?: string;
|
|
4432
|
+
providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
|
|
4433
|
+
metadata?: import("@ai-sdk/provider").JSONObject;
|
|
4434
|
+
inputSchema: import("ai").FlexibleSchema<{
|
|
4435
|
+
path: string;
|
|
4436
|
+
needle: string;
|
|
4437
|
+
replacement: string;
|
|
4438
|
+
mode: "literal" | "regex";
|
|
4439
|
+
dryRun: boolean;
|
|
4440
|
+
includeGlob?: string | undefined;
|
|
4441
|
+
excludeGlob?: string | undefined;
|
|
4442
|
+
occurrenceIds?: string[] | undefined;
|
|
4443
|
+
expectedCount?: number | undefined;
|
|
4444
|
+
}>;
|
|
4445
|
+
contextSchema?: import("ai").FlexibleSchema<import("./tools/toolContext.js").HazeToolContext> | undefined;
|
|
4446
|
+
needsApproval?: boolean | import("@ai-sdk/provider-utils").ToolNeedsApprovalFunction<{
|
|
4447
|
+
path: string;
|
|
4448
|
+
needle: string;
|
|
4449
|
+
replacement: string;
|
|
4450
|
+
mode: "literal" | "regex";
|
|
4451
|
+
dryRun: boolean;
|
|
4452
|
+
includeGlob?: string | undefined;
|
|
4453
|
+
excludeGlob?: string | undefined;
|
|
4454
|
+
occurrenceIds?: string[] | undefined;
|
|
4455
|
+
expectedCount?: number | undefined;
|
|
4456
|
+
}, NoInfer<import("./tools/toolContext.js").HazeToolContext>> | undefined;
|
|
4457
|
+
onInputStart?: ((options: import("ai").ToolExecutionOptions<NoInfer<import("./tools/toolContext.js").HazeToolContext>>) => void | PromiseLike<void>) | undefined;
|
|
4458
|
+
onInputDelta?: ((options: {
|
|
4459
|
+
inputTextDelta: string;
|
|
4460
|
+
} & import("ai").ToolExecutionOptions<NoInfer<import("./tools/toolContext.js").HazeToolContext>>) => void | PromiseLike<void>) | undefined;
|
|
4461
|
+
onInputAvailable?: ((options: {
|
|
4462
|
+
input: {
|
|
4463
|
+
path: string;
|
|
4464
|
+
needle: string;
|
|
4465
|
+
replacement: string;
|
|
4466
|
+
mode: "literal" | "regex";
|
|
4467
|
+
dryRun: boolean;
|
|
4468
|
+
includeGlob?: string | undefined;
|
|
4469
|
+
excludeGlob?: string | undefined;
|
|
4470
|
+
occurrenceIds?: string[] | undefined;
|
|
4471
|
+
expectedCount?: number | undefined;
|
|
4472
|
+
};
|
|
4473
|
+
} & import("ai").ToolExecutionOptions<NoInfer<import("./tools/toolContext.js").HazeToolContext>>) => void | PromiseLike<void>) | undefined;
|
|
4474
|
+
toModelOutput?: ((options: {
|
|
4475
|
+
toolCallId: string;
|
|
4476
|
+
input: {
|
|
4477
|
+
path: string;
|
|
4478
|
+
needle: string;
|
|
4479
|
+
replacement: string;
|
|
4480
|
+
mode: "literal" | "regex";
|
|
4481
|
+
dryRun: boolean;
|
|
4482
|
+
includeGlob?: string | undefined;
|
|
4483
|
+
excludeGlob?: string | undefined;
|
|
4484
|
+
occurrenceIds?: string[] | undefined;
|
|
4485
|
+
expectedCount?: number | undefined;
|
|
4486
|
+
};
|
|
4487
|
+
output: NoInfer<{
|
|
4488
|
+
suggestedPaths?: string[] | undefined;
|
|
4489
|
+
ok: boolean;
|
|
4490
|
+
toolName: string;
|
|
4491
|
+
path: string | undefined;
|
|
4492
|
+
error: string;
|
|
4493
|
+
reasonCode: import("./toolResultTypes.js").ToolFailureReasonCode | undefined;
|
|
4494
|
+
recoverable: boolean;
|
|
4495
|
+
suggestedNextStep: string;
|
|
4496
|
+
recoveryTool: string | undefined;
|
|
4497
|
+
recoveryInput: unknown;
|
|
4498
|
+
} | {
|
|
4499
|
+
ok: boolean;
|
|
4500
|
+
toolName: string;
|
|
4501
|
+
path: string;
|
|
4502
|
+
error: string;
|
|
4503
|
+
reasonCode: "scoped_instructions_discovered";
|
|
4504
|
+
recoverable: boolean;
|
|
4505
|
+
suggestedNextStep: string;
|
|
4506
|
+
applicableProjectInstructions: import("../config/contextFiles.js").ContextFile[];
|
|
4507
|
+
} | {
|
|
4508
|
+
ok: true;
|
|
4509
|
+
duplicateSkipped: true;
|
|
4510
|
+
toolName: string;
|
|
4511
|
+
reason: string;
|
|
4512
|
+
} | {
|
|
4513
|
+
occurrenceHandle?: string | undefined;
|
|
4514
|
+
skippedFiles: number;
|
|
4515
|
+
occurrences: {
|
|
4516
|
+
before: string;
|
|
4517
|
+
after: string;
|
|
4518
|
+
id: string;
|
|
4519
|
+
path: string;
|
|
4520
|
+
line: number;
|
|
4521
|
+
}[];
|
|
4522
|
+
occurrencesTruncated: boolean;
|
|
4523
|
+
ok: boolean;
|
|
4524
|
+
dryRun: boolean;
|
|
4525
|
+
occurrenceCount: number;
|
|
4526
|
+
fileCount: number;
|
|
4527
|
+
error?: undefined;
|
|
4528
|
+
staleOccurrenceIds?: undefined;
|
|
4529
|
+
recoverable?: undefined;
|
|
4530
|
+
suggestedNextStep?: undefined;
|
|
4531
|
+
changedPaths?: undefined;
|
|
4532
|
+
uncertainPaths?: undefined;
|
|
4533
|
+
} | {
|
|
4534
|
+
ok: boolean;
|
|
4535
|
+
error: string;
|
|
4536
|
+
staleOccurrenceIds: string[];
|
|
4537
|
+
recoverable: boolean;
|
|
4538
|
+
suggestedNextStep: string;
|
|
4539
|
+
changedPaths?: undefined;
|
|
4540
|
+
uncertainPaths?: undefined;
|
|
4541
|
+
} | {
|
|
4542
|
+
ok: boolean;
|
|
4543
|
+
error: string;
|
|
4544
|
+
recoverable: boolean;
|
|
4545
|
+
staleOccurrenceIds?: undefined;
|
|
4546
|
+
suggestedNextStep?: undefined;
|
|
4547
|
+
changedPaths?: undefined;
|
|
4548
|
+
uncertainPaths?: undefined;
|
|
4549
|
+
} | {
|
|
4550
|
+
ok: boolean;
|
|
4551
|
+
changedPaths: string[];
|
|
4552
|
+
uncertainPaths: string[];
|
|
4553
|
+
error: string;
|
|
4554
|
+
recoverable: boolean;
|
|
4555
|
+
suggestedNextStep: string;
|
|
4556
|
+
staleOccurrenceIds?: undefined;
|
|
4557
|
+
} | {
|
|
4558
|
+
diffHandle?: string | undefined;
|
|
4559
|
+
ok: boolean;
|
|
4560
|
+
dryRun: boolean;
|
|
4561
|
+
changedPaths: string[];
|
|
4562
|
+
noChange: boolean;
|
|
4563
|
+
occurrenceCount: number;
|
|
4564
|
+
fileCount: number;
|
|
4565
|
+
diffLineCount: number;
|
|
4566
|
+
files: {
|
|
4567
|
+
diff: ToolDiffLine[];
|
|
4568
|
+
addedLines: number;
|
|
4569
|
+
removedLines: number;
|
|
4570
|
+
path: string;
|
|
4571
|
+
}[];
|
|
4572
|
+
error?: undefined;
|
|
4573
|
+
staleOccurrenceIds?: undefined;
|
|
4574
|
+
recoverable?: undefined;
|
|
4575
|
+
suggestedNextStep?: undefined;
|
|
4576
|
+
uncertainPaths?: undefined;
|
|
4577
|
+
}>;
|
|
4578
|
+
}) => import("@ai-sdk/provider-utils").ToolResultOutput | PromiseLike<import("@ai-sdk/provider-utils").ToolResultOutput>) | undefined;
|
|
4579
|
+
} & {
|
|
4580
|
+
outputSchema?: import("ai").FlexibleSchema<{
|
|
4581
|
+
suggestedPaths?: string[] | undefined;
|
|
4582
|
+
ok: boolean;
|
|
4583
|
+
toolName: string;
|
|
4584
|
+
path: string | undefined;
|
|
4585
|
+
error: string;
|
|
4586
|
+
reasonCode: import("./toolResultTypes.js").ToolFailureReasonCode | undefined;
|
|
4587
|
+
recoverable: boolean;
|
|
4588
|
+
suggestedNextStep: string;
|
|
4589
|
+
recoveryTool: string | undefined;
|
|
4590
|
+
recoveryInput: unknown;
|
|
4591
|
+
} | {
|
|
4592
|
+
ok: boolean;
|
|
4593
|
+
toolName: string;
|
|
4594
|
+
path: string;
|
|
4595
|
+
error: string;
|
|
4596
|
+
reasonCode: "scoped_instructions_discovered";
|
|
4597
|
+
recoverable: boolean;
|
|
4598
|
+
suggestedNextStep: string;
|
|
4599
|
+
applicableProjectInstructions: import("../config/contextFiles.js").ContextFile[];
|
|
4600
|
+
} | {
|
|
4601
|
+
ok: true;
|
|
4602
|
+
duplicateSkipped: true;
|
|
4603
|
+
toolName: string;
|
|
4604
|
+
reason: string;
|
|
4605
|
+
} | {
|
|
4606
|
+
occurrenceHandle?: string | undefined;
|
|
4607
|
+
skippedFiles: number;
|
|
4608
|
+
occurrences: {
|
|
4609
|
+
before: string;
|
|
4610
|
+
after: string;
|
|
4611
|
+
id: string;
|
|
4612
|
+
path: string;
|
|
4613
|
+
line: number;
|
|
4614
|
+
}[];
|
|
4615
|
+
occurrencesTruncated: boolean;
|
|
4616
|
+
ok: boolean;
|
|
4617
|
+
dryRun: boolean;
|
|
4618
|
+
occurrenceCount: number;
|
|
4619
|
+
fileCount: number;
|
|
4620
|
+
error?: undefined;
|
|
4621
|
+
staleOccurrenceIds?: undefined;
|
|
4622
|
+
recoverable?: undefined;
|
|
4623
|
+
suggestedNextStep?: undefined;
|
|
4624
|
+
changedPaths?: undefined;
|
|
4625
|
+
uncertainPaths?: undefined;
|
|
4626
|
+
} | {
|
|
4627
|
+
ok: boolean;
|
|
4628
|
+
error: string;
|
|
4629
|
+
staleOccurrenceIds: string[];
|
|
4630
|
+
recoverable: boolean;
|
|
4631
|
+
suggestedNextStep: string;
|
|
4632
|
+
changedPaths?: undefined;
|
|
4633
|
+
uncertainPaths?: undefined;
|
|
4634
|
+
} | {
|
|
4635
|
+
ok: boolean;
|
|
4636
|
+
error: string;
|
|
4637
|
+
recoverable: boolean;
|
|
4638
|
+
staleOccurrenceIds?: undefined;
|
|
4639
|
+
suggestedNextStep?: undefined;
|
|
4640
|
+
changedPaths?: undefined;
|
|
4641
|
+
uncertainPaths?: undefined;
|
|
4642
|
+
} | {
|
|
4643
|
+
ok: boolean;
|
|
4644
|
+
changedPaths: string[];
|
|
4645
|
+
uncertainPaths: string[];
|
|
4646
|
+
error: string;
|
|
4647
|
+
recoverable: boolean;
|
|
4648
|
+
suggestedNextStep: string;
|
|
4649
|
+
staleOccurrenceIds?: undefined;
|
|
4650
|
+
} | {
|
|
4651
|
+
diffHandle?: string | undefined;
|
|
4652
|
+
ok: boolean;
|
|
4653
|
+
dryRun: boolean;
|
|
4654
|
+
changedPaths: string[];
|
|
4655
|
+
noChange: boolean;
|
|
4656
|
+
occurrenceCount: number;
|
|
4657
|
+
fileCount: number;
|
|
4658
|
+
diffLineCount: number;
|
|
4659
|
+
files: {
|
|
4660
|
+
diff: ToolDiffLine[];
|
|
4661
|
+
addedLines: number;
|
|
4662
|
+
removedLines: number;
|
|
4663
|
+
path: string;
|
|
4664
|
+
}[];
|
|
4665
|
+
error?: undefined;
|
|
4666
|
+
staleOccurrenceIds?: undefined;
|
|
4667
|
+
recoverable?: undefined;
|
|
4668
|
+
suggestedNextStep?: undefined;
|
|
4669
|
+
uncertainPaths?: undefined;
|
|
4670
|
+
}> | undefined;
|
|
4671
|
+
execute: import("ai").ToolExecuteFunction<{
|
|
4672
|
+
path: string;
|
|
4673
|
+
needle: string;
|
|
4674
|
+
replacement: string;
|
|
4675
|
+
mode: "literal" | "regex";
|
|
4676
|
+
dryRun: boolean;
|
|
4677
|
+
includeGlob?: string | undefined;
|
|
4678
|
+
excludeGlob?: string | undefined;
|
|
4679
|
+
occurrenceIds?: string[] | undefined;
|
|
4680
|
+
expectedCount?: number | undefined;
|
|
4681
|
+
}, {
|
|
4682
|
+
suggestedPaths?: string[] | undefined;
|
|
4683
|
+
ok: boolean;
|
|
4684
|
+
toolName: string;
|
|
4685
|
+
path: string | undefined;
|
|
4686
|
+
error: string;
|
|
4687
|
+
reasonCode: import("./toolResultTypes.js").ToolFailureReasonCode | undefined;
|
|
4688
|
+
recoverable: boolean;
|
|
4689
|
+
suggestedNextStep: string;
|
|
4690
|
+
recoveryTool: string | undefined;
|
|
4691
|
+
recoveryInput: unknown;
|
|
4692
|
+
} | {
|
|
4693
|
+
ok: boolean;
|
|
4694
|
+
toolName: string;
|
|
4695
|
+
path: string;
|
|
4696
|
+
error: string;
|
|
4697
|
+
reasonCode: "scoped_instructions_discovered";
|
|
4698
|
+
recoverable: boolean;
|
|
4699
|
+
suggestedNextStep: string;
|
|
4700
|
+
applicableProjectInstructions: import("../config/contextFiles.js").ContextFile[];
|
|
4701
|
+
} | {
|
|
4702
|
+
ok: true;
|
|
4703
|
+
duplicateSkipped: true;
|
|
4704
|
+
toolName: string;
|
|
4705
|
+
reason: string;
|
|
4706
|
+
} | {
|
|
4707
|
+
occurrenceHandle?: string | undefined;
|
|
4708
|
+
skippedFiles: number;
|
|
4709
|
+
occurrences: {
|
|
4710
|
+
before: string;
|
|
4711
|
+
after: string;
|
|
4712
|
+
id: string;
|
|
4713
|
+
path: string;
|
|
4714
|
+
line: number;
|
|
4715
|
+
}[];
|
|
4716
|
+
occurrencesTruncated: boolean;
|
|
4717
|
+
ok: boolean;
|
|
4718
|
+
dryRun: boolean;
|
|
4719
|
+
occurrenceCount: number;
|
|
4720
|
+
fileCount: number;
|
|
4721
|
+
error?: undefined;
|
|
4722
|
+
staleOccurrenceIds?: undefined;
|
|
4723
|
+
recoverable?: undefined;
|
|
4724
|
+
suggestedNextStep?: undefined;
|
|
4725
|
+
changedPaths?: undefined;
|
|
4726
|
+
uncertainPaths?: undefined;
|
|
4727
|
+
} | {
|
|
4728
|
+
ok: boolean;
|
|
4729
|
+
error: string;
|
|
4730
|
+
staleOccurrenceIds: string[];
|
|
4731
|
+
recoverable: boolean;
|
|
4732
|
+
suggestedNextStep: string;
|
|
4733
|
+
changedPaths?: undefined;
|
|
4734
|
+
uncertainPaths?: undefined;
|
|
4735
|
+
} | {
|
|
4736
|
+
ok: boolean;
|
|
4737
|
+
error: string;
|
|
4738
|
+
recoverable: boolean;
|
|
4739
|
+
staleOccurrenceIds?: undefined;
|
|
4740
|
+
suggestedNextStep?: undefined;
|
|
4741
|
+
changedPaths?: undefined;
|
|
4742
|
+
uncertainPaths?: undefined;
|
|
4743
|
+
} | {
|
|
4744
|
+
ok: boolean;
|
|
4745
|
+
changedPaths: string[];
|
|
4746
|
+
uncertainPaths: string[];
|
|
4747
|
+
error: string;
|
|
4748
|
+
recoverable: boolean;
|
|
4749
|
+
suggestedNextStep: string;
|
|
4750
|
+
staleOccurrenceIds?: undefined;
|
|
4751
|
+
} | {
|
|
4752
|
+
diffHandle?: string | undefined;
|
|
4753
|
+
ok: boolean;
|
|
4754
|
+
dryRun: boolean;
|
|
4755
|
+
changedPaths: string[];
|
|
4756
|
+
noChange: boolean;
|
|
4757
|
+
occurrenceCount: number;
|
|
4758
|
+
fileCount: number;
|
|
4759
|
+
diffLineCount: number;
|
|
4760
|
+
files: {
|
|
4761
|
+
diff: ToolDiffLine[];
|
|
4762
|
+
addedLines: number;
|
|
4763
|
+
removedLines: number;
|
|
4764
|
+
path: string;
|
|
4765
|
+
}[];
|
|
4766
|
+
error?: undefined;
|
|
4767
|
+
staleOccurrenceIds?: undefined;
|
|
4768
|
+
recoverable?: undefined;
|
|
4769
|
+
suggestedNextStep?: undefined;
|
|
4770
|
+
uncertainPaths?: undefined;
|
|
4771
|
+
}, NoInfer<import("./tools/toolContext.js").HazeToolContext>>;
|
|
4772
|
+
} & {
|
|
4773
|
+
type: "provider";
|
|
4774
|
+
id: `${string}.${string}`;
|
|
4775
|
+
args: Record<string, unknown>;
|
|
4776
|
+
description?: never;
|
|
4777
|
+
strict?: never;
|
|
4778
|
+
inputExamples?: never;
|
|
4779
|
+
} & {
|
|
4780
|
+
isProviderExecuted: true;
|
|
4781
|
+
supportsDeferredResults?: boolean;
|
|
4782
|
+
} & {
|
|
4783
|
+
execute: import("ai").ToolExecuteFunction<{
|
|
4784
|
+
path: string;
|
|
4785
|
+
needle: string;
|
|
4786
|
+
replacement: string;
|
|
4787
|
+
mode: "literal" | "regex";
|
|
4788
|
+
dryRun: boolean;
|
|
4789
|
+
includeGlob?: string | undefined;
|
|
4790
|
+
excludeGlob?: string | undefined;
|
|
4791
|
+
occurrenceIds?: string[] | undefined;
|
|
4792
|
+
expectedCount?: number | undefined;
|
|
4793
|
+
}, {
|
|
4794
|
+
suggestedPaths?: string[] | undefined;
|
|
4795
|
+
ok: boolean;
|
|
4796
|
+
toolName: string;
|
|
4797
|
+
path: string | undefined;
|
|
4798
|
+
error: string;
|
|
4799
|
+
reasonCode: import("./toolResultTypes.js").ToolFailureReasonCode | undefined;
|
|
4800
|
+
recoverable: boolean;
|
|
4801
|
+
suggestedNextStep: string;
|
|
4802
|
+
recoveryTool: string | undefined;
|
|
4803
|
+
recoveryInput: unknown;
|
|
4804
|
+
} | {
|
|
4805
|
+
ok: boolean;
|
|
4806
|
+
toolName: string;
|
|
4807
|
+
path: string;
|
|
4808
|
+
error: string;
|
|
4809
|
+
reasonCode: "scoped_instructions_discovered";
|
|
4810
|
+
recoverable: boolean;
|
|
4811
|
+
suggestedNextStep: string;
|
|
4812
|
+
applicableProjectInstructions: import("../config/contextFiles.js").ContextFile[];
|
|
4813
|
+
} | {
|
|
4814
|
+
ok: true;
|
|
4815
|
+
duplicateSkipped: true;
|
|
4816
|
+
toolName: string;
|
|
4817
|
+
reason: string;
|
|
4818
|
+
} | {
|
|
4819
|
+
occurrenceHandle?: string | undefined;
|
|
4820
|
+
skippedFiles: number;
|
|
4821
|
+
occurrences: {
|
|
4822
|
+
before: string;
|
|
4823
|
+
after: string;
|
|
4824
|
+
id: string;
|
|
4825
|
+
path: string;
|
|
4826
|
+
line: number;
|
|
4827
|
+
}[];
|
|
4828
|
+
occurrencesTruncated: boolean;
|
|
4829
|
+
ok: boolean;
|
|
4830
|
+
dryRun: boolean;
|
|
4831
|
+
occurrenceCount: number;
|
|
4832
|
+
fileCount: number;
|
|
4833
|
+
error?: undefined;
|
|
4834
|
+
staleOccurrenceIds?: undefined;
|
|
4835
|
+
recoverable?: undefined;
|
|
4836
|
+
suggestedNextStep?: undefined;
|
|
4837
|
+
changedPaths?: undefined;
|
|
4838
|
+
uncertainPaths?: undefined;
|
|
4839
|
+
} | {
|
|
4840
|
+
ok: boolean;
|
|
4841
|
+
error: string;
|
|
4842
|
+
staleOccurrenceIds: string[];
|
|
4843
|
+
recoverable: boolean;
|
|
4844
|
+
suggestedNextStep: string;
|
|
4845
|
+
changedPaths?: undefined;
|
|
4846
|
+
uncertainPaths?: undefined;
|
|
4847
|
+
} | {
|
|
4848
|
+
ok: boolean;
|
|
4849
|
+
error: string;
|
|
4850
|
+
recoverable: boolean;
|
|
4851
|
+
staleOccurrenceIds?: undefined;
|
|
4852
|
+
suggestedNextStep?: undefined;
|
|
4853
|
+
changedPaths?: undefined;
|
|
4854
|
+
uncertainPaths?: undefined;
|
|
4855
|
+
} | {
|
|
4856
|
+
ok: boolean;
|
|
4857
|
+
changedPaths: string[];
|
|
4858
|
+
uncertainPaths: string[];
|
|
4859
|
+
error: string;
|
|
4860
|
+
recoverable: boolean;
|
|
4861
|
+
suggestedNextStep: string;
|
|
4862
|
+
staleOccurrenceIds?: undefined;
|
|
4863
|
+
} | {
|
|
4864
|
+
diffHandle?: string | undefined;
|
|
4865
|
+
ok: boolean;
|
|
4866
|
+
dryRun: boolean;
|
|
4867
|
+
changedPaths: string[];
|
|
4868
|
+
noChange: boolean;
|
|
4869
|
+
occurrenceCount: number;
|
|
4870
|
+
fileCount: number;
|
|
4871
|
+
diffLineCount: number;
|
|
4872
|
+
files: {
|
|
4873
|
+
diff: ToolDiffLine[];
|
|
4874
|
+
addedLines: number;
|
|
4875
|
+
removedLines: number;
|
|
4876
|
+
path: string;
|
|
4877
|
+
}[];
|
|
4878
|
+
error?: undefined;
|
|
4879
|
+
staleOccurrenceIds?: undefined;
|
|
4880
|
+
recoverable?: undefined;
|
|
4881
|
+
suggestedNextStep?: undefined;
|
|
4882
|
+
uncertainPaths?: undefined;
|
|
4883
|
+
}, NoInfer<import("./tools/toolContext.js").HazeToolContext>>;
|
|
4884
|
+
});
|
|
2894
4885
|
replaceLines: ({
|
|
4886
|
+
deferLoading?: boolean;
|
|
2895
4887
|
title?: string;
|
|
2896
4888
|
providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
|
|
2897
4889
|
metadata?: import("@ai-sdk/provider").JSONObject;
|
|
@@ -3141,6 +5133,7 @@ export declare const hazeTools: {
|
|
|
3141
5133
|
removedLines: number;
|
|
3142
5134
|
}, NoInfer<import("./tools/toolContext.js").HazeToolContext>>;
|
|
3143
5135
|
}) | ({
|
|
5136
|
+
deferLoading?: boolean;
|
|
3144
5137
|
title?: string;
|
|
3145
5138
|
providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
|
|
3146
5139
|
metadata?: import("@ai-sdk/provider").JSONObject;
|
|
@@ -3390,6 +5383,7 @@ export declare const hazeTools: {
|
|
|
3390
5383
|
removedLines: number;
|
|
3391
5384
|
}, NoInfer<import("./tools/toolContext.js").HazeToolContext>>;
|
|
3392
5385
|
}) | ({
|
|
5386
|
+
deferLoading?: boolean;
|
|
3393
5387
|
title?: string;
|
|
3394
5388
|
providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
|
|
3395
5389
|
metadata?: import("@ai-sdk/provider").JSONObject;
|
|
@@ -3628,6 +5622,7 @@ export declare const hazeTools: {
|
|
|
3628
5622
|
removedLines: number;
|
|
3629
5623
|
}, NoInfer<import("./tools/toolContext.js").HazeToolContext>>;
|
|
3630
5624
|
}) | ({
|
|
5625
|
+
deferLoading?: boolean;
|
|
3631
5626
|
title?: string;
|
|
3632
5627
|
providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
|
|
3633
5628
|
metadata?: import("@ai-sdk/provider").JSONObject;
|
|
@@ -3867,6 +5862,7 @@ export declare const hazeTools: {
|
|
|
3867
5862
|
}, NoInfer<import("./tools/toolContext.js").HazeToolContext>>;
|
|
3868
5863
|
});
|
|
3869
5864
|
writeFile: ({
|
|
5865
|
+
deferLoading?: boolean;
|
|
3870
5866
|
title?: string;
|
|
3871
5867
|
providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
|
|
3872
5868
|
metadata?: import("@ai-sdk/provider").JSONObject;
|
|
@@ -4112,6 +6108,7 @@ export declare const hazeTools: {
|
|
|
4112
6108
|
diffComplete: boolean;
|
|
4113
6109
|
}, NoInfer<import("./tools/toolContext.js").HazeToolContext>>;
|
|
4114
6110
|
}) | ({
|
|
6111
|
+
deferLoading?: boolean;
|
|
4115
6112
|
title?: string;
|
|
4116
6113
|
providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
|
|
4117
6114
|
metadata?: import("@ai-sdk/provider").JSONObject;
|
|
@@ -4357,6 +6354,7 @@ export declare const hazeTools: {
|
|
|
4357
6354
|
diffComplete: boolean;
|
|
4358
6355
|
}, NoInfer<import("./tools/toolContext.js").HazeToolContext>>;
|
|
4359
6356
|
}) | ({
|
|
6357
|
+
deferLoading?: boolean;
|
|
4360
6358
|
title?: string;
|
|
4361
6359
|
providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
|
|
4362
6360
|
metadata?: import("@ai-sdk/provider").JSONObject;
|
|
@@ -4591,6 +6589,7 @@ export declare const hazeTools: {
|
|
|
4591
6589
|
diffComplete: boolean;
|
|
4592
6590
|
}, NoInfer<import("./tools/toolContext.js").HazeToolContext>>;
|
|
4593
6591
|
}) | ({
|
|
6592
|
+
deferLoading?: boolean;
|
|
4594
6593
|
title?: string;
|
|
4595
6594
|
providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
|
|
4596
6595
|
metadata?: import("@ai-sdk/provider").JSONObject;
|
|
@@ -4826,6 +6825,7 @@ export declare const hazeTools: {
|
|
|
4826
6825
|
}, NoInfer<import("./tools/toolContext.js").HazeToolContext>>;
|
|
4827
6826
|
});
|
|
4828
6827
|
editFile: ({
|
|
6828
|
+
deferLoading?: boolean;
|
|
4829
6829
|
title?: string;
|
|
4830
6830
|
providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
|
|
4831
6831
|
metadata?: import("@ai-sdk/provider").JSONObject;
|
|
@@ -5066,6 +7066,7 @@ export declare const hazeTools: {
|
|
|
5066
7066
|
removedLines: number;
|
|
5067
7067
|
}, NoInfer<import("./tools/toolContext.js").HazeToolContext>>;
|
|
5068
7068
|
}) | ({
|
|
7069
|
+
deferLoading?: boolean;
|
|
5069
7070
|
title?: string;
|
|
5070
7071
|
providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
|
|
5071
7072
|
metadata?: import("@ai-sdk/provider").JSONObject;
|
|
@@ -5306,6 +7307,7 @@ export declare const hazeTools: {
|
|
|
5306
7307
|
removedLines: number;
|
|
5307
7308
|
}, NoInfer<import("./tools/toolContext.js").HazeToolContext>>;
|
|
5308
7309
|
}) | ({
|
|
7310
|
+
deferLoading?: boolean;
|
|
5309
7311
|
title?: string;
|
|
5310
7312
|
providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
|
|
5311
7313
|
metadata?: import("@ai-sdk/provider").JSONObject;
|
|
@@ -5534,6 +7536,7 @@ export declare const hazeTools: {
|
|
|
5534
7536
|
removedLines: number;
|
|
5535
7537
|
}, NoInfer<import("./tools/toolContext.js").HazeToolContext>>;
|
|
5536
7538
|
}) | ({
|
|
7539
|
+
deferLoading?: boolean;
|
|
5537
7540
|
title?: string;
|
|
5538
7541
|
providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
|
|
5539
7542
|
metadata?: import("@ai-sdk/provider").JSONObject;
|
|
@@ -5763,6 +7766,7 @@ export declare const hazeTools: {
|
|
|
5763
7766
|
}, NoInfer<import("./tools/toolContext.js").HazeToolContext>>;
|
|
5764
7767
|
});
|
|
5765
7768
|
writeTasks: ({
|
|
7769
|
+
deferLoading?: boolean;
|
|
5766
7770
|
title?: string;
|
|
5767
7771
|
providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
|
|
5768
7772
|
metadata?: import("@ai-sdk/provider").JSONObject;
|
|
@@ -5889,6 +7893,7 @@ export declare const hazeTools: {
|
|
|
5889
7893
|
error?: undefined;
|
|
5890
7894
|
}, NoInfer<import("@ai-sdk/provider-utils").Context>>;
|
|
5891
7895
|
}) | ({
|
|
7896
|
+
deferLoading?: boolean;
|
|
5892
7897
|
title?: string;
|
|
5893
7898
|
providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
|
|
5894
7899
|
metadata?: import("@ai-sdk/provider").JSONObject;
|
|
@@ -6015,6 +8020,7 @@ export declare const hazeTools: {
|
|
|
6015
8020
|
error?: undefined;
|
|
6016
8021
|
}, NoInfer<import("@ai-sdk/provider-utils").Context>>;
|
|
6017
8022
|
}) | ({
|
|
8023
|
+
deferLoading?: boolean;
|
|
6018
8024
|
title?: string;
|
|
6019
8025
|
providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
|
|
6020
8026
|
metadata?: import("@ai-sdk/provider").JSONObject;
|
|
@@ -6131,6 +8137,7 @@ export declare const hazeTools: {
|
|
|
6131
8137
|
error?: undefined;
|
|
6132
8138
|
}, NoInfer<import("@ai-sdk/provider-utils").Context>>;
|
|
6133
8139
|
}) | ({
|
|
8140
|
+
deferLoading?: boolean;
|
|
6134
8141
|
title?: string;
|
|
6135
8142
|
providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
|
|
6136
8143
|
metadata?: import("@ai-sdk/provider").JSONObject;
|
|
@@ -6248,6 +8255,7 @@ export declare const hazeTools: {
|
|
|
6248
8255
|
}, NoInfer<import("@ai-sdk/provider-utils").Context>>;
|
|
6249
8256
|
});
|
|
6250
8257
|
readToolOutput: ({
|
|
8258
|
+
deferLoading?: boolean;
|
|
6251
8259
|
title?: string;
|
|
6252
8260
|
providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
|
|
6253
8261
|
metadata?: import("@ai-sdk/provider").JSONObject;
|
|
@@ -6341,6 +8349,7 @@ export declare const hazeTools: {
|
|
|
6341
8349
|
error: string;
|
|
6342
8350
|
}, NoInfer<import("@ai-sdk/provider-utils").Context>>;
|
|
6343
8351
|
}) | ({
|
|
8352
|
+
deferLoading?: boolean;
|
|
6344
8353
|
title?: string;
|
|
6345
8354
|
providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
|
|
6346
8355
|
metadata?: import("@ai-sdk/provider").JSONObject;
|
|
@@ -6434,6 +8443,7 @@ export declare const hazeTools: {
|
|
|
6434
8443
|
error: string;
|
|
6435
8444
|
}, NoInfer<import("@ai-sdk/provider-utils").Context>>;
|
|
6436
8445
|
}) | ({
|
|
8446
|
+
deferLoading?: boolean;
|
|
6437
8447
|
title?: string;
|
|
6438
8448
|
providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
|
|
6439
8449
|
metadata?: import("@ai-sdk/provider").JSONObject;
|
|
@@ -6516,6 +8526,7 @@ export declare const hazeTools: {
|
|
|
6516
8526
|
error: string;
|
|
6517
8527
|
}, NoInfer<import("@ai-sdk/provider-utils").Context>>;
|
|
6518
8528
|
}) | ({
|
|
8529
|
+
deferLoading?: boolean;
|
|
6519
8530
|
title?: string;
|
|
6520
8531
|
providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
|
|
6521
8532
|
metadata?: import("@ai-sdk/provider").JSONObject;
|
|
@@ -6599,6 +8610,7 @@ export declare const hazeTools: {
|
|
|
6599
8610
|
}, NoInfer<import("@ai-sdk/provider-utils").Context>>;
|
|
6600
8611
|
});
|
|
6601
8612
|
fetch: ({
|
|
8613
|
+
deferLoading?: boolean;
|
|
6602
8614
|
title?: string;
|
|
6603
8615
|
providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
|
|
6604
8616
|
metadata?: import("@ai-sdk/provider").JSONObject;
|
|
@@ -6907,6 +8919,7 @@ export declare const hazeTools: {
|
|
|
6907
8919
|
parseTier: string;
|
|
6908
8920
|
}, NoInfer<import("./tools/toolContext.js").HazeToolContext>>;
|
|
6909
8921
|
}) | ({
|
|
8922
|
+
deferLoading?: boolean;
|
|
6910
8923
|
title?: string;
|
|
6911
8924
|
providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
|
|
6912
8925
|
metadata?: import("@ai-sdk/provider").JSONObject;
|
|
@@ -7215,6 +9228,7 @@ export declare const hazeTools: {
|
|
|
7215
9228
|
parseTier: string;
|
|
7216
9229
|
}, NoInfer<import("./tools/toolContext.js").HazeToolContext>>;
|
|
7217
9230
|
}) | ({
|
|
9231
|
+
deferLoading?: boolean;
|
|
7218
9232
|
title?: string;
|
|
7219
9233
|
providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
|
|
7220
9234
|
metadata?: import("@ai-sdk/provider").JSONObject;
|
|
@@ -7515,6 +9529,7 @@ export declare const hazeTools: {
|
|
|
7515
9529
|
parseTier: string;
|
|
7516
9530
|
}, NoInfer<import("./tools/toolContext.js").HazeToolContext>>;
|
|
7517
9531
|
}) | ({
|
|
9532
|
+
deferLoading?: boolean;
|
|
7518
9533
|
title?: string;
|
|
7519
9534
|
providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
|
|
7520
9535
|
metadata?: import("@ai-sdk/provider").JSONObject;
|
|
@@ -7816,6 +9831,7 @@ export declare const hazeTools: {
|
|
|
7816
9831
|
}, NoInfer<import("./tools/toolContext.js").HazeToolContext>>;
|
|
7817
9832
|
});
|
|
7818
9833
|
shell: ({
|
|
9834
|
+
deferLoading?: boolean;
|
|
7819
9835
|
title?: string;
|
|
7820
9836
|
providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
|
|
7821
9837
|
metadata?: import("@ai-sdk/provider").JSONObject;
|
|
@@ -8194,6 +10210,7 @@ export declare const hazeTools: {
|
|
|
8194
10210
|
background?: undefined;
|
|
8195
10211
|
}, NoInfer<import("./tools/toolContext.js").HazeToolContext>>;
|
|
8196
10212
|
}) | ({
|
|
10213
|
+
deferLoading?: boolean;
|
|
8197
10214
|
title?: string;
|
|
8198
10215
|
providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
|
|
8199
10216
|
metadata?: import("@ai-sdk/provider").JSONObject;
|
|
@@ -8572,6 +10589,7 @@ export declare const hazeTools: {
|
|
|
8572
10589
|
background?: undefined;
|
|
8573
10590
|
}, NoInfer<import("./tools/toolContext.js").HazeToolContext>>;
|
|
8574
10591
|
}) | ({
|
|
10592
|
+
deferLoading?: boolean;
|
|
8575
10593
|
title?: string;
|
|
8576
10594
|
providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
|
|
8577
10595
|
metadata?: import("@ai-sdk/provider").JSONObject;
|
|
@@ -8940,6 +10958,7 @@ export declare const hazeTools: {
|
|
|
8940
10958
|
background?: undefined;
|
|
8941
10959
|
}, NoInfer<import("./tools/toolContext.js").HazeToolContext>>;
|
|
8942
10960
|
}) | ({
|
|
10961
|
+
deferLoading?: boolean;
|
|
8943
10962
|
title?: string;
|
|
8944
10963
|
providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
|
|
8945
10964
|
metadata?: import("@ai-sdk/provider").JSONObject;
|
|
@@ -9309,6 +11328,7 @@ export declare const hazeTools: {
|
|
|
9309
11328
|
}, NoInfer<import("./tools/toolContext.js").HazeToolContext>>;
|
|
9310
11329
|
});
|
|
9311
11330
|
process: ({
|
|
11331
|
+
deferLoading?: boolean;
|
|
9312
11332
|
title?: string;
|
|
9313
11333
|
providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
|
|
9314
11334
|
metadata?: import("@ai-sdk/provider").JSONObject;
|
|
@@ -9583,6 +11603,7 @@ export declare const hazeTools: {
|
|
|
9583
11603
|
processes?: undefined;
|
|
9584
11604
|
}, NoInfer<import("./tools/toolContext.js").HazeToolContext>>;
|
|
9585
11605
|
}) | ({
|
|
11606
|
+
deferLoading?: boolean;
|
|
9586
11607
|
title?: string;
|
|
9587
11608
|
providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
|
|
9588
11609
|
metadata?: import("@ai-sdk/provider").JSONObject;
|
|
@@ -9857,6 +11878,7 @@ export declare const hazeTools: {
|
|
|
9857
11878
|
processes?: undefined;
|
|
9858
11879
|
}, NoInfer<import("./tools/toolContext.js").HazeToolContext>>;
|
|
9859
11880
|
}) | ({
|
|
11881
|
+
deferLoading?: boolean;
|
|
9860
11882
|
title?: string;
|
|
9861
11883
|
providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
|
|
9862
11884
|
metadata?: import("@ai-sdk/provider").JSONObject;
|
|
@@ -10121,6 +12143,7 @@ export declare const hazeTools: {
|
|
|
10121
12143
|
processes?: undefined;
|
|
10122
12144
|
}, NoInfer<import("./tools/toolContext.js").HazeToolContext>>;
|
|
10123
12145
|
}) | ({
|
|
12146
|
+
deferLoading?: boolean;
|
|
10124
12147
|
title?: string;
|
|
10125
12148
|
providerOptions?: import("@ai-sdk/provider-utils").ProviderOptions;
|
|
10126
12149
|
metadata?: import("@ai-sdk/provider").JSONObject;
|