More screenshots

    Works with the AI Agents you already use

    AI Text-to-SQL Assistant with Clarification

    by Manaswi

    1

    Convert natural-language questions into SQL queries with AI-powered clarification, schema awareness, query validation, and easy-to-understand SQL explanations.

    Free

    Security scanned

    What it does

    • Converts natural-language questions into SQL queries Asks clarification questions when user requests are ambi
    • Convert everyday English questions into SQL queries
    • Ask follow-up questions when a request is unclear
    • Check generated queries for common SQL safety issues
    • Explain SQL queries step by step in simple language

    Who it's for

    Buyer: Students and SQL Beginners

    What they get: Learn SQL by converting everyday questions into SQL queries with simple explanations.

    Try asking: “Try: "Show me all customers from Mumbai.”

    Buyer: Data Analysts

    What they get: Save time writing SQL queries for data analysis and reporting.

    Try asking: “Try: "Find the top 10 customers by total spending.”

    Buyer: Software Developers

    What they get: Generate SQL queries using their database schema and understand table relationships.

    Try asking: “Try: "Join customers and orders to show customer purchase history.”

    Buyer: Database Learners

    What they get: Understand SQL queries, joins, filters, grouping, and database concepts through AI explanations.

    Try asking: “Try: "Explain how this SQL JOIN query works.”

    AI Text-to-SQL Assistant with Clarification

    AI Text-to-SQL Assistant with Clarification

    Example session with this skill installed

    I have a PostgreSQL database with the following tables:

    customers

    • customer_id
    • customer_name
    • city

    orders

    • order_id
    • customer_id
    • order_date
    • total_amount

    Generate a SQL query to find the top 5 customers from Mumbai based on their total spending.

    Please explain the query in simple language and check it for common SQL safety issues.

    • Read your context and instructions
    • Compiled the ai text-to-sql assistant

    SQL Query Generation Result

    1. Understanding

    You want to identify the five customers from Mumbai who have the highest total spending across their orders.

    2. Generated SQL Query

    SELECT
        c.customer_id,
        c.customer_name,
        SUM(o.total_amount) AS total_spending
    FROM customers c
    JOIN orders o
        ON c.customer_id = o.customer_id
    WHERE c.city = 'Mumbai'
    GROUP BY
        c.customer_id,
        c.customer_name
    ORDER BY
        total_spending DESC
    LIMIT 5;
    

    3. Explanation

    SQL ComponentPurpose
    SELECTDisplays customer details and total spending
    FROMUses the customers table
    JOINConnects customers with their orders
    WHEREFilters customers from Mumbai
    GROUP BYGroups orders by customer
    SUMCalculates total spending
    ORDER BYSorts customers by spending, highest first
    LIMITReturns only five customers

    4. Assumptions

    • customer_id connects the two tables.
    • total_amount represents the order value.
    • Customers without orders are excluded because this uses an INNER JOIN.
    • PostgreSQL syntax is being used.

    5. SQL Safety Check

    CheckResult
    Query typeSELECT
    Data modificationNone
    DELETE or DROP operationsNone
    Basic SQL reviewPassed

    This is a static review, not a live database execution.

    6. Expected Output

    customer_idcustomer_nametotal_spending
    101Example Customer A95000
    108Example Customer B78000
    115Example Customer C65000
    122Example Customer D52000
    130Example Customer E41000

    The output above is illustrative and does not represent actual database records.

    7. Next Steps

    1. Verify the table and column names.
    2. Confirm the customer-order relationship.
    3. Run the query in your PostgreSQL environment.
    4. Review the results.

    Final Result: A natural-language database question has been converted into a structured SQL query with an explanation and basic safety review.

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

    About this skill

    When you need to pull data from a database but don't know the right code, it feels like there is a wall between you and your answers. You know what you want to ask, but the database only speaks SQL. This skill helps your AI agent act as a bridge. It takes your business questions and turns them into clean, safe code based on the table names and columns you provide. It won't guess or make up data. Instead, it asks smart questions to make sure the result is exactly what you need.

    How it works

    1. Provide a list of your table names and columns or a file showing your database structure.
    2. Type your question in plain English, like asking for sales totals or customer lists.
    3. Review any clarifying questions from your AI agent about dates, filters, or specific math.
    4. Receive the completed code block along with a simple explanation of what each part does.

    What you get: A ready to use SQL query and a plain language breakdown of how it finds your data.

    • Does not directly connect to or execute queries on a live database.
    • Requires the buyer to provide the database schema, table relationships, and SQL dialect for accurate results.
    • Generated SQL may need manual review and testing before execution.
    • Accuracy depends on the quality and completeness of the schema and natural-language question.
    • Complex queries may require additional clarification or refinement.

    This skill acts as a natural language interface for SQL generation using provided schema context. It follows a multi-step logic: request restatement, ambiguity check, schema inspection, and safety review. It supports multiple dialects (PostgreSQL, MySQL, SQLite, SQL Server) and prioritizes read-only SELECT statements. It generates code blocks and explanations but lacks a database connector.

    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

    Fresh listing

    Recently published to Agensi

    Free to use

    No account required to browse

    Trust & safety

    Security scan

    Security scan passed 1 day ago

    • Free with an Agensi account

    Provide your database schema (table names, column names, and relationships) and SQL dialect (PostgreSQL, MySQL, SQLite, or SQL Server) for best results. This skill generates and explains SQL queries but does not directly connect to or execute queries on your live database.

    Permissions

    No special permissions declared or detected

    Listed1 day ago

    What's inside

    Frequently Asked Questions

    This skill turns your plain English questions into clean SQL code by using the specific database structure you provide. It helps you get data from your tables without needing to memorize complex coding syntax.

    You need to provide your table names and columns, a database schema, or a file that shows how your data is organized. The skill also needs to know which database type you use, such as PostgreSQL or MySQL, to ensure the code works correctly.

    You will receive a complete block of SQL code and a plain language explanation of how the query works. It also includes notes on any assumptions made and tips for running the code safely.

    No. This skill generates and explains SQL queries but does not connect to your live database or execute queries. Always review and test generated SQL in your database environment before running it, especially if it modifies or deletes data.

    The skill is designed to ask you one clarifying question at a time if your request is unclear. For example, if you ask for top customers, it will ask if you mean by total spending or by the number of orders.

    Simply tell your AI agent that you want to write a SQL query and provide your database table details. You can then ask your question in normal English, such as asking for a list of sales from last month.

    New in APIs & Backend

    Find more skills like this on the Claude Skills Marketplace, the Codex Skills Marketplace and the Gemini Skills Marketplace, or browse Claude Skills for APIs & Backend.

    Free