huggingface / transformers.js

State-of-the-art Machine Learning for the web. Run 🤗 Transformers directly in your browser, with no need for a server!
https://huggingface.co/docs/transformers.js
Apache License 2.0
12.2k stars 776 forks source link

Add support for indictrans2 #571

Open bil-ash opened 9 months ago

bil-ash commented 9 months ago

Model description

With the recent support for custom models, is it possible to run IndicTrans2 . It is basically nllb with a custom tokenizer.

Prerequisites

Additional information

No response

Your contribution

None, no idea of whether the custom tokenizer is required on js side or nllb tokenizer is fine.

xenova commented 9 months ago

I think you'll need to re-implement the tokenization yourself, since it does not seem to be compatible with transformers or tokenizers.

You should be able to convert the model though 👍