fiddler-client 3.15.0__tar.gz → 3.16.0__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.
- {fiddler_client-3.15.0/fiddler_client.egg-info → fiddler_client-3.16.0}/PKG-INFO +3 -3
- fiddler_client-3.16.0/fiddler/VERSION +1 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/entities/job.py +8 -11
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/entities/model.py +6 -16
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/exceptions.py +2 -2
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/libs/http_client.py +3 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/libs/semver.py +2 -2
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/schemas/model_spec.py +1 -1
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/tests/test_http_client_redaction.py +114 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0/fiddler_client.egg-info}/PKG-INFO +3 -3
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler_client.egg-info/requires.txt +2 -2
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/pyproject.toml +14 -10
- fiddler_client-3.15.0/fiddler/VERSION +0 -1
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/LICENSE.txt +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/PUBLIC.md +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/README.md +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/__init__.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/configs.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/connection.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/constants/__init__.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/constants/alert_rule.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/constants/baseline.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/constants/common.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/constants/dataset.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/constants/events.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/constants/job.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/constants/model.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/constants/model_deployment.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/constants/xai.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/decorators.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/entities/__init__.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/entities/alert_record.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/entities/alert_rule.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/entities/base.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/entities/baseline.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/entities/custom_expression.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/entities/dataset.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/entities/events.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/entities/file.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/entities/model_artifact.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/entities/model_deployment.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/entities/organization.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/entities/project.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/entities/surrogate.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/entities/user.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/entities/webhook.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/entities/xai.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/libs/__init__.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/libs/aws.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/libs/json_encoder.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/packtools/__init__.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/packtools/gem.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/packtools/keras_ig_helpers.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/packtools/project_attributions_helpers.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/packtools/template_model.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/schemas/__init__.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/schemas/alert_record.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/schemas/alert_rule.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/schemas/base.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/schemas/baseline.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/schemas/custom_expression.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/schemas/custom_features.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/schemas/dataset.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/schemas/events.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/schemas/file.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/schemas/filter_query.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/schemas/job.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/schemas/model.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/schemas/model_deployment.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/schemas/model_schema.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/schemas/model_task_params.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/schemas/organization.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/schemas/project.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/schemas/response.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/schemas/server_info.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/schemas/user.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/schemas/webhook.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/schemas/xai.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/schemas/xai_params.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/tests/__init__.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/tests/apis/__init__.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/tests/apis/test_alert_record.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/tests/apis/test_alert_rule.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/tests/apis/test_baseline.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/tests/apis/test_custom_metric.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/tests/apis/test_dataset.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/tests/apis/test_events.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/tests/apis/test_files.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/tests/apis/test_generate_model.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/tests/apis/test_job.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/tests/apis/test_mixin.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/tests/apis/test_model.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/tests/apis/test_model_artifact.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/tests/apis/test_model_deployment.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/tests/apis/test_model_surrogate.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/tests/apis/test_project.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/tests/apis/test_segment.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/tests/apis/test_webhook.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/tests/apis/test_xai.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/tests/artifact_test_dir/package.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/tests/conftest.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/tests/constants.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/tests/test_connection.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/tests/test_json_encoder.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/tests/test_logger.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/tests/test_sagemaker_auth.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/tests/test_utils.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/tests/utils.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/utils/__init__.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/utils/column_generator.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/utils/decorators.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/utils/helpers.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/utils/logger.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/utils/model_generator.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/utils/validations.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/utils/version.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/version.py +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler_client.egg-info/SOURCES.txt +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler_client.egg-info/dependency_links.txt +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler_client.egg-info/top_level.txt +0 -0
- {fiddler_client-3.15.0 → fiddler_client-3.16.0}/setup.cfg +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: fiddler-client
|
|
3
|
-
Version: 3.
|
|
3
|
+
Version: 3.16.0
|
|
4
4
|
Summary: Python client for Fiddler Platform
|
|
5
5
|
Author: Fiddler Labs
|
|
6
6
|
License-Expression: Apache-2.0
|
|
@@ -14,7 +14,7 @@ Classifier: Operating System :: OS Independent
|
|
|
14
14
|
Requires-Python: >=3.11
|
|
15
15
|
Description-Content-Type: text/markdown
|
|
16
16
|
License-File: LICENSE.txt
|
|
17
|
-
Requires-Dist: requests<3
|
|
17
|
+
Requires-Dist: requests<3,>=2.33.0
|
|
18
18
|
Requires-Dist: requests-toolbelt
|
|
19
19
|
Requires-Dist: pydantic>=2.0
|
|
20
20
|
Requires-Dist: deprecated>=1.2.18
|
|
@@ -23,7 +23,7 @@ Requires-Dist: simplejson>=3.17.0
|
|
|
23
23
|
Requires-Dist: pyyaml
|
|
24
24
|
Requires-Dist: typing-extensions<5,>=4.6.0
|
|
25
25
|
Requires-Dist: pandas>=2.1.0
|
|
26
|
-
Requires-Dist: pyarrow>=
|
|
26
|
+
Requires-Dist: pyarrow>=23.0.1
|
|
27
27
|
Dynamic: license-file
|
|
28
28
|
|
|
29
29
|
# fiddler-client
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
3.16.0
|
|
@@ -2,8 +2,7 @@
|
|
|
2
2
|
Job entity for managing asynchronous operations in Fiddler.
|
|
3
3
|
|
|
4
4
|
The Job class represents long-running asynchronous operations in the Fiddler platform,
|
|
5
|
-
such as data publishing
|
|
6
|
-
operations that may take significant time to complete.
|
|
5
|
+
such as data publishing and other operations that may take significant time to complete.
|
|
7
6
|
|
|
8
7
|
Key Concepts:
|
|
9
8
|
- **Async Operations**: Handle long-running tasks without blocking
|
|
@@ -29,8 +28,6 @@ Job Status Types:
|
|
|
29
28
|
|
|
30
29
|
Common Use Cases:
|
|
31
30
|
- **Data Publishing**: Monitor large dataset upload progress
|
|
32
|
-
- **Model Artifacts**: Track model deployment and artifact uploads
|
|
33
|
-
- **Surrogate Training**: Monitor surrogate model training progress
|
|
34
31
|
- **Batch Operations**: Handle bulk data processing jobs
|
|
35
32
|
|
|
36
33
|
Example:
|
|
@@ -75,8 +72,8 @@ logger = logging.getLogger(__name__)
|
|
|
75
72
|
class Job(BaseEntity): # pylint: disable=too-many-instance-attributes
|
|
76
73
|
"""Represents an asynchronous operation in the Fiddler platform.
|
|
77
74
|
|
|
78
|
-
A Job tracks the execution of long-running operations such as data publishing
|
|
79
|
-
|
|
75
|
+
A Job tracks the execution of long-running operations such as data publishing
|
|
76
|
+
and other async tasks. Jobs
|
|
80
77
|
provide status monitoring, progress tracking, and error handling for operations
|
|
81
78
|
that may take significant time to complete.
|
|
82
79
|
|
|
@@ -134,8 +131,8 @@ class Job(BaseEntity): # pylint: disable=too-many-instance-attributes
|
|
|
134
131
|
for direct job creation.
|
|
135
132
|
|
|
136
133
|
Note:
|
|
137
|
-
Jobs are automatically created by async operations (like Model.publish()
|
|
138
|
-
|
|
134
|
+
Jobs are automatically created by async operations (like Model.publish())
|
|
135
|
+
and cannot be created directly. Use Job.get()
|
|
139
136
|
to retrieve existing jobs and monitoring methods to track progress.
|
|
140
137
|
"""
|
|
141
138
|
self.name: str | None = None
|
|
@@ -395,9 +392,9 @@ class Job(BaseEntity): # pylint: disable=too-many-instance-attributes
|
|
|
395
392
|
print("Data publishing completed!")
|
|
396
393
|
|
|
397
394
|
# Custom timeout for long-running jobs
|
|
398
|
-
job = model.
|
|
395
|
+
job = model.publish(source="large_dataset.csv")
|
|
399
396
|
job.wait(timeout=3600) # 1 hour timeout
|
|
400
|
-
print("
|
|
397
|
+
print("Large dataset publishing completed!")
|
|
401
398
|
|
|
402
399
|
# Handle job failures
|
|
403
400
|
try:
|
|
@@ -408,7 +405,7 @@ class Job(BaseEntity): # pylint: disable=too-many-instance-attributes
|
|
|
408
405
|
# Handle failure (retry, alert, etc.)
|
|
409
406
|
|
|
410
407
|
# Fast polling for critical operations
|
|
411
|
-
job = model.
|
|
408
|
+
job = model.publish(source="critical_data.csv")
|
|
412
409
|
job.wait(interval=5, timeout=600) # 5 second polling, 10 min timeout
|
|
413
410
|
|
|
414
411
|
Note:
|
|
@@ -2,14 +2,12 @@
|
|
|
2
2
|
"""Model entity for managing ML models in the Fiddler platform.
|
|
3
3
|
|
|
4
4
|
This module provides the Model class for creating, managing, and monitoring machine learning
|
|
5
|
-
models within Fiddler. Models represent ML systems that can be monitored for drift
|
|
6
|
-
|
|
5
|
+
models within Fiddler. Models represent ML systems that can be monitored for drift
|
|
6
|
+
and performance.
|
|
7
7
|
|
|
8
8
|
Key Features:
|
|
9
9
|
- Create models from DataFrames, files, or manual schema/spec definition
|
|
10
10
|
- Publish production and pre-production data for monitoring
|
|
11
|
-
- Upload and manage model artifacts for serving
|
|
12
|
-
- Generate surrogate models for explainability
|
|
13
11
|
- Monitor model performance and data drift
|
|
14
12
|
- Integrate with alert systems and baselines
|
|
15
13
|
|
|
@@ -92,21 +90,18 @@ class Model( # pylint: disable=too-many-public-methods
|
|
|
92
90
|
|
|
93
91
|
The Model class is the central entity for ML model monitoring and management.
|
|
94
92
|
It encapsulates the model's schema, specification, and metadata, and provides
|
|
95
|
-
methods for data publishing
|
|
93
|
+
methods for data publishing and monitoring operations.
|
|
96
94
|
|
|
97
95
|
Key Concepts:
|
|
98
96
|
- **Schema** (:class:`~fiddler.schemas.ModelSchema`): Defines the structure and data types of model inputs/outputs
|
|
99
97
|
- **Spec** (:class:`~fiddler.schemas.ModelSpec`): Defines how columns are used (features, targets, predictions, etc.)
|
|
100
98
|
- **Task** (:class:`~fiddler.constants.ModelTask`): The ML task type (classification, regression, ranking, etc.)
|
|
101
|
-
- **Artifacts** (:class:`~fiddler.entities.ModelArtifact`): Deployable model code and dependencies
|
|
102
|
-
- **Surrogates** (:class:`~fiddler.entities.Surrogate`): Simplified models for fast explanations
|
|
103
99
|
|
|
104
100
|
Lifecycle:
|
|
105
101
|
1. Create model with schema/spec (from data or manual definition)
|
|
106
|
-
2.
|
|
107
|
-
3. Publish
|
|
108
|
-
4.
|
|
109
|
-
5. Set up alerts and monitoring rules
|
|
102
|
+
2. Publish baseline/training data for drift detection
|
|
103
|
+
3. Publish production data for monitoring
|
|
104
|
+
4. Set up alerts and monitoring rules
|
|
110
105
|
|
|
111
106
|
Common Use Cases:
|
|
112
107
|
- **Tabular Models**: Traditional ML models with structured data
|
|
@@ -128,7 +123,6 @@ class Model( # pylint: disable=too-many-public-methods
|
|
|
128
123
|
event_id_col (str, optional): Column name for unique event identifiers
|
|
129
124
|
event_ts_col (str, optional): Column name for event timestamps
|
|
130
125
|
event_ts_format (str, optional): Timestamp format string
|
|
131
|
-
xai_params (:class:`~fiddler.schemas.XaiParams`): Explainability configuration
|
|
132
126
|
|
|
133
127
|
Examples:
|
|
134
128
|
# Create model from DataFrame with automatic schema detection
|
|
@@ -211,8 +205,6 @@ class Model( # pylint: disable=too-many-public-methods
|
|
|
211
205
|
Used for time-based analysis and drift detection.
|
|
212
206
|
event_ts_format: Format string for parsing timestamps in event_ts_col.
|
|
213
207
|
Examples: '%Y-%m-%d %H:%M:%S', '%Y-%m-%dT%H:%M:%SZ'
|
|
214
|
-
xai_params: :class:`~fiddler.schemas.XaiParams` - Configuration for explainability features like
|
|
215
|
-
explanation methods and custom feature definitions.
|
|
216
208
|
|
|
217
209
|
Note:
|
|
218
210
|
The model exists only locally until .create() is called. Use Model.from_data()
|
|
@@ -894,8 +886,6 @@ class Model( # pylint: disable=too-many-public-methods
|
|
|
894
886
|
analysis, drift detection, and temporal monitoring.
|
|
895
887
|
event_ts_format: Timestamp format string for parsing event_ts_col.
|
|
896
888
|
Examples: '%Y-%m-%d %H:%M:%S', '%Y-%m-%dT%H:%M:%SZ'
|
|
897
|
-
xai_params: :class:`~fiddler.schemas.XaiParams` - Explainability configuration including explanation methods
|
|
898
|
-
and custom feature definitions.
|
|
899
889
|
max_cardinality: Maximum unique values to consider a column categorical.
|
|
900
890
|
Columns with more unique values are treated as continuous.
|
|
901
891
|
Default is typically 100-1000 depending on data size.
|
|
@@ -104,7 +104,7 @@ class AsyncJobFailed(BaseError): # noqa: N818
|
|
|
104
104
|
data processing, or batch operations) fail to complete successfully. The job
|
|
105
105
|
may have been submitted successfully but encountered an error during execution.
|
|
106
106
|
|
|
107
|
-
Async jobs in Fiddler include operations like
|
|
107
|
+
Async jobs in Fiddler include operations like baseline
|
|
108
108
|
computations, batch data ingestion, and other time-intensive operations that
|
|
109
109
|
run in the background.
|
|
110
110
|
|
|
@@ -113,7 +113,7 @@ class AsyncJobFailed(BaseError): # noqa: N818
|
|
|
113
113
|
|
|
114
114
|
.. code-block:: python
|
|
115
115
|
|
|
116
|
-
job = model.
|
|
116
|
+
job = model.publish(source="large_dataset.csv")
|
|
117
117
|
try:
|
|
118
118
|
job.wait() # Raises AsyncJobFailed if the job fails
|
|
119
119
|
except fdl.AsyncJobFailed as e:
|
|
@@ -29,6 +29,9 @@ _SENSITIVE_HEADERS = frozenset(
|
|
|
29
29
|
'proxy-authorization',
|
|
30
30
|
'x-api-key',
|
|
31
31
|
'x-amz-security-token',
|
|
32
|
+
# In SageMaker Partner App mode the SageMaker SDK copies the API key
|
|
33
|
+
# from `Authorization` into this header.
|
|
34
|
+
'x-amz-partner-app-authorization',
|
|
32
35
|
}
|
|
33
36
|
)
|
|
34
37
|
_REDACTED = '**REDACTED**'
|
|
@@ -298,11 +298,11 @@ class VersionInfo:
|
|
|
298
298
|
return self.compare(other) != 0
|
|
299
299
|
|
|
300
300
|
@comparator
|
|
301
|
-
def __lt__(self, other: VersionInfo) -> bool:
|
|
301
|
+
def __lt__(self, other: VersionInfo) -> bool:
|
|
302
302
|
return self.compare(other) < 0
|
|
303
303
|
|
|
304
304
|
@comparator
|
|
305
|
-
def __le__(self, other: VersionInfo) -> bool:
|
|
305
|
+
def __le__(self, other: VersionInfo) -> bool:
|
|
306
306
|
return self.compare(other) <= 0
|
|
307
307
|
|
|
308
308
|
@comparator
|
|
@@ -20,7 +20,7 @@ class ModelSpec(BaseModel):
|
|
|
20
20
|
that enhance model monitoring and analysis capabilities.
|
|
21
21
|
|
|
22
22
|
This specification is crucial for Fiddler to understand your model's structure,
|
|
23
|
-
enabling proper monitoring, drift detection, bias analysis
|
|
23
|
+
enabling proper monitoring, drift detection, and bias analysis
|
|
24
24
|
features. It acts as the contract between your model and Fiddler's monitoring
|
|
25
25
|
infrastructure.
|
|
26
26
|
|
|
@@ -14,16 +14,23 @@ import logging
|
|
|
14
14
|
from typing import Any
|
|
15
15
|
|
|
16
16
|
import pytest
|
|
17
|
+
import requests
|
|
17
18
|
import responses
|
|
19
|
+
from requests.auth import AuthBase
|
|
20
|
+
from requests.models import PreparedRequest
|
|
18
21
|
from requests.structures import CaseInsensitiveDict
|
|
19
22
|
|
|
20
23
|
from fiddler.libs.http_client import (
|
|
21
24
|
_REDACTED,
|
|
22
25
|
_SENSITIVE_HEADERS,
|
|
26
|
+
RequestClient,
|
|
23
27
|
_redact_headers,
|
|
24
28
|
)
|
|
25
29
|
from fiddler.tests.constants import TOKEN, URL
|
|
26
30
|
|
|
31
|
+
# In SageMaker Partner App mode the SageMaker SDK copies the API key here.
|
|
32
|
+
SAGEMAKER_AUTH_HEADER = 'X-Amz-Partner-App-Authorization'
|
|
33
|
+
|
|
27
34
|
|
|
28
35
|
# ---------------------------------------------------------------------------
|
|
29
36
|
# Unit tests for _redact_headers
|
|
@@ -55,6 +62,12 @@ class TestRedactHeaders:
|
|
|
55
62
|
assert result[h] == _REDACTED, f'{h} was not redacted'
|
|
56
63
|
assert result['Accept'] == 'application/json'
|
|
57
64
|
|
|
65
|
+
def test_sagemaker_auth_header_redacted(self) -> None:
|
|
66
|
+
headers = {SAGEMAKER_AUTH_HEADER: f'Bearer {TOKEN}', 'Accept': 'text/plain'}
|
|
67
|
+
result = _redact_headers(headers)
|
|
68
|
+
assert result[SAGEMAKER_AUTH_HEADER] == _REDACTED
|
|
69
|
+
assert result['Accept'] == 'text/plain'
|
|
70
|
+
|
|
58
71
|
def test_case_insensitive_dict(self) -> None:
|
|
59
72
|
headers = CaseInsensitiveDict(
|
|
60
73
|
{'Authorization': f'Bearer {TOKEN}', 'Accept': 'text/plain'}
|
|
@@ -140,3 +153,104 @@ class TestLogRedaction:
|
|
|
140
153
|
f'Auth token leaked into DEBUG log output: found {TOKEN!r}'
|
|
141
154
|
)
|
|
142
155
|
assert _REDACTED in all_log_text, 'Expected redacted placeholder in log output'
|
|
156
|
+
|
|
157
|
+
|
|
158
|
+
# ---------------------------------------------------------------------------
|
|
159
|
+
# Integration: SageMaker Partner App mode
|
|
160
|
+
# ---------------------------------------------------------------------------
|
|
161
|
+
|
|
162
|
+
|
|
163
|
+
class _FakePartnerAppAuth(AuthBase):
|
|
164
|
+
"""Stand-in for the ``requests`` auth callback of the SageMaker SDK.
|
|
165
|
+
|
|
166
|
+
Like ``PartnerAppAuthUtils.get_signed_request`` in sagemaker 2.257.0, it
|
|
167
|
+
copies the API key from ``Authorization`` into
|
|
168
|
+
``X-Amz-Partner-App-Authorization`` and then puts a SigV4 signature into
|
|
169
|
+
``Authorization``.
|
|
170
|
+
"""
|
|
171
|
+
|
|
172
|
+
def __call__(self, request: PreparedRequest) -> PreparedRequest:
|
|
173
|
+
request.headers[SAGEMAKER_AUTH_HEADER] = request.headers['Authorization']
|
|
174
|
+
request.headers['Authorization'] = 'AWS4-HMAC-SHA256 Credential=dummykey/...'
|
|
175
|
+
return request
|
|
176
|
+
|
|
177
|
+
|
|
178
|
+
class _FakePartnerAppAuthProvider:
|
|
179
|
+
"""Stand-in for ``sagemaker.PartnerAppAuthProvider``."""
|
|
180
|
+
|
|
181
|
+
def get_auth(self) -> AuthBase:
|
|
182
|
+
return _FakePartnerAppAuth()
|
|
183
|
+
|
|
184
|
+
|
|
185
|
+
class TestSageMakerLogRedaction:
|
|
186
|
+
"""Assert that the client does not log the API key in SageMaker mode.
|
|
187
|
+
|
|
188
|
+
The SageMaker SDK is not a test dependency, so a stand-in performs its
|
|
189
|
+
header mutation. That leaves out botocore, which logs the request it
|
|
190
|
+
signs on its own ``botocore.auth`` logger at DEBUG.
|
|
191
|
+
|
|
192
|
+
See: https://github.com/fiddler-labs/fiddler/issues/28294
|
|
193
|
+
"""
|
|
194
|
+
|
|
195
|
+
@pytest.fixture
|
|
196
|
+
def client(self, monkeypatch: pytest.MonkeyPatch) -> RequestClient:
|
|
197
|
+
"""Client that authenticates like in SageMaker Partner App mode."""
|
|
198
|
+
monkeypatch.setattr(
|
|
199
|
+
'fiddler.libs.aws.conditionally_init_aws_sm_auth',
|
|
200
|
+
_FakePartnerAppAuthProvider,
|
|
201
|
+
)
|
|
202
|
+
return RequestClient(
|
|
203
|
+
base_url=URL,
|
|
204
|
+
headers={'Authorization': f'Bearer {TOKEN}'},
|
|
205
|
+
)
|
|
206
|
+
|
|
207
|
+
@staticmethod
|
|
208
|
+
def _assert_header_logged_without_key(
|
|
209
|
+
caplog: pytest.LogCaptureFixture, level: int
|
|
210
|
+
) -> None:
|
|
211
|
+
# The request did carry the API key in the SageMaker header ...
|
|
212
|
+
sent_headers = responses.calls[0].request.headers
|
|
213
|
+
assert sent_headers[SAGEMAKER_AUTH_HEADER] == f'Bearer {TOKEN}'
|
|
214
|
+
# ... and that header was logged at the given level ...
|
|
215
|
+
assert any(
|
|
216
|
+
SAGEMAKER_AUTH_HEADER in record.getMessage()
|
|
217
|
+
for record in caplog.records
|
|
218
|
+
if record.levelno == level
|
|
219
|
+
), f'Expected {SAGEMAKER_AUTH_HEADER} in the logged request headers'
|
|
220
|
+
# ... but no record at any level contains the key.
|
|
221
|
+
assert TOKEN not in caplog.text, f'API key {TOKEN!r} leaked into log output'
|
|
222
|
+
|
|
223
|
+
@responses.activate
|
|
224
|
+
def test_4xx_info_log_redacts_sagemaker_auth_header(
|
|
225
|
+
self, client: RequestClient, caplog: pytest.LogCaptureFixture
|
|
226
|
+
) -> None:
|
|
227
|
+
"""A 404 response logs request details at INFO — key must be redacted."""
|
|
228
|
+
responses.add(
|
|
229
|
+
responses.GET,
|
|
230
|
+
f'{URL}/v3/some-endpoint',
|
|
231
|
+
json={'error': {'code': 404, 'message': 'not found'}},
|
|
232
|
+
status=404,
|
|
233
|
+
)
|
|
234
|
+
|
|
235
|
+
with caplog.at_level(logging.DEBUG):
|
|
236
|
+
with pytest.raises(requests.HTTPError):
|
|
237
|
+
client.get(url='/v3/some-endpoint')
|
|
238
|
+
|
|
239
|
+
self._assert_header_logged_without_key(caplog, logging.INFO)
|
|
240
|
+
|
|
241
|
+
@responses.activate
|
|
242
|
+
def test_debug_log_redacts_sagemaker_auth_header(
|
|
243
|
+
self, client: RequestClient, caplog: pytest.LogCaptureFixture
|
|
244
|
+
) -> None:
|
|
245
|
+
"""DEBUG-level request header logging must also redact the key."""
|
|
246
|
+
responses.add(
|
|
247
|
+
responses.GET,
|
|
248
|
+
f'{URL}/v3/some-endpoint',
|
|
249
|
+
json={'data': {}},
|
|
250
|
+
status=200,
|
|
251
|
+
)
|
|
252
|
+
|
|
253
|
+
with caplog.at_level(logging.DEBUG):
|
|
254
|
+
client.get(url='/v3/some-endpoint')
|
|
255
|
+
|
|
256
|
+
self._assert_header_logged_without_key(caplog, logging.DEBUG)
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: fiddler-client
|
|
3
|
-
Version: 3.
|
|
3
|
+
Version: 3.16.0
|
|
4
4
|
Summary: Python client for Fiddler Platform
|
|
5
5
|
Author: Fiddler Labs
|
|
6
6
|
License-Expression: Apache-2.0
|
|
@@ -14,7 +14,7 @@ Classifier: Operating System :: OS Independent
|
|
|
14
14
|
Requires-Python: >=3.11
|
|
15
15
|
Description-Content-Type: text/markdown
|
|
16
16
|
License-File: LICENSE.txt
|
|
17
|
-
Requires-Dist: requests<3
|
|
17
|
+
Requires-Dist: requests<3,>=2.33.0
|
|
18
18
|
Requires-Dist: requests-toolbelt
|
|
19
19
|
Requires-Dist: pydantic>=2.0
|
|
20
20
|
Requires-Dist: deprecated>=1.2.18
|
|
@@ -23,7 +23,7 @@ Requires-Dist: simplejson>=3.17.0
|
|
|
23
23
|
Requires-Dist: pyyaml
|
|
24
24
|
Requires-Dist: typing-extensions<5,>=4.6.0
|
|
25
25
|
Requires-Dist: pandas>=2.1.0
|
|
26
|
-
Requires-Dist: pyarrow>=
|
|
26
|
+
Requires-Dist: pyarrow>=23.0.1
|
|
27
27
|
Dynamic: license-file
|
|
28
28
|
|
|
29
29
|
# fiddler-client
|
|
@@ -20,7 +20,7 @@ classifiers = [
|
|
|
20
20
|
]
|
|
21
21
|
requires-python = ">=3.11"
|
|
22
22
|
dependencies = [
|
|
23
|
-
"requests
|
|
23
|
+
"requests>=2.33.0,<3", # Security floor: CVE-2026-25645.
|
|
24
24
|
"requests-toolbelt",
|
|
25
25
|
"pydantic>=2.0",
|
|
26
26
|
"deprecated>=1.2.18",
|
|
@@ -29,7 +29,7 @@ dependencies = [
|
|
|
29
29
|
"pyyaml",
|
|
30
30
|
"typing-extensions>=4.6.0,<5",
|
|
31
31
|
"pandas>=2.1.0",
|
|
32
|
-
"pyarrow>=
|
|
32
|
+
"pyarrow>=23.0.1", # Security floor: CVE-2026-25087.
|
|
33
33
|
]
|
|
34
34
|
|
|
35
35
|
[project.urls]
|
|
@@ -49,26 +49,30 @@ fiddler = ["VERSION"]
|
|
|
49
49
|
dev = [
|
|
50
50
|
"deepdiff==9.1.0",
|
|
51
51
|
"flake8==7.4.1",
|
|
52
|
-
"flake8-bugbear==26.
|
|
52
|
+
"flake8-bugbear==26.10.27",
|
|
53
53
|
"flake8-builtins==3.1.0",
|
|
54
54
|
"flake8-eradicate==1.5.0",
|
|
55
|
-
"mypy==2.
|
|
56
|
-
"mypy-extensions==1.
|
|
57
|
-
"pylint==4.1.
|
|
55
|
+
"mypy==2.4.1",
|
|
56
|
+
"mypy-extensions==1.2.0",
|
|
57
|
+
"pylint==4.1.4",
|
|
58
58
|
"pylint-pydantic==0.4.1",
|
|
59
|
-
"pytest==9.
|
|
59
|
+
"pytest==9.2.0",
|
|
60
60
|
"pytest-cov==7.1.0",
|
|
61
|
-
"pytest-mock==3.
|
|
61
|
+
"pytest-mock==3.17.0",
|
|
62
62
|
"python-decouple==3.8",
|
|
63
63
|
"responses==0.26.3",
|
|
64
64
|
"types-PyYAML",
|
|
65
|
-
"types-requests==2.33.0.
|
|
66
|
-
"types-simplejson==4.
|
|
65
|
+
"types-requests==2.33.0.20261030",
|
|
66
|
+
"types-simplejson==4.2.0.20261006",
|
|
67
67
|
"ruff",
|
|
68
68
|
"twine",
|
|
69
69
|
"build",
|
|
70
70
|
]
|
|
71
71
|
|
|
72
|
+
[tool.uv]
|
|
73
|
+
# Keep the release cutoffs already recorded in uv.lock reproducible.
|
|
74
|
+
exclude-newer = "5 days"
|
|
75
|
+
|
|
72
76
|
[tool.pytest.ini_options]
|
|
73
77
|
testpaths = ["fiddler/tests"]
|
|
74
78
|
log_cli_level = "INFO"
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
3.15.0
|
|
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
|
|
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
|
|
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
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler/packtools/project_attributions_helpers.py
RENAMED
|
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
|
|
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
|
|
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
|
|
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
|
|
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
|
|
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
|
{fiddler_client-3.15.0 → fiddler_client-3.16.0}/fiddler_client.egg-info/dependency_links.txt
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|