youngtsai commited on
Commit
e5a1f9f
·
1 Parent(s): 67879c8

summary = generate_summarise(df_string)

Browse files
Files changed (1) hide show
  1. app.py +15 -8
app.py CHANGED
@@ -405,8 +405,7 @@ def get_video_id_summary(video_id, df_string):
405
  # 检查逐字稿是否存在
406
  exists, file_id = check_file_exists(service, folder_id, file_name)
407
  if not exists:
408
- # summary = generate_summarise(df_string)
409
- summary = "summary_summary_summary"
410
  summary_json = {"summary": summary}
411
  summary_text = json.dumps(summary_json, ensure_ascii=False, indent=2)
412
  file_id = upload_content_directly(service, file_name, folder_id, summary_text)
@@ -438,14 +437,22 @@ def generate_summarise(df_string):
438
  以及可能的結論與結尾延伸小問題提供學生作反思
439
 
440
  整體格式為:
441
- 🗂️ 1. 內容類型:?
442
- 📚 2. 整體摘要
443
- 🔖 3. 條列式重點
444
- 🔑 4. 關鍵時刻(段落摘要)
445
- 💡 5. 結論反思(為什麼我們要學這個?)
446
- 6. 延伸小問題
447
 
448
  """
 
 
 
 
 
 
 
 
449
  messages = [
450
  {"role": "system", "content": sys_content},
451
  {"role": "user", "content": user_content}
 
405
  # 检查逐字稿是否存在
406
  exists, file_id = check_file_exists(service, folder_id, file_name)
407
  if not exists:
408
+ summary = generate_summarise(df_string)
 
409
  summary_json = {"summary": summary}
410
  summary_text = json.dumps(summary_json, ensure_ascii=False, indent=2)
411
  file_id = upload_content_directly(service, file_name, folder_id, summary_text)
 
437
  以及可能的結論與結尾延伸小問題提供學生作反思
438
 
439
  整體格式為:
440
+ 1. 內容類型:?
441
+ 2. 整體摘要
442
+ 3. 條列式重點
443
+ 4. 關鍵時刻(段落摘要)
444
+ 5. 結論反思(為什麼我們要學這個?)
445
+ 6. 延伸小問題
446
 
447
  """
448
+
449
+ # 🗂️ 1. 內容類型:?
450
+ # 📚 2. 整體摘要
451
+ # 🔖 3. 條列式重點
452
+ # 🔑 4. 關鍵時刻(段落摘要)
453
+ # 💡 5. 結論反思(為什麼我們要學這個?)
454
+ # ❓ 6. 延伸小問題
455
+
456
  messages = [
457
  {"role": "system", "content": sys_content},
458
  {"role": "user", "content": user_content}