Python client for Fiddler Service
Project description
Fiddler Client
Python client for interacting with Fiddler. Provides a user-friendly interface to our REST API and enables event publishing for use with our monitoring features.
Requirements
Requires Python >= Python-3.6.3 and pip >= 19.0
Installation
$ pip3 install fiddler-client
API Example Usage
Documentation for the API can be found here. For examples of interacting with our APIs, please check out our Quick Start Guide as well as the work notebooks found on our Samples Github.
Version History
1.0.0
Inaugural client for Fiddler 22.0! This version includes numerous improvements for stability, performance, and usability.
Compatible with server versions >=22.0.0.
0.8.4.5
-
Modifications
- Move all steps inside register_model to server-side.
0.8.4.4
-
Modifications
- Refactored all methods which are minor utilities into utils module.
0.8.4.3
-
Modifications
- Raise exception on fiddler server connection check failure.
0.8.4.2
-
Modifications
- Fix upload dataset type validation issue.
0.8.4.1
-
Modifications
- Use parquet format internally for uploading batch events
0.8.4
-
Modifications
- Moved the calculations inside trigger pre computation to server side.
- Fixed a bug whereby run_model was returning predictions ordered by feature dataframe row index regardless of row order.
0.8.3.1
-
Modifications
- Remove
do_import
flag from upload dataset API
- Remove
0.8.3
-
Modifications
- Dataset upload using parquet file format with snappy compression for internal transfer
- Add a version requirement for botocore<1.23, as 1.23 seems to break compatibility with the urllib3 version we use.
0.8.2
-
Modifications
- Add pyarrow as dependency
- Add
get_pandas_dtypes()
andget_arrow_schema()
functions toDatasetInfo
- Add
get_arrow_field()
function toColumn
- Add
HigherLevelAggregates
tocore_objects
HigherLevelAggregates
currently supportsTop K
filtering
0.8.1.6
-
Modifications
- Add a parameter in list_projects API to get detailed project information
0.8.1.5
-
Modifications
- Allow
run_explanation
api call to pass a list of explanation withig_flex
and one of the shap algorithm
- Allow
0.8.1.8
-
Modifications
- Minor bug fixes and improvements.
0.8.1.7
-
Modifications
- Minor bug fixes and improvements.
0.8.1.6 - ##### Modifications
- Minor bug fix for the datetime format.
0.8.1.5
-
Modifications
- Add a parameter in list_projects API to get detailed project information
0.8.1.4
-
Modifications
- Minor bugfix for categorical feature drift
0.8.1.3
-
Modifications
- Addressed an issue with categorical features with string literals containing numeric content
0.8.1.2
-
Modifications
- Implement a ranking surrogate model for ranking task models
0.8.1.1
-
Modifications
- change the dependecy of requests package to 0.25.1
0.8.1
-
Modifications
- Improved
SegmentInfo
validation. - make the dependency versions less strict.
- Improved
0.8.0
-
New Features
- New
publish_events_batch_schema
API call, Publishes a batch events object to Fiddler Service using the passedpublish_schema
as a template. - New Ranking Monitoring capability available with publish_events_batch API
- New
-
Modifications
- Enforced package versions in setup.py
trigger_pre_computation
has an additional optional argument (cache_dataset
) to enable/disable dataset histograms caching.register_model
has 3 additional optional arguments to enable/disable pdp caching (set to False by default), feature importance caching (set to True by default) and dataset histograms caching (set to True by default).
0.7.6
-
New Features
- New segment monitoring related functionality (currently in preview):
- Ability to create and validate
SegmentInfo
objects, upload_segment
BE call,activate_segment
BE call,deactivate_segment
BE call, andlist_segments
BE call,
- Ability to create and validate
- New segment monitoring related functionality (currently in preview):
-
Modifications
- Upon connecting to the server, the client now performs a version check for the server by default. Earlier the default was to only do a version check for the client.
0.7.5
-
New Features
- New
update_event
parameter forpublish_events_batch
API. - Changes to
fdl.publish_event()
:- Renamed parameter
event_time_stamp
toevent_timestamp
- Added new parameter:
timestamp_format
- Allows specification of timestamp format using the
FiddlerTimestamp
class
- Allows specification of timestamp format using the
- Renamed parameter
- New
0.7.4
-
New Features
- New
initialize_monitoring
API call, sets up monitoring for a model. Intended to also work retroactively for legacy schema.
- New
-
Modifications
- Modified
DatasetInfo.from_dataframe
andModelInfo.from_dataset_info
to take additionaldataset_id
as parameter. - Modified the
outputs
parameter ofModelInfo.from_dataset_info
to now expect a dictionary in case of regression tasks, specifying output range. - Modified the
preferred_explanation_method
parameter ofModelInfo.from_dataset_info
to accept string names fromcustom_explanation_names
. Details in docstring. - Misc bug fixes and documentation enhancements.
- Modified
0.7.3
-
New Features
- Changed the default display for
ModelInfo
andDatasetInfo
to render HTML instead of plaintext, when accessed via jupyter notebooks - Added support for GCP Storage ingestion of log events using
fdl.BatchPublishType.GCP_STORAGE
- Changed the default display for
0.7.2
-
New Features
- Restructured the following arguments for
fdl.ModelInfo.from_dataset_info()
- Added:
categorical_target_class_details
:- Mandatory for Multiclass classification tasks, optional for Binary (unused for Regression)
- Used to specify the positive class for Binary classification, and the class order for Multiclass classification
- Modified:
target
:- No longer optional, models must specify target columns
- Added:
- Restructured the following arguments for
0.7.1
-
New Features
- Restructured the following arguments for
fdl.publish_events_batch()
- Added:
id_field
:- Column to extract
id
value from
- Column to extract
- Added:
timestamp_format
:- Format of timestamp within batch object. Can be one of:
fdl.FiddlerTimestamp.INFER
fdl.FiddlerTimestamp.EPOCH_MILLISECONDS
fdl.FiddlerTimestamp.EPOCH_SECONDS
fdl.FiddlerTimestamp.ISO_8601
Removed:default_timestamp
- Format of timestamp within batch object. Can be one of:
- Added:
- Minor bug fixes
- Restructured the following arguments for
-
Deprecation Warning
- Support
fdl.publish_events_log
andfdl.publish_parquet_s3
will soon be deprecated in favor offdl.publish_events_batch()
- Support
0.7.0
-
Dataset Refactor
- Datasets refactored to be members of a Project
- This is a change promoting Datasets to be first class within Fiddler. It will affects both the UI and several API in Fiddler
- Many API utilizing Projects will now require
project_id
passed as a parameter
- Datasets refactored to be members of a Project
-
New Features
- Added
fdl.update_model()
to client- update the specified model, with model binary and package.py from the specified model_dir
- Added
fdl.get_model()
to client- download the model binary, package.py and model.yaml to the given output dir.
- Added
fdl.publish_events_batch()
to client- Publishes a batch events object to Fiddler Service.
- Note: Support for other batch methods including
fdl.publish_events_log()
andfdl.publish_parquet_s3()
will be deprecated in the near future in favor offdl.publish_events_batch()
- Added
-
Changes
- Simplified logic within
fld.upload-dataset()
- Added client/server handshake for checking version compatibilities
- Warning issued in case of mismatch
- Deleted redundant APIs
fdl.create_surrogate_model()
fdl.upload_model_sklearn()
- Restructured APIs to be more duck typing-friendly (relaxing data type restrictions)
- Patches for minor bug-fixes
- Simplified logic within
0.6.18
-
Features
- Minor updates to ease use of binary classification labels
0.6.17
-
Features
- Added new arguments to
ModelInfo.from_dataset_info()
preferred_explanation_method
to express a preferred default explanation algorithm for a modelcustom_explanation_names
to support user-provided explanation algorithms which the user will implement on their model object via package.py.
- Added new arguments to
0.6.16
-
Features
- Minor improvements to
publish_events_log()
to circumvent datatype conversion issues
- Minor improvements to
0.6.15
-
Features
- Added strict name checks
0.6.14
-
Features
- Added client-native multithreading support for
publish_events_log()
using new parametersnum_threads
andbatch_size
- Added client-native multithreading support for
0.6.13
-
Features
- Added
fdl.generate_sample_events()
to client- API for generating monitoring traffic to test out Fiddler
- Added
fdl.trigger_pre_computation()
to client- Triggers various precomputation steps within the Fiddler service based on input parameters.
- Optionally add proxies to FiddlerApi() init
- Added
0.6.12
-
Features
- Added
fdl.publish_parquet_s3()
to client- Publishes parquet events file from S3 to Fiddler instance. Experimental and may be expanded in the future.
- Added
0.6.10
-
Features
- Added
fdl.register_model()
to client- Register a model in fiddler. This will generate a surrogate model, which can be replaced later with original model.
- Added
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
fiddler-client-1.0.0.tar.gz
(97.4 kB
view hashes)
Built Distribution
fiddler_client-1.0.0-py3-none-any.whl
(108.2 kB
view hashes)
Close
Hashes for fiddler_client-1.0.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 15022aad9afbdabffc6f2d8952b1695b9aa3ce9abbbc3358be1230d567c258d4 |
|
MD5 | 8720f017804b19a230fc2803f13b4f56 |
|
BLAKE2b-256 | 97f478ca3566f34243affa1e2992f924552eee7a3142db1b739cc9ec853fd41c |