(
question: str,
history: List[List[str] | None] = None
)
| 70 | |
| 71 | |
| 72 | def audio_generation_tool( |
| 73 | question: str, |
| 74 | history: List[List[str] | None] = None |
| 75 | ) -> Tuple[Tuple[str, str], QuestionType]: |
| 76 | text = extract_audio_text(question, history) |
| 77 | lang = extract_language(question) |
| 78 | gender = extract_gender(question) |
| 79 | model_name = get_tts_model_name(lang=lang, gender=gender) |
| 80 | audio_file = generate_audio(text, model_name) |
| 81 | return (audio_file, "语音"), QuestionType.AUDIO |
| 82 | |
| 83 | |
| 84 | def video_generation_tool( |
nothing calls this directly
no test coverage detected