A Python-based web application that converts PDF documents into audio, so you can listen to your documents instead of reading them. Perfect for when you're busy, commuting, cooking, or just want to give your eyes a rest!
Ever had a long PDF to read but no time to sit and read it? This app solves that — just upload your PDF and it converts it into an MP3 audio file you can listen to anywhere, anytime.
You have a 50-page research paper to read before tomorrow's class. Instead of reading it, just upload it to PDF Audio-Book, download the MP3, and listen while getting ready, eating, or traveling. Learn without stopping your day! 🎧
- 📄 Upload any PDF document
- 🔍 Automatically extracts and cleans text
- 🔊 Play audio directly in the app
- 💾 Download as MP3 file
- 🎚️ Adjust speaking speed and volume
- 100% works in your browser — no extra software needed
| Tool | Purpose |
|---|---|
| Python | Core language |
| Streamlit | Web UI |
| PyPDF | PDF text extraction |
| pyttsx3 | Text to speech conversion |
| Docker | Containerization |
| Kubernetes (Minikube) | Orchestration & scaling |
pdf-audiobook/
├── app.py # Main Streamlit application
├── requirements.txt # Python dependencies
├── Dockerfile # Docker image instructions
├── deployment.yaml # Kubernetes deployment config
└── service.yaml # Kubernetes service config
Follow these steps one by one:
Step 1: Clone the project
git clone https://github.com/Aliyas-22/PDF-To-Audio-Converter.git
cd PDF-To-Audio-ConverterStep 2: Create a virtual environment
python -m venv venvStep 3: Activate the virtual environment
# Windows
venv\Scripts\activate
# Mac/Linux
source venv/bin/activateStep 4: Install dependencies
pip install -r requirements.txtStep 5: Run the app
streamlit run app.pyStep 6: Open in browser
http://localhost:8501
Step 7: Use the app
- Upload your PDF using the file uploader
- Wait for text to be extracted
- Click Generate MP3 to download your audio file
- Adjust speed and volume from the left sidebar
Step 1: Make sure Docker is installed
docker --versionStep 2: Pull the image from Docker Hub
docker pull aliyafirdous22/pdf-audiobook:v1Step 3: Run the container
docker run -p 8501:8501 aliyafirdous22/pdf-audiobook:v1Step 4: Open in browser
http://localhost:8501
Step 1: Make sure you have these installed
- Docker
- Minikube
- kubectl
Step 2: Start Minikube
minikube start --memory=2048mb --cpus=2Step 3: Deploy the app
kubectl apply -f deployment.yaml
kubectl apply -f service.yamlStep 4: Check pods are running
kubectl get podsWait until status shows Running
Step 5: Access the app
kubectl port-forward service/pdf-audiobook-service 8501:80Step 6: Open in browser
http://localhost:8501
Kubernetes lets you run multiple copies of the app at the same time. If many people use the app together, Kubernetes handles the load automatically.
# Scale up to 5 replicas
kubectl scale deployment pdf-audiobook --replicas=5
# Check all pods running
kubectl get pods
# Scale back down
kubectl scale deployment pdf-audiobook --replicas=2
Aliya Firdous
Built with Python • Containerized with Docker • Scaled with Kubernetes