HackerReposA FIELD GUIDE TO OPEN SOURCE
ProSponsor the shelf♧ 0
← Back to top all-time
mastra-ai
mastra
TypeScript2025–2026
mastra-ai / mastra

mastra

Mastra is the modern TypeScript framework for AI-powered applications and agents.

9Distinct people
12Mentions
0Explicit recommenders
29.5KGitHub stars
REPOSITORY AT A GLANCE

What to know before exploring

What it is

Mastra is the modern TypeScript framework for AI-powered applications and agents.

GitHub

Where it is used

No documented product use was verified in the last source check.

What people are saying

No recommendation phrase was found in the indexed comments.

No classified warning is attached to this page. Read the discussions before treating silence as approval.

Also in these discussions

No other repository is repeatedly linked in the same discussions.

This week on Hacker News

Nov 7–Nov 14 UTC · Direct repository links and separately labeled related project stories. Indexed through 11/14/2026, 5:04:57 PM UTC.

No direct repository links were found in the indexed HN discussions over the past seven days. Older discussions are available below.

Mentions over time

HN mentions by month12 dated mentions

Observed mentions: 2025-02-19 15:25:08 UTC to 2026-10-07 16:59:27 UTC.

01232025-02-01 00:00:00 UTC to 2025-03-01 00:00:00 UTC (exclusive): 3 mentions; 1 submissions, 2 commentsFeb 20252025-03-01 00:00:00 UTC to 2025-04-01 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2025-04-01 00:00:00 UTC to 2025-05-01 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2025-05-01 00:00:00 UTC to 2025-06-01 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2025-06-01 00:00:00 UTC to 2025-07-01 00:00:00 UTC (exclusive): 1 mentions; 1 submissions, 0 comments2025-07-01 00:00:00 UTC to 2025-08-01 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2025-08-01 00:00:00 UTC to 2025-09-01 00:00:00 UTC (exclusive): 1 mentions; 1 submissions, 0 comments2025-09-01 00:00:00 UTC to 2025-10-01 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2025-10-01 00:00:00 UTC to 2025-11-01 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2025-11-01 00:00:00 UTC to 2025-12-01 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2025-12-01 00:00:00 UTC to 2026-01-01 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 commentsDec 20252026-01-01 00:00:00 UTC to 2026-02-01 00:00:00 UTC (exclusive): 3 mentions; 2 submissions, 1 comments2026-02-01 00:00:00 UTC to 2026-03-01 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2026-03-01 00:00:00 UTC to 2026-04-01 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2026-04-01 00:00:00 UTC to 2026-05-01 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2026-05-01 00:00:00 UTC to 2026-06-01 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2026-06-01 00:00:00 UTC to 2026-07-01 00:00:00 UTC (exclusive): 1 mentions; 1 submissions, 0 comments2026-07-01 00:00:00 UTC to 2026-08-01 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2026-08-01 00:00:00 UTC to 2026-09-01 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2026-09-01 00:00:00 UTC to 2026-10-01 00:00:00 UTC (exclusive): 2 mentions; 0 submissions, 2 comments2026-10-01 00:00:00 UTC to 2026-11-01 00:00:00 UTC (exclusive): 1 mentions; 0 submissions, 1 commentsOct 2026

Counts come from the repository’s dated source evidence. Index cutoff: 2026-11-02 08:16:59 UTC.

