This anonymised case study describes an AI-powered back-office workflow for product copy and SEO-relevant content. The emphasis is controlled processing: content is not published automatically, but generated as a structured preview, validated, and prepared for deliberate approval.
Problem
Product data is often complete enough for shop operations but not consistent enough for clear, search-friendly descriptions. Manual editing does not scale, while uncontrolled mass generation risks tone, HTML quality, and data integrity.
The workflow therefore had to combine speed with explicit boundaries: process individual products with a reviewable preview, handle larger selections reliably in the background, and keep every change under human control.
Workflow
| Stage | Processing | Control |
|---|---|---|
| Context | Combine product data, language, existing copy, and editorial rules | Only defined fields and permitted data sources |
| Generation | Call the OpenAI Responses API with a structured response contract | Validatable JSON instead of free-form side effects |
| Preview | Display proposed changes for one product | Human review before acceptance |
| Bulk processing | Process selected products through background jobs | Job locks, employee binding, and live status |
| Persistence | Apply approved content in a controlled write | Permission checks, CSRF protection, and logging |
Structured outputs
The model response follows a fixed schema. Required fields, data types, and expected content areas are checked before presentation. This separates generation, validation, and persistence, preventing incomplete responses from entering product data directly.
Permitted HTML is limited through an allowlist and sanitised. Editorial formatting remains possible without accepting arbitrary markup or unsafe content.
Safe single and bulk processing
- Single-item preview for controlled quality review before persistence
- Bulk jobs for scalable processing without long-running back-office requests
- Job locks to prevent duplicate or competing processing
- Live status for progress, outcomes, and errors
- CSRF and permission checks for write operations
- Employee binding and traceable logging
- PHPUnit tests for core validation and workflow logic
Outcome
The workflow connects generative AI with an auditable editorial process. Product teams receive faster drafts and scalable processing, while preview, structured validation, security checks, and human approval retain control over published content.
What this case study demonstrates
- OpenAI Responses API and structured JSON outputs
- Human-in-the-loop product and SEO content
- Background jobs, job locks, and live status
- HTML sanitising, CSRF protection, and permission checks
- Testable, maintainable integration into an existing e-commerce back office
More AI and e-commerce projects
The project overview covers additional anonymised workflows, integrations, and full-stack contributions.
Project overviewAI engineeringPrestaShop profile