Vector store search
Description
The Vector store search transform looks up the records of a vector store nearest to the embedding of every row, through a Vector Store Connection. It is the read half of a retrieval (RAG) pipeline: embed the question with Embed Text, search, then pass the chunks found to a language model. Vector store upsert stores them.
For every row the transform outputs a row per record found, the nearest first, with the fields of the input row and the match fields. A row without a match passes on with empty match fields, unless Drop row when nothing is found is on. A row without an embedding is handled as a row without a match.
Options
| Option | Description |
|---|---|
Transform name |
Name of the transform, unique within the pipeline. |
Vector store connection |
The vector store connection to search. |
Collection |
The collection to search. |
Query embedding field |
The field with the embedding to search with: a Vector field, or a String with a JSON array of numbers. |
Top K |
The maximum number of records to return for every row. |
Distance metric |
How the vectors are compared. Qdrant and Weaviate fix the metric when the collection is created: the search fails when it is another one. With pgvector use the metric of the HNSW index. |
Minimum score |
Leave out the records with a lower score. Higher is nearer. See Distance metrics and scores. No minimum when empty. The minimum applies after the top K, so a row can get fewer than K matches. |
Drop row when nothing is found |
Drop a row when the search finds nothing. |
Match ID field |
The output field with the ID of the record found. |
Match document ID field |
The output field with its document ID. |
Match chunk index field |
The output field with its chunk index. |
Match content field |
The output field with its text. |
Match score field |
The output field with its score. |
Filters
The Filters table only returns records where a field equals the value of a stream field. Every filter has to match.
| Column | Description |
|---|---|
Field |
|
Stream field |
The field with the value. |
Skip if empty |
Leave the filter out for a row where the stream field is empty. Otherwise an empty value matches nothing. |
Type |
The type the metadata field was stored with: String, Integer, Number or Boolean. The value of the stream field is converted to it, so the filter finds the same records on every store: a Number field holding |
Returned metadata fields
The Returned metadata fields table adds metadata fields of the records found to the output.
| Column | Description |
|---|---|
Metadata field |
The name of the metadata field. |
Output field |
The name of the output field. The name of the metadata field when empty. When the input already has a field with that name, the output field gets a suffix ( |
Type |
String, Integer, Number or Boolean. |
Error handling
With an error hop attached, a row whose search fails goes there with code VECTORSTORESEARCH001, for example when a returned value can’t be converted to the type of its returned field. None of the matches of that row go to the output then.
Notes
Top K and Minimum score accept variables.