Woo AI Helper

One of our AI-powered business automation projects:

WooCommerce plugin that automates content suggestions, FAQ generation, and product translations using LLM providers (OpenAI, Gemini)

Developed by MARKEYSS SIA for Apsardze24.lv.


AI Highlights

  • Multi-provider architecture — OpenAI and Google Gemini; interface-based design allows adding new providers
  • 3 AI tasks — product content suggestion, FAQ generation, translation
  • Two-part prompt system — structured system role + user instructions for each task
  • 17 dynamic placeholders — context injection system for rich prompts
  • Structured output prompting — JSON schema enforcement for validated LLM responses

Features

1. AI Content Suggestions

Get AI suggestions for missing product content:
  • Smart detection: Suggests only fields that are empty (title, description, short description)
  • One-click apply: Apply suggestions with undo option
  • Customizable length: Configure desired output length for each field

2. AI Product FAQs

Generate unique FAQ questions and answers for products:
  • AI-generated: Creates relevant Q&A based on product information
  • Customizable count: Generate 1-10 FAQs per product
  • Editable: Edit or delete individual FAQs via admin interface
  • Auto-translation: FAQs are automatically translated with the product
  • SEO optimized: Outputs JSON-LD structured data (FAQPage schema) for search engines

3. AI Product Translations

Automatically translate product content (title, description, short description) to other languages:
  • Manual translation: Select target languages in product edit screen and save
  • Automatic processing: Cron job processes pending translations every 5 minutes
  • Smart sync: When source product is updated, translations are automatically re-synced
  • Auto-creation: Creates translated product copy if it doesn’t exist
  • Content creation: Optionally generate missing descriptions if source product lacks them

AI Architecture

Multi-Provider Design

The plugin uses an interface-based architecture for easy switching between AI providers:
  • AiProviderInterface — contract defining generateContent() method
  • OpenAiProvider / GeminiProvider — concrete implementations
  • Factory pattern for runtime provider selection based on settings

Prompt System Overview

Each AI task uses a structured two-part prompt system (system role + user instructions):
Task Key Techniques
Translation Role-based context, HTML preservation, brand name handling, dynamic content generation for missing fields
FAQ Generation SEO optimization, store branding injection, deduplication via existing FAQ context
Content Suggestions Dynamic field detection, configurable output lengths
FAQ Translation Batch processing with structure preservation
Prompt system features:
  • 17 dynamic placeholder variables for context injection
  • JSON schema enforcement for structured responses
  • Customizable specifications via Admin UI
  • Variable chips for easy prompt editing

Production Features

  • Rate Limiting: Slot reservation queue preventing API throttling
  • Response Validation: Typed JSON schema validation per task
  • JSON Cleaning: Regex sanitization for LLM response variations
  • Error Handling: Graceful degradation with descriptive exceptions

Admin Interface

Settings Page

Configure all plugin options:
  • AI Provider: Choose between OpenAI or Google Gemini
  • API Keys: Enter your API credentials
  • Model Selection: Choose which AI model to use
  • Rate Limiting: Set timeout between AI requests (0-10 seconds)
  • Translation Settings: Source language, content length, custom prompts
  • FAQ Settings: Custom specification templates
  • Suggestion Settings: Field lengths and custom prompts

Translations Page

Monitor and manage translation jobs:
  • View translations in progress
  • View translations with errors
  • Retry failed translations
  • Clean up completed/orphaned entries

Product Edit Screen

  • Translation Meta Box: Select target languages for translation (appears on source language products)
  • FAQs Tab: Generate, edit, and delete product FAQs (in Product Data panel)
  • Content Suggestion Meta Box: Generate missing product content

Frontend Features

Product Page FAQ Tab

  • Displays as accordion on product pages (if FAQs exist)
  • Expandable/collapsible Q&A items
  • Clean, responsive design
  • Outputs SEO-friendly JSON-LD structured data

Technical Details

Requirements

  • WordPress
  • WooCommerce
  • Polylang (multilingual plugin)
  • OpenAI or Google Gemini API key

Database Tables

The plugin creates three custom tables:
  • wp_woo_ai_helper_options — Plugin settings
  • wp_woo_ai_helper_translations — Translation job queue and status
  • wp_woo_ai_helper_product_faqs — Generated FAQ data

Background Processing (Cron Jobs)

Job Schedule Description
Translation Processing Every 5 minutes Processes up to 5 pending translations per run
Database Cleanup Daily at 02:00 Removes completed and orphaned translation entries

Supported AI Providers

Provider Models
OpenAI gpt-4o, gpt-4o-mini, gpt-5.1, etc.
Google Gemini gemini-3-pro-preview, gemini-flash-latest, etc.

Developer Integration

External plugins can use these WordPress filters:
// Generate product content
apply_filters('woo_ai_helper_generate_content', $product_id);

// Create translation entries
apply_filters('woo_ai_helper_create_translations', $product_id, $languages);

// Translate single product
apply_filters('woo_ai_helper_translate_single_product', $product_id, $target_lang);

// Generate FAQs
apply_filters('woo_ai_helper_generate_product_faqs', $product_id, $count);

// Check feature status
apply_filters('woo_ai_helper_is_suggestions_enabled', false);
apply_filters('woo_ai_helper_is_faqs_enabled', false);