|
import streamlit as st
|
|
from utlis import *
|
|
|
|
from st_audiorec import st_audiorec
|
|
|
|
st.title("Live Speech to Job Offer Generator")
|
|
|
|
|
|
wav_audio_data = st_audiorec()
|
|
|
|
if wav_audio_data is not None:
|
|
|
|
transcribed_text = audio_to_text(wav_audio_data)
|
|
st.markdown("_Transcribed Text:_", unsafe_allow_html=True)
|
|
st.markdown(f'<p style="text-align: center;">"{transcribed_text}"</p>', unsafe_allow_html=True)
|
|
|
|
|
|
if transcribed_text and st.button("Generate Job Offer"):
|
|
|
|
job_offer = call_ai_api(transcribed_text)
|
|
st.write("Generated Job Offer:")
|
|
st.write(job_offer)
|
|
|