@neovate/code 0.23.0 → 0.24.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/dist/cli.mjs +718 -690
- package/dist/index.d.ts +98 -1
- package/dist/index.mjs +714 -686
- package/package.json +6 -5
package/dist/index.d.ts
CHANGED
|
@@ -80,6 +80,7 @@ declare class AgentManager {
|
|
|
80
80
|
tools: Tool[];
|
|
81
81
|
cwd: string;
|
|
82
82
|
signal?: AbortSignal;
|
|
83
|
+
parentSessionId?: string;
|
|
83
84
|
forkContextMessages?: NormalizedMessage[];
|
|
84
85
|
onMessage?: (message: NormalizedMessage, agentId: string, model: string) => void | Promise<void>;
|
|
85
86
|
onToolApprove?: (opts: {
|
|
@@ -139,6 +140,32 @@ declare type ApprovalContext = {
|
|
|
139
140
|
|
|
140
141
|
declare type ApprovalMode = 'default' | 'autoEdit' | 'yolo';
|
|
141
142
|
|
|
143
|
+
export declare type Argv = {
|
|
144
|
+
_: string[];
|
|
145
|
+
help: boolean;
|
|
146
|
+
mcp: boolean;
|
|
147
|
+
quiet: boolean;
|
|
148
|
+
continue?: boolean;
|
|
149
|
+
version: boolean;
|
|
150
|
+
appendSystemPrompt?: string;
|
|
151
|
+
approvalMode?: string;
|
|
152
|
+
cwd?: string;
|
|
153
|
+
host?: string;
|
|
154
|
+
language?: string;
|
|
155
|
+
model?: string;
|
|
156
|
+
outputFormat?: string;
|
|
157
|
+
outputStyle?: string;
|
|
158
|
+
planModel?: string;
|
|
159
|
+
smallModel?: string;
|
|
160
|
+
visionModel?: string;
|
|
161
|
+
resume?: string;
|
|
162
|
+
systemPrompt?: string;
|
|
163
|
+
tools?: string;
|
|
164
|
+
port?: number;
|
|
165
|
+
plugin: string[];
|
|
166
|
+
mcpConfig: string[];
|
|
167
|
+
};
|
|
168
|
+
|
|
142
169
|
declare type AssistantContent = string | Array<TextPart | ReasoningPart | ToolUsePart>;
|
|
143
170
|
|
|
144
171
|
declare type AssistantMessage = {
|
|
@@ -236,6 +263,14 @@ declare type Config = {
|
|
|
236
263
|
* Example: { explore: { model: "anthropic/claude-haiku-4" } }
|
|
237
264
|
*/
|
|
238
265
|
agent?: Record<string, AgentConfig>;
|
|
266
|
+
/**
|
|
267
|
+
* Notification configuration.
|
|
268
|
+
* - true: play default sound (Funk/warning)
|
|
269
|
+
* - false: disabled
|
|
270
|
+
* - string: custom sound name (e.g., "Glass", "Ping")
|
|
271
|
+
* - object: extended notification config (reserved for future use, e.g., url)
|
|
272
|
+
*/
|
|
273
|
+
notification?: boolean | string;
|
|
239
274
|
};
|
|
240
275
|
|
|
241
276
|
declare type ConfigGetInput = {
|
|
@@ -308,6 +343,7 @@ export declare class Context {
|
|
|
308
343
|
messageBus?: MessageBus;
|
|
309
344
|
agentManager?: AgentManager;
|
|
310
345
|
plugins: (string | Plugin_2)[];
|
|
346
|
+
fetch?: typeof globalThis.fetch;
|
|
311
347
|
constructor(opts: ContextOpts);
|
|
312
348
|
apply(applyOpts: Omit<PluginApplyOpts, 'pluginContext'>): Promise<any>;
|
|
313
349
|
destroy(): Promise<void>;
|
|
@@ -322,6 +358,7 @@ declare type ContextCreateOpts = {
|
|
|
322
358
|
argvConfig: Record<string, any>;
|
|
323
359
|
plugins: (string | Plugin_2)[];
|
|
324
360
|
messageBus?: MessageBus;
|
|
361
|
+
fetch?: typeof globalThis.fetch;
|
|
325
362
|
};
|
|
326
363
|
|
|
327
364
|
declare type ContextOpts = {
|
|
@@ -339,6 +376,7 @@ declare type ContextOpts = {
|
|
|
339
376
|
messageBus?: MessageBus;
|
|
340
377
|
agentManager?: AgentManager;
|
|
341
378
|
plugins: (string | Plugin_2)[];
|
|
379
|
+
fetch?: typeof globalThis.fetch;
|
|
342
380
|
};
|
|
343
381
|
|
|
344
382
|
export declare function createSession(options: SDKSessionOptions): Promise<SDKSession>;
|
|
@@ -741,6 +779,10 @@ declare type HandlerMap = {
|
|
|
741
779
|
input: UtilsGetPathsInput;
|
|
742
780
|
output: UtilsGetPathsOutput;
|
|
743
781
|
};
|
|
782
|
+
'utils.searchPaths': {
|
|
783
|
+
input: UtilsSearchPathsInput;
|
|
784
|
+
output: UtilsSearchPathsOutput;
|
|
785
|
+
};
|
|
744
786
|
'utils.telemetry': {
|
|
745
787
|
input: UtilsTelemetryInput;
|
|
746
788
|
output: SuccessResponse;
|
|
@@ -1040,9 +1082,17 @@ declare type ModelsListOutput = {
|
|
|
1040
1082
|
modelId: string;
|
|
1041
1083
|
modelContextLimit: number;
|
|
1042
1084
|
} | null;
|
|
1085
|
+
nullModels: Array<{
|
|
1086
|
+
providerId: string;
|
|
1087
|
+
modelId: string;
|
|
1088
|
+
}>;
|
|
1043
1089
|
};
|
|
1044
1090
|
};
|
|
1045
1091
|
|
|
1092
|
+
declare type NodeBridgeHandlers = Partial<{
|
|
1093
|
+
[K in keyof HandlerMap]: (data: HandlerMap[K]['input'], context: Context) => Promise<HandlerMap[K]['output']> | HandlerMap[K]['output'];
|
|
1094
|
+
}>;
|
|
1095
|
+
|
|
1046
1096
|
declare type NormalizedMessage = Message_2 & {
|
|
1047
1097
|
type: 'message';
|
|
1048
1098
|
timestamp: string;
|
|
@@ -1087,6 +1137,8 @@ declare type OutputStylesListOutput = {
|
|
|
1087
1137
|
};
|
|
1088
1138
|
};
|
|
1089
1139
|
|
|
1140
|
+
export declare function parseArgs(argv: any): Promise<Argv>;
|
|
1141
|
+
|
|
1090
1142
|
declare class Paths {
|
|
1091
1143
|
globalConfigDir: string;
|
|
1092
1144
|
globalProjectDir: string;
|
|
@@ -1176,6 +1228,29 @@ declare type Plugin_2 = {
|
|
|
1176
1228
|
name: string;
|
|
1177
1229
|
payload: Record<string, any>;
|
|
1178
1230
|
}) => Promise<void> | void;
|
|
1231
|
+
stop?: (this: PluginContext, opts: {
|
|
1232
|
+
sessionId: string;
|
|
1233
|
+
result: LoopResult;
|
|
1234
|
+
usage: Usage;
|
|
1235
|
+
turnsCount: number;
|
|
1236
|
+
toolCallsCount: number;
|
|
1237
|
+
duration: number;
|
|
1238
|
+
model: string;
|
|
1239
|
+
}) => Promise<void> | void;
|
|
1240
|
+
subagentStop?: (this: PluginContext, opts: {
|
|
1241
|
+
parentSessionId: string;
|
|
1242
|
+
agentId: string;
|
|
1243
|
+
agentType: string;
|
|
1244
|
+
result: AgentExecutionResult;
|
|
1245
|
+
usage: {
|
|
1246
|
+
inputTokens: number;
|
|
1247
|
+
outputTokens: number;
|
|
1248
|
+
};
|
|
1249
|
+
totalToolCalls: number;
|
|
1250
|
+
totalDuration: number;
|
|
1251
|
+
model: string;
|
|
1252
|
+
}) => Promise<void> | void;
|
|
1253
|
+
nodeBridgeHandler?: (this: PluginContext) => Promise<NodeBridgeHandlers> | NodeBridgeHandlers;
|
|
1179
1254
|
};
|
|
1180
1255
|
export { Plugin_2 as Plugin }
|
|
1181
1256
|
|
|
@@ -1430,6 +1505,10 @@ declare type ProvidersListOutput = {
|
|
|
1430
1505
|
apiEnv?: string[];
|
|
1431
1506
|
validEnvs: string[];
|
|
1432
1507
|
hasApiKey: boolean;
|
|
1508
|
+
maskedApiKey?: string;
|
|
1509
|
+
apiKeyOrigin?: 'env' | 'config';
|
|
1510
|
+
apiKeyEnvName?: string;
|
|
1511
|
+
oauthUser?: string;
|
|
1433
1512
|
}>;
|
|
1434
1513
|
};
|
|
1435
1514
|
};
|
|
@@ -1485,7 +1564,11 @@ export declare function runNeovate(opts: {
|
|
|
1485
1564
|
version: string;
|
|
1486
1565
|
plugins: Plugin_2[];
|
|
1487
1566
|
upgrade?: UpgradeOptions;
|
|
1488
|
-
|
|
1567
|
+
argv: Argv;
|
|
1568
|
+
fetch?: typeof globalThis.fetch;
|
|
1569
|
+
}): Promise<{
|
|
1570
|
+
shutdown?: () => Promise<void>;
|
|
1571
|
+
}>;
|
|
1489
1572
|
|
|
1490
1573
|
export declare type SDKMessage = NormalizedMessage | SDKSystemMessage | SDKResultMessage;
|
|
1491
1574
|
|
|
@@ -2111,6 +2194,20 @@ declare type UtilsQuickQueryInput = {
|
|
|
2111
2194
|
|
|
2112
2195
|
declare type UtilsQuickQueryOutput = any;
|
|
2113
2196
|
|
|
2197
|
+
declare type UtilsSearchPathsInput = {
|
|
2198
|
+
cwd: string;
|
|
2199
|
+
query: string;
|
|
2200
|
+
maxResults?: number;
|
|
2201
|
+
};
|
|
2202
|
+
|
|
2203
|
+
declare type UtilsSearchPathsOutput = {
|
|
2204
|
+
success: boolean;
|
|
2205
|
+
data: {
|
|
2206
|
+
paths: string[];
|
|
2207
|
+
truncated: boolean;
|
|
2208
|
+
};
|
|
2209
|
+
};
|
|
2210
|
+
|
|
2114
2211
|
declare type UtilsSummarizeMessageInput = {
|
|
2115
2212
|
message: string;
|
|
2116
2213
|
cwd: string;
|