`$speak.AudioOutput = foreach ($o in $speak. The AudioNode interface is a generic interface for representing an audio processing module. This.baseCommand = "$speak = New-Object -ComObject SAPI.SPVoice " I have something similar to this: const childProcess = require('child_process') I'm not set on using Say as a module, it just seemed easy to use at first.Ī workaround I've settled with is making my own TTS class and using SpVoice. I'm pretty much stumped right now, so I'd appreciate any help please. The Cloud Speech Node.js Client API Reference documentation also contains. I've even gone as far as trying to change powershell's output device in app volume device preferences(img), but that seems to do nothing. The audio files encoding, sample rate in hertz, and BCP-47 language code. I first found out about navigator.MediaDevices, then I found how I could make an audio element and change the audio device of that element via setSinkId, then I realized these things are probably(?) irrelevant since the say module seems to play sounds using powershell commands. What I've found so far has been pretty useless, I'm guessing largely because I don't know the proper terminology to search for answers, regardless this is it: At the moment I'm using to produce the speechīut I've no clue on how I could go about choosing the audio output. I'm making a program that will output text to speech, the user will need to be able to change the output device (for example to virtual audio cable).