Skip to Content
Knowledge Graphs and LLMs in Action
book

Knowledge Graphs and LLMs in Action

by Fabio Montagna, Giuseppe Futia, Alessandro Negro, Vlastimil Kus
October 2025
Intermediate to advanced
472 pages
16h 25m
English
Manning Publications

Overview

Combine knowledge graphs with large language models to deliver powerful, reliable, and explainable AI solutions.

Knowledge graphs model relationships between the objects, events, situations, and concepts in your domain so you can readily identify important patterns in your own data and make better decisions. Paired up with large language models, they promise huge potential for working with structured and unstructured enterprise data, building recommendation systems, developing fraud detection mechanisms, delivering customer service chatbots, or more. This book provides tools and techniques for efficiently organizing data, modeling a knowledge graph, and incorporating KGs into the functioning of LLMs—and vice versa.

In Knowledge Graphs and LLMs in Action you will learn how to:

  • Model knowledge graphs with an iterative top-down approach based in business needs
  • Create a knowledge graph starting from ontologies, taxonomies, and structured data
  • Build knowledge graphs from unstructured data sources using LLMs
  • Use machine learning algorithms to complete your graphs and derive insights from it
  • Reason on the knowledge graph and build KG-powered RAG systems for LLMs

In Knowledge Graphs and LLMs in Action, you’ll discover the theory of knowledge graphs then put them into practice with LLMs to build working intelligence systems. You’ll learn to create KGs from first principles, go hands-on to develop advisor applications for real-world domains like healthcare and finance, build retrieval augmented generation for LLMs, and more.

About the Technology
Using knowledge graphs with LLMs reduces hallucinations, enables explainable outputs, and supports better reasoning. By naturally encoding the relationships in your data, knowledge graphs help create AI systems that are more reliable and accurate, even for models that have limited domain knowledge.

About the Book
Knowledge Graphs and LLMs in Action shows you how to introduce knowledge graphs constructed from structured and unstructured sources into LLM-powered applications and RAG pipelines. Real-world case studies for domain-specific applications—from healthcare to financial crime detection—illustrate how this powerful pairing works in practice. You’ll especially appreciate the expert insights on knowledge representation and reasoning strategies.

What's Inside
  • Design knowledge graphs for real-world needs
  • Build KGs from structured and unstructured data
  • Apply machine learning to enrich, complete, and analyze graphs
  • Pair knowledge graphs with RAG systems


About the Reader
For ML and AI engineers, data scientists, and data engineers. Examples in Python.

About the Authors
Alessandro Negro is Chief Scientist at GraphAware and author of Graph-Powered Machine Learning. Vlastimil Kůs, Giuseppe Futia, and Fabio Montagna are seasoned ML and AI professionals specializing in Knowledge Graphs, Large Language Models, and Graph Neural Networks.

Quotes
Comprehensive, pragmatic, definitive.
- Paco Nathan, Senzing

Builds understanding both at a theoretical and a practical level.
- Corey L. Lanum, Visualization Partners

An excellent introduction to building KG and LLM-powered applications.
- Dave Bechberger, Author of Graph Databases in Action

Comprehensive and well thought out! The authors hit it out of the park again.
- Sujit Pal, Elsevier

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.

Read now

Unlock full access

More than 5,000 organizations count on O’Reilly

AirBnbBlueOriginElectronic ArtsHomeDepotNasdaqRakutenTata Consultancy Services

QuotationMarkO’Reilly covers everything we've got, with content to help us build a world-class technology community, upgrade the capabilities and competencies of our teams, and improve overall team performance as well as their engagement.
Julian F.
Head of Cybersecurity
QuotationMarkI wanted to learn C and C++, but it didn't click for me until I picked up an O'Reilly book. When I went on the O’Reilly platform, I was astonished to find all the books there, plus live events and sandboxes so you could play around with the technology.
Addison B.
Field Engineer
QuotationMarkI’ve been on the O’Reilly platform for more than eight years. I use a couple of learning platforms, but I'm on O'Reilly more than anybody else. When you're there, you start learning. I'm never disappointed.
Amir M.
Data Platform Tech Lead
QuotationMarkI'm always learning. So when I got on to O'Reilly, I was like a kid in a candy store. There are playlists. There are answers. There's on-demand training. It's worth its weight in gold, in terms of what it allows me to do.
Mark W.
Embedded Software Engineer

You might also like

Building Knowledge Graphs

Building Knowledge Graphs

Jesús Barrasa, Jim Webber
Learning LangChain

Learning LangChain

Mayo Oshin, Nuno Campos
Hands-On Large Language Models

Hands-On Large Language Models

Jay Alammar, Maarten Grootendorst

Publisher Resources

ISBN: 9781633439894Publisher SupportPublisher Website