Live data from Hacker News

Long Read: Lessons from Building Semantic Search for GitHub and Why I Failed

tzx.notion.site

51–53 of 53 posts

Re: Long Read: Lessons from Building Semantic Search for GitHub and Why I Failed

#51
post #41
post #37

I was the first employee at a company which uses RAG (Halcyon), and I’ve been working through issues with various vector store providers for almost two years now. We’ve gone from tens of thousands to billions of embeddings in that timeframe - so I feel qualified to at least offer my opinion on the problem. I agree that starting with pgvector is wise. It’s the thing you already have (postgres), and it works pretty wel…

Thank you for the comment, compared to you I have only touched the bare surface of this quite complex domain, would love to get more of your input! > building HNSW indices in Postgres is still extremely slow (even with parallel index builds), so it is difficult to experiment with index hyperparameters at scale. Yes, I experienced this too. I from 1536 to 256 and did not try more values than I'd have liked because spi…

> Yes, I experienced this too. I from 1536 to 256 and did not try more values than I'd have liked because spinning up a new database and recreating the embeddings simply took too long. I’m glad it worked well enough for me, but without a quick way to experiment with these hyperparameters, who knows whether I’ve struck the tradeoff at the right place.

Yeah, this is totally a concern. You can mitigate this to some extent by testing on a representative sample of your dataset.

> Curious if you have any good solutions in this respect.

Most vector store providers have some facility to import data from object storage (e.g. s3) in bulk, so you can periodically export all your data from your primary data store, then have a process grab the exported data, transform it into the format your vector store wants, put it in object storage, and then kick off a bulk import.

> I realize they market heavily on this, but for open source databases, wouldn't the fact that you can see the source code make it easier to reason about this? or is your point that their implementation here are all custom and require much more specialized knowledge to evaluate effectively?

This is definitely a selling point for any open-source solution, but there are lots of dedicated vector store which are not open source and so it is hard to really know how their filtering algorithms perform at scale.

Re: Long Read: Lessons from Building Semantic Search for GitHub and Why I Failed

#52
post #37

I was the first employee at a company which uses RAG (Halcyon), and I’ve been working through issues with various vector store providers for almost two years now. We’ve gone from tens of thousands to billions of embeddings in that timeframe - so I feel qualified to at least offer my opinion on the problem. I agree that starting with pgvector is wise. It’s the thing you already have (postgres), and it works pretty wel…

What would you recommend for billions of embeddings?

We've used Pinecone for a while (and it definitely "just worked" up to a certain point), but we're now actively exploring Google's Vertex Search as a potential alternative if some of the pain points can't be mitigated.

Re: Long Read: Lessons from Building Semantic Search for GitHub and Why I Failed

#53
post #37

I was the first employee at a company which uses RAG (Halcyon), and I’ve been working through issues with various vector store providers for almost two years now. We’ve gone from tens of thousands to billions of embeddings in that timeframe - so I feel qualified to at least offer my opinion on the problem. I agree that starting with pgvector is wise. It’s the thing you already have (postgres), and it works pretty wel…

> Finally, building HNSW indices in Postgres is still extremely slow (even with parallel index builds), so it is difficult to experiment with index hyperparameters at scale For anyone coming across this without much experience here, for building these indexes in pgvector it makes a massive difference to increase your maintenance memory above the default. Either as a separate db like whakim mentioned, or for specific…

Thanks for sharing! Yes, getting good performance out of pgvector with even a trivial amount of data requires a bit of understanding of how Postgres works.
Post reply on HN