Spaces:
Sleeping
Sleeping
Download pages/02_Initial_Topic_Modeling.py from shrut27/CRC-Webapp: direct link, hf CLI and curl.
- Browser
- Download file 1.17 kB
-
https://huggingface.co/spaces/shrut27/CRC-Webapp/resolve/refs%2Fpr%2F13/pages/02_Initial_Topic_Modeling.py
- Command line
-
hf download hf://spaces/shrut27/CRC-Webapp@refs/pr/13/pages/02_Initial_Topic_Modeling.py
-
curl -L -o 02_Initial_Topic_Modeling.py https://huggingface.co/spaces/shrut27/CRC-Webapp/resolve/refs%2Fpr%2F13/pages/02_Initial_Topic_Modeling.py
1.17 kB
| import streamlit as st | |
| import streamlit.components.v1 as components | |
| st.title("Topic Modeling") | |
| def introduction(): | |
| st.title("Research & Methodology") | |
| st.markdown("LDA as Baseline: " | |
| "Describe the use of Latent Dirichlet Allocation as a baseline for comparison and understanding.") | |
| st.markdown("Process Flow: Step-by-step breakdown of the analysis process, from data gathering to insights extraction.") | |
| # Display the LDA visualization HTML file | |
| components.html(open('lda_visualization.html', 'r').read(), height=800) | |
| def lda_page(): | |
| st.title("Insights & Findings of Latent Dirichlet Allocation (LDA) Model") | |
| st.markdown("Priliminary Results: findings, notebooks, documentation") | |
| st.markdown("Visualizations including pyLDAvis: ") | |
| st.markdown("Key Trends: ") | |
| sidebar_pages = ["Introduction", "Latent Dirichlet Allocation"] | |
| def main(): | |
| st.sidebar.title("Navigation") | |
| page = st.sidebar.selectbox("Select a page:", sidebar_pages) | |
| if page == "Introduction": | |
| introduction() | |
| elif page == "Latent Dirichlet Allocation": | |
| lda_page() | |
| if __name__ == "__main__": | |
| main() |