Spaces:
Running
on
Zero
Running
on
Zero
Update app.py
Browse files
app.py
CHANGED
@@ -83,9 +83,9 @@ def ollama_func(command):
|
|
83 |
}
|
84 |
if c1 in function_map:
|
85 |
function_map.get(c1)
|
86 |
-
return [
|
87 |
else:
|
88 |
-
return [
|
89 |
|
90 |
@spaces.GPU()
|
91 |
def launch():
|
@@ -99,7 +99,7 @@ def stream_chat(message: str, history: list, model: str, temperature: float, max
|
|
99 |
ollama_func(message)
|
100 |
else:
|
101 |
if not INIT_SIGN:
|
102 |
-
return
|
103 |
else:
|
104 |
launch()
|
105 |
conversation = []
|
|
|
83 |
}
|
84 |
if c1 in function_map:
|
85 |
function_map.get(c1)
|
86 |
+
return "", [("", f"Running {c1}")]
|
87 |
else:
|
88 |
+
return "", [("", "No supported command.")]
|
89 |
|
90 |
@spaces.GPU()
|
91 |
def launch():
|
|
|
99 |
ollama_func(message)
|
100 |
else:
|
101 |
if not INIT_SIGN:
|
102 |
+
return "", [(message, "Please Enter /init to initialize Ollama")]
|
103 |
else:
|
104 |
launch()
|
105 |
conversation = []
|