Cannot use `visualize` multiple times in the same script
andfanilo opened this issue · 0 comments
andfanilo commented
When using visualize
methods multiple times, we get into a DuplicateWidgetID
error.
import spacy_streamlit
models = ["en_core_web_sm", "en_core_web_md"]
text1 = "Sundar Pichai is the CEO of Google."
text2 = "Randy Zwitch is Head of Developer Relations at Streamlit"
spacy_streamlit.visualize(models, text1)
spacy_streamlit.visualize(models, text2)
Adding/generating a key
parameter to pass to those widgets should do.