# Full Text Search

- Page: https://shared.btbytes.com/p/full-text-search
- Date: 2023-10-08
- Tags: full-text-search

## PostgreSQL

[pg_bm25: Elastic-Quality Full Text Search Inside Postgres - ParadeDB](https://docs.paradedb.com/blog/introducing_bm25)
> `pg_bm25` is named after BM25, the algorithm used by modern search engines to calculate the relevance scores of search results

>`pg_bm25` aims to bridge the gap between the native capabilities of Postgres’ full text search and those of a specialized search engine like ElasticSearch. The goal is to eliminate the need to bring a cumbersome service like ElasticSearch into the data stack.

> Built on top of Tantivy, a Rust-based alternative to the Apache Lucene search library

>Support for fuzzy search, aggregations, highlighting, and relevance tuning

> Relevance scoring uses BM25, the same algorithm used by ElasticSearch
> Real-time search — new data is immediately searchable without manual reindexing
