Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -32,37 +32,11 @@ API_URL = "https://aivisions.no/data/daysoff/api/v1/booking/"
|
|
32 |
# Provide a conversational answer.
|
33 |
# This way you directly address the user's question in a manner that reflects the professionalism and warmth
|
34 |
# of a customer support representative (female).
|
|
|
35 |
daysoff_assistant_template = """
|
36 |
-
You are a customer support assistant for Daysoff (โDaysoff Kundeservice AI Supportโ) and help users retrieve their booking information based on a
|
37 |
-
|
38 |
-
|
39 |
-
# examples
|
40 |
-
Norwegian Terms:
|
41 |
-
- booking
|
42 |
-
- bookingnr
|
43 |
-
- bestillingsnummer
|
44 |
-
- bookingen
|
45 |
-
- ordrenummer
|
46 |
-
- bookingreferanse
|
47 |
-
- bestilling
|
48 |
-
- booket
|
49 |
-
English Terms:
|
50 |
-
- reservation
|
51 |
-
- reservation number
|
52 |
-
- order number
|
53 |
-
- booking ID
|
54 |
-
Polish Terms:
|
55 |
-
- rezerwacji
|
56 |
-
- rezerwacja
|
57 |
-
- identyfikacyjny pลatnoลci
|
58 |
-
|
59 |
-
If there is no booking information available for a booking ID, just say so and politely suggest they contact **[email protected]**
|
60 |
-
to enquire further.
|
61 |
-
|
62 |
-
Maintain a conversational and professional tone, **reflecting the warmth of
|
63 |
-
a female customer support representative archetype.**
|
64 |
-
By default, you answer in **Norwegian**.
|
65 |
-
|
66 |
Chat History: {chat_history}
|
67 |
Question: {question}
|
68 |
Answer:
|
@@ -72,7 +46,6 @@ daysoff_assistant_prompt = PromptTemplate(
|
|
72 |
template=daysoff_assistant_template,
|
73 |
)
|
74 |
|
75 |
-
|
76 |
# =============================================================================================================
|
77 |
class APIConnectionError(Exception):
|
78 |
"""Raised when API connection fails"""
|
|
|
32 |
# Provide a conversational answer.
|
33 |
# This way you directly address the user's question in a manner that reflects the professionalism and warmth
|
34 |
# of a customer support representative (female).
|
35 |
+
# If users have more in-depth queries about their booking information, politely suggest they contact **[email protected]** to enquire further.
|
36 |
daysoff_assistant_template = """
|
37 |
+
You are a customer support assistant for Daysoff (โDaysoff Kundeservice AI Supportโ) and help users retrieve their booking information based on a
|
38 |
+
bookingnummer they give you. You should concisely use the term โbookingnummerโ. Maintain a conversational and professional tone, **reflecting the warmth of
|
39 |
+
a female customer support representative archetype.** By default, you answer in **Norwegian**.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
40 |
Chat History: {chat_history}
|
41 |
Question: {question}
|
42 |
Answer:
|
|
|
46 |
template=daysoff_assistant_template,
|
47 |
)
|
48 |
|
|
|
49 |
# =============================================================================================================
|
50 |
class APIConnectionError(Exception):
|
51 |
"""Raised when API connection fails"""
|