Skip to content

D131a — shell: each line of a transcript says who spoke, named by the user — one line, or a voice everywhere - #1406

Draft
kitokey-lina[bot] wants to merge 8 commits into
mainfrom
d131-each-line-of-a-transcript-says-who-spoke
Draft

kitokey-lina[bot] wants to merge 8 commits into
mainfrom
d131-each-line-of-a-transcript-says-who-spoke

Conversation

@kitokey-lina

@kitokey-lina kitokey-lina Bot commented Nov 30, 2026 •

Copy link
Copy Markdown
Contributor

For the decider, in one sentence: on a finished transcript, the name on each line is now a button: you give that line to someone (« Maya »), or name every line of its voice at once, and the names stay with the meeting.

flowchart LR
    L["A line's speaker<br/>(a button, once complete)"]:::new --> F["« Qui parle sur cette ligne ? »<br/>the meeting's names offered"]:::new
    F -->|« Cette ligne seulement »| O["that line alone: voice #n, given<br/>transcript.jsonl replaced whole"]:::new
    F -->|« Toutes les lignes de cette voix »| V{"its voice"}:::ask
    V -->|not told| S["its side named<br/>(#1205's me / others)"]:::old
    V -->|#n, a person's| N["speakers.json voices<br/>remote/#n → name"]:::new
    V -->|a producer's label| P["a #n of the person's own<br/>on each of its lines, then named"]:::new
Loading

Legend: green is new in this pull request; grey is on main; the dark node is the question the shell answers.

Module

shell, exactly one: src/voices.rs (new), src/speakers.rs, src/correction.rs (two helpers made pub(crate)), src/main.rs, src/words.rs, ui/window.js, ui/window.css, tests/voices.rs (new), scripts/e2e_window.py, src/lib.rs.

  • This pull request touches a single module

Deliverable

Deliverable: D131

D131 (cycle 12, P2): « Given a meeting's transcript, when the user names the speaker of one line, then that line takes the name, written as transcript/v1 lets the shell write it (#1251); when they name a voice, every line of that voice takes it (speakers.json); a redo keeps both, as the contract's key says; held by the e2e and the shell's tests ».

This pull request holds the first two clauses. « A redo keeps both » is D131b (d131b-voices-kept-across-a-redo, on top of this one), split off for the review budget. Until D131b merges, a redo leaves the given voices in transcript-previous.jsonl and does not say so: see Risks.

What it changes

