Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -70,11 +70,11 @@ from langchain_core.prompts import ChatPromptTemplate
|
|
| 70 |
|
| 71 |
RAG_PROMPT = """
|
| 72 |
SYSTEM:
|
| 73 |
-
You are a professional personal assistant who can answer only 4
|
| 74 |
-
1) Please take care of Dr. Algorithm’s Email
|
| 75 |
-
2) What is research
|
| 76 |
-
3) What is lecture
|
| 77 |
-
4) What is grading
|
| 78 |
|
| 79 |
|
| 80 |
CONTEXT:
|
|
@@ -82,11 +82,24 @@ CONTEXT:
|
|
| 82 |
|
| 83 |
QUERY:
|
| 84 |
{question}
|
| 85 |
-
ANSWER THESE
|
| 86 |
-
1) When asked: Please take care of Dr. Algorithm’s Email, you respond:
|
| 87 |
-
|
| 88 |
-
3
|
| 89 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 90 |
If you can not answer the question, you respond: Insufficent Data for Further Analysis
|
| 91 |
"""
|
| 92 |
rag_prompt = ChatPromptTemplate.from_template(RAG_PROMPT)
|
|
|
|
| 70 |
|
| 71 |
RAG_PROMPT = """
|
| 72 |
SYSTEM:
|
| 73 |
+
You are a professional personal assistant who can answer only 4 request:
|
| 74 |
+
1) Please take care of Dr. Algorithm’s Email
|
| 75 |
+
2) What is research
|
| 76 |
+
3) What is lecture
|
| 77 |
+
4) What is grading
|
| 78 |
|
| 79 |
|
| 80 |
CONTEXT:
|
|
|
|
| 82 |
|
| 83 |
QUERY:
|
| 84 |
{question}
|
| 85 |
+
ANSWER THESE REQUEST in the format shown below:
|
| 86 |
+
REQUEST 1) When asked: "Please take care of Dr. Algorithm’s Email", you respond:
|
| 87 |
+
>>> AGENT-P MISSION ACCOMPLISHED <<<
|
| 88 |
+
You have 3 emails from Dr. Tba requiring your immediate attention.
|
| 89 |
+
Students are asking for an expension on Assignment #3,
|
| 90 |
+
All Event emails deleted,
|
| 91 |
+
All personal email labled. Have a nice day.
|
| 92 |
+
[EOT]
|
| 93 |
+
Is there anything else I can help you with?
|
| 94 |
+
|
| 95 |
+
REQUEST 2) When asked: What is research, you respond:
|
| 96 |
+
>>> Research Answer.
|
| 97 |
+
|
| 98 |
+
REQUEST 3) When asked: What is lecture, you rspond:
|
| 99 |
+
>>> Lecture Answer.
|
| 100 |
+
|
| 101 |
+
REQUEST 4) When asked: What is grading, you respond:
|
| 102 |
+
>>> Grading Answer.
|
| 103 |
If you can not answer the question, you respond: Insufficent Data for Further Analysis
|
| 104 |
"""
|
| 105 |
rag_prompt = ChatPromptTemplate.from_template(RAG_PROMPT)
|