From 3742affaaa08cee2dd6772d96f438e23754463b3 Mon Sep 17 00:00:00 2001 From: Honglin Cao Date: Tue, 4 Mar 2025 11:19:32 -0500 Subject: [PATCH] fix stuff after rebasing - 2025/03/04 --- .python-version | 2 +- .../providers/remote/inference/centml/centml.py | 11 +++++++---- 2 files changed, 8 insertions(+), 5 deletions(-) diff --git a/.python-version b/.python-version index c8cfe3959..92536a9e4 100644 --- a/.python-version +++ b/.python-version @@ -1 +1 @@ -3.10 +3.12.0 diff --git a/llama_stack/providers/remote/inference/centml/centml.py b/llama_stack/providers/remote/inference/centml/centml.py index 0ed31aacd..93fac26ba 100644 --- a/llama_stack/providers/remote/inference/centml/centml.py +++ b/llama_stack/providers/remote/inference/centml/centml.py @@ -32,7 +32,7 @@ from llama_stack.apis.inference import ( ) from llama_stack.distribution.request_headers import NeedsRequestProviderData from llama_stack.providers.utils.inference.model_registry import ( - build_model_alias, + build_model_entry, ModelRegistryHelper, ) from llama_stack.providers.utils.inference.openai_compat import ( @@ -56,11 +56,11 @@ from .config import CentMLImplConfig # Example model aliases that map from CentML’s # published model identifiers to llama-stack's `CoreModelId`. MODEL_ALIASES = [ - build_model_alias( + build_model_entry( "meta-llama/Llama-3.3-70B-Instruct", CoreModelId.llama3_3_70b_instruct.value, ), - build_model_alias( + build_model_entry( "meta-llama/Llama-3.1-405B-Instruct-FP8", CoreModelId.llama3_1_405b_instruct.value, ), @@ -318,11 +318,14 @@ class CentMLInferenceAdapter( async def embeddings( self, + task_type: str, model_id: str, + text_truncation: Optional[str], + output_dimension: Optional[int], contents: List[InterleavedContent], ) -> EmbeddingsResponse: model = await self.model_store.get_model(model_id) - # CentML does not support media + # CentML does not support media for embeddings. assert all(not content_has_media(c) for c in contents), ( "CentML does not support media for embeddings" )