This is a prototype for the project "Disaster Management using Generative AI."
-
Clone the repository:
git clone https://github.com/your-username/DisasterManagement.git
-
Navigate to the project directory:
cd DisasterManagement -
Run the Flask application:
python app.py
-
Set up Ngrok:
- Navigate to the folder
ngrok-v3-stable-windows-amd64. - Run the
ngrok.exefile inside the folder.
- Navigate to the folder
-
Start the ngrok local server:
ngrok http 5000
- A new server will start at
localhost:5000. - Copy the forwarding link provided by Ngrok in the terminal window.
- A new server will start at
-
Configure the Twilio webhook:
- Take the forwarding link from Ngrok and append
/voiceto it.https://<ngrok-forwarding-link>/voice - Go to your Twilio console and paste this link in the Webhook URL for your active number.
- Take the forwarding link from Ngrok and append
-
Save and continue on Twilio:
- Make sure to add your Account SID and Auth Token in the
app.pyprogram (replace placeholders).
- Make sure to add your Account SID and Auth Token in the
-
Make a call to your Twilio number:
- Call the number, and you'll hear instructions to describe your emergency.
- After the beep, describe the emergency and end the call.
-
Recording and Transcription:
- The program will:
- Download the call recording.
- Transcribe the audio.
- Delete the recording from the local machine after transcription.
- The program will:
-
View Transcription and Disaster Type Matching:
- The transcription will be printed in the terminal.
- Google's gemini will analyze the information reflected by the transcribed text and return JSON format
- The JSON format contains any name mentioned by the caller, address, disaster type
- It will also give a sentiment analysis based on the transcribed text