View mention counts and date ranges
UTC ranges include their start and exclude their end. Select a period to filter the source evidence.
PeriodStart (UTC)End (exclusive, UTC)MentionsSubmissionsComments
Feb 20252025-02-01 00:00:00 UTC2025-03-01 00:00:00 UTC312
Mar 20252025-03-01 00:00:00 UTC2025-04-01 00:00:00 UTC000
Apr 20252025-04-01 00:00:00 UTC2025-05-01 00:00:00 UTC000
May 20252025-05-01 00:00:00 UTC2025-06-01 00:00:00 UTC000
Jun 20252025-06-01 00:00:00 UTC2025-07-01 00:00:00 UTC110
Jul 20252025-07-01 00:00:00 UTC2025-08-01 00:00:00 UTC000
Aug 20252025-08-01 00:00:00 UTC2025-09-01 00:00:00 UTC110
Sep 20252025-09-01 00:00:00 UTC2025-10-01 00:00:00 UTC000
Oct 20252025-10-01 00:00:00 UTC2025-11-01 00:00:00 UTC000
Nov 20252025-11-01 00:00:00 UTC2025-12-01 00:00:00 UTC000
Dec 20252025-12-01 00:00:00 UTC2026-01-01 00:00:00 UTC000
Jan 20262026-01-01 00:00:00 UTC2026-02-01 00:00:00 UTC321
Feb 20262026-02-01 00:00:00 UTC2026-03-01 00:00:00 UTC000
Mar 20262026-03-01 00:00:00 UTC2026-04-01 00:00:00 UTC000
Apr 20262026-04-01 00:00:00 UTC2026-05-01 00:00:00 UTC000
May 20262026-05-01 00:00:00 UTC2026-06-01 00:00:00 UTC000
Jun 20262026-06-01 00:00:00 UTC2026-07-01 00:00:00 UTC110
Jul 20262026-07-01 00:00:00 UTC2026-08-01 00:00:00 UTC000
Aug 20262026-08-01 00:00:00 UTC2026-09-01 00:00:00 UTC000
Sep 20262026-09-01 00:00:00 UTC2026-10-01 00:00:00 UTC202
Oct 20262026-10-01 00:00:00 UTC2026-11-01 00:00:00 UTC101

What Hacker News says

12 sources
Mastra | AI Engineer | REMOTE (AMER or EMEA time zones) | Full-time Mastra is the open-source TypeScript framework for building AI agents (agents, workflows, memory, evals, tracing). From the team behind Gatsby, YC-backed, https://github.com/mastra-ai/mastra Why: We’re starting to build more and more agentic features into Mastra: Trace intelligence, and we’re working on various Agent Learning features to automatically self-improve agents (Autoevals + Suggestions, Rollouts). In addition, we’ve been increasingly running Mastra primitives like memory on industry-standard benchmarks and using the results to fine-tune configuration. You have: Shipped agents and agentic applications into production Tuned and tweaked them to improve accuracy You need to be able to benchmark your results against existing datasets, or intelligently creating Appl
Read the rest
In Ask HN: Who is hiring? (October 2026)
Mastra | Customer Engineer | REMOTE (AMER or EMEA time zones) | Full-time Mastra is the open-source TypeScript framework for building AI agents (agents, workflows, memory, evals, tracing). From the team behind Gatsby, YC-backed,https://github.com/mastra-ai/mastra We're hiring a customer engineer. Some companies would call this an FDE; we don't, because roughly half the job is shipping in the framework itself. The other half you're embedded with paying customers deploying agents to production: in their Slack channels and on calls, writing code in their repos, reviewing their PRs, working through architecture with their engineers. What you learn there comes back as bug fixes, features, and new primitives in Mastra. One of our current customer engineers is among the top bug-fixers in the entire codebase. You should be a full-stack TypeScript
Read the rest
engineer who has built agents and who can explain technical decisions clearly to engineers who haven't seen your code. Remote. We have a lot of EU customers and response-time SLAs, so US Eastern/Central or EU hours work best. Process: a call with Shane (co-founder/CPO, leads customer engineering), a conversation with a customer engineer, a 2-3 hour take-home, then you present it to us and get feedback. Apply: {https://jobs.ashbyhq.com/Mastra/05172cb0-47ec-44f9-9fe8-07d4...} We get back to everyone.
In Ask HN: Who is hiring? (September 2026)
calcsam·Jan 20, 2026Submission

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

