Works with the AI Agents you already use

    Claude CodeClaude CodeCursorCursorCodex CLICodex CLIDeepSeekDeepSeekMuseMuse+22 more

    Tool Schema Designer: Tools Claude Calls Right

    1

    This skill stops LLMs from hallucinating parameters or choosing the wrong functions by enforcing strict schema design and actionable error handling.

    Free

    1 useSecurity scanned
    Tool Schema Designer: Tools Claude Calls Right

    Tool Schema Designer: Tools Claude Calls Right

    Example session with this skill installed

    Design a tool for a CRM agent to search for contacts. It should support filtering by name, tag, or email and handle pagination. Provide the JSON schema and test prompts.

    • Read your context and instructions
    • Compiled the tool schema designer

    I have designed the crm_search_contacts tool using a task-oriented approach. The schema uses strict typing and provides clear examples for the LLM to follow, including specific pagination controls to prevent context overflow.

    CRM Tool Definition

    {
      "name": "crm_search_contacts",
      "description": "Searches for contacts within the CRM database based on specific filters. Use this when the user asks to find, list, or filter people. Do not use for creating or deleting contacts. Returns a maximum of 50 results per call.",
      "parameters": {
        "type": "object",
        "properties": {
          "query": {
            "type": "string",
            "description": "The search term for name or email. Example: 'John Doe' or 'jane@company.com'"
          },
          "tags": {
            "type": "array",
            "items": { "type": "string" },
            "description": "Filter by contact tags. Example: ['prospect', 'high-value']"
          },
          "limit": {
            "type": "integer",
            "default": 20,
            "description": "Number of contacts to return. Max 50."
          },
          "cursor": {
            "type": "string",
            "description": "Pagination token from a previous search result to fetch the next page."
          }
        },
        "required": ["query"],
        "additionalProperties": false
      }
    }
    

    Validation Tests

    Test PromptExpected Tool CallExpected ArgumentsResult
    "Find all prospects with the tag 'vip'"crm_search_contacts{"query": "", "tags": ["vip"]}Pass
    "Search for email support@corp.com"crm_search_contacts{"query": "support@corp.com"}Pass
    "Get the next 10 contacts"crm_search_contacts{"query": "", "limit": 10, "cursor": "XYZ"}Pass

    Next steps

    1. Implement the tool handler to parse these JSON arguments.
    2. Ensure your backend returns the cursor field in the response metadata.
    3. Test the "Actionable Error" path by passing an invalid limit to the LLM.

    Connects securely to your tools. The creator never sees your data.

    About this skill

    Building reliable agentic workflows requires tools that models actually understand. This skill stops LLMs from hallucinating parameters or choosing the wrong functions by enforcing strict schema design and actionable error handling.

    What it does

    • Task-based architecture designs tools around specific user actions rather than just wrapping existing API endpoints.
    • Strict JSON schemas defines clear parameter types with additionalProperties: false to prevent model confusion.
    • Semantic naming applies verb_noun conventions and namespacing for clear tool selection in complex agents.
    • Token-efficient outputs structures returns to provide only necessary data, preventing context window bloat.
    • Actionable error design replaces vague stack traces with specific instructions the LLM can use to self-correct.

    How it works

    1. Task Inventorying creates a mapping of 3 to 15 tools based on user goals rather than backend routes.
    2. Schema Definition builds the JSON properties with enums, units, and clear descriptions including examples.
    3. Output Optimization configures response formats and pagination logic to maintain high signal-to-noise ratios.
    4. Validation Testing runs 10 realistic prompts to verify tool selection, argument accuracy, and token usage.

    Frameworks & tools

    The skill produces standard JSON Schema definitions compatible with OpenAI, Anthropic, and the Model Context Protocol (MCP). It is language-agnostic but follows best practices for Python, TypeScript, and Go SDKs.

    Why this beats prompting it yourself

    Generic prompts often result in tools with vague descriptions that cause LLMs to hesitate or misinterpret units. This skill follows a systematic testing loop that forces the model to prove it can call the tools correctly before you ship to production.

    Use cases

    • Design a suite of tools for a custom MCP server.
    • Fix an agent that consistently passes incorrectly formatted dates or units.
    • Refactor a bloated API wrapper into a focused set of agent tools.
    • Create a standardized tool library for a multi-agent system.

    Known limitations

    This skill focuses on interface design and does not write the internal logic or backend implementation for the tools. It is optimized for agents using 3 to 15 tools per context.

    Find more skills like this on the Claude Skills Marketplace, the Codex Skills Marketplace and the Gemini Skills Marketplace, or browse Claude Skills for Prompt & Skill Engineering.

    Focuses on schema and interface design only. Does not write the internal execution logic or backend code. Optimized for sets of 3 to 15 tools.

    How to use

    1. 1

      Connect your agent to the Agensi MCP

      Copy the prompt and paste it into Claude, ChatGPT, Cursor or any agent that supports MCP. It sets up the connection for you. Manual setup

    2. 2

      Sign in to Agensi

      Your agent shows a sign-in link. Sign in and click Allow.

    3. 3

      Ask for what you need

      Your agent loads this skill and uses it on your task. It always asks before buying a skill.

    Reviews

    No reviews yet

    Be one of the first to try it. Every listed skill goes through the trust checks below.

    Security scanned

    Checked by our 8-point scan before listing

    1 use

    Times used to date

    Free to use

    No account required to browse

    Trust & safety

    Security scan

    Security scan passed 4 days ago

    • Free with an Agensi account

    Permissions

    No special permissions declared or detected

    Listed4 days ago
    Updated1 day ago

    What's inside

    Frequently Asked Questions

    This skill solves common issues like parameter hallucinations, incorrect unit formatting, and tool selection errors by applying strict JSON schemas and semantic naming conventions that make tool functions unmistakable to the model.

    The skill generates standard JSON Schema definitions that are fully compatible with OpenAI, Anthropic, and the Model Context Protocol (MCP), working across Python, TypeScript, and Go environments.

    You receive a suite of optimized tool schemas (typically 3 to 15) mapped to your specific user tasks, complete with optimized output formats and a validation report from 10 stress-test prompts.

    This skill focuses on the 'interface layer'—designing the names, descriptions, and parameter constraints—rather than writing the internal backend code or business logic for your API.

    Yes, the design process includes 'Actionable Error Design,' which replaces generic errors with specific, model-readable instructions that allow the agent to correct its own mistakes and try again.

    New in Prompt & Skill Engineering

    Free