-
-
Notifications
You must be signed in to change notification settings - Fork 14.8k
[Core] Parse vLLM engine required fields from hf_config to model_arch_config #28454
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
34 commits
Select commit
Hold shift + click to select a range
ec81168
introduce model arch config
charlotte12l 9b19e3b
align with_hf_config
charlotte12l 0a4f472
remove dtype_original_type
charlotte12l 1cf506d
fix attention free models
charlotte12l c327dff
fix DummyConfig in tests
charlotte12l a8cc81a
add tests for attention free models
charlotte12l 48eeb1f
remove multimodal in model_arch_config
charlotte12l 5870d36
support falcon_mamba
charlotte12l b78c44f
remove terratorch test
charlotte12l f72949b
architectures can be None
charlotte12l aab35fc
support medusa
charlotte12l 65c6d25
speculative tests
charlotte12l 0cd72dc
speculative tests
charlotte12l 5401f65
refactor tests
charlotte12l 72730a7
Merge branch 'main' into model_arch_cfg
charlotte12l 9845589
Merge branch 'main' into model_arch_cfg
charlotte12l 97e1752
Merge branch 'main' into model_arch_cfg
charlotte12l 9a75278
Merge branch 'main' into model_arch_cfg
charlotte12l 0f85cfd
update with main
charlotte12l f5348c8
fix precommit
charlotte12l 9b239b9
Merge branch 'main' into model_arch_cfg
heheda12345 f7344c9
Merge branch 'main' into model_arch_cfg
charlotte12l 78d4749
sync with #30957
charlotte12l 5bde69c
remove convertor dependency on model&revision, only torch_dtype is cl…
charlotte12l 1c3db56
make get_model_arch_config not classmethod
charlotte12l 441d735
fix tests
charlotte12l a55be1f
Merge branch 'main' into model_arch_cfg
charlotte12l e1b6bfa
sync with #29788
charlotte12l 0d143e4
precommit fix
charlotte12l 58eb6c4
remove mosaicml/mpt-7b in tests
charlotte12l 9d27b1a
remove databricks/dbrx-instruct in tests
charlotte12l e0a2198
Merge branch 'main' into model_arch_cfg
charlotte12l a8b20be
Update test_model_arch_config.py
charlotte12l 4923278
linter
charlotte12l File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,359 @@ | ||
| { | ||
| "state-spaces/mamba-130m-hf": { | ||
| "architectures": [ | ||
| "MambaForCausalLM" | ||
| ], | ||
| "model_type": "mamba", | ||
| "text_model_type": "mamba", | ||
| "hidden_size": 768, | ||
| "total_num_hidden_layers": 24, | ||
| "total_num_attention_heads": 0, | ||
| "head_size": 0, | ||
| "vocab_size": 50280, | ||
| "total_num_kv_heads": 0, | ||
| "num_experts": 0, | ||
| "is_deepseek_mla": false, | ||
| "is_multimodal_model": false, | ||
| "dtype": "torch.float32" | ||
| }, | ||
| "mistralai/Mamba-Codestral-7B-v0.1": { | ||
| "architectures": [ | ||
| "Mamba2ForCausalLM" | ||
| ], | ||
| "model_type": "mamba", | ||
| "text_model_type": "mamba", | ||
| "hidden_size": 4096, | ||
| "total_num_hidden_layers": 64, | ||
| "total_num_attention_heads": 0, | ||
| "head_size": 0, | ||
| "vocab_size": 32768, | ||
| "total_num_kv_heads": 0, | ||
| "num_experts": 0, | ||
| "is_deepseek_mla": false, | ||
| "is_multimodal_model": false, | ||
| "dtype": "torch.bfloat16" | ||
| }, | ||
| "ibm-nasa-geospatial/Prithvi-EO-2.0-300M-TL-Sen1Floods11": { | ||
| "architectures": [ | ||
| "Terratorch" | ||
| ], | ||
| "model_type": "timm_wrapper", | ||
| "text_model_type": "timm_wrapper", | ||
| "hidden_size": 0, | ||
| "total_num_hidden_layers": 0, | ||
| "total_num_attention_heads": 0, | ||
| "head_size": 0, | ||
| "vocab_size": 0, | ||
| "total_num_kv_heads": 0, | ||
| "num_experts": 0, | ||
| "is_deepseek_mla": false, | ||
| "is_multimodal_model": true, | ||
| "dtype": "torch.float32" | ||
| }, | ||
| "tiiuae/falcon-mamba-7b-instruct": { | ||
| "architectures": [ | ||
| "FalconMambaForCausalLM" | ||
| ], | ||
| "model_type": "falcon_mamba", | ||
| "text_model_type": "falcon_mamba", | ||
| "hidden_size": 4096, | ||
| "total_num_hidden_layers": 64, | ||
| "total_num_attention_heads": 0, | ||
| "head_size": 0, | ||
| "vocab_size": 65024, | ||
| "total_num_kv_heads": 0, | ||
| "num_experts": 0, | ||
| "is_deepseek_mla": false, | ||
| "is_multimodal_model": false, | ||
| "dtype": "torch.bfloat16" | ||
| }, | ||
| "Zyphra/Zamba2-7B-instruct": { | ||
| "architectures": [ | ||
| "Zamba2ForCausalLM" | ||
| ], | ||
| "model_type": "zamba2", | ||
| "text_model_type": "zamba2", | ||
| "hidden_size": 3584, | ||
| "total_num_hidden_layers": 81, | ||
| "total_num_attention_heads": 32, | ||
| "head_size": 224, | ||
| "vocab_size": 32000, | ||
| "total_num_kv_heads": 32, | ||
| "num_experts": 0, | ||
| "is_deepseek_mla": false, | ||
| "is_multimodal_model": false, | ||
| "dtype": "torch.bfloat16" | ||
| }, | ||
| "mosaicml/mpt-7b": { | ||
| "architectures": [ | ||
| "MPTForCausalLM" | ||
| ], | ||
| "model_type": "mpt", | ||
| "text_model_type": "mpt", | ||
| "hidden_size": 4096, | ||
| "total_num_hidden_layers": 32, | ||
| "total_num_attention_heads": 32, | ||
| "head_size": 128, | ||
| "vocab_size": 50432, | ||
| "total_num_kv_heads": 32, | ||
| "num_experts": 0, | ||
| "is_deepseek_mla": false, | ||
| "is_multimodal_model": false, | ||
| "dtype": "torch.bfloat16" | ||
| }, | ||
| "databricks/dbrx-instruct": { | ||
| "architectures": [ | ||
| "DbrxForCausalLM" | ||
| ], | ||
| "model_type": "dbrx", | ||
| "text_model_type": "dbrx", | ||
| "hidden_size": 6144, | ||
| "total_num_hidden_layers": 40, | ||
| "total_num_attention_heads": 48, | ||
| "head_size": 128, | ||
| "vocab_size": 100352, | ||
| "total_num_kv_heads": 8, | ||
| "num_experts": 0, | ||
| "is_deepseek_mla": false, | ||
| "is_multimodal_model": false, | ||
| "dtype": "torch.bfloat16" | ||
| }, | ||
| "tiiuae/falcon-7b": { | ||
| "architectures": [ | ||
| "FalconForCausalLM" | ||
| ], | ||
| "model_type": "falcon", | ||
| "text_model_type": "falcon", | ||
| "hidden_size": 4544, | ||
| "total_num_hidden_layers": 32, | ||
| "total_num_attention_heads": 71, | ||
| "head_size": 64, | ||
| "vocab_size": 65024, | ||
| "total_num_kv_heads": 1, | ||
| "num_experts": 0, | ||
| "is_deepseek_mla": false, | ||
| "is_multimodal_model": false, | ||
| "dtype": "torch.bfloat16" | ||
| }, | ||
| "tiiuae/falcon-40b": { | ||
| "architectures": [ | ||
| "FalconForCausalLM" | ||
| ], | ||
| "model_type": "falcon", | ||
| "text_model_type": "falcon", | ||
| "hidden_size": 8192, | ||
| "total_num_hidden_layers": 60, | ||
| "total_num_attention_heads": 128, | ||
| "head_size": 64, | ||
| "vocab_size": 65024, | ||
| "total_num_kv_heads": 8, | ||
| "num_experts": 0, | ||
| "is_deepseek_mla": false, | ||
| "is_multimodal_model": false, | ||
| "dtype": "torch.bfloat16" | ||
| }, | ||
| "luccafong/deepseek_mtp_main_random": { | ||
| "architectures": [ | ||
| "DeepseekV3ForCausalLM" | ||
| ], | ||
| "model_type": "deepseek_v3", | ||
| "text_model_type": "deepseek_v3", | ||
| "hidden_size": 2560, | ||
| "total_num_hidden_layers": 5, | ||
| "total_num_attention_heads": 32, | ||
| "head_size": 576, | ||
| "vocab_size": 129280, | ||
| "total_num_kv_heads": 32, | ||
| "num_experts": 72, | ||
| "is_deepseek_mla": true, | ||
| "is_multimodal_model": false, | ||
| "dtype": "torch.bfloat16" | ||
| }, | ||
| "luccafong/deepseek_mtp_draft_random": { | ||
| "architectures": [ | ||
| "DeepseekV3ForCausalLM" | ||
| ], | ||
| "model_type": "deepseek_v3", | ||
| "text_model_type": "deepseek_v3", | ||
| "hidden_size": 2560, | ||
| "total_num_hidden_layers": 10, | ||
| "total_num_attention_heads": 32, | ||
| "head_size": 576, | ||
| "vocab_size": 129280, | ||
| "total_num_kv_heads": 32, | ||
| "num_experts": 72, | ||
| "is_deepseek_mla": true, | ||
| "is_multimodal_model": false, | ||
| "dtype": "torch.bfloat16" | ||
| }, | ||
| "Qwen/Qwen3-Next-80B-A3B-Instruct": { | ||
| "architectures": [ | ||
| "Qwen3NextForCausalLM" | ||
| ], | ||
| "model_type": "qwen3_next", | ||
| "text_model_type": "qwen3_next", | ||
| "hidden_size": 2048, | ||
| "total_num_hidden_layers": 48, | ||
| "total_num_attention_heads": 16, | ||
| "head_size": 256, | ||
| "vocab_size": 151936, | ||
| "total_num_kv_heads": 2, | ||
| "num_experts": 512, | ||
| "is_deepseek_mla": false, | ||
| "is_multimodal_model": false, | ||
| "dtype": "torch.bfloat16" | ||
| }, | ||
| "tiny-random/qwen3-next-moe": { | ||
| "architectures": [ | ||
| "Qwen3NextForCausalLM" | ||
| ], | ||
| "model_type": "qwen3_next", | ||
| "text_model_type": "qwen3_next", | ||
| "hidden_size": 8, | ||
| "total_num_hidden_layers": 4, | ||
| "total_num_attention_heads": 16, | ||
| "head_size": 32, | ||
| "vocab_size": 151936, | ||
| "total_num_kv_heads": 8, | ||
| "num_experts": 32, | ||
| "is_deepseek_mla": false, | ||
| "is_multimodal_model": false, | ||
| "dtype": "torch.bfloat16" | ||
| }, | ||
| "zai-org/GLM-4.5": { | ||
| "architectures": [ | ||
| "Glm4MoeForCausalLM" | ||
| ], | ||
| "model_type": "glm4_moe", | ||
| "text_model_type": "glm4_moe", | ||
| "hidden_size": 5120, | ||
| "total_num_hidden_layers": 92, | ||
| "total_num_attention_heads": 96, | ||
| "head_size": 128, | ||
| "vocab_size": 151552, | ||
| "total_num_kv_heads": 8, | ||
| "num_experts": 160, | ||
| "is_deepseek_mla": false, | ||
| "is_multimodal_model": false, | ||
| "dtype": "torch.bfloat16" | ||
| }, | ||
| "baidu/ERNIE-4.5-21B-A3B-PT": { | ||
| "architectures": [ | ||
| "Ernie4_5_MoeForCausalLM" | ||
| ], | ||
| "model_type": "ernie4_5_moe", | ||
| "text_model_type": "ernie4_5_moe", | ||
| "hidden_size": 2560, | ||
| "total_num_hidden_layers": 28, | ||
| "total_num_attention_heads": 20, | ||
| "head_size": 128, | ||
| "vocab_size": 103424, | ||
| "total_num_kv_heads": 4, | ||
| "num_experts": 64, | ||
| "is_deepseek_mla": false, | ||
| "is_multimodal_model": false, | ||
| "dtype": "torch.bfloat16" | ||
| }, | ||
| "lmsys/gpt-oss-20b-bf16": { | ||
| "architectures": [ | ||
| "GptOssForCausalLM" | ||
| ], | ||
| "model_type": "gpt_oss", | ||
| "text_model_type": "gpt_oss", | ||
| "hidden_size": 2880, | ||
| "total_num_hidden_layers": 24, | ||
| "total_num_attention_heads": 64, | ||
| "head_size": 64, | ||
| "vocab_size": 201088, | ||
| "total_num_kv_heads": 8, | ||
| "num_experts": 32, | ||
| "is_deepseek_mla": false, | ||
| "is_multimodal_model": false, | ||
| "dtype": "torch.bfloat16" | ||
| }, | ||
| "deepseek-ai/DeepSeek-V3.2-Exp": { | ||
| "architectures": [ | ||
| "DeepseekV32ForCausalLM" | ||
| ], | ||
| "model_type": "deepseek_v32", | ||
| "text_model_type": "deepseek_v32", | ||
| "hidden_size": 7168, | ||
| "total_num_hidden_layers": 61, | ||
| "total_num_attention_heads": 128, | ||
| "head_size": 576, | ||
| "vocab_size": 129280, | ||
| "total_num_kv_heads": 128, | ||
| "num_experts": 256, | ||
| "is_deepseek_mla": true, | ||
| "is_multimodal_model": false, | ||
| "dtype": "torch.bfloat16" | ||
| }, | ||
| "meta-llama/Llama-4-Scout-17B-16E-Instruct": { | ||
| "architectures": [ | ||
| "Llama4ForConditionalGeneration" | ||
| ], | ||
| "model_type": "llama4", | ||
| "text_model_type": "llama4_text", | ||
| "hidden_size": 5120, | ||
| "total_num_hidden_layers": 48, | ||
| "total_num_attention_heads": 40, | ||
| "head_size": 128, | ||
| "vocab_size": 202048, | ||
| "total_num_kv_heads": 8, | ||
| "num_experts": 16, | ||
| "is_deepseek_mla": false, | ||
| "is_multimodal_model": true, | ||
| "dtype": "torch.bfloat16" | ||
| }, | ||
| "nvidia/Llama-3_3-Nemotron-Super-49B-v1": { | ||
| "architectures": [ | ||
| "DeciLMForCausalLM" | ||
| ], | ||
| "model_type": "nemotron-nas", | ||
| "text_model_type": "nemotron-nas", | ||
| "hidden_size": 8192, | ||
| "total_num_hidden_layers": 80, | ||
| "total_num_attention_heads": 64, | ||
| "head_size": 128, | ||
| "vocab_size": 128256, | ||
| "total_num_kv_heads": 8, | ||
| "num_experts": 0, | ||
| "is_deepseek_mla": false, | ||
| "is_multimodal_model": false, | ||
| "dtype": "torch.bfloat16" | ||
| }, | ||
| "XiaomiMiMo/MiMo-7B-RL": { | ||
| "architectures": [ | ||
| "MiMoForCausalLM" | ||
| ], | ||
| "model_type": "mimo", | ||
| "text_model_type": "mimo", | ||
| "hidden_size": 4096, | ||
| "total_num_hidden_layers": 36, | ||
| "total_num_attention_heads": 32, | ||
| "head_size": 128, | ||
| "vocab_size": 151680, | ||
| "total_num_kv_heads": 8, | ||
| "num_experts": 0, | ||
| "is_deepseek_mla": false, | ||
| "is_multimodal_model": false, | ||
| "dtype": "torch.bfloat16" | ||
| }, | ||
| "meituan-longcat/LongCat-Flash-Chat": { | ||
| "architectures": [ | ||
| "LongcatFlashForCausalLM" | ||
| ], | ||
| "model_type": "longcat_flash", | ||
| "text_model_type": "longcat_flash", | ||
| "hidden_size": 6144, | ||
| "total_num_hidden_layers": 28, | ||
| "total_num_attention_heads": 64, | ||
| "head_size": 576, | ||
| "vocab_size": 131072, | ||
| "total_num_kv_heads": 64, | ||
| "num_experts": 512, | ||
| "is_deepseek_mla": true, | ||
| "is_multimodal_model": false, | ||
| "dtype": "torch.float32" | ||
| } | ||
| } |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.