ui_to_artifact
Transform UI screenshots into code, prompts, design specifications, or descriptions. Provide an image, choose an output type, and give detailed instructions to generate the artifact.
Instructions
Convert UI screenshots into various artifacts: code, prompts, design specifications, or descriptions.
Use this tool ONLY when the user wants to:
Generate frontend code from UI design (output_type='code')
Create AI prompts for UI generation (output_type='prompt')
Extract design specifications (output_type='spec')
Get natural language description of the UI (output_type='description')
Do NOT use for: screenshots containing text/code to extract, error messages, diagrams, or data visualizations.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| prompt | Yes | Detailed instructions describing what to generate from this UI image. Should clearly state the desired output and any specific requirements. | |
| output_type | Yes | Type of output to generate. Options: 'code' (generate frontend code), 'prompt' (generate AI prompt for recreating this UI), 'spec' (generate design specification document), 'description' (natural language description of the UI). | |
| image_source | Yes | Local file path or remote URL to the image |