|
11 | 11 |
|
12 | 12 | import oci |
13 | 13 | import pytest |
| 14 | +from ads.aqua.ui import ModelFormat |
14 | 15 | from parameterized import parameterized |
15 | 16 |
|
16 | 17 | import ads.aqua.model |
@@ -323,16 +324,17 @@ def test_get_foundation_models( |
323 | 324 | ) |
324 | 325 |
|
325 | 326 | assert asdict(aqua_model) == { |
| 327 | + "arm_cpu_supported": False, |
326 | 328 | "compartment_id": f"{ds_model.compartment_id}", |
327 | | - "console_link": ( |
328 | | - f"https://cloud.oracle.com/data-science/models/{ds_model.id}?region={self.app.region}", |
329 | | - ), |
| 329 | + "console_link": f"https://cloud.oracle.com/data-science/models/{ds_model.id}?region={self.app.region}", |
330 | 330 | "icon": "", |
331 | 331 | "id": f"{ds_model.id}", |
332 | 332 | "is_fine_tuned_model": False, |
333 | 333 | "license": f'{ds_model.freeform_tags["license"]}', |
334 | 334 | "model_card": f"{mock_read_file.return_value}", |
| 335 | + "model_format": ModelFormat.SAFETENSORS, |
335 | 336 | "name": f"{ds_model.display_name}", |
| 337 | + "nvidia_gpu_supported": False, |
336 | 338 | "organization": f'{ds_model.freeform_tags["organization"]}', |
337 | 339 | "project_id": f"{ds_model.project_id}", |
338 | 340 | "ready_to_deploy": False if foundation_model_type == "verified" else True, |
@@ -464,10 +466,9 @@ def test_get_model_fine_tuned( |
464 | 466 | mock_query_resource.assert_called() |
465 | 467 |
|
466 | 468 | assert asdict(model) == { |
| 469 | + "arm_cpu_supported": False, |
467 | 470 | "compartment_id": f"{ds_model.compartment_id}", |
468 | | - "console_link": ( |
469 | | - f"https://cloud.oracle.com/data-science/models/{ds_model.id}?region={self.app.region}", |
470 | | - ), |
| 471 | + "console_link": f"https://cloud.oracle.com/data-science/models/{ds_model.id}?region={self.app.region}", |
471 | 472 | "dataset": "test_training_data", |
472 | 473 | "experiment": {"id": "", "name": "", "url": ""}, |
473 | 474 | "icon": "", |
@@ -504,7 +505,9 @@ def test_get_model_fine_tuned( |
504 | 505 | }, |
505 | 506 | ], |
506 | 507 | "model_card": f"{mock_read_file.return_value}", |
| 508 | + "model_format": ModelFormat.SAFETENSORS, |
507 | 509 | "name": f"{ds_model.display_name}", |
| 510 | + "nvidia_gpu_supported": False, |
508 | 511 | "organization": "test_organization", |
509 | 512 | "project_id": f"{ds_model.project_id}", |
510 | 513 | "ready_to_deploy": True, |
@@ -564,6 +567,7 @@ def test_import_verified_model( |
564 | 567 | ds_freeform_tags = { |
565 | 568 | "OCI_AQUA": "ACTIVE", |
566 | 569 | "license": "aqua-license", |
| 570 | + "model_format": "SAFETENSORS", |
567 | 571 | "organization": "oracle", |
568 | 572 | "task": "text-generation", |
569 | 573 | "ready_to_import": "true", |
@@ -762,6 +766,7 @@ def test_import_any_model_smc_container( |
762 | 766 | ) |
763 | 767 | assert model.tags == { |
764 | 768 | "aqua_custom_base_model": "true", |
| 769 | + "model_format": "SAFETENSORS", |
765 | 770 | "ready_to_fine_tune": "true", |
766 | 771 | **ds_freeform_tags, |
767 | 772 | } |
|
0 commit comments