distance value in the topK object of the Search Extract Output Node.
Weaviate and Qdrant are tools that calculate similarity in different ways:
- Weaviate calculates similarity values within the range of 0 to 2, where 0 represents maximum similarity and 2 represents minimum similarity.
- Qdrant calculates similarity values within the range of -1 to 1, where 1 represents maximum similarity and -1 represents minimum similarity.
distance value. If you use distance to make decisions in the Flow, consider the new similarity range of -1 to 1.
The LLM embedding model you use defines how precisely Knowledge AI calculates
distance. The different LLM embedding models can provide considerably different distance values. Use the distance value for decision-making in Flows with caution.Adapting Distance Values: Before and After 4.74.0 Version
If your Flows useddistance values within the range of 0 to 2 before the release of Cognigy.AI 4.74.0 and you want to keep this approach, change your Flows as follows:
- Replace all
distanceinstances with1 - distance.
distance for the first time in Cognigy.AI v4.74.0 or later, use the value within the range of -1 to 1.