Fix KeyError in __init__ when vision_config is empty (Transformers v5 compatibility)

#12
by KBayoud - opened

AutoConfig.from_pretrained('OpenGVLab/Mono-InternVL-2B', trust_remote_code=True) with transformers >=5 FAILED with KeyError: 'model_type' at configuration_internvl_chat.py:53
see vllm-project/vllm#38379 PR: TBD β€” InternLM2VEForCausalLM (OpenGVLab/Mono-InternVL-2B), cap 4.57 β€” Custom config can't be loaded with v5, vision_config not always set

wzk1015 changed pull request status to merged

Sign up or log in to comment