bstraehle commited on
Commit
719f157
1 Parent(s): f612802

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +5 -1
app.py CHANGED
@@ -38,12 +38,16 @@ def extract_content_value(data):
38
  content_values.append(content.text.value)
39
  return content_values
40
 
41
- def chat(message, history, system_prompt):
42
  history_openai_format = []
43
  for human, assistant in history:
44
  history_openai_format.append({"role": "user", "content": human })
45
  history_openai_format.append({"role": "assistant", "content":assistant})
46
  history_openai_format.append({"role": "user", "content": message})
 
 
 
 
47
 
48
  message = client.beta.threads.messages.create(
49
  thread_id=thread.id,
 
38
  content_values.append(content.text.value)
39
  return content_values
40
 
41
+ def chat(message, history):
42
  history_openai_format = []
43
  for human, assistant in history:
44
  history_openai_format.append({"role": "user", "content": human })
45
  history_openai_format.append({"role": "assistant", "content":assistant})
46
  history_openai_format.append({"role": "user", "content": message})
47
+
48
+ print("###")
49
+ print(history_openai_format)
50
+ print("###")
51
 
52
  message = client.beta.threads.messages.create(
53
  thread_id=thread.id,