alt.hn

1/20/2026 at 4:38:56 PM

Show HN: Mastra 1.0, open-source JavaScript agent framework from the Gatsby devs

https://github.com/mastra-ai/mastra

by calcsam

1/20/2026 at 9:13:32 PM

> That last one took a bit of time, we went down the ESM/CJS bundling rabbithole, ran into lots of monorepo issues, and ultimately opted for a more explicit approach.

shudders in vietnam war flashbacks congrats on launch guys!!!

for those who want an independent third party endorsement, here's Brex CTO talking about Mastra in their AI engineering stack http://latent.space/p/brex

by swyx

1/20/2026 at 9:27:07 PM

LOL thanks swyx. Yeah we realized although we _could_ fight that war again...it would be better for everyone if we didn't...

by calcsam

1/20/2026 at 9:27:41 PM

And I actually hadn't seen that Brex piece so thanks for sharing!!

by calcsam

1/24/2026 at 7:03:44 PM

use mastra, get acquired!

by swyx

1/21/2026 at 1:15:44 AM

I worked with Mastra for three months and it is awesome. Thank you for making a great product.

One thing to consider is that it felt clunky working with workflows and branching logic with non LLM agents. I have a strong preference for using rules based logic and heuristics first. That way, if I do need to bring in the big gun LLM models, I already have the context engineering solved. To me, an agent means anything with agency. After a couple weeks of frustration, I started using my own custom branching workflows.

One reason to use rules, they are free and 10,000x faster, with an LLM agent fallback if validation rules were not passing. Instead of running an LLM agent to solve a problem every single time, I can have the LLM write the rules once. The whole thing got messy.

Otherwise, Mastra is best in class for working with TypeScript.

by dataviz1000

1/21/2026 at 7:45:20 AM

I learned that every step that can be solved reasonably without an LLM, should be solved without an LLM. Reliability, cost, performance, etc.

I try to transfer as much work as I can out of LLMs and into deterministic steps. This includes most of the “orchestration” layer which is usually deterministic by nature.

Sprinkle a little bit of AI in the right places and you’ll get something that appears genuinely intelligent. Rely too much on AI and it’s dumb as fuck.

Make their tasks very small and simple (ideally, one step), give them only the context and tools that they need and nothing else, and provide them with feedback when they inevitably mess up (ideally, deterministically), and hope for the best.

by brap

1/21/2026 at 1:32:41 AM

Thank you for using us, and for the feedback!

Do you have code snippets you can share about how you wanted to write the rules? Want to understand desired grammar / syntax better.

by calcsam

1/21/2026 at 9:14:05 AM

Within that repo is a concise, high signal book by Sam Bhagwat "Principles of Building AI Agents"

https://github.com/mastra-ai/mastra/blob/main/book/principle...

by cesther

1/21/2026 at 6:42:49 PM

Yes a book is exactly what makes sense in this very immature and fast changing space.

It's especially effective when you litter it around ai company offices in SF

by dcreater

1/21/2026 at 3:22:09 PM

You found the Easter egg!

by calcsam

1/20/2026 at 8:51:04 PM

You’re not locked into a model, but you likely are locked in to a platform. This DX and convenience just shifts within the stack where the lock in occurs. Not criticizing - just a choice people should be conscious of.

Another useful question to ask: since you’re likely using 1 of 3 frontier models anyway, do you believe Claude Agent SDK will increasingly become the workflow and runtime of agentic work? Or if not Claude itself, will that set the pattern for how the work is executed? If you do, why use a wrapper?

by mrcwinn

1/20/2026 at 9:23:25 PM

Re: lessons from coding agents, we're building some of the key abstractions like sandboxes, filesystem, skills/knowledge as Mastra primitives in over the next month.

For any agent you're shipped to production though you probably want a harness that's open-source so you more fully control / can customize the experience.

by calcsam

1/20/2026 at 9:26:49 PM

I think that’s fair, totally, but I also think a Skill would be considered a primitive in and of itself by Anthropic. So to me it’s still wrapping an open primitive. Anyway, trade offs.

by mrcwinn

1/21/2026 at 11:44:47 AM

The old school open source community would get heartburn reading this but my has the world changed.

by redwood

1/21/2026 at 3:35:38 AM

is "from the Gatsby devs" some how supposed to help the credential? Looks like a cool framework regardless of that.

