Welcome & Intros0:00
Allright, should we get it going?
Let's do it.
Allright, welcome everyone. Uh, this is "AI Pipelines and Agents in Pure TypeScript" with Mastra.ai. Uh, today's mission, do you want to talk?
Sure. Um, so what we're going to do today is we're going to build an AI-powered meme generator, and yes, that's humorous. Sounds like a toy, but the patterns that we're going to use here, uh, both with the Mastra framework and in terms of using TypeScript to build a production agent, are the same patterns that we've used and that you can use, um, to deploy to production with, uh, AI applications.
Um, so the rough format that we're going to follow here is we're going to do like a 20-minute intros and concept just to make sure everyone's level set. Feel free to, you know, stop us, ask questions, and then, um, the majority of the time this workshop is going to be spent coding, uh, together, um, collaboratively, and then we'll have about 10 minutes wrap-up and Q&A and a little fun demo for you at the end to get some swag.
Yep. And, uh, yeah, so this is a true workshop format. Uh, we'll be building together. If you have questions, uh, reach out to us. We're happy to help. And, uh, just so you can get kind of a head start on it, if you go to "Workshop AI Agents with Mastra," uh, the Slack channel in the AI Engineer Slack, all the materials are in the pinned link there, and we can have discussions there as well, continuing.
Uh, so we work at a company called WorkOS. Um, we build developer tools and make enterprise features happy—uh, enterprise developers happy—with easy-to-use tools like SSO and SAML, directory sync, audit logs, fine-grained auth. Uh, and we're really getting into AI, uh, and securing your AI, uh, things like securing your MCP, attaching identity to those agents so that they can act on your behalf and know who you are.
Yep. Um, another good way to think about WorkOS is if you—like, let's say Nick and I built the ultimate app this weekend, we're ready to go sell it, and then the first time we demo it to somebody, they say, "Can you give us, uh, single sign-on for our 2,000 users over here in a different path over here?"
Um, so then we would go and buy WorkOS or use WorkOS, drop the JavaScript in, and we would have those features, uh, ready to sell.
Uh, so my name's Nick Nisi. I'm Developer Experience at WorkOS. Uh, I'm also a host on the Dysfunctional.fm podcast, formerly JS Party. Any JS Party listeners ever? Huh? Nice. Um, uh, I also do conference MC-ing and speaking. Um, I'll be at Squiggle Conf MC-ing that, uh, which is a dev tools-focused conference in Boston later this year.
Uh, I'm also a TypeScript enthusiast, as you'll see. I'm a Vim user, by the way, and I'm Nick Nisi everywhere.
Hey everyone. I'm Zack. Um, really excited to be here with you all. I've mostly been an application and infrastructure developer, uh, my career, but for the last two years I've really been focused on GenAI, uh, MLOps, and then retrieval-augmented, uh, generation pipelines or RAG pipelines.
So, um, yep, really excited to be here and building with you today.
Mastra Concepts2:57
Uh, okay, so what is Mastra? Um, I'll just embarrass, uh, two folks quickly and just point out that we have some core Mastra team members here, so this is very exciting. So you'll not only be able to get some assistance from us, hopefully, but also, uh, from the Mastra core team for any questions that go over our heads.
Mastra is a framework, um, and so it's a framework for building, you know, production AI applications in an agentic manner. And these are the components that we're all going to learn and get hands-on with today in this workshop and understand very well by the time we leave here.
So we're going to build workflows. Just think of them as, um, composable and typed pipelines, which are very exciting. Uh, tools that you can optionally use, uh, and give to agents. Agents are like the interfaces that we're chatting with.
Um, they're the ideal interface for humans to work with. And then, uh, the Mastra framework does some incredibly cool things, uh, out of the box with batteries included that we'll see. Um, so not just, you know, a playground that makes it super easy to debug everything, but built-in persistence, memory, observability, and even, um, evaluation so that you can determine over time how healthy your pipeline is, which is critical for, you know, successfully deploying an AI application in production.
Yep. And we'll be—we'll be focusing on, uh, pieces of this. We don't have time in two hours to go over everything, but there's a lot of really cool tools in there. Uh, so we're going to be focusing on some core concepts for the, uh, example app that we're building, um, and we'll kind of understand some of those building blocks as we get going.
Cool. So let's start off, uh, what are workflows? Um, workflows are composable pipelines. So the way that I think about this is I map it in my head mentally to if a coworker says, "I just keep on having to go scrape the site and download people that look interesting and look up their info and then take an image and then write an email."
You know, that sounds to me like a, a workflow,right? It's a pipeline of discrete steps. You want them to happen in a certain order. And as we can begin to see with this example code on the screen, you can even have control over transforms that happen in the middle of your pipeline.
So the idea is you're chaining multiple steps together to get some work done. You can pass data between steps. And then, very importantly, because as we know, LLMs are incredibly powerful, but they're non-deterministic. And so how do we rely on their output?
How do we coerce their output into something that we can actually build against dependably? That's, uh, where we're going to validate inputs with Zod, but we're also going to learn how Zod can even coerse, uh, at runtime and then handle errors, uh, errors gracefully.
But really, the key i-idea here is that workflows are a discrete set of ta uh, steps to get a task done.
Yep. And the, the API is very similar. Uh, it reminds me of, like, RxJS. Like, very similar. You're starting with one thing and then doing something and then mapping to something else and then doing something else, uh, and running through all of that to give a little bit of determinism to the, the call of all of these tools as they're being called by your agent or some other tool.
Um, and speaking of tools, uh, tools are just functions that agents can call. Uh, they can give you things like file system access, API calls, database queries, uh, custom business logic. If you've used MCP, uh, MCP calls tools, and, uh, so that's like a really cool thing.
It gives the, the LLM a bit the ability to act on your behalf or to read in data that it doesn't just inherently know from its latent space, uh, so that it can do more things and be more powerful for you.
Yep. Um, absolutely. I'll just say that, you know, we, we think of, like, uh, AI systems getting better the more data and context they have access to. And, and one of the things that MCP is really excellent at doing is, is giving granting context to Claude to OpenAI, uh, that it normally wouldn't have, and that's not in its training data.
Yep. And one note for today's workshop: we did build everything using tools, uh, but then we switched as we brought in an agent, uh, to call, and we had the agent call a workflow rather than the tools independently.
So we wanted to touch on them there. There's something powerful that you should look into on your own, uh, and figure out your use case for them, but we didn't really use them in, uh, the final version of this workshop.
Um, and then finally, what are agents? So we've all probably seen and used the chatbot, um, type demos, but, you know, the way that we're thinking of agents, uh, these days is really that they're kind of an ideal human interface.
So if I set up a workflow, that's a deterministic set of steps to get some discrete task done for my colleague. Let's say that my colleague is in a hurry or they're busy or they're doing this while they're on the phone or they're not technical, then a chatbot can be an ideal interface for that human colleague,right?
Because they can describe their problem or their issue, what they need, with natural language, and then the system can be smart enough to actually do what they want. And so this is the core—this is a very, uh, core kind of pattern that we're seeing in, in a lot of, um, AI applications.
And so we're actually going to build this and understand this here. So after we create our workflow, we'll create an agent, and we'll grant that agent the ability to call the workflow.
Yep. And agents were something that when I first heard of them, like, it like in a lot of these things, like the, the naming adds more confusion than is really necessary. And we spent, like, an hour on the phone call, and I kept being like, "But what is an agent?
What is how is that anything beyond just a simple prompt?" And it's really like the marriage of that prompt plus the workflows or the tools that it can use, uh, to do things in a specialized way.
Yeah. The other way I think of it is like if, you know, in the past, maybe five, ten years ago, you might have written deterministic, more deterministic software. With agents, you're expecting that the system overall can kind of interpolate or can understand, introspect what's the state, and then make a decision, um, in like a graph sense of, "We need to actually go here."
So, um, that's the other piece that you'll hear when you're discussing agentic systems.
Yep.
Cool. Uh, another thing: MCP or Model Context Protocol. I told you I'd show you how to spell it. Um, this is a way for you to—it's an open standard for a way to bring, like, universal plugins or these tools to AI agents so that they can be called.
Uh, this was really developed, uh, by Anthropic, and you can use it easily in Claude Code, uh, among other places like Cursor, um, Windsurf, I think.
Yep.
Uh, and even OpenAI is, is, uh, adopting these tools as well. So it's really a nice, easy-to-use API that these tools know how to use and call.
And to also make it concrete, like you—so you work on the DX team at WorkOS. You're constantly crushing a ton of, of bugs in all various SDKs, and you use Claude Desktop,right? And so, like, what changed the day that you enabled the, the GitHub MCP server for Claude Desktop?
Yeah. The GitHub MCP server was the one that really, like, made me understand what MCP is doing because I was like, "Why do I want to do this? How is this different than just, like, having access to GitHub and, and, you know, calling all of that?"
But it's really an easy way for me to have a conversation with Claude and for it to bring in the context that it needs based on the tool the, uh, issue that I'm working on. For example, if you have an issue on a, a GitHub repo, I can just say, "Hey, can you check out that issue and tell me, uh, you know, here's my example app.
Tell me how I might reproduce this." And it can, like, go figure that out, pull in the comments, understand what's going on, link out to other repos or other examples from there, and then, uh, look at my example repo and tell me how to, uh, to make that change.
Cool.
Speaking of MCPs, uh, we built a fun little demo called MCP.shop. You can go there now, and you can use MCP to order a shirt. And it's the only way that you can order this shirt. And for the low, low price of $0, you can get an MCP shirt.
The, the point is you just have to use the MCP. So it's just a fun demo to, to try out MCP, play with it.
Yep.
You can add it, uh, it has instructions for adding it into Claude or into any of the, um, MCP servers, uh, sorry, MCP clients that support it.
Yep. Totally. Uh, I'll also mention that recently, so MCP is, you know, one of the protocols that's really hotright now in, in the AI space, um, and a lot of folks are, are taking notice. We recently had an MCP night, and it was at the Exploratorium.
It was a ton of fun. We, we blew out, like, the capacity of the event, um, and we had people, like, lined up around the block, which we didn't expect. Um, we're almost certainly going to do something like this again soon, so, uh, be sure to follow us if you want to hear about it.
Um, and yeah, we'd love to see you there in the future.
Yeah.
Allright. Um, what we're going to actually build today, though, to, to get into it, is the AI meme generator. Um, so we're going to, uh, if you imagine the input to this is going to be you venting any random frustration, workplace frustration, frustration with your colleagues or boss, um, into the pipeline, and, uh, the workflow will process your frustration.
Meme Generator10:45
Um, it's going to find the best base meme that already exists that would be ideal or might be humorous. It's going to think about how to, um, actually edit and, and create new captions, and it's going to publish a new meme at a stable URL that's, uh, available for you.
And again, I just mentioned, like, this is a toy. We've got two hours. It's a quick demonstration. But the patterns that you see here and the Mastra framework are, are definitely, you know, AI, um, production ready. Uh, we'll use OpenAI just for the understanding, and ImageFlip is the only other API involved here, which you can get free, uh, username and keys for that, and there's information in the workshop MD file for that.
Yep. Yeah. And it's a really fun demo just to kind of showcase some of the tooling that you can do with Mastra, uh, and how easy it is to really get all of this going, but also not just to get your, your tools going, but to test them very easily along the way.
So we can start with just, like, a single step in a workflow and test that without an agent. And then we can test the agent independent too. And we can do all of this and not have to have, like, a full picture, uh, to understand how it's going to work, but kind of iterate along the way.
And the tooling that Mastra provides is just super nice. That's why we love it. We're also huge fans of TypeScript, which makes it awesome as well. And so, yeah, it's just nice and easy.
Yep. Absolutely.
Okay. This is the way that we've structured this, uh, workshop. And so, you know, we weren't really sure the level that everyone's coming in at, and some folks are experts and some folks are just getting started. So, uh, it's self-paced learning, and you can go at the speed that you want to go.
If you want to go and fly all the way through it, you're free to do that. Workshop MD in that repo is the entirety of this course, and so you can kind of follow along that way. And then we also created, uh, Git branch checkpoints for you.
So in case, for example, you're to fall behind, uh, you get stuck on something, and then we get to phase two, you can also skip to phase two and stay, stay with everybody just by, you know, Git checking out theright branch.
Um, if you get uns uh, if you get stuck at any point, we're here to help, so please raise your hand. We'll come around.
Come to the mic.
And then if you yeah, if you have questions that other folks likely have or might benefit from in the future, please be sure to come up to a mic and, uh, we'll make sure that your question is heard.
Uh, and then, you know, the other way we're thinking about this, this workshop is, again, it's, it's a anyone can read online. We can all talk online anytime, but we're actually here in person today. So, you know, please shout out questions and raise your hand and ask us things you want to know.
Um, we feel that understanding is more important than completing stuff here, and it's okay to explore, so.
Yeah. We're all very new to this. This is all very new stuff, very new tools, and it's very cool. It's also changing every single week, so it's, uh, it's fun, like, snapshot in time to play with this stuff.
Um, and if you have, uh, like I said, you, you don't have to finish it. Uh, we do have the whole workshop.md that you can follow step by step all the way through to the end, uh, and then those, those branches to, um, to get us there.
And if you just look at the main branch, that's the completed version, but it's more fun to build along the way. So with that, let's get started. Um, like I said, everything is in the, uh, workshop AI agents with Mastra channel on Slack.
So if you're in there, uh, you can go grab it. There's also, uh, the Git clone commandright there to grab the repo, and, uh, we can get started with that. Um, just go to the step/step0 branch. That has everything kind of as a baseline to start from.
Workshop Setup14:12
Uh, and then you can npm install from there and get going with the workshop.md. So here, I think we can stop and, uh, you, you can get started. We'll give you some time to build. Um, but if there are any questions, um, please come to the mics, and we'd be happy to continue the chat.
Hey, I had a quick question.
Yeah.
Um, so the before you were you showed the example of an agent and.
Uh-huh.
Workflows. That's kind of different from what I'm used to seeing in these, like, agent SDKs where they usually have tools.
Mm-hmm.
So is the workflow kind of like a tool that I can use, or?
Yeah. I mean, to I feel like correct me if I'm wrong here. I feel to some degree that, like, the create tool and create step APIs are, are somewhat similar. And in my mind, at leastright now, it's sort of like an organizational preference.
Like, if I have a simple, um, use case and there might be three different tools, and I want the agent to decide theright time to call those tools, I might create three separate, mostly fun essentially functions, name them tools, grant them to the agent, and then start chatting with the agent and ask for things and let the LLM determine at runtime which, which ones to call.
The difference is with the workflow is I'm saying, "I always want you to proceed in exactly this sequence with these steps and these transforms." And then you can also in Mastra, at least, you can optionally grant an agent the ability to call that workflow.
So and then also in my conversation recently with, with Sam, that's kind of like, you know, these are these are various tools that you can build up and, and kind of assemble into the exact, uh, paradigm that you need.
Can you do both tools and workflows? Like.
I think so. Yeah. You can grant because, uh, it's basic like, you, you're passing, like, this giant, uh, JSON object to the agent saying, "You can call these tools and you can call these workflows." And then.
Cool.
The tricky part is, like, if you give something 100 tools and then ask an LLM, like, "You've got 100 tools. Let's, like, go to Disneyland." I don't know exactly what we're going to get out of that, but that's where, like, the determinism of a of a pipeline can be of a a workflow can be beneficial.
Cool. Thanks.
Thanks. Great question. Um, anybody want to raise their hand? Any, uh there's no shame here. Anyone having difficulties getting started, um, need help with that?
Permission issues? Do we expect to have another version?
No. Not at all. Uh, what's the permission issue? I'll come by. Uh, yeah, the repo should be fully public. Um.
Yep.
So should be able to clone that.
While Zack's doing that, I will also bring up the, um, Mastra docs, um, because these are oops. These are wonderful. Uh, they're really easy to go through. But also, as, uh, Zack and I were working, we, uh, discovered something that was actually really awesome, and that is the MCP doc server.
Um, once I installed this, things like got my tooling got a lot smarter and knew how to work with Mastra, and it made things way easier. Uh, so if you get stuck or if not and you want to see MCP in action, I would recommend installing, uh, the Mastra tools for your IDE.
I installed it into.
So we did.
Claude Code and into, um, Claude Desktop and played with it in both, and.
Oh, no.
It immediately knew a lot.
It was easy for the workshop.
Okay.
Gotcha. You can can you clone with HDPS? Can you clone, um, not over SSH? Try the HDPS.
What specifically? Um, so if you if you go back to the repo, uh, look at the GitHub repo, like, in the browser, it should have a different option. Oh, you found it,right? Yep. So what do you want to do?
Um, so go to github.com, WorkOS, and then Mastra agents. You have to change that from a colon to a forward slash thing. So, like, grab this whole grab everything after the ampersand.
Where's my ampersand? You mean after the at? At the at. Sorry. Yeah. Grab everything after that. And then go, yeah. And then go up here. And so, uh, make put together change the URL. So do HDPS.
And then github.com. Yep. And then change. Yep. Hit that.
Sorry, I'm having trouble seeing the.
Oh. You're doing well.
Oh, that's why.
Go ahead.
Thank you. Um, it searched for that URL instead of going directly. So make that a HDPS. And then change this from a colon to a forward slash and then get rid of that final Git dot Git. That should go.
Okay. Now this. If you hit there.
And then go local. You should have that option. And then.
ChatGPT, welcome to his office.
Come up and HDPS version of the GitHub repo.
Oh.
Because people are getting confused and they don't have SSH configured on their work laptops.
Yeah, it's.
And no one knows how to get to the repo for it.
Yeah.
Anybody else, uh, any setup issues or everyone, everyone good?
I'll post the HTTP, uh, s clone command in the.
Yep. Thanks.
Uh, in the Slack as well.
Yeah. In case anyone's having trouble with, um, SSH clone because you're on a work laptop, we'll, uh, put in the instructions for HTTPS too.
Do I do it at a time at a time set? Do I do it at a time set? Like, do we do it at a time? Oh, yeah, we're doing it. We're ahead by five minutes.
Cool.
Allright. We're going to do about five more minutes setup. Um, feel free to raise your hand if you have an issue. Yeah.
Actually, it's not too bad. So just use all packages over the table. Yeah.
Oh, sorry. What's that?
Oh, the Wi-Fi's bad.
The yeah, the comment is the, the Wi-Fi is bad. Uh, I wish we could do something about that.
Sorry. Sorry. Yes.
Classic conference Wi-Fi.
For Claude Code, yeah. Um, you if you open Claude Code, you just need that. You still need that, like, JSON object, I think. I mean, that's what I use for my MC client, but it should, uh yeah.
Yep.
Allright. 65, version 65, 65.
Going to do about two and a half minutes until we move on. Anybody have any issues? Everyone good?
Slow internet.
Slow internet still. Okay.
Yeah. We can give more time. We got.
We'll do a queuing system. Everyone turn off their Wi-Fi. One person download packages. Move to theright.
Put it on a flash drive and then we'll pass it around.
Yeah. That's that'll be a sneaker net.
The repo's 77% cloned.
Nice.
Yeah. Get in there.
This guy clones.
Whoa.
We will. We, we can give more time.
Excellent. These are great numbers.
The end goal of this first step is really just seeing the playground, and we'll kind of show that here in a minute.
Yeah.
Uh, but it's there's not going to be any tools or agents or anything yet, and we'll build those out. Uh, but it's just seeing kind of what Mastra gives youright out of the box so that you have everything you need to get going fast.
Absolutely.
That's kind of less press 60. I think it won.
Question.
Press 60 or 75?
Yes. Why, why Mastra compared to all the other frameworks? I can tell you why I'm excited about it.
Why?
So the first couple of things I heard were pure TypeScript,right? And I'm already kind of bought into that with I like compilers finding my errors before I ship them. Um, then there's, uh, the Vercel AI SDK that they I think that the team wisely chose to build upon.
Um, my experience with that has been excellent. It's kind of mind-bending to kind of wrap my head around. But the idea that I can multiplex between any LLM provider. I mean, when, when GPT-4.0 came out, I shipped a two-character change in a PR, and my entire pipeline got way smarter.
And that was the day where I was like, "This, this SDK." Then I found out that the, you know, Mastra came out and it was like Vercel AI SDK and, uh, pure TypeScript. And, uh, I can tell you that there's a ton of stuff that they put in there, like including evals that are just, uh, baked in.
So that's one of OpenAI's own recommendations about theright way to deploy agents at, at enterprise and at scale, uh, is to start with a evaluated pipeline. Um, and I can also I can tell you from working in, like, vector database companies too, that that's people that are actually in prod are, are using evaluations to determine the health of their pipeline and the health of each individual generation.
And Mastra has those baked in. So it's like, import and then, like, also evaluate my pipeline. And then finally, so it's like because of that, um, and it's on the Vercel AI SDK, then being able to deploy it quickly, um, and then have a good experience that way too.
And, and honestly, what we'll see just in the, the local, uh, playground was pretty great. Um.
Okay.
Yeah. Very complete in my in my experience. Like, every everything has issues, but that was the experience I've had with it so far.
And real quick.
Yep.
Uh, I think that for me, like, TypeScript's moving fast with that. I still don't have to figure out what pip is, so it's prolonging that.
Prolonging that.
Um, but also, like, we had how many of you have had these, like, come-to-AI moments within your company? Like a big, "Hey, we're going to have everybody, we're going to work hard with AI."
We're all doing AI now, whether you like it or not.
Yeah. That Shopify post came out and then, like, we had it. Uh, my wife's company's had it. Like, everybody that I've talked to, like, "Oh, we're, we're going to have this meeting where we're going to do everything with AI.
We're going to see how AI can, you know, solve every problem in every domain." And, um, after we had that, we did like an open workshop thing and we had, uh, like immediately we showed Mastra and then we had like 10 people just like.
10 individuals.
Start going off with 10 individual demos and it was just like fast.
That'sright. And because they successfully built the exact workflow they were looking to build. And so then for me, the reason I'm the most excited about that piece of it is that I think it's an ideal platform for internal tooling.
I think all of us are rapidly experimenting with this stuff. And, you know, do I want to live in a world where Nick's writing bespoke LLM scripts while I'm sleeping and I wake up and I'm like, "What is this spaghetti mess?"
And he has to do the same with my, you know, crap or, or are we all using yeah, I'm bad. Or are we all using like, you know, an actual framework that we can agree on certain primitives? It makes us faster to use.
There's, there's even forethought I can see, um, in, in the way it's been organized so that once you've defined an agent, a different project can reach in and call that agent via code or API. So, um, all those reasons, I'm kind of excited to use it as sort of a unifying internal tools platform.
But we'll see. Uh, yes. Yes, sir.
Yeah. Just a quick question on steps.
Yeah.
This might be a little premature, but, um, step one, number five, where you so you create a workflow, you pass a discrete array of steps.
Mm-hmm.
Um, which of which there's only one, which makes sense to me. And I would think you would just I guess I'm asking the desi the design decision behind then needing to just also explicitly do test workflow.then and then invoke the step.
Yeah.
Is that not implicit in the array of steps?
That's a good question. The commit the ergonomics around are you asking about the ergonomics around the commit method itself? Like why I actually have to find the commit?
Right. Why, why explicitly say, "Here's workflow."
What is what is going on? What's the gentleman, what's the decision behind that? No, I'm just kidding. I'm sorry. I actually don't know. Um, I've looked at it recently and I actually checked that API today.
I'm just curious.
Because I was curious about the same thing. I was like, "Oh, does it return?" I actually argued with Nick because he correctly said, "No, it commit finalizes your pipeline, returns it." And I argued with him incorrectly.
Gotcha.
So I'm not certain. What's the what's the final idea behind commit?
Uh, that then I mean, so for sort of the local dev server, it's kind of like a visualization. Um, so the commits like page.
It's synchronized. It's synchronized. It's synchronized. Okay. Got it. It's the final step that's like actually creates the whole object and adds the steps and returns the final output. Okay.
Gotcha. But why sorry, I don't mean to berate this, but like why the .then and then the name of the step? Is that is that step not already in the workflow steps array there?
Uh, so we should be able to, um, so there's, there's sort of two ways of defining steps.
Can you I'm sorry. Would you mind coming to the mic? Just so we sorry. I apologize.
No, no, no.
So there's, uh, there's two ways of, uh, coming to of defining, um, steps. You can either give it a step array, um, which as you might expect is kind of, um, the most a lot of times we just have these linear pipelines of steps.
And so you can just give it a step array and it will execute things in a linear pipeline. Um, or if you want to add sort of like branching and conditionals and a lot of that kind of thing, um, we have this like fluent syntax where you can do .then and then you can do .if.
.branch.
.do.y and like loop and, and do conditionals and, and all the fun complex stuff. You know, but a lot of times you're just you're running through a pipeline. So the steps.
Do you do you also just do test workflow.commit and then it would run that.
Yeah.
All the steps?
Yeah. Yeah, yeah, yeah.
Okay.
For, for what it's worth, I have also recently had the experience where I had built two different GenAI apps like experimentally internally and realized that I had implemented a pipeline concept in both of them. And that was another reason why I was like, "Okay, I'm excited now about a single framework with one pipeline."
We're learning.
Yeah.
How are we doing on time?
Okay. We mostly got packages installed or still waiting on code.
Anybody get 200?
Yeah. Yeah. That added to the odds.
Nice. Nice. Okay. Excellent. And you're selling access, uh, for $5,right? Okay.
Do we have any more time?
I think we're good.
Allright. We'll kind of show what's, what's happening. Um, feel free to keep working on it. It's not, uh, you'll be able to catch up quickly or you can skip to the next step, which I'll show here. Um, oops.
Allright. So I'm going to just, um, switch over to steps/step, uh, one, which is the end of step zero. That's where it would bring you to. Um, and so
I don't know what's happening. Okay. Nope. I'm not on.
I think it's like switch.
There we go. I didn't know how to spell switch apparently. Um, okay. So once you have it all installed, then, uh, you really should just have kind of a Mastra index. It also has memory, um, set up for you automatically.
Uh, but this just creates the Mastra instance. Um, currently we have nothing enabled, no agents, no workflows, uh, no tools. And that's okay. And when we oops. When we run npm dev,
uh, we will get this URL, localhost:4011. And if we go there, this nope. This is the, the end of step one, which is maybe there we go. Uh, you look here, you have agents, networks, tools, MCP servers, workflows, and then this runtime context.
And currently we have nothing in there. Um, and that's currently by design because we've done nothing. We've just gotten the project set up, but now we have all of these tools to help us with building along the way.
And so, um, once you get this set up, uh, you should be able to switch over to step one or just continue on in your branch. I think it might actually be the same because it's just npm installing.
Um, and then you should be able to continue on in the, uh, the steps.
Uh, this is I'll just say that this is one of my favorite things though about Mastra, like the local playground. And if you look in the console, you'll see that there's also a couple other things spun up. There's the API endpoint.
There's also an, uh, Swagger spec that you get automatically. And so, like, the amount of thought that's been put into this, and you can see how once everyone's comfortable with it, you could, you know, very rapidly deploy applications in a standardized way that other tools can consume, uh, reliably.
So that's, um, another exciting feature of it. And again, this is like without us having built anything yet.
So the goals that we're going to do in, in step one now, uh, is just create our first workflow. And this is just a very basic workflow. We'll end up throwing it away, uh, but it's going to be one workflow with a single step and it's not going to do anything else, but we'll see kind of the power of it.
Step 1: Workflow34:27
Uh, and then we'll build upon that in the next step to add additional steps. We're using steps a lot. Um, and then we will, we'll, uh, be able to put that together into a full workflow in the next step.
But we will more importantly, we'll be able to see it in the Mastra playground and start really seeing the power of that.
Yep. Testing.
As always, any questions, uh, feel free to shout them out. Anyone get stuck, just raise your hand.
Yep.
We'll run past.
We really tried to give ample time for this, not, uh, not including Wi-Fi issues. Um, and so, um, yeah, if you have questions, we'd love to, to chat or just ideas of this stuff because I think there's a lot of really cool powers, uh, that you can do with this.
Sure. Do you want do you want to hop, hop up to the thanks.
Uh, I'm just kind of curious since you're upset using Vim and kind of deepen the hole.
Yeah.
Have you played around with any of like the AI integrations into Neovim? Kind of like how what's your current workflow?
Yeah.
What are you kind of adopting?
I thought nobody would ask.
What have you done?
Um, yeah, I'm a big fan of Vim. I haven't used Cursor yet at all because it's not Vim. Um.
There's Vim mode.
It's not great. Um, but I have played with the tools. There, there's one, I'm forgetting, a goose, I think, that in Vim. I haven't played with that one yet, but it's on my list to play with. Uh, the one that I have played with is Avanti, uh, which I think I have still set up.
Uh, yeah. So it gives you kind of that like chat-like interface here. So I can just start having, uh, a chat with this code. Uh, I don't know.
There's also was it NeoAI? Have you used that for Neovim? Even a year and a half ago, you could do that before, before most of the tools allowed you to chat in IDE.
Yeah.
Yeah. That's always going to be the benefit of open source. Is it lands first,right?
Yep. Um, but I honestly, like, I didn't like the ergonomics of playing with this and like switching buffers and things like that. And I honestly felt that, uh, for me, uh, a better workflow was just not using this at all.
Uh, I'm also a big TMUX user, so, um, you know, I will have like Vim open and then I'll just open a split and Claude, Claude code, um, gives me that kind of the same thing. And it's often like its own TMUX split.
So I can work in Vim as I normally would without like weird buffer things. And then it's just off doing things and I can, uh, you know, oops, use, um, use TMUX to like full screen Vim when I need it.
Claude's out of the way. And then when I want it, I just bring it back in and go.
I would also be interested in hearing how all of you are using these AI tools just for like not just what you're building, but how you're interacting with them day-to-day because they're changing our workflows. And I feel like everybody's like in their own bubble doing their own thing.
And then we like we have this opportunity to come together and learn like amazing new tips and tricks.
Yeah. I'm all for that. I, I don't know that I'm all for everybody getting on the same, you know, uh, plus.
Yeah.
I think I think it should depend on, on, you know, product or, or, you know, service or whatever, but, um. I'm, I'm afeared of, of, you know, somebody coming down from on high with like this is the golden framework.
Everybody use this.
Yeah.
We've been through that for decades.
Yep. For sure.
So that's my personal.
You like to mix and match and let everyone kind of choose their own lane. That's exactly.
Even with coding agents.
Yeah.
I'm, I'm like here and there and everywhere.
Yep.
AI, same thing. Here and there, everywhere.
Yeah. To, to summarize for the video, mixing and matching tools is good. And I think that that's really what is like powering thisright now, especially among like us hackers,right? We're like there's all these cool new things. It's a whole new world of figuring out what to do, how to do it.
And you're not just being prescribed. Oh, just, you know, go use random. I don't want to shame any specific editor, but like.
Not anybody specifically.
Yeah.
Yep.
But I mean, the leaders come forward.
Yeah, for sure.
You have those choices, you know.
For sure.
Absolutely.
In the meantime, I'm going to play around.
Yeah.
Yeah. It's all about experimentation, I think. Yep.
Yeah. There's all sorts of experimentation, all sorts of fun. Um, and, and the, the winners will bubble up for sure. Um, also, I, I do worry that it's like, uh, you know, the, the first hit is free and then we're, we're all like, oh no.
Becoming dependent on it now.
Yes, sir.
Uh, question for you guys. Do you have a framework specific like set of rules like that would integrate not that everyone has to use Cursor, but just like also in like, um, at my company, we've started to essentially say, "Hey, here's the top 10 tools that we use and here's Cursor rules to do all those the same kind of way."
And it's not so much trying to like box people in, but it's more trying to say, give them like in Mario Kart, it's like you get the, the three booster packs. It's like how can we give people, people booster packs from the beginning?
Yeah. We, we were talking about this earlier actually with Nick Taylor. Um, we were talking about like Cursor rules growing and evolving kind of like tests. And then it's like this thing that, that evolves with your, your code base to prevent you from doing bad things.
Um, I don't know what that means though 'cause I've never used Cursor.
It's not exactly the question you asked, but I will just say that that's also, uh, like when you run, you know, npx install Mastra, it asks you if are you going to use Cursor? Are you going to use WinServe?
'Cause if so, I know I can inject the MCP server for our docs. And then the experience that I had after accepting that, I saw it's like, oh, it enabled that. I checked in my MCP in, in Cursor.
And then that session where I coded, um, there were zero hallucinations. And so that means that every time I asked for a feature, it was one-shotted correctly. Furthermore, because it was in TypeScript, I could quickly lint it and compile it and know it was good.
And so that's almost like I we were almost starting to Nick and I were starting to suspect that MCP might be more powerful because the other problem is that Cursor rules are specific to Cursor,right? So what if like half your team's on WinServe, half's on Cursor?
You know, we've got tons of licenses for Cursor internally, so it's kind of like, but it's not prescriptive. I think the MCP doc server so far is more powerful of a pattern because it is the it's almost like the, the guarantee that the end user dev is going to get your latest docs and is not going to get a hallucination.
And I really wonder if that's like, like there's so much excitement around that. We saw that at MCP night a couple weeks ago. Like there's so much excitement around that. And I'm, I'm just starting to wonder, is it really just because it's like a standard emerging, um, and that's the reason?
'Cause it's, it's very simple. Uh, but it's, it's enabling all of these tools across, you know, it's not just an Anthropic thing anymore.
Yep.
Uh, which makes it super powerful.
Absolutely. Totally agree. Yes, sir.
Yeah. I'm not sure if this is a better question for y'all or for the Mastra team, but I saw that Mastra has experimental support for ingest, which is a durable execution backend, but that it's labeled as experimental. And I was curious like how experimental that is 'cause I'm.
Great question.
Really excited about durable execution for agents. You know, if you've read the 12-factor agents manifesto, it's really good.
Oh, no. I haven't. Where's that? Who published that?
Uh, it's on GitHub. Uh, Dex from Human Layer. Um, originally did a lot of the work on that. Um, but yeah, just was curious about jamming on that.
Awesome. Great question. Thank you. Unfortunately, we haven't the folks in the room for that. Okay.
Yeah. I'll, I'll send Dex to shout him out. He'll be happy to hear that. Um, uh, so the we shipped in, uh, sort of a what we call workflows VNext about three, four weeks ago now. Um, the idea being that basically it allows you to have the same syntax, but switch out the, the workflow, um, engine.
So the first, um, the, the first, uh, integration that we shipped, we, we sort of initially had we initially built our workflow engine using XState as a backend because it kind of makes sense. Um, and then we kind of we, we need to make a couple of syntax changes.
And then we also kind of realized that, uh, people started asking us, "Hey, like I love the syntax, but I'd love to have this work with, and I love the visualization in the dev server, but I would love to have this work with ingest or temporal, um, or Cloudflare workflows or dot, dot, dot, dot, dot."
Um, and so we're like, "Yeah, that's a really good idea." So then we shipped workflow VNext that was like again, three, four weeks ago. And then now we're just starting to, you know, do the list of integrations. And so ingest is first.
Um, it's you should use it. Like it's experimental 'cause we shipped it like a week ago, but I would be surprised if the API changed after a week from now.
Thank you.
I actually have a question. Um, just curious, what how is the team thinking about, uh, deployments going forward? Like are you targeting specific platforms first? Are you going serverless first? Like are you thinking about trying to go everywhere?
Like what's top of mind for you there?
Uh, so by default, um, by, by default, like Mastra will bundle into a Hono server. Put the Hono server in a Docker container and put it on EC2 or DigitalOcean or wherever you want to put, uh, put it.
We also have adapters, uh, for Cloudflare, um, Netlify or Sal. Um, we also heard on, uh, Mastra Cloud. Um, we also so those are kind of the two, um, you know, the, the two we also like Hono's not a, you know, if you want to use Hono great, but also you can put it in Express or, um, whatever, whatever you can, um, you know, put it in the backend of a, you know, Next.js operator app, you know.
Uh, in general, I think like you can't really I mean, you can call it open source and it cannot work everywhere, but like these days you should actually make it work everywhere. So that's just our philosophy on things.
Yep. Awesome. Thanks. Yes, sir.
Certainly. Yes.
Hi. Hey.
Okay. And then, uh, what's the full error?
I was going to say I heard my hands shirt for you.
Oh, nice. Yeah. What are your MCP shirts?
Such a fun demo.
So we have 74 minutes.
Yep. I think we're good.
Um, I had a question. So I saw I was just reading ahead a little bit. Um, so I noticed that you sp you're specifying like Zod schemas, but also adding instructions to the prompt, um, to kind of follow that schema.
Yep.
So I was wondering, is there anything sort of inbuilt into the framework that ensures that the output of each step matches the schema kind of by default? Because what if like you specif like, you know, let's say in the prompt you've you kind of forgot what your schema was and you like how does it reconcile that as well?
Yeah, great question. Um, so I, I think the answer to that is essentially the Zod schema,right? And the way that I look at that is, um, like LLMs are non-deterministic. That's part of why we love them. But then it's at the point where they're so useful, we're trying to get specific JSON out of them while coding too,right?
And the Zod, um, package and, and like validation library is now ubiquitous in AI engineering, at least in JavaScript. Like you'll see it literally everywhere. So it's doing the work under the hood. Um, my understanding is that the OpenAI team couldn't get to a certain level of accuracy without adding on top of training the Zod, uh, runtime validation, which can also do coercion into theright types.
So that's kind of doing the heavy lifting there. Um, I don't think there's anything framework specific that's doing structure generation, but correct me if I'm wrong, but you can define like the transform steps between the workflow.
Um, yeah, there's actually we actually just did a blog post on this, but it's funny that the models don't always actually respect the schemas that you give them, especially there's some, you know, yeah, okay, z dot string, like they'll respect that, but if you, you know, z dot string dot, you know, length, you know, four or whatever, like they're not necessarily going to respect that like level of, of nuance.
Um, so we actually added, uh, uh, we, we added sort of for, for this is especially challenging. This is mostly works, works reasonably well with structure generation. It's more challenging with, with tool calling, um, for reasons that are not quite clear to us, but we're clear when we ran 16, uh, you know, uh, with the 30 schemas across 16 models.
So we added like a tool compatibility structured output layer that reduced that like reduced the error rate a lot.
Um, so in addition, on top of the side, like there's also Mastra side like optimizations to ensure structure generation.
The, the longer version of this is in a blog post we published over the last week if you're if you want to dive into the, the details.
And I, I don't know if it's related to this, but one thing that we were running into constantly, uh, while we were developing this was, um, we were like, as you'll see, we were accidentally sending, sending like a base 64 encoded image, uh, which was huge and, and failing, and it would retry a lot.
So I assume that there's some retry logic built into it to if like it wasn't getting back what was expected from the schema. Um, is it built into the, the schema validation piece?
I mean, I would assume probably what was happening was that the agents has like a max steps.
Yeah.
And so you was running until in a loop until it hit max steps.
But I, I guess what I'm asking is if you, if you said, "I want a string that's length four," and I, it gave back a length five, would it automatic would Mastra automatically retry?
There are cases in which it would, it would retry. I don't know if that particular case is one of them.
Okay.
Yeah.
Does that?
Yeah, that does answer, um, my question.
Cool.
To kind of to add to that with if you were to specify, uh, certain things into the schema that aren't inherently like supported, for example, the, the length, would that, um, would that be kind of error? Like would that error be displayed in compile time at all?
Uh, let's try it. I don't know. I, I would expect Zod to coerce it actually at runtime, um, but I'm not sure.
Usually the model will fail silently and just give you an output that doesn't conform to the.
Okay.
To the, um, to the, uh, to the schema. And we kind of made a decision, should we error or not? And we're like.
Makes sense.
You, you maybe you should decide if you want to error.
Yeah.
Allright. Thank you.
Thank you. Yeah. Great question.
Sorry, just talking about deployment again, I, I noticed the serverless deployments, there's no like AWS Lambda or anything. It's all through Netlify or.
Yeah.
Um, there's also an AWS Lambda, um, deployer that the community had.
Okay.
If you, if you Google, you'll probably find that you have issue.
Okay. And how does the, the serverless deploy work? Does each step kind of map onto its own Lambda function or how's that?
Yeah. I mean, we just sort of pack bundle it in a, in a, in a, a platform specific way that works for those platforms. So like Cloudflare has like a 300 meg, um, uh, bundle size limit. And so we need to do some specific things to get down under that.
I guess I'm just meaning in terms of the runtime model, each step kind of maps logically to a function or are you putting multiple steps inside a single function?
I did not work on that part of that.
Okay.
So I was just asked for it.
I'm assuming they're all bundled into one, but could be wrong.
I mean, I, I think they are all bundled into one, but yeah.
Really? Okay.
Yeah.
That would just be weird for long running stuff 'cause there's timeline or something.
Yeah. I mean, we, yeah, that's yeah, we, I think we, we, we all, we bundle it all into one. I'm pretty sure.
Okay. Thanks.
Cool.
How are folks doing on step, uh, step one?
Good.
Good?
Awesome. Okay. Allright. We got functioning Wi-Fi. Excellent.
So we can kind of show that. I'll go to, um, step two. Did I spell thatright? Yep. Uh, which is the end of step one. Um, and so now like looking at the code, uh, we've got if I update this, we've now got our test workflow in our Mastra object.
Step 2: Pipeline53:07
Um, and then we've got a workflows directory with the test workflow and the schema for it. And it's just going to have you, um, basically extract from the user input, uh, the type of frustration that you're experiencing. And the really cool thing now is like without building anything else, uh, we can go to our Mastra playground, refresh it, and go to workflows.
And now we've got our test workflowright there. And you can see the graph here isn't very impressive with just one step in the workflow, but it's there. And we can see that it would accept a raw user input about work frustration.
So does anyone have a work frustration?
Use your, your boss by name, please. Please state the company you work for and your boss's name. We won't tell them.
Conference Wi-Fi sucks. Not really. This is a great job, AI engineer.
Um, in general, sometimes though. So we can see just by calling that, it turned green in the, in the graph. And you can see that we click on it and we can see that that's the input that we gave.
It ran the step and it gave us back this output, this, uh, JSON object. Uh, and we can see with the text, conference Wi-Fi sucks. The overall mood is frustrated. I think that's accurate. Uh, and the analyzed frustration is technology.
We're so we're frustrated about technology in this room.
So in the next step, where did I go? Oh yeah, here we go. Uh, in the next step, um, we're going to create our frustration schema with Zod, uh, build our first workflow step. No, that's what we just did.
I have my slides backwards. In this one, we're going to, uh, create all of the workflow steps. Uh, we're going to chain them together with data mapping. Uh, and then we're going to successfully generate a meme. Uh, and we'll understand the composition of that workflow as we go.
Uh, it still won't be like the perfect end result, but it will give us the full workflow where we can like kind of plug it in, in that, uh, workflows tool and see it go through all of the steps from our user input to an actual meme that's, uh, uploaded to image flip.
So you can skip to step two, uh, or continue on in your branch and, uh, continue from there.
Oh.
Yeah.
I'm not sure what I'm looking at.
Uh, sorry, can you repeat that?
I, I did the, uh, uh, frustration,right?
Uh-huh.
Put in a topic, ran it, got back to blue box. It's highlighted.
Mm-hmm.
It says input, output, so I put it on output.
Yep.
So I, I got a JSON object.
Yep.
Right? And, and so what is this? Is this something, an object that I would then pass to another pass on?
Precisely. Precisely. And it's justright now, we're just in the early stages of showing exactly that and that you could have structured this object however you want.
Right.
Um, but in our case, because of the pipeline that we're building, this is the data that we found valuable. And so we formed it this way and then we're going to pass it further into the pipeline to do more work based on that.
Yeah.
And so, um, the output is, is, uh,
you can change it.
Totally.
I mean, so I.
It's your, it's your arbitrary schema.
If I want Markdown, if I want JSON, if I want whatever.
Yep. Yep. Absolutely. And that's part of what Zod will help you do too 'cause you can define like, you know, maybe you have some giant object and, you know, this may fields and this is a string and this is an array of strings and all that.
Um, but it's really for you to compose together the exact structure that you need.
You would, you would have to know what the next stage is.
Yeah. Yeah.
So there's a little bit of forethought.
Absolutely. The forethought or the third time you've written that app. You've had enough. You've had two shitty first drafts and you're ready for the third. Um, sometimes I do it that way, but yeah, sometimes I'll plan it out and be like, what's the logical breakdown for these steps?
Yeah.
Yep.
Yep.
The main point of this one is to just determine like the level of frustration and what you're frustrated about so that it can be fed in in the next step to, uh, Image Flips API to get back an, an image template, um, that or a meme template that would accurately fit that.
And then we kind of shoehorn it in from there.
Totally. But the, but again, the, the like I guess the mental mapping that we're all trying to do here too is like to think about how do we take this home and like turn it into something that actually solves a problem or automate something at work so we get promoted before the machines come for us, you know?
That's the general.
It's a race.
Pretty much.
It's a human race.
Yeah, I think so.
And just so we're level setting, this is like the memes that you've seen. Image Flip is a, they have an API for not only finding great memes, uh, but also just having blank templates. So they, they can give us back information about this, the rock meme, the rock, uh, in a taxi meme or whatever.
And those boxes are blank. And then you can post to their API with whatever you want it to say in each of those. And it'll tell, tell you like, oh, I have three boxes. And, uh, then you just post in there.
And that's what we're eventually going to be doing in one of these steps.
But that's, that's a perfect real world example. It's like knowing those box slots is critical to the rest of the pipeline. If any other step in the pipeline didn't know the box slots correctly,right? Like that'd be a problem.
So you can define that in your schema and make sure that it's there. And like that's part of it. Yeah.
Okay.
Yep.
Putting this workflow together too is probably the biggest of the steps.
Yep.
Um, once we have this, we'll, we'll create an agent in the next one, and that's pretty straightforward, uh, as you'll see. Um, and so there's, there's time built in also to, to play with this, experiment, tweak things like the, um, like the prompt.
Temperature.
Temperature, things like that.
Yeah. We'll, we'll look at that in the playground. That's the cool thing is like once we get the agent and start chatting with it, um, you know, like there's just a, a iterating locally is so much faster,right? And that's really what the, the playground's about.
So you can even tweak the prompt on a per request basis. You can change temperature, model, whatever.
Can you get help with the UI?
Certainly. Yep.
That's what I did too. It's just so weird. But try that on the other trip.
It's not unusual.
Okay.
So I was looking at that.
So it's like
slowly. That's great. And from there, you once you get to the point where you remember the answers, then once you get to stuff that was, um,
what I thought is that. So you might not have that back. You are correct at that point in memory. And people like to do work or do you? Okay. So yeah.
Precisely.
Correct. And, uh, now there are other, other for example, for example, the actions are there. And actually we're looking at it in our timeline. And it's looking easy to work. It's a work result,right? But the reason we did this here is that we're not able to do it.
Like you said, we have this chat service. It's
if you can, yeah, and if you didn't have that file open before we added it, you, um, you would chat it and then you'd like either read it or you'd go to the,
uh, the, uh, the, uh, the, uh, the, uh, the, uh, the, uh, chat account.
Yeah.
Please.
We got it. We have it.
Oh.
And why?
I think.
Okay. Good. Uh, did you make a move?
Nope.
Okay. Probably that. And that's the, the, the other trick is when you get the answers, it's not really knowing.
Okay.
And the option of that.
Okay.
So I need to go to image flip.
It's good if I have the, uh, the.
There's Google and GFO history.
I just need to.
Their dashboards.
Stop.
Does it sound like the credentials are being rate limited?
Yeah. So in general, if you get an error.
Uh, at the generate meme stuff and you don't get a clear error message and you have not created an image flip username and password, that's likely the problem.
I did it first.
Sweet. Allright. And then if you sign in with Google, which is the same thing I did, that's fine. And then you just have to go into image flip settings after and set a password because you're OAuthing in, so you didn't get to set a password.
Right. Right. Okay.
So the complexity is in the UI of image flip. Just.
Thank you.
Yes. Absolutely. Let me know if you have another issue. Yes.
Do we need to set it?
So, um, in our testing, like, and also there, there's a public, I think it's for image flip, there's a public key that floats around. So there is an anonymous key that's public. Like Git guardian will flag. Others consider it a secret, but apparently it's not and people are using it.
And the reason that we finally asked people to make their username and password is that it gets you a significantly higher rate limit. And so you're less likely to run into this issue in the workshop at least.
But the error is that.
Yeah, the error. The, uh, what's, what's the specific error you're getting? Is it opaque?
Actually, now, now I'm getting just, uh, like 20. Uh, but I don't know. Just like cannot run.
Oh, if you like, are you on the which branch are you? Are you on the.
I was, I guess I was
on.
Okay. I think we're on two. What, we're on two?
Mm-hmm.
Yeah. I think so try doing Git switch and yeah, just do two. I'm going to just stash all that stuff first. Yeah.
You have no idea the struggles of trying to do a workshop with, with when API keys are involved. Uh, we originally had a step that it would not, it would take an inspiration from an image flip image and then generate a new meme.
So it was a completely unique meme. Uh, but in order to do that, you would have to go in and verify your OpenAI account, which means like you'd have to scan your passport to be able to do it.
We thought that might be a little much to ask in this workshop.
Can, um, can you guys say more about like how you're, I guess, like interacting with these workflows and agents like in the cases you've seen? You said something about Vercel. Like are you deploying them and then contacting them through like an API call or like are they actually embedded into your application?
Yeah. Um, what I'm primarily doingright now is, uh, you're still using the Vercel AI SDK. So everything I've got like at least at work that's deployed already, that's mostly Vercel AI SDK. And then we're building a ton of like internal tooling with Mastra that started like two, three weeks ago.
And most of our stuff goes to Vercel, um, just 'cause we already had that and it's pretty fast. Um, and then most of the things I've built so far are web applications that might have a pipeline. So there's a UI and there's still a user kind of requesting generations and asking for things.
Um, what I think would be super cool and powerful though is like the, the workflows expose like an API endpoint to just start them and hit them from anything. And so I think that's also like a pretty powerful pattern.
I've not really used it really fullyright now in prod yet, but that's, um, something I would think about for sure. Like cron jobs almost. Workflows that need to run like every night, you know, maybe have a cron that fires that or something.
Allright. Cool. Thanks.
Yeah. Great question.
Allright. We got about five minutes and then we're going to move to next step. So if anyone's stuck on anything or has questions, don't be shy.
Does anybody have the memes generatingright now through the workflow?
Allright. 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13.
Nice.
That's amazing.
Post some of your favorites in the, in the Slack.
Yeah. Uh, there's no filters left on them. So if you like what happened, it's, uh, we did it. And if you are offended, it's not our fault.
This is the, when you're dealing with memes like this, it really brings out the non-determinism of, of this. If it generates offensive ones, we tried to, to curb that, but also these AIs are not great sometimes.
People who initiatively want to raise their hands, I'll go around and give you guys folks.
If you want a, yeah, a free, a signed. Are we talking autographs here, Sam, or?
Ooh. Oh, autographs.
We're talking autograph copies. Are they first edition or second edition?
Uh, first edition.
Autograph first edition from, from the CEO of Mastra itself. If you, if you got a meme working and you want, or you just want a book, raise your hand. Excellent.
That's pretty offensive. That's pretty offensive, Nick.
This, this gentleman would like a book as well.
Awesome. Thank you.
So this is the Bible. This is the Bible.
On, on building. On, yeah, on building agents in TypeScript. Got it.
Oh, these are all, this is amazing.
Yeah. I got some pretty racy ones by saying, "Why did they put a systems engineer on an open floor plan with the sales folks that are screaming all day?" That's a fun prompt.
I love this.
That's awesome.
Every project is high priority.
Yes, sir.
So I come from a data engineering background and there's something called DAGs in Airflow, which are for whatever reason culturally they've caught on. Um, as you guys have designed workflows, have you thought of DAGs? Are they similar, dissimilar?
Are you talking about direct-to-day cyclic graphs?
Yeah. Control, what does the control flow look like for workflows?
So far, uh, stuff that I've, I've seen, you know, supported by the semantics of like a, a Mastra pipeline. Honestly, um, to be perfectly frank, the place that my mind goes with that is just graph RAG, like a graph plus retrieval augmented generation.
So like some vector database plus a graph, knowledge graph to like do traversal, um, to also answer like structured questions about entities in addition to like semantic search capabilities. Um, that's honestly what I've built mostly or seeing people kind of like, uh, like positing is going to be a next-gen architecture.
But so far what I've needed has just been pretty simple pipelines. Basically run these steps, branch over here if this happens. Um, you know, I see the DAG is like, that's like Terraform in my mind from, from DevOps like land of like it must proceed this way and the entire thing fails if, if like node three, uh, is unhealthy kind of.
So in my workflow, I see like success instead of one, two, three are super expensive.
Uh-huh.
Like an LLM perspective.
Yeah.
Is it possible to trigger just step four?
That's a great question. We were actually, Nick asked if we could, uh, trigger a specific step. I'm not sure. But the other thing I'll say is that in those cases, that's the other reason I love the pipelines and also even just the concept of steps and agents is 'cause I can do a specific model for each one.
So like extracting frustrations is like that's pretty simple and should be fast and cheap. So it's like do 4.0 or even something simpler or maybe even get away with like a 7 billion parameter model that's deployed on like Cloudflare workers,right?
And then which it's like essentially free. Um, that's like, and that, that question by the way, this is like the, uh, like how do youright-size AI application workloads? Like that is top of mind for everybody now. Everyone's asking that question.
It's like how do I get the infra to be what's correct for the workload I have? I think everyone's trying to figure that out.
And, and another thing, like you can explore different ways of doing this. Uh, when we first started with this, we had all of these steps as tools and then kind of let the AI decide when it should call them.
Um, so that could be another approach depending on if it can intelligently skip steps, um, it might be able to do that.
Um, there was a question. Is this is in our chat,right? Or is it, is it, is I'm looking at okay. So there's a question is, is there a way to implement or configure caching with Mastra? I think the answer is yes.
Yeah, for sure.
Yeah. This, so I, I did, I did implement the, uh, image flip method.
Mm-hmm.
And I, and I tried a decent improvement.
It's the same here. Show me the, your .env file if you would.
Okay. Yeah. Okay.
Yeah.
Yeah. Right.
That looks great to me.
Assuming those are your actual creds.
Yeah.
And then the other thing is did you, uh, did you restart and finish?
I, I saved it and then I, and then I, uh.
And I'll use a new password combination.
So it's still saved.
Oh, so restart it now 'cause I bet you did you update env while that was running?
Correct.
So if you restart it, it should, um, pick up the new .env and let's see if it's the same or not.
Okay.
Yep.
Yep.
Yep. Exactly. Yep.
Uh, what did I say?
Bad food. Yeah.
I thought it was because it was two words instead of one.
Am I still have a, is there an extra space anywhere? And 'cause I had that issue even after I had the correct values. Like there has to be.
Yeah.
Still saying that.
How long should it take for this shirt? Like the MCP shirt?
Oh, uh, it'll take a, a few weeks probably.
Oh, no. I mean like.
Oh, is it not going through? Did it try and execute the tool?
Yeah.
Uh, what?
Try a different key?
What, um.
I don't think it's a problem.
Right? 'Cause it's a shirt.
It should. It should be relatively fast.
Second time trying is just waiting for approval.
Ah, okay. Uh, good to know. Let's try that.
I don't think you guys have an early active AP for that either.
Uh, yeah.
We should.
Um, so I can show this now.
Uh, so if you go, if you have it installed, which I do, um.
If I change it in here though.
Down in here. I have MCP shop set up. This is Claude, by the way. Uh, hey bro, I hear I can get a shirt. Let's see if it works.
Should I do install or just, you know, just research this over and make sure that's all.
Pondering t-shirt potential. That was awesome.
Thank you.
Ah, I can't provide physical shirts or merchandise. That's interesting. I thought you.
Should be connected. Nope. That's the problem.
There we go. Try that again.
Yeah. Oh, that's okay. Yeah.
Hey bro, I hear I can get a sweet MCP shirt now that we're maybe connected. Yeah. Cool. So it pops up. We'll allow that.
You can definitely get an MCP shirt. There's one availableright now. Here's what you can get. Minimal design. I don't know that it says context is everything, but it might.
Yeah. I don't think it says that.
Yeah. Go to the last one.
Oh, oh, yeah. Okay. It does.
Context is everything.
Yep.
Nice.
Cool. Uh, so it just needs for me my company name, my mailing address, and my t-shirt size. So I'll say XL, um, one infinite loop and company name, uh, WorkOS.
Oh, it needs my city, state, and zip code. I don't, I don't know what that is for Apple. Um, so I'll just, I'm, I live in Omaha.
Oh, and look at that. It's going to buy my shirt.
And it's ordered.
We will, we will actually send you a shirt, so be sure to.
Yeah.
Be sure to submit it while you're here.
You can also ask things like, um, can you tell me about my order?
I have a question. Technically on Cloudflare or technically on WorkOS?
Uh, it's deployed on, is, is this.
You put it on Cloudflare.
Yeah. I have a version deployed on Cloudflare. Um, this one I think is, it might be deployed.
MCP shop?
Yeah.
Probably in Vercel.
I think it's, yeah, it's deployed to Vercel. Um, for this specific instance of it. I, I have a talk on Thursday where I'm also, I have the same thing deployed to Cloudflare. So, um, we'll go into the code and I can send out the repo for that.
But, um, yes, that one just saves it, saves the info to a KV store. Uh, and then that's, that's what's used to order the shirts.
Uh, you can deploy MCP servers to Cloudflare now using WorkOS as the auth layer.
Yeah.
So, so, uh, feel free to check that out. We have a blog post and a couple of tutorials.
Yeah.
Yeah.
That's the thing. It's using WorkOS to do that auth. You didn't see it 'cause I'm already authed in, but when I hit connect, it opened up and it was do completing that auth flow to get me a token so that I could, uh, do that here.
And you can see that in here. It's got like my order information. Um, I don't know. Do you know my name and email, which is totally not something I've said yet.
But, but also to tie it again, uh, back together,right? 'Cause again, like toy, it's fun. Got a t-shirt, but imagine this as an e-commerce workflow,right? This is what people are building. Like this is what everyone's trying to figure out how to do correctly.
What I actually want to do is just go, I'm in a hurry. I want to get on the page and say, it needs to be a product exactly like this. Does it support that? Okay, fine. Go. Not $40, less than that,right?
That's what everyone wants to do. Um, and so that's what this interface is.
Yeah. Pretty soon you'll be social engineering your way through LLMs to get a free shirt when it's not free.
Yep.
I can't wait for the future.
Yeah.
Uh, cool.
These are challenges.
Yeah. Let's, let's, uh, look at the workflow. So I switched over to the step three branch, which is the end of step two, uh, where you should be at. And you've got a new meme generation workflow. Uh, and it's got, you know, a bunch of schemas set up for the input and output schemas, uh, and all of the steps set up to run each of these.
And, you know, that's the code for it. Let's go look at the, the actual get out of here. Um, the tools in Mastra. So I'll refresh this and go back to work. Yep. Workflows. There we go. Now we have our meme generation workflow and it's got four steps.
And so this is a little bit better, a little, little more detailed in what, what it's doing. Um, it's got not including these mappings. It's got our extract functions, find base meme, generate captions, generate meme. Oh, come on.
Uh, and then a final mapping. Um, and so I don't know. Someone give me a work frustration.
Somebody to eat my sandwich out of the fridge.
When no one in the workshop is.
Someone was too busy preparing a workshop to review my PR.
Nick.
No, never.
And won't review my PR. That's a made-up one. Um, so yeah, it can run. You can see it running. Um, and then we can go, we can see all of the steps are now green. And so we can see the input and debug the input and output on each of the steps.
So there's the input that we got, and it gave out a frustration, a communication frustration.
And I am all sorts of messing this up. Uh, but we can have it find the base meme and then generate the captions for it. Find out what that is. So when the meeting could have been an email, but everyone is just smiling like it's fine.
That's relatable. Um, but then down in the generate meme one, that's going to receive the captions. It's going to receive apparently a meme called Disaster Girl. And
did I mention that these are non-deterministic and I don't know what it's going to generate?
Ah, the meeting could have been an email, but everyone is just smiling like it's fine. This is fine. Yeah. Um, yeah. So this is fun,right? We can see the workflows, the inputs and outputs of it, and we can debug those steps along the way.
We can see exactly what is what we're starting with and how it progresses through each of the steps, uh, to give us a full workflow, which is awesome. Um.
We haven't even had to do a deployment yet.
No.
And we can just iterate locally, change the prompts, change the schemas until you get it exactly the way you want. And then you haven't wasted time going back and forth. You've like iterated rapidly.
Yeah. And so really easy debugging. That's why we love this tool. Like it's, it's just really fun and easy to do. So in the final step, um, the, the final main step we have, uh, we're going to like take that workflow now and call it with an agent.
Step 3: Agent1:27:52
So this is a pretty straightforward step. We're just going to create an agent, give it a prompt to work with, and give it the, the knowledge of the this workflow that it can run. And then it'll run it for us.
So instead of having to use that interface, we can use a chat interface, uh, that we're more familiar with and go from there. And so.
And, and again, to tie it back to actually taking this home and doing something useful with it, like we've gotten to the point where we've described a workflow of steps that completes a discrete task. And maybe that's something that our, our coworker needs.
And then again, maybe they are technical, maybe they're not, maybe they're just in a hurry. So by building them an agent and saying, use this workflow, and you, you have the ability to call this workflow, that becomes an ideal interface to give to our colleagues to start using this.
And then something that they used to have to do piecemealy, they're just now firing off a chat request and it's done for them automatically.
Yep. Yeah. So with this you'll learn what agents are, how you give them instructions, um, the memory systems for them, the workflow integration, uh, through Mastra, and then how you can test them in the playground.
Wow, these are awesome. So these are new community memes pouring in real time. We finally catch up on Slack messages, but there's already 20 more waiting. Nice.
Yeah, that's a great idea.
Yeah.
There's some great, um, feedback on the framework guys in the, in the Slack channel. There's like some UX requests as well. You can see it.
That's great.
Ah, too real.
You can also play with the, uh, prompt, uh, the prompts a little bit to tweak it about what it's, how it's like analyzing the frustration, the level of frustration, the type of meme, um, things like that.
It's really fun to get a, a vibe for it.
Yeah, indeed.
Allright. Does everyone more or less have, uh, what they need? Is anyone still stuck on anything? Any last minute questions or pickups? No? Cool.
That's amazing. I'm going to make a t-shirt with that.
Uh, just a, I guess a comment from us and I guess from the team as well. Like honestly, like thanks everybody for coming and building these. We didn't even know this workshop was happening until last week it was.
But, um, I mean previously like so like most of us at Mastra were previously building Gatsby. Like I was the co-founder. And so we've been doing open source JavaScript stuff for a while, but it's like pretty humbling when you show up for a conference and actually someone else is giving a workshop about how to use the thing that you built.
Um, and I think I speak for all of us. So like thanks everybody.
Thanks a lot.
Yeah, thanks.
Been a pleasure.
And on the same side, we didn't know that you were going to be here until I think like yesterday.
But we got very excited 'cause it's like, hey, you got a question about commit? Let's go ask him.
Yeah.
I'm just personally curious how many folks have or like already have agents deployed at work in prod that they're using for things. How many folks, a couple, how many folks are trying to get them in, into prodright now?
I'd be curious to know what you're using them for.
Yeah. I'd also be curious if anyone wants to share either in the Slack or just call it out or come up to the mic. Like what are the top use cases that you're thinking of for agents or struggling with?
I'd be curious to know too.
This is such a fun time 'cause there's like, like you, you have to get your head around what it's doing and then get your head around what it can do. And it just, it starts to feel like the possibilities are endless and just super fun.
Yep.
Oh, nice.
Getting around the online and online playing close.
Yeah.
Customer
cluster. We have physical servers that have issues operationally.
Yep.
And then goal is to have a problem to get logsright now.
That's awesome. Yeah, that's awesome. So like you've got, um, so you want to be able to chat with your infrastructure and like ask questions, like either an incident, like show up to the incident and even already have like initial guesses maybe.
Right there.
Yeah, that's awesome. Cool. Any other use cases? I think that we're finding, um, we're mostly able to just knock out a ton of like low-hanging fruit that folks are doing manuallyright now. It's, you know, especially with tools like this, like you, you know, create a simple agent or even just a pipeline with a few steps and a couple API calls and that can like free up hours of somebody's week.
Um, I think that's the part that I'm most excited aboutright now.
Yeah. It's like all the little paper cuts, you can just so quickly iterate on them and get things going.
Yep.
And not just with these, these tools, but just like vibe coding in general. Like you can, you know, be like, I'm going to spend an hour just seeing where I can get to and.
Yeah.
It's amazing.
Incredible how quickly you can get there.
Always review the code though, please.
What's that?
Always review the code, please.
Yeah, please review the code. Use tools like Git Guardian before you commit.
Yeah.
Yeah, we had our, our AI moment, uh, a couple weeks ago at our last onsite and, um, we had like a couple hours just to spend doing something with AI. And it, there was really no prescription to it.
It was just explore and play. And if you can solve a problem, great. If not, you learned something along the way. And, uh, the thing that I worked on was like as the maintainer of several SDKs across several languages, uh, a pain point I saw was like people adding in, you know, very simple PRs to one repo that's like the node repo, the node SDK, and then doing the same thing.
It's like adding a new field to the node SDK and then adding the same field to the Ruby, Go, PHP, Kotlin, like all of the SDKs. I was like, I wonder if we could do something to alleviate that and make it easier.
And after two hours of pure vibe coding with Claude, I had a GitHub action that when you label the first PR that you do, you just add a label to it, it will go and generate the PRs for every other repo and just automatically PR it.
Every other SDK.
Yep.
That's awesome.
Were you using like a software engineering framework like Dagger or something to essentially do the changes or QBOD?
Making the, oh, that's a great question. Making the changes is one thing. And that's something that, yeah, I think Dagger would make a lot of sense. But what were you doing with that?
I wasn't, I wasn't doing any of that. Um, I vibe coded it and I actually don't know what the code does.
And he had to.
I didn't review it.
He had a 4,300 line, uh, GitHub action that's working great.
How?
I want to hear more about that.
But to be clear, we didn't ship it. Uh, it's, it's an experiment. Maybe, maybe we will for sure. Um, but the week after that, I think, um, Claude had come out with like the ability to run Claude code as a, uh, like via an API so that you could like spin it up, run it, give it the instructions on what to do, and then let it figure out how to do it.
'Cause like most of the code that it generated was just handling how it was going to do the diffs. And for several hours of that, it was just like it made the changes I wanted and then deleted the rest of the files and that wasn't great.
Um, we're also for what it's worth finding, uh, incredible utility with tools like V0 Dev. So if you're already in the Vercel ecosystem or have used Next.js, there's now, there, they were originally conceived of as like rapid prototyping tools that maybe for designers or maybe for developers.
But like an example is that somebody on our marketing and sales team was trying to figure out who would be interesting engineers that are already doing work with MCP to contact about conferences like this. And their workflow is completely manual and they're, you know, talking to me about it on a, on a call.
And four minutes after they started telling me about it, I had it working like in V0 Dev and handed it to them and they had a completely separate, you know, tool that's available on a URL that they can just paste in whatever they need essentially and get like the analysis done.
Um, and so that was very eye-opening for me 'cause it's in some cases now it's faster to create the tool that your colleague needs than it is to continue talking about the tool that your colleague needs and even ticketing it or saying next Tuesday we should try and like sometimes you can literally sit down in V0 Dev with like a paragraph, very discrete prompt and get what you need.
Nice. That's pretty good.
So then question.
Yes.
Do salespeople do this process and they're creating a keyboard? Now I want to be next to you.
No.
And I'm.
Not in my experience. Not yet.
Cold call.
Yeah, totally. I think that's, that's a fascinating question. Yeah. The question is like when, um, folks in other roles that are not traditionally technical see how quickly you can scaffold this stuff? Are they all clamoring for the keyboard?
That's not been my experience yet. There, I think that's also like part of what the trepidation and anxiety is around is like, well, now everyone can do it. But then I also comfort myself and say that I define a pleasurable evening as like sitting down for 12 hours on one of these machines and going back and forth to try and get it to go the way I want.
And that's not most people's description of a fun time. So like even when the tools are better, I, I still think you kind of have to find this enjoyable. You know what I mean? I don't, I don't, I, I, I think it might change to some degree like when, like most generation becomes one shottable and you say, I want this app and it's of like this complexity and most people can get something working immediately.
That's correct. I think that'll take a lot of low-hanging fruit off, but.
I heard, um, some people said like the lawyers would put some CSVs.
They would do what?
Put lawyer like legal questions and data into CSVs and then they would essentially, um, almost like a blind mouse start telling Claude code, go do XYZ and tell me what the results are. And so I don't know. I don't know.
From a philosophical point of view, some cultures. That structure really engages and the other engagement.
Yeah. I, I think that's super fascinating. And anecdotally, um, it's mostly been lawyers when I've been at meetups that have come up and asked the most like salient questions about Gen AI and they'll say like, I'm not a coder, but like this is what we're trying to do.
Also semantic search and all like the information compression that's available with a lot of the Gen AI tools like I think uniquely speaks to their use case too of there's this gigantic corpus of case law and need to know exactly thisright now,right?
Yeah, it's, but it is, um, it's an intense time I think for that reason. Yeah, culturally,right?
I've gotten away some 20 minutes. What are we doing? Nothing. We're doing great. We've got a nice slide slot. Oh,
you guys are going to configure an MPC server,right? It's like you have trouble with this.
Uh, in this, uh, session or in general? Sorry, I didn'tright now. Uh, no. Yeah. But, uh, I have a, I have a.
Needed it?
Yeah. Yeah, for the most part. I have a tutorial for you that does that if you want it. Thanks. Thanks for coming. Appreciate it.
Yeah.
Yep.
Allright. So we can show the agent piece of it now. Um, so I switched over to the step four branch, uh, which is the end of step three, uh, where we should have the created, uh, agent now that can run, uh, and actually have a conversation with the tooling, uh, which makes it really a lot easier to work with.
Uh, but we still have the power of being able to use the workflow tool to see what's going on and debug the steps along the way. Uh, but now if we go to the agents tab in Mastra, we've got a meme generator.
And this gives us a very sim, a very familiar look and feel. Gives us a chat window. Uh, but it gives us more than that. In the, uh, the sidebar here, we've got an overview. We can see the instructions, uh, that are given to the agent.
So it's a helpful UI agent, uh, or AI agent that's going to help us do that. Uh, it's got some critical steps in there. It's got the workflow that it should follow, um, and telling it what it has access to.
We also can see the model settings and we can adjust this as we go. So we can add more or less temperature, uh, top P. We can change all of these on the fly and test it to really hone in on like what works best for whatever we're trying to build.
So I'll ask one more time. Work frustration.
Who's got the gnarliest work frustration? Who's the most frustrated at workright now? Raise your hand. And again, you must state your company and your immediate superior's name.
Um, I always get asked to go to large meetings for four hours and then, uh, I don't speak at all.
This bothers you too. I see.
Yes. Meeting fatigue. Um, so now we can just ask the chat and see the output and it's much cleaner. It'll actually give us the image in line too, um, which makes it really nice and easy to work with.
That pointless meeting I was dragged into.
But if you scroll up a little bit too, the other thing, uh, to see here is like, so the user asked a question and you saw that the workflow got run. Um, but now there's also additionally like the agent is still chatting and it's in a familiar way that you already are familiar with if you use GPT.
Um, but then again, just a reminder that this is kind of the ideal interface for, uh, folks that might be your clients or your customers or your colleagues.
Yep. And we can see like in line what happened, you know, the tool arguments that were passed in, the total result. We can see what tools were called, uh, and how in this case it was the workflow and here's all of the information and then the end result that we can actually play with.
Yeah. So this could be, you know, a chatbot that someone is, uh, requesting.
Because he is moving for a mode.
Mode.
Here.
It designed like a new image. Uh, you can kind of put whatever you want behind the same interface.
Not really. Not really.
It's non-deterministic, guys.
Um.
There's, there's no HR for this conference. I was told that in advance.
So, uh, kind of to wrap that up, uh, what we built was a multi-step workflow that we could give to a conversational agent who knows how to execute it, knows what to pass into it and what it's going to get back, and then it can do without what it will.
Wrap-Up & Q&A1:45:52
It gave us, you know, human feedback. Uh, it wasn't just spitting out JSON in the end. Uh, it was giving us an actual response and then showing us the image in line and giving us a clickable link so that we could go share that image, uh, to whoever we wanted to.
Um, and we were able to create some awesome memes. I highly recommend you deploy this and use it because it's cathartic to really vent to it. Um, and if you're deploying it, your data's safe probably. I don't know.
Find out together.
So some key takeaways, uh, from this. Uh, we learned about the workflows, agents, we learned, uh, type safety, um, catching errors in that, uh, and the structured generation to ensure a reliable output, uh, and some of the benefits of Mastra.
Yep. Um, also just say that, that we didn't show this here, but one of the examples that's on Mastra site you can go check out is like a 37 line of code, uh, pipeline that does retrieval, augmented generation.
And if you've worked, if you've built those pipelines before, like two years ago, you know, you had to glue together at least three or four libraries. It was a super crappy experience. Um, so it's just really nice to have a single place you can go and define that pipeline at a high level.
Um, so yeah, excited to experiment more with that as well. There's a ton here that you can do that we did not even scratch the surface of or, or point to yet.
Yeah, for sure. Coming up with, uh, what to do in two hours. It's, uh, not a lot of time.
Yeah.
And there's a lot, a lot more that we could dig into and we highly encourage you to. So this was meant as a, a primer. Uh, you, you now have like an example.
Yeah. Yeah.
Uh, now experiment with it. Add things, add tools, um, deploy it with MCP, like figure out how.
Share it with your coworkers. Yeah.
Yeah.
Ask them to use it, see what happens.
So yeah, explore the tool creation, uh, add a vector database, implement RAG, uh, all of those. And just a final reminder, uh, mcp.shop, um, go order a t-shirt, check it out. Uh, it's really cool. So thank you with that.
Um, we've got 15 minutes left. We wanted to save that for questions, any, uh, additional follow-up, any just general casual conversation about these tools, uh, the fascinating world of AI, anything.
Vote on memes that we generated and see who is the ultimate winner in the Slack channel.
So I'm giving a talk on agents and workflows tomorrow and I really liked your agents and workflows side. Can you bring them up again?
What? I didn't hear what you said.
Yeah, I didn't hear it. Sorry.
Oh, sorry. I'm giving a talk on agents and workflows tomorrow. Agents and workflows sides were really good. Can you bring them up again?
Sure. We can share them too. They're open source because they're in our repo and they're on Markdown.
How do you make those in Markdown?
There's a couple tools that Nick, Nick likes.
Uh, yeah, this was slide. Uh, slidev or slide.dev. Um, yeah, it was something that we switched to relatively not that long ago.
20 minutes before this talk.
Pretty much. Yeah.
Uh, questions for us or the Mastra team?
Uh, do make sure that you, if you want a shirt, buy a shirt because we will actually send you a shirt. We might not send it this week, but, uh, we're tracking all the orders and we're going to honor all of them.
So it's a limited edition mcp.shop shirt that will never be seen again.
We've got some here and I think we've got some in the back.
Yep.
If you want an official Mastra book, um, autograph copies are $30,right? And otherwise.
Cool. Um, but yeah, yeah, question.
Where's the memory and execution step?
The memory and execution step? Um.
Yeah. So you, you, you can configure, you know, we, we configured SQLite for this demo and that's what's powering like the ability as you create additional chats, you'll see the previous chats on the left rail. Um, but there's a ton of different storage drivers like there's the Postgres and everything else,right?
Um, so you can basically choose what you need to. Um, and then once you configure the memory, you pass it into either the workflow or agent. Um, and then that's by, by way of doing that, you're telling it can use it essentially.
Is that your question?
The demo one doesn't have memory?
The demo one does have memory using SQLite and it's.
That's what I saw, but, uh, it says check execution step. Where do I find that?
Uh, check execution step.
Where are you? Let me, I'll come over.
Great.
Oh, thank you.
Thank you.
Thanks so much for coming. Appreciate it.
And, uh, yeah, we'll be around, uh, all week, uh, at the conference, so reach out. Uh, we'd love to chat more.
He's talking about just, uh, like that graph.
This is the main. Thank you.





