Instructions to use dnotitia/DNA-VL-STEER-2B with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- sentence-transformers
How to use dnotitia/DNA-VL-STEER-2B with sentence-transformers:
from sentence_transformers import SentenceTransformer model = SentenceTransformer("dnotitia/DNA-VL-STEER-2B") sentences = [ "That is a happy person", "That is a happy dog", "That is a very happy person", "Today is a sunny day" ] embeddings = model.encode(sentences) similarities = model.similarity(embeddings, embeddings) print(similarities.shape) # [4, 4] - Transformers
How to use dnotitia/DNA-VL-STEER-2B with Transformers:
# Load model directly from transformers import AutoProcessor, AutoModelForMultimodalLM processor = AutoProcessor.from_pretrained("dnotitia/DNA-VL-STEER-2B") model = AutoModelForMultimodalLM.from_pretrained("dnotitia/DNA-VL-STEER-2B", device_map="auto") - Notebooks
- Google Colab
- Kaggle
Recommendation to use `requirements` in `config_sentence_transformers.json`
Hello @dhk1349 !
Sentence Transformers maintainer here, I just stumbled on this model when looking at the trending ST models, and I noticed this bit in your README:
Requires transformers >= 5.0 β older versions load RANDOM weights silently
In the last version of Sentence Transformers, I added this requirements option in config_sentence_transformers.json: https://sbert.net/docs/sentence_transformer/usage/custom_models.html#declaring-version-requirements
It allows you to set a minimum requirement of any Python library, optionally with a reason. If you add this option to this model, users with new ST versions will be informed if they have old Transformers versions. This config will be ignored for users with older ST versions, so there's no harm either. Consider it a bit like a built-in guarantee that users are using the versions that work correctly. Might be worth using π€
- Tom Aarsen
Hi @tomaarsen , thanks for flagging this β exactly the mechanism I wanted and I hadn't seen it land.
I've added it to config_sentence_transformers.json on this model and our other STEER releases:
"requirements": {
"transformers": {
"specifier": ">=5.0.0",
"reason": "Qwen3-VL support requires transformers 5.x; older versions silently initialise the vision tower with randomly-initialised weights instead of the checkpoint's, so the model loads without error but returns meaningless embeddings"
}
}
Verified it raises before any weights load, and the reason text surfaces in the error, which is much better than the README warning we were relying on.
One observation in case it's useful: the check lives in SentenceTransformer.__init__, so users loading through AutoModel.from_pretrained bypass it β and for multimodal embedding models that's a common path (it's the primary example in our own README). I'll add a check_min_version call in our custom modeling code to cover it. Not a request, just noting the gap for models that ship both entry points.
Thanks again!
One observation in case it's useful: the check lives in SentenceTransformer.init, so users loading through AutoModel.from_pretrained bypass it β and for multimodal embedding models that's a common path (it's the primary example in our own README).
Indeed, it only lives in Sentence Transformers. Transformers doesn't have this functionality by default I'm afraid.
Also, I couldn't find other STEER models, and I believe the primary example in this README is with Sentence Transformers still. I might be mistaken though!
- Tom Aarsen
Thanks for the quick reply β and sorry for the confusion on both counts.
You're right about the README: the usage section is Sentence Transformers throughout, there's noAutoModel example in it. I was thinking of a different model card and shouldn't have said that
without re-reading ours. So your requirements check actually covers every path we document,
which is better than I implied.
On the other models β my wording, apologies. The other STEER releases are still private while we
finish evaluating them, so there was genuinely nothing for you to find. I've applied the samerequirements field to them so it's in place whenever they go public.
I've also fixed the README.
Thanks again for the pointer β genuinely useful feature.