Laravel Tackle brings an AI coding agent inside your Artisan commands

Computer screen displaying HTML code for a web development project

Laravel Tackle, built by Jordan Dalton, installs an AI coding agent directly into your Laravel application as a set of Artisan commands. Because it boots with the framework, it has native access to the tools you would use yourself: route listing, Telescope exception reading, SELECT queries against your database, and Pint formatting after edits are done.

️ What ships in the package

Tackle is not a single command. It ships seven distinct agents covering most of the workflow a solo Laravel dev touches day to day:

  • ai:code: an interactive REPL with plan mode, slash commands, image attachments, and persistent history between runs
  • ai:run: the same agent headless, with a single task, an exit code, and --output=json for pipeline use
  • ai:fix: a focused fix session started from a pasted exception, a Sentry issue ID, or a GitHub issue number
  • ai:review: reads a diff or pull request and posts inline review comments with severity levels
  • ai:upgrade: takes a Composer package across a major version using the package’s own upgrade guide from vendor/
  • Self-healer: watches for failed queue jobs and scheduled tasks, patches code in an isolated worktree, and opens a pull request
  • Tackle Remote: a companion package that serves the same agent harness as a mobile browser UI, with approval prompts
3D rendered ai text on dark digital background

Guardrails enforced in PHP, not prompts

The key architectural decision here is where the safety layer lives. Path restrictions, the Artisan allowlist, and the per-session spend limit are all defined in config/tackle.php as PHP code. A model cannot talk its way past them because they run before any tool executes, regardless of what is in the prompt.

A few defaults worth knowing:

  • Shell access on production defaults to off; worktree mode defaults to true on production
  • The budget hard-stops the session when estimated spend crosses AI_CODE_BUDGET (default 1.00 USD), with a warning at 80%
  • protected_paths blocks reads as well as writes, so .env and .env.* are never visible to the agent
  • Destructive Artisan commands (migrate:fresh, db:wipe) require terminal confirmation even when they appear in the allowlist

Self-healing queue jobs

Self-healing is off by default. Set AI_CODE_HEALING_ENABLED=true, publish the migration, and start a worker on the healer queue. From that point, a failed job fires Laravel’s JobFailed event, Tackle dispatches a HealJobFailure job to a dedicated queue, and a healing agent works against a fresh worktree on a tackle/heal-{id} branch.

The agent gets the exception class, message, stack trace, and the full Telescope entry when Telescope is installed. It applies a minimal fix, runs your test suite, then either opens a pull request or merges into your working branch and re-dispatches the original job. A failing test run falls back to opening a PR rather than merging, so nothing lands unverified. Set AI_CODE_HEALING_THRESHOLD=3 to hold off until a job has failed three times, giving transient failures room to resolve on their own.

Jobs you don’t want auto-patched get the #[Healable(false)] attribute. The listener checks by reflection before dispatching anything.

MCP server included

Running tackle:mcp serves the Laravel-aware tools over MCP on stdio, so Claude Code, Cursor, or Zed can call ListRoutes, QueryDatabase, ReadTelescopeEntry, and RunLarastan against your app from outside Tackle’s own agents. Path guards, the Artisan allowlist, and the SELECT-only database restriction all apply regardless of what calls the tools.

Stack and pricing

Tackle requires PHP 8.3 and Laravel 12 or 13. It’s built on laravel/ai and defaults to Claude, but AI_CODE_PROVIDER accepts OpenAI, Gemini, Groq, or a local model through Ollama. Running Ollama requires setting AI_CODE_PRICE_INPUT=0 and AI_CODE_PRICE_OUTPUT=0 because the built-in price catalog has no rate for local models.

The package is MIT-licensed and currently at v1.27.3. Source is on GitHub and full documentation lives at tackle.jordandalton.com.

Stay on top of AI & Automation with BizStack Newsletter
BizStack  —  Entrepreneur’s Business Stack
Logo