A cloud function to invoke a prediction against a machine learning model that has been trained outside of a cloud provider, using tools like MLFlow. This repository will not contain the model artifact output, but the code for the cloud function.
FastAPI will be used for the cloud function as it offers many features e.g. authentication, body validation etc. and overall easy to use and maintain.
- External to GCP model training is performed and model artifact output,
- User makes a request to a HTTP endpoint for a prediction,
- Model artifact is stored within a bucket, when function is invoked -- model is downloaded,
- Prediction is output via a HTTP response.
- How to serve deep learning models using TensorFlow 2.0 with Cloud Functions by Rustem Feyzkhanov