File tree Expand file tree Collapse file tree 2 files changed +7
-1
lines changed Expand file tree Collapse file tree 2 files changed +7
-1
lines changed Original file line number Diff line number Diff line change @@ -40,6 +40,7 @@ const char * llm_type_name(llm_type type) {
4040 case LLM_TYPE_335M: return "335M";
4141 case LLM_TYPE_410M: return "410M";
4242 case LLM_TYPE_450M: return "450M";
43+ case LLM_TYPE_475M: return "475M";
4344 case LLM_TYPE_770M: return "770M";
4445 case LLM_TYPE_780M: return "780M";
4546 case LLM_TYPE_0_5B: return "0.5B";
@@ -707,7 +708,11 @@ void llama_model::load_hparams(llama_model_loader & ml) {
707708 ml.get_key(LLM_KV_MOE_EVERY_N_LAYERS, hparams.moe_every_n_layers, 0);
708709
709710 if (hparams.n_layer == 12 && hparams.n_embd == 768) {
710- type = LLM_TYPE_137M;
711+ if (arch == LLM_ARCH_NOMIC_BERT) {
712+ type = LLM_TYPE_137M;
713+ } else if (arch == LLM_ARCH_NOMIC_BERT_MOE && hparams.moe_every_n_layers == 2) {
714+ type = LLM_TYPE_475M;
715+ }
711716 }
712717 } break;
713718 case LLM_ARCH_BLOOM:
Original file line number Diff line number Diff line change @@ -36,6 +36,7 @@ enum llm_type {
3636 LLM_TYPE_335M,
3737 LLM_TYPE_410M,
3838 LLM_TYPE_450M,
39+ LLM_TYPE_475M,
3940 LLM_TYPE_770M,
4041 LLM_TYPE_780M,
4142 LLM_TYPE_0_5B,
You can’t perform that action at this time.
0 commit comments