Files
mudler--localai/core/schema/sound_classification.go
wehub-resource-sync 1b8708893a
Security Scan / tests (push) Has been cancelled
chore: import upstream snapshot with attribution
2026-07-13 13:12:26 +08:00

20 lines
705 B
Go

package schema
// SoundClassification is one scored sound-event tag. Score is the
// per-class probability (multi-label, independent), Index is the class
// index in the model ontology, and Label is the human-readable AudioSet
// class name (e.g. "Baby cry, infant cry").
type SoundClassification struct {
Index int `json:"index"`
Label string `json:"label"`
Score float32 `json:"score"`
}
// SoundClassificationResult is the JSON response of the
// /v1/audio/classification endpoint: the model name and the scored tags
// in score-descending order.
type SoundClassificationResult struct {
Model string `json:"model"`
Detections []SoundClassification `json:"detections"`
}