Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx agentmods add skills/fusengine/agents/laravel-ai-sdknpx skills add fusengine/agents --skill laravel-ai-sdkgit clone --depth 1 https://github.com/fusengine/agentsWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/fusengine/agents/laravel-ai-sdk)<a href="https://agentmods.dev/skills/fusengine/agents/laravel-ai-sdk"><img src="https://agentmods.dev/badge/skills/fusengine/agents/laravel-ai-sdk.svg" alt="Measured on agentmods" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5 | $0.00035 | $0.01389 |
| Opus 5 | $0.00017 | $0.00694 |
| Sonnet 5 | $0.00007 | $0.00278 |
| Haiku 4.5 | $0.00003 | $0.00139 |
Grade A, and why
laravel-ai-sdk scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured today.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 142 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Laravel AI SDK
Agent Workflow (MANDATORY)
Before ANY implementation, spawn 3 agents in parallel, one Agent call each with a name:
- fuse-ai-pilot:explore-codebase - Map existing AI usage (custom HTTP clients, OpenAI PHP, etc.) to migrate
- fuse-ai-pilot:research-expert - Verify provider model IDs and pricing on the official Laravel AI SDK docs
- mcp__context7__query-docs - Pull latest
laravel.com/docs/13.x/ai-sdkexamples
After implementation, run fuse-ai-pilot:sniper for validation.
Overview
| Feature | Description |
|---|---|
| Unified API | Same code surface for 14+ providers via Lab enum |
| Agents | Class-based with Agent contract + Promptable trait |
| Tool calling | First-party FileSearch + custom tools per agent |
| Embeddings | Embeddings::for([...])->generate() + Str::toEmbeddings() |
| Streaming | Native SSE + Vercel AI SDK protocol compatibility |
| Structured output | agent(schema: fn ($s) => ...) with JsonSchema |
Critical Rules
- Use the
Labenum - Never hard-code provider strings; useLab::Anthropic,Lab::OpenAI, etc. - Configure keys in
.env- One env var per provider (OPENAI_API_KEY,ANTHROPIC_API_KEY, ...) read byconfig/ai.php - Agents are classes - Always implement
Laravel\Ai\Contracts\Agentand usePromptabletrait - Declare tools explicitly - Override
tools(): iterableto expose tool calls; never assume implicit registration - Stream via routes - Return
$agent->stream(...)directly from a route; do not buffer in memory
What ships with it
10 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.
- references/agents.md 1.7 KB
- references/embeddings.md 1.5 KB
- references/installation.md 2.4 KB
- references/streaming.md 1.7 KB
- references/structured-output.md 1.8 KB
- references/templates/Agent.php.md 1.3 KB
- references/templates/EmbeddingService.php.md 2.0 KB
- references/templates/StreamingController.php.md 1.2 KB
- references/templates/Tool.php.md 1.3 KB
- references/tools.md 1.7 KB
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- today Changed 1547c2c2a933
- yesterday First seen · 142 lines · 35 tokens per session scan A 605f06f6ad41
laravel-ai-sdk is a skill published in the GitHub repository fusengine/agents (25 stars, last pushed today), licensed MIT. It adds 35 tokens to every session and 1,389 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.
Other skills, from other repositories
expert-ai-engineer
AI/ML engineering specialist — LLM integrations, prompt design, RAG pipelines, embeddings, evals, fine-tuning decisions, agent architectures. Use for any task involving model APIs, prompts, vector stores, or ML tradeoffs. Normally invoked by model-router.
ai-workflow-architect
Designs AI systems, automations, and agent workflows for a business — identifying which manual work is worth automating, how to structure the system, which tools fit, and what could go wrong. Use this to automate part of an operation, design an agent or MCP workflow, reduce repetitive manual work, connect tools into a…
reviewing-ai-papers
Analyzes an AI/ML publication — paper, preprint, article, technical blog post — and extracts what an enterprise AI engineer should do about it. Use when someone supplies a URL or document on RAG, embeddings, fine-tuning, prompt engineering, agents, or LLM deployment and asks "review this paper", "what do you make of…
AI & LLM Security
LLM and AI application security testing — prompt injection, jailbreak resistance, OWASP LLM Top 10 (2025), RAG and agent/tool-use security, model supply chain, and AI red teaming for authorized assessments.
dspy-haystack-integration
Use for integrating DSPy with Haystack, optimizing Haystack prompts, improving retrieval pipelines, and extracting DSPy prompts.
audit-langfuse-llm
Run a PDCA quality audit on LLM/AI features: traces, prompts, costs, evals, grounding, hallucination. Use for "audit LLM quality", "check Langfuse", "audit prompts", "check AI quality", "audit AI costs", "check traces". Jailbreak/OWASP LLM → audit-llm-security. Token caps → plan-llm-cost-guardrails.