PHPackages                             dougkusanagi/laravel-ai-chat - 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. [Utility &amp; Helpers](/categories/utility)
4. /
5. dougkusanagi/laravel-ai-chat

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

dougkusanagi/laravel-ai-chat
============================

A Laravel AI Chat package with database integration

0.1.22(1y ago)143MITPHPPHP ^8.1

Since Nov 29Pushed 1y ago1 watchersCompare

[ Source](https://github.com/dougkusanagi/laravel-ai-chat-package)[ Packagist](https://packagist.org/packages/dougkusanagi/laravel-ai-chat)[ Docs](https://github.com/dougkusanagi/laravel-ai-chat)[ RSS](/packages/dougkusanagi-laravel-ai-chat/feed)WikiDiscussions master Synced today

READMEChangelogDependencies (2)Versions (20)Used By (0)

Laravel AI Chat
===============

[](#laravel-ai-chat)

[![Example](example.png)](example.png)

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

[](#installation)

```
composer require dougkusanagi/laravel-ai-chat
php artisan vendor:publish --tag=ai-chat-config
php artisan vendor:publish --tag=ai-chat-assets
php artisan vendor:publish --tag=ai-chat-views
```

Set your Gemini API key in your .env file:

```
GEMINI_API_KEY=your_api_key_here
```

Add to layout
-------------

[](#add-to-layout)

1. Add the required scripts to your layout file (`app.blade.php` or similar). Make sure to add them in this exact order:

```

```

2. Make sure you have Tailwind CSS installed and configured in your application.
3. The chat component will appear as a floating button in the bottom-right corner of your page.

Customization
-------------

[](#customization)

You can customize the views by publishing them:

```
php artisan vendor:publish --tag=ai-chat-views
```

The views will be published to `resources/views/vendor/ai-chat/components/`.

If you want to add ai-chat to filament php
------------------------------------------

[](#if-you-want-to-add-ai-chat-to-filament-php)

Add this following code to AdminPanelProvider.php

```
// Makes tailwind classes being compiled
->viteTheme('resources/css/app.css')
// Add assets
->assets([
    Js::make('ai-chat-js', asset('vendor/ai-chat/js/ai-chat.js')),
])
// Add blade components
->renderHook(
    PanelsRenderHook::BODY_END,
    function () {
        if (auth()->check()) {
            return view('vendor.ai-chat.components.ai-floating-chat');
        }
    }
)
```

Todo
----

[](#todo)

- Implement GeminiProvider
- Add the ability to execute constructive queries (create, update)
- Implement OpenAiProvider
- Implement AnthropicProvider

###  Health Score

28

—

LowBetter than 52% of packages

Maintenance41

Moderate activity, may be stable

Popularity9

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity47

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 ~5 days

Total

19

Last Release

495d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/4421025?v=4)[Douglas Lopes](/maintainers/dougkusanagi)[@dougkusanagi](https://github.com/dougkusanagi)

---

Top Contributors

[![dougkusanagi](https://avatars.githubusercontent.com/u/4421025?v=4)](https://github.com/dougkusanagi "dougkusanagi (44 commits)")

### Embed Badge

![Health badge](/badges/dougkusanagi-laravel-ai-chat/health.svg)

```
[![Health](https://phpackages.com/badges/dougkusanagi-laravel-ai-chat/health.svg)](https://phpackages.com/packages/dougkusanagi-laravel-ai-chat)
```

###  Alternatives

[illuminate/support

The Illuminate Support package.

630113.0M41.3k](/packages/illuminate-support)[psalm/plugin-laravel

Psalm plugin for Laravel

3355.3M346](/packages/psalm-plugin-laravel)[illuminate/collections

The Illuminate Collections package.

27078.0M1.1k](/packages/illuminate-collections)[illuminate/config

The Illuminate Config package.

10944.5M2.5k](/packages/illuminate-config)[illuminate/pagination

The Illuminate Pagination package.

12234.1M1.0k](/packages/illuminate-pagination)[illuminate/pipeline

The Illuminate Pipeline package.

9349.2M282](/packages/illuminate-pipeline)

PHPackages © 2026

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