Hacker Newsnew | past | comments | ask | show | jobs | submit | jamesgresql's commentslogin

I have no affiliation with this product other than being a happy user, but man is it good for finding out exactly why and when your wifi is slow.

Best feature for me being was being able to detect intermittent jitter to my gateway. I never managed to catch this with speed-tests alone.


Ahhh no demo or trial. I want to support animals and dogs but I don't want to shell out $10 without giving it a try first.

Yeah I get that, I threw caution to the wind and did it (which I would normally never dO)

This is a no-nonsense walkthrough of doing hybrid search inside Postgres without spinning up a separate search service.

A few takeaway: - Postgres’s native `tsvector/ts_rank` stuff works ok for basic text matching, but it doesn’t account for global term frequency like BM25 does , so rankings can feel “flat” or noisy as soon as you go beyond simple queries (it's also slow). - Using a BM25 index (via extensions like `pg_search`) actually gives you relevance scores similar to what you’d expect out of modern search engines, and you can use stemmers/tokenization directly in SQL. BM25 is the star of this story. - Vector search fills in the semantic gaps (so “database optimization” isn’t limited to exact keywords), but you still don’t want to throw out lexical relevance. The trick is making it additive, not just adding scores together. - RRF (Reciprocal Rank Fusion) is a neat practical tool here. It sidesteps trying to normalize totally different scoring systems by just focusing on rank positions.

If you’re building anything where relevance matters (docs, product search, help articles) having BM25 + vector makes a big difference over vanilla FTS + embeddings alone. It also keeps everything in Postgres, which simplifies consistency/ops compared to an external search cluster.


I know it sounds obvious, but some people are pretty determined to us it that way!


Hey HN! Author here. We added faceted search capabilities to our `pg_search` extension for Postgres, which is built on Tantivy (Rust's answer to Lucene). This brings Elasticsearch-style faceting directly into Postgres with a 14x performance improvement over a CTE based approach by performing facet aggregations in a single BM25 index pass and making use of our columnar store.

You get the same faceting features you'd expect from a dedicated search engine while maintaining full ACID compliance. Happy to answer technical questions about the implementation!


Hi, tantivy dev here. There are two recent performance improvements in tantivy, which should make term aggregations considerable faster.

https://github.com/quickwit-oss/tantivy/pull/2740 https://github.com/quickwit-oss/tantivy/pull/2759


Yes, thank you for your hard work! We rebased recently, and we'll likely talk about those improvements as part of our `0.21.x` release.


Haha, I like “good old tokenization”


Amazing, will have a read!


Chinese, Japanese, Korean etc.. don’t work like this either.

However, even though the approach is “old fashioned” it’s still widely used for English. I’m not sure there is a universal approach that semantic search could use that would be both fast and accurate?

At the end of the day people choose a tokenizer that matches their language.

I will update the article to make all this clearer though!


100%, maybe we should do a follow up on other types of tokenization.


Hello HN, author here. It seems like everyone is talking about 'hybrid search' (lexical/BM25 + semantic/vector) these days, so I wanted to show how it's possible (and fully customizable) using reciprocal rank fusion in SQL.


The original title of this post was "When Tokenization Becomes Token", but nobody got it.

I'm curious, after reading this article how many people can tell me why that title would have been great?

(also I'd love feedback on the interactive components, I think they came out well!)


hello. it would be great because it celebrates the total destruction of the search capabilities of the tool, just like the article does.


Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: