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

Create token type ids when not provided #2081

Merged
merged 2 commits into from
Oct 29, 2024
Merged

Create token type ids when not provided #2081

merged 2 commits into from
Oct 29, 2024

Conversation

echarlaix
Copy link
Collaborator

Fix #2062

@HuggingFaceDocBuilderDev

The docs for this PR live here. All of your documentation changes will be reflected on that endpoint. The docs are available until 30 days after the last update.

@echarlaix echarlaix marked this pull request as ready for review October 25, 2024 14:21
@echarlaix echarlaix merged commit 4a39ae0 into main Oct 29, 2024
42 of 47 checks passed
@echarlaix echarlaix deleted the fix-token-type-ids branch October 29, 2024 09:20
@tomaarsen
Copy link
Member

@echarlaix I've tested this with:

from sentence_transformers import SentenceTransformer

model = SentenceTransformer("intfloat/multilingual-e5-small", backend="onnx")

sentences = ["This is an example sentence", "Each sentence is converted"]
embeddings = model.encode(sentences)
print(embeddings.shape)

And it works now. Thanks a bunch.

  • Tom Aarsen

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
gpu-test trigger GPU tests
Projects
None yet
Development

Successfully merging this pull request may close these issues.

No ONNX support for BERT models when token_type_ids is not provided
4 participants