Skip to content

feat(app): merge consecutive same-speaker segments + pipeline warnings integration#61

Merged
pasrom merged 3 commits intomainfrom
feat/merge-speaker-segments
Mar 22, 2026
Merged

feat(app): merge consecutive same-speaker segments + pipeline warnings integration#61
pasrom merged 3 commits intomainfrom
feat/merge-speaker-segments

Conversation

@pasrom
Copy link
Copy Markdown
Owner

@pasrom pasrom commented Mar 22, 2026

Summary

Cherry-picked from execsumo/meeting-transcriber fork:

  • Merge consecutive same-speaker segments — consecutive transcript segments from the same speaker are merged into single blocks with combined text and spanning timestamps, producing cleaner transcripts for protocol generation
  • addWarning() method on PipelineQueue with dedup guard (no writeSnapshot() overhead)
  • Pipeline warning integration — diarization failure adds warning, warning notification on job completion
  • 4 tests for addWarning (append, dedup, invalid ID, multiple distinct)
  • 5 tests for mergeConsecutiveSpeakers (basic, empty, single, all-same, all-different)

Changes

  • DiarizationProcess.swift: New mergeConsecutiveSpeakers() pure function
  • PipelineQueue.swift: addWarning() with dedup, mergeConsecutiveSpeakers applied after diarization, diarization failure warning, warning notification on completion

Test plan

  • 5 tests for mergeConsecutiveSpeakers edge cases
  • 4 tests for addWarning (dedup, invalid ID, multi)
  • Full suite: 763 tests, 0 failures
  • Lint: 0 violations

execsumo and others added 2 commits March 22, 2026 17:13
…ocks

Instead of emitting a separate line for each sentence-level segment,
consecutive segments from the same speaker are now merged into a single
block with combined text and spanning timestamps. This produces cleaner
transcripts for protocol generation.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@github-actions github-actions bot added the enhancement New feature or request label Mar 22, 2026
Prevents long monologs from merging into a single giant block by
breaking at pauses longer than 2 seconds. This produces natural
paragraph-like blocks even when only one speaker is present (e.g.
mic-only diarization in dual-source mode).
@pasrom pasrom force-pushed the feat/merge-speaker-segments branch from 7965383 to 9fb3b12 Compare March 22, 2026 16:48
@pasrom pasrom merged commit 115cbf7 into main Mar 22, 2026
6 checks passed
@pasrom pasrom deleted the feat/merge-speaker-segments branch March 22, 2026 16:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants