@mastra/code-sdk 1.16.0-alpha.8 → 1.16.1-alpha.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.
Files changed (88) hide show
  1. package/dist/acp/agent.d.ts.map +1 -1
  2. package/dist/agent-connections/messaging-processor.d.ts.map +1 -1
  3. package/dist/agent-connections/registry.d.ts.map +1 -1
  4. package/dist/agent-connections/signal-provider.d.ts +21 -21
  5. package/dist/agent-connections/signal-provider.d.ts.map +1 -1
  6. package/dist/agent-connections/state-processor.d.ts.map +1 -1
  7. package/dist/agent-connections/tools.d.ts +21 -21
  8. package/dist/agent-connections/tools.d.ts.map +1 -1
  9. package/dist/agents/credential-resolver.d.ts.map +1 -1
  10. package/dist/agents/mastracode-gateway.d.ts.map +1 -1
  11. package/dist/agents/memory.d.ts.map +1 -1
  12. package/dist/agents/memory.js +4 -3
  13. package/dist/agents/memory.js.map +1 -1
  14. package/dist/agents/prompts/model.d.ts.map +1 -1
  15. package/dist/agents/sandbox-filesystem.d.ts.map +1 -1
  16. package/dist/agents/tools.d.ts.map +1 -1
  17. package/dist/auth/account-rotation-processor.d.ts +4 -4
  18. package/dist/auth/account-rotation-processor.d.ts.map +1 -1
  19. package/dist/auth/provider-auth-error.d.ts.map +1 -1
  20. package/dist/auth/providers/github-copilot.d.ts +3 -3
  21. package/dist/auth/providers/github-copilot.d.ts.map +1 -1
  22. package/dist/auth/storage.d.ts.map +1 -1
  23. package/dist/constants.d.ts +17 -0
  24. package/dist/constants.d.ts.map +1 -1
  25. package/dist/constants.js +18 -1
  26. package/dist/constants.js.map +1 -1
  27. package/dist/factory/remote-controller.d.ts.map +1 -1
  28. package/dist/factory/remote-session.d.ts +2 -2
  29. package/dist/factory/remote-session.d.ts.map +1 -1
  30. package/dist/goal-manager.d.ts.map +1 -1
  31. package/dist/goal-signal.d.ts +1 -1
  32. package/dist/goal-signal.d.ts.map +1 -1
  33. package/dist/headless/flags.d.ts +2 -2
  34. package/dist/headless/flags.d.ts.map +1 -1
  35. package/dist/headless/types.d.ts +3 -3
  36. package/dist/headless/types.d.ts.map +1 -1
  37. package/dist/hooks/manager.d.ts.map +1 -1
  38. package/dist/index.d.ts +3 -3
  39. package/dist/index.d.ts.map +1 -1
  40. package/dist/index.js +1 -2
  41. package/dist/index.js.map +1 -1
  42. package/dist/ipc/ipc-reporter.d.ts.map +1 -1
  43. package/dist/knowledge-inspector.d.ts.map +1 -1
  44. package/dist/lsp/client.d.ts.map +1 -1
  45. package/dist/lsp/manager.d.ts.map +1 -1
  46. package/dist/mcp/manager.d.ts.map +1 -1
  47. package/dist/mcp/manager.js +10 -11
  48. package/dist/mcp/manager.js.map +1 -1
  49. package/dist/onboarding/settings.d.ts.map +1 -1
  50. package/dist/permissions.d.ts.map +1 -1
  51. package/dist/plugins/manager.d.ts.map +1 -1
  52. package/dist/plugins/signal-lane.d.ts.map +1 -1
  53. package/dist/process-memory-diagnostics.d.ts.map +1 -1
  54. package/dist/processors/plan-rejection-abort.d.ts +1 -1
  55. package/dist/processors/plan-rejection-abort.d.ts.map +1 -1
  56. package/dist/providers/amazon-bedrock-gateway.d.ts.map +1 -1
  57. package/dist/providers/anthropic-prompt-cache.d.ts +1 -1
  58. package/dist/providers/claude-max.d.ts.map +1 -1
  59. package/dist/providers/github-copilot-gateway.d.ts.map +1 -1
  60. package/dist/providers/provider-thinking.d.ts.map +1 -1
  61. package/dist/schedules/scheduler.d.ts.map +1 -1
  62. package/dist/schedules/tools.d.ts +6 -6
  63. package/dist/schedules/tools.d.ts.map +1 -1
  64. package/dist/schema.d.ts +87 -87
  65. package/dist/theme-palette.d.ts +7 -7
  66. package/dist/theme-palette.d.ts.map +1 -1
  67. package/dist/thinking.d.ts.map +1 -1
  68. package/dist/tool-names.d.ts +18 -18
  69. package/dist/tool-names.d.ts.map +1 -1
  70. package/dist/tools/request-sandbox-access.d.ts.map +1 -1
  71. package/dist/tools/request-sandbox-access.js +2 -1
  72. package/dist/tools/request-sandbox-access.js.map +1 -1
  73. package/dist/tools/web-search.d.ts.map +1 -1
  74. package/dist/tools/workflows/get-workflow.d.ts +1 -1
  75. package/dist/tools/workflows/list-available-agents.d.ts +1 -1
  76. package/dist/tools/workflows/list-available-classifiers.d.ts +7 -7
  77. package/dist/tools/workflows/list-workflows.d.ts +1 -1
  78. package/dist/tools/workflows/save-workflow.d.ts +328 -328
  79. package/dist/tools/workflows/tool-ids.d.ts +11 -11
  80. package/dist/tools/workflows/tool-ids.d.ts.map +1 -1
  81. package/dist/utils/discarding-scores-storage.d.ts.map +1 -1
  82. package/dist/utils/local-observability.js +1 -1
  83. package/dist/utils/local-observability.js.map +1 -1
  84. package/dist/utils/maintenance-lock.d.ts.map +1 -1
  85. package/dist/utils/signals-pubsub.d.ts.map +1 -1
  86. package/dist/utils/storage-factory.d.ts.map +1 -1
  87. package/dist/utils/thread-lock.d.ts.map +1 -1
  88. package/package.json +19 -19
