Skip to content

Conversation

enestydarealmc
Copy link
Contributor

Hi Ragas maintainers,

I was calculating answer similarity and noticed that my score was way above 1. I found out it was because the ground truth and generated answer embeddings were not normalized before fed into cosine similarity.

Note that this does not happen to all embeddings, only those that doesn't have L2-norm equal 1 innately.

It'd be nice if I can get some feedback and have this PR merged.

Thanks a bunch!

Copy link
Member

@shahules786 shahules786 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks buddy :) Nice catch! @enestydarealmc

@shahules786 shahules786 merged commit 0c05aa2 into explodinggradients:main Feb 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants