liveBook · Manning

Knowledge graph

Also called KG

A knowledge graph is a graph-structured representation of entities and their semantically meaningful relationships, often including associated attributes or facts.

How 15 Manning books explain it

AI-Powered Search

A knowledge graph is a graph-structured representation of entities and the relationships and attributes connecting them.

How it is used
Uses knowledge graphs to interpret domain-specific queries and support semantic search and recommendations.
How deep it goes
Explains explicit nodes and edges, then works through semantic graph traversal using inverted and forward indexes and query expansion.
Examples
Works through author-to-conference traversal, related medication terms, and recommendations from scored document terms.
What you can do after
Apply it via Apache Solr and Python to traverse indexed relationships and construct weighted search queries.

Read how AI-Powered Search explains knowledge graph →

Knowledge Graphs and LLMs in Action

A knowledge graph is an evolving graph data structure of typed entities, attributes, and meaningful named relationships that integrates structured and unstructured domain data.

How it is used
Supports domain-specific integration, reasoning, search, recommendation, visualization, machine learning, and grounded intelligent applications.
How deep it goes
Explains structure, semantics, integration, construction, querying, and validation, while deferring complete ontology design and unstructured-data extraction details.
Examples
Uses healthcare, drug discovery, customer support, clinical decision support, biomedical integration, and archival-text graphs as concrete applications.
What you can do after
Build it from scratch using an ontology, mapped data sources, validation, graph queries, visualization, and downstream analysis.

Read how Knowledge Graphs and LLMs in Action explains knowledge graph →

Natural Language Processing in Action, Second Edition

A knowledge graph is a graph-structured representation of entities, concepts, and their relationships.

How it is used
Uses knowledge graphs to store extracted facts and ground chatbot answers.
How deep it goes
Explains triples, relation extraction, multi-hop inference and inspection of a public graph.
Examples
Illustrates military-rank reasoning with Stanislav Petrov and inspects NELL triples using Python.
What you can do after
Apply it via nlpia2 utilities to inspect and simplify NELL knowledge graph data.

Read how Natural Language Processing in Action, Second Edition explains knowledge graph →

Architecting for Autonomy

A governed graph that represents domain entities, assertions, relationships, qualifications, provenance, and authority for organizational use.

How it is used
Preserves reusable enterprise meaning so agents can interpret information within governed legal, evidential, and policy boundaries.
How deep it goes
Defines assertions, operating constraints, governance, and authority boundaries without detailing graph implementation.
Examples
Illustrates contract amendments, supplier obligations, judicial authorities, and evidence supporting factual propositions.
What you can do after
Evaluate and understand which relationships need governance and when uncertain authority requires qualification, further evidence, or reduced agent authority.

Read how Architecting for Autonomy explains knowledge graph →

Domain-Specific Small Language Models

A structured graph representation of entities and relationships used here to enrich RAG with explicit connections among concepts.

How it is used
Augments semantic-similarity RAG with entity relationships for questions requiring connections across documents.
How deep it goes
Works through extraction, graph assembly, community detection, and summary-based answering; defers embedding-backed local search.
Examples
Uses an action-movie graph and Python listings for relationship extraction, graph composition, and community-summary queries.
What you can do after
Build it from scratch with Ollama structured extraction, Pydantic schemas, NetworkX graphs, and community summaries for GraphRAG.

Read how Domain-Specific Small Language Models explains knowledge graph →

Introduction to Generative AI, Second Edition

A knowledge graph is a conceptual representation of entities as nodes and their relationships as edges.

How it is used
Uses a knowledge graph as a conceptual picture of knowledge in a large language model.
How deep it goes
Defines nodes and edges and extends the analogy to confidence, without detailing graph construction.
Examples
Illustrates entities and relationships with a small knowledge graph diagram.
What you can do after
Evaluate/understand how a knowledge graph can provide an intuitive picture of language model knowledge and uncertainty.

Read how Introduction to Generative AI, Second Edition explains knowledge graph →

Essential GraphRAG

A knowledge graph is a structured representation of entities, attributes, and relationships that supports semantic connections among information.

How it is used
Improves RAG by connecting structured facts and unstructured context for accurate, explainable, interconnected retrieval.
How deep it goes
Explains nodes, relationships, mixed data, extraction, JSON output, and graph import, without detailing a complete graph schema.
Examples
Uses employee hierarchies, tasks, articles, legal contracts, payment terms, and active-agreement counts as retrieval examples.
What you can do after
Build it from scratch by extracting structured facts from text, modeling relationships, importing JSON into Neo4j, and supporting precise retrieval.

Read how Essential GraphRAG explains knowledge graph →

WordPress Power Toolkit: Harness AI to build next-level websites

A knowledge graph is a structured network of entities and labeled relationships that represents interconnected knowledge for querying and analysis.

How it is used
Positions knowledge graphs as an optional way to help AI systems analyze website content beyond traditional SEO.
How deep it goes
Introduces structured relationship markup as a practical tip, without giving graph-building steps or implementation details.
Examples
Shows a relationship diagram and names entities, topics, and events as things whose connections can be marked up.
What you can do after
Evaluate/understand it as an option for making relationships in website content easier for AI systems to analyze.

Read how WordPress Power Toolkit: Harness AI to build next-level websites explains knowledge graph →

LLMs in Production

A knowledge graph represents entities and the relationships between them as a graph of nodes and edges.

