Who it is forA PHP or Laravel developer who lets an AI coding agent write most of the code and wants it to clean up its own mistakes.
The problemAgents repeatedly produce swallowed exceptions, queries inside loops and oversized methods, and code review catches them late.
The outcomeAfter each PHP edit the agent receives only the findings that edit introduced and fixes them before the developer reviews the change.
What you need first
- PHP 8.3 or newer
- Composer
- A PHP project with source roots listed in composer.json
- Git, for diff and review commands
Steps
- Run
composer require --dev heyosseus/sloppyin the project root. - Run
vendor/bin/sloppyto scan the project and confirm the output. - Run
vendor/bin/sloppy agents installto add the Claude Code hooks, orvendor/bin/sloppy agents install --host=geminiorvendor/bin/sloppy agents install --host=codexfor those agents. (inferred, check the README) - Ask the agent to make a small change to a PHP file and watch it run Sloppy after the edit.
Prompt for your agent
In the Heyosseus/sloppy project, install the agent hooks for this repository at <project path> by running the install command for the host agent. Then make a small edit to <target PHP file> that adds a try/catch block, and confirm the agent reports any new findings from that edit. Output the list of findings and whether the agent fixed them.
Caveat. Sloppy only reports pattern-based findings and does not judge whether the code is AI-generated, so a finding is a prompt to review the code, not proof of a defect.
Get 5 new use cases every morning. Free, one short email, unsubscribe anytime.
Get them freeShare: X LinkedIn Hacker News Email Copy link
Disclaimer
Deduped lists open-source repositories that belong to other people. We do not own, maintain, audit, or vouch for any of them, and a repo appearing here is not an endorsement or a safety check. The use cases, steps, and prompts are written by AI and may be incomplete, outdated, or just wrong. Where a use case is marked "Seen in the wild", we link to public posts where someone described something similar, but we have not verified those posts and the use case itself is still our AI's own write-up. Use all of this at your own risk. Only run code, commands, or agents on systems and accounts you are authorized to use, and read the code and every command before you run it, especially anything that touches credentials, files, or the network. Nothing here is professional, security, legal, or financial advice. All trademarks and project names belong to their respective owners, and their use here does not imply affiliation. Content is provided as is, without warranties of any kind. Found a mistake, a safety problem, or something you want removed? Email [email protected] and we will look at it promptly. Full disclaimer page