Added initial segment overlap resolution logic

This commit is contained in:
2026-04-27 15:52:53 -05:00
parent e42a2326e8
commit 1b9f4bd922
16 changed files with 1357 additions and 59 deletions

View File

@@ -123,13 +123,15 @@ func (normalizeSpeakers) Process(ctx context.Context, in pipeline.PreprocessStat
segments := make([]model.Segment, 0, len(raw.Segments))
for index, rawSegment := range raw.Segments {
sourceSegmentIndex := index
segments = append(segments, model.Segment{
Source: raw.Source,
SourceSegmentIndex: index,
SourceSegmentIndex: &sourceSegmentIndex,
Speaker: canonicalSpeaker,
Start: rawSegment.Start,
End: rawSegment.End,
Text: rawSegment.Text,
Words: append([]model.Word(nil), rawSegment.Words...),
})
}