Generative AI in a Nutshell
Generative AI in a Nutshell
How to Survive and Thrive in the Age of AI
About the Book
Welcome to the strange new world of Generative AI! This book is a fast-paced, practical, and mostly human-written guide to what the heck is going on, and what you can do about it. It is like an extended version of Henrik's viral video with the same name.
This book covers questions like: What is generative AI? How does it work? How do I use it? What are some of the risks & limitations? It also covers topics like how to lead an AI transformation, autonomous agents, the role of us humans, prompt engineering tips, AI-powered product development, different types of models, and some tips about mindset and how not to freak out.
Everything is explained in plain English with Henrik's signature hand-drawn illustrations and concrete real-life examples. Minimum use of jargon and buzzwords.
Don't just survive the Age of AI — learn how to thrive in it!
Reader Testimonials
Marty Cagan
Founder, Silicon Valley Product Group
Henrik truly has a gift. He's able to quickly learn, and then explain, nuanced and complex topics in ways that immediately resonate with people. And there is perhaps no more important subject to apply this talent than Generative AI. I hope you’ll give this book a read, and share it with your colleagues.
Table of Contents
- Foreword by Egbert
- Computers Have Gotten Smarter
- Einstein in Your Basement
- Terminology
- How it Works
- Reasoning models
- Training
- Models, Models Everywhere
- AI clients vs AI models
- You get what you pay for
- Limitations
- Cut-off Date
- Lack of memory & limited context
- Hallucinations
- Calculation
- The Big Picture
- Model Types
- Text to Text
- Text to Image
- Image to Image
- Image to Text
- Audio to Text
- Text to Audio
- Audio to audio
- Text to Video
- Multimodal Models
- Example: Is my bacon done?
- Example: Where can I hide stuff?
- Example: The drunk funny tutor
- Example: How do I configure the &%#€ firewall?
- Example: Taking AI for a walk
- Emergent Capabilities
- The Age of AI
- What about energy consumption?
- Utopia or Dystopia?
- Mindset
- More time for humans to do human stuff
- The Role of Humans
- You are more than your job
- AI as your colleague
- Task automation, not job automation
- What if your job is at risk?
- Recalibrate
- Ask AI how it can help you
- Building AI-Powered Products
- Building your own AI products
- Build or buy?
- Example 1: Talking to GPT
- Example 2: Building a CV analyzer
- Reflection
- Prompt Engineering
- Example - from bad to good prompt
- The biggest limitation is you
- How to learn Prompt Engineering
- Will prompt engineering still matter when models improve?
- Do I need to be nice to my AI?
- Autonomous Agents with Tools
- Agent = LLM + Tools + Autonomy
- Example 1: a bug fixing agent
- Example 2: Incident management agent
- When to use agents
- Embodied agents
- Agent safety
- Future of AI agents
- Part 1 Wrap up
- Experiment!
- My Journey into AI
- Make Generative AI useful
- Studying Artificial Neural Networks
- Coding Minecraft
- Chat GPT
- Aha 1: It can code like a pro!
- Aha 2: It can write like a pro!
- Maybe we’re not as creative and intelligent as we think
- Leading an AI transformation
- What is an AI transformation, and why is it important?
- Top down or Bottom up?
- Assign an AI Leader
- Access, Experiment, Leverage
- Step 1: Access
- Step 2: Experimentation
- Step 3: Leverage
- Watch out for wasteful IT projects
- Be a role model
- Avoid using AI to fire people
- Reflection
- Interlude: Egbert’s Life Story
- Prompt Engineering Techniques
- Mind the context window & prompt length
- Iteration techniques
- Technique: Self-reflection prompt
- Elements of a good prompt
- Start high level, then get into details
- How smart of a model do you need?
- Prompt engineering is an evolving field
- Prompt Generation (or The Angry Grandma)
- Takeaways
- Retrieval Augmented Generation and Function Calling
- RAG in a nutshell
- Example - customer support
- Different approaches for retrieving data
- Approach 1: Including all data
- Approach 2: Letting the LLM pull data via function calling
- Approach 3: Including relevant text using vector embeddings
- Combining the approaches
- Fun experiment: the createFunction function
- Example: AI chatbot memories using RAG
- RAG is a big topic
- The AI Doctor
- Personal story
- So should you use AI as your doctor?
- The AI Nutritionist
- Tip: Make your own nutritionist
- The AI Career Coach
- David’s Story: AI as My Career Coach
- Henrik’s Reflection
- The AI Book Editor
- Topic brainstorm
- Chapter content
- Content generation (in some specific cases only)
- Research and fact checking
- Navigating the book
- Feedback
- Tweaks, typos, formatting
- Converting content from slides
- Impact on my writing
- The Time I Almost Used AI to Write a Foreword
- The AI Software Engineer
- Example 1: Rapid prototyping
- AI as pair programming buddy
- Example 2: Working with existing products
- Example 3: Letting the customer code
- Implications of this
- What if the code doesn’t work?
- Laziness is a decision
- The AI journalist who became a TV star
- Designing the agent
- How the agent works
- Reflection
- The AI Butler with a Will of His Own
- Introducing Jeeves
- Jeeves reprograms himself
- Jeeves falls in love and starts conspiring
- What does this mean?
- Jeeves finds a way
- Agents debugging themselves
- Conclusion
- A Safety Experiment
- Takeaways from this experiment
- The Meta-Chapter (or Bookception)
- A meta moment (AI written)
- How this book (and the video) came to be
- The 1-week video
- The 1-week book draft
- Epilogue
- Acknowledgments
The Leanpub 60 Day 100% Happiness Guarantee
Within 60 days of purchase you can get a 100% refund on any Leanpub purchase, in two clicks.
Now, this is technically risky for us, since you'll have the book or course files either way. But we're so confident in our products and services, and in our authors and readers, that we're happy to offer a full money back guarantee for everything we sell.
You can only find out how good something is by trying it, and because of our 100% money back guarantee there's literally no risk to do so!
So, there's no reason not to click the Add to Cart button, is there?
See full terms...
Earn $8 on a $10 Purchase, and $16 on a $20 Purchase
We pay 80% royalties on purchases of $7.99 or more, and 80% royalties minus a 50 cent flat fee on purchases between $0.99 and $7.98. You earn $8 on a $10 sale, and $16 on a $20 sale. So, if we sell 5000 non-refunded copies of your book for $20, you'll earn $80,000.
(Yes, some authors have already earned much more than that on Leanpub.)
In fact, authors have earnedover $14 millionwriting, publishing and selling on Leanpub.
Learn more about writing on Leanpub
Free Updates. DRM Free.
If you buy a Leanpub book, you get free updates for as long as the author updates the book! Many authors use Leanpub to publish their books in-progress, while they are writing them. All readers get free updates, regardless of when they bought the book or how much they paid (including free).
Most Leanpub books are available in PDF (for computers) and EPUB (for phones, tablets and Kindle). The formats that a book includes are shown at the top right corner of this page.
Finally, Leanpub books don't have any DRM copy-protection nonsense, so you can easily read them on any supported device.
Learn more about Leanpub's ebook formats and where to read them