Provide a better code snippet for generators in the "view API" page #4887
Labels
docs/website
Related to documentation or website
enhancement
New feature or request
gradio_client
Related to the one of the gradio client libraries
Say you have a Gradio app like this:
The view API page is still going to suggest that you use the
.predict()
function to call this method via an API:However, this only gives you the first iteration, which is not usually what you want. Instead, it would be better to show the
.submit()
usage here.Inspired by this question: https://discuss.huggingface.co/t/gradio-api-streaming/45395
The text was updated successfully, but these errors were encountered: