#1663 TaskCfg(cache_folder='H:/win-pyvideotrans-v3.85/tmp28584/f6e8fa87a8', target_dir='H:/xiazai/_video_out/Nothing and Nobod

185.220* Posted at: 10 days ago 👁31

翻译字幕阶段出错:[OpenAI ChatGPT] 运行时错误:[OpenAIChatGPT]content_filter:ChatCompletion(id='chatcmpl-Cgv4RNyeynIKqmfZwyzTWSwIWXTW7', choices=[Choice(finish_reason='content_filter', index=0, logprobs=None, message=ChatCompletionMessage(content=None, refusal=None, role='assistant', annotations=[], audio=None, function_call=None, tool_calls=None))], created=1764345191, model='gpt-4o-mini', object='chat.completion', service_tier=None, system_fingerprint='fp_efad92c60b', usage=CompletionUsage(completion_tokens=72, prompt_tokens=579, total_tokens=651, completion_tokens_details=CompletionTokensDetails(accepted_prediction_tokens=0, audio_tokens=0, reasoning_tokens=0, rejected_prediction_tokens=0), prompt_tokens_details=PromptTokensDetails(audio_tokens=0, cached_tokens=0))):
Traceback (most recent call last):
File "videotrans\translator\_base.py", line 77, in run
File "videotrans\translator\_base.py", line 137, in _run_srt
File "tenacity\__init__.py", line 338, in wrapped_f
File "tenacity\__init__.py", line 477, in call
File "tenacity\__init__.py", line 378, in iter
File "tenacity\__init__.py", line 421, in exc_check
tenacity.RetryError: RetryError[]

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "videotrans\task\job.py", line 184, in run
File "videotrans\task\trans_create.py", line 417, in trans
File "videotrans\translator\__init__.py", line 907, in run
File "videotrans\translator\_base.py", line 80, in run
File "tenacity\__init__.py", line 480, in call
File "videotrans\translator\_chatgpt.py", line 168, in _item_task
RuntimeError: [OpenAIChatGPT]content_filter:ChatCompletion(id='chatcmpl-Cgv4RNyeynIKqmfZwyzTWSwIWXTW7', choices=[Choice(finish_reason='content_filter', index=0, logprobs=None, message=ChatCompletionMessage(content=None, refusal=None, role='assistant', annotations=[], audio=None, function_call=None, tool_calls=None))], created=1764345191, model='gpt-4o-mini', object='chat.completion', service_tier=None, system_fingerprint='fp_efad92c60b', usage=CompletionUsage(completion_tokens=72, prompt_tokens=579, total_tokens=651, completion_tokens_details=CompletionTokensDetails(accepted_prediction_tokens=0, audio_tokens=0, reasoning_tokens=0, rejected_prediction_tokens=0), prompt_tokens_details=PromptTokensDetails(audio_tokens=0, cached_tokens=0)))

TaskCfg(cache_folder='H:/win-pyvideotrans-v3.85/tmp28584/f6e8fa87a8', target_dir='H:/xiazai/_video_out/Nothing and Nobody Will Ever Hurt You Again – Carl Jung', remove_noise=False, is_separate=False, detect_language='en', subtitle_language=None, source_language='英语', target_language='简体中文', source_language_code='en', target_language_code='zh-cn', source_sub='H:/xiazai/_video_out/Nothing and Nobody Will Ever Hurt You Again – Carl Jung/en.srt', target_sub='H:/xiazai/_video_out/Nothing and Nobody Will Ever Hurt You Again – Carl Jung/zh-cn.srt', source_wav='H:/win-pyvideotrans-v3.85/tmp28584/f6e8fa87a8/en.wav', source_wav_output='H:/xiazai/_video_out/Nothing and Nobody Will Ever Hurt You Again – Carl Jung/en.m4a', target_wav='H:/win-pyvideotrans-v3.85/tmp28584/f6e8fa87a8/target.wav', target_wav_output='H:/xiazai/_video_out/Nothing and Nobody Will Ever Hurt You Again – Carl Jung/zh-cn.m4a', subtitles='', novoice_mp4='H:/win-pyvideotrans-v3.85/tmp28584/f6e8fa87a8/novoice.mp4', noextname='Nothing and Nobody Will Ever Hurt You Again – Carl Jung', shibie_audio=None, targetdir_mp4='H:/xiazai/_video_out/Nothing and Nobody Will Ever Hurt You Again – Carl Jung/Nothing and Nobody Will Ever Hurt You Again – Carl Jung.mp4', instrument=None, vocal=None, back_audio='', background_music=None, app_mode='tiqu', subtitle_type=0, volume='+0%', pitch='+0Hz', voice_rate='+0%', voice_role='No', copysrt_rawvideo=True, clear_cache=True, translate_type=3, tts_type=0, recogn_type=0, model_name='large-v3-turbo', split_type=0, voice_autorate=False, video_autorate=True, cuda=True, name='H:/xiazai/Nothing and Nobody Will Ever Hurt You Again – Carl Jung.mp4', basename='Nothing and Nobody Will Ever Hurt You Again – Carl Jung.mp4', ext='mp4', dirname='H:/xiazai', shound_del_name=None, uuid='f6e8fa87a8', remove_silent_mid=False, align_sub_audio=True, enable_diariz=False, nums_diariz=0)


=
system:Windows-10-10.0.26200-SP0
version:v3.85
frozen:True
language:zh
root_dir:H:/win-pyvideotrans-v3.85

1 Replies

这个错误是由于 OpenAI 的内容安全过滤器触发了 content_filter 拒绝。当您提交的字幕内容被 OpenAI 系统判定为可能包含不当内容时,就会返回此错误。

解决方案:

  1. 更换翻译渠道:这是最直接的解决方法。在翻译设置中,将 OpenAI ChatGPT 更换为其他翻译渠道,例如:

    • Google 翻译
    • 微软翻译
    • DeepSeek
    • Gemini
  2. 检查字幕内容:如果必须使用 OpenAI,请检查原始字幕文件(位于 H:/xiazai/_video_out/Nothing and Nobody Will Ever Hurt You Again – Carl Jung/en.srt),查看是否有可能被误判为敏感的内容,并进行适当修改。
  3. 分批翻译:在“高级选项”的“字幕翻译调整”区域,将“每批字幕行数”设置为较小的数值(如 1 或 2),这有时可以避免触发内容过滤。

由于这是 OpenAI 服务端的策略限制,软件本身无法绕过。建议优先采用方案 1,更换翻译渠道。

Post Your Reply
Open source and free maintenance is not easy. If this project is helpful to you, please consider making a small donation to help the project continue to maintain and update.

Donate: https://ko-fi.com/jianchang512

Trending Questions