kenny
commited on
Commit
·
ea87e63
1
Parent(s):
945be61
Update system prompt
Browse files- .env.sample +0 -1
- app.py +3 -3
- requirements.txt +5 -5
.env.sample
DELETED
@@ -1 +0,0 @@
|
|
1 |
-
OPENAI_API_KEY=###
|
|
|
|
app.py
CHANGED
@@ -11,7 +11,7 @@ from dotenv import load_dotenv
|
|
11 |
load_dotenv()
|
12 |
|
13 |
# ChatOpenAI Templates
|
14 |
-
system_template = """You are a helpful assistant who
|
15 |
"""
|
16 |
|
17 |
user_template = """{input}
|
@@ -22,9 +22,9 @@ Think through your response step by step.
|
|
22 |
@cl.on_chat_start # marks a function that will be executed at the start of a user session
|
23 |
async def start_chat():
|
24 |
settings = {
|
25 |
-
"model": "gpt-
|
26 |
"temperature": 0,
|
27 |
-
"max_tokens":
|
28 |
"top_p": 1,
|
29 |
"frequency_penalty": 0,
|
30 |
"presence_penalty": 0,
|
|
|
11 |
load_dotenv()
|
12 |
|
13 |
# ChatOpenAI Templates
|
14 |
+
system_template = """You are a helpful assistant who focuses on communicating clearly and concisely, making sure to pay careful attention to the user's input and responding appropriately. You specialize in educating new developers on the basics of programming in a way that is easy to understand and follow. Your audience consists of non-technical students who are interested in starting careers as developers. Rather than trying to provide all possible dertails of the user's question, you focus on the essentials and encourage the user to ask follow-up questions if they need more information and to clarify their thinking.
|
15 |
"""
|
16 |
|
17 |
user_template = """{input}
|
|
|
22 |
@cl.on_chat_start # marks a function that will be executed at the start of a user session
|
23 |
async def start_chat():
|
24 |
settings = {
|
25 |
+
"model": "gpt-4o-mini",
|
26 |
"temperature": 0,
|
27 |
+
"max_tokens": 1000,
|
28 |
"top_p": 1,
|
29 |
"frequency_penalty": 0,
|
30 |
"presence_penalty": 0,
|
requirements.txt
CHANGED
@@ -1,5 +1,5 @@
|
|
1 |
-
chainlit
|
2 |
-
cohere
|
3 |
-
openai
|
4 |
-
tiktoken
|
5 |
-
python-dotenv
|
|
|
1 |
+
chainlit
|
2 |
+
cohere
|
3 |
+
openai
|
4 |
+
tiktoken
|
5 |
+
python-dotenv
|