update
Browse files
app.py
CHANGED
@@ -1,7 +1,7 @@
|
|
1 |
import gradio as gr
|
2 |
-
from transformers import GPT2Tokenizer,
|
3 |
tokenizer = GPT2Tokenizer.from_pretrained('gpt2')
|
4 |
-
model =
|
5 |
|
6 |
def generate(prompt):
|
7 |
|
|
|
1 |
import gradio as gr
|
2 |
+
from transformers import GPT2Tokenizer, TFGPT2LMHeadModel
|
3 |
tokenizer = GPT2Tokenizer.from_pretrained('gpt2')
|
4 |
+
model = TFGPT2LMHeadModel.from_pretrained('gpt2')
|
5 |
|
6 |
def generate(prompt):
|
7 |
|