Alibi-Detect runtime for MLServer
Project description
Alibi-Detect runtime for MLServer
This package provides a MLServer runtime compatible with alibi-detect models.
Usage
You can install the mlserver-alibi-detect
runtime, alongside mlserver
, as:
pip install mlserver mlserver-alibi-detect
For further information on how to use MLServer with Alibi-Detect, you can check out this worked out example.
Content Types
If no content type is present on the request or metadata, the Alibi-Detect runtime will try to decode the payload as a NumPy Array. To avoid this, either send a different content type explicitly, or define the correct one as part of your model's metadata.
Settings
The Alibi Detect runtime exposes a couple setting flags which can be used to
customise how the runtime behaves.
These settings can be added under the parameters.extra
section of your
model-settings.json
file, e.g.
---
emphasize-lines: 6-8
---
{
"name": "drift-detector",
"implementation": "mlserver_alibi_detect.AlibiDetectRuntime",
"parameters": {
"uri": "./alibi-detect-artifact/",
"extra": {
"batch_size": 5
}
}
}
Reference
You can find the full reference of the accepted extra settings for the Alibi Detect runtime below:
.. autopydantic_settings:: mlserver_alibi_detect.runtime.AlibiDetectSettings
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
Built Distribution
Hashes for mlserver-alibi-detect-1.3.0.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 5c230910af32969cd3f78bc19a7e82ab2df3323e7fcb67b34f60b6815dcb1992 |
|
MD5 | 31a18c3db11a9f1e28a0cb064ccedb84 |
|
BLAKE2b-256 | 60d421c8727256a04f7b902ea44066d71a5cf64530660249cb136ab58cc17e7e |
Hashes for mlserver_alibi_detect-1.3.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 1ba93f6965c8a58ca2da6f31b190f885a856274c94a0ef605030d7d019367768 |
|
MD5 | 0fe0aed74d64d30d4c3113e8dd8fb27d |
|
BLAKE2b-256 | 1c8af43da1dc0a7c69930e025cf17fcb6557a9efd105a99ba90b697857a3eaaa |