DEV3 Promptly is a self-hosted AI SaaS: an AI writer with templates, chat with your own documents, embeddable website chatbots and workspaces on credit plans.
Stack: Laravel 12, Filament 4, Livewire 3, plus dev3/laravel-core and dev3/laravel-saas (single-database tenancy by team_id, plans, trials, invoices).
Decisions that mattered
- Every request takes one path: moderation, a credit check against an estimate, the provider driver, a usage log, then the debit for the tokens actually used.
- Customers see models, not vendors. A model row maps to a driver and an exact provider model id with its own credit multiplier, so switching vendor is one setting.
- Drivers are thin HTTP clients (OpenAI-compatible, Anthropic, Google) with streaming and token counting. Keys are stored encrypted.
- An offline demo model ships as the default so every feature can be tried without an API key.
Limits: the screenshots in the listing were all written by the offline demo model, and real quality depends on the provider you connect. There is no public live demo.
Trade-off we chose: credits are checked against an estimate before a call and settled on actual tokens afterwards.
If you run a metered AI product, how do you handle the gap between estimated and actual usage? Questions welcome.
#laravel#filament#ai#case-study