Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -1,17 +1,67 @@
|
|
| 1 |
import streamlit as st
|
| 2 |
import sentiment_analysis
|
| 3 |
import text_summary
|
| 4 |
-
|
|
|
|
| 5 |
def main():
|
| 6 |
-
st.
|
| 7 |
-
|
| 8 |
-
|
| 9 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 10 |
|
|
|
|
| 11 |
if app_mode == "Sentiment Analysis":
|
| 12 |
sentiment_analysis.run()
|
| 13 |
elif app_mode == "Text Summary":
|
| 14 |
text_summary.run()
|
| 15 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 16 |
if __name__ == "__main__":
|
| 17 |
main()
|
|
|
|
| 1 |
import streamlit as st
|
| 2 |
import sentiment_analysis
|
| 3 |
import text_summary
|
| 4 |
+
|
| 5 |
+
|
| 6 |
def main():
|
| 7 |
+
st.set_page_config(page_title="AI ROBO HUB - Smart AI Tools", layout="wide")
|
| 8 |
+
|
| 9 |
+
# Custom styling
|
| 10 |
+
st.markdown(
|
| 11 |
+
"""
|
| 12 |
+
<style>
|
| 13 |
+
.sidebar .sidebar-content {
|
| 14 |
+
background-color: #1f1f2e;
|
| 15 |
+
color: white;
|
| 16 |
+
}
|
| 17 |
+
.stButton>button {
|
| 18 |
+
width: 100%;
|
| 19 |
+
border-radius: 10px;
|
| 20 |
+
background-color: #0073e6;
|
| 21 |
+
color: white;
|
| 22 |
+
font-size: 16px;
|
| 23 |
+
}
|
| 24 |
+
.stButton>button:hover {
|
| 25 |
+
background-color: #005bb5;
|
| 26 |
+
}
|
| 27 |
+
.block-container {
|
| 28 |
+
padding-top: 2rem;
|
| 29 |
+
}
|
| 30 |
+
</style>
|
| 31 |
+
""",
|
| 32 |
+
unsafe_allow_html=True,
|
| 33 |
+
)
|
| 34 |
+
|
| 35 |
+
# Sidebar navigation
|
| 36 |
+
st.sidebar.title("π AI ROBO HUB - Smart AI Tools")
|
| 37 |
+
st.sidebar.markdown("### Select Functionality")
|
| 38 |
+
app_mode = st.sidebar.radio("", ["Sentiment Analysis", "Text Summary"], index=0)
|
| 39 |
+
|
| 40 |
+
# Main Content Section
|
| 41 |
+
st.markdown("<h1 style='text-align: center; color: #0073e6;'>Welcome to AI Robo Hub</h1>", unsafe_allow_html=True)
|
| 42 |
+
st.markdown("<h3 style='text-align: center; color: #444;'>We provide end-to-end AI Apps Development</h3>",
|
| 43 |
+
unsafe_allow_html=True)
|
| 44 |
+
|
| 45 |
+
st.markdown("---")
|
| 46 |
|
| 47 |
+
# Load respective module
|
| 48 |
if app_mode == "Sentiment Analysis":
|
| 49 |
sentiment_analysis.run()
|
| 50 |
elif app_mode == "Text Summary":
|
| 51 |
text_summary.run()
|
| 52 |
|
| 53 |
+
# Footer Section
|
| 54 |
+
st.markdown("---")
|
| 55 |
+
st.markdown(
|
| 56 |
+
"""
|
| 57 |
+
<div style="text-align: center; padding: 10px; background-color: #1f1f2e; color: white; border-radius: 10px;">
|
| 58 |
+
<h4>π Looking for AI-powered solutions?</h4>
|
| 59 |
+
<p>We specialize in AI-driven automation, sentiment analysis, text summarization, and more.</p>
|
| 60 |
+
<p>π© Contact us today at <a href="mailto:airobohub@gmail.com" style="color: #f8c471;">contact@airobohub.com</a></p>
|
| 61 |
+
<p>π Visit our website: <a href="https://www.airobohub.com" target="_blank" style="color: #f8c471;">www.airobohub.com</a></p>
|
| 62 |
+
</div>
|
| 63 |
+
""",
|
| 64 |
+
unsafe_allow_html=True
|
| 65 |
+
)
|
| 66 |
if __name__ == "__main__":
|
| 67 |
main()
|