Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -40,7 +40,7 @@ def check_safety(text):
|
|
| 40 |
return "Unsafe" if pred[0] == 1 else "Safe"
|
| 41 |
|
| 42 |
|
| 43 |
-
@spaces.GPU(duration=
|
| 44 |
def inference(prompt: str, max_tokens: int = 256) -> str:
|
| 45 |
model.to("cuda") # Move to GPU inside decorated function
|
| 46 |
|
|
|
|
| 40 |
return "Unsafe" if pred[0] == 1 else "Safe"
|
| 41 |
|
| 42 |
|
| 43 |
+
@spaces.GPU(duration=60)
|
| 44 |
def inference(prompt: str, max_tokens: int = 256) -> str:
|
| 45 |
model.to("cuda") # Move to GPU inside decorated function
|
| 46 |
|