Spaces:
Sleeping
Sleeping
Commit ·
33c6f10
1
Parent(s): 48bf45d
Update app.py
Browse files15 unmodified lines161718191920212214 unmodified lines3738394041424344454614 unmodified lines6162636465666768697015 unmodified lines
pipe=pipeline('text2text-generation', model=model, tokenizer=tokenizer)
sound_file = BytesIO()
greetings=["Hello! My name is MineAI, A specially trained LLM here to assist you on your Mining Related Queries.","How may I help you?"]
14 unmodified lines for gr in greetings: with st.chat_message("assistant"): st.markdown(gr)
tts=gTTS(gr) tts.write_to_fp(sound_file) st.audio(sound_file) st.session_state.messages.append({ 'role':'assistant',14 unmodified lines with st.chat_message("assistant"): st.markdown(response)
tts=gTTS(response) tts.write_to_fp(sound_file) st.audio(sound_file) st.session_state.messages.append({ 'role':'assistant',app.py+9-1