How erax-ai/vif5tts works
Project type and purpose
• This is a machine-learning text-to-speech (TTS) toolkit built around the F5-TTS architecture, extended for Vietnamese (“EraX-Smile-Female-F5-V1.0”).
• It provides modules for training (dataset preparation, trainer, pruning), evaluation, inference (CLI, Gradio, wrapper), and real-time streaming (FastAPI, socket).
File structure
• Top-level directories:
• src/f5_tts/model – core model code (backbones, modules, trainer).
• src/f5_tts/train – training pipelines & dataset pre-processing scripts.
• src/f5_tts/infer – inference wrappers (CLI, Gradio), example configs and audio.
• src/f5_tts/eval – evaluation scripts for benchmarks.
• src/streaming – real-time streaming server (FastAPI) and client (JS/HTML).
• src/model_pruning – utilities to prune and convert checkpoints.
• src/socket_server, src/socket_client – alternative streaming via sockets.
• Root config files: pyproject.toml, ruff.toml, and YAML config templates.
README for insights
• Describes how to run FastAPI streaming service.
• Shows Python example for CLI-based inference using F5TTSWrapper and Vinorm text normalizer.
• Highlights dependencies: PyTorch, fastapi/uvicorn, piper-tts, langchain, underthesea, vinorm.