Skip to content

Commit

Permalink
add other starcoder models: 3B, 7B, 15B
Browse files Browse the repository at this point in the history
  • Loading branch information
wsxiaoys committed Sep 15, 2023
1 parent 57eaa39 commit 5ca037b
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions llama.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -918,6 +918,7 @@ enum e_model {
MODEL_3B,
MODEL_7B,
MODEL_13B,
MODEL_15B,
MODEL_30B,
MODEL_34B,
MODEL_40B,
Expand Down Expand Up @@ -1624,9 +1625,11 @@ std::string llama_model_ftype_name(enum llama_ftype ftype) {

static const char * llama_model_type_name(e_model type) {
switch (type) {
case MODEL_1B: return "3B";
case MODEL_3B: return "3B";
case MODEL_7B: return "7B";
case MODEL_13B: return "13B";
case MODEL_15B: return "15B";
case MODEL_30B: return "30B";
case MODEL_34B: return "34B";
case MODEL_40B: return "40B";
Expand Down Expand Up @@ -1750,6 +1753,9 @@ static void llm_load_hparams(
GGUF_GET_KEY(ctx, hparams.f_norm_eps, gguf_get_val_f32, GGUF_TYPE_FLOAT32, true, kv(LLM_KV_ATTENTION_LAYERNORM_EPS));
switch (hparams.n_layer) {
case 24: model.type = e_model::MODEL_1B; break;
case 36: model.type = e_model::MODEL_3B; break;
case 42: model.type = e_model::MODEL_7B; break;
case 40: model.type = e_model::MODEL_15B; break;
default: model.type = e_model::MODEL_UNKNOWN;
}
} break;
Expand Down

0 comments on commit 5ca037b

Please sign in to comment.