Works with the AI Agents you already use

    Claude CodeClaude CodeCursorCursorCodex CLICodex CLIMuseMuseDotsDots+21 more

    Agent Clarification UI Builder

    1

    Build interactive clarification forms for AI chat apps without disrupting simple conversations.

    $9

    Secure checkout via Stripe

    Money-back guarantee

    Converts to your local currency at checkout

    Security scanned
    Agent Clarification UI Builder

    Agent Clarification UI Builder

    Example session with this skill installed

    I need to add a clarification form to my React chat app to collect server specs (CPU, RAM, Region) when a user asks to deploy a node. Give me the tool schema and the React renderer code.

    • Read your context and instructions
    • Compiled the agent clarification ui
    • Generated the UI component

    I will implement the show_widget tool schema and a secure React iframe renderer to handle server specification collection.

    Implementation Plan

    The system will trigger this widget when a deploy command is missing specific infrastructure parameters. It will use a sandboxed iframe to prevent the model-generated HTML from accessing your application's DOM.

    1. Tool Definition (JSON Schema)

    {
      "name": "show_widget",
      "description": "Render a form to collect missing server specifications.",
      "parameters": {
        "type": "object",
        "properties": {
          "title": { "type": "string" },
          "loading_messages": {
            "type": "array",
            "items": { "type": "string" },
            "minItems": 2,
            "maxItems": 4
          },
          "widget_code": { "type": "string", "description": "HTML form markup per contract" }
        },
        "required": ["title", "loading_messages", "widget_code"]
      }
    }
    

    2. Secure React Renderer

    import React, { useRef, useEffect } from 'react';
    
    export const SafeWidget = ({ htmlContent, onFormSubmit }) => {
      const iframeRef = useRef<HTMLIFrameElement>(null);
    
      useEffect(() => {
        const handleMessage = (event: MessageEvent) => {
          // Validate event origin and source for security
          if (event.source !== iframeRef.current?.contentWindow) return;
          if (event.data.type === 'WIDGET_SUBMIT') {
            onFormSubmit(event.data.payload);
          }
        };
    
        window.addEventListener('message', handleMessage);
        return () => window.removeEventListener('message', handleMessage);
      }, [onFormSubmit]);
    
      return (
        <iframe
          ref={iframeRef}
          sandbox="allow-scripts"
          srcDoc={htmlContent}
          style={{ width: '100%', border: 'none', minHeight: '300px' }}
          title="Agent Clarification Form"
        />
      );
    };
    

    Next steps

    1. Add the tool definition to your LLM system prompt.
    2. Update your message component to switch to the SafeWidget when a show_widget tool call is detected.
    3. Test with templates/widget-example.html to verify the postMessage bridge.

    widget-example.html

    TSX · React component

    Generated

    Example file from a real run - the skill writes it into your workspace.

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

    About this skill

    Stop guessing what users want and start collecting structured data. This skill provides the logic and code contracts to implement interactive clarification forms directly within AI chat interfaces, reducing hallucination and conversational fatigue.

    What it does

    • Decision logic provides rules to determine if a task warrants a form or a simple follow-up question.
    • HTML data contract defines a strict, script-free markup standard for reliable cross-platform rendering.
    • Tool integration scaffolds the show_widget tool schema with loading states and validation.
    • Secure rendering implements iframe sandboxing, CSP headers, and event-based communication between the host and agent.
    • Result handling wires user form submissions back into the conversation as structured tool-result messages.

    How it works

    1. Analyze stack by identifying message rendering, tool-calling pipelines, and security boundaries.
    2. Define tool using the provided schema for title, loading_messages, and widget_code.
    3. Implement renderer with a sandboxed iframe that communicates via postMessage to keep the host app secure.
    4. Apply guardrails using the verification checklist to prevent XSS and ensure keyboard accessibility.

    Frameworks & tools

    Works with any web-based chat application stack including React, Next.js, and Vue. Compatible with OpenAI and Anthropic tool-calling protocols. Requires a host environment capable of rendering iframes and handling JSON tool results.

    Why this beats prompting it yourself

    Prompting an LLM to "make a form" usually results in broken layouts or dangerous inline scripts. This skill enforces a strict data contract and security architecture that separates untrusted model output from your application logic.

    Use cases

    • Gathering complex configuration parameters for DevOps or cloud infrastructure tasks.
    • Collecting multi-field user preferences for travel itineraries or document generation.
    • Auditing existing chat UIs to identify where forms should replace repetitive questioning.

    Known limitations

    Does not support branching decision trees or nested forms. Requires the host application to implement the rendering bridge as it is not a standalone plugin or hosted widget.

    No support for multi-step branching logic or nested forms. Requires host application implementation for iframe rendering and postMessage handling. Not a standalone widget.

    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 any payment.

    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

    Money-back guarantee

    Doesn't do what its page promises? You get your money back.

    Trust & safety

    Security scan

    Security scan passed 1 day ago

    Permissions

    Read Files
    Network Access
    Listed1 day ago

    What's inside

    Frequently Asked Questions

    This skill solves the problem of 'conversational fatigue' by replacing long strings of back-and-forth clarifying questions with a structured, interactive form. It ensures your AI collects precise parameters for complex tasks without the risk of hallucinations or broken UI layouts.

    The skill is framework-agnostic and works with any web stack like React, Vue, or Next.js that supports iframe sandboxing. It is fully compatible with OpenAI and Anthropic tool-calling protocols, as well as any LLM that can output structured JSON.

    You will receive the complete logic for decision-making (when to show a form), the HTML data contract for rendering, a secure tool schema for your agent, and a comprehensive security checklist for sandboxing. It provides the architectural blueprint and code contracts needed to bridge your agent and your UI.

    Yes, because this skill utilizes a script-free HTML markup standard and event-based communication (postMessage), it allows you to render forms safely within a sandboxed iframe. This architecture protects your host application from XSS risks associated with untrusted model outputs.

    No, this is not a plug-and-play widget or a hosted service. It is a set of logic and implementation standards that require you to have control over your chat application's rendering bridge to handle the tool-call results.

    New in Agents & Orchestration