feat(search): weight subject above body in FTS vector #14

Merged
cesnimda merged 1 commits from feature/search-weighted-vector into develop 2026-07-01 21:29:39 +02:00
Owner

Slice 2 of search-core. The generated FTS vector now weights subject 'A' vs body 'B', so ts_rank_cd ranks subject matches above body-only mentions.

Includes an EF migration (drop/recreate the stored generated column + GIN index, transactional). Verified the migration DDL against the live staging Postgres (real schema + data, in a rolled-back transaction) before shipping, plus confirmed the weighting changes ranking (subject 1.0 vs body 0.4). Build + all 40 tests pass.

The api auto-applies migrations on boot; the post-deploy health gate will catch any issue.

🤖 Generated with Claude Code

Slice 2 of search-core. The generated FTS vector now weights subject 'A' vs body 'B', so ts_rank_cd ranks subject matches above body-only mentions. Includes an EF migration (drop/recreate the stored generated column + GIN index, transactional). **Verified the migration DDL against the live staging Postgres** (real schema + data, in a rolled-back transaction) before shipping, plus confirmed the weighting changes ranking (subject 1.0 vs body 0.4). Build + all 40 tests pass. The api auto-applies migrations on boot; the post-deploy health gate will catch any issue. 🤖 Generated with Claude Code
cesnimda added 1 commit 2026-07-01 21:25:00 +02:00
feat(search): weight subject above body in the FTS vector
CI / backend (pull_request) Successful in 1m16s
CI / frontend (pull_request) Successful in 27s
Security / secrets (pull_request) Successful in 5s
Security / dependencies (pull_request) Successful in 1m14s
9545f94461
Slice 2 of search-core: the generated SearchVector now applies setweight 'A' to
the subject and 'B' to the body, so ts_rank_cd (added last slice) ranks a subject
match above a body-only mention -- what users expect. Adds an EF migration that
drops/recreates the stored generated column + GIN index (Npgsql emits this
correctly and transactionally).

Verified: the migration DDL was dry-run against the live staging Postgres
(schema + real data) inside a rolled-back transaction -- applies cleanly; and the
weighted ranking (subject 1.0 vs body 0.4 for the same term) was confirmed
directly in Postgres. Build + all 40 tests pass.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
cesnimda merged commit fcf290a83b into develop 2026-07-01 21:29:39 +02:00
Sign in to join this conversation.
No Reviewers
No Label
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: cesnimda/Inboxintel#14