Spaces:
Runtime error
Runtime error
use remote repo
Browse files
app.py
CHANGED
@@ -4,7 +4,7 @@ from transformers import AutoModelForCausalLM, AutoTokenizer
|
|
4 |
|
5 |
device = 'cuda' if torch.cuda.is_available() else 'cpu'
|
6 |
|
7 |
-
model = AutoModelForCausalLM.from_pretrained("
|
8 |
|
9 |
model.to(device)
|
10 |
|
@@ -26,5 +26,5 @@ def detect(text_in, max_length):
|
|
26 |
return text
|
27 |
|
28 |
|
29 |
-
iface = gr.Interface(fn=detect, inputs=[gr.Textbox(), gr.Slider(
|
30 |
iface.launch()
|
|
|
4 |
|
5 |
device = 'cuda' if torch.cuda.is_available() else 'cpu'
|
6 |
|
7 |
+
model = AutoModelForCausalLM.from_pretrained("saltacc/RandomPrompt-v1")
|
8 |
|
9 |
model.to(device)
|
10 |
|
|
|
26 |
return text
|
27 |
|
28 |
|
29 |
+
iface = gr.Interface(fn=detect, inputs=[gr.Textbox(), gr.Slider(100, 200, default=120)], outputs=gr.TextArea())
|
30 |
iface.launch()
|