Vector Databases

Is a Vector database possible on Replit? Or do I need to hook into Supabase?

1 Like

I do not know how to use vector databases.
However, I have found that neondb supports pgvector.
And it could actually be enabled in the Replit database.
Below is the result of enabling vecor from the tools shell.

~/workspace$ psql
psql (16.5, server 17.2)
WARNING: psql major version 16, server major version 17.
         Some psql features might not work.
SSL connection (protocol: TLSv1.3, cipher: TLS_AES_256_GCM_SHA384, compression: off)
Type "help" for help.

neondb=> CREATE EXTENSION vector;
CREATE EXTENSION
Quit (core dumped)
~/workspace$ 

Also, the following instructions for using pgvector with neon might help you.

3 Likes

The neondb postgres supports pgvector, Agent might be able to singleshot it if you provide docs/context but it’s not a specific tool for the Agent right now

I’ve been using Pinecone vector database with Voyage-2 and Voyage-3 embeddings. The biggest issues I’ve found is that Voyage-2 and Voyage-3 use a 1024 vector size. On the other hand, OpenAI likes vector sizes for 1536 and larger. Pinecone is considered the top vector database. And you can learn it for free. Voyage-3 requires a credit card. However, you 200 Million free tokens.
–Zachary

1 Like

pg vector defintly lets you do larger vectors than 1000. I think for a small use case postgres is fine.

1024 vs. 1536 is more of a cost-saving issue. Obviously, 1024 takes up less space in GPU memory. It doesn’t stop there you should also look at the embeddings. I have been using Voyage-3 Embeddings. However, I’ve switched to Voyage-3-large and added rerank-lite-1.

You always have a choice. I choose to use tools that I would probably use in production. I want to go as deep as possible on my chosen tech stack. Speed matters when money is on the line. And I don’t want to be learning how to use a new tool when costs count. I’d rather implement something new using tools I’m already comfortable using.