Vector space
A vector space is a set equipped with vector addition and scalar multiplication over a field that satisfy the vector-space axioms.
AI-Powered Search
A vector space is a mathematical space whose elements are vectors defined over a common set of dimensions.
- How it is used
- Uses shared vector spaces to compare queries and documents for search ranking and semantic retrieval.
- How deep it goes
- Explains dimensions, vector mapping, similarity, and embedding chunking through practical search examples rather than formal vector-space axioms.
- Examples
- Maps an “apple juice” query and two documents into a 48-term space and illustrates embeddings with food attributes.
- What you can do after
- Evaluate and understand how shared dimensions support query–document comparison and semantic retrieval.
Natural Language Processing in Action, Second Edition
A vector space is a mathematical set of vectors that can be combined through operations such as addition and scalar multiplication.
- How it is used
- Frames vectors as computable representations for text similarity, distance calculations, and language-model operations.
- How deep it goes
- Explains coordinates, dimensionality, ordering, Euclidean geometry, dot products, and embedding analogies without developing formal axioms.
- Examples
- Uses latitude–longitude coordinates, graph-paper geometry, plotted term-frequency vectors, document vectors, and a sports-team analogy.
- What you can do after
- Apply vector representations to calculate similarity, preserve feature ordering, visualize low-dimensional points, and interpret embedding arithmetic.
Read how Natural Language Processing in Action, Second Edition explains vector space →
Generative AI in Action
A vector space is a mathematical set of vectors that supports operations such as addition and scalar multiplication.
- How it is used
- Supports semantic comparison and machine-readable representations for generative AI, search, classification, and language applications.
- How deep it goes
- Defines vectors, distances, and contextual meaning with examples, but defers detailed similarity algorithms and mathematical derivation.
- Examples
- Uses cat and dog vectors, embedding distances, an OpenAI Python call, and contextual representations of text and code.
- What you can do after
- Apply it via an embeddings API to convert text into vectors and inspect their dimensions and values.
LLM Evaluation and Alignment, The Foundational Ideas
A vector space is a mathematical space whose elements are vectors that can be combined through vector addition and scalar multiplication.
- How it is used
- Frames semantic evaluation as geometric comparison between vector representations rather than exact lexical matching.
- How deep it goes
- Explains points, neighborhoods, contextual embeddings, distance, magnitude, and orientation without developing implementation details.
- Examples
- Uses synonym pairs, context-dependent uses of “run,” and semantically equivalent passages with no shared words.
- What you can do after
- Evaluate/understand semantic similarity by interpreting embedding proximity instead of relying only on exact word overlap.
Read how LLM Evaluation and Alignment, The Foundational Ideas explains vector space →
Building Reliable AI Systems
A mathematical space whose elements are vectors and in which vector operations are defined.
- How it is used
- Uses a shared embedding space to retrieve relevant documents for retrieval-augmented generation.
- How deep it goes
- Connects shared embeddings to similarity search and Pinecone queries without deriving vector-space mathematics.
- Examples
- Uses a health-care policy chatbot to illustrate retrieval of physical-therapy coverage information.
- What you can do after
- Apply vector similarity through Pinecone by embedding queries with the document model and retrieving matching records.
Read how Building Reliable AI Systems explains vector space →
Retrieval Augmented Generation, The Foundational Ideas
A vector space is a mathematical space whose elements are vectors that support operations such as addition and scalar multiplication.
- How it is used
- Frames semantic retrieval as geometric comparison between representations of queries and documents.
- How deep it goes
- Explains the retrieval role and engineering trade-offs but defers mathematical proofs and detailed clustering mechanics.
- Examples
- Uses TF–IDF vectors, modern embedding dimensions, ANN indexes, and clustering text embeddings as concrete examples.
- What you can do after
- Evaluate retrieval representations and index choices against relevance, speed, recall, and memory trade-offs.
Read how Retrieval Augmented Generation, The Foundational Ideas explains vector space →
Also covered in
- Deep Learning with R, Third Edition
- Math and Architectures of Deep Learning
- Knowledge Graphs and LLMs in Action
- Essential GraphRAG
What to know first
- language modelA language model is a computational model that represents patterns in linguistic sequences to assign probabilities, predict, generate, or evaluate language.
- similarity searchSimilarity search is a retrieval technique that finds or ranks items by their similarity to a query, often by comparing feature or vector representations under a similarity or distance measure.
- embeddingAn embedding is a numerical vector representation of an item in a feature space, encoding selected properties or relationships for computational tasks such as comparison or retrieval.
- approximate nearest neighbor searchApproximate nearest neighbor search efficiently finds items close to a query under a distance or similarity measure without guaranteeing the exact nearest items.
Related concepts
- embeddingproduced by · An embedding is a numerical vector representation of an item in a feature space, encoding selected properties or relationships for computational tasks such as comparison or retrieval.
- similarity searchused by · Similarity search is a retrieval technique that finds or ranks items by their similarity to a query, often by comparing feature or vector representations under a similarity or distance measure.
- weighted averageuses · A weighted average is a mean in which each value contributes in proportion to its assigned numerical weight.
- weighted sumuses · A weighted sum is an expression formed by multiplying quantities by corresponding scalar coefficients and adding the resulting products.
Questions about vector space
What is vector space?
A vector space is a set equipped with vector addition and scalar multiplication over a field that satisfy the vector-space axioms.
Which Manning books explain vector space?
AI-Powered Search, Natural Language Processing in Action, Second Edition, Generative AI in Action, LLM Evaluation and Alignment, The Foundational Ideas, Building Reliable AI Systems and Retrieval Augmented Generation, The Foundational Ideas.
What should I know before learning vector space?
Manning books that teach vector space usually introduce language model, similarity search, embedding and approximate nearest neighbor search first.
What kinds of vector space are there?
Kinds of vector space include lattice.
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.





