Skip to main content
drupalreleases
Release: Cms 2.2.3 — Update released for Drupal core (2.2.3)! Release: Easy Breadcrumb 2.0.11 — Minor update available for module easy_breadcrumb (2.0.11). Release: Bootstrap 8.x-3.42 — Minor update available for theme bootstrap (8.x-3.42). Release: Editoria11y Accessibility Checker 3.0.10 — Minor update available for module editoria11y (3.0.10). Release: Editoria11y Accessibility Checker 2.2.24 — Minor update available for module editoria11y (2.2.24). Release: Leaflet 10.4.13 — Minor update available for module leaflet (10.4.13). Release: Flag 5.1.1 — Minor update available for module flag (5.1.1). Release: Layout Paragraphs 3.0.0-beta5 — New beta version released for module layout_paragraphs (3.0.0-beta5). Module Revived: Bootstrap 8.x-3.41 — Theme bootstrap updated after 6 months of inactivity (8.x-3.41). Security Coverage: Component Library — Module component_library now has official Drupal security advisory coverage.

AI Semantic Expansion

No security coverage

Part of the AI ecosystem · 340 projects

View on drupal.org

This module enhances Search API search results by adding AI-generated synonyms and search intent phrases. It processes content in the background, stores the AI-generated text in a local cache, and then injects it into your search index without needing a vector database. This allows for more intelligent semantic search directly from your standard relational database.

The AI Semantic Expansion module enriches your Search API indexes with AI-generated synonyms and search intent phrases, enabling semantic search on standard relational databases (MySQL, MariaDB, PostgreSQL) — no vector database required.

When a node is saved, the module queues it for processing. A background queue worker sends the node's content to your configured LLM provider (via the Drupal AI module) and stores the generated synonym text in a local cache table. During Search API indexing, the processor injects that cached text into a virtual field (ai_semantic_synonyms), which can be mapped and boosted like any other fulltext field.

Key features

  • Zero live HTTP calls during indexing. All AI generation happens in the background queue worker; the Search API processor only reads from the local cache.
  • Hash-based deduplication. The cache row is only regenerated when the source content actually changes, preventing redundant API calls.
  • Provider-agnostic. Works with any chat-capable provider configured in the Drupal AI module (OpenAI, Anthropic, Ollama, and others).
  • Configurable per index. Source fields, character limit, system prompt, and AI provider are all set on the Search API processor configuration form.
  • Bulk pre-warm command. Run drush ai-expand:batch to pre-populate the cache for all existing nodes before the first indexing run.
  • Cache management. A “Flush AI cache” button on the processor form lets administrators clear and regenerate all entries. Changing the LLM prompt automatically invalidates the cache and notifies administrators to re-run the batch command.

Requirements

  • Drupal 10.4 or 11
  • Drupal AI module with at least one chat-capable provider configured
  • Search API module with an active index

Installation

  1. Enable the module: drush en ai_semantic_expansion
  2. Run database updates: drush updb
  3. Go to your Search API index → Processors and enable AI Semantic Expansion.
  4. Go to Fields and add the AI Semantic Synonyms virtual field; set its type to Fulltext and apply a boost weight.
  5. Pre-warm the cache for existing content: drush ai-expand:batch
  6. Re-index: drush search-api-index

Depends on

Dependencies of the latest stable release

No dependencies recorded for this project.

Required by

Tracked projects that depend on this one

No tracked projects depend on this one yet.

Activity

Tracked releases
4
Tracked since
May 2026
Latest release
4 months ago
Releases (12 mo)
4 ▲ from 0
Maintenance
Active

Release Timeline

Releases

Version Type Core Release date
1.0.0-alpha3 Pre-release 10–11 May 19, 2026
1.0.0-alpha2 Pre-release 10–11 May 19, 2026
1.x-dev Dev 10–11 May 19, 2026
1.0.0-alpha1 Pre-release 10–11 May 19, 2026