synkathairo / flan-t5-large-gradio

A gradio frontend for Google's Flan-T5 Large language model, can also be adjusted for other sizes.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

flan-t5-large-gradio

A gradio frontend for Google's Flan-T5 Large language model, can also be adjusted for other sizes.

The gradio frontend runs in the browser, and displays a chat-like interface for interacting with the language model.

To run:

Install the dependencies: gradio, transformers, sentencepiece

Recommended to install: safetensors

Optionally also install: accelerate

Run with: python flan-t5-large-gradio.py

Optionally run with: accelerate launch flan-t5-large-gradio.py (this may or may not speed up your execution)

To use other size models

Modify lines 4-6, comment/uncomment to select a different model. Note that each model has different requirements for storage/RAM, the code as presently configured assumes sufficient RAM to load the entire model.

Additional info on loading large models is on the Hugging Face website, see also

About

A gradio frontend for Google's Flan-T5 Large language model, can also be adjusted for other sizes.

License:BSD 3-Clause "New" or "Revised" License


Languages

Language:Python 100.0%