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

[Bug] Add note about breaking change (version upgrade 1.4.3 to 2) #114

Closed
do-me opened this issue May 18, 2023 · 1 comment
Closed

[Bug] Add note about breaking change (version upgrade 1.4.3 to 2) #114

do-me opened this issue May 18, 2023 · 1 comment
Labels
bug Something isn't working

Comments

@do-me
Copy link
Contributor

do-me commented May 18, 2023

Congrats to version 2! 🎉

I'd just like to throw in that a note somewhere would be useful that the new version breaks sites written for the "old" logic of v1.4.3.

This

<script src="https://cdn.jsdelivr.net/npm/@xenova/transformers/dist/transformers.min.js"></script>

doesn't work anymore but instead you need to specify the version with

<script src="https://cdn.jsdelivr.net/npm/@xenova/[email protected]/dist/transformers.min.js"></script>.

This fixed my broken sites ad-hoc. Else, people will probably be able to find this issue and fix it themselves :)

@do-me do-me added the bug Something isn't working label May 18, 2023
@xenova
Copy link
Collaborator

xenova commented May 18, 2023

I think the best option would be to provide versioned examples/links, so that when users copy-paste example code, nothing should break.

I'll write a script that will update those links on each release.

@xenova xenova closed this as completed in 2f20922 May 29, 2023
DimQ1 added a commit to DimQ1/transformers.js that referenced this issue Jun 1, 2023
* [demo] Fix token-classification (Closes huggingface#116)

* Fix Bert tokenizer regex for numbers

* Update Bert pretokenizer regex

Should match the rust implementation: https://github.com/huggingface/tokenizers/blob/b4fcc9ce6e4ad5806e82826f816acfdfdc4fcc67/tokenizers/src/pre_tokenizers/bert.rs#L11

- Removes whitespace
- Splits on unicode punctuation and certain ascii characters

* Add tokenizer test cases with numbers

* Build demo website after release

* [package.json] Update keywords

* [version] Update to 2.0.1

* Freeze onnxruntime dependencies (huggingface#124)

Their latest version has a few issues, particularly with webgpu, and also uses .wasm files which are incompatible with their previous versions.

So, while those issues are sorted out, it's best to freeze their packages to the latest stable version.

* Use versioned links (#Closes huggingface#114)

Prevents issues where users copy-paste the import code, and then a future update breaks it.

Also ensures that the default wasm files match the target version

* [version] Update to 2.0.2

* Update package-lock.json

* Update README.md

* Replace `Math.max` with custom `max` function

* Add `sentence-transformers` models to supported models/tasks

* Correctly use default module if present

* Use error mapping instead of switch block

* [docs] Fix numbering

---------

Co-authored-by: Joshua Lochner <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants