Commit
·
faa1a8b
1
Parent(s):
17ae380
Update app.py
Browse files
app.py
CHANGED
@@ -161,7 +161,7 @@ def summarize_meeting(filepath):
|
|
161 |
|
162 |
messages = [
|
163 |
{"role": "system", "content": "Summarize this meeting transcript in the same language as the user's input."}]
|
164 |
-
messages.append({"role": "user", "content": prompt_request})
|
165 |
|
166 |
response = openai.ChatCompletion.create(
|
167 |
model="gpt-3.5-turbo",
|
@@ -178,10 +178,10 @@ def summarize_meeting(filepath):
|
|
178 |
# Consolidate these meeting summaries.
|
179 |
prompt_request = str(prompt_response)
|
180 |
|
181 |
-
if count_tokens(prompt_request)
|
182 |
# Summarize the text of the meeting transcripts.
|
183 |
messages = [{"role": "system", "content": "Consolidate, and summarize the text of the meeting transcripts. The output format should be markdown in the same language as the user's input. Start with a brief summary of the meeting, continue with bullets outlining the most important points of discussion. Finally, provide a table to show the list of action items with 3 columns: Action, Assigned Person, Due Date."}]
|
184 |
-
messages.append({"role": "user", "content": prompt_request})
|
185 |
response = openai.ChatCompletion.create(
|
186 |
model="gpt-3.5-turbo",
|
187 |
messages=messages,
|
|
|
161 |
|
162 |
messages = [
|
163 |
{"role": "system", "content": "Summarize this meeting transcript in the same language as the user's input."}]
|
164 |
+
messages.append({"role": "user", "content": "Summarize this meeting transcript in the same language as the meeting transcript. Meeting Transcript:" + prompt_request})
|
165 |
|
166 |
response = openai.ChatCompletion.create(
|
167 |
model="gpt-3.5-turbo",
|
|
|
178 |
# Consolidate these meeting summaries.
|
179 |
prompt_request = str(prompt_response)
|
180 |
|
181 |
+
if count_tokens(prompt_request)<2000:
|
182 |
# Summarize the text of the meeting transcripts.
|
183 |
messages = [{"role": "system", "content": "Consolidate, and summarize the text of the meeting transcripts. The output format should be markdown in the same language as the user's input. Start with a brief summary of the meeting, continue with bullets outlining the most important points of discussion. Finally, provide a table to show the list of action items with 3 columns: Action, Assigned Person, Due Date."}]
|
184 |
+
messages.append({"role": "user", "content": "Consolidate, and summarize the text of the meeting transcripts. The output format should be markdown in the same language as the meeting summary. Start with a brief summary of the meeting, continue with bullets outlining the most important points of discussion. Finally, provide a table to show the list of action items with 3 columns: Action, Assigned Person, Due Date. Meeting summary:"+ prompt_request})
|
185 |
response = openai.ChatCompletion.create(
|
186 |
model="gpt-3.5-turbo",
|
187 |
messages=messages,
|