import{b as l,i as t}from"./useflows-BpG3C9m1.js";import{e}from"./main-few-lands-burn.js";import{s as d,h as a}from"./machine.-BRuqPpdF.js";import{h as _,c as E}from"./commonut-BBfXq81f.js";import"./mutative-C6xjlr6O.js";import"./lodash-YpNkAOPN.js";const g=l(({helpers:n})=>({states:{components:[E(n),{componentName:n.componentName.select,fieldType:"config",helperText:e("Select the model to use for speech-to-text conversion."),id:"model-id",isMappable:!0,label:e("Model"),onChange:"HANDLE_MODEL_CHANGE",optionFilterProp:"label",options:[{label:e("Scribe V1"),value:"scribe_v1"},{label:e("Scribe V2"),value:"scribe_v2"}],render:"IF_CONNECTION_SELECTED",required:!0,showSearch:!0,value:void 0},{componentName:n.componentName.mixInput,helperText:e("Enter the URL of the audio file to transcribe."),id:"file-url",label:e("File URL"),onChange:"SET_FILE_URL",path:"cloud_storage_url",render:"IF_MODEL_SELECTED",required:!0,value:[]},{componentName:n.componentName.mixInput,helperText:e('Language code for the audio (e.g., "en" for English, "es" for Spanish). Optional.'),id:"language-code",label:e("Language Code"),onChange:"SET_LANGUAGE_CODE",path:"language_code",render:"IF_MODEL_SELECTED",value:[]},{componentName:n.componentName.switch,helperText:e("Enable tagging of audio events in the transcription."),id:"tag-audio-events",label:e("Tag Audio Events"),onChange:"SET_TAG_AUDIO_EVENTS",path:"tag_audio_events",render:"IF_MODEL_SELECTED",size:"small",value:!1}]},actions:{CONNECTION_ADD_CHANGE:_,HANDLE_MODEL_CHANGE:a("model_id"),IF_CONNECTION_SELECTED:({$:o})=>t(o.getComponent("connection-id")?.value),SET_FILE_URL:a("file_url"),SET_LANGUAGE_CODE:a("language_code"),SET_TAG_AUDIO_EVENTS:a("tag_audio_events"),IF_MODEL_SELECTED:({$:o})=>t(o.getComponent("connection-id")?.value)&&t(o.getComponent("model-id")?.value),SET_CONNECTION:({$:o,e:i})=>{a("connectionId")({$:o,e:i})},ON_MACHINE_LOAD:({$:o})=>{d(o,[{db:"connectionId",id:"connection-id"},{db:"model_id",id:"model-id"},{db:"file_url",id:"file-url"},{db:"language_code",id:"language-code"},{db:"tag_audio_events",id:"tag-audio-events"}])}}}));export{g as default};
