ai-tool-creation
AI SDK v5 tool creation patterns for this project. Factory functions, Zod schemas, budget tracking, rate limiting, caching, timeout handling. Triggers on "tool", "ai tool", "searchAll", "codeExecution", "urlReader", "tool creation".
npx skills add majiayu000/claude-skill-registry --skill ai-tool-creation --agent claude-code
Same command for any agent — swap --agent for codex, cursor, copilot.
Weekly change comes from our own snapshots, not the repository page — it measures attention, not adoption.
# AI Tool Creation Tools for Vercel AI SDK v5. All tools use factory pattern, Zod validation, budget tracking, rate limiting, search caching, timeout enforcement. ## Tool Factory Pattern Tools created via factory functions accepting `ctx`, `userId`, optional params: ```typescript // From convex/ai/tools/search/searchAll.ts export function createSearchAllTool( ctx: ActionCtx, userId: Id<"users">, currentConversationId?: Id<"conversations">, searchCache?: Map<string, unknown>, budgetState?: { current: BudgetState; update: (newState: BudgetState) => void; }, ) { return tool({ description: `Search across ALL resource types...`, inputSchema: z.object({ ... }), execute: async ({ query, projectId, resourceTypes, limit }) => { ... }, }); } ``` **Pattern**: Factory wraps `tool()` from AI SDK, captures context in closure. ## Zod Input Schema Describe all parameters clearly - AI reads these to understand tool usage: ```typescript // From convex/ai/tools/search/searchAll.ts inputSchema: z.object({ query: z.string().describe("What to search for across all resources"), projectId: z .string() .optional() .describe("Optional project ID to filter results to a specific project"), resourceTypes: z .a
- Tool Factory Pattern
- Zod Input Schema
- Description Format
- Budget State Integration
- Rate Limit Configuration
- Timeout Configuration
- Search Cache Pattern
- ProjectId Filtering
- Tool Registration
- Multi-Step Tool Calling
- Tool Result Truncation
- Type Casting Pattern
- Key Files
- Avoid
What does the ai-tool-creation skill do?
AI SDK v5 tool creation patterns for this project. Factory functions, Zod schemas, budget tracking, rate limiting, caching, timeout handling. Triggers on "tool", "ai tool", "searchAll", "codeExecution", "urlReader", "tool creation".
How do I install it?
Run `npx skills add majiayu000/claude-skill-registry --skill ai-tool-creation --agent claude-code` — it drops the skill into your project so the agent can pick it up. Swap the --agent value for codex, cursor or copilot if you use one of those.
Where does this skill come from?
From majiayu000/claude-skill-registry, a repository with 534 stars. We read it straight from the repository tree rather than a submitted listing, so what you see here is what is actually published.
Is a popular skill a good skill?
Not necessarily. Stars measure attention, not adoption — a repository can trend for a week and be abandoned. That is why we show the weekly change from our own snapshots next to the total, instead of a single flattering number.
