Lenylvt commited on
Commit
cd0284d
·
verified ·
1 Parent(s): e0bf751

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +20 -1
app.py CHANGED
@@ -101,10 +101,29 @@ def segmenter_texte(texte):
101
  st.set_page_config(layout="wide")
102
  st.title('🎓 Entrainement de Dictée')
103
 
 
104
  if 'expanded' not in st.session_state:
105
  st.session_state.expanded = True
 
106
  if 'dicteecreation' not in st.session_state:
107
- st.session_state.dicteecreation = False #Inversed
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
108
  with st.expander("📝 Génération de la dictée", expanded=st.session_state.expanded):
109
  with st.form("dictation_form"):
110
  st.markdown("### 🚀 Choisissez votre mode de dictée")
 
101
  st.set_page_config(layout="wide")
102
  st.title('🎓 Entrainement de Dictée')
103
 
104
+ # Initializing session state variables
105
  if 'expanded' not in st.session_state:
106
  st.session_state.expanded = True
107
+
108
  if 'dicteecreation' not in st.session_state:
109
+ st.session_state.dicteecreation = False
110
+
111
+ if 'creationmodified' not in st.session_state:
112
+ st.session_state.creationmodified = False
113
+
114
+ if 'dictee' not in st.session_state:
115
+ st.session_state.dictee = None
116
+
117
+ if 'audio_urls' not in st.session_state:
118
+ st.session_state.audio_urls = []
119
+
120
+ if 'concatenated_audio_path' not in st.session_state:
121
+ st.session_state.concatenated_audio_path = None
122
+
123
+ if 'correction' not in st.session_state:
124
+ st.session_state.correction = ""
125
+
126
+ # Settings Dictee
127
  with st.expander("📝 Génération de la dictée", expanded=st.session_state.expanded):
128
  with st.form("dictation_form"):
129
  st.markdown("### 🚀 Choisissez votre mode de dictée")