mirror of
https://github.com/jambonz/jambonz-feature-server.git
synced 2025-12-20 16:50:39 +00:00
support jambonz transcribe sampling rate (#847)
* support jambonz transcribe sampling rate * fix review comment * update verb specification version
This commit is contained in:
@@ -837,6 +837,7 @@ module.exports = (logger) => {
|
||||
};
|
||||
} else if (vendor.startsWith('custom:')) {
|
||||
let {options = {}} = rOpts;
|
||||
const {sampleRate} = rOpts.customOptions || {};
|
||||
const {auth_token, custom_stt_url} = sttCredentials;
|
||||
options = {
|
||||
...options,
|
||||
@@ -846,12 +847,12 @@ module.exports = (logger) => {
|
||||
{hints: JSON.stringify(rOpts.hints)}),
|
||||
...(typeof rOpts.hintsBoost === 'number' && {hintsBoost: rOpts.hintsBoost})
|
||||
};
|
||||
|
||||
opts = {
|
||||
...opts,
|
||||
...(auth_token && {JAMBONZ_STT_API_KEY: auth_token}),
|
||||
JAMBONZ_STT_URL: custom_stt_url,
|
||||
...(Object.keys(options).length > 0 && {JAMBONZ_STT_OPTIONS: JSON.stringify(options)}),
|
||||
...(sampleRate && {JAMBONZ_STT_SAMPLING: sampleRate})
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user