Skip to content

Conversation

@LekoArts
Copy link

Description

At Mastra we're working towards a v1.0.0 release and recently we released a beta version of that. Users can now install @beta versions of Mastra packages and try out the new changes. This version bumps also comes with breaking changes which also affect third-party packages like @ag-ui/mastra.

In our shared Slack channel I communicated with @tylerslaton so far about this and I'm open to handling however you prefer. Here's what I think we should do:

  • Publish some form of prerelease version of the package (that is not @latest)
  • Wait for Mastra v1 be released
  • Release a new major for @ag-ui/mastra, too

In this PR I've updated all examples, too, as they use the local version and would not work otherwise. It's probably easiest to create a release based off from this branch/PR and not merge the PR until Mastra v1. But if you want to do it in another way, let me know.

`,
model: openai("gpt-4o-mini"),
model: "openai/gpt-4o-mini",
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Mastra now has its own model router so we can remove AI SDK usage

tools: { weatherTool, browserTool },
memory: new Memory({
storage: new LibSQLStore({
id: "mastra-cli-example-db",
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

execute: async ({ context }) => {
open(context.url);
return `Browsed ${context.url}`;
execute: async (inputData) => {
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"@ag-ui/client": ">=0.0.40",
"@copilotkit/runtime": "^1.10.5",
"@mastra/core": ">=0.20.1",
"zod": "^3.25.67"
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

zod is a peerDep of @mastra/core so not required to place it here, too

ExperimentalEmptyAdapter,
} from "@copilotkit/runtime";
import { RuntimeContext } from "@mastra/core/runtime-context";
import { RequestContext } from "@mastra/core/request-context";
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

const memory = await this.agent.getMemory();
if (memory) {
const workingMemory = await memory.getWorkingMemory({
resourceId: this.resourceId,
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Everything is 'resource' scoped now, so we need to pass it here: https://mastra.ai/guides/v1/migrations/upgrade-to-v1/memory#default-memory-scope-from-thread-to-resource

That's why I made it required everywhere

@tylerslaton
Copy link
Contributor

Hey @LekoArts! I had to make some small changes to the mastra examples for the Dojo so that code shows properly.

Happy to help get any conflicts resolved - just let me know!

#750

@LekoArts
Copy link
Author

LekoArts commented Dec 1, 2025

@tylerslaton Should be all fixed 👍

@mme
Copy link
Contributor

mme commented Dec 1, 2025

@LekoArts we published a beta @ag-ui/mastra@0.2.1-beta.0

@LekoArts
Copy link
Author

LekoArts commented Dec 1, 2025

Thanks! I'll give it a try tomorrow 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants