这是indexloc提供的服务,不要输入任何密码
Skip to content

TTS Optimization to generate speech lazily #2981

@anlagbr

Description

@anlagbr

Currently, all speech is generated sequentially. However, if the agent is interrupted mid-speech, some audio will not be played, and a significant cost will still be incurred (TTS is typically the most expensive component among STT, LLM, and TTS).

I propose generating speech in a more efficient manner. For instance, the initial speech segment could be generated immediately. Subsequently, there would be a 1.5-second delay (depending on the provider) before generating the next chunk of audio, coinciding with the completion of the current segment. This approach aims to minimize wasted computational resources and expenditure.

I couldn't find an official API solution for this problem.

Thanks.

Metadata

Metadata

Assignees

No one assigned

    Labels

    questionFurther information is requested

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions