@@ -2254,14 +2254,21 @@ def create_custom_metadata_artifact(
2254
2254
The name of the model custom metadata key
2255
2255
2256
2256
artifact_path_or_content: Union[str,bytes]
2257
- The model custom metadata artifact path to be upload . It can also be the actual content of the defined metadata
2257
+ The model custom metadata artifact path to be uploaded . It can also be the actual content of the custom metadata artifact
2258
2258
The type is string when it represents local path or oss path.
2259
2259
The type is bytes when it represents content itself
2260
2260
2261
2261
path_type: MetadataArtifactPathType
2262
2262
Can be either of MetadataArtifactPathType.LOCAL , MetadataArtifactPathType.OSS , MetadataArtifactPathType.CONTENT
2263
2263
Specifies what type of path is to be provided for metadata artifact.
2264
- Can be either local , oss or the actual content itself
2264
+
2265
+ Example:
2266
+ >>> ds_model=DataScienceModel.from_id("ocid1.datasciencemodel.iad.xxyxz...")
2267
+ >>> ds_model.create_custom_metadata_artifact(
2268
+ ... "README",
2269
+ ... artifact_path_or_content="/Users/<username>/Downloads/README.md",
2270
+ ... path_type=MetadataArtifactPathType.LOCAL
2271
+ ... )
2265
2272
2266
2273
Returns
2267
2274
-------
@@ -2307,7 +2314,7 @@ def create_defined_metadata_artifact(
2307
2314
The name of the model defined metadata key
2308
2315
2309
2316
artifact_path_or_content: Union[str,bytes]
2310
- The model defined metadata artifact path to be upload . It can also be the actual content of the defined metadata
2317
+ The model defined metadata artifact path to be uploaded . It can also be the actual content of the defined metadata
2311
2318
The type is string when it represents local path or oss path.
2312
2319
The type is bytes when it represents content itself
2313
2320
@@ -2316,6 +2323,14 @@ def create_defined_metadata_artifact(
2316
2323
Specifies what type of path is to be provided for metadata artifact.
2317
2324
Can be either local , oss or the actual content itself
2318
2325
2326
+ Example:
2327
+ >>> ds_model=DataScienceModel.from_id("ocid1.datasciencemodel.iad.xxyxz...")
2328
+ >>> ds_model.create_defined_metadata_artifact(
2329
+ ... "README",
2330
+ ... artifact_path_or_content="oci://path/to/bucket/README.md",
2331
+ ... path_type=MetadataArtifactPathType.OSS
2332
+ ... )
2333
+
2319
2334
Returns
2320
2335
-------
2321
2336
ModelMetadataArtifactDetails
@@ -2360,7 +2375,7 @@ def update_custom_metadata_artifact(
2360
2375
The name of the model custom metadata key
2361
2376
2362
2377
artifact_path_or_content: Union[str,bytes]
2363
- The model custom metadata artifact path to be upload . It can also be the actual content of the defined metadata
2378
+ The model custom metadata artifact path to be uploaded . It can also be the actual content of the custom metadata
2364
2379
The type is string when it represents local path or oss path.
2365
2380
The type is bytes when it represents content itself
2366
2381
@@ -2413,7 +2428,7 @@ def update_defined_metadata_artifact(
2413
2428
The name of the model defined metadata key
2414
2429
2415
2430
artifact_path_or_content: Union[str,bytes]
2416
- The model defined metadata artifact path to be upload . It can also be the actual content of the defined metadata
2431
+ The model defined metadata artifact path to be uploaded . It can also be the actual content of the defined metadata
2417
2432
The type is string when it represents local path or oss path.
2418
2433
The type is bytes when it represents content itself
2419
2434
0 commit comments