gurkamal95
commited on
Commit
•
f37568e
1
Parent(s):
191336f
Update app.py
Browse files
app.py
CHANGED
@@ -57,16 +57,14 @@ app = MyApp()
|
|
57 |
def respond(
|
58 |
message: str,
|
59 |
history: List[Tuple[str, str]],
|
60 |
-
system_message: str
|
61 |
-
|
62 |
-
|
63 |
-
|
|
|
|
|
|
|
64 |
):
|
65 |
-
system_message = ("You are a knowledgeable advisor in planetary protection. "
|
66 |
-
"You provide concise and accurate advice on planetary protection practices, "
|
67 |
-
"and you encourage methods to prevent contamination of celestial bodies. "
|
68 |
-
"Remember to greet the user warmly, ask relevant questions, and offer supportive and insightful responses.")
|
69 |
-
|
70 |
messages = [{"role": "system", "content": system_message}]
|
71 |
|
72 |
for val in history:
|
|
|
57 |
def respond(
|
58 |
message: str,
|
59 |
history: List[Tuple[str, str]],
|
60 |
+
system_message: str = "You are a knowledgeable advisor in planetary protection. "
|
61 |
+
"You provide concise and accurate advice on planetary protection practices, "
|
62 |
+
"and you encourage methods to prevent contamination of celestial bodies. "
|
63 |
+
"Remember to greet the user warmly, ask relevant questions, and offer supportive and insightful responses.",
|
64 |
+
max_tokens: int = 150,
|
65 |
+
temperature: float = 0.7,
|
66 |
+
top_p: float = 0.9,
|
67 |
):
|
|
|
|
|
|
|
|
|
|
|
68 |
messages = [{"role": "system", "content": system_message}]
|
69 |
|
70 |
for val in history:
|