Skip to content

Commit

Permalink
增加配置参考音频
Browse files Browse the repository at this point in the history
  • Loading branch information
diudiu62 committed Jan 24, 2025
1 parent 22be063 commit fcbad3a
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion services/audio/cosyvoice_service.py
Original file line number Diff line number Diff line change
Expand Up @@ -88,13 +88,13 @@ def read_with_content(self, content):
def chat_with_content(self, content, audio_output_file):
# main infer params
if hasattr(self, 'refer_wav_path') and self.refer_wav_path:
print("1111:",self.prompt_text)
body = {
"mode": "zero_shot",
"tts_text": content,
"prompt_text": self.prompt_text,
"seed": self.audio_seed,
"speed": self.audio_speed,
"prompt_voice": self.refer_wav_path,
"stream":False,
"instruct_text": None,
"sft_dropdown": None,
Expand All @@ -110,6 +110,7 @@ def chat_with_content(self, content, audio_output_file):
"stream":False,
"prompt_text": None,
"instruct_text": None,
"prompt_voice": None,
}

print(body)
Expand Down

0 comments on commit fcbad3a

Please sign in to comment.