Evaluates how close two texts are in meaning by comparing their vector embeddings, typically using cosine similarity. It captures meaning beyond exact word matches.
output
(str): The generated text.expectedOutput
(str): The reference text.Result
(float): A similarity score, typically between 0 and 1.1
: The texts are considered semantically identical.0
: The texts have completely different meanings.A
and B
are the embedding vectors.