
- Database migration: Updated publicstream.uid from usernames to email addresses - devuser → oib@bubuit.net - oibchello → oib@chello.at - Updated related tables (UploadLog, UserQuota) to use email-based UIDs - Fixed backend audio route to map email UIDs to username-based directories - Updated SSE event payloads to use email for UID and username for display - Removed redundant display_name field from SSE events - Fixed frontend rendering conflicts between nav.js and streams-ui.js - Updated stream player template to display usernames instead of email addresses - Added cache-busting parameters to force browser refresh - Created migration script for future reference Benefits: - Eliminates UID duplicates and inconsistency - Provides stable, unique email-based identifiers - Maintains user-friendly username display - Follows proper data normalization practices Fixes: Stream UI now displays usernames (devuser, oibchello) instead of email addresses
dicta2stream
A FastAPI-based audio streaming and upload backend with user registration, quota management, and abuse logging.
Features
- User registration and magic link login
- Audio upload with music/singing detection
- Per-user storage quota
- Admin stats endpoint
- Abuse/violation logging
Setup
Requirements
- Python 3.11+
- PostgreSQL (or compatible DB)
Installation
python3 -m venv venv
source venv/bin/activate
pip install -r requirements.txt
Environment Variables
Create a .env
file in the project root with:
DATABASE_URL=postgresql://user:pass@localhost:5432/dictastream
ADMIN_SECRET=your_admin_secret
Running
uvicorn main:app --reload
Directory Structure
main.py
— FastAPI entrypointregister.py
,magic.py
,upload.py
,redirect.py
— routersmodels.py
— SQLModel ORM modelsdatabase.py
— DB session/enginestatic/
— static HTML/JS/CSS assets
Notes
- By default, audio uploads are stored in
/data
. - Ollama music/singing detection requires a local Whisper API at
localhost:11434
. - Abuse logs are written to
abuse.log
.
License
MIT
Description
Languages
JavaScript
40.9%
Python
34.5%
CSS
21.5%
HTML
2.9%
Mako
0.2%