src/Backend/src/api/adapters/google/speech_to_text.py [104:148]:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
                        new_transcript = await self._rerun_audio(
                            path=path,
                            desired=desired,
                            start_time=start_time,
                            last_time=last_time,
                            phrases=phrases_id,
                            words=words,
                            duration=duration,
                            i=i,
                            depth=depth + 1,
                            sample_rate=sample_rate,
                            channels=channels,
                        )
                        transcript_arr.extend(new_transcript.split(" "))
                        i += 1
                    else:
                        word_data = word_obj.word
                        transcript_arr.extend(
                            util.convert_number_to_written_text(
                                word_data, self.language
                            )
                            if word_data.isdecimal()
                            else [word_data]
                        )
                if depth < 2 and (total_time - last_time).total_seconds() >= 5.0:
                    new_transcript = await self._rerun_audio(
                        path,
                        desired,
                        start_time=last_time,
                        last_time=total_time,
                        phrases=phrases_id,
                        words=words,
                        duration=duration,
                        i=i,
                        depth=depth + 1,
                        sample_rate=sample_rate,
                        channels=channels,
                    )
                    transcript_arr.extend(new_transcript.split(" "))
            result_transc = " ".join(transcript_arr)
        except IndexError:
            return ""
        return result_transc

    async def create_phrase_set(self, phrases: list[dict[str, typing.Any]]) -> str:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -



src/Backend/src/api/adapters/google/speech_to_text_v2.py [402:446]:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
                                new_transcript = await self._rerun_audio(
                                    path=path,
                                    desired=desired,
                                    start_time=start_time,
                                    last_time=last_time,
                                    phrases=phrases_id,
                                    words=words,
                                    duration=duration,
                                    i=i,
                                    depth=depth + 1,
                                    sample_rate=sample_rate,
                                    channels=channels,
                                )
                                transcript_arr.extend(new_transcript.split(" "))
                                i += 1
                            else:
                                word_data = word_obj.word
                                transcript_arr.extend(
                                    util.convert_number_to_written_text(
                                        word_data, self.language
                                    )
                                    if word_data.isdecimal()
                                    else [word_data]
                                )
                    if depth < 2 and (total_time - last_time).total_seconds() >= 5.0:
                        new_transcript = await self._rerun_audio(
                            path,
                            desired,
                            start_time=last_time,
                            last_time=total_time,
                            phrases=phrases_id,
                            words=words,
                            duration=duration,
                            i=i,
                            depth=depth + 1,
                            sample_rate=sample_rate,
                            channels=channels,
                        )
                        transcript_arr.extend(new_transcript.split(" "))
            result_transc = " ".join(transcript_arr)
        except IndexError:
            return ""
        return result_transc

    async def create_phrase_set(self, phrases: list[dict[str, typing.Any]]) -> str:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -



