pg_textsearch adds a bm25 index type and a <@> ranking operator to Postgres, so you can order query results by BM25 relevance directly in SQL. It's developed and maintained upstream by TigerData, not by EDB.
For syntax, index options, configuration settings, and examples, see the pg_textsearch documentation on GitHub.