Skip to content

Commit 2f725f6

Browse files
committed
Doc Update
1 parent 962d0ed commit 2f725f6

File tree

4 files changed

+18
-3
lines changed

4 files changed

+18
-3
lines changed

ads/feature_store/dataset.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -530,6 +530,7 @@ def add_models(self, model_details: ModelDetails) -> "Dataset":
530530
self.with_model_details(ModelDetails().with_items(existing_model_details["items"]))
531531
else:
532532
self.with_model_details(ModelDetails().with_items([]))
533+
return self
533534

534535
# self._update_from_oci_dataset_model(self.oci_dataset)
535536
# updated_model_details = self.model_details

ads/feature_store/docs/source/dataset.rst

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -317,3 +317,16 @@ Below is an example of the output.
317317

318318
.. figure:: figures/dataset_lineage.png
319319
:width: 400
320+
321+
322+
Add Model Details
323+
=================
324+
325+
You can call the ``add_models()`` method of the Dataset instance to add model ids to dataset.
326+
The ``.add_models()`` method takes the following parameter:
327+
``ModelDetails()`` with which we can associate model ids.
328+
329+
330+
.. code-block:: python3
331+
332+
dataset.add_models(ModelDetails().with_items([<ocid1.datasciencemodel..<unique_id>]))

ads/feature_store/docs/source/quickstart.rst

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,8 +55,9 @@ Background reading to understand the concepts of Feature Store and OCI Data Scie
5555
compartment_id = "ocid1.compartment.<unique_id>"
5656
metastore_id = "ocid1.datacatalogmetastore.oc1.iad.<unique_id>"
5757
api_gateway_endpoint = "https://**.{region}.oci.customer-oci.com/20230101"
58+
os.environ["OCI_FS_SERVICE_ENDPOINT"] = api_gateway_endpoint
5859
59-
ads.set_auth(auth="user_principal", client_kwargs={"service_endpoint": api_gateway_endpoint})
60+
ads.set_auth(auth="api_key")
6061

6162
# step1: Create feature store
6263
feature_store_resource = (

tests/integration/feature_store/test_dataset_validations.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -91,8 +91,8 @@ def test_dataset_model_details(self):
9191
assert dataset.oci_dataset.id
9292

9393
dataset.materialise()
94-
updated_dataset = dataset.add_models(ModelDetails().with_items(["model_ocid_invalid"]))
95-
assert len(updated_dataset.model_details.get("items")) == 0
94+
dataset.add_models(ModelDetails().with_items(["model_ocid_invalid"]))
95+
assert len(dataset.model_details.get("items")) == 0
9696
self.clean_up_dataset(dataset)
9797
self.clean_up_feature_group(fg)
9898
self.clean_up_entity(entity)

0 commit comments

Comments
 (0)