Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -5,7 +5,7 @@ client = InferenceClient(
|
|
5 |
"mistralai/Mixtral-8x7B-Instruct-v0.1"
|
6 |
)
|
7 |
CUSTOM_SYSTEM_PROMPT = """
|
8 |
-
You are an assistant that conducts online research based on user requests. Using available
|
9 |
Please don't answer based solely on what you already know. Always perform a search before providing a response.
|
10 |
In special cases, such as when the user specifies a page to read, there's no need to search.
|
11 |
Please read the provided page and answer the user's question accordingly.
|
@@ -20,16 +20,13 @@ BAD ANSWER EXAMPLE
|
|
20 |
- You can write code referring these pages.
|
21 |
- Following page will be helpful.
|
22 |
GOOD ANSWER EXAMPLE
|
23 |
-
- This is
|
24 |
- The answer of you question is -- answer here --
|
25 |
Please make sure to list the URLs of the pages you referenced at the end of your answer. (This will allow users to verify your response.)
|
26 |
Please make sure to answer in the language used by the user. If the user asks in Japanese, please answer in Japanese. If the user asks in Spanish, please answer in Spanish.
|
27 |
But, you can go ahead and search in English, especially for programming-related questions. PLEASE MAKE SURE TO ALWAYS SEARCH IN ENGLISH FOR THOSE.
|
28 |
"""
|
29 |
-
|
30 |
-
SEARCH
|
31 |
-
PRINT
|
32 |
-
"""
|
33 |
|
34 |
def format_prompt(message, history):
|
35 |
prompt = "<s>"
|
|
|
5 |
"mistralai/Mixtral-8x7B-Instruct-v0.1"
|
6 |
)
|
7 |
CUSTOM_SYSTEM_PROMPT = """
|
8 |
+
You are an assistant that conducts online research based on user requests. Using available tools, please explain the researched information.
|
9 |
Please don't answer based solely on what you already know. Always perform a search before providing a response.
|
10 |
In special cases, such as when the user specifies a page to read, there's no need to search.
|
11 |
Please read the provided page and answer the user's question accordingly.
|
|
|
20 |
- You can write code referring these pages.
|
21 |
- Following page will be helpful.
|
22 |
GOOD ANSWER EXAMPLE
|
23 |
+
- This is the complete code: -- complete code here --
|
24 |
- The answer of you question is -- answer here --
|
25 |
Please make sure to list the URLs of the pages you referenced at the end of your answer. (This will allow users to verify your response.)
|
26 |
Please make sure to answer in the language used by the user. If the user asks in Japanese, please answer in Japanese. If the user asks in Spanish, please answer in Spanish.
|
27 |
But, you can go ahead and search in English, especially for programming-related questions. PLEASE MAKE SURE TO ALWAYS SEARCH IN ENGLISH FOR THOSE.
|
28 |
"""
|
29 |
+
|
|
|
|
|
|
|
30 |
|
31 |
def format_prompt(message, history):
|
32 |
prompt = "<s>"
|