diff --git a/openllm-core/src/openllm_core/protocol/openai.py b/openllm-core/src/openllm_core/protocol/openai.py index 42b22bd7..e2bec7d5 100644 --- a/openllm-core/src/openllm_core/protocol/openai.py +++ b/openllm-core/src/openllm_core/protocol/openai.py @@ -45,8 +45,6 @@ class CompletionRequest(pydantic.BaseModel): class ChatCompletionRequest(pydantic.BaseModel): messages: t.List[t.Dict[str, str]] model: str = pydantic.Field(default=None) - functions: t.List[t.Dict[str, str]] = pydantic.Field(default_factory=list) - function_calls: t.List[t.Dict[str, str]] = pydantic.Field(default_factory=list) temperature: t.Optional[float] = 0.7 top_p: t.Optional[float] = 1.0 n: t.Optional[int] = 1 diff --git a/openllm-python/src/_openllm_tiny/_entrypoint.py b/openllm-python/src/_openllm_tiny/_entrypoint.py index 0adb8d3e..52c849f3 100644 --- a/openllm-python/src/_openllm_tiny/_entrypoint.py +++ b/openllm-python/src/_openllm_tiny/_entrypoint.py @@ -423,10 +423,11 @@ def build_command( bentomodel = bentoml.models.get(model_id.lower()) model_id = bentomodel.path _revision = bentomodel.tag.version + _tag_name = bentomodel.tag.name if not trust_remote_code: trust_remote_code = True except (ValueError, bentoml.exceptions.NotFound): - bentomodel, _revision = None, None + bentomodel, _revision, _tag_name = None, None, None llm_config = core.AutoConfig.from_id(model_id, trust_remote_code=trust_remote_code) transformers_config = transformers.AutoConfig.from_pretrained(model_id, trust_remote_code=trust_remote_code) @@ -450,7 +451,7 @@ def build_command( if bento_tag is None: _bento_version = first_not_none(bento_version, default=_revision) generated_tag = bentoml.Tag.from_taglike( - f'{normalise_model_name(model_id)}-service:{_bento_version}'.lower().strip() + f'{_tag_name if _tag_name is not None else normalise_model_name(model_id)}-service:{_bento_version}'.lower().strip() ) else: generated_tag = bentoml.Tag.from_taglike(bento_tag)