gradio/js/_website/CHANGELOG.md
Gradio PR Bot 5a2967e78a
chore: update versions (#9747)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-10-21 19:28:58 -07:00

47 KiB

website

0.40.3

Fixes

  • #9653 61cd768 - Ensures tabs with visible set to false are not visible. Thanks @hannahblair!
  • #9738 2ade59b - Export Tabs type from @gradio/tabs and fix the Playground to be compatible with the new Tabs API. Thanks @whitphx!

Dependency updates

  • @gradio/tabs@0.3.2
  • @gradio/tabitem@0.3.2
  • @gradio/code@0.10.5
  • @gradio/paramviewer@0.5.4

0.40.2

Dependency updates

  • @gradio/code@0.10.4
  • @gradio/paramviewer@0.5.3

0.40.1

Dependency updates

  • @gradio/tabs@0.3.1
  • @gradio/code@0.10.3
  • @gradio/paramviewer@0.5.2
  • @gradio/tabitem@0.3.1

0.40.0

Features

  • #9635 67e4044 - Add website banner for gradio 5. Thanks @aliabd!

Dependency updates

  • @gradio/code@0.10.2

0.39.1

Features

Dependency updates

  • @gradio/code@0.10.1
  • @gradio/paramviewer@0.5.1

0.39.0

Features

Dependencies

  • @gradio/code@0.10.0
  • @gradio/tabs@0.3.0
  • @gradio/tabitem@0.3.0

0.39.0-beta.9

Dependency updates

  • @gradio/code@0.10.0-beta.8
  • @gradio/paramviewer@0.4.22-beta.5
  • @gradio/tabitem@0.3.0-beta.4
  • @gradio/tabs@0.3.0-beta.3

0.39.0-beta.8

Dependency updates

  • @gradio/tabitem@0.3.0-beta.4
  • @gradio/code@0.10.0-beta.7
  • @gradio/paramviewer@0.4.22-beta.4

0.39.0-beta.7

Dependency updates

  • @gradio/code@0.10.0-beta.6

0.39.0-beta.6

Features

  • #9460 7352a89 - Playground requirements tab. Thanks @whitphx!
  • #9452 3ec8e63 - Expanding AI Playground Prompt for Qwen. Thanks @aliabd!

Dependency updates

  • @gradio/tabs@0.3.0-beta.3
  • @gradio/tabitem@0.3.0-beta.3
  • @gradio/code@0.10.0-beta.5
  • @gradio/paramviewer@0.4.22-beta.3

0.39.0-beta.5

Dependency updates

  • @gradio/code@0.10.0-beta.4
  • @gradio/paramviewer@0.4.22-beta.2

0.39.0-beta.4

Features

  • #9419 018c140 - Start/stop recoding from the backend. Add guide on conversational chatbots. Thanks @freddyaboulton!
  • #9469 f7c3396 - Fix. Triggered dataframe change event for header change. Thanks @Joodith!
  • #9426 4e54105 - Refactoring playground. Thanks @whitphx!
  • #9462 b622b1f - Improve UI on the Playground. Thanks @aliabd!

0.39.0-beta.3

Dependency updates

  • @gradio/code@0.10.0-beta.3

0.39.0-beta.2

Features

Dependency updates

  • @gradio/code@0.10.0-beta.2
  • @gradio/paramviewer@0.4.22-beta.2

0.39.0-beta.1

Features

  • #9204 3c73f00 - 🔡 Update default core Gradio font. Thanks @hannahblair!

Dependency updates

  • @gradio/code@0.9.1-beta.1
  • @gradio/paramviewer@0.4.22-beta.1

0.39.0-beta.0

Features

  • #9194 20c0836 - Deprecate type='tuples for chatbot and focus chatbot docs on 'messages' type. Thanks @freddyaboulton!
  • #9213 ab4580b - Remove grey background behind all components. Thanks @hannahblair!
  • #9206 bdbcf7b - Cloudflare migration. Thanks @aliabd!
  • #9156 8deeeb6 - File access security guide. Thanks @freddyaboulton!

0.39.1

Features

Dependency updates

  • @gradio/code@0.9.1
  • @gradio/paramviewer@0.4.22

0.39.0

Features

  • #9291 bcb3a2b - chore: update error.svx. Thanks @eltociear!

0.38.1

Features

Fixes

  • #9163 2b6cbf2 - fix exports and generate types. Thanks @pngwn!

Dependency updates

  • @gradio/paramviewer@0.4.22-beta.0
  • @gradio/code@0.9.1-beta.0

0.38.0

Features

  • #9102 efdc323 - Initial SSR refactor. Thanks @pngwn!
  • #9104 cf02f7d - Fix chatinterface e2e test. Thanks @freddyaboulton!
  • #9075 3258968 - Add warning to guides and change styling of tip. Thanks @aliabd!
  • #9108 474102a - Better text styling on docs. Thanks @aliabd!

Dependency updates

  • @gradio/code@0.9.0
  • @gradio/paramviewer@0.4.21

0.37.0

Features

  • #8965 d30432e - harden CI. Thanks @pngwn!
  • #9043 890bae3 - Filter out type ignore comments from demos on website. Thanks @aliabd!
  • #8857 6584aac - Website fixes for mobile. Thanks @aliabd!
  • #9067 f29aef4 - Fix trailing slash link on docs. Thanks @aliabd!

Dependency updates

  • @gradio/code@0.8.2
  • @gradio/paramviewer@0.4.20

0.36.0

Features

  • #8907 9b42ba8 - Update guides esp plots. Thanks @aliabid94!
  • #8871 7f1a78c - Add confirmation dialogue if leaving playground. Thanks @aliabd!
  • #8908 7c9fc9e - Add docs for Rust client to website. Thanks @aliabd!

Dependency updates

  • @gradio/code@0.8.1
  • @gradio/paramviewer@0.4.19

0.35.0

Features

  • #8842 38c2ad4 - Add website to contributing readme. Thanks @aliabd!
  • #8784 2cc813a - Fix OS detection for cross-browser compatibility. Thanks @lappemic!
  • #8825 b45d37f - Fix param table rendering. Thanks @aliabd!
  • #8773 0b9e870 - Hide embedded components while loading. Thanks @aliabd!
  • #8832 e75f2ca - Fix build for pre-release. Thanks @pngwn!
  • #8618 aa4b7a7 - Improve styling of parameter tables in the docs. Thanks @abidlabs!
  • #8745 4030f28 - Allows updating the dataset of a gr.Examples. Thanks @abidlabs!
  • #8757 6073736 - Document FileData class in docs. Thanks @hannahblair!

Fixes

  • #8823 7b049e0 - Fix DateTime docs. Thanks @aliabd!
  • #8854 d1f0441 - Use covariant container types across the codebase and add typing to our demos. Thanks @abidlabs!

Dependency updates

  • @gradio/code@0.8.0
  • @gradio/paramviewer@0.4.18

0.34.0

Highlights

Support message format in chatbot 💬 (#8422 4221290)

gr.Chatbot and gr.ChatInterface now support the Messages API, which is fully compatible with LLM API providers such as Hugging Face Text Generation Inference, OpenAI's chat completions API, and Llama.cpp server.

Building Gradio applications around these LLM solutions is now even easier!

gr.Chatbot and gr.ChatInterface now have a type parameter that can accept two values - 'tuples' and 'messages'. If set to 'tuples', the default chatbot data format is expected. If set to 'messages', a list of dictionaries with content and role keys is expected. See below -

def chat_greeter(msg, history):
    history.append({"role": "assistant", "content": "Hello!"})
    return history

Additionally, gradio now exposes a gr.ChatMessage dataclass you can use for IDE type hints and auto completion.

image

Tool use in Chatbot 🛠️

The Gradio Chatbot can now natively display tool usage and intermediate thoughts common in Agent and chain-of-thought workflows!

If you are using the new "messages" format, simply add a metadata key with a dictionary containing a title key and value. This will display the assistant message in an expandable message box to show the result of a tool or intermediate step.

import gradio as gr
from gradio import ChatMessage
import time

def generate_response(history):
    history.append(ChatMessage(role="user", content="What is the weather in San Francisco right now?"))
    yield history
    time.sleep(0.25)
    history.append(ChatMessage(role="assistant",
                               content="In order to find the current weather in San Francisco, I will need to use my weather tool.")
                               )
    yield history
    time.sleep(0.25)

    history.append(ChatMessage(role="assistant",
                               content="API Error when connecting to weather service.",
                              metadata={"title": "💥 Error using tool 'Weather'"})
                  )
    yield history
    time.sleep(0.25)

    history.append(ChatMessage(role="assistant",
                               content="I will try again",
                              ))
    yield history
    time.sleep(0.25)

    history.append(ChatMessage(role="assistant",
                               content="Weather 72 degrees Fahrenheit with 20% chance of rain.",
                                metadata={"title": "🛠️ Used tool 'Weather'"}
                              ))
    yield history
    time.sleep(0.25)

    history.append(ChatMessage(role="assistant",
                               content="Now that the API succeeded I can complete my task.",
                              ))
    yield history
    time.sleep(0.25)

    history.append(ChatMessage(role="assistant",
                               content="It's a sunny day in San Francisco with a current temperature of 72 degrees Fahrenheit and a 20% chance of rain. Enjoy the weather!",
                              ))
    yield history


with gr.Blocks() as demo:
    chatbot  = gr.Chatbot(type="messages")
    button = gr.Button("Get San Francisco Weather")
    button.click(generate_response, chatbot, chatbot)

if __name__ == "__main__":
    demo.launch()

tool-box-demo

Thanks @freddyaboulton!

Features

  • #8733 fb0daf3 - Improvements to gr.Examples: adds events as attributes and documents, them, adds sample_labels, and visible properties. Thanks @abidlabs!
  • #8686 64ac05b - Better spacing for codeblocks on docs. Thanks @aliabd!
  • #8656 740364e - Add guide on best practices for ZeroGPU limits with the python client. Thanks @freddyaboulton!
  • #8689 edcd574 - Fix playground to display errors. Thanks @whitphx!
  • #8624 ba59bb8 - Add search to website. Thanks @aliabd!

Fixes

  • #8505 2943d6d - Add Timer component. Thanks @aliabid94!
  • #8677 c946c6f - Allow supplying custom gr.Chatbot with events to gr.ChatInterface. Thanks @abidlabs!

Dependency updates

  • @gradio/code@0.7.0

0.33.0

Features

  • #8604 b6fa6b5 - Add docs for .on(), .then(), and .success(), as well as the subclasses of gr.EventData. Thanks @abidlabs!
  • #8623 4c6e4e0 - Fix CORS issues with Lite Component Demos. Thanks @aliabd!

Dependency updates

  • @gradio/code@0.6.13

0.32.0

Features

  • #8489 c2a0d05 - Control Display of Error, Info, Warning. Thanks @freddyaboulton!
  • #8593 d35c290 - Adding more docs for using components in chatbot. Thanks @abidlabs!
  • #8516 de6aa2b - Add helper classes to docs. Thanks @aliabd!
  • #8605 fe83e64 - Small fix to guide styling. Thanks @aliabd!
  • #8557 ed82a62 - Bring back embedded demos on component docs. Thanks @aliabd!

Fixes

  • #8589 34430b9 - Handle GIFs correct in gr.Image preprocessing. Thanks @abidlabs!
  • #8581 a1c21cb - fix dataset update. Thanks @abidlabs!
  • #8537 81ae766 - Many small fixes to website and docs. Thanks @aliabd!
  • #8559 483ecaa - fix website build. Thanks @pngwn!

Dependency updates

  • @gradio/code@0.6.12

0.31.5

Features

  • #8491 ffd53fa - Remove broken guide redirect. Thanks @aliabd!
  • #8487 3a5d56e - Add Client Release Notes to Docs. Thanks @freddyaboulton!

Dependency updates

  • @gradio/code@0.6.11

0.31.4

Dependency updates

  • @gradio/code@0.6.10

0.31.3

Features

  • #8471 a9e6595 - Tweak meta titles and descriptions for clients. Thanks @aliabd!

Dependency updates

  • @gradio/code@0.6.9

0.31.2

Features

  • #8456 881f11c - Add website banner for clients launch. Thanks @aliabd!

0.31.1

Dependency updates

  • @gradio/code@0.6.8

0.31.0

Features

Dependency updates

  • @gradio/code@0.6.7

0.30.4

Dependency updates

  • @gradio/code@0.6.6

0.30.3

Features

  • #8319 1f9a5f0 - Fix bad redirect breaking website build. Thanks @aliabd!

0.30.2

Dependency updates

  • @gradio/code@0.6.5

0.30.1

Dependency updates

  • @gradio/code@0.6.4

0.30.0

Features

  • #8278 4ae17a4 - Embedded Lite example apps in the docs. Thanks @whitphx!
  • #8262 d708ca8 - Reorganize Guides in a more logical order. Thanks @abidlabs!

Dependency updates

  • @gradio/code@0.6.3

0.29.0

Features

  • #8224 6ee1f1f - Display all custom components in the gallery. Thanks @freddyaboulton!

Fixes

  • #8220 f176e1b - Convert all demos on docs to lite. Thanks @aliabd!

Dependency updates

  • @gradio/code@0.6.2

0.28.0

Features

  • #8121 f5b710c - chore(deps): update dependency eslint to v9. Thanks @renovate!
  • #8189 68dcae5 - Use workspace version for code in _website. Thanks @aliabd!
  • #8152 989fe25 - Make guide for tailwind more verbose. Thanks @duerrsimon!

Dependency updates

  • @gradio/code@0.6.1

0.27.0

Features

  • #8061 17e83c9 - Docs Reorg and Intro Page. Thanks @aliabd!
  • #8122 e089e4c - update dependencies. Thanks @pngwn!
  • #8119 38a5482 - Be able to link to a custom component in the gallery directly. Thanks @freddyaboulton!

0.26.1

Dependency updates

  • @gradio/code@0.5.12

0.26.0

Features

  • #7945 328325a - style changes for gradio website docs navbar. Thanks @shafiqihtsham!

Fixes

  • #7935 919afff - Adds a Guide on deploying Gradio apps with Docker. Thanks @abidlabs!

Dependency updates

  • @gradio/code@0.5.11

0.25.2

Dependency updates

  • @gradio/code@0.5.10

0.25.1

Dependency updates

  • @gradio/code@0.5.9

0.25.0

Features

  • #7684 755157f - Do not reload code inside gr.NO_RELOAD context. Thanks @freddyaboulton!
  • #7661 c62a57e - Convert Docs Demos to Lite. Thanks @aliabd!

Dependency updates

  • @gradio/code@0.5.8

0.24.3

Dependency updates

  • @gradio/code@0.5.7

0.24.2

Dependency updates

  • @gradio/code@0.5.6

0.24.1

Patch Changes

  • Updated dependencies []:
    • @gradio/code@0.5.5

0.24.0

Features

0.23.4

Patch Changes

  • Updated dependencies []:
    • @gradio/code@0.5.3

0.23.3

Patch Changes

  • Updated dependencies []:
    • @gradio/code@0.5.2

0.23.2

Patch Changes

  • Updated dependencies []:
    • @gradio/code@0.5.1

0.23.1

Patch Changes

  • Updated dependencies [c1a7ea7]:
    • @gradio/code@0.5.0

0.23.0

Features

  • #7116 3c8c4ac - Document the gr.ParamViewer component, and fix component preprocessing/postprocessing docstrings. Thanks @abidlabs!

0.22.0

Features

0.21.3

Patch Changes

  • Updated dependencies []:
    • @gradio/code@0.3.7

0.21.2

Features

0.21.1

Patch Changes

  • Updated dependencies []:
    • @gradio/code@0.3.6

0.21.0

Features

0.20.4

Fixes

0.20.3

Patch Changes

  • Updated dependencies []:
    • @gradio/code@0.3.3

0.20.2

Patch Changes

  • Updated dependencies []:
    • @gradio/code@0.3.2

0.20.1

Patch Changes

  • Updated dependencies []:
    • @gradio/code@0.3.1

0.20.0

Features

0.19.0

Features

0.18.0

Features

0.17.0

Features

0.16.1

Patch Changes

  • Updated dependencies []:
    • @gradio/code@0.2.7

0.16.0

Features

0.15.0

Features

0.14.0

Features

0.13.0

Features

0.12.1

Patch Changes

  • Updated dependencies []:
    • @gradio/code@0.2.3

0.12.0

Features

0.11.1

Features

0.11.0

Patch Changes

0.11.0-beta.1

Features

0.11.0-beta.0

Features

Fixes

0.10.0

Features

0.9.0

Features

0.8.0

Features

0.7.1

Features

0.7.0

Features

Fixes

0.6.0

Features

0.5.0

Features

  • #5481 df623e74 - Toggle main vs versioned demos on website and show install snippet. Thanks @aliabd!

0.4.0

Features

0.3.0

Features

Fixes

0.2.2

Features

  • #5284 5f25eb68 - Minor bug fix sweep. Thanks @aliabid94!/n - Our use of exit was catching errors and corrupting the traceback of any component that failed to instantiate (try running blocks_kitchen_sink off main for an example). Now the exit exits immediately if there's been an exception, so the original exception can be printed cleanly/n - HighlightedText was rendering weird, cleaned it up

0.2.1

Fixes

0.2.0

Highlights

Improve startup performance and markdown support (#5279 fe057300)

Improved markdown support

We now have better support for markdown in gr.Markdown and gr.Dataframe. Including syntax highlighting and Github Flavoured Markdown. We also have more consistent markdown behaviour and styling.

Various performance improvements

These improvements will be particularly beneficial to large applications.

  • Rather than attaching events manually, they are now delegated, leading to a significant performance improvement and addressing a performance regression introduced in a recent version of Gradio. App startup for large applications is now around twice as fast.
  • Optimised the mounting of individual components, leading to a modest performance improvement during startup (~30%).
  • Corrected an issue that was causing markdown to re-render infinitely.
  • Ensured that the gr.3DModel does re-render prematurely.

Thanks @pngwn!

Features

0.1.0

Features

Fixes

0.0.2

Features

Fixes