Cache embedding lookups

Created on 16 October 2025, 5 days ago

Problem/Motivation

Particularly with AI Search, now that hybrid search is getting more popular, changes to exposed filters trigger regeneration of embeddings. As done in Store resulting embedding from AI into local k/v for later lookup Active , the wider AI Search can benefit from this.

Proposed resolution

Use a persistent cache that does not get cleared on cache rebuild (but still expires and gets cleared on cron cleanup after expiry

Remaining tasks

  1. Make the expiry configurable?
  2. Document how to clear it (i.e., drush cache:clear ai_embeddings)
  3. Create follow-ups in the various AI Providers that support embeddings to have them opt-in to this

Optional: Other details as applicable (e.g., User interface changes, API changes, Data model changes)

Since the method won't exist, should be 2.x + AI Providers should be 2.x constraint (or we do method_exists call in providers?)

Feature request
Status

Active

Version

2.0

Component

AI Search

Created by

🇬🇧United Kingdom scott_euser

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.71.5 2024