mastracode 0.22.3 → 0.23.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 (181) hide show
  1. package/CHANGELOG.md +55 -0
  2. package/dist/HarnessCompat.d.ts +2 -2
  3. package/dist/HarnessCompat.d.ts.map +1 -1
  4. package/dist/agents/mastracode-gateway.d.ts +58 -0
  5. package/dist/agents/mastracode-gateway.d.ts.map +1 -0
  6. package/dist/agents/model.d.ts +26 -28
  7. package/dist/agents/model.d.ts.map +1 -1
  8. package/dist/agents/{subagents/execute.d.ts → modes/build.d.ts} +3 -3
  9. package/dist/agents/modes/build.d.ts.map +1 -0
  10. package/dist/agents/{subagents → modes}/explore.d.ts +2 -2
  11. package/dist/agents/modes/explore.d.ts.map +1 -0
  12. package/dist/agents/modes/plan.d.ts +6 -0
  13. package/dist/agents/modes/plan.d.ts.map +1 -0
  14. package/dist/{chunk-EATS4KOR.cjs → chunk-3CO7PY6M.cjs} +1094 -239
  15. package/dist/chunk-3CO7PY6M.cjs.map +1 -0
  16. package/dist/{chunk-DJEQBK7L.cjs → chunk-CBPEMMRV.cjs} +1659 -2010
  17. package/dist/chunk-CBPEMMRV.cjs.map +1 -0
  18. package/dist/{chunk-W7Y7QIJA.js → chunk-FXYM4OEI.js} +14 -805
  19. package/dist/chunk-FXYM4OEI.js.map +1 -0
  20. package/dist/{chunk-OXYE6SUY.js → chunk-GKGPZBID.js} +836 -1187
  21. package/dist/chunk-GKGPZBID.js.map +1 -0
  22. package/dist/{chunk-FDDVVRPH.js → chunk-RDIIIT54.js} +1076 -221
  23. package/dist/chunk-RDIIIT54.js.map +1 -0
  24. package/dist/{chunk-NKTZDFIU.cjs → chunk-XPPJHUAD.cjs} +12 -809
  25. package/dist/chunk-XPPJHUAD.cjs.map +1 -0
  26. package/dist/cli.cjs +18 -18
  27. package/dist/cli.js +3 -3
  28. package/dist/index.cjs +3 -3
  29. package/dist/index.d.ts +4 -5
  30. package/dist/index.d.ts.map +1 -1
  31. package/dist/index.js +1 -1
  32. package/dist/mcp/manager.d.ts.map +1 -1
  33. package/dist/onboarding/onboarding-inline.d.ts +2 -2
  34. package/dist/onboarding/onboarding-inline.d.ts.map +1 -1
  35. package/dist/onboarding/settings.d.ts.map +1 -1
  36. package/dist/providers/claude-max.d.ts.map +1 -1
  37. package/dist/tui/chat-boundary-reconciliation.d.ts +18 -1
  38. package/dist/tui/chat-boundary-reconciliation.d.ts.map +1 -1
  39. package/dist/tui/command-dispatch.d.ts.map +1 -1
  40. package/dist/tui/commands/browser.d.ts.map +1 -1
  41. package/dist/tui/commands/goal.d.ts.map +1 -1
  42. package/dist/tui/commands/mode.d.ts.map +1 -1
  43. package/dist/tui/commands/new.d.ts.map +1 -1
  44. package/dist/tui/commands/settings.d.ts.map +1 -1
  45. package/dist/tui/commands/skills.d.ts.map +1 -1
  46. package/dist/tui/components/api-key-dialog.d.ts +2 -2
  47. package/dist/tui/components/api-key-dialog.d.ts.map +1 -1
  48. package/dist/tui/components/ask-question-dialog.d.ts +2 -2
  49. package/dist/tui/components/ask-question-dialog.d.ts.map +1 -1
  50. package/dist/tui/components/ask-question-inline.d.ts +4 -2
  51. package/dist/tui/components/ask-question-inline.d.ts.map +1 -1
  52. package/dist/tui/components/assistant-message.d.ts +2 -2
  53. package/dist/tui/components/assistant-message.d.ts.map +1 -1
  54. package/dist/tui/components/chat-boundary-spacer.d.ts +9 -9
  55. package/dist/tui/components/chat-boundary-spacer.d.ts.map +1 -1
  56. package/dist/tui/components/chat-spacing.d.ts +1 -1
  57. package/dist/tui/components/chat-spacing.d.ts.map +1 -1
  58. package/dist/tui/components/collapsible.d.ts +2 -2
  59. package/dist/tui/components/collapsible.d.ts.map +1 -1
  60. package/dist/tui/components/custom-editor.d.ts +2 -2
  61. package/dist/tui/components/custom-editor.d.ts.map +1 -1
  62. package/dist/tui/components/diff-output.d.ts +3 -1
  63. package/dist/tui/components/diff-output.d.ts.map +1 -1
  64. package/dist/tui/components/error-display.d.ts +4 -2
  65. package/dist/tui/components/error-display.d.ts.map +1 -1
  66. package/dist/tui/components/goal-cycles-dialog.d.ts +2 -2
  67. package/dist/tui/components/goal-cycles-dialog.d.ts.map +1 -1
  68. package/dist/tui/components/idle-counter.d.ts +1 -1
  69. package/dist/tui/components/idle-counter.d.ts.map +1 -1
  70. package/dist/tui/components/judge-display.d.ts +14 -2
  71. package/dist/tui/components/judge-display.d.ts.map +1 -1
  72. package/dist/tui/components/login-dialog.d.ts +2 -2
  73. package/dist/tui/components/login-dialog.d.ts.map +1 -1
  74. package/dist/tui/components/login-mode-selector.d.ts +2 -2
  75. package/dist/tui/components/login-mode-selector.d.ts.map +1 -1
  76. package/dist/tui/components/login-selector.d.ts +1 -1
  77. package/dist/tui/components/login-selector.d.ts.map +1 -1
  78. package/dist/tui/components/masked-input.d.ts +1 -1
  79. package/dist/tui/components/masked-input.d.ts.map +1 -1
  80. package/dist/tui/components/mcp-selector.d.ts +2 -2
  81. package/dist/tui/components/mcp-selector.d.ts.map +1 -1
  82. package/dist/tui/components/model-selector.d.ts +2 -2
  83. package/dist/tui/components/model-selector.d.ts.map +1 -1
  84. package/dist/tui/components/multi-step-progress.d.ts +3 -1
  85. package/dist/tui/components/multi-step-progress.d.ts.map +1 -1
  86. package/dist/tui/components/multiline-input.d.ts +1 -1
  87. package/dist/tui/components/multiline-input.d.ts.map +1 -1
  88. package/dist/tui/components/notification-summary.d.ts +1 -1
  89. package/dist/tui/components/notification-summary.d.ts.map +1 -1
  90. package/dist/tui/components/notification.d.ts +1 -1
  91. package/dist/tui/components/notification.d.ts.map +1 -1
  92. package/dist/tui/components/om-marker.d.ts +3 -1
  93. package/dist/tui/components/om-marker.d.ts.map +1 -1
  94. package/dist/tui/components/om-output.d.ts +3 -1
  95. package/dist/tui/components/om-output.d.ts.map +1 -1
  96. package/dist/tui/components/om-progress.d.ts +1 -1
  97. package/dist/tui/components/om-progress.d.ts.map +1 -1
  98. package/dist/tui/components/om-settings.d.ts +2 -2
  99. package/dist/tui/components/om-settings.d.ts.map +1 -1
  100. package/dist/tui/components/plan-approval-inline.d.ts +2 -2
  101. package/dist/tui/components/plan-approval-inline.d.ts.map +1 -1
  102. package/dist/tui/components/reactive-signal.d.ts +1 -1
  103. package/dist/tui/components/reactive-signal.d.ts.map +1 -1
  104. package/dist/tui/components/settings.d.ts +2 -2
  105. package/dist/tui/components/settings.d.ts.map +1 -1
  106. package/dist/tui/components/shell-output.d.ts +3 -1
  107. package/dist/tui/components/shell-output.d.ts.map +1 -1
  108. package/dist/tui/components/simple-progress.d.ts +1 -1
  109. package/dist/tui/components/simple-progress.d.ts.map +1 -1
  110. package/dist/tui/components/slash-command.d.ts +3 -1
  111. package/dist/tui/components/slash-command.d.ts.map +1 -1
  112. package/dist/tui/components/state-signal.d.ts +1 -1
  113. package/dist/tui/components/state-signal.d.ts.map +1 -1
  114. package/dist/tui/components/subagent-execution.d.ts +2 -2
  115. package/dist/tui/components/subagent-execution.d.ts.map +1 -1
  116. package/dist/tui/components/system-reminder.d.ts +1 -1
  117. package/dist/tui/components/system-reminder.d.ts.map +1 -1
  118. package/dist/tui/components/task-progress.d.ts +1 -1
  119. package/dist/tui/components/task-progress.d.ts.map +1 -1
  120. package/dist/tui/components/temporal-gap.d.ts +3 -1
  121. package/dist/tui/components/temporal-gap.d.ts.map +1 -1
  122. package/dist/tui/components/thinking-settings.d.ts +2 -2
  123. package/dist/tui/components/thinking-settings.d.ts.map +1 -1
  124. package/dist/tui/components/thread-selector.d.ts +2 -2
  125. package/dist/tui/components/thread-selector.d.ts.map +1 -1
  126. package/dist/tui/components/tool-approval-dialog.d.ts +2 -2
  127. package/dist/tui/components/tool-approval-dialog.d.ts.map +1 -1
  128. package/dist/tui/components/tool-execution-enhanced.d.ts +2 -2
  129. package/dist/tui/components/tool-execution-enhanced.d.ts.map +1 -1
  130. package/dist/tui/components/tool-validation-error.d.ts +2 -2
  131. package/dist/tui/components/tool-validation-error.d.ts.map +1 -1
  132. package/dist/tui/components/user-message.d.ts +2 -2
  133. package/dist/tui/components/user-message.d.ts.map +1 -1
  134. package/dist/tui/components/wrapping-autocomplete-list.d.ts +1 -1
  135. package/dist/tui/components/wrapping-autocomplete-list.d.ts.map +1 -1
  136. package/dist/tui/components/wrapping-select-list.d.ts +1 -1
  137. package/dist/tui/components/wrapping-select-list.d.ts.map +1 -1
  138. package/dist/tui/display.d.ts.map +1 -1
  139. package/dist/tui/event-dispatch.d.ts.map +1 -1
  140. package/dist/tui/goal-manager.d.ts +48 -40
  141. package/dist/tui/goal-manager.d.ts.map +1 -1
  142. package/dist/tui/handlers/agent-lifecycle.d.ts +13 -0
  143. package/dist/tui/handlers/agent-lifecycle.d.ts.map +1 -1
  144. package/dist/tui/handlers/index.d.ts +1 -1
  145. package/dist/tui/handlers/index.d.ts.map +1 -1
  146. package/dist/tui/handlers/message.d.ts.map +1 -1
  147. package/dist/tui/handlers/om.d.ts.map +1 -1
  148. package/dist/tui/handlers/tool.d.ts.map +1 -1
  149. package/dist/tui/handlers/types.d.ts +1 -1
  150. package/dist/tui/handlers/types.d.ts.map +1 -1
  151. package/dist/tui/mastra-tui.d.ts.map +1 -1
  152. package/dist/tui/modal-question.d.ts +1 -1
  153. package/dist/tui/modal-question.d.ts.map +1 -1
  154. package/dist/tui/overlay.d.ts +1 -1
  155. package/dist/tui/overlay.d.ts.map +1 -1
  156. package/dist/tui/prompt-api-key.d.ts +1 -1
  157. package/dist/tui/prompt-api-key.d.ts.map +1 -1
  158. package/dist/tui/render-messages.d.ts +1 -1
  159. package/dist/tui/render-messages.d.ts.map +1 -1
  160. package/dist/tui/setup.d.ts.map +1 -1
  161. package/dist/tui/shell.d.ts.map +1 -1
  162. package/dist/tui/state.d.ts +2 -2
  163. package/dist/tui/state.d.ts.map +1 -1
  164. package/dist/tui/status-line.d.ts.map +1 -1
  165. package/dist/tui/theme.d.ts +1 -1
  166. package/dist/tui/theme.d.ts.map +1 -1
  167. package/dist/tui.cjs +19 -19
  168. package/dist/tui.js +2 -2
  169. package/package.json +20 -20
  170. package/dist/agents/coding.d.ts +0 -2
  171. package/dist/agents/coding.d.ts.map +0 -1
  172. package/dist/agents/subagents/execute.d.ts.map +0 -1
  173. package/dist/agents/subagents/explore.d.ts.map +0 -1
  174. package/dist/agents/subagents/plan.d.ts +0 -10
  175. package/dist/agents/subagents/plan.d.ts.map +0 -1
  176. package/dist/chunk-DJEQBK7L.cjs.map +0 -1
  177. package/dist/chunk-EATS4KOR.cjs.map +0 -1
  178. package/dist/chunk-FDDVVRPH.js.map +0 -1
  179. package/dist/chunk-NKTZDFIU.cjs.map +0 -1
  180. package/dist/chunk-OXYE6SUY.js.map +0 -1
  181. package/dist/chunk-W7Y7QIJA.js.map +0 -1
