summary_json = { "summary": str(summary.replace("\n","|")) } 2546c90 youngtsai commited on Feb 14, 2024
with open(f'{OUTPUT_PATH}/{video_id}_summary.json', 'w') as f: 38a8c25 youngtsai commited on Feb 13, 2024
# if chat_history is not none, append role, content to messages 57ecc14 youngtsai commited on Feb 13, 2024
user_content = f"請根據 {df_string} 生成三個問題,並用 JSON 格式返回 questions:[q1的敘述text, q2的敘述text, q3的敘述text]" 939f3b1 youngtsai commited on Feb 7, 2024
summary_text = json.dumps(summary_json, ensure_ascii=False, indent=2) c1d56d4 youngtsai commited on Feb 7, 2024
summary = get_video_id_summary(video_id, formatted_simple_transcript) 071ad69 youngtsai commited on Feb 7, 2024
df_summarise = gr.Textbox(container=True, show_copy_button=True, lines=40) a8d67ba youngtsai commited on Feb 7, 2024
btn_create_question.click(get_questions, inputs = [df_string_output], outputs = [btn_1, btn_2, btn_3]) f5c871b youngtsai commited on Feb 7, 2024
btn_create_question.click(generate_questions, inputs = [df_string_output], outputs = [btn_1, btn_2, btn_3]) 1b79c0f youngtsai commited on Feb 7, 2024