News for hackers. Stuff that matters.
Re:Storing OpenAI embeddings in Postgres with pgvector by qigtyofhp on Tuesday February 07, 2023 @12:59AM (#34689275)
This will load the transformer models from Hugging Face (their models have a similar architecture to OpenAI embedding models): https://www.sbert.net/docs/pretrained_models.html

Redis has approximate nearest-neighbors vector similarity search: https://redis-py.readthedocs.io/en/stable/examples/search_ve...

Generate the embeddings on a rented GPU, push to Redis then do a similarity search. Store vectors in Redis using ndarray.tobytes()

There are no comments on this comment yet.