A Streamlit component for rating text
You can install using the pip package manager by running
pip install streamlit-text-rating
Alternatively, you could install the latest version directly from Github:
pip install https://github.com/TVS-Motor-Company/streamlit-text-rating/streamlit-text-rating/archive/master.zip
Download the source code by cloning the repository or by pressing 'Download ZIP' on this page.
Install by navigating to the proper directory and running:
python setup.py install
from streamlit_text_rating.st_text_rater import st_text_rater
import streamlit as st
st.title("Awesome App")
for text in ["Is this text helpful?", "Do you like this text?"]:
response = st_text_rater(text=text)
# st.write(f"response --> {response}")