Skip to content

Generalize audio device selection to preflight checks (input selection & non-Meet output routing) #206

Closed

Description

@s4512138

Summary

Currently, media preflight verifies microphone activity via passive volume threshold checks (audio-check.js) and audio output via subjective confirmation tone, without allowing candidates to pick specific hardware devices. While audio-output.js already implements robust output routing via setSinkId and device enumeration, it is strictly bound to Google Meet tab-presentation mode (meetOutputSelect).

I propose adding a microphone (audioinput) selector to the preflight gate and making audio output selection available for standard interview sessions.

Current Implementation Analysis

  1. Audio Input:
    • audio-check.js checks micPeak >= MIC_SILENT_PEAK against pool.trackOf("audio").
    • Candidates with multiple microphones (e.g., built-in laptop mic vs. external USB condenser / headset) have no way to choose which device feeds into the preflight check or LiveKit room without altering OS-level defaults.
  2. Audio Output:
    • audio-output.js already provides serialized setSinkId routing and device enumeration (refreshAudioOutputs, applyAudioOutput).
    • However, this is only rendered under nodes.meetOutputRow when presenting in Google Meet, leaving standard sessions unable to route Jim's voice explicitly to headphones.

Motivation

  • Built-in microphones often capture loud mechanical keyboard clicking during the REACTO coding phase, reducing Jim's speech recognition accuracy.
  • Multi-monitor setups often set HDMI/DisplayPort monitor speakers as the OS default, causing echo unless the user manually alters system settings before opening CodeTrial.

Proposed Changes

  1. Preflight Microphone Selector:
    • Query navigator.mediaDevices.enumerateDevices() for kind === 'audioinput'.
    • Expose a <select> dropdown in the preflight gate to pass a specific deviceId constraint to the media track pool.
  2. Expose Output Selection in Preflight:
    • Decouple the device selection logic in audio-output.js from meet-audio.js / nodes.meetOutputRow so that candidates can route Jim's audio to their desired output device directly from the preflight screen.

References

  • web/audio-output.js: refreshAudioOutputs(), applyAudioOutput()
  • web/audio-check.js: preflightReadiness(), mediaReadiness()

Activity

  1. changed the title [-][Feature Request] Generalize audio device selection to preflight checks (input selection & non-Meet output routing)[/-] [+]Generalize audio device selection to preflight checks (input selection & non-Meet output routing)[/+] on Oct 1, 2026
  2. jserv commented on Oct 5, 2026

    @jserv
    Contributor

    @s4512138 Accepted as scoped: a microphone selector in the preflight, and the output selector from web/audio-output.js offered outside Meet mode as well. Keep the default device as the default, so a candidate who picks nothing sees no change. #44 and #197 (a silent test tone on some drivers) may be helped by choosing the output explicitly; note in the pull request whether you could check that.

  3. s4512138 commented on Oct 12, 2026

    @s4512138
    ContributorAuthor

    I am working on this change following the agreed scope.

  4. jserv commented on Oct 20, 2026

    @jserv
    Contributor

    @s4512138 On 2026-10-12 you said you were working on the scope accepted on 2026-10-05, and no pull request has appeared since. Is it still coming? If there is no reply by 2026-10-27, the assignment is removed and the issue stays open for anyone else to take, with Closes #206.

  5. s4512138 commented on Oct 20, 2026

    @s4512138
    ContributorAuthor

    @jserv Yes I am still working on the change, thank you.

  6. added 3 commits that reference this issue on Oct 21, 2026
    94144c4
    ad2e6b9
    6d7351e
  7. added a commit that references this issue on Oct 22, 2026
    bb97ed6
  8. jserv commented on Oct 23, 2026

    @jserv
    Contributor

    Status of the open pull requests that reference this issue:

    @s4512138 the next step is the open review threads on #411.

  9. added a commit that references this issue on Oct 23, 2026
    30da05b
  10. added 2 commits that reference this issue on Oct 23, 2026
    278e749
    1ee77c2
  11. added a commit that references this issue on Oct 23, 2026
    b4fe940
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions