Record a meeting from both sides, and write its minutes

Who said what is the hard part of a meeting transcript, and the usual answer
is to hand one mixed recording to a model and ask it to tell the voices apart.
That guess is wrong often enough to be worse than useless in minutes, where a
decision attributed to the wrong person is a decision nobody made.

So the question never reaches a model. ffmpeg records the microphone and the
default sink's monitor as one stereo stream, you on the left and everyone else
on the right, and one process reading both is what keeps them aligned over an
hour. Each channel is transcribed on its own and the two are interleaved on a
single timeline, so attribution is settled by the wire a voice arrived on.
What a microphone picks up from the speakers lands on both channels; our copy
is dropped when it overlaps theirs in time and says nearly the same thing.

The stream is written to disk as it arrives rather than held in memory, so
length costs nothing and a crash costs the tail instead of the whole meeting.
Every stage the run reaches is recorded in meetings.jsonl, so a failure while
summarising does not throw away the transcription of an hour of audio: the
retry reads the transcript back out of the document and picks up from there.
A run that dies keeps its recording whether or not audio is being kept.

The minutes model is configured on its own, under Settings, with its own
prompt, and it is told who was expected in the room so the names come out
spelled right. It is told outright that the transcript is a record of other
people talking, not instructions addressed to it.

The built-in listener now holds several bindings rather than one, and the KDE
side is parameterised by desktop id, so the meeting toggle gets a shortcut of
its own on the same footing as the dictation one.
This commit is contained in:
yusufipk
2026-07-28 16:32:31 +07:00
parent 0bdee07564
commit 352f7b6c22
11 changed files with 1783 additions and 82 deletions
+11 -1
View File
@@ -46,6 +46,7 @@ yapıştırılır; modelin yanındaki kutudan düşünme seviyesini de seçebili
| --- | --- |
| Kaydı başlat / bitir | `Ctrl+Space`, ya da tepsi simgesine tıkla |
| Kaydı iptal et | Tepsi menüsü → *Kaydı iptal et*, ya da `dikte cancel` |
| Toplantıyı başlat / bitir | Tepsi menüsü → *Toplantı kaydet*, ya da `dikte meeting` |
| Ayarlar | Tepsi menüsü → *Ayarlar*, ya da `dikte settings` |
| Güncelleme sonrası yeniden yükle | Tepsi menüsü → *Yeniden başlat*, ya da `dikte restart` |
| Çık | Tepsi menüsü → *Çık*, ya da `dikte quit` |
@@ -79,6 +80,14 @@ süreyi, ardından hangi aşamada olduğunu gösterir. Odak almaz. Dikte çalı
- **Başarısız temizleme sessizce geçmez.** Dikte kaybolmasın diye ham transkript
yine yapıştırılır ama gösterge kehribar rengine döner ve nedenini söyler,
normal bir çalışma gibi görünmez.
- **Toplantılar** mikrofonla hoparlör çıkışından aynı anda kaydedilir; kimin ne
dediği tahmin edilmez, sesin hangi kanaldan geldiğiyle belli olur. İki taraf
ayrı ayrı yazıya çevrilip tek bir zaman damgalı transkriptte birleştirilir,
ardından Ayarlar → Toplantı sekmesinden seçtiğin ikinci bir model kendi
talimatıyla bunu tutanağa çevirir: kararlar, aksiyonlar, açık sorular. Sonuç
`~/.local/share/dikte/meetings` altına ve Ayarlar → Tutanaklar sekmesine
düşer. Yarıda kalan bir işlem ses kaydını saklar, yeniden denemede parası
ödenmiş transkriptin üstünden devam eder.
- **Ses ve video dosyaları** Ayarlar → Ses dosyası sekmesinde aynı modellerden
geçer; istersen `[dd:ss]` zaman damgalarıyla, uzun dosyalar ffmpeg ile
parçalanarak, sonuç `.txt` ya da `.srt` altyazı olarak kaydedilerek.
@@ -99,7 +108,8 @@ grubunda olmasını gerektirir: `sudo usermod -aG input $USER`.
```
dikte.py giriş noktası, tepsi simgesi, durum makinesi, IPC
audio.py pw-record ile ham PCM kaydı ve seviye ölçer
audio.py PCM kaydı: diktede pw-record, toplantıda ffmpeg
meeting.py kanal ayırma, konuşmacı etiketi, temizleme, tutanak
api.py iki sağlayıcıda transkript + OpenRouter temizleme (yalnız stdlib)
worker.py transkript → temizleme → pano → yapıştırma
vad.py kayıtta gerçekten konuşma var mı kararı