YoniFriedman commited on
Commit
155e345
·
verified ·
1 Parent(s): a8d8112

Updating prompt

Browse files
Files changed (1) hide show
  1. app.py +15 -12
app.py CHANGED
@@ -51,24 +51,27 @@ def nishauri(question: str, conversation_history: list[str]):
51
 
52
  background = ("The person who asked the question is a person living with HIV."
53
  " If the person says sasa or niaje, that is swahili slang for hello."
54
- " Recognize that they already have HIV and do not suggest that they have to get tested"
55
- " for HIV or take post-exposure prophylaxis, as that is not relevant, though their partners perhaps should."
56
- " Do not suggest anything that is not relevant to someone who already has HIV."
57
- " Do not mention in the response that the person is living with HIV."
58
- " The following information about viral loads is authoritative for any question about viral loads:"
59
- " Under 50 copies/ml is low detectable level,"
60
- " 50 - 199 copies/ml is low level viremia, 200 - 999 is high level viremia, and "
61
- " 1000 and above is suspected treatment failure."
62
- " A high viral load or non-suppressed viral load is any viral load above 200 copies/ml."
63
- " A suppressed viral load is one below 200 copies / ml.")
 
64
 
65
- question_final = (
66
  f" The user previously asked and answered the following: {context}. "
67
  f" The user just asked the following question: {question}."
68
  f" Please use the following content to generate a response: {source0} {source1} {source2}."
69
- f" Please update the response provided only if needed, based on the following background information {background}."
70
  " Keep answers brief and limited to the question that was asked."
71
  " Do not provide information the user did not ask about. If they start with a greeting, just greet them in return and don't share anything else."
 
 
72
  )
73
 
74
  completion = client.chat.completions.create(
 
51
 
52
  background = ("The person who asked the question is a person living with HIV."
53
  " If the person says sasa or niaje, that is swahili slang for hello."
54
+ " They are asking questions about HIV. Do not talk about anything that is not related to HIV. "
55
+ " Recognize that they already have HIV and do not suggest that they have to get tested"
56
+ " for HIV or take post-exposure prophylaxis, as that is not relevant, though their partners perhaps should."
57
+ " Do not suggest anything that is not relevant to someone who already has HIV."
58
+ " Do not mention in the response that the person is living with HIV."
59
+ " The following information about viral loads is authoritative for any question about viral loads:"
60
+ " Under 50 copies/ml is low detectable level,"
61
+ " 50 - 199 copies/ml is low level viremia, 200 - 999 is high level viremia, and "
62
+ " 1000 and above is suspected treatment failure."
63
+ " A high viral load or non-suppressed viral load is any viral load above 200 copies/ml."
64
+ " A suppressed viral load is one below 200 copies / ml.")
65
 
66
+ question_final = (
67
  f" The user previously asked and answered the following: {context}. "
68
  f" The user just asked the following question: {question}."
69
  f" Please use the following content to generate a response: {source0} {source1} {source2}."
70
+ f" Please consider the following background information when generating a response: {background}."
71
  " Keep answers brief and limited to the question that was asked."
72
  " Do not provide information the user did not ask about. If they start with a greeting, just greet them in return and don't share anything else."
73
+ " Do not change the subject or address anything the user didn't directly ask about."
74
+ " If they respond with an acknowledgement such as 'ok' or 'thanks', simply thank them ask if there is anything else that you can help with."
75
  )
76
 
77
  completion = client.chat.completions.create(