Similarity Analysis Config
Default value: SimilarityOptions()
Environment Variable: SIMILARITY
In Key Concepts, Similarity Analysis explains how the different configuration attributes will affect the analysis results.
If your machine does not have a lot of computing power, similarity
can be set to null
. It can be
enabled later on in the application.
from pydantic import BaseModel
class SimilarityOptions(BaseModel):
faiss_encoder: str = "all-MiniLM-L12-v2" # (1)
few_similar_threshold: float = 0.9 # (2)
no_close_threshold: float = 0.5 # (3)
- The name of your encoder must be supported by sentence-transformers.
- Threshold to determine the ratio of utterances that should belong to another class for the
smart tags
few_similar_train
/few_similar_eval
. - Threshold for cosine similarity for the smart tags
no_close_train
/no_close_eval
.