subhashladumor1/laravel-ai-guard
Laravel AI Guard ๐ก๏ธ๐ฐ๐ค - Control and optimize AI costs in Laravel AI SDK applications ๐ Track OpenAI & LLM token usage ๐, estimate AI costs before execution โ ๏ธ, enforce AI budgets ๐งพ, and prevent unexpected billing spikes in production ๐ฅ.
This package helps Laravel developers manage and control spending on AI services like OpenAI and Anthropic within their applications. It takes your app's AI requests, estimates their cost before they run, tracks actual token usage, and enforces budgets for users or organizations. This provides financial visibility and prevents unexpected AI billing spikes.
Use this if you are building or maintaining a Laravel application that uses AI and you need to ensure predictable costs, prevent overspending, and track every AI interaction for billing or internal reporting.
Not ideal if your application does not use Laravel, or if you only use AI APIs for non-critical, ad-hoc tasks where cost tracking is not a priority.
Stars
24
Forks
—
Language
PHP
License
MIT
Category
Last pushed
Feb 14, 2026
Commits (30d)
0
Get this data via API
curl "https://pt-edge.onrender.com/api/v1/quality/llm-tools/subhashladumor1/laravel-ai-guard"
Open to everyone — 100 requests/day, no key needed. Get a free key for 1,000/day.
Higher-rated alternatives
jmuncor/tokentap
Intercept LLM API traffic and visualize token usage in a real-time terminal dashboard. Track...
AgentOps-AI/tokencost
Easy token price estimates for 400+ LLMs. TokenOps.
Merit-Systems/echo
The User Pays AI SDK
Ruthwik000/tokenfirewall
Scalable LLM cost enforcement middleware for Node.js with budget protection and multi-provider support
adarshxs/TokenTally
Estimate Your LLM's Token Toll Across Various Platforms and Configurations