Skip to content

vyavasthita/ai-ml

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

61 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

🧠 gen-ai-gl

GenAI Learning Suite

📦 Prerequisites

  • ffmpeg (for audio processing)
    • brew install ffmpeg

🚀 How to Run

▶️ CLI Mode

cd gen-ai-gl/apps
poetry run python -m audio_to_text.cli.cli --audio audio_to_text/sample_files/first.wav

🖥️ Streamlit UI (Local)

Export the following environment variables:

export STREAMLIT_SERVER_PORT=8502
export STREAMLIT_SERVER_HEADLESS=true
export HUGGINGFACE_API_TOKEN=<HUGGING_FACE_API_ACCESS_TOKEN>

Then run:

cd gen-ai-gl/apps
poetry run streamlit run main.py

🐳 Dockerized Deployment

Click to expand Docker instructions

1️⃣ Build & Run with Docker Compose

Quick Start:

# Set environment variables (edit as needed)
export PORT=8501
export HUGGINGFACE_API_TOKEN=<your_hf_token>
export OPENAI_API_KEY=<your_openai_key>

# Start the app
make up

The app will be available at: http://localhost:8501

2️⃣ Useful Makefile Commands

Command Description
make up Build & start containers
make down Stop & remove containers
make stop Stop containers
make clean Prune containers/images/networks
make ps List all containers
make logs Show container logs

3️⃣ Configuration

  • Port: Set PORT env variable to change the exposed port (default: 8501).
  • API Keys: Set HUGGINGFACE_API_TOKEN and OPENAI_API_KEY as needed.
  • Headless Mode: STREAMLIT_SERVER_HEADLESS=true is set by default in Docker Compose.

📝 Project Structure

gen-ai-gl/
├── apps/
│   ├── audio_to_text/
│   ├── image_to_text/
│   ├── learning_assistant/
│   ├── ui/
│   └── utils/
├── Dockerfile
├── docker-compose.yaml
├── Makefile
└── README.md

Happy Learning with GenAI!

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 2

  •  
  •