import streamlit as st from transformers import pipeline pipe = pipeline(task='text-generation', model='Marxav/frpron') x = st.text_input('Write a French word:') if x: x += ':' out = pipe(x) word_ipa = out[0]["generated_text"] word = word_ipa.split(":")[0] ipa = word_ipa.split(":")[1] #st.json(out) txt = 'The phonemized and syllabized pronunciation of ['+word+'] is \\'+ipa+'\\' st.write(txt)