dawood HF staff commited on
Commit
6864462
1 Parent(s): c23c40c

Create app.py

Browse files
Files changed (1) hide show
  1. app.py +11 -0
app.py ADDED
@@ -0,0 +1,11 @@
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import gradio as gr
2
+
3
+ title = "GPT-J-6B"
4
+ description = "Gradio Demo for GPT-J 6B, a transformer model trained using Ben Wang's Mesh Transformer JAX. 'GPT-J' refers to the class of model, while '6B' represents the number of trainable parameters. To use it, simply add your text, or click one of the examples to load them. Read more at the links below."
5
+ article = "<p style='text-align: center'><a href='https://github.com/kingoflolz/mesh-transformer-jax' target='_blank'>GPT-J-6B: A 6 Billion Parameter Autoregressive Language Model</a></p>"
6
+ examples = [
7
+ ['The tower is 324 metres (1,063 ft) tall,'],
8
+ ["The Moon's orbit around Earth has"],
9
+ ["The smooth Borealis basin in the Northern Hemisphere covers 40%"]
10
+ ]
11
+ gr.Interface.load("huggingface/EleutherAI/gpt-j-6B", inputs=gr.Textbox(lines=5, label="Input Text"),title=title,description=description,article=article, examples=examples,enable_queue=True).launch()