Reasoning is one of the most exciting and important recent advances in improving LLMs, but it’s also one of the easiest to misunderstand if you only hear the term reasoning and read about it in theory. That’s why this book takes a hands-on approach. We’ll start with a pre-trained base LLM and then add reasoning capabilities ourselves, step by step in code, so you can see exactly how it works.
This book isn’t a “production deployment” manual, and we won’t use any third-party LLM libraries. Instead, think of it as a behind-the-scenes tour where you get to develop the machinery yourself.
By the end, you will not only understand what reasoning is and how it works, but you will also have built it from scratch. That’s a perspective that will serve you well whether you are using, developing, or planning to deploy LLMs in the future.



