#1366 openai.NotFoundError: Error code: 404 - {'error': {'message':

209.9* Posted at: 22 hours ago 👁22

请求的资源不存在,请检查模型名称或API地址 Error code: 404 - {'error': {'message': "model 'deepseek-chat' not found", 'type': 'api_error', 'param': None, 'code': None}}:Traceback (most recent call last):
File "videotrans\util\TestSrtTrans.py", line 19, in run
File "videotrans\translator\__init__.py", line 907, in run
File "videotrans\translator\_base.py", line 81, in run
File "videotrans\translator\_base.py", line 99, in _run_text
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 400, in
File "concurrent\futures\_base.py", line 439, in result
File "concurrent\futures\_base.py", line 391, in __get_result
File "tenacity\__init__.py", line 480, in call
File "videotrans\translator\_localllm.py", line 54, in _item_task
File "openai\_utils\_utils.py", line 286, in wrapper
File "openai\resources\chat\completions\completions.py", line 1156, in create
File "openai\_base_client.py", line 1259, in post
File "openai\_base_client.py", line 1047, in request
openai.NotFoundError: Error code: 404 - {'error': {'message': "model 'deepseek-chat' not found", 'type': 'api_error', 'param': None, 'code': None}}


=
system:Windows-10-10.0.26100-SP0
version:v3.84
frozen:True
language:zh
root_dir:G:/AI/win-videotrans-v3.84

3 Replies

这个错误表明 pyVideoTrans 无法找到您指定的 DeepSeek 模型 "deepseek-chat"。这通常是由于 API 地址配置不正确或模型名称错误导致的。

请按以下步骤检查和修正:

  1. 检查 API 地址

    • 在软件菜单栏选择 翻译设置 -> DeepSeek
    • 确认 API 地址为 DeepSeek 官方的正确地址:https://api.deepseek.com/v1
  2. 检查模型名称

    • 在同一个设置页面,确认模型名称填写正确
    • DeepSeek 的聊天模型名称应为:deepseek-chat(您当前使用的)或 deepseek-reasoner
    • 如果使用最新模型,可以尝试改为:deepseek-chat-001
  3. 验证 API Key

    • 确保您的 DeepSeek API Key 有效且已正确填入
    • 可以在 DeepSeek 官方控制台检查 API Key 的状态和余额
  4. 网络连接检查

    • 如果您的网络环境需要代理,请在翻译渠道设置中填写正确的代理地址

如果以上步骤仍无法解决问题,请提供完整的日志文件(位于 videotrans/logs/ 目录下)以便进一步分析。

使用ollama部署到本地的大模型的api,无法运行

无法连接到本地 Ollama 部署的模型,通常是由于 API 地址配置错误导致的。请按以下步骤检查和修正:

  1. 验证 Ollama 服务状态

    • 在命令行中运行 ollama serve 确保服务正在运行。
    • 运行 ollama list 确认您要使用的模型已正确下载并可用。
  2. 检查 pyVideoTrans 中的 API 地址

    • 在软件菜单栏选择 翻译设置 -> 兼容AI/本地模型
    • API 地址 必须填写为:http://localhost:11434/v1
    • 模型名称 填写您在 Ollama 中部署的模型的实际名称(例如:qwen2.5:7b, llama3.2:3b 等)。
  3. 验证配置

    • API Key 可以留空,或者任意填写(如 ollama)。
    • 确保没有启用网络代理,除非您的 Ollama 服务需要通过代理访问。

如果问题依旧,请提供 videotrans/logs/ 目录下的最新日志文件以便进一步诊断。

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

Similar issues already exist

Trending Questions