PHPackages                             gtstudio/module-ai-widgets - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Admin Panels](/categories/admin)
4. /
5. gtstudio/module-ai-widgets

ActiveMagento2-module[Admin Panels](/categories/admin)

gtstudio/module-ai-widgets
==========================

AI-powered admin widgets for Magento 2. Provides the floating chat assistant and PageBuilder content generation backed by Gtstudio\_AiAgents.

1.0.3(3mo ago)292BUSL-1.1JavaScriptPHP &gt;=8.1

Since Mar 9Pushed 2mo agoCompare

[ Source](https://github.com/gabrielgts/module-ai-widgets)[ Packagist](https://packagist.org/packages/gtstudio/module-ai-widgets)[ RSS](/packages/gtstudio-module-ai-widgets/feed)WikiDiscussions main Synced 3w ago

READMEChangelog (1)Dependencies (3)Versions (4)Used By (0)

Gtstudio\_AiWidgets
===================

[](#gtstudio_aiwidgets)

AI-powered admin widgets for Magento 2. Provides a floating chat assistant on every admin page and an AI content generator inside PageBuilder HTML blocks.

Preview
-------

[](#preview)

[![AiWidgets — floating chat assistant and PageBuilder AI content generation](docs/images/aiwidgets-preview.gif)](docs/images/aiwidgets-preview.gif)

AI Studio Ecosystem
-------------------

[](#ai-studio-ecosystem)

Part of the **AI Studio** suite for Magento 2. See all modules:

ModuleRepositoryDescription**Gtstudio\_AiConnector**[module-aiconnector](https://github.com/gabrielgts/module-aiconnector)Core AI provider abstraction**Gtstudio\_AiAgents**[module-ai-agents](https://github.com/gabrielgts/module-ai-agents)Agent &amp; tool orchestration, cron scheduling, execution log**Gtstudio\_AiWidgets***(this module)*Floating admin chat widget + PageBuilder AI generator**Gtstudio\_AiDataQuery**[module-ai-data-query](https://github.com/gabrielgts/module-ai-data-query)Natural-language store analytics (privacy-first)**Gtstudio\_AiKnowledgeBase**[module-ai-knowledge-base](https://github.com/gabrielgts/module-ai-knowledge-base)Document upload &amp; RAG retrieval for agents**Gtstudio\_AiDashboard**[module-ai-dashboard](https://github.com/gabrielgts/module-ai-dashboard)AI-powered KPI dashboard with ML insightsWhat It Does
------------

[](#what-it-does)

- **Floating Chat Widget** — a persistent chat panel in the Magento admin, powered by the `admin_assistant` agent
- **PageBuilder AI Generator** — an *AI Generate* button inside PageBuilder HTML blocks to create or rewrite content via the `page_builder_generator` agent
- Token and cost estimation displayed in real time for every message

Requirements
------------

[](#requirements)

- Magento 2.4.4+
- PHP 8.1+
- `Gtstudio_AiConnector` enabled and configured
- `Gtstudio_AiAgents` enabled
- `Magento_PageBuilder` (bundled with Adobe Commerce; available as OSS extension for Community)

Installation
------------

[](#installation)

```
composer require gtstudio/module-ai-widgets
php bin/magento module:enable Gtstudio_AiWidgets
php bin/magento setup:upgrade
```

Setup
-----

[](#setup)

### Admin Chat Assistant

[](#admin-chat-assistant)

1. Go to *AI Studio → Agents → Add New*
2. Set **Code** to `admin_assistant`
3. Fill in Background, Steps, and Output Instructions to define the assistant's persona
4. Save — the widget appears automatically for users with the `Gtstudio_AiWidgets::management` ACL resource

### PageBuilder Generator

[](#pagebuilder-generator)

1. Create an agent with code `page_builder_generator`
2. In PageBuilder, open any HTML block — an **AI Generate** button appears in the toolbar
3. Type a prompt and click Generate; the result is inserted into the block

Extensibility
-------------

[](#extensibility)

### Swapping the agent used by the chat widget

[](#swapping-the-agent-used-by-the-chat-widget)

The agent code is hardcoded as `admin_assistant` in `AdminChatService`. Override the service via DI preference to change this or add additional logic:

```

```

### Customising the chat widget template

[](#customising-the-chat-widget-template)

Override via standard Magento layout XML:

```

                    Vendor_Module::chat/custom-widget.phtml

```

The default templates are in:

```
view/adminhtml/templates/chat/widget.phtml
view/adminhtml/web/js/admin-chat.js

```

### Adding token pricing for a custom model

[](#adding-token-pricing-for-a-custom-model)

Extend `TokenCostService` via `di.xml` — see the `Gtstudio_AiConnector` README for the full pattern.

ACL Resources
-------------

[](#acl-resources)

ResourceControls`Gtstudio_AiWidgets::management`Access to all widget features and the chat API endpoint

###  Health Score

38

—

LowBetter than 83% of packages

Maintenance82

Actively maintained with recent releases

Popularity10

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity45

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~1 days

Total

3

Last Release

104d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/ab1f0030c21bebf4e87187df361e770ffaa2c0d3cdcd0cd45c77a79db5836156?d=identicon)[gtstudio](/maintainers/gtstudio)

---

Top Contributors

[![gabrielgts](https://avatars.githubusercontent.com/u/22245724?v=4)](https://github.com/gabrielgts "gabrielgts (1 commits)")

### Embed Badge

![Health badge](/badges/gtstudio-module-ai-widgets/health.svg)

```
[![Health](https://phpackages.com/badges/gtstudio-module-ai-widgets/health.svg)](https://phpackages.com/packages/gtstudio-module-ai-widgets)
```

###  Alternatives

[magepal/magento2-guest-to-customer

Quickly and easily convert existing guest checkout customers to registered customers.

68178.6k](/packages/magepal-magento2-guest-to-customer)[mage-os/theme-adminhtml-m137

M137 Admin Theme

36190.9k](/packages/mage-os-theme-adminhtml-m137)[smile/module-seller

Smile Retailer Suite - Seller Module

13539.8k4](/packages/smile-module-seller)[markshust/magento2-module-ordergrid

The Order Grid module adds more details to the order grid in the admin.

9186.1k](/packages/markshust-magento2-module-ordergrid)[mage-os/module-inventory-reservations-grid

Add a grid with the list of inventory reservations.

1512.6k](/packages/mage-os-module-inventory-reservations-grid)[loki/magento2-admin-components

Admin Panel grids and forms created via Loki Components

173.7k7](/packages/loki-magento2-admin-components)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
