Builds interactive Python web UIs and ML demos with Gradio - Interface, Blocks, ChatInterface, event listeners, layouts, and streaming - with accurate component signatures.
---
name: huggingface-gradio
description: Build Gradio web UIs and demos in Python. Use when creating or editing Gradio apps, components, event listeners, layouts, or chatbots.
---
# Gradio
Gradio is a Python library for building interactive web UIs and ML demos. This skill covers the core API, component signatures, and patterns.
## How to use
1. For a quick demo, use the high-level `gr.Interface(fn=..., inputs="text", outputs="text").launch()` to wrap a function.
2. For custom layouts, use `gr.Blocks()` with explicit components and event wiring (`btn.click(fn=..., inputs=..., outputs=...)`).
3. For chatbots, use `gr.ChatInterface(fn=respond)` where `respond(message, history)` returns the reply.
4. Configure components from their real signatures (`Textbox`, `Number`, etc.) for labels, types, streaming, and interactivity.
5. Add streaming outputs/inputs and control layout with rows, columns, and tabs; reference the linked Gradio guides for advanced features.
6. Share with `launch(share=True)` or deploy to Hugging Face Spaces.
Full skill & source: https://github.com/huggingface/skills/tree/ea9a24f38a98baf2430dab3bcb31a89753ae9e6d/skills/huggingface-gradioIn any Claude conversation, say:
Install the Hugging Face Gradio skill
It activates automatically in your next session.
Not connected yet? Connect your AI first →
MCP endpoint
https://skillme.dev/api/mcp