@mastra/code-sdk 1.1.0-alpha.4 → 1.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +42 -0
- package/package.json +12 -12
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,47 @@
|
|
|
1
1
|
# @mastra/code-sdk
|
|
2
2
|
|
|
3
|
+
## 1.1.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- Added `resolveProviderOMDefault` to `@mastra/code-sdk/onboarding/packs`, which returns the small, cheap observational memory model for a provider, or the model you pass in when that provider has none. ([#20298](https://github.com/mastra-ai/mastra/pull/20298))
|
|
8
|
+
|
|
9
|
+
The built-in OM packs are now a single table, so the list offered during onboarding and the per-provider default can no longer drift apart.
|
|
10
|
+
|
|
11
|
+
```ts
|
|
12
|
+
import { resolveProviderOMDefault } from '@mastra/code-sdk/onboarding/packs';
|
|
13
|
+
|
|
14
|
+
resolveProviderOMDefault('anthropic').modelId; // 'anthropic/claude-haiku-4-5'
|
|
15
|
+
resolveProviderOMDefault('openai-codex').modelId; // 'openai/gpt-5.4-mini'
|
|
16
|
+
resolveProviderOMDefault('xai', 'xai/grok-4.5').modelId; // 'xai/grok-4.5'
|
|
17
|
+
```
|
|
18
|
+
|
|
19
|
+
- Added provider-aware observational memory defaults, so a controller started without a stored OM choice observes and reflects with the cheap model of a provider you can actually reach instead of the built-in Gemini default. ([#20291](https://github.com/mastra-ai/mastra/pull/20291))
|
|
20
|
+
|
|
21
|
+
The helpers behind it are exported if you build your own surface on the SDK:
|
|
22
|
+
|
|
23
|
+
```ts
|
|
24
|
+
import { hasExplicitOMConfiguration } from '@mastra/code-sdk/onboarding/om-settings';
|
|
25
|
+
import { selectPreferredOMPack } from '@mastra/code-sdk/onboarding/packs';
|
|
26
|
+
|
|
27
|
+
// Best OM pack across everything the user can reach, preferring a given provider
|
|
28
|
+
selectPreferredOMPack({ anthropic: 'oauth', google: 'apikey' }, 'anthropic')?.modelId;
|
|
29
|
+
|
|
30
|
+
// True once the user picked an OM model or pack themselves — never seed over it
|
|
31
|
+
hasExplicitOMConfiguration(settings);
|
|
32
|
+
```
|
|
33
|
+
|
|
34
|
+
### Patch Changes
|
|
35
|
+
|
|
36
|
+
- Updated dependencies [[`ce93a3c`](https://github.com/mastra-ai/mastra/commit/ce93a3c114ea1cbfbd576f3db41d7c26c9844f5b), [`5718a22`](https://github.com/mastra-ai/mastra/commit/5718a229281dcfd36bcd1f42a242e3717e510a33), [`a211d09`](https://github.com/mastra-ai/mastra/commit/a211d09185dc65a746534914cf38b67f21ee9bac), [`0dca9d0`](https://github.com/mastra-ai/mastra/commit/0dca9d0b1356024a53b72ea6f040db528b126caa), [`6218217`](https://github.com/mastra-ai/mastra/commit/62182171b6cfca0b099f1c6a77a2e65e7639ab86), [`5807d3a`](https://github.com/mastra-ai/mastra/commit/5807d3ae1d259b8b7d6df7e5bf2b485c694af9c8), [`57661af`](https://github.com/mastra-ai/mastra/commit/57661afeca52ff9af4e72675ede2134fa503d5a5), [`05db566`](https://github.com/mastra-ai/mastra/commit/05db566fcbdcbf33d0bffca0c72ec30129e2e3ca), [`57661af`](https://github.com/mastra-ai/mastra/commit/57661afeca52ff9af4e72675ede2134fa503d5a5), [`273bb71`](https://github.com/mastra-ai/mastra/commit/273bb71e82e74b656f3906288239429899398c0c), [`57661af`](https://github.com/mastra-ai/mastra/commit/57661afeca52ff9af4e72675ede2134fa503d5a5), [`05db566`](https://github.com/mastra-ai/mastra/commit/05db566fcbdcbf33d0bffca0c72ec30129e2e3ca), [`57661af`](https://github.com/mastra-ai/mastra/commit/57661afeca52ff9af4e72675ede2134fa503d5a5), [`5718a22`](https://github.com/mastra-ai/mastra/commit/5718a229281dcfd36bcd1f42a242e3717e510a33), [`57661af`](https://github.com/mastra-ai/mastra/commit/57661afeca52ff9af4e72675ede2134fa503d5a5), [`d1b7e3a`](https://github.com/mastra-ai/mastra/commit/d1b7e3a978a309a5653eeaa490d2d6c7c53bd093), [`29c584a`](https://github.com/mastra-ai/mastra/commit/29c584a13a88831e5ed1fdeb0ff8e82eae180433), [`c093146`](https://github.com/mastra-ai/mastra/commit/c0931466404d3c521308ea119cb165bb7e695155), [`e075db9`](https://github.com/mastra-ai/mastra/commit/e075db9715c836bae5dfc37c50248492af397c3b), [`8124754`](https://github.com/mastra-ai/mastra/commit/8124754ae89fbc69f8136d1df4a91904d0f84c4e), [`d12b2e4`](https://github.com/mastra-ai/mastra/commit/d12b2e4023fd9e3d3e93a9169f5088bcee2a849c), [`d1b7e3a`](https://github.com/mastra-ai/mastra/commit/d1b7e3a978a309a5653eeaa490d2d6c7c53bd093)]:
|
|
37
|
+
- @mastra/core@1.54.0
|
|
38
|
+
- @mastra/libsql@1.18.0
|
|
39
|
+
- @mastra/memory@1.24.0
|
|
40
|
+
- @mastra/pg@1.18.0
|
|
41
|
+
- @mastra/duckdb@1.5.2
|
|
42
|
+
- @mastra/observability@1.16.3
|
|
43
|
+
- @mastra/mcp@1.15.0
|
|
44
|
+
|
|
3
45
|
## 1.1.0-alpha.4
|
|
4
46
|
|
|
5
47
|
### Patch Changes
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mastra/code-sdk",
|
|
3
|
-
"version": "1.1.0
|
|
3
|
+
"version": "1.1.0",
|
|
4
4
|
"description": "Mastra Code SDK: the agent core behind Mastra Code (everything except the TUI) — build your own UIs and surfaces on top of it",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"publishConfig": {
|
|
@@ -56,19 +56,19 @@
|
|
|
56
56
|
"vscode-languageserver-protocol": "^3.17.5",
|
|
57
57
|
"yaml": "^2.7.1",
|
|
58
58
|
"zod": "^4.3.6",
|
|
59
|
-
"@mastra/core": "1.54.0-alpha.4",
|
|
60
|
-
"@mastra/duckdb": "1.5.2-alpha.0",
|
|
61
59
|
"@mastra/agent-browser": "0.4.1",
|
|
62
|
-
"@mastra/
|
|
60
|
+
"@mastra/core": "1.54.0",
|
|
63
61
|
"@mastra/github-signals": "0.2.2",
|
|
64
|
-
"@mastra/
|
|
65
|
-
"@mastra/
|
|
66
|
-
"@mastra/pg": "1.18.0-alpha.2",
|
|
62
|
+
"@mastra/libsql": "1.18.0",
|
|
63
|
+
"@mastra/memory": "1.24.0",
|
|
67
64
|
"@mastra/mcp": "1.15.0",
|
|
68
|
-
"@mastra/observability": "1.16.3
|
|
65
|
+
"@mastra/observability": "1.16.3",
|
|
66
|
+
"@mastra/duckdb": "1.5.2",
|
|
67
|
+
"@mastra/pg": "1.18.0",
|
|
68
|
+
"@mastra/fastembed": "1.2.0",
|
|
69
|
+
"@mastra/tavily": "1.1.1",
|
|
69
70
|
"@mastra/schema-compat": "1.3.4",
|
|
70
|
-
"@mastra/stagehand": "0.3.1"
|
|
71
|
-
"@mastra/tavily": "1.1.1"
|
|
71
|
+
"@mastra/stagehand": "0.3.1"
|
|
72
72
|
},
|
|
73
73
|
"devDependencies": {
|
|
74
74
|
"@libsql/client": "^0.17.4",
|
|
@@ -79,8 +79,8 @@
|
|
|
79
79
|
"typescript": "^6.0.3",
|
|
80
80
|
"typescript-eslint": "^8.57.0",
|
|
81
81
|
"vitest": "4.1.10",
|
|
82
|
-
"@internal/lint": "0.0.
|
|
83
|
-
"@internal/types-builder": "0.0.
|
|
82
|
+
"@internal/lint": "0.0.118",
|
|
83
|
+
"@internal/types-builder": "0.0.93"
|
|
84
84
|
},
|
|
85
85
|
"engines": {
|
|
86
86
|
"node": ">=22.19.0"
|