this repository contains a small web server with an API to calculate the similarity between a text and a list of texts. The server is build using FastApi and sentence-transformers librairie from huggingface.
NB: The Languages of the text should be English.
I build this to integrate it the This project.
- python >=3.6
- docker
Create a venv folder:
$ python3 -m venv venv
Activate the venv:
$ source venv/bin/activate
Install requirements:
$ pip install -r requirements.txt
Run the server:
$ uvicorn similarity.main:app --reload --host 0.0.0.0 --port 8002
The server shoul start on the port 8002 and the api documentation should available Hier.
Don't forget to deactivate the venv when you're done:
$ deactivate