universal-agent-memory 1.0.17 → 1.0.19

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1121,6 +1121,272 @@ export declare const TimeOptimizationSchema: z.ZodObject<{
1121
1121
  prewarmServices?: string[] | undefined;
1122
1122
  } | undefined;
1123
1123
  }>;
1124
+ /**
1125
+ * Model configuration for multi-model architecture
1126
+ */
1127
+ export declare const ModelConfigSchema: z.ZodObject<{
1128
+ id: z.ZodString;
1129
+ name: z.ZodString;
1130
+ provider: z.ZodEnum<["anthropic", "deepseek", "openai", "zhipu", "ollama", "custom"]>;
1131
+ apiModel: z.ZodString;
1132
+ endpoint: z.ZodOptional<z.ZodString>;
1133
+ apiKeyEnvVar: z.ZodOptional<z.ZodString>;
1134
+ maxContextTokens: z.ZodDefault<z.ZodNumber>;
1135
+ costPer1MInput: z.ZodOptional<z.ZodNumber>;
1136
+ costPer1MOutput: z.ZodOptional<z.ZodNumber>;
1137
+ capabilities: z.ZodDefault<z.ZodArray<z.ZodString, "many">>;
1138
+ }, "strip", z.ZodTypeAny, {
1139
+ provider: "custom" | "anthropic" | "deepseek" | "openai" | "zhipu" | "ollama";
1140
+ name: string;
1141
+ maxContextTokens: number;
1142
+ id: string;
1143
+ apiModel: string;
1144
+ capabilities: string[];
1145
+ endpoint?: string | undefined;
1146
+ apiKeyEnvVar?: string | undefined;
1147
+ costPer1MInput?: number | undefined;
1148
+ costPer1MOutput?: number | undefined;
1149
+ }, {
1150
+ provider: "custom" | "anthropic" | "deepseek" | "openai" | "zhipu" | "ollama";
1151
+ name: string;
1152
+ id: string;
1153
+ apiModel: string;
1154
+ endpoint?: string | undefined;
1155
+ maxContextTokens?: number | undefined;
1156
+ apiKeyEnvVar?: string | undefined;
1157
+ costPer1MInput?: number | undefined;
1158
+ costPer1MOutput?: number | undefined;
1159
+ capabilities?: string[] | undefined;
1160
+ }>;
1161
+ /**
1162
+ * Routing rule for task-to-model mapping
1163
+ */
1164
+ export declare const RoutingRuleSchema: z.ZodObject<{
1165
+ complexity: z.ZodOptional<z.ZodEnum<["low", "medium", "high", "critical"]>>;
1166
+ keywords: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
1167
+ taskType: z.ZodOptional<z.ZodEnum<["planning", "coding", "refactoring", "bug-fix", "review", "documentation"]>>;
1168
+ targetRole: z.ZodEnum<["planner", "executor", "reviewer", "fallback"]>;
1169
+ priority: z.ZodDefault<z.ZodNumber>;
1170
+ }, "strip", z.ZodTypeAny, {
1171
+ targetRole: "planner" | "executor" | "reviewer" | "fallback";
1172
+ priority: number;
1173
+ complexity?: "low" | "medium" | "high" | "critical" | undefined;
1174
+ keywords?: string[] | undefined;
1175
+ taskType?: "planning" | "coding" | "refactoring" | "bug-fix" | "review" | "documentation" | undefined;
1176
+ }, {
1177
+ targetRole: "planner" | "executor" | "reviewer" | "fallback";
1178
+ complexity?: "low" | "medium" | "high" | "critical" | undefined;
1179
+ keywords?: string[] | undefined;
1180
+ taskType?: "planning" | "coding" | "refactoring" | "bug-fix" | "review" | "documentation" | undefined;
1181
+ priority?: number | undefined;
1182
+ }>;
1183
+ /**
1184
+ * NEW: Multi-Model Architecture configuration.
1185
+ * Enables two-tier agentic architecture with separate planner and executor models.
1186
+ */
1187
+ export declare const MultiModelSchema: z.ZodObject<{
1188
+ enabled: z.ZodDefault<z.ZodBoolean>;
1189
+ models: z.ZodDefault<z.ZodArray<z.ZodUnion<[z.ZodString, z.ZodObject<{
1190
+ id: z.ZodString;
1191
+ name: z.ZodString;
1192
+ provider: z.ZodEnum<["anthropic", "deepseek", "openai", "zhipu", "ollama", "custom"]>;
1193
+ apiModel: z.ZodString;
1194
+ endpoint: z.ZodOptional<z.ZodString>;
1195
+ apiKeyEnvVar: z.ZodOptional<z.ZodString>;
1196
+ maxContextTokens: z.ZodDefault<z.ZodNumber>;
1197
+ costPer1MInput: z.ZodOptional<z.ZodNumber>;
1198
+ costPer1MOutput: z.ZodOptional<z.ZodNumber>;
1199
+ capabilities: z.ZodDefault<z.ZodArray<z.ZodString, "many">>;
1200
+ }, "strip", z.ZodTypeAny, {
1201
+ provider: "custom" | "anthropic" | "deepseek" | "openai" | "zhipu" | "ollama";
1202
+ name: string;
1203
+ maxContextTokens: number;
1204
+ id: string;
1205
+ apiModel: string;
1206
+ capabilities: string[];
1207
+ endpoint?: string | undefined;
1208
+ apiKeyEnvVar?: string | undefined;
1209
+ costPer1MInput?: number | undefined;
1210
+ costPer1MOutput?: number | undefined;
1211
+ }, {
1212
+ provider: "custom" | "anthropic" | "deepseek" | "openai" | "zhipu" | "ollama";
1213
+ name: string;
1214
+ id: string;
1215
+ apiModel: string;
1216
+ endpoint?: string | undefined;
1217
+ maxContextTokens?: number | undefined;
1218
+ apiKeyEnvVar?: string | undefined;
1219
+ costPer1MInput?: number | undefined;
1220
+ costPer1MOutput?: number | undefined;
1221
+ capabilities?: string[] | undefined;
1222
+ }>]>, "many">>;
1223
+ roles: z.ZodOptional<z.ZodObject<{
1224
+ planner: z.ZodDefault<z.ZodString>;
1225
+ executor: z.ZodDefault<z.ZodString>;
1226
+ reviewer: z.ZodOptional<z.ZodString>;
1227
+ fallback: z.ZodDefault<z.ZodString>;
1228
+ }, "strip", z.ZodTypeAny, {
1229
+ planner: string;
1230
+ executor: string;
1231
+ fallback: string;
1232
+ reviewer?: string | undefined;
1233
+ }, {
1234
+ planner?: string | undefined;
1235
+ executor?: string | undefined;
1236
+ reviewer?: string | undefined;
1237
+ fallback?: string | undefined;
1238
+ }>>;
1239
+ routing: z.ZodOptional<z.ZodArray<z.ZodObject<{
1240
+ complexity: z.ZodOptional<z.ZodEnum<["low", "medium", "high", "critical"]>>;
1241
+ keywords: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
1242
+ taskType: z.ZodOptional<z.ZodEnum<["planning", "coding", "refactoring", "bug-fix", "review", "documentation"]>>;
1243
+ targetRole: z.ZodEnum<["planner", "executor", "reviewer", "fallback"]>;
1244
+ priority: z.ZodDefault<z.ZodNumber>;
1245
+ }, "strip", z.ZodTypeAny, {
1246
+ targetRole: "planner" | "executor" | "reviewer" | "fallback";
1247
+ priority: number;
1248
+ complexity?: "low" | "medium" | "high" | "critical" | undefined;
1249
+ keywords?: string[] | undefined;
1250
+ taskType?: "planning" | "coding" | "refactoring" | "bug-fix" | "review" | "documentation" | undefined;
1251
+ }, {
1252
+ targetRole: "planner" | "executor" | "reviewer" | "fallback";
1253
+ complexity?: "low" | "medium" | "high" | "critical" | undefined;
1254
+ keywords?: string[] | undefined;
1255
+ taskType?: "planning" | "coding" | "refactoring" | "bug-fix" | "review" | "documentation" | undefined;
1256
+ priority?: number | undefined;
1257
+ }>, "many">>;
1258
+ routingStrategy: z.ZodDefault<z.ZodEnum<["cost-optimized", "performance-first", "balanced", "adaptive"]>>;
1259
+ costOptimization: z.ZodOptional<z.ZodObject<{
1260
+ enabled: z.ZodDefault<z.ZodBoolean>;
1261
+ targetReduction: z.ZodDefault<z.ZodNumber>;
1262
+ maxPerformanceDegradation: z.ZodDefault<z.ZodNumber>;
1263
+ fallbackThreshold: z.ZodDefault<z.ZodNumber>;
1264
+ }, "strip", z.ZodTypeAny, {
1265
+ enabled: boolean;
1266
+ targetReduction: number;
1267
+ maxPerformanceDegradation: number;
1268
+ fallbackThreshold: number;
1269
+ }, {
1270
+ enabled?: boolean | undefined;
1271
+ targetReduction?: number | undefined;
1272
+ maxPerformanceDegradation?: number | undefined;
1273
+ fallbackThreshold?: number | undefined;
1274
+ }>>;
1275
+ plannerSettings: z.ZodOptional<z.ZodObject<{
1276
+ complexityThreshold: z.ZodDefault<z.ZodEnum<["low", "medium", "high"]>>;
1277
+ maxPlanningTokens: z.ZodDefault<z.ZodNumber>;
1278
+ enableDecomposition: z.ZodDefault<z.ZodBoolean>;
1279
+ }, "strip", z.ZodTypeAny, {
1280
+ complexityThreshold: "low" | "medium" | "high";
1281
+ maxPlanningTokens: number;
1282
+ enableDecomposition: boolean;
1283
+ }, {
1284
+ complexityThreshold?: "low" | "medium" | "high" | undefined;
1285
+ maxPlanningTokens?: number | undefined;
1286
+ enableDecomposition?: boolean | undefined;
1287
+ }>>;
1288
+ executorSettings: z.ZodOptional<z.ZodObject<{
1289
+ retryWithFallback: z.ZodDefault<z.ZodBoolean>;
1290
+ maxRetries: z.ZodDefault<z.ZodNumber>;
1291
+ stepTimeout: z.ZodDefault<z.ZodNumber>;
1292
+ }, "strip", z.ZodTypeAny, {
1293
+ retryWithFallback: boolean;
1294
+ maxRetries: number;
1295
+ stepTimeout: number;
1296
+ }, {
1297
+ retryWithFallback?: boolean | undefined;
1298
+ maxRetries?: number | undefined;
1299
+ stepTimeout?: number | undefined;
1300
+ }>>;
1301
+ }, "strip", z.ZodTypeAny, {
1302
+ enabled: boolean;
1303
+ models: (string | {
1304
+ provider: "custom" | "anthropic" | "deepseek" | "openai" | "zhipu" | "ollama";
1305
+ name: string;
1306
+ maxContextTokens: number;
1307
+ id: string;
1308
+ apiModel: string;
1309
+ capabilities: string[];
1310
+ endpoint?: string | undefined;
1311
+ apiKeyEnvVar?: string | undefined;
1312
+ costPer1MInput?: number | undefined;
1313
+ costPer1MOutput?: number | undefined;
1314
+ })[];
1315
+ routingStrategy: "cost-optimized" | "performance-first" | "balanced" | "adaptive";
1316
+ roles?: {
1317
+ planner: string;
1318
+ executor: string;
1319
+ fallback: string;
1320
+ reviewer?: string | undefined;
1321
+ } | undefined;
1322
+ routing?: {
1323
+ targetRole: "planner" | "executor" | "reviewer" | "fallback";
1324
+ priority: number;
1325
+ complexity?: "low" | "medium" | "high" | "critical" | undefined;
1326
+ keywords?: string[] | undefined;
1327
+ taskType?: "planning" | "coding" | "refactoring" | "bug-fix" | "review" | "documentation" | undefined;
1328
+ }[] | undefined;
1329
+ costOptimization?: {
1330
+ enabled: boolean;
1331
+ targetReduction: number;
1332
+ maxPerformanceDegradation: number;
1333
+ fallbackThreshold: number;
1334
+ } | undefined;
1335
+ plannerSettings?: {
1336
+ complexityThreshold: "low" | "medium" | "high";
1337
+ maxPlanningTokens: number;
1338
+ enableDecomposition: boolean;
1339
+ } | undefined;
1340
+ executorSettings?: {
1341
+ retryWithFallback: boolean;
1342
+ maxRetries: number;
1343
+ stepTimeout: number;
1344
+ } | undefined;
1345
+ }, {
1346
+ enabled?: boolean | undefined;
1347
+ models?: (string | {
1348
+ provider: "custom" | "anthropic" | "deepseek" | "openai" | "zhipu" | "ollama";
1349
+ name: string;
1350
+ id: string;
1351
+ apiModel: string;
1352
+ endpoint?: string | undefined;
1353
+ maxContextTokens?: number | undefined;
1354
+ apiKeyEnvVar?: string | undefined;
1355
+ costPer1MInput?: number | undefined;
1356
+ costPer1MOutput?: number | undefined;
1357
+ capabilities?: string[] | undefined;
1358
+ })[] | undefined;
1359
+ roles?: {
1360
+ planner?: string | undefined;
1361
+ executor?: string | undefined;
1362
+ reviewer?: string | undefined;
1363
+ fallback?: string | undefined;
1364
+ } | undefined;
1365
+ routing?: {
1366
+ targetRole: "planner" | "executor" | "reviewer" | "fallback";
1367
+ complexity?: "low" | "medium" | "high" | "critical" | undefined;
1368
+ keywords?: string[] | undefined;
1369
+ taskType?: "planning" | "coding" | "refactoring" | "bug-fix" | "review" | "documentation" | undefined;
1370
+ priority?: number | undefined;
1371
+ }[] | undefined;
1372
+ routingStrategy?: "cost-optimized" | "performance-first" | "balanced" | "adaptive" | undefined;
1373
+ costOptimization?: {
1374
+ enabled?: boolean | undefined;
1375
+ targetReduction?: number | undefined;
1376
+ maxPerformanceDegradation?: number | undefined;
1377
+ fallbackThreshold?: number | undefined;
1378
+ } | undefined;
1379
+ plannerSettings?: {
1380
+ complexityThreshold?: "low" | "medium" | "high" | undefined;
1381
+ maxPlanningTokens?: number | undefined;
1382
+ enableDecomposition?: boolean | undefined;
1383
+ } | undefined;
1384
+ executorSettings?: {
1385
+ retryWithFallback?: boolean | undefined;
1386
+ maxRetries?: number | undefined;
1387
+ stepTimeout?: number | undefined;
1388
+ } | undefined;
1389
+ }>;
1124
1390
  export declare const AgentContextConfigSchema: z.ZodObject<{
1125
1391
  $schema: z.ZodOptional<z.ZodString>;
1126
1392
  version: z.ZodDefault<z.ZodString>;
@@ -1838,6 +2104,209 @@ export declare const AgentContextConfigSchema: z.ZodObject<{
1838
2104
  prewarmServices?: string[] | undefined;
1839
2105
  } | undefined;
1840
2106
  }>>;
