Skip to content

Commit 256c615

Browse files
authored
Merge branch 'main' into tests/explainers
2 parents aceed56 + df59b07 commit 256c615

File tree

2 files changed

+12
-2
lines changed

2 files changed

+12
-2
lines changed

ads/aqua/config/container_config.py

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,9 @@ class AquaContainerConfigItem(Serializable):
8080
default_factory=AquaContainerConfigSpec,
8181
description="Detailed container specification.",
8282
)
83+
usages: Optional[List[str]] = Field(
84+
default_factory=list, description="Supported usages."
85+
)
8386

8487
class Config:
8588
extra = "allow"
@@ -131,7 +134,7 @@ def from_container_index_json(
131134
-------
132135
AquaContainerConfig: The constructed container configuration.
133136
"""
134-
#TODO: Return this logic back if necessary in the next iteraion.
137+
# TODO: Return this logic back if necessary in the next iteraion.
135138
# if not config:
136139
# config = get_container_config()
137140

@@ -144,6 +147,7 @@ def from_container_index_json(
144147
for container in containers:
145148
platforms = container.get("platforms", [])
146149
model_formats = container.get("modelFormats", [])
150+
usages = container.get("usages", [])
147151
container_spec = (
148152
config.get(ContainerSpec.CONTAINER_SPEC, {}).get(
149153
container_type, {}
@@ -160,6 +164,7 @@ def from_container_index_json(
160164
family=container_type,
161165
platforms=platforms,
162166
model_formats=model_formats,
167+
usages=usages,
163168
spec=(
164169
AquaContainerConfigSpec(
165170
cli_param=container_spec.get(

tests/unitary/with_extras/aqua/test_ui.py

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
#!/usr/bin/env python
22
# -*- coding: utf-8 -*--
33

4-
# Copyright (c) 2024 Oracle and/or its affiliates.
4+
# Copyright (c) 2024, 2025 Oracle and/or its affiliates.
55
# Licensed under the Universal Permissive License v 1.0 as shown at https://oss.oracle.com/licenses/upl/
66

77
import hashlib
@@ -518,6 +518,7 @@ def test_list_containers(self, mock_get_container_config):
518518
"platforms": [],
519519
"model_formats": [],
520520
"spec": None,
521+
"usages": [],
521522
}
522523
],
523524
"inference": [
@@ -541,6 +542,7 @@ def test_list_containers(self, mock_get_container_config):
541542
"restricted_params": [],
542543
"server_port": "8080",
543544
},
545+
"usages": [],
544546
},
545547
{
546548
"name": "dsmc://odsc-text-generation-inference",
@@ -567,6 +569,7 @@ def test_list_containers(self, mock_get_container_config):
567569
],
568570
"server_port": "8080",
569571
},
572+
"usages": [],
570573
},
571574
{
572575
"name": "dsmc://odsc-vllm-serving",
@@ -592,6 +595,7 @@ def test_list_containers(self, mock_get_container_config):
592595
],
593596
"server_port": "8080",
594597
},
598+
"usages": [],
595599
},
596600
],
597601
"finetune": [
@@ -603,6 +607,7 @@ def test_list_containers(self, mock_get_container_config):
603607
"platforms": [],
604608
"model_formats": [],
605609
"spec": None,
610+
"usages": [],
606611
}
607612
],
608613
}

0 commit comments

Comments
 (0)