Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix wrong comparison of embeddings #2

Open
nachoalonsoportillo opened this issue Nov 19, 2023 · 0 comments
Open

Fix wrong comparison of embeddings #2

nachoalonsoportillo opened this issue Nov 19, 2023 · 0 comments

Comments

@nachoalonsoportillo
Copy link

nachoalonsoportillo commented Nov 19, 2023

Issue Overview

The embeddings being compared are those of answer given in code as "3rd century" with those of answer provided by model for question "When was tea discovered?", which is correct, and those of answer provided by model for question "When was tea discovered?" with itself, which is incorrect.

Describe your environment

Steps to Reproduce

  1. Run code in branch 05_03.

Expected Behavior

Current Behavior

Possible Solution

Replace this code

for i in range(0, len(question_answers)*2, 2):

with this code:

for i in range(0, len(question_answers)):

And this code

embedding_b = resp['data'][len(question_answers)]['embedding']

with this code:

embedding_b = resp['data'][i+len(question_answers)]['embedding']

Screenshots / Video

Related Issues

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

No branches or pull requests

1 participant