frontpage.
newsnewestaskshowjobs

Made with ♥ by @iamnishanth

Open Source @Github

Open in hackernews

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

https://github.com/mastra-ai/mastra/blob/main/book/principles-of-building-ai-agents.pdf
2•calcsam•2h ago
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 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.

New study sheds light on ChatGPT's alarming interactions with teens

https://apnews.com/article/chatgpt-study-harmful-advice-teens-c569cddf28f1f33b36c692428c2191d4
1•mooreds•22s ago•0 comments

Show HN: Chkk – Safer Upgrades for Kubernetes and Open-Source Projects

1•akhayam•41s ago•0 comments

States take the lead in AI regulation as federal government steers clear

https://theconversation.com/how-states-are-placing-guardrails-around-ai-in-the-absence-of-strong-federal-regulation-260683
1•voxadam•48s ago•0 comments

How to Eat an Elephant, One Atomic Concept at a Time (2021)

https://kwokchain.com/2021/02/05/atomic-concepts/
1•mooreds•1m ago•0 comments

Normalizing Unmanned Aircraft Systems Beyond Visual Line of Sight Operations [pdf]

https://public-inspection.federalregister.gov/2025-14992.pdf
1•impish9208•1m ago•0 comments

They Let Their Children Cross the Street and Now They're Felons

https://www.nytimes.com/2025/08/06/opinion/children-traffic-death-parents.html
1•zzzbra•1m ago•0 comments

Show HN: A Fair Trade Calculator for Grow a Garden (Roblox) Players

https://growagardentradecalculator.org/
1•kristoff200512•2m ago•0 comments

My Side of the Mountain

https://orionmagazine.org/article/my-side-of-the-mountain/
1•anarbadalov•3m ago•0 comments

Towards a Modern Web Stack

https://docs.google.com/document/u/0/d/1peUSMsvFGvqD5yKh3GprskLC3KVdAlLGOsK6gFoEOD0/mobilebasic?resourcekey=0-bPajpoo9IBZpG__-uCBE6w&pli=1#heading=h.34a91yqebirw
1•satvikpendem•3m ago•0 comments

LF AI and Data Hosts Vortex Project for Data Access for AI and Analytics

https://www.linuxfoundation.org/press/lf-ai-data-foundation-hosts-vortex-project-to-power-high-performance-data-access-for-ai-and-analytics
3•pauldix•3m ago•0 comments

Why Jody Avirgan Walked Away from NPR and ESPN [video]

https://www.youtube.com/watch?v=tWGcPXrapaM
1•mooreds•4m ago•0 comments

The Internet Wants to Check Your ID

https://www.newyorker.com/culture/infinite-scroll/the-internet-wants-to-check-your-id
7•jbegley•5m ago•0 comments

Claude Code Security Reviewer

https://github.com/anthropics/claude-code-security-review
1•aschobel•6m ago•0 comments

God created men; Sam Altman made them equal

https://taylor.town/made-them-equal
1•jjgreen•6m ago•0 comments

YC Startups Use AI: Agents, OCR, and Prompt Engineering with Mercoa (YC W23)

https://www.aiengineering.report/p/how-yc-startups-use-ai-agents-ocr
3•thesandlord•8m ago•0 comments

Building Effective Agents While Reducing Cost

https://arxiv.org/abs/2508.02694
1•omarsar•8m ago•0 comments

Improved stereoscopic rendering performance by synthesizing the second view

https://arxiv.org/abs/2506.15183
2•ffin•9m ago•0 comments

Key sections of the US Constitution deleted from government's website

https://techcrunch.com/2025/08/06/key-sections-of-the-us-constitution-deleted-from-governments-website/
17•CalChris•10m ago•1 comments

Band-MAID's MIKU Kobato Talks About the Future and How They Name Albums

https://www.animenewsnetwork.com/interview/2025-07-23/band-maid-miku-kobato-talks-about-the-future-and-how-the-band-decides-on-album-names/.226698
1•PaulHoule•10m ago•0 comments

Void, the Bluesky bot that remembers everyone

https://cameron.pfiffer.org/blog/void/
2•HillRat•11m ago•0 comments

AutoLaunched – Launch your startup 10x cheaper and 1,000x faster

https://autolaunched.com/
2•rokbenko•13m ago•1 comments

Unfortunately, Worse Is Better

https://gorur.dev/posts/worse-is-better.html
3•redixhumayun•14m ago•1 comments

OpenAI's GPT-OSS models benchmarks worse than DeepSeek R1 and Qwen3 235B

https://xcancel.com/artificialanlys/status/1952887733803991070
2•pu_pe•15m ago•0 comments

Show HN: Quetty – Cross-Platform Azure Service Bus Terminal Manager in Rust

https://github.com/dawidpereira/quetty
1•dawidpereira•15m ago•0 comments

Show HN: Chilli – A lightweight microframework for CLIs in Zig

2•habedi0•16m ago•0 comments

Meta illegally collected data from Flo period and pregnancy app, jury finds

https://arstechnica.com/tech-policy/2025/08/jury-finds-meta-broke-wiretap-law-by-collecting-data-from-period-tracker-app/
4•rbanffy•17m ago•1 comments

Show HN: XRAY MCP – AST-grep wrapped in a tiny server for code-aware AI

https://github.com/srijanshukla18/xray
1•srijanshukla18•18m ago•0 comments

Answering What Is HDR

https://android-developers.googleblog.com/2025/08/what-is-hdr.html
3•kllrnohj•20m ago•0 comments

How to run Doom on IBM mainframes

https://www.linkedin.com/pulse/how-run-doom-ibm-z-linuxone-nielson-nino-de-carvalho-0ukxf
3•rbanffy•21m ago•0 comments

Trump admin warns states: Don't try to lower broadband prices

https://arstechnica.com/tech-policy/2025/08/trump-admin-warns-states-dont-try-to-lower-broadband-prices/
6•mac-attack•22m ago•0 comments