Skip to content
Welcome to the new era of Laravel. Today, Dec 1, at 10am PT / 1pm ET.Add it to your calendar

Getting Started

AI

AI: Getting Started

Introduction

Laravel offers first-party packages for building AI into your applications, whether you're adding a single AI feature to an existing application or building a standalone agent from scratch. Each package handles one part of the work, and you may use them on their own or together:

  • Laravel AI SDK provides a unified API for AI providers such as OpenAI, Anthropic, and Gemini. Use it to build agents and their tools, generate images, transcribe audio, create embeddings, and more.
  • Laravel Converse connects your agents to Slack, Telegram, GitHub, and web chat on your application's own pages.
  • Laravel MCP lets AI clients such as ChatGPT and Claude interact with your application, and lets your agents call tools on external MCP servers.
  • Laravel Boost gives coding agents such as Claude Code and Cursor Laravel guidelines, documentation, and tools so they write accurate Laravel code.

Where you start depends on whether you're adding AI to an existing application or building a new agent.

Adding AI to an Existing Application

Start with the AI SDK when you want to add AI to an existing Laravel application. It gives you everything you need to call models from your PHP code, whether you're summarizing documents, classifying support tickets, or answering questions against your own data.

When you want users to chat with your agents in Slack, Telegram, GitHub, or a chat widget on your own pages, add Laravel Converse. Converse is optional, so you may install it whenever you need chat integrations.

To let AI clients such as ChatGPT and Claude read your application's data or take actions for your users, add Laravel MCP. It lets you expose parts of your application as tools, resources, and prompts that MCP clients can call. It also works in the other direction: your agents can connect to external MCP servers, such as GitHub or Linear, and use the tools those servers provide.

Building a New Agent

If you're building a new agent, start with Agent Kit. Agent Kit is a Laravel starter kit that ships with the AI SDK, Converse, Laravel MCP, and Laravel Boost installed and wired together. Conversation memory, webhook routing, and queue processing are already configured, so you can create an application with one command and start writing your agent right away.

Agent Kit doesn't include a web frontend or user authentication. If you want users to chat with your agent on your application's own pages, start from one of Laravel's full-stack starter kits and add the AI SDK and Converse instead.