File tree Expand file tree Collapse file tree 3 files changed +4
-4
lines changed Expand file tree Collapse file tree 3 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -939,7 +939,7 @@ struct common_init_result common_init_from_params(common_params & params) {
939
939
}
940
940
941
941
if (!params.lora_init_without_apply ) {
942
- common_adapter_loras_apply (lctx, params.lora_adapters );
942
+ common_set_adapter_lora (lctx, params.lora_adapters );
943
943
}
944
944
945
945
if (params.sampling .ignore_eos && llama_token_eos (model) == LLAMA_TOKEN_NULL) {
@@ -1006,7 +1006,7 @@ struct common_init_result common_init_from_params(common_params & params) {
1006
1006
return iparams;
1007
1007
}
1008
1008
1009
- void common_adapter_loras_apply (struct llama_context * ctx, std::vector<common_adapter_lora_info> & lora) {
1009
+ void common_set_adapter_lora (struct llama_context * ctx, std::vector<common_adapter_lora_info> & lora) {
1010
1010
llama_clear_adapter_lora (ctx);
1011
1011
for (auto & la : lora) {
1012
1012
if (la.scale != 0 .0f ) {
Original file line number Diff line number Diff line change @@ -503,7 +503,7 @@ struct llama_model * common_load_model_from_hf(
503
503
const struct llama_model_params & params);
504
504
505
505
// clear LoRA adapters from context, then apply new list of adapters
506
- void common_adapter_loras_apply (struct llama_context * ctx, std::vector<common_adapter_lora_info> & lora);
506
+ void common_set_adapter_lora (struct llama_context * ctx, std::vector<common_adapter_lora_info> & lora);
507
507
508
508
//
509
509
// Batch utils
Original file line number Diff line number Diff line change @@ -2927,7 +2927,7 @@ struct server_context {
2927
2927
// make sure we're in the right embedding mode
2928
2928
llama_set_embeddings (ctx, slot_batched->is_non_causal ());
2929
2929
// apply lora, only need to do it once per batch
2930
- common_adapter_loras_apply (ctx, slot_batched->lora );
2930
+ common_set_adapter_lora (ctx, slot_batched->lora );
2931
2931
}
2932
2932
2933
2933
// process the created batch of tokens
You can’t perform that action at this time.
0 commit comments