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/superduke/ganvil/ai-integrationnpx skills add superduke/ganvil --skill ai-integrationgit clone --depth 1 https://github.com/superduke/ganvilWrote 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/superduke/ganvil/ai-integration)<a href="https://agentmods.dev/skills/superduke/ganvil/ai-integration"><img src="https://agentmods.dev/badge/skills/superduke/ganvil/ai-integration.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.1 | $0.00051 | $0.01464 |
| Opus 5 | $0.00026 | $0.00732 |
| Sonnet 5 | $0.00010 | $0.00293 |
| Haiku 4.5 | $0.00005 | $0.00146 |
Grade A, and why
ai-integration 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 6d ago.
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 — 189 lines — stays where its author put it; the contents beside it link to each section on GitHub.
AI Integration Guidelines
This skill provides patterns and best practices for weaving AI-powered features into applications built by the ganvil. It is referenced by the planner (when designing specs) and generators (when implementing AI features).
When to Add AI Features
Add AI features when they genuinely improve the product:
- Accelerating repetitive creative workflows (e.g., generating assets, code, or content)
- Providing intelligent defaults or suggestions based on context
- Automating multi-step processes through natural language
- Analyzing, summarizing, or transforming complex data
Do NOT add AI features just because you can. Each AI feature should solve a real user problem that would be tedious or impossible without AI.
Building App-Internal Agents
When the spec calls for AI-powered functionality, build a proper agent that can drive the app's own functionality through tools — not just a chat widget pasted on top.
The Tool-Use Pattern
The recommended architecture for app-internal AI features:
User Input (natural language)
↓
Agent Loop:
1. Understand intent
2. Plan which tools to call
3. Execute tools (your app's own functions)
4. Observe results
5. Repeat or respond
↓
Result (action taken in the app + explanation to user)
Implementation Steps
-
Define clear, focused tools that map to your app's core operations:
- Each tool does one thing well
- Parameters are typed and validated
- Return values are structured (not free text)
-
Build tools as standalone functions in your app:
- They should work independently of the AI integration
- They should be testable without an API key
-
Implement the agent loop:
- Receive user input → construct messages → call API → parse tool_use → execute → loop
- Handle the
end_turnstop reason to know when the agent is done - Accumulate tool results and feed them back as
tool_resultmessages
-
Handle errors gracefully:
- The agent should explain failures in natural language, not crash
- Implement retry logic for transient API errors
- Provide graceful degradation when the AI service is unavailable
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.
- 6d ago First seen · 189 lines · 51 tokens per session scan A 4cf113da7f2f
ai-integration is a skill published in the GitHub repository superduke/ganvil (3 stars, last pushed 1mo ago), licensed MIT. It adds 51 tokens to every session and 1,464 once invoked, about $0.0003 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-08-31.
Other skills, from other repositories
ccc-prompt-fix
Fix and sharpen a prompt. Diagnoses it against the 6 prompt-quality patterns, returns a tightened rewrite with the reasoning, and suggests the right library prompt for your task.
agy-prompting
Internal helper — how to tighten a user request into a sharp prompt for the Antigravity CLI (agy / Gemini 3.x with native web search and agentic tools).
meta-prompt-optimizer
Audit and rewrite prompts against Claude Opus 4.7 instruction-following best practices. Produces a scored audit plus a rewritten prompt. Use when the user asks to audit, review, critique, rewrite, improve, optimize, tighten, score, fix, migrate, or draft a prompt — including system prompts, CLAUDE.md files, Claude…
prompt-optimizer
Optimize prompts for Claude's latest models (Claude 5 family — Opus 5, Sonnet 5, Fable 5 — plus the still-active Opus 4.8, Sonnet 4.6, and Haiku 4.5) using Anthropic's official prompt-engineering guidance. Use when users want to improve, refine, debug, or create prompts or system prompts for Claude. Triggers include…
refine
Crossover layer between the user's intent and LLM execution: takes a raw prompt (terse, frustrated, ambiguous, or shorthand), resolves every vague reference to a concrete artifact, recalls past decisions and lessons, and compiles a verifiable execution contract BEFORE any code is touched. Invoke explicitly as $refine…
gemini-prompting
Internal guidance for composing Gemini prompts for coding, review, diagnosis, and research tasks inside the Gemini Claude Code plugin.