Skip to content

Releases: jonaspauleta/scout-postgres

v1.0.0 — first stable release

25 Apr 17:27

Choose a tag to compare

First public stable release of jonaspauleta/scout-postgres — a Postgres-native Laravel Scout engine backed by tsvector FTS + pg_trgm trigram similarity.

Highlights

  • Adaptive query strategy (default) — FTS-only first, hybrid FTS + trigram fallback only when recall is insufficient. Cuts trigram cost on common queries while preserving typo recovery.
  • Short-prefix fast path — single short tokens skip websearch_to_tsquery and the trigram pass; only to_tsquery(:prefix:*) runs. Dominant win for as-you-type UIs.
  • total_count=false by default — drops COUNT(*) OVER() so latency scales with page size, not match-set size. Per-query opt-in for paginators that need exact totals.
  • JIT off per querySET LOCAL jit = off removes 10–30 ms compile cost on FTS queries that complete in single-digit ms.
  • STORED GENERATED columns + GIN indexessearch_vector (tsvector) and search_text (capped at 1000 chars by default for bounded trigram cost). No external index, no sync queue.
  • Per-model overrides via the PostgresSearchable contract.
  • Scout-native APIsearch(), where(), whereIn(), whereNotIn(), orderBy(), paginate(), cursor(), soft deletes.

Compatibility

  • PHP 8.3 / 8.4 / 8.5
  • Laravel 11 / 12 / 13
  • Laravel Scout 10 / 11
  • Postgres 14+ (CI-tested on Postgres 18) with pg_trgm ≥ 1.6 and unaccent ≥ 1.1.

See CHANGELOG.md, README.md, and benchmarks/ for full detail.

Install

composer require jonaspauleta/scout-postgres
php artisan migrate

Set SCOUT_DRIVER=pgsql and SCOUT_QUEUE=false in .env.