@mastra/mcp-docs-server 1.0.2-alpha.2 → 1.0.2

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 (36) hide show
  1. package/.docs/organized/changelogs/%40internal%2Fchangeset-cli.md +3 -1
  2. package/.docs/organized/changelogs/%40internal%2Fexternal-types.md +3 -1
  3. package/.docs/organized/changelogs/%40internal%2Fplayground.md +14 -0
  4. package/.docs/organized/changelogs/%40internal%2Fstorage-test-utils.md +8 -8
  5. package/.docs/organized/changelogs/%40internal%2Ftypes-builder.md +3 -1
  6. package/.docs/organized/changelogs/%40mastra%2Fagent-builder.md +13 -13
  7. package/.docs/organized/changelogs/%40mastra%2Fai-sdk.md +14 -14
  8. package/.docs/organized/changelogs/%40mastra%2Fclickhouse.md +78 -78
  9. package/.docs/organized/changelogs/%40mastra%2Fclient-js.md +148 -148
  10. package/.docs/organized/changelogs/%40mastra%2Fcloudflare.md +76 -76
  11. package/.docs/organized/changelogs/%40mastra%2Fcodemod.md +41 -0
  12. package/.docs/organized/changelogs/%40mastra%2Fconvex.md +10 -10
  13. package/.docs/organized/changelogs/%40mastra%2Fcore.md +103 -103
  14. package/.docs/organized/changelogs/%40mastra%2Fdeployer-cloud.md +10 -10
  15. package/.docs/organized/changelogs/%40mastra%2Fdeployer-cloudflare.md +17 -17
  16. package/.docs/organized/changelogs/%40mastra%2Fdeployer-netlify.md +9 -9
  17. package/.docs/organized/changelogs/%40mastra%2Fdeployer-vercel.md +9 -9
  18. package/.docs/organized/changelogs/%40mastra%2Fdeployer.md +98 -98
  19. package/.docs/organized/changelogs/%40mastra%2Fevals.md +11 -11
  20. package/.docs/organized/changelogs/%40mastra%2Flibsql.md +98 -98
  21. package/.docs/organized/changelogs/%40mastra%2Floggers.md +10 -10
  22. package/.docs/organized/changelogs/%40mastra%2Fmcp-docs-server.md +8 -8
  23. package/.docs/organized/changelogs/%40mastra%2Fmemory.md +25 -25
  24. package/.docs/organized/changelogs/%40mastra%2Fmongodb.md +94 -94
  25. package/.docs/organized/changelogs/%40mastra%2Fmssql.md +12 -12
  26. package/.docs/organized/changelogs/%40mastra%2Fpg.md +98 -98
  27. package/.docs/organized/changelogs/%40mastra%2Fplayground-ui.md +184 -184
  28. package/.docs/organized/changelogs/%40mastra%2Frag.md +70 -70
  29. package/.docs/organized/changelogs/%40mastra%2Freact.md +34 -34
  30. package/.docs/organized/changelogs/%40mastra%2Fserver.md +186 -186
  31. package/.docs/organized/changelogs/%40mastra%2Fvoice-google-gemini-live.md +9 -0
  32. package/.docs/organized/changelogs/%40mastra%2Fvoice-openai-realtime.md +10 -10
  33. package/.docs/organized/changelogs/create-mastra.md +7 -7
  34. package/.docs/organized/changelogs/mastra.md +101 -101
  35. package/CHANGELOG.md +7 -0
  36. package/package.json +5 -5
@@ -1,5 +1,188 @@
1
1
  # @mastra/playground-ui
2
2
 
