Repository navigation
fix(speakers): never match a voice to someone it was said not to be - #691
Merged
Merged
Conversation
match() ignored not_same: a voice split off from a person, or turned down as them, could be auto-assigned or suggested as that person again when it sat near their average voice, or when the person it sounded like was already taken in the same recording. Now, of two people said not to be the same, a voice goes to (or is suggested as) only the one it sounds more like, by their voice overall or in any one recording they're in. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01QFUNzy1QZy5HhKAyJxTAYJ
18 of 23 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Requested by Adeel · project thread
Description
Before: after a voice was split off from a person ("Not them here") or a suggested pair was marked not the same, a voice in a new or re-diarized asset that sat near the first person's average could still be auto-assigned or suggested as them. The voice matcher's
match()ignorednot_same.After: for each pair of people said not to be the same, a new voice goes to, or is suggested as, only the one of the two it sounds more like, by their voice overall or in any one asset they're in. When two voices in one recording are both nearest the same person, the second no longer falls through to the barred person. With no
not_samepairs, nothing changes and no extra queries run.How: a new
_not_them()indomain/speakers.py, called bymatch().Motivation and Context
Item from the personal feature plan sheet (speaker fixes:
match()ignoresnot_same).Screenshots (if appropriate):
n/a
Steps to reproduce (if appropriate):
Mark a voice "Not them here" on person A, then import another recording of that voice: it is no longer matched or suggested as A.
Types of changes
!in the title)Checklist:
make hookschecks it on commit).tests/domain/test_voices.py::test_a_voice_never_goes_to_someone_it_was_said_not_to_be; it fails against the oldmatch()).docs/accordingly (docs/processing.md#people-and-namespaces).## UnreleasedinCHANGELOG.md. Written aschangelog.d/voice-not-same.md, per build(release): changelog fragments in changelog.d/ instead of one Unreleased section #581.Done questions (AGENTS.md)
POST /speakers/{sid}/detachand not-same decisions made through the API..envedit or manual step.docs/requirements.mdname the new test.make openapi). No API change.not_samerecords.Local CI: the container runs several times slower than usual, so I ran the changed tests directly:
test_voices.py,test_speakers.py,test_voice_mode.py,test_speech.pypass, and ruff and mypy are clean. GitHub CI decides the merge.Generated by Claude Code