News for hackers. Stuff that matters.
Re:Ask HN: Why Try RAG on the Client Side? Is Local-First RA... by softwaredoug on Sunday January 26, 2025 @01:18PM (#42832353)
You can do pretty fast (single digit ms) cosine similarity on 1m vectors with numpy on the CPU. And there are small embedded databases like RocksDB with HNSW indices that work well beyond that. Especially staying at like 256 dims. Quantization can shrink even further.

Also locally you’re QPS is very low as you’re the only searcher.

So with enough RAM, and small enough dataset, it should be fine.

Re:Ask HN: Why Try RAG on the Client Side? Is Local-First RA... by MutedEstate45 on Monday January 27, 2025 @12:01AM (#42837586)
Thanks for your suggestions, especially RocksDB! I’m gonna play around with it today. Do you have any ideas related to use cases? I was thinking something like dynamic RAG for transformers.js