Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -1,11 +1,11 @@
|
|
1 |
import gradio as gr
|
2 |
|
3 |
-
from transformers import
|
4 |
from transformers import TextGenerationPipeline
|
5 |
|
6 |
|
7 |
tokenizer = AutoTokenizer.from_pretrained("Sigurdur/icebreaker")
|
8 |
-
model =
|
9 |
pipeline = TextGenerationPipeline(model=model, tokenizer=tokenizer)
|
10 |
|
11 |
def generate_text(inp):
|
|
|
1 |
import gradio as gr
|
2 |
|
3 |
+
from transformers import AutoModelForCausalLM, AutoTokenizer
|
4 |
from transformers import TextGenerationPipeline
|
5 |
|
6 |
|
7 |
tokenizer = AutoTokenizer.from_pretrained("Sigurdur/icebreaker")
|
8 |
+
model = AutoModelForCausalLM.from_pretrained("Sigurdur/icebreaker")
|
9 |
pipeline = TextGenerationPipeline(model=model, tokenizer=tokenizer)
|
10 |
|
11 |
def generate_text(inp):
|