Skip to content

Commit

Permalink
Add different content in text areas to prevent duplicate widget id (#45)
Browse files Browse the repository at this point in the history
  • Loading branch information
Kostis-S-Z authored Dec 9, 2024
1 parent c7edb54 commit d1a899b
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions demo/app.py
Original file line number Diff line number Diff line change
Expand Up @@ -71,12 +71,18 @@ def load_text_to_speech_model_and_tokenizer():
raw_text = DATA_LOADERS[extension](uploaded_file)
with col1:
st.subheader("Raw Text")
st.text_area(f"Total Length: {len(raw_text)}", f"{raw_text[:500]} . . .")
st.text_area(
f"Number of characters before cleaning: {len(raw_text)}",
f"{raw_text[:500]} . . .",
)

clean_text = DATA_CLEANERS[extension](raw_text)
with col2:
st.subheader("Cleaned Text")
st.text_area(f"Total Length: {len(clean_text)}", f"{clean_text[:500]} . . .")
st.text_area(
f"Number of characters after cleaning: {len(clean_text)}",
f"{clean_text[:500]} . . .",
)

st.divider()
st.header("Downloading and Loading models")
Expand Down

0 comments on commit d1a899b

Please sign in to comment.