YingxuHe's picture
Update app.py
d3fed50 verified
raw
history blame
1.36 kB
import os
import streamlit as st
import streamlit.components.v1 as components
from st_on_hover_tabs import on_hover_tabs
from pages import *
from utils import start_server
certificate = os.getenv('PRIVATE_KEY')
dns_name = os.getenv('SERVER_DNS_NAME')
start_server(certificate, dns_name)
## Set Streamlit configuration
st.set_page_config(page_title='MERaLiON-AudioLLM', page_icon = "πŸ”₯", layout='wide')
st.markdown('<style>' + open('./style/sidebar_style.css').read() + '</style>', unsafe_allow_html=True)
with st.sidebar:
tabs = on_hover_tabs(tabName=['HOME',
'MERaLiON-AudioLLM',
],
iconName=['dashboard', 'filter_1'],
styles = {
'navtab': {
'font-size': '12px',
'transition': '0.3s',
'text-transform': 'none',
},
'iconStyle':{
'font-size': '18px',
},
},
default_choice=0
)
if tabs =='HOME':
home_page()
elif tabs == 'MERaLiON-AudioLLM':
audio_llm()