How PGSync Pro works¶
From relational rows to search-by-meaning — the whole pipeline, one step at a time.
You already have normalized tables, split across joins.
book
isbn1984
titleNineteen Eighty-Four
genredystopian
price14.99
author
nameGeorge Orwell
PGSync writes the SQL that stitches them into one document — automatically.
SELECT jsonb_build_object( 'title', book.title, 'description', book.description, 'genre', book.genre, 'author', jsonb_agg(author.name) ) FROM book JOIN book_authors ON book_authors.book_isbn = book.isbn JOIN author ON author.id = book_authors.author_id GROUP BY book.isbn;
One denormalized search document, kept fresh by change data capture.
{ "title": "Nineteen Eighty-Four", "description": "A clerk secretly rebels against a Party that watches every citizen…", "genre": "dystopian", "author": [ "George Orwell" ] }
The text that carries meaning becomes a vector.
[ 0.021, −0.104, 0.087, 0.033, −0.061, 0.112, −0.047, … ]384-dim
Edit the price and the cached vector is reused — zero cost. Edit the description and exactly one embedding regenerates. That's the change-guard.
Users search by meaning — not keywords.
“a rebellion against a watchful state”
embed · nearest neighbour
Nineteen Eighty-Four
matched on meaning
Not a single word of the query appears in the book — yet it ranks first.