Skip to content

Commit

Permalink
Add CodeLlama as part of model presets (mlc-ai#1190)
Browse files Browse the repository at this point in the history
  • Loading branch information
junrushao authored Nov 4, 2023
1 parent 5d1dc34 commit 4832c2f
Showing 1 changed file with 70 additions and 0 deletions.
70 changes: 70 additions & 0 deletions python/mlc_chat/compiler/model/model.py
Original file line number Diff line number Diff line change
Expand Up @@ -134,4 +134,74 @@ class Model:
"use_cache": True,
"vocab_size": 32000,
},
"codellama_7b": {
"_name_or_path": "codellama/CodeLlama-7b-hf",
"architectures": ["LlamaForCausalLM"],
"bos_token_id": 1,
"eos_token_id": 2,
"hidden_act": "silu",
"hidden_size": 4096,
"initializer_range": 0.02,
"intermediate_size": 11008,
"max_position_embeddings": 16384,
"model_type": "llama",
"num_attention_heads": 32,
"num_hidden_layers": 32,
"num_key_value_heads": 32,
"pretraining_tp": 1,
"rms_norm_eps": 1e-05,
"rope_scaling": None,
"rope_theta": 1000000,
"tie_word_embeddings": False,
"torch_dtype": "bfloat16",
"transformers_version": "4.33.0.dev0",
"use_cache": True,
"vocab_size": 32016,
},
"codellama_13b": {
"architectures": ["LlamaForCausalLM"],
"bos_token_id": 1,
"eos_token_id": 2,
"hidden_act": "silu",
"hidden_size": 5120,
"initializer_range": 0.02,
"intermediate_size": 13824,
"max_position_embeddings": 16384,
"model_type": "llama",
"num_attention_heads": 40,
"num_hidden_layers": 40,
"num_key_value_heads": 40,
"pretraining_tp": 1,
"rms_norm_eps": 1e-05,
"rope_scaling": None,
"rope_theta": 1000000,
"tie_word_embeddings": False,
"torch_dtype": "bfloat16",
"transformers_version": "4.32.0.dev0",
"use_cache": True,
"vocab_size": 32016,
},
"codellama_34b": {
"architectures": ["LlamaForCausalLM"],
"bos_token_id": 1,
"eos_token_id": 2,
"hidden_act": "silu",
"hidden_size": 8192,
"initializer_range": 0.02,
"intermediate_size": 22016,
"max_position_embeddings": 16384,
"model_type": "llama",
"num_attention_heads": 64,
"num_hidden_layers": 48,
"num_key_value_heads": 8,
"pretraining_tp": 1,
"rms_norm_eps": 1e-05,
"rope_scaling": None,
"rope_theta": 1000000,
"tie_word_embeddings": False,
"torch_dtype": "bfloat16",
"transformers_version": "4.32.0.dev0",
"use_cache": True,
"vocab_size": 32016,
},
}

0 comments on commit 4832c2f

Please sign in to comment.