vllm-project/vllm

[Transformers v5] Tarsier2ForConditionalGeneration

Open

#38736 opened on Apr 1, 2026

View on GitHub
 (3 comments) (0 reactions) (0 assignees)Python (80,034 stars) (16,816 forks)batch import
good first issuehelp wanted

Description

This is a sub-issue forming part of the work in https://github.com/vllm-project/vllm/issues/38379, please read the description of this issue before beginning to work on this one.

Which test is failing?

Tarsier 2 has a malformed config.json in its checkpoint and vLLM already has some workarounds to account for this (the Tarsier2Config that gets registered in vLLM). This appears to not be working correctly with the latest Transformers.

$ pytest tests/models/test_initialization.py::test_can_initialize_large_subset[Tarsier2ForConditionalGeneration]
...
[2026-04-01T10:33:31Z]   Value error, The text_config extracted from the model config does not have `num_attention_heads` attribute. This indicates a mismatch between the model config and vLLM's expectations. Please ensure that the model config is compatible with vLLM. [type=value_error, input_value=ArgsKwargs((), {'model': ...nderer_num_workers': 1}), input_type=ArgsKwargs]

How to configure my environment?

It's very important that you install both vLLM and Transformers from source so that your test results reflect the current state of both libraries.

# Or your fork
git clone https://github.com/huggingface/transformers.git
git clone https://github.com/vllm-project/vllm.git

cd vllm
VLLM_USE_PRECOMPILED=1 uv pip install -e .
uv pip install -e ../transformers

Contributor guide