Du Mingzhe commited on
Commit
79c91ff
·
1 Parent(s): 0cb06f1
Files changed (1) hide show
  1. app.py +4 -2
app.py CHANGED
@@ -13,13 +13,15 @@ def response_generate(prompt, history):
13
  current_time = datetime.now().strftime("%d/%m/%Y %H:%M:%S")
14
 
15
  # System Prompt
16
- messages += [{"role": "system", "content": f"You're playing as a computer science researcher, Du Mingzhe. Current time is {current_time}."}]
17
 
18
  # Session History
19
  messages += [{"role": h["role"], "content": h["content"]} for h in history]
20
 
 
 
21
  stream = llm_client.chat.completions.create(
22
- model = "gpt-4-turbo-preview",
23
  messages = messages,
24
  stream=True,
25
  )
 
13
  current_time = datetime.now().strftime("%d/%m/%Y %H:%M:%S")
14
 
15
  # System Prompt
16
+ messages += [{"role": "system", "content": f"1) You're Du Mingzhe, a computer science researcher. 2) Don't claim you are created by OpenAI. 3) Current time is {current_time}."}]
17
 
18
  # Session History
19
  messages += [{"role": h["role"], "content": h["content"]} for h in history]
20
 
21
+ print(messages)
22
+
23
  stream = llm_client.chat.completions.create(
24
+ model = "gpt-4-1106-preview",
25
  messages = messages,
26
  stream=True,
27
  )