Skip to main content
Archived

This project has been archived by its maintainers, and is no longer receiving any updates.

Build status Build Status Windows https://circleci.com/gh/sdpython/lightmlrestapi/tree/master.svg?style=svg https://badge.fury.io/py/lightmlrestapi.svg MIT License Requirements Status https://codecov.io/github/sdpython/lightmlrestapi/coverage.svg?branch=master GitHub Issues Notebook Coverage size

lightmlrestapi

It implements a light machine learning REST API based on falcon. If I were to start again this project, I would probably choose FastAPI. You can test a dummy wsgi server by running:

start_mlrestapi --name=dummy

And then query it with:

import requests
import ujson
features = ujson.dumps({'X': [0.1, 0.2]})
r = requests.post('http://127.0.0.1:8081', data=features)
print(r)
print(r.json())

It should return:

{'Y': [[0.4994216179, 0.4514893599, 0.0490890222]]}

The module was first tried with success in a hackathon in 2018. Participants could upload their model and retrieve their predictions through a REST API to check it was producing the same one as they had. A simple way to put a model into production.

History

current - 2021-01-01 - 0.00Mb

  • 23: Issue with ujson>=3.0, reject_bytes must be set to False (2020-06-06)

  • 21: Fix issue with non-serializable numpy array (ujson does not do it anymore) (2020-03-29)

0.2.151 - 2019-05-17 - 0.12Mb

  • 20: fix issue with falcon 2.0 (2019-05-08)

  • 17: reload module mapped to subfolder (2019-01-11)

  • 16: add full example to start a rest api (2018-12-01)

  • 9: add version number to REST API (2018-11-13)

  • 6: allow a zip file which contains data and code (2018-11-13)

  • 4: add authentification to the rest api (2018-11-13)

  • 8: allow clear logs (2018-11-02)

  • 5: add a load function (2018-11-02)

  • 3: add ip address in the logging (2018-04-15)

  • 2: add encrypted logging (2018-04-15)

  • 1: fix gallery of examples (style) (2018-01-05)

Metadata

Release files for lightmlrestapi 0.3.192

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Built distribution (wheel)

Table of built distributions (wheels) for lightmlrestapi 0.3.192
File Interpreter ABI Platform Actions
lightmlrestapi-0.3.192-py3-none-any.whl Python 3 none any Details for lightmlrestapi-0.3.192-py3-none-any.whl

Release files / lightmlrestapi-0.3.192-py3-none-any.whl

Download URL lightmlrestapi-0.3.192-py3-none-any.whl
Size 129.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
07f6630c1c63924ab5723332bbd0db1ffd72b2bfebe15ae79643490d8380b022
BLAKE2b-256 checksum
How to use checksums
9a61c9d37af490963f84edf0460332f40d0ca399a3a738f2c1b95fd880e4576c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.3.0 pkginfo/1.6.1 requests/2.25.1 setuptools/49.2.1 requests-toolbelt/0.9.1 tqdm/4.55.0 CPython/3.9.1

Security for lightmlrestapi 0.3.192

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page