File tree Expand file tree Collapse file tree 1 file changed +6
-2
lines changed
vllm/model_executor/models Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -366,12 +366,16 @@ def load_weights(self,
366
366
weight_loader (param , loaded_weight )
367
367
368
368
369
- class BaichuanForCausalLM (BaiChuanBaseForCausalLM ): # baichuan 13b
369
+ class BaichuanForCausalLM (BaiChuanBaseForCausalLM
370
+ ): # baichuan 13b, baichuan2 13b, baichuan2 7b
370
371
371
372
def __init__ (self ,
372
373
config ,
373
374
linear_method : Optional [LinearMethodBase ] = None ):
374
- super ().__init__ (config , "ALIBI" , linear_method )
375
+ if config .hidden_size == 4096 : # baichuan2 7b
376
+ super ().__init__ (config , "ROPE" , linear_method )
377
+ else : # baichuan 13b, baichuan2 13b
378
+ super ().__init__ (config , "ALIBI" , linear_method )
375
379
376
380
377
381
class BaiChuanForCausalLM (BaiChuanBaseForCausalLM ): # baichuan 7b
You can’t perform that action at this time.
0 commit comments