/vector-db

Primary LanguagePython

Vector Database

Getting Vectors

Start by running the python vector server

	# cd python 
	# source venv/bin/activate
	# pip install -r requirements.txt
	# python app.py

This will start a server, please note that no models will of been cached. On the first request the model will be cached so will take some time.

Example request

# curl -XPOST -d '["test", "test"]' -H "Content-Type: application/json" http://127.0.0.1:5000/doc/embedding/msmarco-roberta-base-ance-fristp

Example response

[[0.9499503970146179,0.8039794564247131,0.022799743339419365,...],[0.9499503970146179,0.8039794564247131,0.022799743339419365,...]]

Setting up elasticsearch

Requires version 7.12+

Install elastiknn plugin from elastiknn.com # ./bin/elasticsearch-plugin install --batch https://github.com/alexklibisz/elastiknn/releases/download/7.12.0.0/elastiknn-7.12.0.0.zip