by nsonha

1/21/2026 at 5:53:25 AM

If I had some heartfelt advice for the Mastra devrel team it would be to shut up about about Gatsby.

I'm a happy Mastra user and I'm biased to their success. But I think linking it to an unrelated project is only going to matter to non-technical CXOs who choose technology based on names not merits. And that's not the audience Mastra needs to appeal to to be successful. Good dev tools and techs trickle from the bottom up in engineering organizations.

by avaer

1/21/2026 at 6:40:58 AM

Thanks for the feedback. We hear from a lot of devs with fond memories of Gatsby but if it cuts the opposite way for you that's also fair!

Most of us spent a lot of the last decade building Gatsby so it's sort of a personal identity/pride thing for us more than a marketing thing. But maybe we need to keep our identity small! Either way, thanks for saying something, worth thinking about.

by calcsam

1/21/2026 at 9:07:37 AM

I don’t mean to be provocative, but given that it’s in the title of the post, of course I checked whether the marketing page for this framework was built with Gatsby - seems like it’s Next.js though. Any reason Gatsby was not chosen if it’s a point of pride?

by __jonas

1/20/2026 at 11:52:31 PM

I've been building with Mastra for a couple of weeks now and loving it, so congratulations on reaching 1.0!

It's built on top of Vercel AI elements/SDK and it seems to me that was a good decision.

My mental heuristic is:

Vercel AI SDK = library, low level

Mastra = framework

Then Vercel AI Elements gives you an optional pre built UI.

However, I read the blog post for the upcoming AI SDK 6.0 release last week, and it seems like it's shifting more towards being a framework as well. What are your thoughts on this? Are these two tools going to align further in the future?

https://vercel.com/blog/ai-sdk-6

by esperent

1/21/2026 at 12:25:59 AM

Never ask a woman her age, a man his salary, and an agent framework developer his long term plans

by deepdarkforest

1/21/2026 at 1:15:30 AM

Have a ton of respect for the AI SDK team. Initially we only used AI SDK model routing, but now we also have our own built-in model routing as well.

I see each of us having different architectures. AI SDK is more low-level, and Mastra is more integrated with storage powering our studio, evals, memory, workflow suspend/resume etc.

by calcsam

1/21/2026 at 6:52:18 AM

What a corporate and wishy washy response that just basically repeated what I said back at me.

I was hoping to actually engage with you but I guess you just came here to do marketing.

> AI SDK is more low-level

AI SDK was more low level. My question was, since the latest V6 release is moving towards higher level components, what do you think about that? How will you continue to differentiate your product if Vercel makes moves to eat your lunch?

That's almost certainly their intention here, following their highly successful Next.js playbook: start by creating low level dev tools, gradually expand the scope, make sure that all the docs and setup guides you towards deploying on their infrastructure.

by esperent

1/21/2026 at 11:35:29 AM

It's a mix of savvy and diplomacy to neither attack a competitor in the open nor be forced to reveal their strategic way of thinking into your way of viewing things. This is not a winner take all space. Corporate yes but you can be more self aware yourself.

by redwood

1/20/2026 at 8:13:48 PM

Offtopic but how much is AI used these days for generating code at your place? Curious because we see a major shift last months where almost everything is generated. Still human checked and human quality gates. Big difference compared to last year.

by holoduke

1/20/2026 at 8:32:02 PM

There's the normal stuff you'd expect -- we're all Opus-pilled, use Claude Code, a PR review bot etc. But it's been especially helpful with highly templatized code like our storage adapters, we already have 10-15 working examples which makes the n+1st adapter almost trivial to write.

by calcsam

1/21/2026 at 4:45:11 PM

Happy you guys are moving forward. Just to make the comment section a bit more balanced wanted to give my xp. Mastra is by design batteries included and opinionated when you don't fit into an existing pattern it is difficult to keep being productive. In our system several times we have needed to go out and create our own hono routes. We are currently have someone rebuilding everything with langgraph/langchain and will then write a detailed comparison.

For sure lots of good ideas in mastra, and happy that its JS TS first, I think you'll will continue to grow becuase of the TS first approach

by scirob

1/21/2026 at 9:17:17 PM

