Spaces:
Sleeping
Sleeping
metadata
title: ECHO TUTOR PRO
emoji: π£οΈ
colorFrom: blue
colorTo: indigo
sdk: docker
app_file: app.py
pinned: false
ECHO TUTOR PRO π£οΈ
An AI-powered English language tutor with a premium, immersive interface. Practice natural English conversation with real-time corrections, suggestions, and adaptive difficulty.
β¨ Features
- Streaming AI Responses β Real-time token-by-token response rendering via SSE
- Adaptive Difficulty β Beginner, Intermediate, and Advanced levels
- Conversation Topics β 8 curated topics: Free Talk, Travel, Food, Tech, Movies, Sports, Work, Daily Life
- Premium UI β Glassmorphism design, animated particle background, 3D orb avatar
- Voice Interaction β Real-time Speech-to-Text (STT) and Text-to-Speech (TTS)
- Audio Waveform β Live microphone visualization using Web Audio API
- Smart Corrections β AI provides inline corrections and vocabulary suggestions
- PWA Support β Installable as a Progressive Web App
- Session Persistence β Conversation history saved across page refreshes
- Keyboard Shortcuts β Ctrl+M (mic), Enter (send), Escape (end)
π Quick Start
1. Clone the repository
git clone <your-repo-url>
cd echo-tutor
2. Set environment variable
export NVIDIA_API_KEY="your-api-key-here"
3. Install dependencies
pip install -r requirements.txt
4. Run locally
python app.py
Open http://localhost:7860 in your browser.
Auth + Nova Integration (Production Runtime)
- Production runtime for
PROJECT_APPis Flask viaapp.py(notmain.py). - Auth pages are served as standalone routes:
/signup/verify/login
- Auth API is mounted under
/authfromauth_module.flask_auth_routes. - Signup/request-otp generates local OTP and pushes it to Nova when configured:
POST /api/external/push-otpon NovaGET /api/external/check-verifiedon Nova
Required env keys for integration:
NOVA_API_URLNOVA_API_KEYAPP_IDJWT_SECRET_KEY
To route auth through Nova centrally, set:
AUTH_MODE=centralAUTH_PROXY_TIMEOUT_SECONDS=15
π³ Docker
docker build -t echo-tutor .
docker run -p 7860:7860 -e NVIDIA_API_KEY="your-key" echo-tutor
π Project Structure
echo-tutor/
βββ app.py # Flask backend with streaming SSE
βββ config.py # Configuration (levels, topics, API settings)
βββ requirements.txt # Python dependencies
βββ Dockerfile # Docker container configuration
βββ Procfile # Gunicorn process file
βββ templates/
β βββ index.html # Main application template
βββ static/
βββ css/style.css # Premium glassmorphism design system
βββ js/script.js # Application engine (SSE, particles, waveform)
βββ manifest.json # PWA manifest
βββ service-worker.js
βββ icons/
βββ icon-192.png
βββ icon-512.png
π§ API Endpoints
| Endpoint | Method | Description |
|---|---|---|
/ |
GET | Main application page |
/chat |
POST | Non-streaming chat endpoint |
/chat/stream |
POST | SSE streaming chat endpoint |
/topics |
GET | Available topics & difficulty levels |
/health |
GET | Health check with uptime |
π Deploy on Hugging Face Spaces
- Push to your HF Space repository
- Set
NVIDIA_API_KEYas a Space secret - The app runs automatically via Docker
For more: https://huggingface.co/docs/hub/spaces-config-reference