mageprince / magento2-mage-ai

mageprince/magento2-mage-ai

Magento 2 Content Generator Extension

  • Mageprince
magento2-module Compatibility: Not yet tested Code Quality: Pending Tests: N/A Security: Pending GPL-3.0-or-later

Are you the maintainer of mageprince?

Packagento pulls mageprince's Composer packages from the public registry so buyers can find them here.

Claim the namespace to take ownership, publish new releases directly, and start charging for premium versions.

Claim this namespace →

Viewing version 1.0.3. Latest version is 1.1.1. Switch to latest

Magento 2 MageAI Extension

This Magento 2 extension integrates OpenAI (GPT), Anthropic (Claude), and Google Gemini to automatically generate high-quality short and long product descriptions — and AI-generated product images — based on product attributes like name, features, material, and more. It's a powerful tool to save time and improve content quality across your catalog.

❤️ The goal of this extension is to remain fully open-source and continuously expand by integrating every possible way to use AI with Magento 2. From writing content to helping customers, improving SEO, or automating tasks — the idea is to make Magento and AI work great together. I'm building it to be flexible and helpful for everyone, and I'd love for others to join in. If you're into Magento or AI, your ideas and contributions are always welcome. Let's create something awesome together!

Features

  • Multi-provider AI support — switch between OpenAI (GPT), Anthropic (Claude), and Google Gemini from a single config screen
  • AI product image generation — generate a product image from a prompt (or a configurable default) right from the Images And Videos section, added straight to the gallery (OpenAI & Gemini)
  • Generate product descriptions using a custom free-form prompt for full control and flexibility
  • Customize prompt templates using {{ product.name }} and {{ product.attributes }} variables
  • Select multiple product attributes to base generation on (name, material, features, etc.)
  • Configure max tokens and temperature separately for full and short descriptions
  • Works on both existing and unsaved (new) products
  • Supports OpenAI chat and completion endpoints (gpt-4o, gpt-4-turbo, gpt-4o-mini, gpt-3.5-turbo, etc.)
  • Supports Anthropic Messages API (claude-opus-4-5, claude-sonnet-4-6, claude-haiku-4-5, etc.)
  • Supports Google Gemini API (gemini-2.5-flash, gemini-2.5-pro, etc.)
  • Clean, valid HTML output ready to use in the WYSIWYG editor
  • Compatible with Page Builder

Supported AI Providers

Provider Models
Google Gemini (default) gemini-2.5-flash, gemini-2.5-pro, gemini-1.5-flash, gemini-1.5-pro
OpenAI (ChatGPT) gpt-4o, gpt-4o-mini, gpt-4-turbo, gpt-4, gpt-3.5-turbo
Anthropic (Claude) claude-opus-4-5, claude-sonnet-4-6, claude-haiku-4-5

Usage

  1. Go to Stores > Configuration > Mageprince > MageAI
  2. Choose your preferred AI Provider (Gemini, OpenAI, or Anthropic)
  3. Enter the API key for the selected provider
  4. Select the model and tune max tokens / temperature as needed
  5. Open any product (new or existing) and click "Generate with MageAI" in the Short / Long Description editor
  6. Watch the AI generate polished, HTML-ready content instantly
  7. Save the product

Custom Prompt

Click "Advanced Generate with MageAI" to open the custom prompt modal and type any free-form instruction — the module skips attribute lookup and sends your prompt directly to the AI.

Generate Product Image

Open a product and click "Generate Image with MageAI" next to the Add Video button in the Images And Videos section. Enter a prompt (or leave it empty to use the default configured prompt) and the generated image is added straight to the product gallery. Available with the OpenAI and Gemini providers.

Prompt Templates

Default prompts support two variables:

  • {{ product.name }} — the product's name
  • {{ product.attributes }} — a comma-separated Label: Value string from the attributes you selected in config

How to Install

Install via Composer

Run the following commands in your Magento 2 root folder:

composer require mageprince/magento2-mage-ai
php bin/magento setup:upgrade
php bin/magento setup:di:compile
php bin/magento setup:static-content:deploy

Contribution

Contributions are highly welcome and encouraged! 🙌

This project is a personal open-source effort to bring the power of AI to Magento 2. Whether you want to:

  • Add new features
  • Improve prompts or logic
  • Fix bugs
  • Help with translations or documentation
  • Or just share feedback…

You're very welcome to join in.

To contribute:

  1. Fork the repository
  2. Create your feature branch: git checkout -b feature/my-feature
  3. Commit your changes: git commit -m 'Add new feature'
  4. Push to the branch: git push origin feature/my-feature
  5. Create a new Pull Request

Screenshots

Generate Product Image

mageprince-mageai-image-generati

Generate Descriptions with Custom Prompt

mageprince-mageai-final

Generate Product Short Description

short-description

Generate Product Long Description With Page Builder

full-description-short

No changelog yet

The vendor hasn't published a changelog. Tagged releases appear in the Versions tab.

Versions
Version Stability QA Status Compatibility Released
1.1.1 stable Not tested Not yet tested Details 2026-06-10 06:54:56
1.1.0 stable Not tested Not yet tested Details 2026-06-09 04:49:16
1.0.3 stable Not tested Not yet tested Details 2026-06-04 06:10:44
1.0.2 stable Not tested Not yet tested Details 2026-06-02 10:13:59
1.0.1 stable Not tested Not yet tested Details 2025-05-05 14:50:10
1.0.0 stable Not tested Not yet tested Details 2025-04-07 05:40:00

No dependencies declared

This package's composer.json doesn't declare any required, suggested, replaced, or conflicting packages.

No QA results yet

QA pipelines haven't run for this version. Compatibility and quality results appear here once the vendor publishes a tagged release that gets ingested.

License
GPL-3.0-or-later
Authors

More from mageprince

View vendor
Make it pay

Turn an existing module into recurring revenue.

If you already maintain a Magento 2 module on GitHub or GitLab, listing it on Packagento takes about five minutes. We mirror your tags, handle distribution signing, and route paid licenses through Stripe Connect, so you can keep shipping the way you already do.