Thanks for the feedback! Our mission with Mastra is to make sure users can get further faster with the standard primitives of AI engineering! We learned over the last year that while we want to be opinionated, users need to be able to eject and adapt Mastra however they want! We added server adapters so users didn’t have to deal with our opinions on esbuild, we made storage more configurable and extendable, and invested more into our workflows engine which will be the foundation for distributed execution in the future! We are always willing to hear feedback and welcome changes! Would love to know what you learn from the langchain comparison and happy to improve Mastra from it! Thanks!

by asaiyer

1/21/2026 at 2:14:58 AM

Ran through quickstart, created my first agent "Friendo" that acts as my best friend, chatted a bit. Nice UI, cool systems, hope to play with it more and build something, but I'm just not sure what yet.

by magicmicah85

1/20/2026 at 10:51:48 PM

Congratulations! I’m a fan of the publicity work and general out-of-the-box DX! That stuff matters a lot and I’m happy you’re aware.

I wonder: Are there any large general purpose agent harnesses developed using Mastra? From what I can tell OpenCode chose not to use it.

A lot of people on here repeat that rolling your own is more powerful than using Langchain or other frameworks and I wonder how Mastra relates to this sentiment.

by solarkraft

1/20/2026 at 11:31:30 PM

When Langchain was the only option rolling your own made a lot of sense!

These days we see things going the other way, where teams that started rolling their own shift over to Mastra so they can focus on the agent vs having to maintain an internal framework.

The Latent Space article swyx linked earlier includes a quote from the Brex CTO talking about how they did that.

by calcsam

1/20/2026 at 8:27:22 PM

We use typescript for all our entire stack and it's super dope to see a production-grade framework (with no vendor lock in) launch!

by pancomplex

1/20/2026 at 8:37:19 PM

Thanks! That's a lot of why we built Mastra. We wanted something that felt like it was made for us.

by calcsam

1/20/2026 at 8:48:32 PM

Congrats on the launch ! Someone told me that you have an excellent product but I don't have a need for it yet.

by simlevesque

1/20/2026 at 8:53:07 PM

Thanks! And of course hope you try Mastra out when you do.

by calcsam

1/20/2026 at 8:26:43 PM

Why should I use this over say Strands Agents [1] or Spring AI [2]?

[1]: https://strandsagents.com

[2]: https://spring.io/projects/spring-ai

by microflash

1/20/2026 at 8:35:59 PM

You should use whatever framework you feel like has the best DX / fits your stack best!

We're TypeScript-first, TypeScript-only so a lot of the teams who use us are full-stack TypeScript devs and want an agent framework that feels TS-native, easy to use, and feature-complete.

by calcsam

1/21/2026 at 4:46:46 AM

Spring AI is fantastic for Java shops. I am assuming Typescript devs will enjoy Mastra just as much .

by manishsharan

1/21/2026 at 1:56:33 PM

Strands documentation seems very underwhelming compared to Mastra

by isuckatcoding

1/20/2026 at 8:29:05 PM

seems non of these are typescript-based? Strand appears to have a typescript sdk available but not natively ts.

by pancomplex

1/20/2026 at 8:34:23 PM

Language, although an important factor, should not be the only factor to decide using a tool. I'm curious is there something unique Mastra is bringing to the table, compared to other alternatives.

by microflash

1/20/2026 at 8:27:59 PM

Been using Mastra for some side projects for months and it's just phenomenal. Congrats to the team!

by bradledford

1/20/2026 at 8:33:21 PM

Thanks, great to hear!

by calcsam

1/21/2026 at 5:04:27 AM

Mastra looks great!

- How do you compare Mastra with Tanstack AI? And/or do you plan to build on top of Tanstack AI like the Vercel AI SDK?

- Since there's a Mastra cloud, do you have an idea as to what features will be exclusive to the hosted version?

by sabr

1/21/2026 at 6:32:42 AM

Re: Tanstack AI, really depends on adoption. We've known Tanner since his react-static days and if it takes off we'll def work together.

Re: Mastra cloud -- this is basically hosted services, eg observability, hosted studio, hosted serverless deployments, as distinct from the framework.

With server adapters you can now deploy your studio in your infra. We're going to pull multi-project / multi-user Mastra cloud features into a Mastra admin feature so you can run these locally or deploy them on your infra as well (with EE licensing for stuff like RBAC). Stay tuned here.

by calcsam

1/20/2026 at 11:18:14 PM

