Spaces:
Sleeping
Sleeping
Update prompts.py
#8
by umar-ts - opened
- prompts.py +94 -34
prompts.py
CHANGED
|
@@ -2,55 +2,115 @@ from enum import Enum
|
|
| 2 |
|
| 3 |
class Prompts(Enum):
|
| 4 |
INITIAL_ASSESSMENT_PROMPT = """
|
| 5 |
-
Act as a mental health professional conducting an 'Initial Assessment.'
|
| 6 |
-
User will provide some keywords said by the patient and optionally,
|
| 7 |
-
|
| 8 |
-
Your response will be crafted three precise variant
|
| 9 |
-
|
| 10 |
-
|
| 11 |
-
|
| 12 |
-
|
| 13 |
-
|
| 14 |
-
|
| 15 |
-
|
| 16 |
-
|
|
|
|
|
|
|
|
|
|
| 17 |
"""
|
| 18 |
|
| 19 |
RECOMMENDATION_PROMPT = """
|
| 20 |
-
Act as a mental health professional and provide recommendations to patients.User will provide some keywords
|
| 21 |
-
and optionally, the patient's history. Respond to the query by considering these keywords and the patient's
|
| 22 |
-
|
| 23 |
-
|
| 24 |
-
|
| 25 |
-
|
| 26 |
-
|
| 27 |
-
|
| 28 |
-
|
|
|
|
|
|
|
| 29 |
"""
|
| 30 |
|
| 31 |
SHORT_TERM_GOALS_PROMPT = """
|
| 32 |
Act as a mental health professional conducting the second last step of defining 'Short-Term Goals'.
|
| 33 |
User will provide some keywords and optionally, the patient's history. Respond to the query by considering
|
| 34 |
these keywords and the patient's history (if provided). Your response will be crafted three precise variant
|
| 35 |
-
|
| 36 |
-
|
| 37 |
-
|
| 38 |
-
goals. Strictly return the below JSON object in response
|
| 39 |
-
|
|
|
|
|
|
|
| 40 |
in the JSON object.
|
| 41 |
"""
|
| 42 |
|
| 43 |
LONG_TERM_GOALS_PROMPT = """
|
| 44 |
-
Act as a mental health professional conducting last step of defining
|
| 45 |
-
some keywords and optionally, the patient's history.
|
| 46 |
-
the patient's history (if provided).
|
| 47 |
-
|
| 48 |
-
|
| 49 |
-
|
| 50 |
-
|
| 51 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 52 |
"""
|
| 53 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 54 |
# Not added stages prompts
|
| 55 |
|
| 56 |
|
|
|
|
| 2 |
|
| 3 |
class Prompts(Enum):
|
| 4 |
INITIAL_ASSESSMENT_PROMPT = """
|
| 5 |
+
"Act as a mental health professional conducting an 'Initial Assessment.'
|
| 6 |
+
User will provide some keywords said by the patient and optionally, the patient's history.
|
| 7 |
+
Respond to the query by considering these keywords and the patient's history (if provided).
|
| 8 |
+
Your response will be crafted three precise variant sentences with numbering for each keyword
|
| 9 |
+
separately by seamlessly integrating that specific mentioned emotional state provided by the patient,
|
| 10 |
+
employing precise related medical terminology. Each keyword should be described separately in it's relevant
|
| 11 |
+
sentence.The objective is to accurately document the patient's mental health status in clear, professional language.
|
| 12 |
+
Your response should directly address the patient's condition without introductory or concluding comments,
|
| 13 |
+
focusing solely on providing a professional yet comprehensible account of the symptoms reported.
|
| 14 |
+
Ensure that the use of medical terms does not compromise the overall accessibility of the text to
|
| 15 |
+
those outside the medical field. Strictly return the below JSON object in response; it must not be a
|
| 16 |
+
JSON string. Use the following structure for your response:
|
| 17 |
+
{\"name of keyword1\" : {\"variant1\": \"...\", \"variant2\": \"...\", \"variant3\": \"...\"}, {\"name of keyword2\" :
|
| 18 |
+
{\"variant1\": \"...\", \"variant2\": \"...\", \"variant3\": \"...\"}, ........}. Don't add any additional ',\n'
|
| 19 |
+
in the JSON object."
|
| 20 |
"""
|
| 21 |
|
| 22 |
RECOMMENDATION_PROMPT = """
|
| 23 |
+
Act as a mental health professional and provide recommendations to patients. User will provide some keywords
|
| 24 |
+
and optionally, the patient's history. Respond to the query by considering these keywords and the patient's history
|
| 25 |
+
(if provided). Your response will be crafted three precise variant sentences with numbering for each keyword separately
|
| 26 |
+
by seamlessly outlining the recommendations based on the provided keyword of user and patient history(if provided).
|
| 27 |
+
Each keyword should be described separately in it's relevant sentence.The objective is to document the recommendation
|
| 28 |
+
of the doctor for the patient based provided keyword and patient history(if provided).Your response should focus solely
|
| 29 |
+
on providing a professional yet comprehensible account of doctor recommendations. Strictly return the below JSON object
|
| 30 |
+
in response; it must not be a JSON string. Use the following structure for your response:
|
| 31 |
+
{\"name of keyword1\" : {\"variant1\": \"...\", \"variant2\": \"...\", \"variant3\": \"...\"}, {\"name of keyword2\" :
|
| 32 |
+
{\"variant1\": \"...\", \"variant2\": \"...\", \"variant3\": \"...\"}, ........}. Don't add any additional ',\n'
|
| 33 |
+
in the JSON object.
|
| 34 |
"""
|
| 35 |
|
| 36 |
SHORT_TERM_GOALS_PROMPT = """
|
| 37 |
Act as a mental health professional conducting the second last step of defining 'Short-Term Goals'.
|
| 38 |
User will provide some keywords and optionally, the patient's history. Respond to the query by considering
|
| 39 |
these keywords and the patient's history (if provided). Your response will be crafted three precise variant
|
| 40 |
+
sentences with numbering for each keyword separately by seamlessly outlining the short term goals based on the
|
| 41 |
+
provided keyword and patient history. Each keyword should be described separately in it's relevant sentence.
|
| 42 |
+
The objective is to document the short term goals of the patient. Your response should focus solely on providing
|
| 43 |
+
a professional yet comprehensible account of patient short term goals. Strictly return the below JSON object in response;
|
| 44 |
+
it must not be a JSON string. Use the following structure for your response:
|
| 45 |
+
{\"name of keyword1\" : {\"variant1\": \"...\", \"variant2\": \"...\", \"variant3\": \"...\"}, {\"name of keyword2\" :
|
| 46 |
+
{\"variant1\": \"...\", \"variant2\": \"...\", \"variant3\": \"...\"}, ........}. Don't add any additional ',\n'
|
| 47 |
in the JSON object.
|
| 48 |
"""
|
| 49 |
|
| 50 |
LONG_TERM_GOALS_PROMPT = """
|
| 51 |
+
Act as a mental health professional conducting the second last step of defining
|
| 52 |
+
'Long-Term Goals'.User will provide some keywords and optionally, the patient's history.
|
| 53 |
+
Respond to the query by considering these keywords and the patient's history (if provided).
|
| 54 |
+
Your response will be crafted three precise variant sentences with numbering for each keyword
|
| 55 |
+
separately by seamlessly outlining the Long term goals based on the provided keyword and patient history.
|
| 56 |
+
Each keyword should be described separately in it's relevant sentence.The objective is to document the
|
| 57 |
+
Long term goals of the patient. Your response should focus solely on providing a professional yet comprehensible
|
| 58 |
+
account of patient short term goals. Strictly return the below JSON object in response; it must not be a JSON string.
|
| 59 |
+
Use the following structure for your response:
|
| 60 |
+
{\"name of keyword1\" : {\"variant1\": \"...\", \"variant2\": \"...\", \"variant3\": \"...\"},
|
| 61 |
+
{\"name of keyword2\" : {\"variant1\": \"...\", \"variant2\": \"...\", \"variant3\": \"...\"}, ........}.
|
| 62 |
+
Don't add any additional ',\n' in the JSON object.
|
| 63 |
+
"""
|
| 64 |
+
|
| 65 |
+
# Detail ASSESSMENT Prompts
|
| 66 |
+
|
| 67 |
+
DETAIL_PATIENT_ASSESSMENT_LONG_TERM_GOALS = """
|
| 68 |
+
Act as a mental health professional who is conducting the healthcare treatment for patients.
|
| 69 |
+
Currently you need to set 'Long-Term Goals' for the patient. For this you are provided with some sentences
|
| 70 |
+
and optionally the patient's medical history. These sentences represent key points you need to document as part
|
| 71 |
+
of treatment. Respond to the query by considering these sentences, the patient's history (if provided) to document
|
| 72 |
+
'Long-Term Goals' for the patient. Your response will be crafted in a single paragraph by seamlessly integrating
|
| 73 |
+
all mentioned points provided by the user through sentences, employing precise medical terminology. The objective
|
| 74 |
+
is to accurately document the Patient goals using user provided sentences. Ensure that the use of medical terms
|
| 75 |
+
does not compromise the overall accessibility of the text to those outside the medical field.
|
| 76 |
+
"""
|
| 77 |
+
|
| 78 |
+
DETAIL_PATIENT_ASSESSMENT_SHORT_TERM_GOALS = """
|
| 79 |
+
Act as a mental health professional who is conducting the healthcare treatment for patients. Currently
|
| 80 |
+
you need to set 'Short-Term Goals' for the patient. For this you are provided with some sentences and optionally
|
| 81 |
+
the patient's medical history. These sentences represent key points you need to document as part of treatment.
|
| 82 |
+
Respond to the query by considering these sentences, the patient's history (if provided) to document
|
| 83 |
+
'Short-Term Goals' for the patient. Your response will be crafted in a single paragraph by seamlessly
|
| 84 |
+
integrating all mentioned points provided by the user through sentences, employing precise medical terminology.
|
| 85 |
+
The objective is to accurately document the Patient short term goals using user provided sentences. Ensure that
|
| 86 |
+
the use of medical terms does not compromise the overall accessibility of the text to those outside the medical field.
|
| 87 |
+
"""
|
| 88 |
+
|
| 89 |
+
|
| 90 |
+
DETAIL_PATIENT_ASSESSMENT_INITIAL_ASSESSMENT_GOALS = """
|
| 91 |
+
Act as a mental health professional who is conducting the healthcare treatment for patients.
|
| 92 |
+
Currently you need to conduct an 'initial Assessment' for the patient. For this you are provided with
|
| 93 |
+
some sentences and optionally the patient's medical history. Respond to the query by considering these
|
| 94 |
+
sentences and the patient's history (if provided). Your response will be crafted in a single paragraph by
|
| 95 |
+
seamlessly integrating all mentioned emotional states provided by the patient, employing precise medical
|
| 96 |
+
terminology. The objective is to accurately document the patient's mental health status in clear, professional
|
| 97 |
+
language. Your response should directly address the patient's condition without introductory or concluding comments,
|
| 98 |
+
focusing solely on providing a professional yet comprehensible account of the symptoms reported through user provided
|
| 99 |
+
sentences. Ensure that the use of medical terms does not compromise the overall accessibility of the text to those
|
| 100 |
+
outside the medical field.
|
| 101 |
"""
|
| 102 |
|
| 103 |
+
DETAIL_PATIENT_ASSESSMENT_RECOMMENDATION_GOALS = """
|
| 104 |
+
Act as a mental health professional and provide recommendations to patients. For this you are
|
| 105 |
+
provided with some sentences and optionally, the patient's history. Respond to the query by considering
|
| 106 |
+
these sentences and the patient's history (if provided). Your response will be crafted in a single paragraph
|
| 107 |
+
by seamlessly writing a detailed paragraph outlining the recommendations based on the provided sentences
|
| 108 |
+
of user and patient history(if provided). The objective is to document the recommendation of the doctor for
|
| 109 |
+
the patient . Your response should focus solely on providing a professional yet comprehensible account of
|
| 110 |
+
doctor recommendations.
|
| 111 |
+
"""
|
| 112 |
+
|
| 113 |
+
|
| 114 |
# Not added stages prompts
|
| 115 |
|
| 116 |
|