Sensei – Web GUI to manage AI Subtitle Generator & Translator
Two are the components:
- Frontend (Vue 3 + Vite)
- Backend (FastAPI + SQLAlchemy)
- ️Automatic generation of transcription subtitles (in the language spoken in the video)
- Automatic generation of translation subtitles, in a target language
- Integrated editor to modify subtitle text and time stamps
Frontend:
- Vue 3
- Vite
- JavaScript
- npm
Backend:
- FastAPI
- SQLAlchemy
- Pydantic Settings
- Uvicorn
Clone the repo:
git clone https://github.com/hlt-mt/sensei.git
cd senseicd frontend
npm installnpm run devVite automatically start the development server (by default on http://localhost:5173).
API developed with FastAPI, with JWT authentication and user/project management. Swagger doc available on /docs.
cd backend
python -m venv .venv
source .venv/bin/activate
pip install -r requirements.txtuvicorn backend.main:app --reloadEnvironment variables are read from the (optional) file .env.
Frontend environment variables (frontend/.env):
VITE_WHISPER_BASE: base URL of the subtitler systemVITE_ENDPOINT_POST: endpoint to create a subtitling projectVITE_ENDPOINT_STATUS: endpoint to check the state of the subtitling projectVITE_ENDPOINT_OUT: endpoint to retrieve the project transcription subtitlesVITE_ENDPOINT_TRANSLATED: endpoint to retrieve the project translation subtitlesVITE_REQUIRE_SOURCE_LANG:true/falsese il provider richiede la lingua sorgenteVITE_WHISPER_TOKEN: token subtitler system authenticationVITE_AUDIO_EXTRACTION_TOKEN: audio extraction token
Backend environment variables (backend/.env):
SECRET_KEY: JWT key (default:change-me)ADMIN_EMAIL: admin bootstrap email (default:admin@example.com)ADMIN_PASSWORD: admin password (automatically generated if empty)DB_URL: connection string (default: SQLite in-memory)PASSWORD_LENGTH: password minimum length (default: 8)JWT_ALGORITHM: JWT algorithm (default:HS256)
- A video file is loaded
- The system automatically generates the transcription subtitles
- Transcription subtitles are automatically translated
- Both transcription and translation subtitles can be modified by the user by means of the integrated editor
- Both transcription and translation subtitles are exported as srt files