Skip to content

Commit 3ebc9d9

Browse files
committed
sdk docs
1 parent e6b7e9e commit 3ebc9d9

File tree

3 files changed

+124
-21
lines changed

3 files changed

+124
-21
lines changed

md-docs/api/python/client.md

Lines changed: 11 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
## ML3PlatformClient
55
```python
66
ML3PlatformClient(
7-
url: str, api_key: str, timeout: int = 60
7+
url: str, api_key: str, timeout: int = 180
88
)
99
```
1010

@@ -943,8 +943,8 @@ reference of this new model with set_reference request.
943943
### .update_model_version_from_time_range
944944
```python
945945
.update_model_version_from_time_range(
946-
model_id: str, new_model_version: str, from_timestamp: float,
947-
to_timestamp: float
946+
model_id: str, new_model_version: str, default_reference: ReferenceInfo,
947+
segment_references: (list[ReferenceInfo]|None) = None
948948
)
949949
```
950950

@@ -969,8 +969,8 @@ using the method `wait_job_completion(job_id)`
969969

970970
* **model_id** : the identifier of the model
971971
* **new_model_version** : the new version of the model
972-
from_timestamp
973-
to_timestamp
972+
* **default_reference** : the list of time intervals used as default reference
973+
* **segment_references** : list of segment specific time intervals used as reference for the segments
974974

975975

976976
**Raises**
@@ -1207,7 +1207,8 @@ using the method `wait_job_completion(job_id)`
12071207
### .set_model_reference
12081208
```python
12091209
.set_model_reference(
1210-
model_id: str, from_timestamp: float, to_timestamp: float
1210+
model_id: str, default_reference: ReferenceInfo,
1211+
segment_references: (list[ReferenceInfo]|None) = None
12111212
)
12121213
```
12131214

@@ -1231,8 +1232,10 @@ using the method `wait_job_completion(job_id)`
12311232
**Args**
12321233

12331234
* **model_id** : the identifier of the model
1234-
from_timestamp
1235-
to_timestamp
1235+
* **default_reference** : the list of time intervals used as default reference, they are combined with OR operator
1236+
* **segment_references** : a dictionary containing for each specified segments constraints on the time intervals,
1237+
they are combined with OR operator among themselves and with AND operator with the time intervals.
1238+
12361239

12371240

12381241
**Returns**

md-docs/api/python/enums.md

Lines changed: 57 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,38 @@ Base class for all enums in the ML3 Platform SDK
3131
----
3232

3333

34+
## BooleanLicenceFeature
35+
```python
36+
BooleanLicenceFeature()
37+
```
38+
39+
40+
---
41+
Boolean licence feature
42+
43+
**Fields:**
44+
- EXPLAINABILITY
45+
Whether the company has access to explainability reports
46+
- MONITORING
47+
Whether the company has monitoring feature enabled
48+
- MONITORING_METRICS
49+
Whether the company has monitoring metrics feature enabled
50+
- SEGMENTED_MONITORING
51+
Whether the company has segmented monitoring feature enabled
52+
- RETRAINING
53+
Whether the company has retraining feature enabled
54+
- TOPIC_ANALYSIS
55+
Whether the company has topic analysis feature enabled
56+
- RAG_EVALUATION
57+
Whether the company has RAG evaluation feature enabled
58+
- LLM_SECURITY
59+
Whether the company has LLM security feature enabled
60+
- BUSINESS
61+
Whether the company has business feature enabled
62+
63+
----
64+
65+
3466
## ColumnRole
3567
```python
3668
ColumnRole()
@@ -348,12 +380,12 @@ Image:
348380
- IMAGE_BRIGHTNESS
349381
- IMAGE_CONTRAST
350382
- IMAGE_FOCUS
351-
- IMAGE_COLOR_VARIATION_RED
352-
- IMAGE_COLOR_VARIATION_GREEN
353-
- IMAGE_COLOR_VARIATION_BLUE
383+
- IMAGE_BLUR
384+
- IMAGE_COLOR_VARIATION
385+
- IMAGE_COLOR_CONTRAST
354386

355387
Object detection and semantic segmentation:
356-
- TRACKING_OBJECT_POSITION: polar coordinates of farther object from the center of the image
388+
(position wrt Cartesian axis with origin in the center of the image)
357389

358390
----
359391

@@ -397,6 +429,27 @@ MonitoringTarget()
397429
----
398430

399431

432+
## NumericLicenceFeature
433+
```python
434+
NumericLicenceFeature()
435+
```
436+
437+
438+
---
439+
Numeric licence feature
440+
441+
**Fields:**
442+
- MAX_TASKS
443+
Maximum number of tasks that the company can have
444+
- MAX_USERS
445+
Maximum number of users that the company can have
446+
- DAILY_DATA_BATCH_UPLOAD
447+
Maximum number of data batches that the company can upload
448+
in a day. Only considers production data batches.
449+
450+
----
451+
452+
400453
## ProductKeyStatus
401454
```python
402455
ProductKeyStatus()

