Serve Hugging face models with FastAPI, the Python's fastest REST API framework.

Radu Boncea cfe065cecb fixing payload to include model as param %!s(int64=2) %!d(string=hai) anos
assets 0f251447c2 initial commit %!s(int64=2) %!d(string=hai) anos
hfapi cfe065cecb fixing payload to include model as param %!s(int64=2) %!d(string=hai) anos
mlmodels 0f251447c2 initial commit %!s(int64=2) %!d(string=hai) anos
.gitignore 0f251447c2 initial commit %!s(int64=2) %!d(string=hai) anos
Dockerfile 0f251447c2 initial commit %!s(int64=2) %!d(string=hai) anos
Makefile 0f251447c2 initial commit %!s(int64=2) %!d(string=hai) anos
README.md eabecc0b63 small fix %!s(int64=2) %!d(string=hai) anos
docker-compose.yml 0f251447c2 initial commit %!s(int64=2) %!d(string=hai) anos
requirements.txt 0f251447c2 initial commit %!s(int64=2) %!d(string=hai) anos
setup.cfg 0f251447c2 initial commit %!s(int64=2) %!d(string=hai) anos
setup.py 0f251447c2 initial commit %!s(int64=2) %!d(string=hai) anos
tox.ini 0f251447c2 initial commit %!s(int64=2) %!d(string=hai) anos

README.md

ICI HuggingFace API via FastAPI

🤗 Huggingface + ⚡ FastAPI = ❤️ Awesomeness. Structure Deep Learning models serving REST API with FastAPI

Inspired by and bootstraped from https://github.com/Proteusiq/huggingfastapi/

hfapi

Serve Hugging face models with FastAPI, the Python's fastest REST API framework.

The minimalistic project structure for development and production.

Installation and setup instructions to run the development mode model and serve a local RESTful API endpoint.

Project structure

Files related to application are in the hfapi or tests directories. Application parts are:

hfapi
├── api              - Main API.
│   └── routes       - Web routes.
├── core             - Application configuration, startup events, logging.
├── models           - Pydantic models for api.
├── services         - NLP logics.
└── main.py          - FastAPI application creation and configuration.
│
tests                - Codes without tests is an illusion