gr.Workflow is a new Gradio feature that lets developers build AI pipelines as a graph of typed nodes on a drag-and-drop canvas, where every node is runnable and every intermediate result visible. The same graph automatically becomes a REST API and can be deployed to Hugging Face Spaces with one command. Example workflows shown include an image editor powered by Qwen-Image-Edit, a media studio chaining FLUX image generation, background removal, text-to-speech, and an LLM title generator, a parallel fan-out image generation demo, a Hugging Face dataset profiler, and a GPU-based video animation node using ZeroGPU and Diffusers. Each output node becomes a named REST endpoint callable via the Gradio client or plain curl. Building a workflow is as simple as wrapping Python functions with gr.Workflow(bind=[...]).launch().
Table of contents
Edit an ImageChain real models into a media studioFan-out image generation in parallelProfile a Hugging Face datasetRun your own GPU modelHow it works, in a nutshellCall it from codeBuild your ownQuestions this post answers
What is gr.Workflow in Gradio and what does it do?
gr.Workflow is a Gradio feature that lets developers describe an AI pipeline as a graph of typed nodes, with Gradio rendering a drag-and-drop canvas where every node is runnable and every intermediate result visible. The same graph automatically becomes a REST API and can be deployed to Hugging Face Spaces with a single command, without extra API setup work. Building multi-step AI pipelines gets easier to track when you follow releases like gr.Workflow on daily.dev.
How do I expose a Gradio workflow's outputs as REST API endpoints?
Each output node in a gr.Workflow graph automatically becomes a named REST endpoint based on its label, with no extra work required. You can call these endpoints with the gradio_client Python library using Client(space_name).predict(..., api_name="/endpoint_name"), or reach them directly over plain HTTP with curl against the /gradio_api/call/ path. Developers wiring up model APIs can follow Gradio's evolving tooling on daily.dev.
How can I run a GPU-based model inside a Gradio Space node instead of using an external inference API?
An fn node in gr.Workflow is just Python, so it can run a model directly inside the Space on a GPU rather than calling an external service. Decorating the bound function with @spaces.GPU lets ZeroGPU allocate a GPU for that call, run the model, and release it afterward, with gr.Workflow itself needing no knowledge of the GPU setup. Teams choosing between hosted inference and in-Space GPU execution track these tooling changes on daily.dev.