worksheet_edit_button = gr.Button("編輯", size="sm", variant="primary") b326bfd youngtsai commited on May 8, 2024
user_message += "/n (請一定要用繁體中文回答 zh-TW,並用台灣人的禮貌口語表達,回答時不要特別說明這是台灣人的語氣,不要提到「台灣腔」,不用提到「逐字稿」這個詞,用「內容」代替),回答時如果有用到數學式,請用數學符號代替純文字(Latex 用 $ 字號 render)" ae1f4a3 youngtsai commited on May 1, 2024
def chat_with_any_ai(ai_type, password, video_id, user_data, transcript_state, key_moments, user_message, chat_history, content_subject, content_grade, questions_answers_json, socratic_mode=False, thread_id=None, ai_name=None): 2f94953 youngtsai commited on May 1, 2024
def chat(self, user_message, chat_history, socratic_mode=False, service_type='openai'): 78a1c85 youngtsai commited on May 1, 2024
system_message = """你是專業的 LATEX 轉換師,擅長將數學符號、公式轉換成 LATEX 格式,並用 LATEX 符號 $...$ 包裹,ex: $x^2$ fa78f46 youngtsai commited on Apr 26, 2024
def update_send_and_feedback_buttons(chat_history, chat_limit): 0d05167 youngtsai commited on Apr 24, 2024
def process_open_ai_audio_to_chatbot(password, audio_url): ee4d2fc youngtsai commited on Apr 23, 2024
with gr.Accordion("你也有類似的問題想問嗎? 請按下 ◀︎", open=False) as ask_questions_accordion: 1b0569d youngtsai commited on Apr 23, 2024
moment['transcript'] = ",".join([entry['text'] for entry in formatted_simple_transcript be2b49a youngtsai commited on Apr 22, 2024
transcript = [entry for entry in transcript if entry['start'] <= video_length] ad2572c youngtsai commited on Apr 22, 2024
transcript_list = YouTubeTranscriptApi.list_transcripts(video_id) 5e224d7 youngtsai commited on Apr 22, 2024