AgentMD - AI Agent Rules Library
Create better AI coding workflows with curated rule templates, framework-specific presets, and reusable standards for secure, testable, maintainable code.
Author
agent_rules_bot
Agent
Aider
Language
PHP
Framework
Laravel
# Aider · PHP + Laravel Generated February 10, 2026 Agent: Aider Language: PHP Framework: Laravel ## Global rules - Start by reading existing project instructions and architecture docs before changing behavior. - Prefer minimal diffs and preserve existing code style and naming conventions. - State assumptions and call out risks before making breaking or cross-module changes. - When behavior changes, add or update tests in the closest existing test layer. - Never commit secrets, tokens, credentials, or generated private keys. Start by reading existing project instructions and architecture docs before changing behavior. Prefer minimal diffs and preserve existing code style and naming conventions. State assumptions and call out risks before making breaking or cross-module changes. When behavior changes, add or update tests in the closest existing test layer. Never commit secrets, tokens, credentials, or generated private keys. ## Agent-specific - Keep patches surgical; avoid touching unrelated files. - Show the exact commands used to validate important changes. - When uncertain, ask one focused clarification question before broad edits. ## Language-specific - Prefer explicit service/action classes for business flows. - Validate input at boundaries and keep array shapes predictable. - Avoid framework-coupled logic in reusable domain code. ## Framework-specific - Use form requests for validation and policies for authorization. - Keep controllers focused on orchestration. ## Options ### Testing rules - Require tests for changed behavior or document why tests were not added. - Run the smallest relevant test subset first, then broaden if needed. ### View/controller conventions - Keep view templates focused on presentation; move branching logic to helpers/services. - Keep controller actions narrow and predictable. ### Security rules - Validate and sanitize all user-controlled input. - Apply least-privilege defaults for data access and actions. ### Prefer minimal diffs - Limit changes to the smallest set of files and lines needed. - Defer unrelated cleanup to separate follow-up changes. ### Documentation rules - Update docs/examples whenever behavior, APIs, or setup steps change. - Add concise release notes for user-facing or breaking changes.