Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
88 changes: 87 additions & 1 deletion .changeset/pre.json

Large diffs are not rendered by default.

46 changes: 46 additions & 0 deletions client-sdks/ai-sdk/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,51 @@
# @mastra/ai-sdk

## 1.0.0-beta.15

### Major Changes

- **Breaking Change**: Convert OUTPUT generic from `OutputSchema` constraint to plain generic ([#11741](https://github.com/mastra-ai/mastra/pull/11741))

This change removes the direct dependency on Zod typings in the public API by converting all `OUTPUT extends OutputSchema` generic constraints to plain `OUTPUT` generics throughout the codebase. This is preparation for moving to a standard schema approach.
- All generic type parameters previously constrained to `OutputSchema` (e.g., `<OUTPUT extends OutputSchema = undefined>`) are now plain generics with defaults (e.g., `<OUTPUT = undefined>`)
- Affects all public APIs including `Agent`, `MastraModelOutput`, `AgentExecutionOptions`, and stream/generate methods
- `InferSchemaOutput<OUTPUT>` replaced with `OUTPUT` throughout
- `PartialSchemaOutput<OUTPUT>` replaced with `Partial<OUTPUT>`
- Schema fields now use `NonNullable<OutputSchema<OUTPUT>>` instead of `OUTPUT` directly
- Added `FullOutput<OUTPUT>` type representing complete output with all fields
- Added `AgentExecutionOptionsBase<OUTPUT>` type
- `getFullOutput()` method now returns `Promise<FullOutput<OUTPUT>>`
- `Agent` class now generic: `Agent<TAgentId, TTools, TOutput>`
- `agent.generate()` and `agent.stream()` methods have updated signatures
- `MastraModelOutput<OUTPUT>` no longer requires `OutputSchema` constraint
- Network route and streaming APIs updated to use plain OUTPUT generic

**Before:**

```typescript
const output = await agent.generate<z.ZodType>({
messages: [...],
structuredOutput: { schema: mySchema }
});

**After:**
const output = await agent.generate<z.infer<typeof mySchema>>({
messages: [...],
structuredOutput: { schema: mySchema }
});
// Or rely on type inference:
const output = await agent.generate({
messages: [...],
structuredOutput: { schema: mySchema }
});

```

### Patch Changes

- Updated dependencies [[`ebae12a`](https://github.com/mastra-ai/mastra/commit/ebae12a2dd0212e75478981053b148a2c246962d), [`c61a0a5`](https://github.com/mastra-ai/mastra/commit/c61a0a5de4904c88fd8b3718bc26d1be1c2ec6e7), [`69136e7`](https://github.com/mastra-ai/mastra/commit/69136e748e32f57297728a4e0f9a75988462f1a7), [`449aed2`](https://github.com/mastra-ai/mastra/commit/449aed2ba9d507b75bf93d427646ea94f734dfd1), [`eb648a2`](https://github.com/mastra-ai/mastra/commit/eb648a2cc1728f7678768dd70cd77619b448dab9), [`0131105`](https://github.com/mastra-ai/mastra/commit/0131105532e83bdcbb73352fc7d0879eebf140dc), [`9d5059e`](https://github.com/mastra-ai/mastra/commit/9d5059eae810829935fb08e81a9bb7ecd5b144a7), [`ef756c6`](https://github.com/mastra-ai/mastra/commit/ef756c65f82d16531c43f49a27290a416611e526), [`b00ccd3`](https://github.com/mastra-ai/mastra/commit/b00ccd325ebd5d9e37e34dd0a105caae67eb568f), [`3bdfa75`](https://github.com/mastra-ai/mastra/commit/3bdfa7507a91db66f176ba8221aa28dd546e464a), [`e770de9`](https://github.com/mastra-ai/mastra/commit/e770de941a287a49b1964d44db5a5763d19890a6), [`52e2716`](https://github.com/mastra-ai/mastra/commit/52e2716b42df6eff443de72360ae83e86ec23993), [`27b4040`](https://github.com/mastra-ai/mastra/commit/27b4040bfa1a95d92546f420a02a626b1419a1d6), [`610a70b`](https://github.com/mastra-ai/mastra/commit/610a70bdad282079f0c630e0d7bb284578f20151), [`8dc7f55`](https://github.com/mastra-ai/mastra/commit/8dc7f55900395771da851dc7d78d53ae84fe34ec), [`8379099`](https://github.com/mastra-ai/mastra/commit/8379099fc467af6bef54dd7f80c9bd75bf8bbddf), [`8c0ec25`](https://github.com/mastra-ai/mastra/commit/8c0ec25646c8a7df253ed1e5ff4863a0d3f1316c), [`ff4d9a6`](https://github.com/mastra-ai/mastra/commit/ff4d9a6704fc87b31a380a76ed22736fdedbba5a), [`69821ef`](https://github.com/mastra-ai/mastra/commit/69821ef806482e2c44e2197ac0b050c3fe3a5285), [`1ed5716`](https://github.com/mastra-ai/mastra/commit/1ed5716830867b3774c4a1b43cc0d82935f32b96), [`4186bdd`](https://github.com/mastra-ai/mastra/commit/4186bdd00731305726fa06adba0b076a1d50b49f), [`7aaf973`](https://github.com/mastra-ai/mastra/commit/7aaf973f83fbbe9521f1f9e7a4fd99b8de464617)]:
- @mastra/core@1.0.0-beta.22

## 1.0.0-beta.14

### Patch Changes
Expand Down
2 changes: 1 addition & 1 deletion client-sdks/ai-sdk/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@mastra/ai-sdk",
"version": "1.0.0-beta.14",
"version": "1.0.0-beta.15",
"description": "Adds custom API routes to be compatible with the AI SDK UI parts",
"type": "module",
"main": "dist/index.js",
Expand Down
108 changes: 108 additions & 0 deletions client-sdks/client-js/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,113 @@
# @mastra/client-js

## 1.0.0-beta.22

### Major Changes

- **Breaking Change**: Convert OUTPUT generic from `OutputSchema` constraint to plain generic ([#11741](https://github.com/mastra-ai/mastra/pull/11741))

This change removes the direct dependency on Zod typings in the public API by converting all `OUTPUT extends OutputSchema` generic constraints to plain `OUTPUT` generics throughout the codebase. This is preparation for moving to a standard schema approach.
- All generic type parameters previously constrained to `OutputSchema` (e.g., `<OUTPUT extends OutputSchema = undefined>`) are now plain generics with defaults (e.g., `<OUTPUT = undefined>`)
- Affects all public APIs including `Agent`, `MastraModelOutput`, `AgentExecutionOptions`, and stream/generate methods
- `InferSchemaOutput<OUTPUT>` replaced with `OUTPUT` throughout
- `PartialSchemaOutput<OUTPUT>` replaced with `Partial<OUTPUT>`
- Schema fields now use `NonNullable<OutputSchema<OUTPUT>>` instead of `OUTPUT` directly
- Added `FullOutput<OUTPUT>` type representing complete output with all fields
- Added `AgentExecutionOptionsBase<OUTPUT>` type
- `getFullOutput()` method now returns `Promise<FullOutput<OUTPUT>>`
- `Agent` class now generic: `Agent<TAgentId, TTools, TOutput>`
- `agent.generate()` and `agent.stream()` methods have updated signatures
- `MastraModelOutput<OUTPUT>` no longer requires `OutputSchema` constraint
- Network route and streaming APIs updated to use plain OUTPUT generic

**Before:**

```typescript
const output = await agent.generate<z.ZodType>({
messages: [...],
structuredOutput: { schema: mySchema }
});

**After:**
const output = await agent.generate<z.infer<typeof mySchema>>({
messages: [...],
structuredOutput: { schema: mySchema }
});
// Or rely on type inference:
const output = await agent.generate({
messages: [...],
structuredOutput: { schema: mySchema }
});

```

### Patch Changes

- Removes the deprecated `threadId` and `resourceId` options from `AgentExecutionOptions`. These have been deprecated for months in favour of the `memory` option. ([#11897](https://github.com/mastra-ai/mastra/pull/11897))

### Breaking Changes

#### `@mastra/core`

The `threadId` and `resourceId` options have been removed from `agent.generate()` and `agent.stream()`. Use the `memory` option instead:

```ts
// Before
await agent.stream('Hello', {
threadId: 'thread-123',
resourceId: 'user-456',
});

// After
await agent.stream('Hello', {
memory: {
thread: 'thread-123',
resource: 'user-456',
},
});
```

#### `@mastra/server`

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.

#### `@mastra/react`

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.

#### `@mastra/client-js`

When using the client SDK agent methods, use the `memory` option instead of `threadId`/`resourceId`:

```ts
const agent = client.getAgent('my-agent');

// Before
await agent.generate({
messages: [...],
threadId: 'thread-123',
resourceId: 'user-456',
});

// After
await agent.generate({
messages: [...],
memory: {
thread: 'thread-123',
resource: 'user-456',
},
});
```

- Add human-in-the-loop (HITL) support to agent networks ([#11678](https://github.com/mastra-ai/mastra/pull/11678))
- Add suspend/resume capabilities to agent network
- Enable auto-resume for suspended network execution via `autoResumeSuspendedTools`

`agent.resumeNetwork`, `agent.approveNetworkToolCall`, `agent.declineNetworkToolCall`

- Updated dependencies [[`ebae12a`](https://github.com/mastra-ai/mastra/commit/ebae12a2dd0212e75478981053b148a2c246962d), [`c61a0a5`](https://github.com/mastra-ai/mastra/commit/c61a0a5de4904c88fd8b3718bc26d1be1c2ec6e7), [`69136e7`](https://github.com/mastra-ai/mastra/commit/69136e748e32f57297728a4e0f9a75988462f1a7), [`449aed2`](https://github.com/mastra-ai/mastra/commit/449aed2ba9d507b75bf93d427646ea94f734dfd1), [`eb648a2`](https://github.com/mastra-ai/mastra/commit/eb648a2cc1728f7678768dd70cd77619b448dab9), [`0131105`](https://github.com/mastra-ai/mastra/commit/0131105532e83bdcbb73352fc7d0879eebf140dc), [`9d5059e`](https://github.com/mastra-ai/mastra/commit/9d5059eae810829935fb08e81a9bb7ecd5b144a7), [`ef756c6`](https://github.com/mastra-ai/mastra/commit/ef756c65f82d16531c43f49a27290a416611e526), [`b00ccd3`](https://github.com/mastra-ai/mastra/commit/b00ccd325ebd5d9e37e34dd0a105caae67eb568f), [`3bdfa75`](https://github.com/mastra-ai/mastra/commit/3bdfa7507a91db66f176ba8221aa28dd546e464a), [`e770de9`](https://github.com/mastra-ai/mastra/commit/e770de941a287a49b1964d44db5a5763d19890a6), [`52e2716`](https://github.com/mastra-ai/mastra/commit/52e2716b42df6eff443de72360ae83e86ec23993), [`27b4040`](https://github.com/mastra-ai/mastra/commit/27b4040bfa1a95d92546f420a02a626b1419a1d6), [`610a70b`](https://github.com/mastra-ai/mastra/commit/610a70bdad282079f0c630e0d7bb284578f20151), [`8dc7f55`](https://github.com/mastra-ai/mastra/commit/8dc7f55900395771da851dc7d78d53ae84fe34ec), [`8379099`](https://github.com/mastra-ai/mastra/commit/8379099fc467af6bef54dd7f80c9bd75bf8bbddf), [`8c0ec25`](https://github.com/mastra-ai/mastra/commit/8c0ec25646c8a7df253ed1e5ff4863a0d3f1316c), [`ff4d9a6`](https://github.com/mastra-ai/mastra/commit/ff4d9a6704fc87b31a380a76ed22736fdedbba5a), [`69821ef`](https://github.com/mastra-ai/mastra/commit/69821ef806482e2c44e2197ac0b050c3fe3a5285), [`1ed5716`](https://github.com/mastra-ai/mastra/commit/1ed5716830867b3774c4a1b43cc0d82935f32b96), [`4186bdd`](https://github.com/mastra-ai/mastra/commit/4186bdd00731305726fa06adba0b076a1d50b49f), [`7aaf973`](https://github.com/mastra-ai/mastra/commit/7aaf973f83fbbe9521f1f9e7a4fd99b8de464617)]:
- @mastra/core@1.0.0-beta.22

## 1.0.0-beta.21

### Patch Changes
Expand Down
2 changes: 1 addition & 1 deletion client-sdks/client-js/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@mastra/client-js",
"version": "1.0.0-beta.21",
"version": "1.0.0-beta.22",
"description": "The official TypeScript library for the Mastra Client API",
"author": "",
"type": "module",
Expand Down
75 changes: 75 additions & 0 deletions client-sdks/react/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,80 @@
# @mastra/react-hooks

## 0.1.0-beta.22

### Patch Changes

- Removes the deprecated `threadId` and `resourceId` options from `AgentExecutionOptions`. These have been deprecated for months in favour of the `memory` option. ([#11897](https://github.com/mastra-ai/mastra/pull/11897))

### Breaking Changes

#### `@mastra/core`

The `threadId` and `resourceId` options have been removed from `agent.generate()` and `agent.stream()`. Use the `memory` option instead:

```ts
// Before
await agent.stream('Hello', {
threadId: 'thread-123',
resourceId: 'user-456',
});

// After
await agent.stream('Hello', {
memory: {
thread: 'thread-123',
resource: 'user-456',
},
});
```

#### `@mastra/server`

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.

#### `@mastra/react`

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.

#### `@mastra/client-js`

When using the client SDK agent methods, use the `memory` option instead of `threadId`/`resourceId`:

```ts
const agent = client.getAgent('my-agent');

// Before
await agent.generate({
messages: [...],
threadId: 'thread-123',
resourceId: 'user-456',
});

// After
await agent.generate({
messages: [...],
memory: {
thread: 'thread-123',
resource: 'user-456',
},
});
```

- Add human-in-the-loop (HITL) support to agent networks ([#11678](https://github.com/mastra-ai/mastra/pull/11678))
- Add suspend/resume capabilities to agent network
- Enable auto-resume for suspended network execution via `autoResumeSuspendedTools`

`agent.resumeNetwork`, `agent.approveNetworkToolCall`, `agent.declineNetworkToolCall`

- Fix text parts incorrectly merging across tool calls ([#11783](https://github.com/mastra-ai/mastra/pull/11783))

Previously, when an agent produced text before and after a tool call (e.g., "Let me search for that" → tool call → "Here's what I found"), the text parts would be merged into a single part, losing the separation. This fix introduces a `textId` property to track separate text streams, ensuring each text stream maintains its own text part in the UI message.

Fixes #11577

- Updated dependencies [[`9d5059e`](https://github.com/mastra-ai/mastra/commit/9d5059eae810829935fb08e81a9bb7ecd5b144a7), [`ef756c6`](https://github.com/mastra-ai/mastra/commit/ef756c65f82d16531c43f49a27290a416611e526), [`610a70b`](https://github.com/mastra-ai/mastra/commit/610a70bdad282079f0c630e0d7bb284578f20151)]:
- @mastra/client-js@1.0.0-beta.22

## 0.1.0-beta.21

### Patch Changes
Expand Down
2 changes: 1 addition & 1 deletion client-sdks/react/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@mastra/react",
"version": "0.1.0-beta.21",
"version": "0.1.0-beta.22",
"repository": {
"type": "git",
"url": "git+https://github.com/mastra-ai/mastra.git",
Expand Down
77 changes: 77 additions & 0 deletions deployers/cloud/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,82 @@
# @mastra/deployer-cloud

## 1.0.0-beta.22

### Minor Changes

- Renamed Mastra Studio artifact directory from `dist/playground` to `dist/studio` to align with updated terminology across the deployer and CLI tools. ([#11751](https://github.com/mastra-ai/mastra/pull/11751))

### Patch Changes

- Aligned vector store configuration with underlying library APIs, giving you access to all library options directly. ([#11742](https://github.com/mastra-ai/mastra/pull/11742))

**Why this change?**

Previously, each vector store defined its own configuration types that only exposed a subset of the underlying library's options. This meant users couldn't access advanced features like authentication, SSL, compression, or custom headers without creating their own client instances. Now, the configuration types extend the library types directly, so all options are available.

**@mastra/libsql** (Breaking)

Renamed `connectionUrl` to `url` to match the `@libsql/client` API and align with LibSQLStorage.

```typescript
// Before
new LibSQLVector({ id: 'my-vector', connectionUrl: 'file:./db.sqlite' });

// After
new LibSQLVector({ id: 'my-vector', url: 'file:./db.sqlite' });
```

**@mastra/opensearch** (Breaking)

Renamed `url` to `node` and added support for all OpenSearch `ClientOptions` including authentication, SSL, and compression.

```typescript
// Before
new OpenSearchVector({ id: 'my-vector', url: 'http://localhost:9200' });

// After
new OpenSearchVector({ id: 'my-vector', node: 'http://localhost:9200' });

// With authentication (now possible)
new OpenSearchVector({
id: 'my-vector',
node: 'https://localhost:9200',
auth: { username: 'admin', password: 'admin' },
ssl: { rejectUnauthorized: false },
});
```

**@mastra/pinecone** (Breaking)

Removed `environment` parameter. Use `controllerHostUrl` instead (the actual Pinecone SDK field name). Added support for all `PineconeConfiguration` options.

```typescript
// Before
new PineconeVector({ id: 'my-vector', apiKey: '...', environment: '...' });

// After
new PineconeVector({ id: 'my-vector', apiKey: '...' });

// With custom controller host (if needed)
new PineconeVector({ id: 'my-vector', apiKey: '...', controllerHostUrl: '...' });
```

**@mastra/clickhouse**

Added support for all `ClickHouseClientConfigOptions` like `request_timeout`, `compression`, `keep_alive`, and `database`. Existing configurations continue to work unchanged.

**@mastra/cloudflare, @mastra/cloudflare-d1, @mastra/lance, @mastra/libsql, @mastra/mongodb, @mastra/pg, @mastra/upstash**

Improved logging by replacing `console.warn` with structured logger in workflow storage domains.

**@mastra/deployer-cloud**

Updated internal LibSQLVector configuration for compatibility with the new API.

- Updated dependencies [[`8aab268`](https://github.com/mastra-ai/mastra/commit/8aab268ee81ed6cde8adf3ac81a5e2de1c544a0c), [`ebae12a`](https://github.com/mastra-ai/mastra/commit/ebae12a2dd0212e75478981053b148a2c246962d), [`c61a0a5`](https://github.com/mastra-ai/mastra/commit/c61a0a5de4904c88fd8b3718bc26d1be1c2ec6e7), [`69136e7`](https://github.com/mastra-ai/mastra/commit/69136e748e32f57297728a4e0f9a75988462f1a7), [`449aed2`](https://github.com/mastra-ai/mastra/commit/449aed2ba9d507b75bf93d427646ea94f734dfd1), [`eb648a2`](https://github.com/mastra-ai/mastra/commit/eb648a2cc1728f7678768dd70cd77619b448dab9), [`0131105`](https://github.com/mastra-ai/mastra/commit/0131105532e83bdcbb73352fc7d0879eebf140dc), [`9d5059e`](https://github.com/mastra-ai/mastra/commit/9d5059eae810829935fb08e81a9bb7ecd5b144a7), [`ef756c6`](https://github.com/mastra-ai/mastra/commit/ef756c65f82d16531c43f49a27290a416611e526), [`b00ccd3`](https://github.com/mastra-ai/mastra/commit/b00ccd325ebd5d9e37e34dd0a105caae67eb568f), [`6afd81d`](https://github.com/mastra-ai/mastra/commit/6afd81df67fbbf362871f632fb34d90da1ed5c0b), [`3bdfa75`](https://github.com/mastra-ai/mastra/commit/3bdfa7507a91db66f176ba8221aa28dd546e464a), [`e770de9`](https://github.com/mastra-ai/mastra/commit/e770de941a287a49b1964d44db5a5763d19890a6), [`52e2716`](https://github.com/mastra-ai/mastra/commit/52e2716b42df6eff443de72360ae83e86ec23993), [`27b4040`](https://github.com/mastra-ai/mastra/commit/27b4040bfa1a95d92546f420a02a626b1419a1d6), [`610a70b`](https://github.com/mastra-ai/mastra/commit/610a70bdad282079f0c630e0d7bb284578f20151), [`f4eebb2`](https://github.com/mastra-ai/mastra/commit/f4eebb28151f8b0259c88559149c4abfa00a84de), [`8dc7f55`](https://github.com/mastra-ai/mastra/commit/8dc7f55900395771da851dc7d78d53ae84fe34ec), [`8379099`](https://github.com/mastra-ai/mastra/commit/8379099fc467af6bef54dd7f80c9bd75bf8bbddf), [`8c0ec25`](https://github.com/mastra-ai/mastra/commit/8c0ec25646c8a7df253ed1e5ff4863a0d3f1316c), [`ff4d9a6`](https://github.com/mastra-ai/mastra/commit/ff4d9a6704fc87b31a380a76ed22736fdedbba5a), [`69821ef`](https://github.com/mastra-ai/mastra/commit/69821ef806482e2c44e2197ac0b050c3fe3a5285), [`1ed5716`](https://github.com/mastra-ai/mastra/commit/1ed5716830867b3774c4a1b43cc0d82935f32b96), [`4186bdd`](https://github.com/mastra-ai/mastra/commit/4186bdd00731305726fa06adba0b076a1d50b49f), [`7aaf973`](https://github.com/mastra-ai/mastra/commit/7aaf973f83fbbe9521f1f9e7a4fd99b8de464617)]:
- @mastra/deployer@1.0.0-beta.22
- @mastra/core@1.0.0-beta.22

## 1.0.0-beta.21

### Patch Changes
Expand Down
2 changes: 1 addition & 1 deletion deployers/cloud/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@mastra/deployer-cloud",
"version": "1.0.0-beta.21",
"version": "1.0.0-beta.22",
"description": "",
"type": "module",
"files": [
Expand Down
Loading