Vector embeddings in ClickHouse with Ollama and OpenAI

Previous videoClickHouse v26.7 Release WebinarNext videoObserving and Improving AI Agents with Langfuse
Mark Needham
ClickHouse's new aiEmbed function generates embeddings directly in SQL — no external pipeline needed. In this video, Mark Needham shows how to use it with both a local Ollama model and OpenAI.
https://clickhouse.com/blog/clickhouse-release-26-06#aiembed
- Point
aiEmbedat a local Ollama model (Qwen3 Embedding) via a named collection with an OpenAI-compatible endpoint - Auto-generate embeddings on insert using a
DEFAULT aiEmbed(text)column, backed by an HNSW vector similarity index - Run approximate nearest neighbor search with
L2Distanceto find phrases closest to a lookup embedding - Query a 1M-row Hugging Face dbpedia dataset pre-embedded with OpenAI's
text-embedding-3-large - Switch
aiEmbedto OpenAI, match embedding dimensions to the dataset, and search for "the best footballer ever"
Recent videos
View all Videos
How to
Inspect incoming data with INSERT … RETURNING in ClickHouse
Use INSERT … RETURNING in ClickHouse 26.11 to inspect generated values, sample incoming rows, find invalid ratings, and summarise an ingestion batch.

How to
Reading and writing Vortex files with ClickHouse (26.11)
Query and export Vortex files with ClickHouse 26.11, using a FineWeb dataset containing just over a million web pages.

