Skip to content

Commit

Permalink
feat: 支持qwen2.5 fuction_call
Browse files Browse the repository at this point in the history
  • Loading branch information
gaozixiang committed Nov 11, 2024
1 parent 3cfb02f commit e25b072
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions lmdeploy/model.py
Original file line number Diff line number Diff line change
Expand Up @@ -989,12 +989,8 @@ def match(cls, model_path: str) -> Optional[str]:
Args:
model_path (str): the model path used for matching.
"""
if 'qwen' in model_path.lower() and 'qwen2.5' not in model_path.lower():
return 'qwen'
if 'minicpm-v-2_6' in model_path.lower():
return 'minicpmv-2d6'
if 'minicpm3-' in model_path.lower():
return 'minicpm3'
if 'qwen2.5' in model_path.lower():
return 'qwen2d5'

@MODELS.register_module(name='minicpmv-2d6')
@MODELS.register_module(name='minicpm3')
Expand Down Expand Up @@ -1031,8 +1027,12 @@ def match(cls, model_path: str) -> Optional[str]:
Args:
model_path (str): the model path used for matching.
"""
if 'qwen2.5' in model_path.lower():
return 'qwen2d5'
if 'qwen' in model_path.lower() and 'qwen2.5' not in model_path.lower():
return 'qwen'
if 'minicpm-v-2_6' in model_path.lower():
return 'minicpmv-2d6'
if 'minicpm3-' in model_path.lower():
return 'minicpm3'


@MODELS.register_module(name='codellama')
Expand Down

0 comments on commit e25b072

Please sign in to comment.