sandeepmajumdar commited on
Commit
a057dcd
·
1 Parent(s): 2d8463e
Files changed (1) hide show
  1. app.py +17 -0
app.py ADDED
@@ -0,0 +1,17 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ from transformers import AutoModelForCausalLM, AutoTokenizer, set_seed
2
+ import gradio as gr
3
+
4
+ #def result(text):
5
+ # tokenizer = AutoTokenizer.from_pretrained("bigscience/bloom-1b1")
6
+ # model = AutoModelForCausalLM.from_pretrained("bigscience/bloom-1b1", use_cache=True)
7
+
8
+ with gr.Blocks() as demo:
9
+ gr.Markdown("Here is a Sentiment Analysis app")
10
+ gr.Interface.load(
11
+ 'huggingface/bigscience/bloom-1b1',
12
+ title='Text Generation',
13
+ examples=tg_examples,
14
+ description="Write an incomplete sentence and submit",
15
+ )
16
+
17
+ demo.launch()