Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -20,6 +20,7 @@ def call_cohere_api(system_instruction, user_prompt):
|
|
20 |
}
|
21 |
|
22 |
# Append word limit instruction
|
|
|
23 |
user_prompt += "\n\nAnswer in 100 words or fewer."
|
24 |
payload = {
|
25 |
"model": "command-r-plus",
|
@@ -151,15 +152,6 @@ with gr.Blocks() as demo:
|
|
151 |
outputs=[user_input, persona1, output1, output2, output1_title, output2_title]
|
152 |
)
|
153 |
|
154 |
-
# Ask button for normal questions
|
155 |
-
# ask_button.click(
|
156 |
-
# fn=lambda p1, p2, q: (call_cohere_api(load_instruction(p1), q),
|
157 |
-
# call_cohere_api(load_instruction(p2), q)),
|
158 |
-
# inputs=[persona1, persona2, user_input],
|
159 |
-
# outputs=[output1, output2]
|
160 |
-
# )
|
161 |
-
|
162 |
-
|
163 |
ask_button.click(
|
164 |
fn=ask_with_titles,
|
165 |
inputs=[persona1, persona2, user_input],
|
|
|
20 |
}
|
21 |
|
22 |
# Append word limit instruction
|
23 |
+
user_prompt += "\n\nAnswer in a context of Bristol, UK ecosystem."
|
24 |
user_prompt += "\n\nAnswer in 100 words or fewer."
|
25 |
payload = {
|
26 |
"model": "command-r-plus",
|
|
|
152 |
outputs=[user_input, persona1, output1, output2, output1_title, output2_title]
|
153 |
)
|
154 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
155 |
ask_button.click(
|
156 |
fn=ask_with_titles,
|
157 |
inputs=[persona1, persona2, user_input],
|