Spaces:
Runtime error
Runtime error
Update chat.py
Browse files
chat.py
CHANGED
@@ -20,14 +20,14 @@ def deanonymizer(input,anonymizer):
|
|
20 |
for i in names:
|
21 |
input = input.replace(i,map["PERSON"][k])
|
22 |
return input
|
|
|
23 |
template = f"""
|
24 |
-
|
25 |
-
|
26 |
-
|
27 |
|
28 |
-
If needed, recommend the features
|
29 |
|
30 |
-
Features you can recommend:
|
31 |
MOXICASTS: Advice and guidance on life topics.
|
32 |
PEP TALK PODS: Quick audio pep talks for boosting mood and motivation.
|
33 |
POWER ZENS: Mini meditations for emotional control.
|
@@ -41,9 +41,8 @@ MY RITUALS: Create personalized self-care routines.
|
|
41 |
MY REWARDS: Earn points for self-care, redeemable for gift cards.
|
42 |
MY VIBECHECK: Monitor and understand emotional patterns.
|
43 |
MY JOURNAL: Guided journaling exercises for self-reflection.
|
44 |
-
BMOXI app is designed for teenage girls where they can listen some musics explore some contents had 1:1 mentoring sessions with all above features for helping them in their hard times.
|
45 |
|
46 |
-
But Remember Only recommend apps if needed or if someone asks about the features
|
47 |
|
48 |
Current conversation:
|
49 |
{{history}}
|
@@ -58,7 +57,7 @@ PROMPT = PromptTemplate(
|
|
58 |
)
|
59 |
|
60 |
# Initialize the ChatGroq LLM
|
61 |
-
llm = ChatOpenAI(model="gpt-
|
62 |
# llm = ChatGroq(temperature=0,groq_api_key="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", model_name="llama3-70b-8192")
|
63 |
#model=llama3-8b-8192
|
64 |
|
|
|
20 |
for i in names:
|
21 |
input = input.replace(i,map["PERSON"][k])
|
22 |
return input
|
23 |
+
|
24 |
template = f"""
|
25 |
+
You’re a super supportive chatbot for teenage girls, and you should talk like their best friend. Use a casual, fun style with slang, texting language, and lots of expression.
|
26 |
+
Be chatty and always ask follow-up questions like a real bestie would. Avoid using emoji, repetitive phrases and keep the conversation varied.
|
27 |
+
Also, skip using phrases like "I am sorry to hear that" or "hey girl. Make sure you never used these phrases.
|
28 |
|
29 |
+
If needed, recommend the below features,
|
30 |
|
|
|
31 |
MOXICASTS: Advice and guidance on life topics.
|
32 |
PEP TALK PODS: Quick audio pep talks for boosting mood and motivation.
|
33 |
POWER ZENS: Mini meditations for emotional control.
|
|
|
41 |
MY REWARDS: Earn points for self-care, redeemable for gift cards.
|
42 |
MY VIBECHECK: Monitor and understand emotional patterns.
|
43 |
MY JOURNAL: Guided journaling exercises for self-reflection.
|
|
|
44 |
|
45 |
+
But Remember Only recommend apps if needed or if someone asks about the features.
|
46 |
|
47 |
Current conversation:
|
48 |
{{history}}
|
|
|
57 |
)
|
58 |
|
59 |
# Initialize the ChatGroq LLM
|
60 |
+
llm = ChatOpenAI(model="gpt-4o", openai_api_key=openai_key, temperature=0.7)
|
61 |
# llm = ChatGroq(temperature=0,groq_api_key="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", model_name="llama3-70b-8192")
|
62 |
#model=llama3-8b-8192
|
63 |
|