Spaces:
Runtime error
Runtime error
Commit
·
8bb0a31
1
Parent(s):
0e3b32d
update prompt
Browse files
app.py
CHANGED
|
@@ -651,6 +651,12 @@ You must always check vector database first and try to answer the question based
|
|
| 651 |
Only when there is no information available from vector database, you can search information by using other tools.
|
| 652 |
You have access to the following tools:"""
|
| 653 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 654 |
FORMAT_INSTRUCTIONS = """Use the following format:
|
| 655 |
|
| 656 |
Question: the input question you must answer
|
|
@@ -750,7 +756,7 @@ agent_ZEROSHOT_REACT_2 = initialize_agent(tools_remote, GPTfake,
|
|
| 750 |
max_iterations = int(os.environ["max_iterations"]),
|
| 751 |
early_stopping_method="generate",
|
| 752 |
agent_kwargs={
|
| 753 |
-
'prefix':
|
| 754 |
'format_instructions': FORMAT_INSTRUCTIONS_2,
|
| 755 |
'suffix': SUFFIX,
|
| 756 |
# 'input_variables': input_variables,
|
|
@@ -1308,7 +1314,7 @@ with gr.Blocks() as demo:
|
|
| 1308 |
label="SELECT AI AGENT",
|
| 1309 |
scale= 2,
|
| 1310 |
show_label = True,
|
| 1311 |
-
value="
|
| 1312 |
)
|
| 1313 |
voice_input = gr.Audio(
|
| 1314 |
source="microphone",
|
|
|
|
| 651 |
Only when there is no information available from vector database, you can search information by using other tools.
|
| 652 |
You have access to the following tools:"""
|
| 653 |
|
| 654 |
+
PREFIX_2 = """You are a helpful AI assistant. Your mission is to answer the following request as best as you can with detail information and explanation.
|
| 655 |
+
You must always check vector database first and try to answer the question based on the information found in vector database only.
|
| 656 |
+
Only when there is no information available from vector database, you can search information by using other tools.
|
| 657 |
+
You have access to the following tools:"""
|
| 658 |
+
|
| 659 |
+
|
| 660 |
FORMAT_INSTRUCTIONS = """Use the following format:
|
| 661 |
|
| 662 |
Question: the input question you must answer
|
|
|
|
| 756 |
max_iterations = int(os.environ["max_iterations"]),
|
| 757 |
early_stopping_method="generate",
|
| 758 |
agent_kwargs={
|
| 759 |
+
'prefix': PREFIX_2,
|
| 760 |
'format_instructions': FORMAT_INSTRUCTIONS_2,
|
| 761 |
'suffix': SUFFIX,
|
| 762 |
# 'input_variables': input_variables,
|
|
|
|
| 1314 |
label="SELECT AI AGENT",
|
| 1315 |
scale= 2,
|
| 1316 |
show_label = True,
|
| 1317 |
+
value="Zero Short React 2",
|
| 1318 |
)
|
| 1319 |
voice_input = gr.Audio(
|
| 1320 |
source="microphone",
|