How it is used
Improves RAG retrieval when questions require traversing relationships among linked entities.
How deep it goes
Defines nodes and edges, compares graph and vector retrieval, and identifies query-generation and document-conversion hurdles.
Examples
Uses Gal Gadot’s relationship to Jaron Varsano and his occupation to illustrate multipart retrieval.
What you can do after
Evaluate when relationship-aware graph retrieval outweighs the simplicity of vector-based document search.

Read how LLMs in Production explains knowledge graph →

Build AI Drug Discovery Pipelines

A knowledge graph is a graph-based representation of entities and the typed relationships between them, supporting structured querying and inference.

How it is used
Supports target discovery and drug-repurposing hypotheses by connecting heterogeneous biomedical and clinical evidence.
How deep it goes
Traces ingestion, relationship extraction, querying, and downstream ranking, but does not specify graph schemas or implementation code.
Examples
Uses PandaOmics integration and BenevolentAI’s baricitinib hypothesis from 350 million biological and clinical relationships.
What you can do after
Apply it via relationship queries that prioritize targets or reveal drug-repurposing hypotheses for expert assessment.

Read how Build AI Drug Discovery Pipelines explains knowledge graph →

The Art of AI Product Development

An organized graph of entities and explicitly represented relationships that can be queried for facts or context.

How it is used
Improves RAG retrieval when entity relationships and connected context matter more than keyword or text similarity alone.
How deep it goes
Explains graph construction, subgraph traversal, hybrid retrieval, and schema tailoring, but defers deeper implementation details.
Examples
Uses companies, products, acquisitions, competition, regulations, and market events as graph entities and relationships.
What you can do after
Build it from scratch by modeling domain entities, defining relationships, traversing subgraphs, and integrating graph retrieval into RAG.

Read how The Art of AI Product Development explains knowledge graph →

AI Agents and Applications

A knowledge graph is a connected representation of entities, relationships, and associated information intended to support querying and reasoning.

How it is used
Supports relationship-aware retrieval, complex querying, reasoning, inference, and explainable answers in LLM applications.
How deep it goes
Defines nodes, edges, triples, extraction, querying, and GraphRAG, but stops short of full database implementation.
Examples
Uses Roberto, Inter Milan, Serie A, RDF triples, a KG-RAG architecture, and a schema-constrained Cypher prompt.
What you can do after
Build it from extracted entities and relationships, query it with SPARQL or Cypher, and synthesize answers from retrieved graph data.

Read how AI Agents and Applications explains knowledge graph →

Graph Neural Networks in Action

A knowledge graph is a heterogeneous graph that represents entities and relationships with explicit semantic context, metadata, and schema information.

How it is used
Supports querying, pattern identification, connection discovery, and relationship inference over richly contextualized heterogeneous data.
How deep it goes
Defines semantic entities, relationships, metadata, and schemas, then illustrates them through an academic network without implementation details.
Examples
Uses a university physics research network containing professors, students, papers, topics, departments, and typed relationships.
What you can do after
Evaluate how explicit semantics and metadata enable more targeted graph queries and analysis.

Read how Graph Neural Networks in Action explains knowledge graph →

AI Agents in Action, Second Edition

A knowledge graph is a graph-structured representation of entities, entity types, observations, and relationships among them.

How it is used
Supports relationship-aware retrieval and persistent long-term memory for agents.
How deep it goes
Explains nodes, edges, observations, traversal, and memory workflows, while deferring graph database internals.
Examples
Uses a Back to the Future script, Micheal-to-Calgary relationship, and agent experiences as concrete graph examples.
What you can do after
Operate/configure a local MCP memory server and structure agent experiences for retrieval, recording, and relation building.

Read how AI Agents in Action, Second Edition explains knowledge graph →

Context Engineering

A graph-structured representation of entities and their relationships.

How it is used
Organizes external domain knowledge for retrieval across linked relationships in graph-based RAG.
How deep it goes
Defines graph elements and compares property graphs with RDF, including RDF trade-offs and inference.
Examples
Uses people, organizations, products, and locations as entities, with relationships such as “manufactures” and “located in.”
What you can do after
Understand how graph structure supports linked retrieval and how property graphs differ from RDF.

Read how Context Engineering explains knowledge graph →

Also covered in

What to know first

Related concepts

Questions about knowledge graph

What is knowledge graph?

A knowledge graph is a graph-structured representation of entities and their semantically meaningful relationships, often including associated attributes or facts.

Which Manning books explain knowledge graph?

AI-Powered Search, Knowledge Graphs and LLMs in Action, Natural Language Processing in Action, Second Edition, Architecting for Autonomy, Domain-Specific Small Language Models, Introduction to Generative AI, Second Edition, Essential GraphRAG, WordPress Power Toolkit: Harness AI to build next-level websites and 7 more.

What should I know before learning knowledge graph?

Manning books that teach knowledge graph usually introduce similarity search, graph database, language model and edge first.

What is knowledge graph a kind of?

Knowledge graph is a kind of graph. A graph is a mathematical structure consisting of vertices and edges that connect pairs of vertices to represent relationships or connections.

What are the parts of knowledge graph?

Knowledge graph includes edge.

What is knowledge graph also called?

Knowledge graph is also called KG.

These guides are generated from the text of Manning books by Manning's knowledge graph and link to the sections they draw on. The full books are available on liveBook and at manning.com.