## What Are Vector Embeddings? An Intuitive Explanation for UK Business
Vector embeddings are a technique for representing text (or images, audio, code) as a list of numbers — a point in high-dimensional space — such that semantically similar content is located near each other. Consider a UK law firm's document library: a keyword search for 'termination of employment' will miss documents that say 'dismissal', 'redundancy', 'ending the contract of service', or 'summary dismissal'. A semantic search using embeddings represents all these phrases as nearby points in vector space, returning all relevant documents regardless of exact wording. The intuitive analogy: imagine a map where every document occupies a location, and documents about similar topics are clustered geographically. A search query is also plotted on this map, and results are the nearest documents. OpenAI's text-embedding-3-large model produces 3,072-dimensional vectors — each document is a point in 3,072-dimensional space. The remarkable property of well-trained embeddings: the vector for 'UK employment law' minus 'UK' plus 'EU' lands near 'EU employment law'. This algebraic structure in vector space captures semantic relationships that keyword matching fundamentally cannot.
## text-embedding-3-large vs Open-Source Alternatives: UK Cost-Performance Trade-Off
For UK businesses choosing an embedding model, the decision involves: embedding quality (measured on MTEB benchmark — Massive Text Embedding Benchmark, which includes UK legal, financial and biomedical datasets); cost per token; inference latency; and data residency (UK GDPR consideration — does the embedding model process personal data on EU or UK servers?). OpenAI text-embedding-3-large: MTEB score 64.6 (state-of-the-art as of Q1 2026), cost £0.00013 per 1,000 tokens, hosted on Azure UK South region for UK GDPR compliance. Open-source alternatives on UK businesses' own infrastructure: E5-mistral-7B-instruct (MTEB 66.6, beats text-embedding-3-large but requires 16GB GPU — approximately £0.20/hour on AWS ml.g4dn.xlarge); nomic-embed-text-v1.5 (MTEB 62.4, optimised for long documents, runs on CPU — approximately £0.003/hour on ml.c5.2xlarge); multilingual-e5-large (MTEB 58.4, covers 100 languages — relevant for UK businesses with multilingual content). For UK businesses with personal data sensitivity (NHS patient records, HR documents, client communications), self-hosted open-source embeddings on UK-based cloud instances provide GDPR compliance certainty that cloud API providers cannot guarantee without UK-specific data processing agreements.
## pgvector vs Pinecone vs Qdrant: UK Deployment Cost and Performance
The vector database choice determines both operational cost and query performance for UK semantic search deployments. pgvector (PostgreSQL extension): free, open-source, integrates with existing PostgreSQL infrastructure — zero additional licensing cost. Performance: handles up to 1 million vectors with sub-100ms query latency on ml.r5.xlarge (£0.26/hour); above 1 million vectors, requires HNSW index tuning (ef_construction=128, m=16 for typical UK document corpora). Ideal for UK mid-market businesses with existing PostgreSQL: a UK law firm running semantic search over 500,000 document chunks can implement pgvector at £0 licensing cost and approximately £80-£150/month in additional database instance costs. Pinecone (managed, US company): £0.096/GB/month for storage, £0.00000025 per query vector operation. For 1 million 1,536-dimensional vectors: approximately £85/month storage plus query costs. Performance: p99 query latency <20ms guaranteed SLA. UK GDPR consideration: Pinecone data stored in US-East-1 by default — requires Standard Contractual Clauses for UK personal data. Qdrant (open-source, can be self-hosted or managed): self-hosted on ml.m5.2xlarge (£0.40/hour, UK region) handles 5 million 1,536-dimensional vectors with HNSW at p95 <35ms latency — total cost approximately £290/month. Qdrant Cloud (managed, EU region available) provides UK GDPR-safe managed option at comparable cost to Pinecone.
## Hybrid BM25 + Semantic Search: UK Use Cases and Latency Benchmarks
Pure semantic search outperforms keyword search on conceptual queries ('what is the NHS's policy on AI medical devices?') but underperforms on exact lookups ('DCB0129 compliance deadline'). Hybrid search combines BM25 (term frequency-based scoring — the algorithm behind Elasticsearch and Solr) with semantic vector search, using Reciprocal Rank Fusion (RRF) to merge ranked lists. For UK businesses, hybrid search achieves 15-25% higher NDCG@10 (normalised discounted cumulative gain — a retrieval quality metric) versus pure semantic search on real-world enterprise search benchmarks. UK use cases with measured outcomes: a Magic Circle law firm implementing hybrid semantic search over 2 million contracts (Qdrant + BM25 Elasticsearch, Codeworth deployment 2025): query latency p95 42ms, 68% reduction in 'no results found' rate versus previous keyword search, 34% increase in relevant first-page results from associate user surveys; an NHS Trust implementing symptom checker semantic search (pgvector over ICD-11 codes and clinical guidelines, 340,000 document chunks): p95 latency 28ms, 41% improvement in clinical guideline retrieval accuracy versus keyword search; a UK e-commerce platform (250,000 product catalogue, Qdrant + BM25 hybrid): +12% search-to-basket conversion rate, p95 latency 18ms. Implementation pattern for UK businesses new to semantic search: start with pgvector for proof-of-concept (zero additional cost), move to Qdrant or Pinecone when corpus exceeds 2 million chunks or latency requirements tighten below 25ms.
Related Codeworth Services
Need Help with Implementation?
The Codeworth team is ready to implement these ideas in your project. Free consultation.
Discuss the ProjectCodeworth team specialist.