Text Embeddings, Classification, and Semantic Search
An introduction with example Python code
Published in
11 min readMar 27, 2024
This article is part of a larger series on using large language models (LLMs) in practice. In the previous post, we saw how to improve an LLM via retrieval-augmented generation (i.e. RAG). A key part of RAG was using text embeddings to retrieve relevant information from a knowledge base automatically. Here, I will discuss text embeddings more deeply and share two simple (yet powerful) applications: text classification and semantic search.