package/CHANGELOG.md CHANGED
@@ -1,5 +1,60 @@
1
1
  # mastracode
2
2
 
3
+ ## 0.23.0
4
+
5
+ ### Minor Changes
6
+
7
+ - Reimplement `/goal` on top of the Agent's native goal mechanism instead of a MastraCode-specific judge loop. ([#17889](https://github.com/mastra-ai/mastra/pull/17889))
8
+
9
+ The goal is now configured on the agent (`goal: { judge, maxRuns, prompt }`, sourced from the `goalJudgeModel` / `goalMaxTurns` settings) and evaluated **in-loop** by the core goal step, surfaced via the typed `goal` stream chunk. `GoalManager` is now a thin adapter over the agent's `setObjective` / `getObjective` / `clearObjective` / `updateObjectiveOptions` methods backed by the thread-scoped `threadState` store, so the objective persists across thread reloads and process restarts. The old between-turn judge agent (`evaluateAfterTurn`, `maybeGoalContinuation`, the judge memory/tools, and the judge-failure resume retrigger) has been removed.
10
+
11
+ All user-facing behavior is preserved: `/goal <text>`, `/goal status|pause|resume|clear`, the goal action modal, the judge settings dialog (which now persists updated judge defaults into the active objective record), the status line, Esc-to-pause and the goal input lock, the judge display, and the plan-approval "Use as /goal" flow with plan-mode auto-switch on completion.
12
+
13
+ The standalone `/judge` command is now the `/goal judge` subcommand, grouping judge configuration under the goal it belongs to (the judge model is only meaningful for evaluating a goal).
14
+
15
+ The goal judge model is resolved through mastracode's model gateway (`goal.judge` is a resolver function), so provider credentials stored in auth storage are injected — previously the goal scorer received a bare model id and failed with "Could not find API key" for the configured judge. Because evaluation now happens during the run, an objective with no judge model configured anywhere is inert (no judging, no continuation).
16
+
17
+ The raw `<current-objective>` goal state signal is suppressed in the transcript (both streamed and replayed), matching the existing behavior for the `<current-task-list>` task signal — the objective is surfaced by the goal/judge UI instead of echoed inline.
18
+
19
+ - Added MastraCode mode definitions for build, plan, and explore workflows using the shared harness mode model. ([#17892](https://github.com/mastra-ai/mastra/pull/17892))
20
+
21
+ ### Patch Changes
22
+
23
+ - Enable the alpha browser video recording tools for Mastra Code's browser integration. Mastra Code now opts its configured browser provider into recording and stores videos in the app-data `browser-recordings` directory. ([#17028](https://github.com/mastra-ai/mastra/pull/17028))
24
+
25
+ Agents can use `browser_record` to start, stop, and check recording status, then use `browser_record_caption` to add short captions that are burned into the saved Motion-JPEG AVI video.
26
+
27
+ - Fixed mastracode silently writing all tracing/observability data to the main libsql database even when /observability was never configured. The MastraStorageExporter now only activates when local DuckDB tracing is explicitly enabled via `/observability local on`, preventing the mastra_ai_spans table from growing to tens or hundreds of gigabytes. ([#18033](https://github.com/mastra-ai/mastra/pull/18033))
28
+
29
+ - Moved MastraCode model catalog and gateway-backed model resolution out of the core harness and into a class-backed MastraCode gateway, with model IDs resolving directly to gateway-created provider instances. ([#17913](https://github.com/mastra-ai/mastra/pull/17913))
30
+
31
+ - Migrated from deprecated @mariozechner/pi-tui to @earendil-works/pi-tui. Mastra Code now requires Node.js 22.19.0 or newer to match the new terminal UI dependency. ([#17974](https://github.com/mastra-ai/mastra/pull/17974))
32
+
33
+ - dependencies updates: ([#17846](https://github.com/mastra-ai/mastra/pull/17846))
34
+ - Updated dependency [`posthog-node@^5.37.0` ↗︎](https://www.npmjs.com/package/posthog-node/v/5.37.0) (from `^5.28.3`, in `dependencies`)
35
+
36
+ - Fixed claude-fable-5 requests failing with "Invalid request: fallbacks: Extra inputs are not permitted" when logged in with Claude Max OAuth. The OAuth fetch wrapper was overwriting the anthropic-beta header, dropping the server-side-fallback beta that the automatic fable-5 fallback configuration requires. Request betas are now merged with the OAuth-required betas instead of being replaced. ([#17897](https://github.com/mastra-ai/mastra/pull/17897))
37
+
38
+ - Moved Mastra Code model discovery and resolution onto its gateway configuration. ([#17913](https://github.com/mastra-ai/mastra/pull/17913))
39
+
40
+ - Fixed TUI chat spacing so message layout stays stable while the assistant streams. Chat spacing now runs through a single boundary-spacing pass, preventing flicker from dynamic spacer recomputation, avoiding stacked or missing blank lines, and keeping custom slash command previews consistently spaced as responses begin. ([#17979](https://github.com/mastra-ai/mastra/pull/17979))
41
+
42
+ - Fixed harness modes so they can reuse configured agents and resolve their default models before running. ([#17892](https://github.com/mastra-ai/mastra/pull/17892))
43
+
44
+ - Fixed cross-instance output leaking between mastracode TUI tabs after /new. The /new command now fully unsubscribes from the old thread's PubSub topic instead of only aborting the current run, preventing another mc instance on the same thread from pushing events into the detached TUI. ([#17883](https://github.com/mastra-ai/mastra/pull/17883))
45
+
46
+ - Updated dependencies [[`de66bb0`](https://github.com/mastra-ai/mastra/commit/de66bb040570444c702ce4d8e1e228a5de2949cb), [`67bf8e2`](https://github.com/mastra-ai/mastra/commit/67bf8e206dfe583954d96015cf0d09f7ac50e45f), [`8216d05`](https://github.com/mastra-ai/mastra/commit/8216d0528d866eb9a07f5d4c87ea3bb1e1139b45), [`d18b23c`](https://github.com/mastra-ai/mastra/commit/d18b23c5e29dfc381e73e3c51fcf6c779afd1823), [`8216d05`](https://github.com/mastra-ai/mastra/commit/8216d0528d866eb9a07f5d4c87ea3bb1e1139b45), [`bec2f15`](https://github.com/mastra-ai/mastra/commit/bec2f151d01f61f41dc45538a1ab8f80bad260d8), [`5eb94eb`](https://github.com/mastra-ai/mastra/commit/5eb94ebcf66d4e28c9e26d5821ac93379bab20a0), [`1fa3e12`](https://github.com/mastra-ai/mastra/commit/1fa3e123582b63cfe49de4ee52dc6a065e8d956a), [`f9ee2ac`](https://github.com/mastra-ai/mastra/commit/f9ee2ac661af584e61bc063ac208c9035cd752ef), [`c853d53`](https://github.com/mastra-ai/mastra/commit/c853d535d2df84ab89db1adb4c28900c54c9a2d2), [`d8df1f8`](https://github.com/mastra-ai/mastra/commit/d8df1f8e947e1966c9d4e54713df56d0d0d65226), [`9192ddb`](https://github.com/mastra-ai/mastra/commit/9192ddbced8949113b30de444cbe763f075b59f5), [`ae96523`](https://github.com/mastra-ai/mastra/commit/ae965231f562d9766b0c90c49a69fc68acaa031c), [`17d5a92`](https://github.com/mastra-ai/mastra/commit/17d5a9211aa293b4d4418de3de70dc0394d58101), [`5573693`](https://github.com/mastra-ai/mastra/commit/5573693b589822250e20dfe6cf66e9ff3bc96da8), [`ec4da8a`](https://github.com/mastra-ai/mastra/commit/ec4da8a09e0d2ab452c6ee2c786042ea826b77e5), [`adc44e1`](https://github.com/mastra-ai/mastra/commit/adc44e13c7e570b91e86b20ea7556e61d819db31), [`218d952`](https://github.com/mastra-ai/mastra/commit/218d952ec09e5111c10ccd143b5bc0ef19434376), [`7c987b4`](https://github.com/mastra-ai/mastra/commit/7c987b4cfcc498bb579f986d07f794633f8e0ff8), [`ed346c0`](https://github.com/mastra-ai/mastra/commit/ed346c0bee2d8496690a4e538bfba1e46894660f), [`9b1adf7`](https://github.com/mastra-ai/mastra/commit/9b1adf7f39943c869182106bc4016e793b3304ac), [`c9ce1b2`](https://github.com/mastra-ai/mastra/commit/c9ce1b28d10871110648f9d7b6d76e880b9fa999), [`81fe587`](https://github.com/mastra-ai/mastra/commit/81fe587275035715c1720ddf3fee0505cf053036), [`3ef01fd`](https://github.com/mastra-ai/mastra/commit/3ef01fd130b53d5bd4f828beb174e516a2eb1158), [`4572357`](https://github.com/mastra-ai/mastra/commit/45723576c19602ba28528d498399c67e2efc86f4), [`245a9a3`](https://github.com/mastra-ai/mastra/commit/245a9a315705fce17ddd980f78a92504b6615c4a), [`dc0b611`](https://github.com/mastra-ai/mastra/commit/dc0b6119b769bd00ee2c5df9259fb376fe63077a), [`38b5de8`](https://github.com/mastra-ai/mastra/commit/38b5de8e5d1d41a69522addf53d96f4b3a1d5bf0), [`eae1556`](https://github.com/mastra-ai/mastra/commit/eae1556eedac109b67d91b627689cdf70a83bab7), [`efe917d`](https://github.com/mastra-ai/mastra/commit/efe917d524f285d9d131804027c7201bf7aee110), [`b9ac4c3`](https://github.com/mastra-ai/mastra/commit/b9ac4c3ab54b0889c01d7f7285cca89a791d2351), [`dc0b611`](https://github.com/mastra-ai/mastra/commit/dc0b6119b769bd00ee2c5df9259fb376fe63077a), [`dd6a66e`](https://github.com/mastra-ai/mastra/commit/dd6a66ea0b32e0dea8059aec6b35d151e2c87dc4), [`d785c59`](https://github.com/mastra-ai/mastra/commit/d785c593b67fcb4cdc4fab9fdbde5f3b7665efc0), [`1fa3e12`](https://github.com/mastra-ai/mastra/commit/1fa3e123582b63cfe49de4ee52dc6a065e8d956a), [`8b984f4`](https://github.com/mastra-ai/mastra/commit/8b984f4361c202270ceb69257185c4756c9a7c56), [`bf08402`](https://github.com/mastra-ai/mastra/commit/bf084022374fa5d06ca70ed67a86dd64e379071b), [`81fe587`](https://github.com/mastra-ai/mastra/commit/81fe587275035715c1720ddf3fee0505cf053036), [`1fa3e12`](https://github.com/mastra-ai/mastra/commit/1fa3e123582b63cfe49de4ee52dc6a065e8d956a), [`403c438`](https://github.com/mastra-ai/mastra/commit/403c438e417278989ce247233d2c465b8d902cdd), [`f8ba195`](https://github.com/mastra-ai/mastra/commit/f8ba1954e27ee2b20586cc6cd9cf13c002c232f2)]:
47
+ - @mastra/core@1.43.0
48
+ - @mastra/tavily@1.0.3
49
+ - @mastra/memory@1.20.4
50
+ - @mastra/observability@1.14.2
51
+ - @mastra/schema-compat@1.2.12
52
+ - @mastra/stagehand@0.2.5
53
+ - @mastra/agent-browser@0.3.2
54
+ - @mastra/libsql@1.13.1
55
+ - @mastra/pg@1.13.1
56
+ - @mastra/mcp@1.10.0
57
+
3
58
  ## 0.22.3
4
59
 
5
60
  ### Patch Changes
@@ -11,7 +11,7 @@ type CloneSessionOptions = {
11
11
  modeId?: string;
12
12
  modelId?: string;
13
13
  };
14
- export declare function v1ModeToLegacy<TState = {}>(mode: HarnessMode, agent: Agent): HarnessModeLegacy<TState>;
14
+ export declare function v1ModeToLegacy(mode: HarnessMode, agent: Agent): HarnessModeLegacy;
15
15
  export declare class HarnessCompat<TState = {}> extends HarnessLegacy<TState> {
16
16
  #private;
17
17
  constructor(args: HarnessConfig<TState>, harnessV1: Harness<HarnessMode[], TState>);
@@ -37,7 +37,7 @@ export declare class HarnessCompat<TState = {}> extends HarnessLegacy<TState> {
37
37
  title?: string;
38
38
  resourceId?: string;
39
39
  }): Promise<HarnessThread>;
40
- getCurrentMode(): HarnessModeLegacy<TState>;
40
+ getCurrentMode(): HarnessModeLegacy;
41
41
  /**
42
42
  * Switch to a different mode.
43
43
  * Aborts any in-progress generation and switches to the mode's default model.
@@ -1 +1 @@
1
- {"version":3,"file":"HarnessCompat.d.ts","sourceRoot":"","sources":["../src/HarnessCompat.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,oBAAoB,CAAC;AAChD,OAAO,EAAE,OAAO,IAAI,aAAa,EAAE,MAAM,sBAAsB,CAAC;AAChE,OAAO,KAAK,EAAE,aAAa,EAAE,WAAW,IAAI,iBAAiB,EAAE,aAAa,EAAE,MAAM,sBAAsB,CAAC;AAC3G,OAAO,KAAK,EAAE,OAAO,EAAE,WAAW,EAAE,OAAO,EAAE,MAAM,yBAAyB,CAAC;AAE7E,KAAK,mBAAmB,GAAG;IACzB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,MAAM,CAAC,EAAE,WAAW,GAAG,eAAe,CAAC;IACvC,MAAM,CAAC,EAAE,MAAM,CAAC;I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E,EAAE;QAAE,MAAM,EAAE,MAAM,CAAA;KAAE,GAAG,OAAO,CAAC,IAAI,CAAC;IAe/D;;;;;;OAMG;IACG,QAAQ,CAAC,IAAI,EAAE,MAAM,EAAE,KAAK,CAAC,EAAE;QAAE,IAAI,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAA;KAAE,GAAG,OAAO,CAAC,MAAM,CAAC;CAM1F"}
@@ -0,0 +1,58 @@
1
+ import type { CustomModelCatalogProvider } from '@mastra/core/harness';
2
+ import { MastraModelGateway } from '@mastra/core/llm';
3
+ import type { GatewayAuthRequest, GatewayAuthResult, GatewayLanguageModel, MastraModelGatewayInterface, ProviderConfig } from '@mastra/core/llm';
4
+ import type { ThinkingLevel } from '../providers/openai-codex.js';
5
+ export declare const OPENAI_PREFIX = "openai/";
6
+ export declare const MASTRA_GATEWAY_PREFIX = "mastra/";
7
+ export declare const MASTRACODE_GATEWAY_ID = "mastracode";
8
+ export type MastraCodeCustomProvider = {
9
+ name: string;
10
+ url: string;
11
+ apiKey?: string;
12
+ models?: string[];
13
+ };
14
+ export type MastraCodeGatewayOptions = {
15
+ mastraGatewayBaseUrl: string;
16
+ mastraGatewayApiKey?: string;
17
+ routeThroughMastraGateway: boolean;
18
+ thinkingLevel?: ThinkingLevel;
19
+ customProviders?: MastraCodeCustomProvider[];
20
+ settingsPath?: string;
21
+ };
22
+ export declare function reloadAuthStorage(): void;
23
+ export declare function stripMastraGatewayPrefix(modelId: string): string;
24
+ export declare function remapOpenAIModelForCodexOAuth(modelId: string): string;
25
+ /**
26
+ * Resolve the Anthropic API key.
27
+ * Main slot → dedicated apikey: slot → env var.
28
+ */
29
+ export declare function getAnthropicApiKey(): string | undefined;
30
+ /**
31
+ * Resolve the OpenAI API key.
32
+ * Main slot → dedicated apikey: slot → env var.
33
+ */
34
+ export declare function getOpenAIApiKey(): string | undefined;
35
+ export declare function resolveAuth(request: GatewayAuthRequest, memoryGatewayApiKey?: string): GatewayAuthResult | undefined;
36
+ export declare class MastraCodeGateway extends MastraModelGateway {
37
+ #private;
38
+ readonly id = "mastracode";
39
+ readonly name = "MastraCode Gateway";
40
+ constructor({ mastraGatewayBaseUrl, mastraGatewayApiKey, routeThroughMastraGateway, thinkingLevel, customProviders, settingsPath, }: MastraCodeGatewayOptions);
41
+ static getMemoryGatewayApiKey(): string | undefined;
42
+ static resolveProviderAuth(request: GatewayAuthRequest, memoryGatewayApiKey?: string): GatewayAuthResult | undefined;
43
+ static createModelCatalogProvider(gateway: MastraModelGatewayInterface): CustomModelCatalogProvider;
44
+ createModelCatalogProvider(): CustomModelCatalogProvider;
45
+ fetchProviders(): Promise<Record<string, ProviderConfig>>;
46
+ buildUrl(modelId: string): string | undefined | Promise<string | undefined>;
47
+ getApiKey(modelId: string): Promise<string>;
48
+ resolveAuth(request: GatewayAuthRequest): GatewayAuthResult | undefined;
49
+ resolveLanguageModel(args: {
50
+ modelId: string;
51
+ providerId: string;
52
+ apiKey: string;
53
+ headers?: Record<string, string>;
54
+ transport?: any;
55
+ responsesWebSocket?: any;
56
+ }): GatewayLanguageModel;
57
+ }
58
+ //# sourceMappingURL=mastracode-gateway.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"mastracode-gateway.d.ts","sourceRoot":"","sources":["../../src/agents/mastracode-gateway.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAwB,0BAA0B,EAAE,MAAM,sBAAsB,CAAC;AAC7F,OAAO,EAGL,kBAAkB,EAGnB,MAAM,kBAAkB,CAAC;AAC1B,OAAO,KAAK,EACV,kBAAkB,EAClB,iBAAiB,EACjB,oBAAoB,EACpB,2BAA2B,EAC3B,cAAc,EACf,MAAM,kBAAkB,CAAC;AAkB1B,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,8BAA8B,CAAC;AAElE,eAAO,MAAM,aAAa,YAAY,CAAC;AACvC,eAAO,MAAM,qBAAqB,YAAY,CAAC;AAC/C,eAAO,MAAM,qBAAqB,eAAe,CA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,SAAS;IAcpH,MAAM,CAAC,0BAA0B,CAAC,OAAO,EAAE,2BAA2B,GAAG,0BAA0B;IA+BnG,0BAA0B,IAAI,0BAA0B;IAQlD,cAAc,IAAI,OAAO,CAAC,MAAM,CAAC,MAAM,EAAE,cAAc,CAAC,CAAC;IA+B/D,QAAQ,CAAC,OAAO,EAAE,MAAM,GAAG,MAAM,GAAG,SAAS,GAAG,OAAO,CAAC,MAAM,GAAG,SAAS,CAAC;IAIrE,SAAS,CAAC,OAAO,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC;IAMjD,WAAW,CAAC,OAAO,EAAE,kBAAkB,GAAG,iBAAiB,GAAG,SAAS;IAevE,oBAAoB,CAAC,IAAI,EAAE;QACzB,OAAO,EAAE,MAAM,CAAC;QAChB,UAAU,EAAE,MAAM,CAAC;QACnB,MAAM,EAAE,MAAM,CAAC;QACf,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;QACjC,SAAS,CAAC,EAAE,GAAG,CAAC;QAChB,kBAAkB,CAAC,EAAE,GAAG,CAAC;KAC1B,GAAG,oBAAoB;CA0JzB"}
@@ -1,31 +1,13 @@
1
- import { createAnthropic } from '@ai-sdk/anthropic';
2
- import { createOpenAI } from '@ai-sdk/openai';
3
- import { ModelRouterLanguageModel } from '@mastra/core/llm';
4
- import type { GatewayAuthRequest, GatewayAuthResult } from '@mastra/core/llm';
1
+ import type { GatewayLanguageModel, MastraModelGatewayInterface } from '@mastra/core/llm';
5
2
  import type { RequestContext } from '@mastra/core/request-context';
6
- import { opencodeClaudeMaxProvider } from '../providers/claude-max.js';
7
- import { githubCopilotProvider } from '../providers/github-copilot.js';
8
- import { openaiCodexProvider } from '../providers/openai-codex.js';
9
3
  import type { ThinkingLevel } from '../providers/openai-codex.js';
10
- type ResolvedModel = ReturnType<typeof openaiCodexProvider> | ReturnType<typeof opencodeClaudeMaxProvider> | ReturnType<typeof githubCopilotProvider> | ModelRouterLanguageModel | ReturnType<ReturnType<typeof createAnthropic>> | ReturnType<ReturnType<typeof createOpenAI>>;
11
- export declare function remapOpenAIModelForCodexOAuth(modelId: string): string;
12
- /**
13
- * Resolve the Anthropic API key.
14
- * Main slot → dedicated apikey: slot → env var.
15
- */
16
- export declare function getAnthropicApiKey(): string | undefined;
17
- /**
18
- * Resolve the OpenAI API key.
19
- * Main slot → dedicated apikey: slot → env var.
20
- */
21
- export declare function getOpenAIApiKey(): string | undefined;
22
- export declare function resolveAuth(request: GatewayAuthRequest, memoryGatewayApiKey?: string): GatewayAuthResult | undefined;
23
- /**
24
- * Placeholder for future model ID normalization.
25
- * Currently returns the input unchanged, but exists as a seam
26
- * for aliasing, casing fixes, or validation in the future.
27
- */
28
- export declare function resolveModelId(modelId: string): string;
4
+ import { MastraCodeGateway } from './mastracode-gateway.js';
5
+ import type { MastraCodeGatewayOptions } from './mastracode-gateway.js';
6
+ export { getAnthropicApiKey, getOpenAIApiKey, MASTRACODE_GATEWAY_ID, MastraCodeGateway, remapOpenAIModelForCodexOAuth, resolveAuth, } from './mastracode-gateway.js';
7
+ export type { MastraCodeCustomProvider, MastraCodeGatewayOptions } from './mastracode-gateway.js';
8
+ type ResolvedModel = GatewayLanguageModel;
9
+ export declare function createMastraCodeGateway(options: MastraCodeGatewayOptions): MastraCodeGateway;
10
+ export declare function createMastraCodeModelCatalogProvider(gateway: MastraModelGatewayInterface): import("@mastra/core/harness").CustomModelCatalogProvider;
29
11
  /**
30
12
  * Resolve a model ID to the correct provider instance.
31
13
  * Shared by the main agent, observer, and reflector.
@@ -39,7 +21,7 @@ export declare function resolveModel(modelId: string, options?: {
39
21
  thinkingLevel?: ThinkingLevel;
40
22
  remapForCodexOAuth?: boolean;
41
23
  requestContext?: RequestContext;
42
- }): ResolvedModel;
24
+ }): GatewayLanguageModel;
43
25
  /**
44
26
  * Dynamic model function that reads the current model from harness state.
45
27
  * This allows runtime model switching via the /models picker.
@@ -47,5 +29,21 @@ export declare function resolveModel(modelId: string, options?: {
47
29
  export declare function getDynamicModel({ requestContext }: {
48
30
  requestContext: RequestContext;
49
31
  }): ResolvedModel;
50
- export {};
32
+ /**
33
+ * Goal judge model resolver for the agent's `goal.judge` config. Resolves the
34
+ * configured goal judge model through mastracode's gateway so provider
35
+ * credentials (stored in auth storage, not just env) are injected — a bare model
36
+ * id handed to core's default model router would fail to find the API key.
37
+ *
38
+ * Returns `undefined` when no judge model is configured, which keeps the goal
39
+ * step a complete no-op (the goal mechanism requires a judge to do anything).
40
+ *
41
+ * `settingsPath` must be the same source `createMastraCode()` reads from so the
42
+ * judge model and the goal budget (`goalMaxTurns`) come from one config — with a
43
+ * custom `settingsPath` a bare `loadSettings()` here could read a different file
44
+ * and silently turn the goal step into a no-op.
45
+ */
46
+ export declare function getGoalJudgeModel({ requestContext }: {
47
+ requestContext: RequestContext;
48
+ }, settingsPath?: string): ResolvedModel | undefined;
51
49
  //# sourceMappingURL=model.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"model.d.ts","sourceRoot":"","sources":["../../src/agents/model.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AACpD,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAG9C,OAAO,EAAsC,wBAAwB,EAAE,MAAM,kBAAkB,CAAC;AAChG,OAAO,KAAK,EACV,kBAAkB,EAClB,iBAAiB,EAGlB,MAAM,kBAAkB,CAAC;AAC1B,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,8BAA8B,CAAC;AAInE,OAAO,EAGL,yBAAyB,EAE1B,MAAM,4BAA4B,CAAC;AACpC,OAAO,EAAE,qBAAqB,EAAE,MAAM,gCAAgC,CAAC;AACvE,OAAO,EAIL,mBAAmB,EAEpB,MAAM,8BAA8B,CAAC;AACtC,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,8BAA8B,CAAC;AAgBlE,KAAK,aAAa,GACd,UAAU,CAAC,OAAO,mBAAmB,CAAC,GAC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,MAAM,yBAAyB,CAAC;AACjC,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,yBAAyB,CAAC;AAExE,OAAO,EACL,kBAAkB,EAClB,eAAe,EACf,qBAAqB,EACrB,iBAAiB,EACjB,6BAA6B,EAC7B,WAAW,GACZ,MAAM,yBAAyB,CAAC;AACjC,YAAY,EAAE,wBAAwB,EAAE,wBAAwB,EAAE,MAAM,yBAAyB,CAAC;AAElG,KAAK,aAAa,GAAG,oBAAoB,CAAC;AAa1C,wBAAgB,uBAAuB,CAAC,OAAO,EAAE,wBAAwB,GAAG,iBAAiB,CAE5F;AAED,wBAAgB,oCAAoC,CAAC,OAAO,EAAE,2BAA2B,6DAIxF;AAED;;;;;;;;GAQG;AACH,wBAAgB,YAAY,CAC1B,OAAO,EAAE,MAAM,EACf,OAAO,CAAC,EAAE;IAAE,aAAa,CAAC,EAAE,aAAa,CAAC;IAAC,kBAAkB,CAAC,EAAE,OAAO,CAAC;IAAC,cAAc,CAAC,EAAE,cAAc,CAAA;CAAE,GACzG,oBAAoB,CAqCtB;AAED;;;GAGG;AACH,wBAAgB,eAAe,CAAC,EAAE,cAAc,EAAE,EAAE;IAAE,cAAc,EAAE,cAAc,CAAA;CAAE,GAAG,aAAa,CAWrG;AAED;;;;;;;;;;;;;GAaG;AACH,wBAAgB,iBAAiB,CAC/B,EAAE,cAAc,EAAE,EAAE;IAAE,cAAc,EAAE,cAAc,CAAA;CAAE,EACtD,YAAY,CAAC,EAAE,MAAM,GACpB,aAAa,GAAG,SAAS,CAI3B"}
@@ -5,6 +5,6 @@
5
5
  * read and write tools to complete it. It can modify files, run commands,
6
6
  * and perform actual development work within a constrained scope.
7
7
  */
8
- import type { HarnessSubagent } from '@mastra/core/harness';
9
- export declare const executeSubagent: HarnessSubagent;
10
- //# sourceMappingURL=execute.d.ts.map
8
+ import type { HarnessMode } from '@mastra/core/harness';
9
+ export declare const buildMode: HarnessMode;
10
+ //# sourceMappingURL=build.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"build.d.ts","sourceRoot":"","sources":["../../../src/agents/modes/build.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AACH,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,sBAAsB,CAAC;AAExD,eAAO,MAAM,SAAS,EAAE,WAyCvB,CAAC"}
@@ -5,6 +5,6 @@
5
5
  * "understand how module Y works") and uses read-only tools to explore
6
6
  * the codebase, then returns a concise summary of its findings.
7
7
  */
8
- import type { HarnessSubagent } from '@mastra/core/harness';
9
- export declare const exploreSubagent: HarnessSubagent;
8
+ import type { HarnessMode } from '@mastra/core/harness';
9
+ export declare const fastMode: HarnessMode;
10
10
  //# sourceMappingURL=explore.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"explore.d.ts","sourceRoot":"","sources":["../../../src/agents/modes/explore.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AACH,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,sBAAsB,CAAC;AAExD,eAAO,MAAM,QAAQ,EAAE,WAgCtB,CAAC"}
@@ -0,0 +1,6 @@
1
+ /**
2
+ * Plan mode — read-only analysis and planning.
3
+ */
4
+ import type { HarnessMode } from '@mastra/core/harness';
5
+ export declare const planMode: HarnessMode;
6
+ //# sourceMappingURL=plan.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"plan.d.ts","sourceRoot":"","sources":["../../../src/agents/modes/plan.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,sBAAsB,CAAC;AAExD,eAAO,MAAM,QAAQ,EAAE,WAuCtB,CAAC"}