How kowsalya-21/music_misatch_prediction works
Label Audit is a web-backed music mood and editorial-label auditing service. Users submit audio or search for a track; the API obtains audio and optional lyrics, produces acoustic and lyrical mood estimates, compares them with the supplied label, and invokes an investigative agent for flagged mismatches. The repository also contains substantial dataset preparation, model-training, and evaluation code. The graph reflects documented capabilities and indexed imports; unsampled implementation details and frontend wiring are not inferred.
Main entry points: main.py Analysis API · train_audio.py Audio model training · tools.py Investigation tools · app.js Audit dashboard
Components 20
Audit service
- Audit dashboard
backend/static/app.js - Analysis API
backend/app/main.py - Verification agent
backend/app/agent/engine.py - Investigation tools
backend/app/agent/tools.py
Inference models
- Acoustic inference
backend/app/inference/audio.py - Lyrics inference
backend/app/inference/lyrics.py - Label mood mapping
backend/app/inference/label.py - Mismatch comparator
backend/app/inference/comparator.py - Audio model artifact
weights/audio_mood.onnx
Data and training
- Audio preprocessing
src/features/preprocess.py - Audio feature extraction
src/features/audio_features.py - Acoustic CNN
src/models/audio_model.py - Spectrogram augmentation
src/models/augmentations.py - Audio model training
src/train/train_audio.py - Lyrics model training
src/train/train_lyrics.py - Temperature calibration
src/models/temperature_scaling.py - Acoustic baselines
src/models/baseline_models.py
Evaluation
- Evaluation metrics
src/eval/metrics.py
Other components
- Auditor
- Online catalog services
Connections 19
- Auditor → Audit dashboard: uses
README.md - Audit dashboard → Analysis API: submits analysis
- Analysis API → Acoustic inference: predicts mood
backend/app/main.py - Analysis API → Lyrics inference: analyzes lyrics
backend/app/main.py - Analysis API → Label mood mapping: maps label
backend/app/main.py - Analysis API → Mismatch comparator: compares signals
backend/app/main.py - Analysis API → Verification agent: requests verification
backend/app/main.py - Analysis API → Investigation tools: fetches lyrics
backend/app/main.py - Verification agent → Investigation tools: runs tools
backend/app/agent/engine.py - Investigation tools → Online catalog services: searches catalog
backend/app/agent/tools.py - Acoustic inference → Audio model artifact: loads model
backend/app/inference/audio.py - Audio preprocessing → Audio feature extraction: uses extraction
src/features/preprocess.py - Audio model training → Acoustic CNN: trains CNN
src/train/train_audio.py - Audio model training → Spectrogram augmentation: augments samples
src/train/train_audio.py - Audio model training → Temperature calibration: calibrates outputs
src/train/train_audio.py - Audio model training → Acoustic baselines: trains baselines
src/train/train_audio.py - Audio model training → Evaluation metrics: evaluates predictions
src/train/train_audio.py - Acoustic baselines → Evaluation metrics: computes scores
src/models/baseline_models.py - Lyrics model training → Online catalog services: uses emotion datasets