Add rich-text image description support to AI Automators
## Summary Add optional rich-text image description support to AI Automators for AI-based formatted text fields, including metadata storage for generated image descriptions. Related/source issue: https://git.drupalcode.org/project/ai_initiative/-/work_items/3585695 ## Problem AI Automators can use formatted text as input, but images embedded in that text are currently ignored unless they are already available through a separate image/media field. This makes automations less accurate for content that depends on visual context (for example: summaries, quality checks, and editorial pre-screening prompts). ## Proposed solution Add an advanced setting on AI-based formatted text automators: - Include image descriptions in output (checkbox) When enabled: - Parse formatted text for embedded images - Optionally include secure external image URLs - Generate short image descriptions using a vision-capable model - Append these descriptions to automator context - Store structured metadata in a configurable field (JSON payload) Suggested additional advanced settings: - metadata target field - include external images (default off) - max images to process - description prompt override Expected behavior: - Feature is opt-in (off by default) - Existing automators remain unchanged unless enabled - Metadata can be reused by downstream automations/workflows ## Affected modules / components - ai_automators (primary) - RuleBase / formatted text token generation - automator advanced configuration UI - helper/service for rich-text image extraction and metadata writing
issue