The configuration/deployment files and codes are based on the official documentations of Jina. Here has more idea of CLIP. Please refer to them for up-to-date setup and information.
The goal of this project is to generate AI process and traffic in microservice deployment.
This repo have three sets of files:
- Containerized components of CLIP:
./Indexer
and./CLIPEncoder
- K8s config files generator:
gen_k8s_yaml.py
- User-side functions:
client.py
andflow_client.py
The deploying processes are:
- Build docker images
- Generate K8s config files
- Run microservice in K8s
- Fire client requests for benchmarking
It is recommended to use Python virtual environment, and then install the required packages by below command:
$ virtualenv -p python3 venv
$ . ./venv/bin/active
(venv) $ pip install jina
Uncomment/comment the part of components in the file gen_k8s_yaml.py
and run it directly.
(venv) $ python gen_k8e_yaml.py