Spaces:
Sleeping
Sleeping
| """Data models for the Audio Labeling Tool.""" | |
| from dataclasses import dataclass | |
| from typing import TypedDict | |
| class LabelRow(TypedDict): | |
| """TypedDict representing a single row in the metadata CSV.""" | |
| source: str # Audio filename only (e.g., "clip_001.wav") | |
| transcription: str # Corrected transcription text | |
| gender: str # "male" or "female" | |
| pii: str # "True" or "False" (string representation in CSV) | |
| labeler: str # Username of the labeler | |
| class LabelRecord: | |
| """Dataclass for constructing a label before saving.""" | |
| source: str | |
| transcription: str | |
| gender: str | |
| pii: bool | |
| labeler: str | |