Downloads · 30 days
18
19% of all-time downloads
soyrsoyr/Qwen3-VL-Reranker-0.1B-tiny
Qwen3-VL-Reranker-0.1B-tiny is a image-text-to-text model from soyrsoyr. Use it for the image-text-to-text task on the model card, and read the license before you ship it in a product. It is set up for transformers.
This is a tiny version of Qwen/Qwen3-VL-Reranker-2B created for testing and development.
Downloads · 30 days
18
19% of all-time downloads
All-time downloads
93
Public
Parameters
98.7M
209 MB on disk
Likes
0
Public
Click a slice to open those files.
.safetensors197 MB · 95%
From the Hugging Face model README
This is a tiny version of Qwen/Qwen3-VL-Reranker-2B created for testing and development.
A small, fast stand-in for the qwen3_vl reranker architecture, useful for:
Qwen3VLForSequenceClassification path via hf_overridesWeights are random (then briefly fine-tuned on a toy corpus), so scores/generations are not meaningful, this model is for plumbing, not output quality.
The following parameters were reduced from the original model:
| Parameter | Original | Tiny |
|---|---|---|
| text_config.num_hidden_layers | 28 | 4 |
| text_config.hidden_size | 2048 | 512 |
| text_config.intermediate_size | 6144 | 1024 |
| text_config.num_attention_heads | 16 | 8 |
| text_config.num_key_value_heads | 8 | 2 |
| vision_config.depth | 24 | 4 |
| vision_config.hidden_size | 1024 | 256 |
| vision_config.intermediate_size | 4096 | 512 |
| vision_config.num_heads | 16 | 4 |
| vision_config.out_hidden_size | 2048 | 512 |
| vision_config.deepstack_visual_indexes | [5, 11, 17] | [0, 1, 2] |
Attention head_dim is kept at 128, and the full 151,936-token vocabulary is retained.
Single safetensors file (model.safetensors). Key naming matches the original
checkpoint format (model.language_model.*, model.visual.*). Module-path
structure was verified equal to the base checkpoint's safetensors header.
Load as a sequence-classification reranker in vLLM (as with the full Qwen3-VL-Reranker-2B):
from vllm import LLM
llm = LLM(
model="soyrsoyr/Qwen3-VL-Reranker-0.1B-tiny",
hf_overrides={
"architectures": ["Qwen3VLForSequenceClassification"],
"classifier_from_token": ["no", "yes"],
"is_original_qwen3_reranker": True,
},
)
Or as a plain generative model in transformers:
from transformers import AutoModelForImageTextToText, AutoProcessor
model = AutoModelForImageTextToText.from_pretrained(
"soyrsoyr/Qwen3-VL-Reranker-0.1B-tiny", device_map="auto"
)
processor = AutoProcessor.from_pretrained("soyrsoyr/Qwen3-VL-Reranker-0.1B-tiny")
input_ids = processor.tokenizer("According to all known laws", return_tensors="pt").input_ids.to(model.device)
print(processor.tokenizer.decode(model.generate(input_ids, max_new_tokens=20)[0]))
This is a multimodal ...ForConditionalGeneration model, so AutoModelForCausalLM
does not resolve it. Pass AutoModelForImageTextToText to
load_offloaded_model — the class you pass must match the class you call, since
that is where device_map="auto_offload" support is injected:
from transformers import AutoModelForImageTextToText
from compressed_tensors.offload import load_offloaded_model
from compressed_tensors.distributed import init_dist
init_dist()
with load_offloaded_model(model_class=AutoModelForImageTextToText):
model = AutoModelForImageTextToText.from_pretrained(
"soyrsoyr/Qwen3-VL-Reranker-0.1B-tiny",
device_map="auto_offload", # weights on CPU/disk, GPU for activations
)
This model was created using the llm-compressor create-tiny-model claude skill.
inspect_config.pysave_tiny_model.py, adapted for the
multimodal class (AutoModelForImageTextToText.from_config); the text tower
and vision tower were shrunk and any all-zero / non-finite / extreme param was
fixed after init_weights()validate_tiny_model.pyQwen3VLForSequenceClassification at load time via the
hf_overrides shown above, so this tiny model exercises the reranker →
sequence-classification path.vision_config.out_hidden_size is set to the text
hidden size (512) so the visual merger projects into the text tower;
deepstack_visual_indexes is remapped to valid indices for the reduced
4-layer vision tower.tie_word_embeddings=True: lm_head shares embed_tokens and is not stored
as a separate tensor.Validation output: Success: 1.003219485282898 <= 10.0