ANAlpesh Nakrani
SolutionsBlogBooksPraiseAboutWork with me ↗
All books
Embeddings, Honestly cover
2025/Free online book · Technical Deep Dives

Embeddings, Honestly

What Vectors Do and Don't Know

Access
Free
Chapters
28
Read time
258 min

Embeddings can make fuzzy language computable, power semantic search, cluster messy information, retrieve context for LLMs, and support recommendations. They do not know truth, authority, chronology, identity, permissions, freshness, or business rules. This research-backed edition works through the HONEST framework, retrieval architecture, metadata, reranking, evaluation, security, cost, model choice, and production anti-patterns for teams building semantic systems that must survive contact with real users.

A full field manual on what embeddings capture, what they forget, and why similarity is not truth.

This edition is free to read onsite. Each chapter has its own URL, so readers can bookmark, share, and return to the exact section they need.

Table of contents
PREPreface: What Vectors Do and Don't KnowEmbeddings are one of the most useful misunderstandings in modern AI.10 min01A Vector Is a ShadowA support-ticket search pilot looks impressive until the CTO asks why the system cannot tell the difference between an old draft policy and the approved one. The failure is not that embeddings are useless.9 min02What Similarity Can DoA customer support manager wants one queue for refund intent even when users write 'money back', 'reverse charge', or 'cancel my renewal'. The failure is not that embeddings are useless.8 min03What Similarity Cannot KnowA legal assistant retrieves a confidential merger memo because it is semantically similar to a public policy page. The failure is not that embeddings are useless.8 min04Similar Is Not CorrectA healthcare policy assistant returns the closest paragraph, but the correct paragraph is farther away because it uses a newer name for the program. The failure is not that embeddings are useless.8 min05The Numbers Are Not LabelsA product engineer stares at a 1536-dimensional vector and tries to name dimension 812. The mistake is educational.8 min06Distance Is a Ranking, Not a VerdictA sales-search feature treats cosine 0.82 as confidence and shows a document that sounds relevant but belongs to another product line. The failure is not that embeddings are useless.8 min07The Map Is Learned, Not UniversalA generic embedding model fails on internal acronyms that every employee understands, because the model never learned the organization's map. The failure is not that embeddings are useless.8 min08Dense, Sparse, and HybridA pure vector search misses SKU AX-1042 because the text around it is not semantically rich, while BM25 finds it instantly. The failure is not that embeddings are useless.8 min09Semantic Search From First PrinciplesA team builds semantic search over internal markdown docs and learns the pipeline matters more than the database brand. The failure is not that embeddings are useless.9 min10Chunking Is Where Retrieval Is WonA PDF manual is chunked by fixed token windows; the answer exists, but the table heading and value land in different chunks. The failure is not that embeddings are useless.9 min11Metadata Is RealityA finance assistant must prefer approved Q4 forecasts over similar draft Q3 notes, and the only way is metadata. The failure is not that embeddings are useless.9 min12Vector Databases Are Not MagicA startup nearly buys a vector database before discovering its existing Lucene stack can run the first version well enough. The failure is not that embeddings are useless.9 min13RAG Still Needs JudgmentA RAG assistant retrieves the right source but still hallucinates a confident conclusion not supported by the text. The failure is not that embeddings are useless.9 min14Rerank Before You BelieveA vector index returns many plausible candidates; a reranker finally chooses the passages that answer the actual question. The failure is not that embeddings are useless.9 min15Evaluate or GuessThe demo works with five hand-picked questions; the golden dataset exposes that most real user questions fail silently. The failure is not that embeddings are useless.9 min16The Failure Modes Nobody ShowsEvery failure in a support bot looks like 'the LLM hallucinated' until the team separates retrieval failures from generation failures. The failure is not that embeddings are useless.9 min17Hybrid Search in ProductionA production catalog search needs exact SKU, synonym handling, semantic intent, stock status, and freshness scoring at once. The failure is not that embeddings are useless.9 min18Graphs Remember RelationshipsA compliance question needs relationships: which entity owns which policy under which jurisdiction, not merely similar paragraphs. The failure is not that embeddings are useless.9 min19Multimodal EmbeddingsA manufacturing team wants to ask questions over screenshots, inspection photos, PDF pages, and text notes in one system. The failure is not that embeddings are useless.9 min20Personalization and RecommendationsA recommender learns from user clicks and then traps users inside its own feedback loop unless exploration and privacy controls exist. The failure is not that embeddings are useless.9 min21Embeddings for CodeA codebase assistant retrieves a similar function but misses the canonical usage pattern because symbols and tests were not indexed. The failure is not that embeddings are useless.9 min22Security Starts Before RetrievalA tenant-aware knowledge base leaks a restricted document because the team filtered permissions after retrieval instead of before output. The failure is not that embeddings are useless.9 min23The Cost of MeaningThe prototype costs $40. The same design at production traffic costs $40, 000 because token length and reranking were ignored.9 min24Choosing an Embedding ModelA model upgrade improves public benchmark scores but breaks the company's golden queries and requires a full reindex. The failure is not that embeddings are useless.9 min25The Honest Retrieval ArchitectureThe team stops arguing about vector database brands and designs the retrieval system as a set of explicit trust gates. The failure is not that embeddings are useless.9 min26Use Case PlaybookTwelve teams ask for embeddings; each use case needs different metadata, evaluation, retrieval strategy, and failure response. The failure is not that embeddings are useless.9 min27The Embedding Anti-PatternsA design review finds every classic anti-pattern in one architecture diagram: whole PDFs, no ACL, top-5 only, no eval, no freshness. The failure is not that embeddings are useless.9 min28The Honest Checklist Before ShippingThe shipping meeting changes from 'does the demo work?' to 'which readiness gate is still red?' The failure is not that embeddings are useless. The failure is that the team expected the embedding to carry information it was never designed to carry.9 minAAppendix A: Source MapThis edition intentionally uses chapter-specific research bases rather than repeating the same source list everywhere.3 min

Ask AI about Embeddings, Honestly