md-docs/api/python/models.md

Lines changed: 56 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -223,9 +223,9 @@ Column base model
223223
* **model_id** : Optional[str] = None
224224
* **dims** : Optional[tuple[int]] = None
225225
it is mandatory when data_type is Array
226-
* **tol** : Optional[int] = 0
226+
* **tol** : Optional[int | None] = 0
227227
Tolerance for ImageData width and height.
228-
Images can be loaded with size (w +- tol, h +- tol) pixels
228+
Images can be loaded with size (w ± tol, h ± tol) pixels
229229
* **classes_names** : Optional[list[str]] = None
230230
it is mandatory when the column is the target
231231
in multilabel classification tasks
@@ -870,6 +870,30 @@ false positive and false negative costs for each class
870870
----
871871

872872

873+
## NumericLicenceFeatureInfo
874+
```python
875+
NumericLicenceFeatureInfo()
876+
```
877+
878+
879+
---
880+
Numeric Licence feature info model
881+
882+
883+
**Attributes**
884+
885+
* **feature** : NumericLicenceFeature
886+
Current numeric feature
887+
* **max_value** : int | None
888+
Maximum value of the feature. If None, no limit is set
889+
* **used_value** : int
890+
Used value of the feature. If max_value is None,
891+
this value defaults to 0
892+
893+
894+
----
895+
896+
873897
## NumericSegmentRule
874898
```python
875899
NumericSegmentRule()
@@ -919,6 +943,30 @@ Project model
919943
----
920944

921945

946+
## ReferenceInfo
947+
```python
948+
ReferenceInfo()
949+
```
950+
951+
952+
---
953+
Reference info
954+
955+
956+
**Attributes**
957+
958+
* **time_intervals** : list[tuple[float, float]]
959+
List of time intervals used as model reference with tuples
960+
containing the start and end time of the intervals
961+
Can be the default time intervals or segment specific ones
962+
* **segment_id** : str | None
963+
Segment id associated to the model reference considered, None if the
964+
reference is for the whole population (default)
965+
966+
967+
----
968+
969+
922970
## RegressionTaskCostInfo
923971
```python
924972
RegressionTaskCostInfo()
@@ -1269,8 +1317,7 @@ SubscriptionPlanInfo()
12691317

12701318
---
12711319
Data model for a subscription plan
1272-
Permission limit set to None means no limit is set
1273-
Expiration date set to None means no expiration is set
1320+
12741321
Product key data are set only if a product key is associated to the
12751322
subscription plan
12761323

@@ -1279,14 +1326,14 @@ subscription plan
12791326

12801327
* **subscription_id** : str
12811328
* **type** : SubscriptionType
1282-
* **max_tasks** : int | None
1283-
* **max_users** : int | None
1284-
* **monitoring** : bool
1285-
* **explainability** : bool
1286-
* **retraining** : bool
1329+
* **boolean_licence_features** : list[BooleanLicenceFeature]
1330+
Features which are either enabled or disabled
1331+
* **numeric_licence_features** : list[NumericLicenceFeatureInfo]]
1332+
Features associated with a usage limit
12871333
* **is_active** : bool
12881334
* **start_date** : date
12891335
* **expiration_date** : date | None
1336+
If set to None, no expiration is set
12901337
* **product_key** : str | None
12911338
* **product_key_status** : ProductKeyStatus | None
12921339

0 commit comments

Comments
 (0)