Skip to content

Conversation

@nico-martin
Copy link
Collaborator

The env.backends.onnx is set at the end of the file while env.backends.onnx.versions?.web is requested already on line 197.
That means the check wether the jsdelivr file should be requested is always false.

This PR ensures that https://cdn.jsdelivr.net is used if not in service worker.

@nico-martin nico-martin requested a review from xenova November 22, 2025 14:48
@nico-martin
Copy link
Collaborator Author

FYI, the reason it did work in dev when using transformers.js via http import { pipeline } from "http://localhost:8080/dist/transformers.js"; is that in this case, the wasm file is actually at the correct place http://localhost:8080/dist/ort-wasm-simd-threaded.mjs. But when using it via npm it could not resolve correctly.

Copy link
Collaborator

@xenova xenova left a comment

Choose a reason for hiding this comment

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

Thanks!

@xenova xenova merged commit d4a2281 into huggingface:v4 Nov 23, 2025
1 check failed
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