Add GIPHY image search feature

This commit is contained in:
GHStaK
2026-03-24 16:02:49 +09:00
parent 494a54fa46
commit d63c467ef9
13 changed files with 1385 additions and 84 deletions
+23
View File
@@ -268,6 +268,22 @@
- backend debug broadcasts
## Recent Change Log
- Date: `2026-03-24`
- What changed:
- Replaced the earlier frontend-only image prototype with an integrated GIPHY image/GIF search flow.
- Added backend GIPHY search aggregation with dedupe, up to `100` results, secure download handling, and Gemini-driven multilingual image query expansion into exactly `5` English queries.
- Reused the existing result modal for enlarged GIPHY preview and download actions, and added an internal-scroll image results panel with visible `Powered by GIPHY` attribution.
- Updated startup config and Unraid template fields for `GIPHY_ENABLED`, `GIPHY_API_KEY`, `GIPHY_MAX_RESULTS`, `GIPHY_RATING`, `GIPHY_LANG`, `GIPHY_DOWNLOAD_DIR`, and `GEMINI_MODEL`.
- Added backend tests covering Gemini image-expansion parsing/fallback, GIPHY aggregation/cap behavior, download validation, and handler-level API paths.
- Why it changed:
- The app needed a production-usable image/GIF provider added incrementally without breaking the existing video search experience.
- How it was verified:
- `node --check frontend/app.js`
- static code review of backend/frontend wiring and new test coverage
- What is still risky or incomplete:
- This environment currently does not expose `go` or `gofmt`, so Go formatting and `go test ./...` could not be rerun locally in this turn even though new tests were added.
- Live browser QA and real GIPHY credential validation still need to be performed in a runtime environment with working API keys.
- Date: `2026-03-24`
- What changed:
- Added a working-rule note that git push authentication for this repository should be retried with the local credential file `.local/git-credentials.psd1` before leaving work in a local-only state.
@@ -460,6 +476,13 @@
- `SEARXNG_GOOGLE_VIDEO_ENGINE`
- `SEARXNG_WEB_ENGINE`
- `GEMINI_API_KEY`
- `GEMINI_MODEL`
- `GIPHY_ENABLED`
- `GIPHY_API_KEY`
- `GIPHY_MAX_RESULTS`
- `GIPHY_RATING`
- `GIPHY_LANG`
- `GIPHY_DOWNLOAD_DIR`
## Local Development Environment Notes
- This machine started without `go`, `pip`, `ffmpeg`, `yt-dlp`, or `node`.