#4109 TaskCfgSTS(is_cuda=False, uuid='8751858ccd', cache_folder=None, target_dir='E:/2023/personal/inspo2/CN Course/Kana/W8',

202.150* Posted at: 1 hour ago 👁8

Trans Error [Local/Compatible AI] 'NoneType' object is not subscriptable
Traceback (most recent call last):
File "videotrans\translator\_base.py", line 102, in run
File "videotrans\translator\_base.py", line 165, 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 174, in run
File "videotrans\task\_translate_srt.py", line 45, in trans
File "videotrans\translator\__init__.py", line 970, in run
File "videotrans\translator\_base.py", line 105, in run
File "tenacity\__init__.py", line 480, in call
File "videotrans\translator\_localllm.py", line 71, in _item_task
TypeError: 'NoneType' object is not subscriptable
TaskCfgSTS(is_cuda=False, uuid='8751858ccd', cache_folder=None, target_dir='E:/2023/personal/inspo2/CN Course/Kana/W8', source_language=None, source_language_code='Simplified Chinese', source_sub='E:/2023/personal/inspo2/CN Course/Kana/W8/2.srt', source_wav=None, source_wav_output=None, target_language=None, target_language_code='English', target_sub='E:/2023/personal/inspo2/CN Course/Kana/W8/2.English.srt', target_wav=None, target_wav_output=None, name='E:/2023/personal/inspo2/CN Course/Kana/W8/2.srt', noextname='2', basename='2.srt', ext='srt', dirname='E:/2023/personal/inspo2/CN Course/Kana/W8', shound_del_name=None, translate_type=8)


=
system:Windows-10-10.0.26200-SP0
version:v3.97
frozen:True
language:en
root_dir:E:/ytrans

1 Replies

翻译渠道(兼容AI/本地模型)配置错误,导致API返回了空响应。

  1. 检查并配置本地AI模型或兼容AI接口的设置:

    • 点击菜单栏的 翻译设置
    • 选择 本地大模型设置
    • 确保 API URLAPI Key 填写正确。例如,对于Ollama,API URL通常是 http://localhost:11434/v1,模型名称如 qwen:latest
    • 如果使用其他兼容OpenAI的接口,请确保API地址和模型名称无误。
  2. 降低翻译并发请求:

    • 点击菜单栏的 工具/选项 -> 高级选项
    • 字幕翻译调整 区域,将 AI翻译渠道每批字幕行数 设置为一个较小的值(例如 5 或 10)。
    • 翻译后暂停秒 设置为 1 或 2,以降低请求频率。
  3. 如果问题依旧,请检查网络代理设置:

    • 如果使用的AI服务需要代理访问,请在主界面的 网络代理地址 中正确填写代理地址(例如 http://127.0.0.1:10808)。如果不需要代理,请留空。

请查阅相关文档:

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.

Related resource