mastracode 0.36.0-alpha.7 → 0.36.0-alpha.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +19 -0
- package/dist/cli.cjs +2 -2
- package/dist/cli.js +2 -2
- package/dist/tui/commands/settings.d.ts.map +1 -1
- package/dist/tui/components/settings.d.ts +5 -1
- package/dist/tui/components/settings.d.ts.map +1 -1
- package/dist/tui/event-dispatch.d.ts.map +1 -1
- package/dist/{tui-Cn3hmvHg.js → tui-5ivxiFIl.js} +46 -2
- package/dist/tui-5ivxiFIl.js.map +1 -0
- package/dist/{tui-DPNQNK2b.cjs → tui-JjrLDEgc.cjs} +46 -2
- package/dist/tui-JjrLDEgc.cjs.map +1 -0
- package/dist/tui.cjs +1 -1
- package/dist/tui.js +1 -1
- package/package.json +9 -9
- package/dist/tui-Cn3hmvHg.js.map +0 -1
- package/dist/tui-DPNQNK2b.cjs.map +0 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,24 @@
|
|
|
1
1
|
# mastracode
|
|
2
2
|
|
|
3
|
+
## 0.36.0-alpha.9
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- Updated dependencies [[`eb9ecaa`](https://github.com/mastra-ai/mastra/commit/eb9ecaa89c36e889749e3b825cfc507ce7f7980b), [`3e8727e`](https://github.com/mastra-ai/mastra/commit/3e8727e11ec1a5d733acedb5c872896394be18c1)]:
|
|
8
|
+
- @mastra/core@1.62.0-alpha.9
|
|
9
|
+
- @mastra/code-sdk@1.5.0-alpha.9
|
|
10
|
+
|
|
11
|
+
## 0.36.0-alpha.8
|
|
12
|
+
|
|
13
|
+
### Patch Changes
|
|
14
|
+
|
|
15
|
+
- Updated dependencies [[`aa3a85d`](https://github.com/mastra-ai/mastra/commit/aa3a85daf094c683bb97efdf4b6a696d2e474af5), [`d29d06f`](https://github.com/mastra-ai/mastra/commit/d29d06fe00bbd35b4571150ea04c59d2ed783c71), [`e6516df`](https://github.com/mastra-ai/mastra/commit/e6516dfcdae4f4ac0e7971d84359a81385ee602f), [`0b2a3d1`](https://github.com/mastra-ai/mastra/commit/0b2a3d1783875c5b97b7b36ab3d03d7360e0dde7), [`6bb5d71`](https://github.com/mastra-ai/mastra/commit/6bb5d7193fe9166b219f0fccae17db7a5ae86e65), [`57de7d6`](https://github.com/mastra-ai/mastra/commit/57de7d644ba7146edb4e9e6111ec4fa98c3a59e9), [`e8e299c`](https://github.com/mastra-ai/mastra/commit/e8e299cc6abdfc39947e2fec25803493015d3882), [`edfc548`](https://github.com/mastra-ai/mastra/commit/edfc548886bc7bae17b681f8b6b41a47eb32bcd2), [`a8a4871`](https://github.com/mastra-ai/mastra/commit/a8a4871215f51da95c47129602157ce5372f634a), [`c7d2ac2`](https://github.com/mastra-ai/mastra/commit/c7d2ac245e6e549f3ee8b6c019fd43fd352fb528), [`e6c3c14`](https://github.com/mastra-ai/mastra/commit/e6c3c14c27fe0b46137c9593b1ad81df1cb46d72), [`5165cdc`](https://github.com/mastra-ai/mastra/commit/5165cdcdcf50e144bb8113278535196cc9b07065), [`6bb5d71`](https://github.com/mastra-ai/mastra/commit/6bb5d7193fe9166b219f0fccae17db7a5ae86e65), [`bbd4486`](https://github.com/mastra-ai/mastra/commit/bbd4486b7296d6fd0de7177344f87fbbc0bb4fff), [`9c984f9`](https://github.com/mastra-ai/mastra/commit/9c984f9152c0ded45453f21cb1f517fe12f8beae), [`6bb5d71`](https://github.com/mastra-ai/mastra/commit/6bb5d7193fe9166b219f0fccae17db7a5ae86e65), [`9ee8120`](https://github.com/mastra-ai/mastra/commit/9ee8120ce17f76b9f617489e05a283353742690a), [`d975e92`](https://github.com/mastra-ai/mastra/commit/d975e924d4936f46c386bd3dee39c671720289f6), [`1cfa878`](https://github.com/mastra-ai/mastra/commit/1cfa8784d8da0dfaa0317e5048bc48b6084a5ea5), [`c118318`](https://github.com/mastra-ai/mastra/commit/c1183181c9804303db4b511c2e2648f8b714712b), [`fc07c64`](https://github.com/mastra-ai/mastra/commit/fc07c6465043e08e99193a6751a01c56ffc2e7a1), [`542dee2`](https://github.com/mastra-ai/mastra/commit/542dee254167f974ff8cbbbfc0ce10f9a2616a7b), [`8dcd635`](https://github.com/mastra-ai/mastra/commit/8dcd6357f0d9557cebc727d7abc6901af6231e4f), [`a58483c`](https://github.com/mastra-ai/mastra/commit/a58483cff1a9d41fce7c931843f48cb0ac450f64), [`a58483c`](https://github.com/mastra-ai/mastra/commit/a58483cff1a9d41fce7c931843f48cb0ac450f64), [`895e9df`](https://github.com/mastra-ai/mastra/commit/895e9dfc17d6f34299eca64e317ded9e5f5e5ef8)]:
|
|
16
|
+
- @mastra/core@1.62.0-alpha.8
|
|
17
|
+
- @mastra/libsql@1.22.0-alpha.2
|
|
18
|
+
- @mastra/pg@1.22.0-alpha.4
|
|
19
|
+
- @mastra/memory@1.28.0-alpha.3
|
|
20
|
+
- @mastra/code-sdk@1.5.0-alpha.8
|
|
21
|
+
|
|
3
22
|
## 0.36.0-alpha.7
|
|
4
23
|
|
|
5
24
|
### Patch Changes
|
package/dist/cli.cjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
const require_tui = require("./tui-
|
|
2
|
+
const require_tui = require("./tui-JjrLDEgc.cjs");
|
|
3
3
|
let _mastra_code_sdk = require("@mastra/code-sdk");
|
|
4
4
|
let fs = require("fs");
|
|
5
5
|
fs = require_tui.__toESM(fs, 1);
|
|
@@ -33,7 +33,7 @@ function createShutdownCoordinator(cleanup, exit, timeoutMs = 5e3) {
|
|
|
33
33
|
//#endregion
|
|
34
34
|
//#region src/version.ts
|
|
35
35
|
function getCurrentVersion() {
|
|
36
|
-
return "0.36.0-alpha.
|
|
36
|
+
return "0.36.0-alpha.9";
|
|
37
37
|
}
|
|
38
38
|
//#endregion
|
|
39
39
|
//#region src/main.ts
|
package/dist/cli.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import { d as detectTerminalTheme, f as applyThemeMode, t as MastraTUI, v as restoreTerminalForeground } from "./tui-
|
|
2
|
+
import { d as detectTerminalTheme, f as applyThemeMode, t as MastraTUI, v as restoreTerminalForeground } from "./tui-5ivxiFIl.js";
|
|
3
3
|
import { createMastraCode } from "@mastra/code-sdk";
|
|
4
4
|
import fs from "fs";
|
|
5
5
|
import { createMastraCodeAnalytics } from "@mastra/code-sdk/analytics";
|
|
@@ -32,7 +32,7 @@ function createShutdownCoordinator(cleanup, exit, timeoutMs = 5e3) {
|
|
|
32
32
|
//#endregion
|
|
33
33
|
//#region src/version.ts
|
|
34
34
|
function getCurrentVersion() {
|
|
35
|
-
return "0.36.0-alpha.
|
|
35
|
+
return "0.36.0-alpha.9";
|
|
36
36
|
}
|
|
37
37
|
//#endregion
|
|
38
38
|
//#region src/main.ts
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"settings.d.ts","sourceRoot":"","sources":["../../../src/tui/commands/settings.ts"],"names":[],"mappings":"AAeA,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,YAAY,CAAC;AAgLtD,wBAAsB,qBAAqB,CAAC,GAAG,EAAE,mBAAmB,GAAG,OAAO,CAAC,IAAI,CAAC,
|
|
1
|
+
{"version":3,"file":"settings.d.ts","sourceRoot":"","sources":["../../../src/tui/commands/settings.ts"],"names":[],"mappings":"AAeA,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,YAAY,CAAC;AAgLtD,wBAAsB,qBAAqB,CAAC,GAAG,EAAE,mBAAmB,GAAG,OAAO,CAAC,IAAI,CAAC,CA6GnF"}
|
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
*/
|
|
8
8
|
import { Box } from '@earendil-works/pi-tui';
|
|
9
9
|
import type { Focusable } from '@earendil-works/pi-tui';
|
|
10
|
-
import type { StorageBackend } from '@mastra/code-sdk/onboarding/settings';
|
|
10
|
+
import type { StorageBackend, WebSearchProviderSetting } from '@mastra/code-sdk/onboarding/settings';
|
|
11
11
|
import type { NotificationMode } from '../notify.js';
|
|
12
12
|
export interface SettingsConfig {
|
|
13
13
|
notifications: NotificationMode;
|
|
@@ -21,6 +21,9 @@ export interface SettingsConfig {
|
|
|
21
21
|
pgConnectionString: string;
|
|
22
22
|
libsqlUrl: string;
|
|
23
23
|
experimentalGithubSignals: boolean;
|
|
24
|
+
webSearchProvider: WebSearchProviderSetting;
|
|
25
|
+
tavilyKeyAvailable: boolean;
|
|
26
|
+
parallelKeyAvailable: boolean;
|
|
24
27
|
}
|
|
25
28
|
export interface SettingsCallbacks {
|
|
26
29
|
onNotificationsChange: (mode: NotificationMode) => void;
|
|
@@ -31,6 +34,7 @@ export interface SettingsCallbacks {
|
|
|
31
34
|
onQuietModeMaxToolPreviewLinesChange: (lines: number) => void;
|
|
32
35
|
onStorageBackendChange: (backend: StorageBackend, connectionUrl?: string) => void;
|
|
33
36
|
onExperimentalGithubSignalsChange: (enabled: boolean) => boolean | void | Promise<boolean | void>;
|
|
37
|
+
onWebSearchProviderChange: (provider: WebSearchProviderSetting) => void;
|
|
34
38
|
onApiKeys?: () => void;
|
|
35
39
|
onClose: () => void;
|
|
36
40
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"settings.d.ts","sourceRoot":"","sources":["../../../src/tui/components/settings.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EAAE,GAAG,EAAiE,MAAM,wBAAwB,CAAC;AAC5G,OAAO,KAAK,EAAE,SAAS,EAA2B,MAAM,wBAAwB,CAAC;AACjF,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,sCAAsC,CAAC;
|
|
1
|
+
{"version":3,"file":"settings.d.ts","sourceRoot":"","sources":["../../../src/tui/components/settings.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EAAE,GAAG,EAAiE,MAAM,wBAAwB,CAAC;AAC5G,OAAO,KAAK,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O,GAAG,IAAI,CAAC,CAAC;IAClG,yBAAyB,EAAE,CAAC,QAAQ,EAAE,wBAAwB,KAAK,IAAI,CAAC;IACxE,SAAS,CAAC,EAAE,MAAM,IAAI,CAAC;IACvB,OAAO,EAAE,MAAM,IAAI,CAAC;CACrB;AAmKD,qBAAa,iBAAkB,SAAQ,GAAI,YAAW,SAAS;IAC7D,OAAO,CAAC,YAAY,CAAe;IACnC,OAAO,CAAC,QAAQ,CAAS;IAEzB,IAAI,OAAO,IAAI,OAAO,CAErB;IACD,IAAI,OAAO,CAAC,KAAK,EAAE,OAAO,EAEzB;gBAEW,MAAM,EAAE,cAAc,EAAE,SAAS,EAAE,iBAAiB;IAiThE,WAAW,CAAC,IAAI,EAAE,MAAM,GAAG,IAAI;CAGhC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"event-dispatch.d.ts","sourceRoot":"","sources":["../../src/tui/event-dispatch.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,oBAAoB,EAAyB,MAAM,+BAA+B,CAAC;AA0CjG,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,qBAAqB,CAAC;AAE/D,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AAc3C,wBAAsB,aAAa,CACjC,KAAK,EAAE,oBAAoB,EAC3B,IAAI,EAAE,mBAAmB,EACzB,KAAK,EAAE,QAAQ,GACd,OAAO,CAAC,IAAI,CAAC,
|
|
1
|
+
{"version":3,"file":"event-dispatch.d.ts","sourceRoot":"","sources":["../../src/tui/event-dispatch.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,oBAAoB,EAAyB,MAAM,+BAA+B,CAAC;AA0CjG,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,qBAAqB,CAAC;AAE/D,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AAc3C,wBAAsB,aAAa,CACjC,KAAK,EAAE,oBAAoB,EAC3B,IAAI,EAAE,mBAAmB,EACzB,KAAK,EAAE,QAAQ,GACd,OAAO,CAAC,IAAI,CAAC,CAgbf"}
|
|
@@ -14032,6 +14032,11 @@ var StorageBackendSubmenu = class extends Container {
|
|
|
14032
14032
|
function quietPreviewLinesLabel(lines) {
|
|
14033
14033
|
return lines === 0 ? "None" : `${lines} line${lines === 1 ? "" : "s"}`;
|
|
14034
14034
|
}
|
|
14035
|
+
function webSearchProviderLabel(provider) {
|
|
14036
|
+
if (provider === "tavily") return "Tavily";
|
|
14037
|
+
if (provider === "parallel") return "Parallel";
|
|
14038
|
+
return "Auto";
|
|
14039
|
+
}
|
|
14035
14040
|
function storageLabel(config) {
|
|
14036
14041
|
if (config.storageBackend === "pg") return "PostgreSQL";
|
|
14037
14042
|
if (config.libsqlUrl) return `LibSQL (${config.libsqlUrl})`;
|
|
@@ -14188,6 +14193,35 @@ var SettingsComponent = class extends Box {
|
|
|
14188
14193
|
done(quietPreviewLinesLabel(config.quietModeMaxToolPreviewLines));
|
|
14189
14194
|
}, () => done())
|
|
14190
14195
|
}] : [],
|
|
14196
|
+
{
|
|
14197
|
+
id: "webSearchProvider",
|
|
14198
|
+
label: "Web search provider",
|
|
14199
|
+
description: "Default provider for web_search/web_extract. Providers require their API key.",
|
|
14200
|
+
currentValue: webSearchProviderLabel(config.webSearchProvider),
|
|
14201
|
+
submenu: (_currentValue, done) => new SelectSubmenu([
|
|
14202
|
+
{
|
|
14203
|
+
value: "auto",
|
|
14204
|
+
label: " Auto",
|
|
14205
|
+
description: "First configured provider key (Tavily, then Parallel)"
|
|
14206
|
+
},
|
|
14207
|
+
{
|
|
14208
|
+
value: "tavily",
|
|
14209
|
+
label: config.tavilyKeyAvailable ? " Tavily" : " Tavily (unavailable)",
|
|
14210
|
+
description: config.tavilyKeyAvailable ? "Always use Tavily" : "Missing TAVILY_API_KEY — set it to use Tavily"
|
|
14211
|
+
},
|
|
14212
|
+
{
|
|
14213
|
+
value: "parallel",
|
|
14214
|
+
label: config.parallelKeyAvailable ? " Parallel" : " Parallel (unavailable)",
|
|
14215
|
+
description: config.parallelKeyAvailable ? "Always use Parallel" : "Missing PARALLEL_API_KEY — set it to use Parallel"
|
|
14216
|
+
}
|
|
14217
|
+
], config.webSearchProvider, (value) => {
|
|
14218
|
+
if (value === "tavily" && !config.tavilyKeyAvailable) return;
|
|
14219
|
+
if (value === "parallel" && !config.parallelKeyAvailable) return;
|
|
14220
|
+
config.webSearchProvider = value;
|
|
14221
|
+
callbacks.onWebSearchProviderChange(config.webSearchProvider);
|
|
14222
|
+
done(webSearchProviderLabel(config.webSearchProvider));
|
|
14223
|
+
}, () => done())
|
|
14224
|
+
},
|
|
14191
14225
|
{
|
|
14192
14226
|
id: "experimentalGithubSignals",
|
|
14193
14227
|
label: "Experimental GitHub signals",
|
|
@@ -14551,7 +14585,10 @@ async function handleSettingsCommand(ctx) {
|
|
|
14551
14585
|
storageBackend: globalSettings.storage.backend,
|
|
14552
14586
|
pgConnectionString: globalSettings.storage.pg?.connectionString ?? "",
|
|
14553
14587
|
libsqlUrl: globalSettings.storage.libsql?.url ?? "",
|
|
14554
|
-
experimentalGithubSignals: globalSettings.signals.experimentalGithubSignals
|
|
14588
|
+
experimentalGithubSignals: globalSettings.signals.experimentalGithubSignals,
|
|
14589
|
+
webSearchProvider: globalSettings.preferences.webSearchProvider === "tavily" && !process.env.TAVILY_API_KEY || globalSettings.preferences.webSearchProvider === "parallel" && !process.env.PARALLEL_API_KEY ? "auto" : globalSettings.preferences.webSearchProvider,
|
|
14590
|
+
tavilyKeyAvailable: !!process.env.TAVILY_API_KEY,
|
|
14591
|
+
parallelKeyAvailable: !!process.env.PARALLEL_API_KEY
|
|
14555
14592
|
};
|
|
14556
14593
|
return new Promise((resolve) => {
|
|
14557
14594
|
const settings = new SettingsComponent(config, {
|
|
@@ -14617,6 +14654,12 @@ async function handleSettingsCommand(ctx) {
|
|
|
14617
14654
|
ctx.showInfo(`Experimental GitHub signals: ${enabled ? "on" : "off"} (restart required)`);
|
|
14618
14655
|
return true;
|
|
14619
14656
|
},
|
|
14657
|
+
onWebSearchProviderChange: (provider) => {
|
|
14658
|
+
const current = loadSettings();
|
|
14659
|
+
current.preferences.webSearchProvider = provider;
|
|
14660
|
+
saveSettings(current);
|
|
14661
|
+
ctx.showInfo(`Web search provider: ${provider}`);
|
|
14662
|
+
},
|
|
14620
14663
|
onApiKeys: () => {
|
|
14621
14664
|
ctx.state.ui.hideOverlay();
|
|
14622
14665
|
resolve();
|
|
@@ -21018,6 +21061,7 @@ async function dispatchEvent(event, ectx, state) {
|
|
|
21018
21061
|
break;
|
|
21019
21062
|
}
|
|
21020
21063
|
case "om_thread_title_updated":
|
|
21064
|
+
if (event.threadId !== state.session.thread.getId()) break;
|
|
21021
21065
|
state.currentThreadTitle = event.newTitle;
|
|
21022
21066
|
handleOMThreadTitleUpdated(ectx, event.newTitle, event.oldTitle);
|
|
21023
21067
|
ectx.updateStatusLine();
|
|
@@ -23915,4 +23959,4 @@ var MastraTUI = class MastraTUI {
|
|
|
23915
23959
|
//#endregion
|
|
23916
23960
|
export { mastraBrand as _, OMProgressComponent as a, ToolExecutionComponentEnhanced as c, detectTerminalTheme as d, applyThemeMode as f, mastra as g, getThemeMode as h, LoginDialogComponent as i, ModelSelectorComponent as l, getMarkdownTheme as m, createTUIState as n, formatOMStatus as o, getEditorTheme as p, LoginSelectorComponent as r, UserMessageComponent as s, MastraTUI as t, AssistantMessageComponent as u, restoreTerminalForeground as v, theme as y };
|
|
23917
23961
|
|
|
23918
|
-
//# sourceMappingURL=tui-
|
|
23962
|
+
//# sourceMappingURL=tui-5ivxiFIl.js.map
|