This is a Streamlit web application that:
- Takes audio input from a microphone and plays an MP3 file received from a server in response
- Takes a date-time input from a calendar box and plays an MP3 file received from a server in response
- Takes a location input using Google Maps and plays an MP3 file received from a server in response
web_server/
├── app.py # Main Streamlit application
├── requirements.txt # Dependencies
├── static/
│ ├── mp3/ # Directory for sample MP3 files
│ ├── js/
│ │ ├── maps.js # JavaScript for Google Maps functionality
│ │ └── streamlit_component.js # JavaScript for Streamlit component
│ └── location.html # HTML template for Google Maps
└── uploads/ # Directory for uploaded audio files
pip install -r requirements.txt
Open another terminal and run:
streamlit run app.py
This will start the Streamlit app and open it in your default web browser.
- Navigate to the "Audio Input" tab
- Click the "PLAY" button to begin recording audio from your microphone
- Speak into your microphone
- Click "PAUSE" when you're done recording
- Click the "Process Audio Recording" button
- The server will process your audio and return an MP3 file, which will be played automatically
- Navigate to the "DateTime Input" tab
- Select a date using the date picker
- Select a time using the time picker
- Click the "Mock DateTime" button
- The server will process your date-time selection and return an MP3 file, which will be played automatically