refactor: rombak cache AI analisis image — pakai CDN URL langsung, hapus phash+sha

- Cache key image = CDN URL (query params stripped), bukan SHA data URL
  → re-analysis SAME attachment selalu cache-hit, berbeda attachment tidak kolisi
- Hapus perceptual hash (imghash dep + phash get/upsert/compute) sepenuhnya
- Hapus makeImageCacheKey hashing, ganti makeImageCacheKey yang return CDN URL
- textCacheStore, visionAnalyzer, mediaCache, mediaAnalysisClient updated
- imghash dependency removed from package.json
- Purge 82 stale cache rows (image: + phash:) dari DB
This commit is contained in:
asepharyana
2026-08-12 22:31:08 +07:00
parent 37787cc4f0
commit d3cb5f6756
5 changed files with 24 additions and 123 deletions
@@ -6,7 +6,6 @@
*/
export {
acquireMediaAnalysisLock,
computeImagePhash,
deleteCachedMediaAnalysis,
getCachedMediaAnalysis,
setCachedMediaAnalysis,