Instructions to use zeromodels/deepseek_vl_7b_base with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- KerasFormers
How to use zeromodels/deepseek_vl_7b_base with KerasFormers:
# No code snippets available yet for this library. # To use this model, check the repository files and the library's documentation. # Want to help? PRs adding snippets are welcome at: # https://github.com/huggingface/huggingface.js
- Keras
How to use zeromodels/deepseek_vl_7b_base with Keras:
# Available backend options are: "jax", "torch", "tensorflow". import os os.environ["KERAS_BACKEND"] = "jax" import keras model = keras.saving.load_model("hf://zeromodels/deepseek_vl_7b_base") - Notebooks
- Google Colab
- Kaggle
| pipeline_tag: image-text-to-text | |
| license: other | |
| license_name: deepseek | |
| license_link: https://huggingface.co/deepseek-ai/deepseek-vl-7b-base/blob/main/LICENSE | |
| base_model: deepseek-ai/deepseek-vl-7b-base | |
| library_name: kerasformers | |
| tags: | |
| - keras | |
| - kerasformers | |
| - deepseek-vl | |
| - vision-language | |
| - image-text-to-text | |
| - arxiv:2403.05525 | |
| - pytorch | |
| - jax | |
| - tf | |
| ## ***See [our collection](https://huggingface.co/collections/kerasformers/deepseek-vl-6a6ea961fe80d98b7c69b489) for all versions of DeepSeek-VL.*** | |
| # Run DeepSeek-VL with Keras 3: JAX, PyTorch, or TensorFlow | |
| [](https://github.com/IMvision12/KerasFormers) [](https://imvision12.github.io/KerasFormers/deepseek_vl_hybrid/) [](https://huggingface.co/collections/kerasformers/deepseek-vl-6a6ea961fe80d98b7c69b489) | |
| # kerasformers/deepseek_vl_7b_base | |
| Paper: [DeepSeek-VL: Towards Real-World Vision-Language Understanding (arXiv:2403.05525)](https://arxiv.org/abs/2403.05525) · [HF Papers](https://huggingface.co/papers/2403.05525) | |
| DeepSeek-VL **7B hybrid** uses a dual vision tower (SigLIP @384 + SAM-style @1024) and a 3-way aligner for finer detail and small text. Import from `kerasformers.models.deepseek_vl_hybrid` (not `deepseek_vl`). | |
| For more details on the model, please go to the upstream [model card](https://huggingface.co/deepseek-ai/deepseek-vl-7b-base). | |
| Pure-**Keras 3** conversion of [`deepseek-ai/deepseek-vl-7b-base`](https://huggingface.co/deepseek-ai/deepseek-vl-7b-base) for [kerasformers](https://github.com/IMvision12/KerasFormers). One implementation runs unmodified on **TensorFlow / Torch / JAX**. | |
| This is a **vision-language** (base) checkpoint (`DeepseekVLHybridConditionalGenerate`, 7B base (SigLIP + SAM hybrid)). | |
| ## ✨ Quick start | |
| ```python | |
| import os | |
| os.environ["KERAS_BACKEND"] = "torch" # or "jax" / "tensorflow" | |
| from PIL import Image | |
| from kerasformers.models.deepseek_vl_hybrid import ( | |
| DeepseekVLHybridConditionalGenerate, | |
| DeepseekVLHybridProcessor, | |
| ) | |
| model = DeepseekVLHybridConditionalGenerate.from_weights("kerasformers/deepseek_vl_7b_base") | |
| processor = DeepseekVLHybridProcessor.from_weights("kerasformers/deepseek_vl_7b_base") | |
| image = Image.open("your_image.jpg") | |
| inputs = processor( | |
| conversation=[ | |
| { | |
| "role": "user", | |
| "content": [ | |
| {"type": "image", "image": image}, | |
| {"type": "text", "text": "Describe this image in one sentence."}, | |
| ], | |
| } | |
| ] | |
| ) | |
| outputs = model.generate(**inputs, max_new_tokens=64) | |
| print(processor.decode(outputs[0])) | |
| ``` | |
| Load any DeepSeek-VL variant the same way with `from_weights("kerasformers/<variant>")`: | |
| | Variant | Hub | Notes | | |
| |---|---|---| | |
| | `deepseek_vl_1.3b_base` | [`kerasformers/deepseek_vl_1.3b_base`](https://huggingface.co/kerasformers/deepseek_vl_1.3b_base) | 1.3B base | | |
| | `deepseek_vl_1.3b_chat` | [`kerasformers/deepseek_vl_1.3b_chat`](https://huggingface.co/kerasformers/deepseek_vl_1.3b_chat) | 1.3B chat | | |
| | `deepseek_vl_7b_base` | [`kerasformers/deepseek_vl_7b_base`](https://huggingface.co/kerasformers/deepseek_vl_7b_base) | 7B hybrid base | | |
| | `deepseek_vl_7b_chat` | [`kerasformers/deepseek_vl_7b_chat`](https://huggingface.co/kerasformers/deepseek_vl_7b_chat) | 7B hybrid chat | | |
| ## Tips | |
| - Set `KERAS_BACKEND` **before** importing Keras / kerasformers. | |
| - Prefer `Processor.from_weights(...)` so vision + tokenizer match. | |
| - 7B hybrid is a **different package** than 1.3B; do not mix imports. | |
| - See [docs](https://imvision12.github.io/KerasFormers/deepseek_vl_hybrid/) and [Loading Weights](https://imvision12.github.io/KerasFormers/loading_weights/). | |
| - Community / upstream safetensors still work via the `hf:` prefix, e.g. `DeepseekVLHybridConditionalGenerate.from_weights("hf:deepseek-ai/deepseek-vl-7b-base")`. | |
| ## Special Thanks | |
| A huge thank you to the DeepSeek-VL authors for creating and releasing these models. | |
| License: DeepSeek (`other` / deepseek). See [LICENSE](https://huggingface.co/deepseek-ai/deepseek-vl-7b-base/blob/main/LICENSE). | |