What this prompt does
This prompt asks the AI to scaffold a complete Filament 3 admin resource for one Eloquent model, end to end. Instead of generating a bare resource and leaving you to wire up the form, table, filters, and actions by hand, it spells out eight concrete deliverables in a single pass: a form schema, a sortable/searchable table, relation managers, custom actions, validation, media uploads, translatable fields, and an export action.
The structure works because it forces the model name and its surrounding concerns to be decided up front. You set [model_name] to the model you're managing, list the [form_fields] so the AI picks correct field types (rich editor vs text vs select), declare a [filter_count] so the table isn't under- or over-filtered, name the [relations] that need relation managers, the [custom_actions] beyond the default CRUD, and the [export_format]. Because each variable maps to a real Filament concern, the output lands close to production rather than a generic stub.
When to use it
- Standing up a new admin panel section for a model that needs full CRUD plus media and exports
- Scaffolding a resource where you already know the fields and relations but don't want to type the boilerplate
- Building a content-managed model (posts, products) that needs a rich editor and a featured image
- Adding a resource that must stay consistent with Form Request validation used elsewhere in the app
- Generating translatable resources for multi-locale admin panels
- Wiring publish/archive/duplicate-style workflow actions onto an existing model
Example output
You get a set of PHP files: a Filament Resource class with form() and table() methods, one or more relation manager classes, and supporting bits like a Form Request and an export action. The form uses typed components matching your [form_fields], the table declares searchable/sortable columns plus the requested [filter_count] filters, and the custom actions appear as table or header actions. Expect navigation grouping and Spatie Media Library wiring included rather than as an afterthought.
Pro tips
- Be specific in
[form_fields]— note which field is a rich editor, which is a select, and which is the featured image, so the AI doesn't default everything to text inputs - Keep
[filter_count]honest; four well-chosen filters beat ten that nobody uses, and the AI will pad to hit the number you give - List only the
[relations]you actually manage inline — extra relation managers add clutter and queries - Name
[custom_actions]as verbs (publish, archive, duplicate) so the AI generates the right action callbacks and confirmation modals - Confirm the generated validation matches your real Form Request rules; treat the prompt output as a starting contract, not gospel
- Set
[export_format]to exactly what you need (CSV and Excel) so it doesn't scaffold export plumbing you'll never ship