No. 469 of 500 No. 61 in Generative AI & LLMs

Learning LangChain

Building AI and LLM Applications with LangChain and LangGraph

By Mayo Oshin and Nuno Campos

Print length
294 pages
Publisher
O'Reilly Media
Reading level
Intermediate
ISBN-13
978-1098167288
Published
March 25, 2025
Written for
Python or JavaScript developers building their first RAG applications or LangGraph agents.

Synopsis

Learning LangChain is a guided tour of building LLM applications with LangChain, the open-source framework, and LangGraph, its library for stateful, multi-step agent workflows. Mayo Oshin and Nuno Campos write for developers who know Python or JavaScript but are new to AI, and they show nearly every example in both languages. The book opens with prompts, chat models and the framework's building blocks, then spends two chapters on retrieval-augmented generation: loading and chunking documents, embedding them in a vector store, and retrieving the right passages to ground a model's answer. Later chapters add conversational memory, explain the cognitive architectures that range from a single LLM call to autonomous agents, and build agents that call tools, reflect on their output and coordinate with other agents.

The final third turns to production concerns that many tutorials skip: structured output, streaming, human-in-the-loop checkpoints, deployment with a hosted vector store and the LangGraph Platform, and evaluation and monitoring with LangSmith. Readers come away with a working mental model of how RAG pipelines and agent graphs fit together, and with code they can adapt to their own data. Because Campos was LangChain's first employee and created LangGraph, the explanations reflect the framework's design intent, though the libraries have continued to change since publication.

Scorecard

Editorial score

How it scored

Editorial score: 65.3 / 1005 weighted criteria

  • Influence30%

    16.5/30
  • Authority25%

    20.0/25
  • Practical value20%

    14.0/20
  • Currency15%

    8.3/15
  • Readability10%

    6.5/10
  • Editorial score

    65.3/100

How the rank was computed

Rank No. 469 of 500 comes from a composite of 48.0: observable signals 18.7 of 55 points plus editorial review 29.3 of 45 points.

All 11 inputs
InputPoints
Observable signals18.7/55
Reach (Amazon ratings volume)5.3/16.5
Consensus across best-of lists5.5/13.8
Awards and bestseller evidence0.0/8.3
Reader rating, sample-adjusted4.6/8.3
Amazon sales rank0.5/5.5
Recency2.8/2.8
Editorial review29.3/45
Author authority9.0/11.3
Influence7.4/13.5
Practical value6.3/9.0
Readability2.9/4.5
Currency3.7/6.8

Each criterion is scored from 1 to 10 and weighted, and the points add up to the editorial score. The rank combines observable signals (55 percent) with this score (45 percent). Read the methodology.

Verdict

A clear, code-first introduction to RAG and LangGraph agents, co-written by LangGraph's creator, though fast-moving APIs date some examples.

Strengths

  • Co-written by LangGraph's creator at LangChain
  • Parallel Python and JavaScript code throughout
  • Covers deployment, evaluation and monitoring, not only prototyping

Keep in mind

LangChain's APIs change quickly, so some code no longer runs as printed, and readers wanting deep explanations of internals will find coverage brief.

Key takeaways

  1. Retrieval-augmented generation grounds an LLM in your own documents by indexing, chunking and embedding them, then retrieving relevant passages at query time.
  2. LLM applications sit on a spectrum of autonomy, from fixed chains to routers to full agents, and more autonomy usually costs some reliability.
  3. LangGraph models an application as a graph of nodes sharing state, which makes memory, branching, loops and human approval steps explicit.
  4. A working prototype is not production-ready until it has evaluation datasets, tracing and monitoring, and LangSmith supplies tooling for each.

Notable facts

About the author

Mayo Oshin and Nuno Campos

Mayo Oshin is an AI and data technologist, early LangChain contributor and LangChain Ambassador whose open-source AI PDF chatbot built on LangChain has more than 16,500 GitHub stars; he has trained engineers and product managers from Amazon, LinkedIn, Visa and BCG. Co-author Nuno Campos is a founding engineer at LangChain, its first employee and the creator of LangGraph.

Questions

Is Learning LangChain worth reading in 2026?
It remains useful for understanding RAG pipelines, agent architectures and LangGraph's state-graph model, which still underpin the framework. LangChain's APIs have changed since the 2025 printing, however, so readers should check examples against the current documentation rather than copying code directly from the page, and expect some import paths and method names to differ.
Who should read Learning LangChain?
Developers comfortable in Python or JavaScript who are new to building with large language models. The book suits engineers asked to add document question-answering or agent features to a product. Experienced LangChain users and machine learning researchers will find it introductory, and nontechnical managers will find the code-heavy chapters hard to follow.
What is Learning LangChain about?
It teaches how to build LLM applications with LangChain and LangGraph. Chapters move from prompts and chat models to retrieval-augmented generation, conversational memory, agent architectures and multi-agent patterns, then cover structured output, human review steps, deployment, evaluation and monitoring. Examples appear in both Python and JavaScript, and the throughline is a production-ready agent that answers questions using your own data.

Sources

As an Amazon Associate, Best AI Books earns from qualifying purchases. Best AI Books is sponsored by Iternal.ai, whose founder and CEO, John Byron Hanby IV, wrote The AI Strategy Blueprint, our #1 ranked book. How we rank books.