Share E-Book
Scan to open this page

Scan with your phone to open this page

Author: Jungjun Hur, Younghee Son, Roberto Infante, Peter Belcak, Micheal Lanham

Rating No ratings yet

• What is an AI agent? Chapter 1 from Build an AI Agent (From Scratch) by Jungjun Hur and Younghee Song • Building tool-based agents with LangGraph Chapter 11 from AI Agents and Applications by Roberto Infante • Errand: Breaking complex workflows into units Chapter 3 from Agent Design Patterns by Peter Belcak • Building robust agents with evaluation and feedback Chapter 7 from AI Agents in Action, Second Edition by Micheal Lanham

AI Reading Assistant

Whole-book reading guide from stratified index samples; jump to passages in the text

AI guide
【One-Line Pitch】 A practical sampler that turns the vague idea of "AI agents" into an engineering discipline: it shows when to hand control to a model, how to wire tools and state into a working loop, how to break messy workflows into testable units, and how to evaluate and improve the result. Best for developers and technical leads who already know some LLM basics and want a mental model they can debug, not just a framework to copy. 【Book Arc】 - **Opening (~0%–10%)**: Frames the whole sampler and defines what an agent actually is — an LLM given tools plus a loop that decides its own next step — and contrasts this with developer-defined workflows. - **Early (~10%–32%)**: Builds the conceptual foundation: the LLM/tool/loop triad, the workflow-vs-agent spectrum (chains, routers, tool-using loops), criteria for when a task needs an LLM and when it needs an agent, and the GAIA benchmark as a practice ground. - **Early–Middle (~32%–42%)**: Shifts from "what is an agent" to "why agents fail," introducing context engineering — prompt vs. context, information deficiency as a leading failure cause, and the generate/retrieve/write/reduce/isolate strategies. - **Middle (~42%–48%)**: Moves into hands-on construction with LangGraph: project setup, a travel-information agent, registering and executing tools, conversation state, and vector-store retrieval for grounding. - **Late (~48%–63%)**: Continues the LangGraph build toward conditional routing, inspecting messages and tool calls, debugging execution, and comparing a custom graph with the prebuilt ReAct agent. - **Late–Ending (~63%–100%)**: Introduces the "errand" pattern for splitting complex workflows into focused, testable units, then closes with evaluation and feedback loops for making agents robust. 【Key Takeaways】 - **An agent is defined by autonomous control flow** (Early): the LLM decides what to do next and when to stop, rather than following hardcoded branches — this single distinction separates agents from workflows. - **Three elements make autonomy real: LLM + tools + loop** (Early): the model is the brain, tools extend its action space into the world, and the loop unfolds decisions over time until the goal is met. - **Workflow vs. agent is a cost/value trade-off, not a dogma** (Early): agents buy flexibility but cost more LLM calls and are harder to control; production systems typically mix both, using agents only where flexibility genuinely pays. - **Ask two questions before building** (Early): does this task need an LLM at all, and if so, does it need an agent or will a workflow suffice? "No" at either stage means pick the simpler, cheaper option. - **Most real-world agent failures are information failures, not intelligence failures** (Early–Middle): if the needed facts aren't in context, even a strong model fails — which is why context engineering matters more than prompt phrasing. - **Context engineering has five reusable moves** (Middle): generate, retrieve, write, reduce, and isolate — a framework for feeding the model the right information at the right time and preventing context rot. - **LangGraph makes the loop concrete and inspectable** (Middle–Late): registering tools, holding state, adding conditional routing, and reading message/tool-call traces turn agent behavior into something you can debug rather than guess at. - **Complex workflows should be decomposed into "errands"** (Late): small, focused, testable routines keep behavior manageable as systems grow, and evaluation plus feedback closes the improvement loop. 【Reading Tips】 - **Deep-read the opening chapter's workflow-vs-agent comparison** — it's the decision framework the rest of the book assumes; skim the GAIA benchmark details if you're not planning to benchmark. - **Treat the LangGraph chapter as a lab, not prose**: follow the setup, tool registration, and routing steps in code, and pay attention to how messages and tool calls are inspected — that's where debugging skill comes from. - **Read the context-engineering section twice**: the five strategies (generate/retrieve/write/reduce/isolate) are the most transferable ideas and apply regardless of framework. - **Skim the errand and evaluation chapters first for structure**, then return when your own agent gets too tangled to test — they're most useful once you have something to refactor. - **Budget for the tooling**: the excerpts mention Python package setup, an OpenAI API key, and a Tavily search key, with exercises estimated under $10 — set these up before starting the hands-on chapter. 【Coverage Limits】 This guide is based on stratified excerpts from a four-chapter sampler, so it reflects the book's framing and early-to-mid material more than its full depth; specific code listings, later chapters, and detailed evaluation mechanics are only partially covered. The excerpts do not cover the complete errand and feedback chapters in detail.
Page 6
” from Build an AI Agent (From Scratch) by Jungjun Hur and Younghee Song, starts with explaining the three elements behind agent auton- omy. Then, you’ll com...
View in text
Excerpt 2
e lens of the agent loop. 3 Add information to LLM context. 1 2 Need tool? Execute. User: 2024 Nobel Physics LLM Tool Tool result Decide to use tool. 4 Enoug...
View in text
Page 20
, tool execution results, and retrieved documents. In this sense, prompts are one component of context. Think of context as the LLM’s working memory. Just as...
View in text
Excerpt 4
h components ¡ Observing agent execution with LangSmith You learned that agentic workflows are fundamentally deterministic: their logic is based on flows wit...
View in text
Excerpt 5
fing in question to ➥ Cornwall."} answer) tools=[search_travel_info_tool], Registers the tool so the model tool_choice="auto", knows it can call it if needed...
View in text
Excerpt 6
ow ready to run your first agent-based chatbot. Try asking it about destinations or activities in Cornwall, and experience how the agent reasons, retrieves i...
View in text
Excerpt 7
d won’t pick them from its own “knowledge.” This minimizes hallucinations and guarantees the data used comes from your knowledge base. Continue stepping thro...
View in text
Excerpt 8
tputs across tools with the LLM orchestrating the sequence. For example, search_customer → get_orders → calculate_total hap- pens automatically based on the...
View in text
Tags
AI categories
Artificial IntelligenceAIProgramming
ISBN: 1638359261
Publish Year: 2026
Language: English
Pages: 105
File Format: PDF
File Size: 7.1 MB
Text Preview (First 20 pages)
Registered users can read the full content for free

Register as a Gaohf Library member to read the complete e-book online for free and enjoy a better reading experience.

Generating text preview…