laravel:specifying-constraints
Define clear constraints—performance, security, testing, architecture, dependencies—so AI generates code that meets your project standards
Skill by jpcaparas
Install
Works with Claude Code, Claude apps, Codex, Cursor, Gemini CLI, GitHub Copilot, VS Code, OpenCode, Goose, Windsurf. Read the repository before you give any tool access to your data.
npx agentmarket install skill/jpcaparas-laravel-specifying-constraints
Asks which of your tools to add it to (Claude Code, Codex, Cursor, VS Code, Windsurf, Gemini CLI, Claude Desktop) and shows the change first. See https://agentmart.dev/cli.
Get the weekly diff
The weekly diff: one email a week with new agent tools, notable updates and grade changes, plus security alerts for tools you follow. Double opt-in, one-click unsubscribe.
About
Use cases: testing, security
Reviews
Write a reviewNo reviews yet. Installed it? Reviews come from verified installers only. How reviews work
Permissions
What this skill can do and what it asks for, from its SKILL.md. Checked Oct 25, 2026.
- Tools
- No tools found
- Secrets
- None asked for
- Install scripts
- None found
Network hosts it talks to 1
codeload.github.com· found in install command
Files it touches
~/.claude/skills/laravel-specifying-constraints
What's inside
- Skill name
laravel:specifying-constraints- Description
- Define clear constraints—performance, security, testing, architecture, dependencies—so AI generates code that meets your project standards
- License
- MIT
- Instructions
- 160 lines in SKILL.md · view on GitHub
Agent Skills spec issues
- name: only lowercase letters, digits and single hyphens allowed
- name: "laravel:specifying-constraints" does not match folder "specifying-constraints"
Files (1)
- SKILL.md
SKILL.md (first lines)
# Specifying Constraints Constraints guide the AI toward solutions that fit your project. Without them, you get generic code that may not meet your requirements. ## Performance Constraints ### Vague "Make it fast" ### Specific "Optimize product search: - Response time < 200ms for 95th percentile - Support 1000 concurrent users - Cache results for 5 minutes using Redis - Use database indexes on `name`, `category_id`, `published_at` - Paginate results, max 50 per page - Avoid N+1 queries with eager loading" ### Database Performance "Query orders with performance constraints: - Use `select()` to load only needed columns - Eager load `items`, `customer`, `shipping_address` in one query - Add composite index on `(user_id, created_at, status)` - Use `chunk()` for batch processing > 1000 records - Set query timeout to 5 seconds" ## Security Constraints ### Vague "Make it secure" ### Specific "Implement user profile update with security requirements: - Authorize using `ProfilePolicy@update` - Validate all inputs in `ProfileUpdateRequest` - Sanitize HTML in bio field (strip scripts, allow basic formatting) - Rate limit to 10 requests per minute per user - Hash passwords with bcrypt (cost factor 12) - Log all profile changes for audit trail - Prevent mass assignment vulnerabilities with `$fillable`" ### API Security "Secure the payment API: - Require `auth:sanctum` middleware - Validate API tokens have `process-payments` ability - Use HTTPS only (enforce in middleware) - Validate webhook signatures from payment provider - Store sensitive data encrypted in database - Never log credit card numbers or tokens - Return generic error messages (don't leak system details)" ## Testing Constraints ### Vague "Add tests" ### Specific "Test the order processing feature: - Feature test for complete order flow (create → process → confirm) - Unit tests for OrderService methods - Test validation failures (invalid payment, insufficient inventory) - Test edge cases (zero quantity, negative prices) - Mock external payment gateway - Use factories for test data - Aim for 80% code coverage on business logic - Tests must run in < 30 seconds" ### Test Requirements "Testing requirements for authentication: - Test successful login with valid credentials - Test failed login with invalid credentials - Test rate limiting (max 5 attempts per minute) - Test token expiration after 24 hours - Test logout invalidates token - Use `RefreshDatabase` trait - No external API calls in tests (use mocks)" ## Architectural Constraints ### Patterns to Follow "Implement payment processing following our architecture: - Use repository pattern: `PaymentRepository` for data access - Use service layer: `PaymentService` for business logic - Use jobs for async work: `ProcessPaymentJob` - Use events: `PaymentProcessed`, `PaymentFailed` - Controllers orchestrate only, no business logic - Keep cyclomatic complexity < 7 per method - Follow SOLID principles" ### Patterns to Avoid "Implement user management with these constraints: - Don't use static methods or facades in business logic - Don't put business logic in controllers or models - Don't use global state or singletons - Don't mix concerns (separate validation, business logic, persistence) - Don't use raw SQL queries (use Eloquent or Query Builder) - Don't bypass authorization checks" ## Dependency Constraints ### Version Requirements "Add image processing feature: - Use `intervention/image` ^3.0 (Laravel 13.x compatible) - Requires PHP 8.2+ - Requires GD or Imagick extension - Compatible with our existing `spatie/laravel-medialibrary` ^11.0 - No conflicts with current dependencies" ### Package Selection "Choose a package for PDF generation: - Must support Laravel 13.x - Must handle UTF-8 and special characters - Should support headers/footers - Prefer actively maintained (updated in last 6 months) - Check compatibility with our PHP 8.2 requirement - Consider: `barryvdh/laravel-dompdf` or `spatie/laravel-pdf`" ## Constraint Templates
From jpcaparas/superpowers-laravel, MIT.
More from jpcaparas/superpowers-laravel
- 0.597score
laravel:performance-caching
jpcaparas
Use framework caches and value/query caching to reduce work; add tags, locks, and explicit invalidation strategies for correctness
SkillCFreshness: C★ 157Claude Code +9 - 0.597score
laravel:php-attributes
jpcaparas
Use first-party PHP attributes (Laravel 13+) for controllers, authorization, queue jobs, and models; declarative configuration colocated with code
SkillCFreshness: C★ 157Claude Code +9 - 0.597score
laravel:form-requests
jpcaparas
Move validation and authorization into Form Requests; use rule objects, custom messages, and nested data handling to keep controllers slim
SkillCFreshness: C★ 157Claude Code +9 - 0.597score
laravel:migrations-and-factories
jpcaparas
Safe database change patterns; when to modify vs add migrations; always pair models with migrations and factories; seeding guidance
SkillCFreshness: C★ 157Claude Code +9 - 0.597score
laravel:request-forgery-protection
jpcaparas
Configure CSRF and origin-aware request forgery protection; PreventRequestForgery middleware (Laravel 13+) with token fallback and exclusions
SkillCFreshness: C★ 157Claude Code +9 - 0.597score
laravel:debugging-prompts
jpcaparas
Create effective debugging prompts—include error messages, stack traces, expected vs actual behavior, logs, and attempted solutions
SkillCFreshness: C★ 157Claude Code +9 - 0.597score
laravel:effective-context
jpcaparas
Provide comprehensive context in prompts—files, errors, Laravel version, dependencies, and monorepo details—for accurate AI responses
SkillCFreshness: C★ 157Claude Code +9 - 0.597score
laravel:eloquent-relationships
jpcaparas
Define clear relationships and load data efficiently; prevent N+1, use constraints, counts/sums, and pivot syncing safely
SkillCFreshness: C★ 157Claude Code +9 - 0.597score
laravel:ai-sdk
jpcaparas
Build AI features with the first-party Laravel AI SDK (Laravel 13+); agents, embeddings, images, audio, and tool calling with provider-agnostic APIs
SkillCFreshness: C★ 157Claude Code +9 - 0.597score
laravel:laravel-prompting-patterns
jpcaparas
Use Laravel-specific vocabulary—Eloquent patterns, Form Requests, API resources, jobs/queues—to get idiomatic framework code
SkillCFreshness: C★ 157Claude Code +9 - 0.597score
laravel:code-review-requests
jpcaparas
Request effective code reviews—specify focus areas, provide context, ask for architectural feedback, reference Laravel conventions
SkillCFreshness: C★ 157Claude Code +9 - 0.597score
laravel:upgrade-13
jpcaparas
Upgrade an app from Laravel 12.x to 13.x safely; PHP 8.3 baseline, dependency bumps, breaking-change checklist, and verification steps
SkillCFreshness: C★ 157Claude Code +9
Signals
- Stars
- 157
- Forks
- 3
- Open issues
- 0
- Last commit (this folder)
- Jul 2, 2026 (4 months ago)
- Last release
- Nov 4, 2025 (11 months ago)
From GitHub (fetched Oct 24, 2026).
Details
- License
- MIT
- Repository
- github.com/jpcaparas/superpowers-laravel
- First seen
- Oct 24, 2026
- Last checked
- Oct 24, 2026
- Source
- GitHubgithub-graphql
More from jpcaparas
- 0.597score
laravel:request-forgery-protection
jpcaparas
Configure CSRF and origin-aware request forgery protection; PreventRequestForgery middleware (Laravel 13+) with token fallback and exclusions
SkillCFreshness: C★ 157Claude Code +9 - 0.597score
laravel:code-review-requests
jpcaparas
Request effective code reviews—specify focus areas, provide context, ask for architectural feedback, reference Laravel conventions
SkillCFreshness: C★ 157Claude Code +9 - 0.597score
laravel:debugging-prompts
jpcaparas
Create effective debugging prompts—include error messages, stack traces, expected vs actual behavior, logs, and attempted solutions
SkillCFreshness: C★ 157Claude Code +9 - 0.597score
laravel:effective-context
jpcaparas
Provide comprehensive context in prompts—files, errors, Laravel version, dependencies, and monorepo details—for accurate AI responses
SkillCFreshness: C★ 157Claude Code +9 - 0.597score
laravel:ai-sdk
jpcaparas
Build AI features with the first-party Laravel AI SDK (Laravel 13+); agents, embeddings, images, audio, and tool calling with provider-agnostic APIs
SkillCFreshness: C★ 157Claude Code +9 - 0.597score
laravel:eloquent-relationships
jpcaparas
Define clear relationships and load data efficiently; prevent N+1, use constraints, counts/sums, and pivot syncing safely
SkillCFreshness: C★ 157Claude Code +9
Cite this page
laravel:specifying-constraints skill. Agent Mart. https://agentmart.dev/skills/jpcaparas-laravel-specifying-constraints (last updated 2026-10-24)