Hi HN, we're Sam, Shane, and Abhi. Almost a year ago, we first shared Mastra here (https://news.ycombinator.com/item?id=43103073). It’s kind of fun looking back since we were only a few months into building at the time. The HN community gave a lot of enthusiasm and some helpful feedback. Today, we released Mastra 1.0 in stable, so we wanted to come back and talk about what’s changed. If you’re new to Mastra, it's an open-source TypeScript agent framework that also lets you create multi-agent workflows, run evals, inspect in a local studio, and emit observability. Since our last post, Mastra has grown to over 300k weekly npm downloads and 19.4k GitHub stars. It’s now Apache 2.0 licensed and runs in prod at companies like Replit, PayPal, and Sanity. Agent development is changing quickly, so we’ve added a lot since February: - Native model r
Read the rest
outing: You can access 600+ models from 40+ providers by specifying a model string (e.g., `openai/gpt-5.2-codex`) with TS autocomplete and fallbacks. - Guardrails: Low-latency input and output processors for prompt injection detection, PII redaction, and content moderation. The tricky thing here was the low-latency part. - Scorers: An async eval primitive for grading agent outputs. Users were asking how they should do evals. We wanted to make it easy to attach to Mastra agents, runnable in Mastra studio, and save results in Mastra storage. - Plus a few other features like AI tracing (per-call costing for Langfuse, Braintrust, etc), memory processors, a `.network()` method that turns any agent into a routing agent, and server adapters to integrate Mastra within an existing Express/Hono server. (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.) Anyway, we'd love for you to try Mastra out and let us know what you think. You can get started with `npm create mastra@latest`. We'll be around and happy to answer any questions!
213 points · Open discussion
calcsam·Aug 6, 2025Submission

Show HN: Principles of Building AI Agents book [pdf]