Where On main Here
A line's speaker, complete transcript, v3 meeting a label: « Vous », « Les autres », or the side's name (#1205) a button whose text is the same name. Its accessible name is « Maya : changer qui parle à 0:03 », which includes the visible name (WCAG 2.5.3). It follows the line in the order of Tab, as the pencil does (D62)
Pressed — « Qui parle sur cette ligne ? » opens under the line: one labelled field with the meeting's names offered (datalist), and two choices, « Cette ligne seulement » (the default) and « Toutes les lignes de cette voix ». Enter saves; Escape or « Annuler » closes it as it was. Either way the focus goes back to the line's speaker. A blank name is said under the field (« Saisissez un nom, ou appuyez sur Échap pour annuler. »), nothing asked of the shell. A name the shell refuses says why (« Nom non enregistré : … », the shell's own words, role=alert). What was typed stays either way
One line named — transcript/v1 « a voice given » (#1244): that segment alone gets a label of the person's own (#1, #2…) and given = the instant. The file is replaced whole: written beside, then renamed. speakers.json voices gets remote/#1 → Maya (session-audio/v3). The same name on the same track reuses its label
A voice named — A #n label: its name changes and the transcript stays untouched. No voice (null): its side is named, as #1205 does. A producer's label: each of its lines first gets a #n of the person's own, because a producer's label holds within one transcript only (transcript/v1)
Refused — Before complete, while the transcript is being made or is waiting, while its summary is being written, before v3, or a blank name, or one over 60 characters: nothing is written. These are the same gates as a correction (D62). The gate while the transcript or summary is being made is not covered by a test. It is D62's code, copied into voice_given, and an e2e check of it would race the transcription stand-in. No name is ever logged
Window redrawn on focus the speakers' panel is kept (#1205) this field is kept the same way

Prior art (#1230's research, 2026-11-25, sources there). Fireflies renames a speaker on one line or on every line of its label. Those two scopes are the convention kept here. Otter does the same, and MacWhisper adds merging and reassigning by shortcut. Granola stops at « Me / Them », where Kitokey stood with #1205. The market is moving to on-device diarization (MacWhisper 12+, sherpa-onnx). Its labels will land in voice, and naming one is already handled here (a producer's label). Left out:

  • recognizing a voice across meetings: it is a voiceprint, biometric data (GDPR art. 9, transcript/v1 « never »);
  • merging two voices: one name typed on both does it;
  • shortcuts;
  • the summary taking the per-line names: it reads speakers.json as Request: give a meeting's voices their speakers' names #1205 left it.

Oracle

  • Red, b3929e7 (the oracle on a voices stub that refuses everything): cargo test --test voices: 0 passed, 8 failed. Each test fails on the stub's Err(File("not built")).
  • Red e2e, b3929e7: speakers_by_line 3 FAIL (« each line's speaker is a button », « Enter … opens « Qui parle sur cette ligne ? » », axe with no field), then raised a StaleElementReferenceException on a button held across a redraw (logs/partial-i-lina-d131-red-b3929e75-e2e.txt). Fixed at ef71797: the scenario holds ids, never references, so it fails there and never crashes.
  • Green at 7964290: cargo test 602 passed, 0 failed; cargo fmt --check and clippy --all-targets -D warnings clean.
  • Green e2e at 7964290: DJ speakers_by_line, speakers_named, transcript_corrected, corrections_gated (run queued). Since ines' reading at fd45399, DJ also checks: the accessible name, the speaker following its line in the order of Tab (D62), the field kept when the window comes back, the blank name, and the log holding shell.voice_given before it is read for names. An earlier run at a2c6f62, D131b's tree: 57 ok, 4 FAIL, all from the second naming on. A name the meeting holds is offered under the field, and its first Enter takes the suggestion (APG's combobox); the scenario now presses Enter again (logs/partial-i-lina-d131-green-a2c6f624-e2e.txt).

Kind of oracle: the shell's tests (tests/voices.rs, 6 here, 2 more in D131b) and the window's e2e, DJ (speakers_by_line).

Verifier

ines (named by the coordinator, 2026-11-30). Merge order: after #1333, before #1397.

Review budget

  • nstack pr-scope: 798 lines of 800, 10 files of 15, at 7964290.

Test sheet

# Given · when · then Kind Result Evidence Commit Confirmed
S1 Given a complete v3 transcript, when a line's speaker is pressed by the keyboard (Enter), then « Qui parle sur cette ligne ? » opens, its field focused and labelled, « Cette ligne seulement » chosen; axe finds no violation automated
S2 Given the field, when Escape is pressed, then nothing is written and the focus is back on the line's speaker automated
S3 Given one line named « Maya », then that line alone says Maya, its segment voice: "#1" with given, speakers.json voices {"remote/#1": "Maya"}; the same name on another line is #1 too automated
S4 Given « Toutes les lignes de cette voix » and « Maya Durand », then every line of #1 says it, the others as they were; read again with the meeting, the names stay automated
S5 Given the window, when the names are given, then no name is in the log automated
S6 Given a producer's label, a voice not told, a refusal (not complete, no line, blank, 61 characters, v2), then tests/voices.rs holds each case automated
S7 Given the running window at 420 px and in dark mode, when a line's speaker is named, then the field fits the pane and the focus ring shows on the speaker explored

Summary

DONE

  • Each line's speaker is a button once complete; it names that line alone, or every line of its voice.
  • voices.rs writes voice and given as transcript/v1 lets the shell, and the names in speakers.json voices.

VERIFIED

  • cargo test: 602 passed, 0 failed at 7964290; red, 8 failed at b3929e7.

ASSUMED

  • The summary keeps reading the two sides alone. Telling it the per-line names is not in D131's criterion.

NOT VERIFIED

  • The refusal while the transcript or its summary is being made: no test (D62's gate, copied).
  • The e2e, red and green: queued. Before/after shots: to be taken from the green run.

RISKS

  • Until D131b merges, a redo drops the given voices from the version shown without saying so. They stay in transcript-previous.jsonl, and « Versions » brings them back. D131b follows directly.

🤖 Generated with Claude Code

kitokey-lina Bot and others added 7 commits November 30, 2026 15:09
…ser: a name given to one line, or to a voice everywhere

Agent-Session: a9706e0b-8e19-4419-9d88-76384b634747
…a voice everywhere, kept across a redo

tests/voices.rs (8 tests) on a `voices` stub that refuses everything: a name
given to one line gives it alone a voice of the person's own (`#1`, `given`),
its name in speakers.json's `voices`; the same name is the same voice; a name
given to a voice names every line of it (a voice not told: its side, as
#1205); a producer's label is given a label of the person's own first;
refusals write nothing; a transcript made again carries the voices given by
their stretch of the clock, the one given last within two, and returns the
given lines it cannot find (transcript/v1, #1244, #1251).

e2e speakers_by_line: the same three criteria through the window, by
keyboard alone, axe on the open field, no name logged.

Agent-Session: a9706e0b-8e19-4419-9d88-76384b634747
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ne line, a voice everywhere, kept across a redo

voices.rs: a name given to one line gives it alone a label of the person's
own (`#n`, `given`), its name in speakers.json's `voices`; the same name on
the same track is the same label; a name given to a voice renames its label,
names its side when no voice is told (#1205), and gives a producer's label a
label of the person's own first (transcript/v1, #1244). A transcript made
again takes the voices given by each segment's stretch of the clock, the one
given last within two, under the making's lock, before its summary reads it.

The window: each line's speaker is a button, once complete in a v3 meeting,
its name « {who} : changer qui parle à {time} »; it opens « Qui parle sur
cette ligne ? » under the line — « Cette ligne seulement » or « Toutes les
lignes de cette voix », the meeting's names offered —, Enter saves, Escape
closes it, the focus back on the line's speaker. The lines a redo found no
line for are said on the transcript, the previous version keeping them.

cargo test: 604 passed, 0 failed; fmt and clippy -D warnings clean.

Agent-Session: a9706e0b-8e19-4419-9d88-76384b634747
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… moves to D131b

What D131a holds: one line named, a voice named, by the window and by
voices.rs (criteria 1 and 2). The transcript made again keeping them
(criterion 3, voices::carried, the page saying the lines it found none
for) is D131b, the next pull request on this one: 741 + 16 lines here.

cargo test: 602 passed, 0 failed; fmt and clippy -D warnings clean.

Agent-Session: a9706e0b-8e19-4419-9d88-76384b634747
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ss a redraw; the suggestion's Enter taken

The red at b3929e7 raised a StaleElementReferenceException on a button held
across the page's redraw: the oracle now fails there, never crashes. The
green at a2c6f62 failed from the second naming on: a name the meeting holds
is offered under the field and its first Enter takes the suggestion (APG's
combobox); the scenario presses Enter again when the field is still open.

Agent-Session: a9706e0b-8e19-4419-9d88-76384b634747
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…the oracle holding the accessible name, Tab and the redraw

- A blank name: « Saisissez un nom, ou appuyez sur Échap pour annuler. »
  under the field, what was typed kept, nothing asked of the shell; a name
  not kept says why (« Nom non enregistré : … »), never « ces noms ».
- speakers_by_line is DJ (handoff-common l.77). It now checks: the
  accessible name (WCAG 2.5.3), the speaker following its line in the order
  of Tab (D62), the field kept when the window comes back, the blank name,
  and the log holding shell.voice_given before it is read for names.

cargo test: 602 passed, 0 failed; fmt and clippy -D warnings clean.

Agent-Session: a9706e0b-8e19-4419-9d88-76384b634747
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…:voices, two refusals as one, the redo's model left to D131b

cargo test: 602 passed, 0 failed; fmt and clippy -D warnings clean.

Agent-Session: a9706e0b-8e19-4419-9d88-76384b634747
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… — and the field selected by script

The green at 7964290 failed twice on the oracle, never the product: a
meeting with no sound has no line in the order of Tab (got role None,
tabIndex -1 on each line, 0 on each speaker), so D62's roving was never
reached — DJ's meeting now plays, as AB's; and ActionChains' Ctrl+A typed
an « a » (got « aPersonne ») — the field is selected by script. The redo's
helpers (idle, the transcript set aside) are D131b's.

Agent-Session: a9706e0b-8e19-4419-9d88-76384b634747
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants