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

remove deprecated model_type param (embedding) #102

Merged
merged 2 commits into from
Sep 21, 2024

Conversation

mattf
Copy link
Collaborator

@mattf mattf commented Sep 17, 2024

NVIDIAEmbeddings' constructor accepts a model_type parameter with value of either "query" or "passage"

using it changes the behavior of the standard embed_query and embed_documents methods.

for example, setting model_type="passage" and calling embed_query results in using the same behavior as not setting model_type and calling embed_passage.

this parameter is confusing to users and has been removed.

users should use embed_query when embedding queries and embed_passage when embedding passages.

if you would like to batch embed queries, please raise a feature request.

note: the query / passage distinction is only important for asymmetric embedding models

@mattf mattf requested a review from dglogo September 17, 2024 11:07
@mattf mattf self-assigned this Sep 17, 2024
Copy link
Collaborator

@dglogo dglogo left a comment

Choose a reason for hiding this comment

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

lgtm! thanks for doing this

@mattf mattf merged commit c73b9b6 into dev-v0.3 Sep 21, 2024
12 checks passed
@mattf mattf deleted the mattf/remove-deprecated-model-type-param branch September 21, 2024 11:53
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