Skip to content

Add LUFS and true-peak observations with explicit measurement contracts #5

Description

@engkimo

Problem

VoxBench currently records RMS, sample peak, full-scale sample percentage, gain, silence, and duration evidence. These are useful for debugging but do not describe integrated loudness, loudness range, or inter-sample true peak.

Goal

Add standards-informed loudness and true-peak observations without turning a single number into an unsupported quality verdict.

Design requirements

  • Propose the measurement standard and algorithm before implementation.
  • Record sample rate, channel contract, window/gating behavior, units, and implementation version.
  • Define how short telephone utterances become insufficient rather than misleading values.
  • Keep sample peak and true peak distinct.
  • Keep stage-native and comparison sample rates explicit.
  • Do not add a mandatory heavyweight dependency without discussing packaging and platform impact.

Acceptance criteria

  • Deterministic synthetic fixtures cover tone, silence, clipped signal, short/insufficient audio, and level changes.
  • Results are finite, bounded, and use explicit units (LUFS, LU, dBTP).
  • Timeline/stage presentation distinguishes measured values from policy thresholds.
  • A missing optional implementation reports unavailable or insufficient, not zero.
  • Documentation states limitations for 8 kHz telephony audio.
  • Python checks and Web build pass.

Likely areas

  • src/voxbench/media/
  • src/voxbench/observability/observer.py
  • src/voxbench/control_plane/run_api.py
  • src/voxbench/verification/
  • stage detail Web UI and tests

Out of scope

  • Declaring one universal “good” loudness threshold for every provider or route.
  • Retaining additional raw media.
  • Replacing full-reference scorers such as ViSQOL.

Audio measurement expertise and review are welcome.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or requesthelp wantedExtra attention is needed

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions