mostlyai 0.4.4__tar.gz → 0.4.5__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {mostlyai-0.4.4 → mostlyai-0.4.5}/PKG-INFO +1 -1
- {mostlyai-0.4.4 → mostlyai-0.4.5}/mostlyai/__init__.py +1 -1
- {mostlyai-0.4.4 → mostlyai-0.4.5}/mostlyai/model.py +61 -11
- {mostlyai-0.4.4 → mostlyai-0.4.5}/pyproject.toml +1 -1
- {mostlyai-0.4.4 → mostlyai-0.4.5}/LICENSE +0 -0
- {mostlyai-0.4.4 → mostlyai-0.4.5}/README.md +0 -0
- {mostlyai-0.4.4 → mostlyai-0.4.5}/mostlyai/api.py +0 -0
- {mostlyai-0.4.4 → mostlyai-0.4.5}/mostlyai/base.py +0 -0
- {mostlyai-0.4.4 → mostlyai-0.4.5}/mostlyai/connectors.py +0 -0
- {mostlyai-0.4.4 → mostlyai-0.4.5}/mostlyai/exceptions.py +0 -0
- {mostlyai-0.4.4 → mostlyai-0.4.5}/mostlyai/generators.py +0 -0
- {mostlyai-0.4.4 → mostlyai-0.4.5}/mostlyai/naming_conventions.py +0 -0
- {mostlyai-0.4.4 → mostlyai-0.4.5}/mostlyai/shares.py +0 -0
- {mostlyai-0.4.4 → mostlyai-0.4.5}/mostlyai/synthetic_datasets.py +0 -0
- {mostlyai-0.4.4 → mostlyai-0.4.5}/mostlyai/utils.py +0 -0
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
# generated by datamodel-codegen:
|
|
2
|
-
# timestamp: 2024-
|
|
2
|
+
# timestamp: 2024-11-14T17:29:08+00:00
|
|
3
3
|
|
|
4
4
|
from __future__ import annotations
|
|
5
5
|
|
|
@@ -469,6 +469,45 @@ class RareCategoryReplacementMethod(str, Enum):
|
|
|
469
469
|
sample = "SAMPLE"
|
|
470
470
|
|
|
471
471
|
|
|
472
|
+
class ModelConfigurationDifferentialPrivacy(CustomBaseModel):
|
|
473
|
+
"""
|
|
474
|
+
The optional differential privacy configuration for training the model.
|
|
475
|
+
If not provided, then no differential privacy will be applied.
|
|
476
|
+
|
|
477
|
+
"""
|
|
478
|
+
|
|
479
|
+
max_epsilon: Annotated[
|
|
480
|
+
Optional[float],
|
|
481
|
+
Field(
|
|
482
|
+
None,
|
|
483
|
+
alias="maxEpsilon",
|
|
484
|
+
description="Specifies the maximum allowable epsilon value. If the training process exceeds this threshold, it will be terminated early. Only model checkpoints with epsilon values below this limit will be retained. \nIf not provided, the training will proceed without early termination based on epsilon constraints.\n",
|
|
485
|
+
ge=0.0,
|
|
486
|
+
le=10000.0,
|
|
487
|
+
),
|
|
488
|
+
] = None
|
|
489
|
+
noise_multiplier: Annotated[
|
|
490
|
+
Optional[float],
|
|
491
|
+
Field(
|
|
492
|
+
1.5,
|
|
493
|
+
alias="noiseMultiplier",
|
|
494
|
+
description="The ratio of the standard deviation of the Gaussian noise to the L2-sensitivity of the function to which the noise is added (How much noise to add).\n",
|
|
495
|
+
ge=0.0,
|
|
496
|
+
le=10000.0,
|
|
497
|
+
),
|
|
498
|
+
] = 1.5
|
|
499
|
+
max_grad_norm: Annotated[
|
|
500
|
+
Optional[float],
|
|
501
|
+
Field(
|
|
502
|
+
1.0,
|
|
503
|
+
alias="maxGradNorm",
|
|
504
|
+
description="The maximum norm of the per-sample gradients for training the model with differential privacy.\n",
|
|
505
|
+
ge=0.0,
|
|
506
|
+
le=10000.0,
|
|
507
|
+
),
|
|
508
|
+
] = 1.0
|
|
509
|
+
|
|
510
|
+
|
|
472
511
|
class Accuracy(CustomBaseModel):
|
|
473
512
|
overall: Annotated[
|
|
474
513
|
Optional[float],
|
|
@@ -1102,7 +1141,13 @@ class User(CustomBaseModel):
|
|
|
1102
1141
|
id: Annotated[
|
|
1103
1142
|
Optional[str], Field(None, description="The unique identifier of a user")
|
|
1104
1143
|
] = None
|
|
1105
|
-
|
|
1144
|
+
first_name: Annotated[
|
|
1145
|
+
Optional[str],
|
|
1146
|
+
Field(None, alias="firstName", description="First name of a user"),
|
|
1147
|
+
] = None
|
|
1148
|
+
last_name: Annotated[
|
|
1149
|
+
Optional[str], Field(None, alias="lastName", description="Last name of a user")
|
|
1150
|
+
] = None
|
|
1106
1151
|
email: Annotated[Optional[str], Field(None, description="The email of a user")] = (
|
|
1107
1152
|
None
|
|
1108
1153
|
)
|
|
@@ -1112,7 +1157,13 @@ class CurrentUser(CustomBaseModel):
|
|
|
1112
1157
|
id: Annotated[
|
|
1113
1158
|
Optional[str], Field(None, description="The unique identifier of a user")
|
|
1114
1159
|
] = None
|
|
1115
|
-
|
|
1160
|
+
first_name: Annotated[
|
|
1161
|
+
Optional[str],
|
|
1162
|
+
Field(None, alias="firstName", description="First name of a user"),
|
|
1163
|
+
] = None
|
|
1164
|
+
last_name: Annotated[
|
|
1165
|
+
Optional[str], Field(None, alias="lastName", description="Last name of a user")
|
|
1166
|
+
] = None
|
|
1116
1167
|
email: Annotated[Optional[str], Field(None, description="The email of a user")] = (
|
|
1117
1168
|
None
|
|
1118
1169
|
)
|
|
@@ -1243,6 +1294,10 @@ class ModelConfiguration(CustomBaseModel):
|
|
|
1243
1294
|
description="Specifies, if the rare categories for categoricals will be replaced by a constant\n_RARE_ or by a sample from non-rare categories.\nOnly applicable if valueProtection is set to True.\n",
|
|
1244
1295
|
),
|
|
1245
1296
|
] = "CONSTANT"
|
|
1297
|
+
differential_privacy: Annotated[
|
|
1298
|
+
Optional[ModelConfigurationDifferentialPrivacy],
|
|
1299
|
+
Field(None, alias="differentialPrivacy"),
|
|
1300
|
+
] = None
|
|
1246
1301
|
compute: Optional[str] = None
|
|
1247
1302
|
|
|
1248
1303
|
|
|
@@ -1797,14 +1852,9 @@ class Generator(CustomBaseModel):
|
|
|
1797
1852
|
|
|
1798
1853
|
def clone(self, training_status: Literal["NEW", "CONTINUE"] = "NEW") -> "Generator":
|
|
1799
1854
|
"""
|
|
1800
|
-
|
|
1801
|
-
|
|
1802
|
-
|
|
1803
|
-
the model configuration can still be modified. Other configurations, like columns, model, and
|
|
1804
|
-
valueProtection cannot be changed anymore, as these would break compatibility with the existing model
|
|
1805
|
-
weights.
|
|
1806
|
-
|
|
1807
|
-
:param training_status: The training status of the new generator.
|
|
1855
|
+
Clone generator
|
|
1856
|
+
|
|
1857
|
+
:param training_status: The training status of the cloned generator
|
|
1808
1858
|
"""
|
|
1809
1859
|
return self.client._clone(generator_id=self.id, training_status=training_status)
|
|
1810
1860
|
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|