package/dist/schema.d.ts CHANGED
@@ -193,16 +193,16 @@ export declare const stateSchema: z.ZodPipe<z.ZodObject<{
193
193
  cavemanObservations: z.ZodDefault<z.ZodBoolean>;
194
194
  observeAttachments: z.ZodDefault<z.ZodUnion<readonly [z.ZodLiteral<"auto">, z.ZodBoolean]>>;
195
195
  omScope: z.ZodOptional<z.ZodEnum<{
196
- thread: "thread";
197
196
  resource: "resource";
197
+ thread: "thread";
198
198
  }>>;
199
199
  thinkingLevel: z.ZodPreprocess<z.ZodOptional<z.ZodEnum<{
200
- off: "off";
200
+ high: "high";
201
201
  low: "low";
202
+ max: "max";
202
203
  medium: "medium";
203
- high: "high";
204
+ off: "off";
204
205
  xhigh: "xhigh";
205
- max: "max";
206
206
  }>>, unknown>;
207
207
  yolo: z.ZodDefault<z.ZodBoolean>;
208
208
  permissionRules: z.ZodDefault<z.ZodObject<{
@@ -219,18 +219,18 @@ export declare const stateSchema: z.ZodPipe<z.ZodObject<{
219
219
  }, z.core.$strip>>;
220
220
  smartEditing: z.ZodDefault<z.ZodBoolean>;
221
221
  notifications: z.ZodDefault<z.ZodEnum<{
222
- off: "off";
223
222
  bell: "bell";
224
- system: "system";
225
223
  both: "both";
224
+ off: "off";
225
+ system: "system";
226
226
  }>>;
227
227
  tasks: z.ZodDefault<z.ZodArray<z.ZodObject<{
228
228
  id: z.ZodOptional<z.ZodString>;
229
229
  content: z.ZodString;
230
230
  status: z.ZodEnum<{
231
- pending: "pending";
232
- in_progress: "in_progress";
233
231
  completed: "completed";
232
+ in_progress: "in_progress";
233
+ pending: "pending";
234
234
  }>;
235
235
  activeForm: z.ZodString;
236
236
  }, z.core.$strip>>>;
@@ -241,8 +241,8 @@ export declare const stateSchema: z.ZodPipe<z.ZodObject<{
241
241
  toModelId: z.ZodString;
242
242
  threadId: z.ZodOptional<z.ZodString>;
243
243
  reason: z.ZodEnum<{
244
- "pool-exhausted": "pool-exhausted";
245
244
  "persistent-outage": "persistent-outage";
245
+ "pool-exhausted": "pool-exhausted";
246
246
  }>;
247
247
  at: z.ZodString;
248
248
  }, z.core.$strip>>>;
@@ -257,8 +257,8 @@ export declare const stateSchema: z.ZodPipe<z.ZodObject<{
257
257
  activeBrowserSettings: z.ZodOptional<z.ZodObject<{
258
258
  enabled: z.ZodBoolean;
259
259
  provider: z.ZodEnum<{
260
- stagehand: "stagehand";
261
260
  "agent-browser": "agent-browser";
261
+ stagehand: "stagehand";
262
262
  }>;
263
263
  headless: z.ZodOptional<z.ZodBoolean>;
264
264
  viewport: z.ZodOptional<z.ZodUnion<readonly [z.ZodObject<{
@@ -269,13 +269,13 @@ export declare const stateSchema: z.ZodPipe<z.ZodObject<{
269
269
  profile: z.ZodOptional<z.ZodString>;
270
270
  executablePath: z.ZodOptional<z.ZodString>;
271
271
  scope: z.ZodOptional<z.ZodEnum<{
272
- thread: "thread";
273
272
  shared: "shared";
273
+ thread: "thread";
274
274
  }>>;
275
275
  stagehand: z.ZodOptional<z.ZodObject<{
276
276
  env: z.ZodEnum<{
277
- LOCAL: "LOCAL";
278
277
  BROWSERBASE: "BROWSERBASE";
278
+ LOCAL: "LOCAL";
279
279
  }>;
280
280
  projectId: z.ZodOptional<z.ZodString>;
281
281
  model: z.ZodOptional<z.ZodString>;
@@ -288,43 +288,14 @@ export declare const stateSchema: z.ZodPipe<z.ZodObject<{
288
288
  activeBrowserModel: z.ZodOptional<z.ZodObject<{
289
289
  modelName: z.ZodOptional<z.ZodString>;
290
290
  source: z.ZodEnum<{
291
- settings: "settings";
292
291
  "chat-model": "chat-model";
293
292
  "codex-oauth": "codex-oauth";
293
+ settings: "settings";
294
294
  "stagehand-default": "stagehand-default";
295
295
  }>;
296
296
  viaCodexOAuth: z.ZodBoolean;
297
297
  }, z.core.$strip>>;
298
298
  }, z.core.$strip>, z.ZodTransform<{
299
- observerModelSelection: string;
300
- reflectorModelSelection: string;
301
- configDir: string;
302
- observationThreshold: number;
303
- reflectionThreshold: number;
304
- cavemanObservations: boolean;
305
- observeAttachments: boolean | "auto";
306
- yolo: boolean;
307
- permissionRules: {
308
- categories: Record<string, "allow" | "ask" | "deny">;
309
- tools: Record<string, "allow" | "ask" | "deny">;
310
- };
311
- smartEditing: boolean;
312
- notifications: "off" | "bell" | "system" | "both";
313
- tasks: {
314
- content: string;
315
- status: "pending" | "in_progress" | "completed";
316
- activeForm: string;
317
- id?: string | undefined;
318
- }[];
319
- sandboxAllowedPaths: string[];
320
- pluginSkillPaths: string[];
321
- pluginCommandPaths: string[];
322
- pluginInstructions: string[];
323
- activePlan: {
324
- title: string;
325
- plan: string;
326
- approvedAt: string;
327
- } | null;
328
299
  currentModelId?: string | undefined;
329
300
  modeId?: string | undefined;
330
301
  modelRoute?: {
@@ -353,24 +324,51 @@ export declare const stateSchema: z.ZodPipe<z.ZodObject<{
353
324
  baseRef?: string | undefined;
354
325
  skipGlobalInstructions?: boolean | undefined;
355
326
  instructionRoots?: string[] | undefined;
327
+ configDir: string;
356
328
  homeDir?: string | undefined;
357
329
  gitBranch?: string | undefined;
358
330
  lastCommand?: string | undefined;
359
331
  observerModelId?: string | undefined;
360
332
  reflectorModelId?: string | undefined;
361
- omScope?: "thread" | "resource" | undefined;
362
- thinkingLevel?: "off" | "low" | "medium" | "high" | "xhigh" | "max" | undefined;
333
+ observationThreshold: number;
334
+ reflectionThreshold: number;
335
+ cavemanObservations: boolean;
336
+ observeAttachments: "auto" | boolean;
337
+ omScope?: "resource" | "thread" | undefined;
338
+ thinkingLevel?: "high" | "low" | "max" | "medium" | "off" | "xhigh" | undefined;
339
+ yolo: boolean;
340
+ permissionRules: {
341
+ categories: Record<string, "allow" | "ask" | "deny">;
342
+ tools: Record<string, "allow" | "ask" | "deny">;
343
+ };
344
+ smartEditing: boolean;
345
+ notifications: "bell" | "both" | "off" | "system";
346
+ tasks: {
347
+ id?: string | undefined;
348
+ content: string;
349
+ status: "completed" | "in_progress" | "pending";
350
+ activeForm: string;
351
+ }[];
352
+ sandboxAllowedPaths: string[];
363
353
  mastracodePendingModelFallback?: {
364
354
  fromEntryId: string;
365
355
  toEntryId: string;
366
356
  toModelId: string;
367
- reason: "pool-exhausted" | "persistent-outage";
368
- at: string;
369
357
  threadId?: string | undefined;
358
+ reason: "persistent-outage" | "pool-exhausted";
359
+ at: string;
370
360
  } | null | undefined;
361
+ pluginSkillPaths: string[];
362
+ pluginCommandPaths: string[];
363
+ pluginInstructions: string[];
364
+ activePlan: {
365
+ title: string;
366
+ plan: string;
367
+ approvedAt: string;
368
+ } | null;
371
369
  activeBrowserSettings?: {
372
370
  enabled: boolean;
373
- provider: "stagehand" | "agent-browser";
371
+ provider: "agent-browser" | "stagehand";
374
372
  headless?: boolean | undefined;
375
373
  viewport?: "window" | {
376
374
  width: number;
@@ -379,9 +377,9 @@ export declare const stateSchema: z.ZodPipe<z.ZodObject<{
379
377
  cdpUrl?: string | undefined;
380
378
  profile?: string | undefined;
381
379
  executablePath?: string | undefined;
382
- scope?: "thread" | "shared" | undefined;
380
+ scope?: "shared" | "thread" | undefined;
383
381
  stagehand?: {
384
- env: "LOCAL" | "BROWSERBASE";
382
+ env: "BROWSERBASE" | "LOCAL";
385
383
  projectId?: string | undefined;
386
384
  model?: string | undefined;
387
385
  preserveUserDataDir?: boolean | undefined;
@@ -391,38 +389,13 @@ export declare const stateSchema: z.ZodPipe<z.ZodObject<{
391
389
  } | undefined;
392
390
  } | undefined;
393
391
  activeBrowserModel?: {
394
- source: "settings" | "chat-model" | "codex-oauth" | "stagehand-default";
395
- viaCodexOAuth: boolean;
396
392
  modelName?: string | undefined;
393
+ source: "chat-model" | "codex-oauth" | "settings" | "stagehand-default";
394
+ viaCodexOAuth: boolean;
397
395
  } | undefined;
396
+ observerModelSelection: string;
397
+ reflectorModelSelection: string;
398
398
  }, {
399
- configDir: string;
400
- observationThreshold: number;
401
- reflectionThreshold: number;
402
- cavemanObservations: boolean;
403
- observeAttachments: boolean | "auto";
404
- yolo: boolean;
405
- permissionRules: {
406
- categories: Record<string, "allow" | "ask" | "deny">;
407
- tools: Record<string, "allow" | "ask" | "deny">;
408
- };
409
- smartEditing: boolean;
410
- notifications: "off" | "bell" | "system" | "both";
411
- tasks: {
412
- content: string;
413
- status: "pending" | "in_progress" | "completed";
414
- activeForm: string;
415
- id?: string | undefined;
416
- }[];
417
- sandboxAllowedPaths: string[];
418
- pluginSkillPaths: string[];
419
- pluginCommandPaths: string[];
420
- pluginInstructions: string[];
421
- activePlan: {
422
- title: string;
423
- plan: string;
424
- approvedAt: string;
425
- } | null;
426
399
  currentModelId?: string | undefined;
427
400
  modeId?: string | undefined;
428
401
  modelRoute?: {
@@ -451,6 +424,7 @@ export declare const stateSchema: z.ZodPipe<z.ZodObject<{
451
424
  baseRef?: string | undefined;
452
425
  skipGlobalInstructions?: boolean | undefined;
453
426
  instructionRoots?: string[] | undefined;
427
+ configDir: string;
454
428
  homeDir?: string | undefined;
455
429
  gitBranch?: string | undefined;
456
430
  lastCommand?: string | undefined;
@@ -458,19 +432,45 @@ export declare const stateSchema: z.ZodPipe<z.ZodObject<{
458
432
  reflectorModelId?: string | undefined;
459
433
  observerModelSelection?: string | undefined;
460
434
  reflectorModelSelection?: string | undefined;
461
- omScope?: "thread" | "resource" | undefined;
462
- thinkingLevel?: "off" | "low" | "medium" | "high" | "xhigh" | "max" | undefined;
435
+ observationThreshold: number;
436
+ reflectionThreshold: number;
437
+ cavemanObservations: boolean;
438
+ observeAttachments: "auto" | boolean;
439
+ omScope?: "resource" | "thread" | undefined;
440
+ thinkingLevel?: "high" | "low" | "max" | "medium" | "off" | "xhigh" | undefined;
441
+ yolo: boolean;
442
+ permissionRules: {
443
+ categories: Record<string, "allow" | "ask" | "deny">;
444
+ tools: Record<string, "allow" | "ask" | "deny">;
445
+ };
446
+ smartEditing: boolean;
447
+ notifications: "bell" | "both" | "off" | "system";
448
+ tasks: {
449
+ id?: string | undefined;
450
+ content: string;
451
+ status: "completed" | "in_progress" | "pending";
452
+ activeForm: string;
453
+ }[];
454
+ sandboxAllowedPaths: string[];
463
455
  mastracodePendingModelFallback?: {
464
456
  fromEntryId: string;
465
457
  toEntryId: string;
466
458
  toModelId: string;
467
- reason: "pool-exhausted" | "persistent-outage";
468
- at: string;
469
459
  threadId?: string | undefined;
460
+ reason: "persistent-outage" | "pool-exhausted";
461
+ at: string;
470
462
  } | null | undefined;
463
+ pluginSkillPaths: string[];
464
+ pluginCommandPaths: string[];
465
+ pluginInstructions: string[];
466
+ activePlan: {
467
+ title: string;
468
+ plan: string;
469
+ approvedAt: string;
470
+ } | null;
471
471
  activeBrowserSettings?: {
472
472
  enabled: boolean;
473
- provider: "stagehand" | "agent-browser";
473
+ provider: "agent-browser" | "stagehand";
474
474
  headless?: boolean | undefined;
475
475
  viewport?: "window" | {
476
476
  width: number;
@@ -479,9 +479,9 @@ export declare const stateSchema: z.ZodPipe<z.ZodObject<{
479
479
  cdpUrl?: string | undefined;
480
480
  profile?: string | undefined;
481
481
  executablePath?: string | undefined;
482
- scope?: "thread" | "shared" | undefined;
482
+ scope?: "shared" | "thread" | undefined;
483
483
  stagehand?: {
484
- env: "LOCAL" | "BROWSERBASE";
484
+ env: "BROWSERBASE" | "LOCAL";
485
485
  projectId?: string | undefined;
486
486
  model?: string | undefined;
487
487
  preserveUserDataDir?: boolean | undefined;
@@ -491,9 +491,9 @@ export declare const stateSchema: z.ZodPipe<z.ZodObject<{
491
491
  } | undefined;
492
492
  } | undefined;
493
493
  activeBrowserModel?: {
494
- source: "settings" | "chat-model" | "codex-oauth" | "stagehand-default";
495
- viaCodexOAuth: boolean;
496
494
  modelName?: string | undefined;
495
+ source: "chat-model" | "codex-oauth" | "settings" | "stagehand-default";
496
+ viaCodexOAuth: boolean;
497
497
  } | undefined;
498
498
  }>>;
499
499
  //# sourceMappingURL=schema.d.ts.map
@@ -6,12 +6,12 @@
6
6
  * The TUI's `theme.ts` re-exports this and layers contrast adaptation on top.
7
7
  */
8
8
  export declare const mastraBrand: {
9
- readonly purple: "#7f45e0";
10
- readonly green: "#16c858";
11
- readonly orange: "#fdac53";
12
- readonly pink: "#ff69cc";
13
- readonly blue: "#2563eb";
14
- readonly red: "#DC5663";
15
- readonly yellow: "#e7e67b";
9
+ readonly purple: '#7f45e0';
10
+ readonly green: '#16c858';
11
+ readonly orange: '#fdac53';
12
+ readonly pink: '#ff69cc';
13
+ readonly blue: '#2563eb';
14
+ readonly red: '#DC5663';
15
+ readonly yellow: '#e7e67b';
16
16
  };
17
17
  //# sourceMappingURL=theme-palette.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"theme-palette.d.ts","sourceRoot":"","sources":["../src/theme-palette.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AACH,eAAO,MAAM,WAAW;;;;;;;;CAQd,CAAC"}
1
+ {"version":3,"file":"theme-palette.d.ts","sourceRoot":"","sources":["../src/theme-palette.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AACH,eAAO,MAAM,WAAW;aACtB,MAAM,EAAE,SAAS;aACjB,KAAK,EAAE,SAAS;aAChB,MAAM,EAAE,SAAS;aACjB,IAAI,EAAE,SAAS;aACf,IA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24 @@
9
9
  * to these names (e.g. `view`) via the `name` property in workspace tool config.
10
10
  */
11
11
  export declare const MC_TOOLS: {
12
- readonly VIEW: "view";
13
- readonly WRITE_FILE: "write_file";
14
- readonly STRING_REPLACE_LSP: "string_replace_lsp";
15
- readonly FIND_FILES: "find_files";
16
- readonly DELETE_FILE: "delete_file";
17
- readonly FILE_STAT: "file_stat";
18
- readonly MKDIR: "mkdir";
19
- readonly SEARCH_CONTENT: "search_content";
20
- readonly AST_SMART_EDIT: "ast_smart_edit";
21
- readonly EXECUTE_COMMAND: "execute_command";
22
- readonly GET_PROCESS_OUTPUT: "get_process_output";
23
- readonly KILL_PROCESS: "kill_process";
24
- readonly LSP_INSPECT: "lsp_inspect";
25
- readonly NOTIFICATION_INBOX: "notification_inbox";
26
- readonly AGENT_CONNECTIONS_LIST: "agent_connections_list";
27
- readonly AGENT_CONNECT: "agent_connect";
28
- readonly AGENT_DISCONNECT: "agent_disconnect";
29
- readonly AGENT_SIGNAL_SEND: "agent_signal_send";
12
+ readonly VIEW: 'view';
13
+ readonly WRITE_FILE: 'write_file';
14
+ readonly STRING_REPLACE_LSP: 'string_replace_lsp';
15
+ readonly FIND_FILES: 'find_files';
16
+ readonly DELETE_FILE: 'delete_file';
17
+ readonly FILE_STAT: 'file_stat';
18
+ readonly MKDIR: 'mkdir';
19
+ readonly SEARCH_CONTENT: 'search_content';
20
+ readonly AST_SMART_EDIT: 'ast_smart_edit';
21
+ readonly EXECUTE_COMMAND: 'execute_command';
22
+ readonly GET_PROCESS_OUTPUT: 'get_process_output';
23
+ readonly KILL_PROCESS: 'kill_process';
24
+ readonly LSP_INSPECT: 'lsp_inspect';
25
+ readonly NOTIFICATION_INBOX: 'notification_inbox';
26
+ readonly AGENT_CONNECTIONS_LIST: 'agent_connections_list';
27
+ readonly AGENT_CONNECT: 'agent_connect';
28
+ readonly AGENT_DISCONNECT: 'agent_disconnect';
29
+ readonly AGENT_SIGNAL_SEND: 'agent_signal_send';
30
30
  };
31
31
  /**
32
32
  * Workspace tool name remapping config.
@@ -1 +1 @@
1
- {"version":3,"file":"tool-names.d.ts","sourceRoot":"","sources":["../src/tool-names.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAIH,eAAO,MAAM,QAAQ;;;;;;;;;;;;;;;;;;;CAgCX,CAAC;AAEX;;;;GAIG;AACH,eAAO,MAAM,mBAAmB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CActB,CAAC"}
1
+ {"version":3,"file":"tool-names.d.ts","sourceRoot":"","sources":["../src/tool-names.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAIH,eAAO,MAAM,QAAQ;aAEnB,IAAI,EAAE,MAAM;aACZ,UAAU,EAAE,YAAY;aACxB,kBAAkB,EAAE,oBAAoB;aACxC,UAAU,EAAE,YAAY;aACxB,WAAW,EAAE,aAAa;aAC1B,SAAS,EAAE,WAAW;aACtB,KAAK,EAAE,OAAO;aAGd,cAAc,EAAE,gBAAgB;aAGhC,cAAc,EAAE,gBAAgB;aAGhC,eAAe,EAAE,iBAAiB;aAClC,kBAAkB,EAAE,oBAAoB;aACxC,YAAY,EAAE,cAAc;aAG5B,WAAW,EAAE,aAAa;aAG1B,kBAAkB,EAAE,oBAAoB;aAGxC,sBAAsB,EAAE,wBAAwB;aAChD,aAAa,EAAE,eAAe;aAC9B,gBAAgB,EAAE,kBAAkB;aACpC,iBAAiB,EAAE,mBAAmB;CAC9B,CAAC;AAEX;;;;GAIG;AACH,eAAO,MAAM,mBAAmB;;iBACY,IAAI;;;iBACH,IAAI;;;iBACL,IAAI;;;iBACH,IAAI;;;iBACR,IAAI;;;iBACD,IAAI;;;iBACR,IAAI;;;iBACL,IAAI;;;iBACA,IAAI;;;iBACA,IAAI;;;iBACD,IAAI;;;iBACV,IAAI;;;iBACT,IAAI;;CACjC,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"request-sandbox-access.d.ts","sourceRoot":"","sources":["../../src/tools/request-sandbox-access.ts"],"names":[],"mappings":"AAAA;;;GAGG;AA2BH,eAAO,MAAM,wBAAwB,sKA6F5B,CAAC"}
1
+ {"version":3,"file":"request-sandbox-access.d.ts","sourceRoot":"","sources":["../../src/tools/request-sandbox-access.ts"],"names":[],"mappings":"AAAA;;;GAGG;AA2BH,eAAO,MAAM,wBAAwB,sKA4F5B,CAAC"}
@@ -64,7 +64,8 @@ const requestSandboxAccessTool = createTool({
64
64
  content: `Access granted: "${absolutePath}" has been added to allowed paths. You can now access files in this directory.`,
65
65
  isError: false
66
66
  };
67
- } else return {
67
+ }
68
+ return {
68
69
  content: `Access denied: The user declined access to "${absolutePath}".`,
69
70
  isError: false
70
71
  };
@@ -1 +1 @@
1
- {"version":3,"file":"request-sandbox-access.js","names":["os","path"],"sources":["../../src/tools/request-sandbox-access.ts"],"sourcesContent":["/**\n * request_access tool — requests permission to access a directory outside the project root.\n * The user can approve or deny the request via TUI dialog.\n */\n\nimport * as os from 'node:os';\nimport * as path from 'node:path';\nimport type { AgentControllerRequestContext } from '@mastra/core/agent-controller';\nimport { createTool } from '@mastra/core/tools';\nimport { LocalFilesystem } from '@mastra/core/workspace';\nimport { z } from 'zod';\nimport type { MastraCodeState } from '../schema.js';\nimport { isPathAllowed, getAllowedPathsFromContext } from './utils.js';\n\nfunction expandTilde(p: string): string {\n if (p === '~') return os.homedir();\n if (p.startsWith('~/') || p.startsWith('~\\\\')) return path.join(os.homedir(), p.slice(2));\n return p;\n}\n\ntype RequestSandboxAccessInput = {\n path: string;\n reason: string;\n};\n\nconst requestSandboxAccessInputSchema = z.object({\n path: z.string().min(1).describe('The absolute path to the directory you need access to.'),\n reason: z.string().min(1).describe('Brief explanation of why you need access to this directory.'),\n});\n\nexport const requestSandboxAccessTool = createTool({\n id: 'request_access',\n description: `Request permission to access a directory outside the current project. Use this when you need to read or write files in a directory that is not within the project root. The user will be prompted to approve or deny the request.`,\n inputSchema: requestSandboxAccessInputSchema,\n suspendSchema: z.object({\n kind: z.literal('sandbox_access_request'),\n path: z.string(),\n reason: z.string(),\n }),\n resumeSchema: z.union([z.string(), z.array(z.string())]),\n execute: async ({ path: requestedPath, reason }: RequestSandboxAccessInput, context: any) => {\n try {\n const agentControllerCtx = context?.requestContext?.get('controller') as\n | AgentControllerRequestContext<MastraCodeState>\n | undefined;\n\n // Resolve to absolute path (expand ~ first since Node path APIs don't handle it)\n const projectRoot = agentControllerCtx?.getState()?.projectPath ?? process.cwd();\n const expanded = expandTilde(requestedPath);\n const absolutePath = path.isAbsolute(expanded) ? expanded : path.resolve(projectRoot, expanded);\n\n // Check if already allowed\n const allowedPaths = getAllowedPathsFromContext(context);\n if (isPathAllowed(absolutePath, projectRoot, allowedPaths)) {\n return {\n content: `Access already granted: \"${absolutePath}\" is within the project root or allowed paths.`,\n isError: false,\n };\n }\n\n const suspend = context?.agent?.suspend ?? context?.suspend;\n const resumeData = context?.agent?.resumeData ?? context?.resumeData;\n\n // First pass: pause via the native tool-suspension primitive so the host can\n // prompt the user. The suspend payload carries the request details; the host\n // resumes with the user's answer as resume data.\n if (resumeData === undefined) {\n if (!suspend) {\n return {\n content: `Cannot request sandbox access: interactive context not available. The user should manually run /sandbox add ${absolutePath}`,\n isError: true,\n };\n }\n await suspend({ kind: 'sandbox_access_request', path: absolutePath, reason });\n return;\n }\n\n const answerText = Array.isArray(resumeData) ? resumeData.join(', ') : String(resumeData);\n const approved = answerText.toLowerCase().startsWith('y') || answerText.toLowerCase() === 'approve';\n if (approved) {\n // Persist to controller state first (and await it) so the value is\n // committed before the next tool call re-derives the workspace's\n // allowed paths from state. The workspace factory rebuilds the\n // filesystem allowlist from `sandboxAllowedPaths` on every call\n // (getDynamicWorkspace), so an unawaited setState would let that\n // rebuild clobber the in-turn widen below before the grant lands.\n const controllerState = agentControllerCtx?.getState();\n const currentAllowed = (controllerState?.sandboxAllowedPaths as string[] | undefined) ?? [];\n const nextAllowed = currentAllowed.includes(absolutePath) ? currentAllowed : [...currentAllowed, absolutePath];\n if (!currentAllowed.includes(absolutePath)) {\n await agentControllerCtx?.setState({\n sandboxAllowedPaths: nextAllowed,\n });\n }\n\n // Also update the live workspace filesystem immediately so tools in\n // the same turn (e.g. `view`) can access the path without waiting for\n // a fresh workspace build. The resolved workspace is carried on the\n // controller request context — the tool-execution context does not expose\n // it — so read the filesystem from there.\n const fs = agentControllerCtx?.workspace?.filesystem ?? context?.workspace?.filesystem;\n if (fs instanceof LocalFilesystem) {\n fs.setAllowedPaths((prev: readonly string[]) => [...prev, absolutePath]);\n }\n\n return {\n content: `Access granted: \"${absolutePath}\" has been added to allowed paths. You can now access files in this directory.`,\n isError: false,\n };\n } else {\n return {\n content: `Access denied: The user declined access to \"${absolutePath}\".`,\n isError: false,\n };\n }\n } catch (error) {\n const msg = error instanceof Error ? error.message : 'Unknown error';\n return {\n content: `Failed to request sandbox access: ${msg}`,\n isError: true,\n };\n }\n },\n} as any);\n"],"mappings":";;;;;;;;;;;AAcA,SAAS,YAAY,GAAmB;CACtC,IAAI,MAAM,KAAK,OAAOA,KAAG,QAAQ;CACjC,IAAI,EAAE,WAAW,IAAI,KAAK,EAAE,WAAW,KAAK,GAAG,OAAOC,OAAK,KAAKD,KAAG,QAAQ,GAAG,EAAE,MAAM,CAAC,CAAC;CACxF,OAAO;AACT;AAOA,MAAM,kCAAkC,EAAE,OAAO;CAC/C,MAAM,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,SAAS,wDAAwD;CACzF,QAAQ,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,SAAS,6DAA6D;AAClG,CAAC;AAED,MAAa,2BAA2B,WAAW;CACjD,IAAI;CACJ,aAAa;CACb,aAAa;CACb,eAAe,EAAE,OAAO;EACtB,MAAM,EAAE,QAAQ,wBAAwB;EACxC,MAAM,EAAE,OAAO;EACf,QAAQ,EAAE,OAAO;CACnB,CAAC;CACD,cAAc,EAAE,MAAM,CAAC,EAAE,OAAO,GAAG,EAAE,MAAM,EAAE,OAAO,CAAC,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;KAC1C,SAAS;IACX;GACF,OACE,OAAO;IACL,SAAS,+CAA+C,aAAa;IACrE,SAAS;GACX;EAEJ,SAAS,OAAO;GAEd,OAAO;IACL,SAAS,qCAFC,iBAAiB,QAAQ,MAAM,UAAU;IAGnD,SAAS;GACX;EACF;CACF;AACF,CAAQ"}
1
+ {"version":3,"file":"request-sandbox-access.js","names":["os","path"],"sources":["../../src/tools/request-sandbox-access.ts"],"sourcesContent":["/**\n * request_access tool — requests permission to access a directory outside the project root.\n * The user can approve or deny the request via TUI dialog.\n */\n\nimport * as os from 'node:os';\nimport * as path from 'node:path';\nimport type { AgentControllerRequestContext } from '@mastra/core/agent-controller';\nimport { createTool } from '@mastra/core/tools';\nimport { LocalFilesystem } from '@mastra/core/workspace';\nimport { z } from 'zod';\nimport type { MastraCodeState } from '../schema.js';\nimport { isPathAllowed, getAllowedPathsFromContext } from './utils.js';\n\nfunction expandTilde(p: string): string {\n if (p === '~') return os.homedir();\n if (p.startsWith('~/') || p.startsWith('~\\\\')) return path.join(os.homedir(), p.slice(2));\n return p;\n}\n\ntype RequestSandboxAccessInput = {\n path: string;\n reason: string;\n};\n\nconst requestSandboxAccessInputSchema = z.object({\n path: z.string().min(1).describe('The absolute path to the directory you need access to.'),\n reason: z.string().min(1).describe('Brief explanation of why you need access to this directory.'),\n});\n\nexport const requestSandboxAccessTool = createTool({\n id: 'request_access',\n description: `Request permission to access a directory outside the current project. Use this when you need to read or write files in a directory that is not within the project root. The user will be prompted to approve or deny the request.`,\n inputSchema: requestSandboxAccessInputSchema,\n suspendSchema: z.object({\n kind: z.literal('sandbox_access_request'),\n path: z.string(),\n reason: z.string(),\n }),\n resumeSchema: z.union([z.string(), z.array(z.string())]),\n execute: async ({ path: requestedPath, reason }: RequestSandboxAccessInput, context: any) => {\n try {\n const agentControllerCtx = context?.requestContext?.get('controller') as\n | AgentControllerRequestContext<MastraCodeState>\n | undefined;\n\n // Resolve to absolute path (expand ~ first since Node path APIs don't handle it)\n const projectRoot = agentControllerCtx?.getState()?.projectPath ?? process.cwd();\n const expanded = expandTilde(requestedPath);\n const absolutePath = path.isAbsolute(expanded) ? expanded : path.resolve(projectRoot, expanded);\n\n // Check if already allowed\n const allowedPaths = getAllowedPathsFromContext(context);\n if (isPathAllowed(absolutePath, projectRoot, allowedPaths)) {\n return {\n content: `Access already granted: \"${absolutePath}\" is within the project root or allowed paths.`,\n isError: false,\n };\n }\n\n const suspend = context?.agent?.suspend ?? context?.suspend;\n const resumeData = context?.agent?.resumeData ?? context?.resumeData;\n\n // First pass: pause via the native tool-suspension primitive so the host can\n // prompt the user. The suspend payload carries the request details; the host\n // resumes with the user's answer as resume data.\n if (resumeData === undefined) {\n if (!suspend) {\n return {\n content: `Cannot request sandbox access: interactive context not available. The user should manually run /sandbox add ${absolutePath}`,\n isError: true,\n };\n }\n await suspend({ kind: 'sandbox_access_request', path: absolutePath, reason });\n return;\n }\n\n const answerText = Array.isArray(resumeData) ? resumeData.join(', ') : String(resumeData);\n const approved = answerText.toLowerCase().startsWith('y') || answerText.toLowerCase() === 'approve';\n if (approved) {\n // Persist to controller state first (and await it) so the value is\n // committed before the next tool call re-derives the workspace's\n // allowed paths from state. The workspace factory rebuilds the\n // filesystem allowlist from `sandboxAllowedPaths` on every call\n // (getDynamicWorkspace), so an unawaited setState would let that\n // rebuild clobber the in-turn widen below before the grant lands.\n const controllerState = agentControllerCtx?.getState();\n const currentAllowed = (controllerState?.sandboxAllowedPaths as string[] | undefined) ?? [];\n const nextAllowed = currentAllowed.includes(absolutePath) ? currentAllowed : [...currentAllowed, absolutePath];\n if (!currentAllowed.includes(absolutePath)) {\n await agentControllerCtx?.setState({\n sandboxAllowedPaths: nextAllowed,\n });\n }\n\n // Also update the live workspace filesystem immediately so tools in\n // the same turn (e.g. `view`) can access the path without waiting for\n // a fresh workspace build. The resolved workspace is carried on the\n // controller request context — the tool-execution context does not expose\n // it — so read the filesystem from there.\n const fs = agentControllerCtx?.workspace?.filesystem ?? context?.workspace?.filesystem;\n if (fs instanceof LocalFilesystem) {\n fs.setAllowedPaths((prev: readonly string[]) => [...prev, absolutePath]);\n }\n\n return {\n content: `Access granted: \"${absolutePath}\" has been added to allowed paths. You can now access files in this directory.`,\n isError: false,\n };\n }\n return {\n content: `Access denied: The user declined access to \"${absolutePath}\".`,\n isError: false,\n };\n } catch (error) {\n const msg = error instanceof Error ? error.message : 'Unknown error';\n return {\n content: `Failed to request sandbox access: ${msg}`,\n isError: true,\n };\n }\n },\n} as any);\n"],"mappings":";;;;;;;;;;;AAcA,SAAS,YAAY,GAAmB;CACtC,IAAI,MAAM,KAAK,OAAOA,KAAG,QAAQ;CACjC,IAAI,EAAE,WAAW,IAAI,KAAK,EAAE,WAAW,KAAK,GAAG,OAAOC,OAAK,KAAKD,KAAG,QAAQ,GAAG,EAAE,MAAM,CAAC,CAAC;CACxF,OAAO;AACT;AAOA,MAAM,kCAAkC,EAAE,OAAO;CAC/C,MAAM,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,SAAS,wDAAwD;CACzF,QAAQ,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,SAAS,6DAA6D;AAClG,CAAC;AAED,MAAa,2BAA2B,WAAW;CACjD,IAAI;CACJ,aAAa;CACb,aAAa;CACb,eAAe,EAAE,OAAO;EACtB,MAAM,EAAE,QAAQ,wBAAwB;EACxC,MAAM,EAAE,OAAO;EACf,QAAQ,EAAE,OAAO;CACnB,CAAC;CACD,cAAc,EAAE,MAAM,CAAC,EAAE,OAAO,GAAG,EAAE,MAAM,EAAE,OAAO,CAAC,CAAC,CAAC;CACvD,SAAS,OAAO,EAAE,MAAM,eAAe,UAAqC,YAAiB;EAC3F,IAAI;GACF,MAAM,qBAAqB,SAAS,gBAAgB,IAAI,YAAY;GAKpE,MAAM,cAAc,oBAAoB,SAAS,CAAC,EAAE,eAAe,QAAQ,IAAI;GAC/E,MAAM,WAAW,YAAY,aAAa;GAC1C,MAAM,eAAeC,OAAK,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","sources":["../../src/tools/web-search.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,2BAA2B,CAAC;AAwB1E;;;;GAIG;AACH,wBAAgB,YAAY,IAAI,OAAO,CAEtC;AAED,wEAAwE;AACxE,wBAAgB,cAAc,IAAI,OAAO,CAExC;AAED;;;;GAIG;AACH,wBAAsB,mBAAmB;;;;;;;;;;;oIA+BxC;AAED;;;GAGG;AACH,wBAAsB,oBAAoB;;;;;;qIAyBzC;AAED;;;GAGG;AACH,wBAAsB,2BAA2B;;oIAwBhD;AAED;;;GAGG;AACH,wBAAsB,4BAA4B;;;;;;;;;qBArIjC,CAAC;sBACJ,CAAC;4BAGZ,CAAC;;;qIA0JH;AAED;;;;GAIG;AACH,wBAAgB,wBAAwB,CACtC,UAAU,GAAE,wBAAiC,GAC5C,QAAQ,GAAG,UAAU,GAAG,SAAS,CAQnC;AAED;;;;;GAKG;AACH,wBAAgB,wBAAwB;;;;;;;;;;;;;yBAvLvB,CAAC;0BACJ,CAAC;gCAGZ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;eA+LH"}
1
+ {"version":3,"file":"web-search.d.ts","sourceRoot":"","sources":["../../src/tools/web-search.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,2BAA2B,CAAC;AAwB1E;;;;GAIG;AACH,wBAAgB,YAAY,IAAI,OAAO,CAEtC;AAED,wEAAwE;AACxE,wBAAgB,cAAc,IAAI,OAAO,CAExC;AAED;;;;GAIG;AACH,wBAAsB,mBAAmB;;;;;;;;;;;oIA+BxC;AAED;;;GAGG;AACH,wBAAsB,oBAAoB;;;;;;qIAyBzC;AAED;;;GAGG;AACH,wBAAsB,2BAA2B;;oIAwBhD;AAED;;;GAGG;AACH,wBAAsB,4BAA4B;;;;;;;;;;;;;;qIAyBjD;AAED;;;;GAIG;AACH,wBAAgB,wBAAwB,CACtC,UAAU,GAAE,wBAAiC,GAC5C,QAAQ,GAAG,UAAU,GAAG,SAAS,CAQnC;AAED;;;;;GAKG;AACH,wBAAgB,wBAAwB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;eAYvC"}
@@ -2,8 +2,8 @@ export declare const getWorkflowTool: import("@mastra/core/tools").Tool<{
2
2
  id: string;
3
3
  }, {
4
4
  id: string;
5
- status: "active" | "archived";
6
5
  description?: string | undefined;
6
+ status: "active" | "archived";
7
7
  inputSchema?: any;
8
8
  outputSchema?: any;
9
9
  graph?: any[] | undefined;
@@ -1,8 +1,8 @@
1
1
  export declare const listAvailableAgentsTool: import("@mastra/core/tools").Tool<Record<string, never>, {
2
2
  agents: {
3
3
  id: string;
4
- outputShape: string;
5
4
  description?: string | undefined;
5
+ outputShape: string;
6
6
  }[];
7
7
  }, unknown, unknown, import("@mastra/core/tools").ToolExecutionContext<unknown, unknown, unknown>, "list-available-agents", unknown>;
8
8
  //# sourceMappingURL=list-available-agents.d.ts.map
@@ -1,19 +1,19 @@
1
1
  export declare const listAvailableClassifiersTool: import("@mastra/core/tools").Tool<Record<string, never>, {
2
2
  classifiers: {
3
3
  id: string;
4
- outputPaths: {
5
- answers: string;
6
- usage: string;
7
- };
8
4
  questions?: {
9
5
  id: string;
10
- type: "boolean" | "score" | "choice";
11
- answerPath: string;
12
- routingPath: string;
6
+ type: "boolean" | "choice" | "score";
13
7
  instructions?: any;
14
8
  choices?: string[] | undefined;
15
9
  criteria?: any;
10
+ answerPath: string;
11
+ routingPath: string;
16
12
  }[] | undefined;
13
+ outputPaths: {
14
+ answers: string;
15
+ usage: string;
16
+ };
17
17
  }[];
18
18
  }, unknown, unknown, import("@mastra/core/tools").ToolExecutionContext<unknown, unknown, unknown>, "list-available-classifiers", unknown>;
19
19
  //# sourceMappingURL=list-available-classifiers.d.ts.map
@@ -1,8 +1,8 @@
1
1
  export declare const listWorkflowsTool: import("@mastra/core/tools").Tool<Record<string, never>, {
2
2
  workflows: {
3
3
  id: string;
4
- status: "active" | "archived";
5
4
  description?: string | undefined;
5
+ status: "active" | "archived";
6
6
  }[];
7
7
  total: number;
8
8
  }, unknown, unknown, import("@mastra/core/tools").ToolExecutionContext<unknown, unknown, unknown>, "list-workflows", unknown>;