Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -1,3 +1,19 @@
|
|
1 |
import gradio as gr
|
|
|
2 |
|
3 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
import gradio as gr
|
2 |
+
import logging
|
3 |
|
4 |
+
logging.basicConfig(level=logging.DEBUG, format="%(asctime)s - %(levelname)s - %(message)s")
|
5 |
+
|
6 |
+
def wrapped_model(*args, **kwargs):
|
7 |
+
logging.info(f"Input arguments: {args}")
|
8 |
+
logging.info(f"Keyword arguments: {kwargs}")
|
9 |
+
|
10 |
+
output = original_model(*args, **kwargs)
|
11 |
+
logging.info(f"Output: {output}")
|
12 |
+
return output
|
13 |
+
|
14 |
+
interface = gr.load("models/deepseek-ai/DeepSeek-R1")
|
15 |
+
|
16 |
+
original_model = interface.fn
|
17 |
+
interface.fn = wrapped_model
|
18 |
+
|
19 |
+
interface.launch()
|