Reduce search timeout pressure on reverted baseline
build-push / docker (push) Successful in 4m22s

This commit is contained in:
GHStaK
2026-03-18 14:01:39 +09:00
parent f131cee6de
commit d3fb5e15e9
4 changed files with 82 additions and 7 deletions
+28
View File
@@ -624,6 +624,34 @@
- If behavior in the browser does not match the latest backend/frontend code, the first assumption should be stale frontend assets until proven otherwise
## Recent Change Log
- Date: `2026-03-18`
- What changed:
- Resumed and completed the interrupted search-timeout mitigation work that had been left locally after the rollback to `f131cee`.
- Split the search-service deadline into:
- collection deadline
- enrichment deadline with a reserved window
- Reduced collector fan-out on the reverted baseline:
- fewer base queries
- no per-request query shuffling
- earlier stop when a collector repeatedly returns `0` results before producing any accepted item
- Raised `Google Video` max results to `12` so visible count does not collapse as hard when Envato / Artgrid are cold.
- Added unit coverage for the search/enrichment deadline split helper.
- Why it changed:
- The user-provided log `ai-media-hub-2026-03-18T04-44-11-440Z.log` showed:
- repeated collector passes with many `rawCount: 0`
- `search_service:deadline_reached`
- `partialDueToDeadline: true`
- final warning `search returned partial results to avoid gateway timeout`
- only `Google Video` surviving into the final result set with `resultCount: 8`
- The real bottleneck in that log was collector-side time waste before enrichment/Gemini, not another Gemini output-format issue.
- How it was verified:
- PowerShell with repo-local tooling:
- `go test ./...`
- `node --check frontend/app.js`
- What is still risky or incomplete:
- This should reduce timeout pressure and improve visible count in the common “Envato/Artgrid zero streak” case, but upstream SearXNG quality can still dominate the final pool.
- A full app-boot smoke flow was not reintroduced into this reverted baseline in this turn.
- Date: `2026-03-17`
- What changed:
- Reverted commit `5ca7aef` (`Strengthen search breadth and modal fitting`) to restore the previous stable search/modal baseline.