3
+ ## 8.0.0
4
+
5
+ ### Minor Changes
6
+
7
+ - Moved model provider and model selection dropdowns from the agent side panel to the chat composer area for easier access during conversations ([#12407](https://github.com/mastra-ai/mastra/pull/12407))
8
+
9
+ - Refactored Combobox component to use @base-ui/react instead of custom Radix UI Popover implementation. This removes ~70 lines of manual keyboard navigation code while preserving the same props interface and styling. ([#12377](https://github.com/mastra-ai/mastra/pull/12377))
10
+
11
+ - Added dynamic agent management with CRUD operations and version tracking ([#12038](https://github.com/mastra-ai/mastra/pull/12038))
12
+
13
+ **New Features:**
14
+ - Create, edit, and delete agents directly from the Mastra Studio UI
15
+ - Full version history for agents with compare and restore capabilities
16
+ - Visual diff viewer to compare agent configurations across versions
17
+ - Agent creation modal with comprehensive configuration options (model selection, instructions, tools, workflows, sub-agents, memory)
18
+ - AI-powered instruction enhancement
19
+
20
+ **Storage:**
21
+ - New storage interfaces for stored agents and agent versions
22
+ - PostgreSQL, LibSQL, and MongoDB implementations included
23
+ - In-memory storage for development and testing
24
+
25
+ **API:**
26
+ - RESTful endpoints for agent CRUD operations
27
+ - Version management endpoints (create, list, activate, restore, delete, compare)
28
+ - Automatic versioning on agent updates when enabled
29
+
30
+ **Client SDK:**
31
+ - JavaScript client with full support for stored agents and versions
32
+ - Type-safe methods for all CRUD and version operations
33
+
34
+ **Usage Example:**
35
+
36
+ ```typescript
37
+ // Server-side: Configure storage
38
+ import { Mastra } from '@mastra/core';
39
+ import { PgAgentsStorage } from '@mastra/pg';
40
+
41
+ const mastra = new Mastra({
42
+ agents: { agentOne },
43
+ storage: {
44
+ agents: new PgAgentsStorage({
45
+ connectionString: process.env.DATABASE_URL,
46
+ }),
47
+ },
48
+ });
49
+
50
+ // Client-side: Use the SDK
51
+ import { MastraClient } from '@mastra/client-js';
52
+
53
+ const client = new MastraClient({ baseUrl: 'http://localhost:3000' });
54
+
55
+ // Create a stored agent
56
+ const agent = await client.createStoredAgent({
57
+ name: 'Customer Support Agent',
58
+ description: 'Handles customer inquiries',
59
+ model: { provider: 'ANTHROPIC', name: 'claude-sonnet-4-5' },
60
+ instructions: 'You are a helpful customer support agent...',
61
+ tools: ['search', 'email'],
62
+ });
63
+
64
+ // Create a version snapshot
65
+ await client.storedAgent(agent.id).createVersion({
66
+ name: 'v1.0 - Initial release',
67
+ changeMessage: 'First production version',
68
+ });
69
+
70
+ // Compare versions
71
+ const diff = await client.storedAgent(agent.id).compareVersions('version-1', 'version-2');
72
+ ```
73
+
74
+ **Why:**
75
+ This feature enables teams to manage agents dynamically without code changes, making it easier to iterate on agent configurations and maintain a complete audit trail of changes.
76
+
77
+ - Added Command component (CMDK) with CommandDialog, CommandInput, CommandList, CommandEmpty, CommandGroup, CommandItem, CommandSeparator, and CommandShortcut subcomponents for building command palettes and searchable menus ([#12360](https://github.com/mastra-ai/mastra/pull/12360))
78
+
79
+ - Bump playground-ui to v7.1.0 ([#12186](https://github.com/mastra-ai/mastra/pull/12186))
80
+
81
+ - Added keyboard navigation support to Table component with new `useTableKeyboardNavigation` hook and `isActive` prop on Row ([#12352](https://github.com/mastra-ai/mastra/pull/12352))
82
+
83
+ - Added global command palette (Cmd+K) for quick navigation to any entity in Mastra Studio. Press Cmd+K (or Ctrl+K on Windows/Linux) to search and navigate to agents, workflows, tools, scorers, processors, and MCP servers. ([#12360](https://github.com/mastra-ai/mastra/pull/12360))
84
+
85
+ - Improved command palette with sidebar toggle, direct links to agent/workflow traces, and preserved search result ordering ([#12406](https://github.com/mastra-ai/mastra/pull/12406))
86
+
87
+ - Added workspace UI components for the Mastra playground. ([#11986](https://github.com/mastra-ai/mastra/pull/11986))
88
+
89
+ **New components:**
90
+ - `FileBrowser` - Browse and manage workspace files with breadcrumb navigation
91
+ - `FileViewer` - View file contents with syntax highlighting
92
+ - `SkillsTable` - List and search available skills
93
+ - `SkillDetail` - View skill details, instructions, and references
94
+ - `SearchPanel` - Search workspace content with BM25/vector/hybrid modes
95
+ - `ReferenceViewerDialog` - View skill reference file contents
96
+
97
+ **Usage:**
98
+
99
+ ```tsx
100
+ import { FileBrowser, FileViewer, SkillsTable } from '@mastra/playground-ui';
101
+
102
+ // File browser with navigation
103
+ <FileBrowser
104
+ entries={files}
105
+ currentPath="/docs"
106
+ onNavigate={setPath}
107
+ onFileSelect={handleFileSelect}
108
+ />
109
+
110
+ // Skills table with search
111
+ <SkillsTable
112
+ skills={skills}
113
+ onSkillSelect={handleSkillSelect}
114
+ />
115
+ ```
116
+
117
+ - Developers can now configure a custom API route prefix in the Studio UI, enabling Studio to work with servers using custom base paths (e.g., `/mastra` instead of the default `/api`). See #12261 for more details. ([#12295](https://github.com/mastra-ai/mastra/pull/12295))
118
+
119
+ ### Patch Changes
120
+
121
+ - Fix link to evals documentation ([#12122](https://github.com/mastra-ai/mastra/pull/12122))
122
+
123
+ - Added ghost variant support to domain comboboxes (AgentCombobox, WorkflowCombobox, MCPServerCombobox, ScorerCombobox, ToolCombobox) and moved them into the breadcrumb for a cleaner navigation pattern ([#12357](https://github.com/mastra-ai/mastra/pull/12357))
124
+
125
+ - Added processor combobox to processor page header for quick navigation between processors ([#12368](https://github.com/mastra-ai/mastra/pull/12368))
126
+
127
+ - Restructured stored agents to use a thin metadata record with versioned configuration snapshots. ([#12488](https://github.com/mastra-ai/mastra/pull/12488))
128
+
129
+ The agent record now only stores metadata fields (id, status, activeVersionId, authorId, metadata, timestamps). All configuration fields (name, instructions, model, tools, etc.) live exclusively in version snapshot rows, enabling full version history and rollback.
130
+
131
+ **Key changes:**
132
+ - Stored Agent records are now thin metadata-only (StorageAgentType)
133
+ - All config lives in version snapshots (StorageAgentSnapshotType)
134
+ - New resolved type (StorageResolvedAgentType) merges agent record + active version config
135
+ - Renamed `ownerId` to `authorId` for multi-tenant filtering
136
+ - Changed `memory` field type from `string` to `Record<string, unknown>`
137
+ - Added `status` field ('draft' | 'published') to agent records
138
+ - Flattened CreateAgent/UpdateAgent input types (config fields at top level, no nested snapshot)
139
+ - Version config columns are top-level in the agent_versions table (no single snapshot jsonb column)
140
+ - List endpoints return resolved agents (thin record + active version config)
141
+ - Auto-versioning on update with retention limits and race condition handling
142
+
143
+ - Added Request Context tab to Tools, Agents, and Workflows in Mastra Studio. When an entity defines a requestContextSchema, a form is displayed allowing you to input context values before execution. ([#12259](https://github.com/mastra-ai/mastra/pull/12259))
144
+
145
+ - Fixed keyboard events in command palette propagating to underlying page elements like tables ([#12458](https://github.com/mastra-ai/mastra/pull/12458))
146
+
147
+ - fix workflow run input caching bug in studio UI ([#11784](https://github.com/mastra-ai/mastra/pull/11784))
148
+
149
+ - Refactored agent model dropdowns to use the Combobox design system component, reducing code complexity while preserving all features including custom model ID support and provider connection status indicators. ([#12367](https://github.com/mastra-ai/mastra/pull/12367))
150
+
151
+ - Fixed model combobox auto-opening on mount. The model selector now only opens when explicitly changing providers, improving the initial page load experience. ([#12456](https://github.com/mastra-ai/mastra/pull/12456))
152
+
153
+ - Fixed legacy agent runs so each request now gets a unique run ID, improving trace readability in observability tools. ([#12229](https://github.com/mastra-ai/mastra/pull/12229))
154
+
155
+ - Improved skill activation styling with cleaner badge appearance and dark-themed tooltip on hover. ([#12487](https://github.com/mastra-ai/mastra/pull/12487))
156
+
157
+ - Added workflow run ID to breadcrumbs with truncation and copy functionality ([#12409](https://github.com/mastra-ai/mastra/pull/12409))
158
+
159
+ - Refactored WorkflowTrigger component into focused sub-components for better maintainability. Extracted WorkflowTriggerForm, WorkflowSuspendedSteps, WorkflowCancelButton, and WorkflowStepsStatus. Added useSuspendedSteps and useWorkflowSchemas hooks for memoized computations. No changes to public API. ([#12349](https://github.com/mastra-ai/mastra/pull/12349))
160
+
161
+ - Use useExecuteWorkflow hook from @mastra/react instead of local implementation in playground-ui ([#12138](https://github.com/mastra-ai/mastra/pull/12138))
162
+
163
+ - Refined color palette for a more polished dark theme. Surfaces now use warm near-blacks, accents are softer and less neon, borders are subtle white overlays for a modern look. ([#12350](https://github.com/mastra-ai/mastra/pull/12350))
164
+
165
+ - Added useCancelWorkflowRun hook to @mastra/react for canceling workflow runs. This hook was previously only available internally in playground-ui and is now exported for use in custom applications. ([#12142](https://github.com/mastra-ai/mastra/pull/12142))
166
+
167
+ - Fixed skill detail page crashing when skills have object-typed compatibility or metadata fields. Skills from skills.sh and other external sources now display correctly. ([#12491](https://github.com/mastra-ai/mastra/pull/12491))
168
+
169
+ - Remove hardcoded temperature: 0.5 and topP: 1 defaults from playground agent settings ([#12256](https://github.com/mastra-ai/mastra/pull/12256))
170
+ Let agent config and provider defaults handle these values instead
171
+
172
+ - Added useStreamWorkflow hook to @mastra/react for streaming workflow execution. This hook supports streaming, observing, resuming, and time-traveling workflows. It accepts tracingOptions and onError as parameters for better customization. ([#12151](https://github.com/mastra-ai/mastra/pull/12151))
173
+
174
+ - Added view transitions to internal sidebar navigation links for smoother page transitions ([#12358](https://github.com/mastra-ai/mastra/pull/12358))
175
+
176
+ - Added raw SKILL.md source view in skill detail page. The 'Source' toggle now shows the full file contents including YAML frontmatter. ([#12497](https://github.com/mastra-ai/mastra/pull/12497))
177
+
178
+ - Added IconButton design system component that combines button styling with built-in tooltip support. Replaced TooltipIconButton with IconButton throughout the chat interface for consistency. ([#12410](https://github.com/mastra-ai/mastra/pull/12410))
179
+
180
+ - Updated dependencies [[`90fc0e5`](https://github.com/mastra-ai/mastra/commit/90fc0e5717cb280c2d4acf4f0410b510bb4c0a72), [`1cf5d2e`](https://github.com/mastra-ai/mastra/commit/1cf5d2ea1b085be23e34fb506c80c80a4e6d9c2b), [`b99ceac`](https://github.com/mastra-ai/mastra/commit/b99ceace2c830dbdef47c8692d56a91954aefea2), [`deea43e`](https://github.com/mastra-ai/mastra/commit/deea43eb1366d03a864c5e597d16a48592b9893f), [`60d9d89`](https://github.com/mastra-ai/mastra/commit/60d9d899e44b35bc43f1bcd967a74e0ce010b1af), [`833ae96`](https://github.com/mastra-ai/mastra/commit/833ae96c3e34370e58a1e979571c41f39a720592), [`943772b`](https://github.com/mastra-ai/mastra/commit/943772b4378f625f0f4e19ea2b7c392bd8e71786), [`b5c711b`](https://github.com/mastra-ai/mastra/commit/b5c711b281dd1fb81a399a766bc9f86c55efc13e), [`0350626`](https://github.com/mastra-ai/mastra/commit/03506267ec41b67add80d994c0c0fcce93bbc75f), [`3efbe5a`](https://github.com/mastra-ai/mastra/commit/3efbe5ae20864c4f3143457f4f3ee7dc2fa5ca76), [`1e49e7a`](https://github.com/mastra-ai/mastra/commit/1e49e7ab5f173582154cb26b29d424de67d09aef), [`751eaab`](https://github.com/mastra-ai/mastra/commit/751eaab4e0d3820a94e4c3d39a2ff2663ded3d91), [`69d8156`](https://github.com/mastra-ai/mastra/commit/69d81568bcf062557c24471ce26812446bec465d), [`60d9d89`](https://github.com/mastra-ai/mastra/commit/60d9d899e44b35bc43f1bcd967a74e0ce010b1af), [`5c544c8`](https://github.com/mastra-ai/mastra/commit/5c544c8d12b08ab40d64d8f37b3c4215bee95b87), [`771ad96`](https://github.com/mastra-ai/mastra/commit/771ad962441996b5c43549391a3e6a02c6ddedc2), [`2b0936b`](https://github.com/mastra-ai/mastra/commit/2b0936b0c9a43eeed9bef63e614d7e02ee803f7e), [`3b04f30`](https://github.com/mastra-ai/mastra/commit/3b04f3010604f3cdfc8a0674731700ad66471cee), [`97e26de`](https://github.com/mastra-ai/mastra/commit/97e26deaebd9836647a67b96423281d66421ca07), [`ac9ec66`](https://github.com/mastra-ai/mastra/commit/ac9ec6672779b2e6d4344e415481d1a6a7d4911a), [`dc82e6c`](https://github.com/mastra-ai/mastra/commit/dc82e6c5a05d6a9160c522af08b8c809ddbcdb66), [`dc82e6c`](https://github.com/mastra-ai/mastra/commit/dc82e6c5a05d6a9160c522af08b8c809ddbcdb66), [`10523f4`](https://github.com/mastra-ai/mastra/commit/10523f4882d9b874b40ce6e3715f66dbcd4947d2), [`cb72d20`](https://github.com/mastra-ai/mastra/commit/cb72d2069d7339bda8a0e76d4f35615debb07b84), [`42856b1`](https://github.com/mastra-ai/mastra/commit/42856b1c8aeea6371c9ee77ae2f5f5fe34400933), [`70237c5`](https://github.com/mastra-ai/mastra/commit/70237c51e9e92332eb55d6e3c6dd7f1ea8435d26), [`66f33ff`](https://github.com/mastra-ai/mastra/commit/66f33ff68620018513e499c394411d1d39b3aa5c), [`910367c`](https://github.com/mastra-ai/mastra/commit/910367ce8f89905bd1d958ccfdf0ba1e713696aa), [`ab3c190`](https://github.com/mastra-ai/mastra/commit/ab3c1901980a99910ca9b96a7090c22e24060113), [`d4f06c8`](https://github.com/mastra-ai/mastra/commit/d4f06c85ffa5bb0da38fb82ebf3b040cc6b4ec4e), [`0caf854`](https://github.com/mastra-ai/mastra/commit/0caf854cdeea7bd524e5149de9df56e862be4bc9), [`1d70a4a`](https://github.com/mastra-ai/mastra/commit/1d70a4a6d53c3f2571544dc0767f2c5f4e445ba0), [`0350626`](https://github.com/mastra-ai/mastra/commit/03506267ec41b67add80d994c0c0fcce93bbc75f), [`a64a24c`](https://github.com/mastra-ai/mastra/commit/a64a24c9bce499b989667c7963f2f71a11d90334), [`bc9fa00`](https://github.com/mastra-ai/mastra/commit/bc9fa00859c5c4a796d53a0a5cae46ab4a3072e4), [`f46a478`](https://github.com/mastra-ai/mastra/commit/f46a4782f595949c696569e891f81c8d26338508), [`90fc0e5`](https://github.com/mastra-ai/mastra/commit/90fc0e5717cb280c2d4acf4f0410b510bb4c0a72), [`f05a3a5`](https://github.com/mastra-ai/mastra/commit/f05a3a5cf2b9a9c2d40c09cb8c762a4b6cd5d565), [`a64a24c`](https://github.com/mastra-ai/mastra/commit/a64a24c9bce499b989667c7963f2f71a11d90334), [`a291da9`](https://github.com/mastra-ai/mastra/commit/a291da9363efd92dafd8775dccb4f2d0511ece7a), [`c5d71da`](https://github.com/mastra-ai/mastra/commit/c5d71da1c680ce5640b1a7f8ca0e024a4ab1cfed), [`07042f9`](https://github.com/mastra-ai/mastra/commit/07042f9f89080f38b8f72713ba1c972d5b1905b8), [`0423442`](https://github.com/mastra-ai/mastra/commit/0423442b7be2dfacba95890bea8f4a810db4d603)]:
181
+ - @mastra/core@1.1.0
182
+ - @mastra/client-js@1.1.0
183
+ - @mastra/react@0.2.0
184
+ - @mastra/ai-sdk@1.0.3
185
+
3
186
  ## 8.0.0-alpha.3
4
187
 
5
188
  ### Patch Changes
@@ -315,188 +498,5 @@
315
498
  All storage and memory pagination APIs have been updated to use `page` (0-indexed) and `perPage` instead of `offset` and `limit`, aligning with standard REST API patterns.
316
499
 
317
500
  **Affected APIs:**
318
- - `Memory.listThreadsByResourceId()`
319
- - `Memory.listMessages()`
320
- - `Storage.listWorkflowRuns()`
321
-
322
- **Migration:**
323
-
324
- ```typescript
325
- // Before
326
- await memory.listThreadsByResourceId({
327
- resourceId: 'user-123',
328
- offset: 20,
329
- limit: 10,
330
- });
331
-
332
- // After
333
- await memory.listThreadsByResourceId({
334
- resourceId: 'user-123',
335
- page: 2, // page = Math.floor(offset / limit)
336
- perPage: 10,
337
- });
338
-
339
- // Before
340
- await memory.listMessages({
341
- threadId: 'thread-456',
342
- offset: 20,
343
- limit: 10,
344
- });
345
-
346
- // After
347
- await memory.listMessages({
348
- threadId: 'thread-456',
349
- page: 2,
350
- perPage: 10,
351
- });
352
-
353
- // Before
354
- await storage.listWorkflowRuns({
355
- workflowName: 'my-workflow',
356
- offset: 20,
357
- limit: 10,
358
- });
359
-
360
- // After
361
- await storage.listWorkflowRuns({
362
- workflowName: 'my-workflow',
363
- page: 2,
364
- perPage: 10,
365
- });
366
- ```
367
-
368
- **Additional improvements:**
369
- - Added validation for negative `page` values in all storage implementations
370
- - Improved `perPage` validation to handle edge cases (negative values, `0`, `false`)
371
- - Added reusable query parser utilities for consistent validation in handlers
372
-
373
- - ```ts ([#9709](https://github.com/mastra-ai/mastra/pull/9709))
374
- import { Mastra } from '@mastra/core';
375
- import { Observability } from '@mastra/observability'; // Explicit import
376
-
377
- const mastra = new Mastra({
378
- ...other_config,
379
- observability: new Observability({
380
- default: { enabled: true },
381
- }), // Instance
382
- });
383
- ```
384
-
385
- Instead of:
386
-
387
- ```ts
388
- import { Mastra } from '@mastra/core';
389
- import '@mastra/observability/init'; // Explicit import
390
-
391
- const mastra = new Mastra({
392
- ...other_config,
393
- observability: {
394
- default: { enabled: true },
395
- },
396
- });
397
- ```
398
-
399
- Also renamed a bunch of:
400
- - `Tracing` things to `Observability` things.
401
- - `AI-` things to just things.
402
-
403
- - Changing getAgents -> listAgents, getTools -> listTools, getWorkflows -> listWorkflows ([#9495](https://github.com/mastra-ai/mastra/pull/9495))
404
-
405
- - Mark as stable ([`83d5942`](https://github.com/mastra-ai/mastra/commit/83d5942669ce7bba4a6ca4fd4da697a10eb5ebdc))
406
-
407
- - Renamed `MastraMessageV2` to `MastraDBMessage` ([#9255](https://github.com/mastra-ai/mastra/pull/9255))
408
- Made the return format of all methods that return db messages consistent. It's always `{ messages: MastraDBMessage[] }` now, and messages can be converted after that using `@mastra/ai-sdk/ui`'s `toAISdkV4/5Messages()` function
409
-
410
- - Remove legacy evals from Mastra ([#9491](https://github.com/mastra-ai/mastra/pull/9491))
411
-
412
- ### Minor Changes
413
-
414
- - Added consistent sizing, radius, and focus effects across all form elements. ([#11970](https://github.com/mastra-ai/mastra/pull/11970))
415
-
416
- **New size prop** for form elements with unified values:
417
- - `sm` (24px)
418
- - `md` (32px)
419
- - `lg` (40px)
420
-
421
- Components now share a consistent `size` prop: Button, Input, SelectTrigger, Searchbar, InputField, SelectField, and Combobox.
422
-
423
- ```tsx
424
- // Before - inconsistent props
425
- <Input customSize="default" />
426
- <Button size="md" /> // was 24px
427
-
428
- // After - unified size prop
429
- <Input size="md" />
430
- <Button size="md" /> // now 32px
431
- <SelectTrigger size="lg" />
432
- ```
433
-
434
- **Breaking changes:**
435
- - Input: `customSize` prop renamed to `size`
436
- - Button: `size="md"` now renders at 32px (was 24px). Use `size="sm"` for 24px height.
437
-
438
- **Other changes:**
439
- - All form elements now use `rounded-md` radius
440
- - All form elements now use `focus:outline focus:outline-accent1` focus effect
441
- - Removed `button-md` and `button-lg` size tokens (use `form-sm`, `form-md`, `form-lg` instead)
442
-
443
- - Added platform-aware navigation filtering using `useMastraPlatform` hook. Nav links now include an `isOnMastraPlatform` property that controls visibility based on whether the app is running on Mastra Platform or locally. ([#11990](https://github.com/mastra-ai/mastra/pull/11990))
444
-
445
- - Moving scorers under the eval domain, api method consistency, prebuilt evals, scorers require ids. ([#9589](https://github.com/mastra-ai/mastra/pull/9589))
446
-
447
- - Enhance design system components with visual polish and micro-interactions. ([#12045](https://github.com/mastra-ai/mastra/pull/12045))
448
-
449
- Phase 2 of DS enhancement covering 40+ components:
450
- - **Form Controls**: Checkbox, RadioGroup, Switch, Slider, Combobox with focus rings, hover states, and smooth transitions
451
- - **Navigation**: Tabs with animated indicator, Steps with progress animation, Collapsible with icon rotation
452
- - **Feedback**: Alert with entrance animation, Notification with slide animations, Skeleton with gradient shimmer
453
- - **Display**: Badge with semantic variants, Avatar with interactive mode, StatusBadge enhancements
454
- - **Layout**: SideDialog with backdrop blur, ScrollArea with visibility transitions
455
-
456
- All components now use consistent design tokens (duration-normal, ease-out-custom, shadow-focus-ring) and GPU-accelerated properties for smooth 60fps animations.
457
-
458
- - Update peer dependencies to match core package version bump (0.22.1) ([#8649](https://github.com/mastra-ai/mastra/pull/8649))
459
-
460
- - Toast error from workflow stream and resume stream ([#9431](https://github.com/mastra-ai/mastra/pull/9431))
461
- Update peer dependencies to match core package version bump (0.22.3)
462
-
463
- - Unified observability schema with entity-based span identification ([#11132](https://github.com/mastra-ai/mastra/pull/11132))
464
-
465
- ## What changed
466
-
467
- Spans now use a unified identification model with `entityId`, `entityType`, and `entityName` instead of separate `agentId`, `toolId`, `workflowId` fields.
468
-
469
- **Before:**
470
-
471
- ```typescript
472
- // Old span structure
473
- span.agentId; // 'my-agent'
474
- span.toolId; // undefined
475
- span.workflowId; // undefined
476
- ```
477
-
478
- **After:**
479
-
480
- ```typescript
481
- // New span structure
482
- span.entityType; // EntityType.AGENT
483
- span.entityId; // 'my-agent'
484
- span.entityName; // 'My Agent'
485
- ```
486
-
487
- ## New `listTraces()` API
488
-
489
- Query traces with filtering, pagination, and sorting:
490
-
491
- ```typescript
492
- const { spans, pagination } = await storage.listTraces({
493
- filters: {
494
- entityType: EntityType.AGENT,
495
- entityId: 'my-agent',
496
- userId: 'user-123',
497
- environment: 'production',
498
- status: TraceStatus.SUCCESS,
499
- startedAt: { start: new Date('2024-01-01'), end: new Date('2024-01-31') },
500
- },
501
501
 
502
- ... 5921 more lines hidden. See full changelog in package directory.
502
+ ... 6104 more lines hidden. See full changelog in package directory.
@@ -1,5 +1,74 @@
1
1
  # @mastra/rag
2
2
 
3
+ ## 2.1.0
4
+
5
+ ### Minor Changes
6
+
7
+ - Added support for 20 additional languages in code chunking ([#12154](https://github.com/mastra-ai/mastra/pull/12154))
8
+
9
+ Extended RecursiveCharacterTransformer to support all languages defined in the Language enum. Previously, only 6 languages were supported (CPP, C, TS, MARKDOWN, LATEX, PHP), causing runtime errors for other defined languages.
10
+
11
+ **Newly supported languages:**
12
+ - GO, JAVA, KOTLIN, JS, PYTHON, RUBY, RUST, SCALA, SWIFT (popular programming languages)
13
+ - HTML, SOL (Solidity), CSHARP, COBOL, LUA, PERL, HASKELL, ELIXIR, POWERSHELL (additional languages)
14
+ - PROTO (Protocol Buffers), RST (reStructuredText) (data/documentation formats)
15
+
16
+ Each language has been configured with appropriate separators based on its syntax patterns (modules, classes, functions, control structures) to enable semantic code chunking.
17
+
18
+ **Before:**
19
+
20
+ ```typescript
21
+ import { RecursiveCharacterTransformer, Language } from '@mastra/rag';
22
+
23
+ // These would all throw "Language X is not supported!" errors
24
+ const goTransformer = RecursiveCharacterTransformer.fromLanguage(Language.GO);
25
+ const pythonTransformer = RecursiveCharacterTransformer.fromLanguage(Language.PYTHON);
26
+ const rustTransformer = RecursiveCharacterTransformer.fromLanguage(Language.RUST);
27
+ ```
28
+
29
+ **After:**
30
+
31
+ ```typescript
32
+ import { RecursiveCharacterTransformer, Language } from '@mastra/rag';
33
+
34
+ // All languages now work seamlessly
35
+ const goTransformer = RecursiveCharacterTransformer.fromLanguage(Language.GO);
36
+ const goChunks = goTransformer.transform(goCodeDocument);
37
+
38
+ const pythonTransformer = RecursiveCharacterTransformer.fromLanguage(Language.PYTHON);
39
+ const pythonChunks = pythonTransformer.transform(pythonCodeDocument);
40
+
41
+ const rustTransformer = RecursiveCharacterTransformer.fromLanguage(Language.RUST);
42
+ const rustChunks = rustTransformer.transform(rustCodeDocument);
43
+ // All languages in the Language enum are now fully supported
44
+ ```
45
+
46
+ ### Patch Changes
47
+
48
+ - Add support for PHP in Language enum
49
+ ([#12124](https://github.com/mastra-ai/mastra/pull/12124))
50
+ Previously, the Language enum defined PHP, but it was not supported in the `getSeparatorsForLanguage` method. This caused runtime errors when trying to use PHP for code chunking.
51
+ This change adds proper separator definitions for PHP, ensuring that PHP defined in the Language enum is now fully supported. PHP has been configured with appropriate separators based on its syntax and common programming patterns (classes, functions, control structures, etc.).
52
+ **Before:**
53
+ ```typescript
54
+ import { RecursiveCharacterTransformer, Language } from '@mastra/rag';
55
+
56
+ const transformer = RecursiveCharacterTransformer.fromLanguage(Language.PHP);
57
+ const chunks = transformer.transform(phpCodeDocument);
58
+ // Throws: "Language PHP is not supported!"
59
+ ```
60
+ **After:**
61
+ ```typescript
62
+ import { RecursiveCharacterTransformer, Language } from '@mastra/rag';
63
+
64
+ const transformer = RecursiveCharacterTransformer.fromLanguage(Language.PHP);
65
+ const chunks = transformer.transform(phpCodeDocument);
66
+ // Successfully chunks PHP code at namespace, class, function boundaries
67
+ ```
68
+ Fixes the issue where using `Language.PHP` would throw "Language PHP is not supported!" error.
69
+ - Updated dependencies [[`90fc0e5`](https://github.com/mastra-ai/mastra/commit/90fc0e5717cb280c2d4acf4f0410b510bb4c0a72), [`1cf5d2e`](https://github.com/mastra-ai/mastra/commit/1cf5d2ea1b085be23e34fb506c80c80a4e6d9c2b), [`b99ceac`](https://github.com/mastra-ai/mastra/commit/b99ceace2c830dbdef47c8692d56a91954aefea2), [`deea43e`](https://github.com/mastra-ai/mastra/commit/deea43eb1366d03a864c5e597d16a48592b9893f), [`833ae96`](https://github.com/mastra-ai/mastra/commit/833ae96c3e34370e58a1e979571c41f39a720592), [`943772b`](https://github.com/mastra-ai/mastra/commit/943772b4378f625f0f4e19ea2b7c392bd8e71786), [`b5c711b`](https://github.com/mastra-ai/mastra/commit/b5c711b281dd1fb81a399a766bc9f86c55efc13e), [`3efbe5a`](https://github.com/mastra-ai/mastra/commit/3efbe5ae20864c4f3143457f4f3ee7dc2fa5ca76), [`1e49e7a`](https://github.com/mastra-ai/mastra/commit/1e49e7ab5f173582154cb26b29d424de67d09aef), [`751eaab`](https://github.com/mastra-ai/mastra/commit/751eaab4e0d3820a94e4c3d39a2ff2663ded3d91), [`69d8156`](https://github.com/mastra-ai/mastra/commit/69d81568bcf062557c24471ce26812446bec465d), [`60d9d89`](https://github.com/mastra-ai/mastra/commit/60d9d899e44b35bc43f1bcd967a74e0ce010b1af), [`5c544c8`](https://github.com/mastra-ai/mastra/commit/5c544c8d12b08ab40d64d8f37b3c4215bee95b87), [`771ad96`](https://github.com/mastra-ai/mastra/commit/771ad962441996b5c43549391a3e6a02c6ddedc2), [`2b0936b`](https://github.com/mastra-ai/mastra/commit/2b0936b0c9a43eeed9bef63e614d7e02ee803f7e), [`3b04f30`](https://github.com/mastra-ai/mastra/commit/3b04f3010604f3cdfc8a0674731700ad66471cee), [`97e26de`](https://github.com/mastra-ai/mastra/commit/97e26deaebd9836647a67b96423281d66421ca07), [`ac9ec66`](https://github.com/mastra-ai/mastra/commit/ac9ec6672779b2e6d4344e415481d1a6a7d4911a), [`10523f4`](https://github.com/mastra-ai/mastra/commit/10523f4882d9b874b40ce6e3715f66dbcd4947d2), [`cb72d20`](https://github.com/mastra-ai/mastra/commit/cb72d2069d7339bda8a0e76d4f35615debb07b84), [`42856b1`](https://github.com/mastra-ai/mastra/commit/42856b1c8aeea6371c9ee77ae2f5f5fe34400933), [`66f33ff`](https://github.com/mastra-ai/mastra/commit/66f33ff68620018513e499c394411d1d39b3aa5c), [`ab3c190`](https://github.com/mastra-ai/mastra/commit/ab3c1901980a99910ca9b96a7090c22e24060113), [`d4f06c8`](https://github.com/mastra-ai/mastra/commit/d4f06c85ffa5bb0da38fb82ebf3b040cc6b4ec4e), [`0350626`](https://github.com/mastra-ai/mastra/commit/03506267ec41b67add80d994c0c0fcce93bbc75f), [`bc9fa00`](https://github.com/mastra-ai/mastra/commit/bc9fa00859c5c4a796d53a0a5cae46ab4a3072e4), [`f46a478`](https://github.com/mastra-ai/mastra/commit/f46a4782f595949c696569e891f81c8d26338508), [`90fc0e5`](https://github.com/mastra-ai/mastra/commit/90fc0e5717cb280c2d4acf4f0410b510bb4c0a72), [`f05a3a5`](https://github.com/mastra-ai/mastra/commit/f05a3a5cf2b9a9c2d40c09cb8c762a4b6cd5d565), [`a291da9`](https://github.com/mastra-ai/mastra/commit/a291da9363efd92dafd8775dccb4f2d0511ece7a), [`c5d71da`](https://github.com/mastra-ai/mastra/commit/c5d71da1c680ce5640b1a7f8ca0e024a4ab1cfed), [`07042f9`](https://github.com/mastra-ai/mastra/commit/07042f9f89080f38b8f72713ba1c972d5b1905b8), [`0423442`](https://github.com/mastra-ai/mastra/commit/0423442b7be2dfacba95890bea8f4a810db4d603)]:
70
+ - @mastra/core@1.1.0
71
+
3
72
  ## 2.1.0-alpha.0
4
73
 
5
74
  ### Minor Changes
@@ -429,74 +498,5 @@
429
498
 
430
499
  Introduces a new `SchemaExtractor` that enables extraction of custom structured metadata from document chunks using user-defined Zod schemas. This allows for domain-specific metadata structures (e.g., product details, legal entities, sentiment analysis) to be reliably extracted via LLM structured output.
431
500
  - Extract domain-specific metadata using your own Zod schemas (e.g., product details, legal entities, sentiment)
432
- - Customize extraction behavior with your own LLM model and instructions
433
- - Organize extracted data by nesting it under custom metadata keys
434
- - Existing extractors (title, summary, keywords, questions) remain unchanged and fully compatible
435
-
436
- **Before** (limited to built-in extractors):
437
-
438
- ```typescript
439
- await document.extractMetadata({
440
- extract: {
441
- title: true,
442
- summary: true,
443
- },
444
- });
445
- ```
446
-
447
- **After** (with custom Zod schema):
448
-
449
- ```typescript
450
- import { z } from 'zod';
451
-
452
- const productSchema = z.object({
453
- name: z.string(),
454
- price: z.number(),
455
- category: z.string(),
456
- });
457
-
458
- await document.extractMetadata({
459
- extract: {
460
- title: true,
461
- schema: {
462
- schema: productSchema,
463
- instructions: 'Extract product details from the document',
464
- metadataKey: 'product',
465
- },
466
- },
467
- });
468
- ```
469
-
470
- With `metadataKey`, extracted data is nested under the key:
471
-
472
- ```typescript
473
- {
474
- title: "Product Document",
475
- summary: "A comprehensive guide",
476
- product: {
477
- name: "Wireless Headphones",
478
- price: 149.99,
479
- category: "Electronics"
480
- }
481
- }
482
- ```
483
-
484
- Without `metadataKey`, extracted data is returned inline:
485
-
486
- ```typescript
487
- {
488
- title: "Product Document",
489
- summary: "A comprehensive guide",
490
- name: "Wireless Headphones",
491
- price: 149.99,
492
- category: "Electronics"
493
- }
494
- ```
495
-
496
- Fixes #11799
497
-
498
- - Renamed `keepSeparator` parameter to `separatorPosition` with a cleaner type. ([#11802](https://github.com/mastra-ai/mastra/pull/11802))
499
-
500
- The `keepSeparator` parameter had a confusing `boolean | 'start' | 'end'` type where `true` was secretly an alias for `'start'`. The new `separatorPosition` parameter uses explicit `'start' | 'end'` values, and omitting the parameter discards the separator (previous default behavior).
501
501
 
502
- ... 3383 more lines hidden. See full changelog in package directory.
502
+ ... 3452 more lines hidden. See full changelog in package directory.
@@ -1,5 +1,38 @@
1
1
  # @mastra/react
2
2
 
3
+ ## 0.2.0
4
+
5
+ ### Minor Changes
6
+
7
+ - Added `apiPrefix` prop to `MastraClientProvider` for connecting to servers with custom API route prefixes (defaults to `/api`). ([#12295](https://github.com/mastra-ai/mastra/pull/12295))
8
+
9
+ **Default usage (no change required):**
10
+
11
+ ```tsx
12
+ <MastraClientProvider baseUrl="http://localhost:3000">{children}</MastraClientProvider>
13
+ ```
14
+
15
+ **Custom prefix usage:**
16
+
17
+ ```tsx
18
+ <MastraClientProvider baseUrl="http://localhost:3000" apiPrefix="/mastra">
19
+ {children}
20
+ </MastraClientProvider>
21
+ ```
22
+
23
+ See #12261 for more details.
24
+
25
+ - Added useCancelWorkflowRun hook to @mastra/react for canceling workflow runs. This hook was previously only available internally in playground-ui and is now exported for use in custom applications. ([#12142](https://github.com/mastra-ai/mastra/pull/12142))
26
+
27
+ - Added useStreamWorkflow hook to @mastra/react for streaming workflow execution. This hook supports streaming, observing, resuming, and time-traveling workflows. It accepts tracingOptions and onError as parameters for better customization. ([#12151](https://github.com/mastra-ai/mastra/pull/12151))
28
+
29
+ ### Patch Changes
30
+
31
+ - Use useExecuteWorkflow hook from @mastra/react instead of local implementation in playground-ui ([#12138](https://github.com/mastra-ai/mastra/pull/12138))
32
+
33
+ - Updated dependencies [[`deea43e`](https://github.com/mastra-ai/mastra/commit/deea43eb1366d03a864c5e597d16a48592b9893f), [`60d9d89`](https://github.com/mastra-ai/mastra/commit/60d9d899e44b35bc43f1bcd967a74e0ce010b1af), [`0350626`](https://github.com/mastra-ai/mastra/commit/03506267ec41b67add80d994c0c0fcce93bbc75f), [`3efbe5a`](https://github.com/mastra-ai/mastra/commit/3efbe5ae20864c4f3143457f4f3ee7dc2fa5ca76), [`dc82e6c`](https://github.com/mastra-ai/mastra/commit/dc82e6c5a05d6a9160c522af08b8c809ddbcdb66), [`a64a24c`](https://github.com/mastra-ai/mastra/commit/a64a24c9bce499b989667c7963f2f71a11d90334), [`a64a24c`](https://github.com/mastra-ai/mastra/commit/a64a24c9bce499b989667c7963f2f71a11d90334)]:
34
+ - @mastra/client-js@1.1.0
35
+
3
36
  ## 0.2.0-alpha.2
4
37
 
5
38
  ### Patch Changes
@@ -466,37 +499,4 @@
466
499
  resourceId: 'user-456',
467
500
  });
468
501
 
469
- // After
470
- await agent.stream('Hello', {
471
- memory: {
472
- thread: 'thread-123',
473
- resource: 'user-456',
474
- },
475
- });
476
- ```
477
-
478
- #### `@mastra/server`
479
-
480
- The `threadId`, `resourceId`, and `resourceid` fields have been removed from the main agent execution body schema. The server now expects the `memory` option format in request bodies. Legacy routes (`/api/agents/:agentId/generate-legacy` and `/api/agents/:agentId/stream-legacy`) continue to support the deprecated fields.
481
-
482
- #### `@mastra/react`
483
-
484
- The `useChat` hook now internally converts `threadId` to the `memory` option format when making API calls. No changes needed in component code - the hook handles the conversion automatically.
485
-
486
- #### `@mastra/client-js`
487
-
488
- When using the client SDK agent methods, use the `memory` option instead of `threadId`/`resourceId`:
489
-
490
- ```ts
491
- const agent = client.getAgent('my-agent');
492
-
493
- // Before
494
- await agent.generate({
495
- messages: [...],
496
- threadId: 'thread-123',
497
- resourceId: 'user-456',
498
- });
499
-
500
- // After
501
-
502
- ... 656 more lines hidden. See full changelog in package directory.
502
+ ... 689 more lines hidden. See full changelog in package directory.