Hi, I’m Sam, the cofounder/CEO of Mastra, the Typescript agent framework. I wrote a book on building agents and wanted to share it with HN. The book is called Principles of Building AI Agents. Right now it has 34 chapters and 148 pages covering LLMs, prompting, agents, workflows, RAG, evals, multi-agent, tracing, deployment, MCP, tool use, and a few other topics. The backstory here is that last October when we started working on Mastra we knew very little about AI engineering, and had to learn as we were building. In January, we started going to local AI meetups. We met a lot of people who were where we’d been. Somehow, we turned from students to teachers. Whenever an explanation seemed to stick we’d go home and put it in our docs or blog. One day my cofounder Shane turned to me and was like, what if you wrote a book on this stuff? I was
Read the rest
initially skeptical, but I tried writing an outline and it was pretty natural. So I spent the next couple weekends trying to hammer our posts into book form, and fill in the gaps. Surprisingly it worked. The initial version was 92 pages, in 27 very short chapters. We were going to call it Principles of AI Engineering but a founder author friend convinced me to use the word Agents instead, so Principles of Building AI Agents it was. The first reaction we got was surprise. We handed it out at the same meetups we’d gone to earlier. We started seeing people post book reviews on social media. A couple founder friends told us the book changed their agent architecture or their interface design. An engineer turned videographer came to our office and shot a mini-documentary. People asked us a lot how we’d keep the book up to date. We didn’t really know. Then MCP and Studio Ghibli happened, and we knew we needed to update it. I sat down in May to write for another weekend. I ended up with another 50 pages. In addition to MCP and image gen, there was a lot of stuff to write about web browsing, workflow streaming, code gen, agentic RAG. We republished the book as the 2nd edition. The single thing that people comment on the most is a page where I give a partial excerpt from the leaked Bolt.new system prompt. It’s the first time many people have read a production-grade prompt. The book has become pretty popular recently. We've given out thousands of copies at AI meetups and conferences, and it's even gone viral on LinkedIn (of all places). In terms of actual mechanics, I wrote the book in Notion, then pasted it into a desktop app called Vellum, which spits out ePubs and PDFs. Amazon’s KDP lets you upload those and publish your book (they’ll print it for you). Having a nice CI/CD helped, as did having docs and blog posts as sort of intermediate artifacts in a content pipeline. It meant that when I was writing I could pull from a warm cache. The process felt O(n) rather than O(n log n). Enjoy reading, and please let me know what you think! (You probably just want to download the book and read it in your favorite reader, rather than use Github's PDF reader) I’ll be starting on a third edition soon, and I want to know what topics feel like they’re missing, if anything feels outdated, and so on.
5 points · Open discussion

Show HN: A “Course” as an MCP Server

We wanted to build a course for new Mastra devs to get started quickly. However, we knew videos would go out of date and be more difficult to maintain. We decided to launch our "course" as an MCP server. This way your coding agent actually teaches the course content to you and can help you write the code. We think this is a really interactive way to learn. Using an editor with MCP support (such as Cursor, Windsurf, or VSCode), your code agent will call the appropriate MCP tools which will return context for the agent. This context tries to instruct the agent that it should be teaching you the content, not just doing the work for you. The course is still pretty experimental and some models work better than others. Code is available in the Mastra Github repo in the mcp-docs-server package (https://github.com/mastra-ai/mastra/tree/main/packa
Read the rest
213 points · Open discussion
calcsam·Feb 19, 2025Submission

Show HN: Mastra – Open-source JS agent framework, by the developers of Gatsby

Hi HN, we’re Sam, Shane, and Abhi, and we’re building Mastra (https://mastra.ai), an open-source JavaScript SDK for building agents on top of Vercel’s AI SDK. You can start a Mastra project with `npm create mastra` and create workflow graphs that can suspend/resume, build a RAG pipeline and write evals, give agents memory, create multi-agent workflows, and view it all in a local playground. Previously, we built Gatsby, the open-source React web framework. Later, we worked on an AI-powered CRM but it felt like we were having to roll all the AI bits (agentic workflows, evals, RAG) ourselves. We also noticed our friends building AI applications suffering from long iteration cycles: they were getting stuck debugging prompts, figuring out why their agents called (or didn’t call) tools, and writing lots of custom memory retrieval logic. At some
Read the rest
point we just looked at each other and were like, why aren't we trying to make this part easier, and decided to work on Mastra. Demo video: https://www.youtube.com/watch?v=8o_Ejbcw5s8 One thing we heard from folks is that seeing input/output of every step, of every run of every workflow, is very useful. So we took XState and built a workflow graph primitive on top with OTel tracing. We wrote the APIs to make control flow explicit: `.step()` for branching, `.then()` for chaining, and `.after()` for merging. We also added .`.suspend()/.resume()` for human-in-the-loop. We abstracted the main RAG verbs like `.chunk()`, `embed()`, `.upsert(),’ `.query()`, and `rerank()` across document types and vector DBs. We shipped an eval runner with evals like completeness and relevance, plus the ability to write your own. Then we read the MemGPT paper and implemented agent memory on top of AI SDK with a `lastMessages` key, `topK` retrieval, and a `messageRange` for surrounding context (think `grep -C`). But we still weren’t sure whether our agents were behaving as expected, so we built a local dev playground that lets you curl agents/workflows, chat with agents, view evals and traces across runs, and iterate on prompts with an assistant. The playground uses a local storage layer powered by libsql (thanks Turso team!) and runs on localhost with `npm run dev` (no Docker). Mastra agents originally ran inside a Next.js app. But we noticed that AI teams’ development was increasingly decoupled from the rest of their organization, so we built Mastra so that you can also run it as a standalone endpoint or service. Some things people have been building so far: one user automates support for an iOS app he owns with tens of thousands of paying users. Another bundled Mastra inside an Electron app that ingests aerospace PDFs and outputs CAD diagrams. Another is building WhatsApp bots that let you chat with objects like your house. We did (for now) adopt an Elastic v2 license. The agent space is pretty new, and we wanted to let users do whatever they want with Mastra but prevent, eg, AWS from grabbing it. If you want to get started: - On npm: npm create mastra@latest - Github repo: https://github.com/mastra-ai/mastra - Demo video: https://www.youtube.com/watch?v=8o_Ejbcw5s8 - Our website homepage: https://mastra.ai (includes some nice diagrams and code samples on agents, RAG, and links to examples) - And our docs: https://mastra.ai/docs Excited to share Mastra with everyone here – let us know what you think!
442 points · Open discussion

MAKE YOURSELF AT HOME

A few shortcuts

/
Search the collection
?
Open this guide
Esc
Close dialogs and navigation

Your saved repositories and interests stay in this browser.