semvec/pypi-packages huggingface dataset:
yummy-mlflow 0.0.9
Yummy mlflow rust model server
License: Apache-2.0
Requires Python: >=3.7

# Yummy-[MLflow](https://www.mlflow.org/) rust addons

This repository contains Yummy mlflow addon written in Rust.

## Yummy mlflow

The MLflow rust wrapper currently supports models:
[x] lightgbm
[x] catboost (only binary classification)

The implementation currently supports MLflow models kept on local path.
To run the model run:

`yummy_mlflow.model_serve(MODEL_PATH, HOST, POST, LOG_LEVEL)`

example:
```python
import yummy_mlflow

yummy_mlflow.model_serve(model_path, '0.0.0.0', 8080, 'error')
```

The `yummy-mlflow` will expose HTTP server. 
The request response is compatible with MLflow model serving API.

Example:

Request:
```
curl -X POST "http://test1:8080/invocations" \
-H "Content-Type: application/json" \
-d '{
    "columns": ["0","1","2","3","4","5","6","7","8","9","10",
               "11","12"],
    "data": [
     [ 0.913333, -0.598156, -0.425909, -0.929365,  1.281985,
       0.488531,  0.874184, -1.223610,  0.050988,  0.342557,
      -0.164303,  0.830961,  0.997086,
    ]]
}'
```

Response:
```
[[0.9849612333276241, 0.008531186707393178, 0.006507579964982725]]
```
yummy-features 0.0.9
Yummy feature store server
License: Apache-2.0
Requires Python: >=3.7

# Yummy rust addons

This repository contains Yummy addons written in Rust.

## Feature server

Rust feature server have been implemented using [Actix](https://actix.rs/) server.
The server is fully compatible with Feast.
Thus you can use it with the features materialized with Feast to online store.
Currently `Redis/RedisCluster` online store implementation is available.
Additionaly only http protocol is supported.

The payload is fully compatible with Feast server:

### Example request/response:

Request with features list:
```json
{          
  "features": [
                "driver_hourly_stats:conv_rate",
                "driver_hourly_stats:acc_rate",
                "driver_hourly_stats:avg_daily_trips",                      
            ],
  "entities": {"driver_id": [1001,1002,1003,1004,1005]},
  "full_feature_names": true,
}
```

Request with [feature service](https://docs.feast.dev/getting-started/concepts/feature-retrieval#feature-services):
```json
{
  "feature_service": "driver_activity_basic",
  "entities": {"driver_id": [1001,1002,1003,1004,1005]},
  "full_feature_names": true,
}
```

Example response:
```json
{"metadata": {"feature_names": ["driver_id",
   "driver_hourly_stats__conv_rate",
   "driver_hourly_stats__acc_rate",
   "driver_hourly_stats__avg_daily_trips"]},
 "results": [{"values": [1001, 1002, 1003, 1004, 1005],
   "statuses": ["PRESENT", "PRESENT", "PRESENT", "PRESENT", "PRESENT"],
   "event_timestamps": ["2022-10-04T22:46:16",
    "2022-10-04T22:46:16",
    "2022-10-04T22:46:16",
    "2022-10-04T22:46:16",
    "2022-10-04T22:46:16"]},
  {"values": [0.44467267, null, 0.775576, 0.719485, null],
   "statuses": ["PRESENT", "PRESENT", "PRESENT", "PRESENT", "PRESENT"],
   "event_timestamps": ["2022-10-04T22:46:16",
    "2022-10-04T22:46:16",
    "2022-10-04T22:46:16",
    "2022-10-04T22:46:16",
    "2022-10-04T22:46:16"]},
  {"values": [0.36920926, null, 0.8855987, 0.09924329, null],
   "statuses": ["PRESENT", "PRESENT", "PRESENT", "PRESENT", "PRESENT"],
   "event_timestamps": ["2022-10-04T22:46:16",
    "2022-10-04T22:46:16",
    "2022-10-04T22:46:16",
    "2022-10-04T22:46:16",
    "2022-10-04T22:46:16"]},
  {"values": [821, null, 381, 587, null],
   "statuses": ["PRESENT", "PRESENT", "PRESENT", "PRESENT", "PRESENT"],
   "event_timestamps": ["2022-10-04T22:46:16",
    "2022-10-04T22:46:16",
    "2022-10-04T22:46:16",
    "2022-10-04T22:46:16",
    "2022-10-04T22:46:16"]}]}
```


## Protos

[Feast](https://github.com/feast-dev/feast) protobuf definitions ([License](https://github.com/feast-dev/feast/blob/master/LICENSE)) have been used in the project.

Protobuf rust implementation have been used to generate rust code:
```bash
protoc --rust_out . $(find . -iname "*.proto")
```