14 comments

  • devy 33 minutes ago
    A couple preliminary findings if you are considering adopting this extension to replace your previous pgvector's HNSW indexing.

    - pg_vectorsearch uses a quantized IVF index called PRISM. PRISM caps at 1968 dimensions for vectors. If your previous HNSW index has more dimensions than that, you're SOL (at least for now until they fix that).

    - pg_vectorsearch requires Postgres version 18 or above. If you run PG versions below that you need to migrate your database first. Many legacy PG production environment are way dated on PG 14 or 15, migration is prohibitively high cost to just try this out.

    - pg_vectorsearch shipped yesterday and it's obviously alpha. Hasn't been battle tested in production environments outside of Timescale's. Also since it's so new, it isn't on Azure's allowed-extension list or any other Hyperscale's managed PG instances' allowed extension list. It takes time to graduate from alpha and mature. So if you run managaed PG instances from hyperscaler's cloud, you're SOL (at least for now until this matures into those ecosystems) or you have to migrate to a PG 18 self-hosted.

    • curious_cat_163 23 minutes ago
      I have used pgvector on an Azure DB. It did a "reasonable" job. I am not an expert on HNSW vs PRISM but because it is all backward compatible, I am curious why they didn't just send a PR to the pgvector folks?

      Like, I would love to learn more about the design process that led to a whole new thing. I am sure the decision was not taken lightly, but the README is very thin on the details for why anyone should go through the troubles above, at least in the making of it.

      • surister 11 minutes ago
        "Just sending a PR" is not that easy
  • EgregiousCube 1 hour ago
    I'm currently running VectorChord and I love it - with a fast backing disk, it's cut my postgres cost in half. Excited to see competition in low-RAM vector index tools. RAMageddon seems to be creating incentives to find more ways to take advantage of how fast modern nvme drives are!
    • enordstr 1 hour ago
      I am the main contributor of pg_vectorsearch. If you try both, let us know about your experience and how we can improve.
  • dmix 13 minutes ago
    I'm curious how it compares to `pg_search` https://www.paradedb.com/blog/introducing-search
    • thenoahhein 6 minutes ago
      unrelated! full-text search vs vector search, and this has a more permissive license.
  • ilumanty 37 minutes ago
    It would be so awesome if SQLite supported anything along these lines.
  • alexpadula 1 hour ago
    Dark side of the PRISM! The image on the repo 100% inspired by Dark Side of The Moon by Pink Floyd.
  • swe_dima 1 hour ago
    Sadly if cloud providers don't offer it on managed postgres then not many people can use it...
    • jascha_eng 1 hour ago
      Well you can always move to tiger cloud if you want it managed :) And this is PostgreSQL licensed just like our pg_textsearch which has been adopted to Googles AlloyDB and microsofts HorizonDB already, so there is hope!
  • Rapzid 2 hours ago
    Does it support filtering though?

    Edit: post filtering only

    I don't understand how people are efficiently implementing tenant/user/permission scopes with these indexes.

    • qeternity 52 minutes ago
      Partitioning is the easy bit I think, and falls out naturally from Postgres.

      But how are people doing recency biasing with vector databases?

      All of our approaches are either expensive or super hacky.

    • 3abiton 1 hour ago
      Checks notes, one dayabase per client, per user, per project ... etc
    • enordstr 1 hour ago
      Multi-column indexes for multi-tenant tables is planned for a future release.
    • esafak 1 hour ago
      LanceDB supports push down and list/array membership through DataFusion.
  • jakobedding 44 minutes ago
    How does this compare to pgvectorscale?
    • mfreed 20 minutes ago
      We're also the authors behind pgvectorscale. From our blog post:

      This isn’t the first vector index we’ve built and open-sourced for PostgreSQL. In 2024, Tiger Data released pgvectorscale, which used a graph-based indexing algorithm inspired by Microsoft’s DiskANN research. We deliberately chose a disk-optimized design so that indexes could scale beyond available RAM. Our initial benchmarks were promising, but as adoption grew and we tested against a wider variety of datasets, particularly low-dimensional ones, we encountered a troubling problem: portions of the graph could become unreachable, causing recall to degrade. We searched the literature for a principled solution but couldn’t find one, and the heuristics we tried worked on some datasets but not others.

      That’s a frustrating failure mode for a search index. When queries are slow, you can measure the problem and tune accordingly. But when recall degrades, you might not even notice until users start questioning the quality of their search results. And telling them to experiment with yet another set of tuning parameters isn’t the experience we want to provide.

      Meanwhile, partitioned-list approaches reminiscent of IVFFlat were getting a second life, as advances in compression and optimization addressed many of their old limitations. More importantly, they offered stronger guarantees than we could achieve by patching a graph-based index. We came to believe they were a better foundation, and decided to start over.

      With the introduction of pg_vectorsearch, we are shifting the majority of our vector-search development efforts to this new architecture. The existing pgvectorscale extension, which is stable and handling production workloads currently, will enter maintenance mode.

  • jascha_eng 2 hours ago
    from the accompanying blog post: https://www.tigerdata.com/blog/announcing-pg_vectorsearch-sc...

    > TLDR: We are launching pg_vectorsearch, a new open-source PostgreSQL extension that makes vector search dramatically faster and more cost-efficient. Its new PRISM index uses partitioning and compression instead of HNSW's graph-based approach, delivering faster queries with a fraction of the memory and significantly faster index builds. At 100 million vectors, PRISM achieved 6 ms query latency on a machine with 4× less memory than HNSW, with index builds over 20× faster.

    • jascha_eng 1 hour ago
      Btw, I do work for Tiger Data/timescale, but am not at all associated with this team. I just found this release really exciting.

      I sent the thread to Erik (the main contributor) though, so if you have feedback or questions, good chance that he'll see it.

  • esafak 1 hour ago
    Shouldn't you lead with your benchmarks if you're fast? qps and precision/recall, please.
  • arbor-group 27 minutes ago
    [flagged]
  • srameshonline 25 minutes ago
    [flagged]
  • hushpadapp 2 hours ago
    [flagged]