TrendWhat rose on GitHub, every day at 07:30 KST · 한국어

GitHub · as of November 8, 2026 · View on GitHub →

bojieli/ai-agent-book

Open-source AI agent book

+622 stars in 7 days

Build agent systems by studying design principles and 109 experimental code examples

You can examine how models read context and use tools through code, and build agent systems yourself. The book centers on the formula 'agent = LLM + context + tools,' showing step by step how to move from theory to working systems. Version 2.0 integrates multimodal and asynchronous processing content to restructure the material, and provides the latest PDF and translations in 15 languages.

Version 2.0 structural changes and latest content

The repository was recently updated from version 1.4 to version 2.0. The major change is the reorganization of the former Chapter 4 'Asynchronous Interaction' and Chapter 9 'Multimodal Agents' into a new Chapter 6 'Interaction: Expanding the Space of Observation and Action.' Consequently, the chapters on evaluation, model post-training, and continuous evolution were renumbered to 7, 8, and 9, respectively. If you are reading an older PDF, it is advisable to switch to the latest version, as this update includes content revisions and adjustments. A companion book on AI infrastructure is also available, which helps in understanding the infrastructure of model-based applications.

A learning path across 10 chapters

The entire content is divided into 10 chapters, covering agent fundamentals through production environment application. Chapter 1 defines the core components of an agent, and Chapter 2 discusses how to raise model capability limits through context engineering. Chapter 3 explains how to connect external knowledge using user memory and RAG (Retrieval-Augmented Generation), while Chapter 4 describes the MCP protocol and tool discovery mechanisms. Chapter 5 emphasizes the role of tools that create tools, focusing on coding agents, and Chapter 6 covers methods for broadening the scope of observation and action, such as voice, computer use, and robot manipulation. Chapter 7 details evaluation systems for measuring agent performance, Chapter 8 covers model post-training strategies using SFT and RL, Chapter 9 explains how to obtain learning signals from execution trajectories to evolve agents, and Chapter 10 describes multi-agent collaboration and social phenomena.

Setting up and running the experimental environment

All experiments support Python 3.11 through 3.13. uv is recommended for installing dependencies, and the uv sync --locked --extra ch1 command sets up the environment for the corresponding chapter. If uv is not available, you can use python -m pip install -e ".[ch1]". Experiments requiring model calls need you to copy .env.example to .env and enter your API key. Some experiments are specified to use local Ollama, in which case you must add the --provider ollama option.

Pre-execution checks and requirements

The book does not require deep knowledge of mathematics or machine learning, but you should be able to read and modify intermediate-level Python code. Experience using LLM products like ChatGPT or Claude and familiarity with AI-assisted coding tools (such as Claude Code and Codex) are helpful. The post-training experiments in Chapter 8 may require Python 3.12 or higher and a GPU environment, and some external repositories (such as robot simulators and browser automation tools) must be cloned separately. Since all experimental code was generated by coding agents, it is better to focus on understanding the architecture and design principles rather than trying to understand every line. The license is Apache License 2.0, and some sub-projects may have separate licenses, so verification is necessary.

Written by AI from this repository's README on September 26, 2026. For the facts, the original on GitHub is the reference.

By the numbers

GitHub trending history
15 days between Jun 19, when Trend began recording, and Nov 8, 2026 · first on Jul 21 · best daily rank #2 (Jul 21)

Read from GitHub, as of November 8, 2026.

Language
Python
Topics
agent · agent-memory · ai-agent · book · coding-agent · context-engineering · large-language-models · llm
Stars
57,463
Stars gained in 7 days
+622
Contributors
92
Forks
6,644
Commits
1,812
Last commit
September 30, 2026
Open issues
26
Open pull requests
31

Related repositories

View on GitHub →

README badge

trend.ondo.sh · GitHub daily trending #2 · July 21, 2026

The badge above shows the highest this repository has ranked on GitHub's daily trending since June 19, 2026, and the day it did. Paste the Markdown below into your README. The badge opens this page, and it updates by itself when the repository climbs higher.

[![trend.ondo.sh](https://trend.ondo.sh/github/r/bojieli--ai-agent-book/badge.en.svg)](https://trend.ondo.sh/github/r/bojieli--ai-agent-book/en.html)