So the ultimate real life use case of this is having a bubble on your site that you click to chat with a bot?! Most users prefer to chat with an actual human being 99% of the times or immediately ask the bot to chat with one.

by tamimio

1/20/2026 at 11:34:56 PM

Less frequently sites and more frequently a SaaS app, for example Sanity released a content agent in their CMS, Factorial released an agent inside their HR/payroll product.

But tons of other use cases too, eg dev teams at Workday and PayPal have built an agentic SRE to triage their alerts, etc etc

by calcsam

1/20/2026 at 11:04:32 PM

> a `.network()` method that turns any agent into a routing agent

say more pls?

by swyx

1/20/2026 at 11:42:42 PM

We've always supported letting folks specify their agent hierarchy, eg agent supervisor, workflow orchestrator, mix and match, etc.

But people kept asking us for a multi-agent primitive out of the box so we shipped `agent.network()`, which is basically dynamic hierarchy decided at runtime, pass in an array of workflows and agents to the routing agent and let it decide what to do, how long to execute for, etc!

https://mastra.ai/docs/agents/networks

by calcsam

1/21/2026 at 12:44:44 AM

ty! btw your docs search is broken, as i tweeted to Ward.

by swyx

1/21/2026 at 1:33:35 AM

ah crap, thanks for heads-up. looking into it.

by calcsam

1/20/2026 at 8:49:08 PM

From punch cards to assembly, to C, to modern languages and web frameworks, each generation raised the abstraction. Agentic frameworks are the next one.

by anditherobot

1/20/2026 at 8:59:21 PM

I mean we're framework guys so I would agree!

by calcsam

1/21/2026 at 11:32:19 AM

I don't get the pricing page. It seems not to have prices.

by I_am_tiberius

1/21/2026 at 3:27:48 PM

Our cloud platform is in beta so it's free right now!

by calcsam

1/21/2026 at 2:53:39 PM

How does it compare to claude agents sdk?

How do I make a selection between:

* openai agents sdk

* claude agents sdk

* and mastra

by throwaw12

1/21/2026 at 3:36:57 PM

Those are both good options. You should try us all out and see which one you like best!

by calcsam

1/21/2026 at 4:19:07 PM

in terms of agent harness, how would you describe the differences?

by throwaw12

1/21/2026 at 4:46:21 AM

fantastic work, congratulations on the launch!!!!

by yawnxyz

1/21/2026 at 6:41:21 AM

thanks!

by calcsam

1/21/2026 at 4:24:04 PM

Love to see it!

by gneray

1/20/2026 at 11:52:24 PM

Congratulations on the launch. The landing page looks dope.

by admiralrohan

1/21/2026 at 12:34:11 AM

Thank you! We have an incredible designer and we love obsessing about this stuff.

by calcsam

1/21/2026 at 6:46:00 PM

This post is totally not astroturfed

by dcreater

1/21/2026 at 4:11:14 AM

the framework is great, but how are you gonna make real money?

by orliesaurus

1/21/2026 at 6:35:54 AM

Cloud-hosted observability + studio features (and self-hosted with EE bits).

You can take a look at the cloud platform at cloud.mastra.ai, it's in beta currently

It's the same play we did at Gatsby to get to several million in ARR in a couple of years

by calcsam

1/21/2026 at 6:02:17 AM

[dead]

by Agent_Builder

1/21/2026 at 4:54:20 PM

Congrats on the 1.0 launch! The workflow and agent composition primitives look well-designed.

Curious about the observability story - when agents make tool calls, how do you debug what actually got sent to external APIs? We've found that's often the hardest part of agent development - the "it works locally but fails in production" debugging loop.

Great to see more production-ready agent frameworks emerging. Will be following the project!

by kxbnb

1/21/2026 at 6:05:09 PM

Hi. I'm on the Mastra team, and I've built out the observability stack. We support outputting traces to numerous 3rd party tools, and also our own system.

More info can be found here: https://mastra.ai/docs/observability/tracing/overview#export...

In the coming months we will add improvements to logging, overall metric collection, experimentation tracing, and numerous additional observability features.

Thanks for your interest.

by epinzur

1/21/2026 at 12:41:35 AM

[flagged]

by owebmaster

1/21/2026 at 9:43:12 AM

It's crazy that my comment was up voted then flagged.

by owebmaster