Instructions to use mlx-community/sarvam-translate-mlx-bf16 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use mlx-community/sarvam-translate-mlx-bf16 with Transformers:
# Use a pipeline as a high-level helper # Warning: Pipeline type "translation" is no longer supported in transformers v5. # You must load the model directly (see below) or downgrade to v4.x with: # pip install "transformers<5.0.0" from transformers import pipeline pipe = pipeline("translation", model="mlx-community/sarvam-translate-mlx-bf16")# pip install -U transformers accelerate # Load model directly from transformers import AutoProcessor, AutoModelForMultimodalLM processor = AutoProcessor.from_pretrained("mlx-community/sarvam-translate-mlx-bf16") model = AutoModelForMultimodalLM.from_pretrained("mlx-community/sarvam-translate-mlx-bf16", device_map="auto") - MLX
How to use mlx-community/sarvam-translate-mlx-bf16 with MLX:
# Download the model from the Hub pip install huggingface_hub[hf_xet] hf download mlx-community/sarvam-translate-mlx-bf16 --local-dir sarvam-translate-mlx-bf16
- Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- LM Studio
- Atomic Chat
Upload added_tokens.json with huggingface_hub
Browse files- added_tokens.json +3 -0
added_tokens.json
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"<image_soft_token>": 262144
|
| 3 |
+
}
|