Skip to content

Sponsor

What is Tackle?

Laravel Tackle is an AI agent harness for Laravel.

Tackle is the runtime layer that lets AI agents operate inside your Laravel application — reading code, executing tools, running tests, and taking action, with safety boundaries enforced at the framework level.

Think of it the way you think of Claude Code, Codex, or GitHub Copilot — but purpose-built for Laravel and installed directly into your app via Composer. The harness ships with a family of built-in agents and a full tool infrastructure you can extend or build on top of:

CommandWhat it does
ai:codeAn interactive coding agent that reads your codebase, edits files, runs tests, and formats code. Supports plan mode (approve a read-only plan before any edits), project-defined slash commands, and automatic context compaction for long sessions.
ai:runThe same agent with no terminal attached: one task, a JSON result, and an exit code — for CI and cron.
ai:fixA focused fix session: paste an exception, point it at a Sentry issue (--sentry=ID) or GitHub issue (--issue=N), and the agent diagnoses, patches, and verifies the fix. Runs in worktree mode by default.
ai:reviewA read-only agent that reviews git diffs and surfaces real issues with severity levels. Point it at a GitHub pull request (--pr=42 --comment) and it posts the findings as inline PR review comments.
ai:respondActs on a /tackle comment left on a pull request: applies the requested change, pushes it to the PR branch, and replies in the thread.
ai:explainExplains what a file, class, or method does in plain English.
ai:testGenerates a Pest test file for any class or method.
ai:onboardOnboards a new developer: a guided, read-only tour of the codebase — what it is, how it's put together, how to run it, where to be careful — then answers their questions. --write saves it as docs/ONBOARDING.md.
ai:evalBenchmarks the agent against seeded bugs — fix rate, false-fix rate, tokens, cost. Makes harness changes measurable.
ai:upgradeSafe major version upgrades for Composer dependencies — audit, plan, resolve, fix, verify — in an isolated worktree, delivered as a PR.
Self-healerAn autonomous agent that listens for failed jobs and scheduled tasks, diagnoses the exception, patches the code, and opens a PR or applies the fix.

Every agent runs through the same tool infrastructure and safety layer. You can add your own tools, write new agents, and swap the default agent entirely — all without forking the package. And the terminal isn't the only way to drive it: Tackle Remote puts the same harness in your phone's browser, approval prompts and all.

Built on top of laravel/ai — and provider-agnostic like it: Tackle runs on any provider laravel/ai supports with tool calling. Anthropic (Claude) is the default; OpenAI, Gemini, Groq, and fully local models via Ollama are two env vars away. See Models & Providers.

How the harness works

Tackle has three layers:

LayerWhat it is
ToolsAction primitives agents can call — ReadFile, EditFile, RunTests, RunShell, etc. Every tool goes through PathGuard and shell policy before executing.
AgentsClasses implementing CodingAgent that receive a prompt, call tools, and return a result. Tackle ships several; you can add your own.
SafetyPathGuard blocks reads/writes outside the workspace and protected paths. BudgetTracker aborts the session when estimated spend exceeds the limit. Shell modes gate command execution. All enforced in PHP — not advisory.

Living inside the booted application is the part an external tool cannot copy. The agent can ask the framework instead of inferring from files: the real columns and types off the live connection, relationships and casts by reflection, observers off the event dispatcher, the fully resolved middleware stack for a route. Tackle packages that as the application map — an index of your models in every session's system prompt, and the full shape of any one of them a single tool call away.

The self-healer adds a fourth piece: an event-driven runtime that spins up an agent autonomously in an isolated git worktree whenever a job or scheduled task fails. It is the same harness, running unattended.

The ecosystem

The core package is the harness. Around it:

  • Tackle Remote — a mobile-first browser UI for the same harness. Scan a QR code and your phone drives the agent.
  • Tackle Review — a GitHub Action that wraps ai:review, ai:respond, and ai:upgrade so every pull request gets reviewed with one workflow file.
  • Tackle Codex — an OpenAI Codex provider: run the agents on your ChatGPT subscription (usage records as $0) or an OpenAI API key.
  • Tackle Grok — an xAI Grok provider: run the agents on an xAI API key or your grok.com plan.
  • MCP servertackle:mcp serves Tackle's Laravel-aware tools to any MCP client (Claude Code, Cursor, Zed), with the same safety layer enforced.

Next steps

Released under the MIT License.