2107
+ multiModel: z.ZodOptional<z.ZodObject<{
2108
+ enabled: z.ZodDefault<z.ZodBoolean>;
2109
+ models: z.ZodDefault<z.ZodArray<z.ZodUnion<[z.ZodString, z.ZodObject<{
2110
+ id: z.ZodString;
2111
+ name: z.ZodString;
2112
+ provider: z.ZodEnum<["anthropic", "deepseek", "openai", "zhipu", "ollama", "custom"]>;
2113
+ apiModel: z.ZodString;
2114
+ endpoint: z.ZodOptional<z.ZodString>;
2115
+ apiKeyEnvVar: z.ZodOptional<z.ZodString>;
2116
+ maxContextTokens: z.ZodDefault<z.ZodNumber>;
2117
+ costPer1MInput: z.ZodOptional<z.ZodNumber>;
2118
+ costPer1MOutput: z.ZodOptional<z.ZodNumber>;
2119
+ capabilities: z.ZodDefault<z.ZodArray<z.ZodString, "many">>;
2120
+ }, "strip", z.ZodTypeAny, {
2121
+ provider: "custom" | "anthropic" | "deepseek" | "openai" | "zhipu" | "ollama";
2122
+ name: string;
2123
+ maxContextTokens: number;
2124
+ id: string;
2125
+ apiModel: string;
2126
+ capabilities: string[];
2127
+ endpoint?: string | undefined;
2128
+ apiKeyEnvVar?: string | undefined;
2129
+ costPer1MInput?: number | undefined;
2130
+ costPer1MOutput?: number | undefined;
2131
+ }, {
2132
+ provider: "custom" | "anthropic" | "deepseek" | "openai" | "zhipu" | "ollama";
2133
+ name: string;
2134
+ id: string;
2135
+ apiModel: string;
2136
+ endpoint?: string | undefined;
2137
+ maxContextTokens?: number | undefined;
2138
+ apiKeyEnvVar?: string | undefined;
2139
+ costPer1MInput?: number | undefined;
2140
+ costPer1MOutput?: number | undefined;
2141
+ capabilities?: string[] | undefined;
2142
+ }>]>, "many">>;
2143
+ roles: z.ZodOptional<z.ZodObject<{
2144
+ planner: z.ZodDefault<z.ZodString>;
2145
+ executor: z.ZodDefault<z.ZodString>;
2146
+ reviewer: z.ZodOptional<z.ZodString>;
2147
+ fallback: z.ZodDefault<z.ZodString>;
2148
+ }, "strip", z.ZodTypeAny, {
2149
+ planner: string;
2150
+ executor: string;
2151
+ fallback: string;
2152
+ reviewer?: string | undefined;
2153
+ }, {
2154
+ planner?: string | undefined;
2155
+ executor?: string | undefined;
2156
+ reviewer?: string | undefined;
2157
+ fallback?: string | undefined;
2158
+ }>>;
2159
+ routing: z.ZodOptional<z.ZodArray<z.ZodObject<{
2160
+ complexity: z.ZodOptional<z.ZodEnum<["low", "medium", "high", "critical"]>>;
2161
+ keywords: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
2162
+ taskType: z.ZodOptional<z.ZodEnum<["planning", "coding", "refactoring", "bug-fix", "review", "documentation"]>>;
2163
+ targetRole: z.ZodEnum<["planner", "executor", "reviewer", "fallback"]>;
2164
+ priority: z.ZodDefault<z.ZodNumber>;
2165
+ }, "strip", z.ZodTypeAny, {
2166
+ targetRole: "planner" | "executor" | "reviewer" | "fallback";
2167
+ priority: number;
2168
+ complexity?: "low" | "medium" | "high" | "critical" | undefined;
2169
+ keywords?: string[] | undefined;
2170
+ taskType?: "planning" | "coding" | "refactoring" | "bug-fix" | "review" | "documentation" | undefined;
2171
+ }, {
2172
+ targetRole: "planner" | "executor" | "reviewer" | "fallback";
2173
+ complexity?: "low" | "medium" | "high" | "critical" | undefined;
2174
+ keywords?: string[] | undefined;
2175
+ taskType?: "planning" | "coding" | "refactoring" | "bug-fix" | "review" | "documentation" | undefined;
2176
+ priority?: number | undefined;
2177
+ }>, "many">>;
2178
+ routingStrategy: z.ZodDefault<z.ZodEnum<["cost-optimized", "performance-first", "balanced", "adaptive"]>>;
2179
+ costOptimization: z.ZodOptional<z.ZodObject<{
2180
+ enabled: z.ZodDefault<z.ZodBoolean>;
2181
+ targetReduction: z.ZodDefault<z.ZodNumber>;
2182
+ maxPerformanceDegradation: z.ZodDefault<z.ZodNumber>;
2183
+ fallbackThreshold: z.ZodDefault<z.ZodNumber>;
2184
+ }, "strip", z.ZodTypeAny, {
2185
+ enabled: boolean;
2186
+ targetReduction: number;
2187
+ maxPerformanceDegradation: number;
2188
+ fallbackThreshold: number;
2189
+ }, {
2190
+ enabled?: boolean | undefined;
2191
+ targetReduction?: number | undefined;
2192
+ maxPerformanceDegradation?: number | undefined;
2193
+ fallbackThreshold?: number | undefined;
2194
+ }>>;
2195
+ plannerSettings: z.ZodOptional<z.ZodObject<{
2196
+ complexityThreshold: z.ZodDefault<z.ZodEnum<["low", "medium", "high"]>>;
2197
+ maxPlanningTokens: z.ZodDefault<z.ZodNumber>;
2198
+ enableDecomposition: z.ZodDefault<z.ZodBoolean>;
2199
+ }, "strip", z.ZodTypeAny, {
2200
+ complexityThreshold: "low" | "medium" | "high";
2201
+ maxPlanningTokens: number;
2202
+ enableDecomposition: boolean;
2203
+ }, {
2204
+ complexityThreshold?: "low" | "medium" | "high" | undefined;
2205
+ maxPlanningTokens?: number | undefined;
2206
+ enableDecomposition?: boolean | undefined;
2207
+ }>>;
2208
+ executorSettings: z.ZodOptional<z.ZodObject<{
2209
+ retryWithFallback: z.ZodDefault<z.ZodBoolean>;
2210
+ maxRetries: z.ZodDefault<z.ZodNumber>;
2211
+ stepTimeout: z.ZodDefault<z.ZodNumber>;
2212
+ }, "strip", z.ZodTypeAny, {
2213
+ retryWithFallback: boolean;
2214
+ maxRetries: number;
2215
+ stepTimeout: number;
2216
+ }, {
2217
+ retryWithFallback?: boolean | undefined;
2218
+ maxRetries?: number | undefined;
2219
+ stepTimeout?: number | undefined;
2220
+ }>>;
2221
+ }, "strip", z.ZodTypeAny, {
2222
+ enabled: boolean;
2223
+ models: (string | {
2224
+ provider: "custom" | "anthropic" | "deepseek" | "openai" | "zhipu" | "ollama";
2225
+ name: string;
2226
+ maxContextTokens: number;
2227
+ id: string;
2228
+ apiModel: string;
2229
+ capabilities: string[];
2230
+ endpoint?: string | undefined;
2231
+ apiKeyEnvVar?: string | undefined;
2232
+ costPer1MInput?: number | undefined;
2233
+ costPer1MOutput?: number | undefined;
2234
+ })[];
2235
+ routingStrategy: "cost-optimized" | "performance-first" | "balanced" | "adaptive";
2236
+ roles?: {
2237
+ planner: string;
2238
+ executor: string;
2239
+ fallback: string;
2240
+ reviewer?: string | undefined;
2241
+ } | undefined;
2242
+ routing?: {
2243
+ targetRole: "planner" | "executor" | "reviewer" | "fallback";
2244
+ priority: number;
2245
+ complexity?: "low" | "medium" | "high" | "critical" | undefined;
2246
+ keywords?: string[] | undefined;
2247
+ taskType?: "planning" | "coding" | "refactoring" | "bug-fix" | "review" | "documentation" | undefined;
2248
+ }[] | undefined;
2249
+ costOptimization?: {
2250
+ enabled: boolean;
2251
+ targetReduction: number;
2252
+ maxPerformanceDegradation: number;
2253
+ fallbackThreshold: number;
2254
+ } | undefined;
2255
+ plannerSettings?: {
2256
+ complexityThreshold: "low" | "medium" | "high";
2257
+ maxPlanningTokens: number;
2258
+ enableDecomposition: boolean;
2259
+ } | undefined;
2260
+ executorSettings?: {
2261
+ retryWithFallback: boolean;
2262
+ maxRetries: number;
2263
+ stepTimeout: number;
2264
+ } | undefined;
2265
+ }, {
2266
+ enabled?: boolean | undefined;
2267
+ models?: (string | {
2268
+ provider: "custom" | "anthropic" | "deepseek" | "openai" | "zhipu" | "ollama";
2269
+ name: string;
2270
+ id: string;
2271
+ apiModel: string;
2272
+ endpoint?: string | undefined;
2273
+ maxContextTokens?: number | undefined;
2274
+ apiKeyEnvVar?: string | undefined;
2275
+ costPer1MInput?: number | undefined;
2276
+ costPer1MOutput?: number | undefined;
2277
+ capabilities?: string[] | undefined;
2278
+ })[] | undefined;
2279
+ roles?: {
2280
+ planner?: string | undefined;
2281
+ executor?: string | undefined;
2282
+ reviewer?: string | undefined;
2283
+ fallback?: string | undefined;
2284
+ } | undefined;
2285
+ routing?: {
2286
+ targetRole: "planner" | "executor" | "reviewer" | "fallback";
2287
+ complexity?: "low" | "medium" | "high" | "critical" | undefined;
2288
+ keywords?: string[] | undefined;
2289
+ taskType?: "planning" | "coding" | "refactoring" | "bug-fix" | "review" | "documentation" | undefined;
2290
+ priority?: number | undefined;
2291
+ }[] | undefined;
2292
+ routingStrategy?: "cost-optimized" | "performance-first" | "balanced" | "adaptive" | undefined;
2293
+ costOptimization?: {
2294
+ enabled?: boolean | undefined;
2295
+ targetReduction?: number | undefined;
2296
+ maxPerformanceDegradation?: number | undefined;
2297
+ fallbackThreshold?: number | undefined;
2298
+ } | undefined;
2299
+ plannerSettings?: {
2300
+ complexityThreshold?: "low" | "medium" | "high" | undefined;
2301
+ maxPlanningTokens?: number | undefined;
2302
+ enableDecomposition?: boolean | undefined;
2303
+ } | undefined;
2304
+ executorSettings?: {
2305
+ retryWithFallback?: boolean | undefined;
2306
+ maxRetries?: number | undefined;
2307
+ stepTimeout?: number | undefined;
2308
+ } | undefined;
2309
+ }>>;
1841
2310
  }, "strip", z.ZodTypeAny, {
1842
2311
  version: string;
1843
2312
  project: {
@@ -1857,6 +2326,25 @@ export declare const AgentContextConfigSchema: z.ZodObject<{
1857
2326
  pipelineOnly: boolean;
1858
2327
  } | undefined;
1859
2328
  } | undefined;
2329
+ costOptimization?: {
2330
+ enabled: boolean;
2331
+ tokenBudget?: {
2332
+ maxTemplateTokens: number;
2333
+ maxMemoryQueryTokens: number;
2334
+ maxContextTokens: number;
2335
+ warningThreshold: number;
2336
+ } | undefined;
2337
+ embeddingBatching?: {
2338
+ enabled: boolean;
2339
+ batchSize: number;
2340
+ maxDelayMs: number;
2341
+ } | undefined;
2342
+ llmCallReduction?: {
2343
+ cacheResponses: boolean;
2344
+ cacheTtlMs: number;
2345
+ deduplicateQueries: boolean;
2346
+ } | undefined;
2347
+ } | undefined;
1860
2348
  $schema?: string | undefined;
1861
2349
  platforms?: {
1862
2350
  claudeCode?: {
@@ -1947,25 +2435,6 @@ export declare const AgentContextConfigSchema: z.ZodObject<{
1947
2435
  description?: string | undefined;
1948
2436
  argumentHint?: string | undefined;
1949
2437
  }[] | undefined;
1950
- costOptimization?: {
1951
- enabled: boolean;
1952
- tokenBudget?: {
1953
- maxTemplateTokens: number;
1954
- maxMemoryQueryTokens: number;
1955
- maxContextTokens: number;
1956
- warningThreshold: number;
1957
- } | undefined;
1958
- embeddingBatching?: {
1959
- enabled: boolean;
1960
- batchSize: number;
1961
- maxDelayMs: number;
1962
- } | undefined;
1963
- llmCallReduction?: {
1964
- cacheResponses: boolean;
1965
- cacheTtlMs: number;
1966
- deduplicateQueries: boolean;
1967
- } | undefined;
1968
- } | undefined;
1969
2438
  timeOptimization?: {
1970
2439
  enabled: boolean;
1971
2440
  batchWindows?: {
@@ -1985,6 +2454,51 @@ export declare const AgentContextConfigSchema: z.ZodObject<{
1985
2454
  prewarmServices: string[];
1986
2455
  } | undefined;
1987
2456
  } | undefined;
2457
+ multiModel?: {
2458
+ enabled: boolean;
2459
+ models: (string | {
2460
+ provider: "custom" | "anthropic" | "deepseek" | "openai" | "zhipu" | "ollama";
2461
+ name: string;
2462
+ maxContextTokens: number;
2463
+ id: string;
2464
+ apiModel: string;
2465
+ capabilities: string[];
2466
+ endpoint?: string | undefined;
2467
+ apiKeyEnvVar?: string | undefined;
2468
+ costPer1MInput?: number | undefined;
2469
+ costPer1MOutput?: number | undefined;
2470
+ })[];
2471
+ routingStrategy: "cost-optimized" | "performance-first" | "balanced" | "adaptive";
2472
+ roles?: {
2473
+ planner: string;
2474
+ executor: string;
2475
+ fallback: string;
2476
+ reviewer?: string | undefined;
2477
+ } | undefined;
2478
+ routing?: {
2479
+ targetRole: "planner" | "executor" | "reviewer" | "fallback";
2480
+ priority: number;
2481
+ complexity?: "low" | "medium" | "high" | "critical" | undefined;
2482
+ keywords?: string[] | undefined;
2483
+ taskType?: "planning" | "coding" | "refactoring" | "bug-fix" | "review" | "documentation" | undefined;
2484
+ }[] | undefined;
2485
+ costOptimization?: {
2486
+ enabled: boolean;
2487
+ targetReduction: number;
2488
+ maxPerformanceDegradation: number;
2489
+ fallbackThreshold: number;
2490
+ } | undefined;
2491
+ plannerSettings?: {
2492
+ complexityThreshold: "low" | "medium" | "high";
2493
+ maxPlanningTokens: number;
2494
+ enableDecomposition: boolean;
2495
+ } | undefined;
2496
+ executorSettings?: {
2497
+ retryWithFallback: boolean;
2498
+ maxRetries: number;
2499
+ stepTimeout: number;
2500
+ } | undefined;
2501
+ } | undefined;
1988
2502
  }, {
1989
2503
  project: {
1990
2504
  name: string;
@@ -2003,6 +2517,25 @@ export declare const AgentContextConfigSchema: z.ZodObject<{
2003
2517
  pipelineOnly?: boolean | undefined;
2004
2518
  } | undefined;
2005
2519
  } | undefined;
2520
+ costOptimization?: {
2521
+ enabled?: boolean | undefined;
2522
+ tokenBudget?: {
2523
+ maxTemplateTokens?: number | undefined;
2524
+ maxMemoryQueryTokens?: number | undefined;
2525
+ maxContextTokens?: number | undefined;
2526
+ warningThreshold?: number | undefined;
2527
+ } | undefined;
2528
+ embeddingBatching?: {
2529
+ enabled?: boolean | undefined;
2530
+ batchSize?: number | undefined;
2531
+ maxDelayMs?: number | undefined;
2532
+ } | undefined;
2533
+ llmCallReduction?: {
2534
+ cacheResponses?: boolean | undefined;
2535
+ cacheTtlMs?: number | undefined;
2536
+ deduplicateQueries?: boolean | undefined;
2537
+ } | undefined;
2538
+ } | undefined;
2006
2539
  $schema?: string | undefined;
2007
2540
  version?: string | undefined;
2008
2541
  platforms?: {
@@ -2094,25 +2627,6 @@ export declare const AgentContextConfigSchema: z.ZodObject<{
2094
2627
  description?: string | undefined;
2095
2628
  argumentHint?: string | undefined;
2096
2629
  }[] | undefined;
2097
- costOptimization?: {
2098
- enabled?: boolean | undefined;
2099
- tokenBudget?: {
2100
- maxTemplateTokens?: number | undefined;
2101
- maxMemoryQueryTokens?: number | undefined;
2102
- maxContextTokens?: number | undefined;
2103
- warningThreshold?: number | undefined;
2104
- } | undefined;
2105
- embeddingBatching?: {
2106
- enabled?: boolean | undefined;
2107
- batchSize?: number | undefined;
2108
- maxDelayMs?: number | undefined;
2109
- } | undefined;
2110
- llmCallReduction?: {
2111
- cacheResponses?: boolean | undefined;
2112
- cacheTtlMs?: number | undefined;
2113
- deduplicateQueries?: boolean | undefined;
2114
- } | undefined;
2115
- } | undefined;
2116
2630
  timeOptimization?: {
2117
2631
  enabled?: boolean | undefined;
2118
2632
  batchWindows?: {
@@ -2132,8 +2646,54 @@ export declare const AgentContextConfigSchema: z.ZodObject<{
2132
2646
  prewarmServices?: string[] | undefined;
2133
2647
  } | undefined;
2134
2648
  } | undefined;
2649
+ multiModel?: {
2650
+ enabled?: boolean | undefined;
2651
+ models?: (string | {
2652
+ provider: "custom" | "anthropic" | "deepseek" | "openai" | "zhipu" | "ollama";
2653
+ name: string;
2654
+ id: string;
2655
+ apiModel: string;
2656
+ endpoint?: string | undefined;
2657
+ maxContextTokens?: number | undefined;
2658
+ apiKeyEnvVar?: string | undefined;
2659
+ costPer1MInput?: number | undefined;
2660
+ costPer1MOutput?: number | undefined;
2661
+ capabilities?: string[] | undefined;
2662
+ })[] | undefined;
2663
+ roles?: {
2664
+ planner?: string | undefined;
2665
+ executor?: string | undefined;
2666
+ reviewer?: string | undefined;
2667
+ fallback?: string | undefined;
2668
+ } | undefined;
2669
+ routing?: {
2670
+ targetRole: "planner" | "executor" | "reviewer" | "fallback";
2671
+ complexity?: "low" | "medium" | "high" | "critical" | undefined;
2672
+ keywords?: string[] | undefined;
2673
+ taskType?: "planning" | "coding" | "refactoring" | "bug-fix" | "review" | "documentation" | undefined;
2674
+ priority?: number | undefined;
2675
+ }[] | undefined;
2676
+ routingStrategy?: "cost-optimized" | "performance-first" | "balanced" | "adaptive" | undefined;
2677
+ costOptimization?: {
2678
+ enabled?: boolean | undefined;
2679
+ targetReduction?: number | undefined;
2680
+ maxPerformanceDegradation?: number | undefined;
2681
+ fallbackThreshold?: number | undefined;
2682
+ } | undefined;
2683
+ plannerSettings?: {
2684
+ complexityThreshold?: "low" | "medium" | "high" | undefined;
2685
+ maxPlanningTokens?: number | undefined;
2686
+ enableDecomposition?: boolean | undefined;
2687
+ } | undefined;
2688
+ executorSettings?: {
2689
+ retryWithFallback?: boolean | undefined;
2690
+ maxRetries?: number | undefined;
2691
+ stepTimeout?: number | undefined;
2692
+ } | undefined;
2693
+ } | undefined;
2135
2694
  }>;
2136
2695
  export type AgentContextConfig = z.infer<typeof AgentContextConfigSchema>;
2696
+ export type MultiModelConfig = z.infer<typeof MultiModelSchema>;
2137
2697
  export type Platform = 'claudeCode' | 'factory' | 'vscode' | 'opencode' | 'claudeWeb' | 'factoryWeb';
2138
2698
  export type Droid = z.infer<typeof DroidSchema>;
2139
2699
  export type Command = z.infer<typeof CommandSchema>;