Skip to content

Conversation

@shaohuzhang1
Copy link
Contributor

fix: When automatic sending is not selected, the text conversion should be displayed in the position of the question input box

…ld be displayed in the position of the question input box
@f2c-ci-robot
Copy link

f2c-ci-robot bot commented Apr 22, 2025

Adding the "do-not-merge/release-note-label-needed" label because no release-note block was detected, please follow our release note process to remove it.

Details

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@f2c-ci-robot
Copy link

f2c-ci-robot bot commented Apr 22, 2025

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by:

The full list of commands accepted by this bot can be found here.

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

other_list: uploadOtherList.value
})
inputValue.value = ''
uploadImageList.value = []
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The code has several improvements. First, redundant checks can be removed for recorderStatus.value in the uploadRecording function. Additionally, you should use an await keyword when calling .emit() inside .then() to ensure correct flow handling of asynchronous operations.

Updated Code:

@@ -688,13 +688,7 @@ const uploadRecording = async (audioBlob: Blob) => {
   recorderStatus.value = 'TRANSCRIBING'

   const formData = new FormData();
   formData.append('file', audioBlob, 'recording.mp3');

-  if (props.applicationDetails.stt_autosend) {
-    bus.emit('on:transcribing', true);
-  } else {
-    // Optional message or status update here
-  }

+  bus.emit('on:transcribing', true);

   try {
     const response = await applicationApi.postSpeechToText(
       props.applicationDetails.id as string,
       formData
     );

In addition, there's a small typo which can be fixed by using single quotes throughout:

Original line with double quotes:

'other_list': uploadOtherList.value,

Corrected version:

'other_list': uploadOtherList.value

@shaohuzhang1 shaohuzhang1 merged commit 9c56c7e into main Apr 22, 2025
4 checks passed
@shaohuzhang1 shaohuzhang1 deleted the pr@main@fix_stt branch April 22, 2025 03:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants