#834 openai.RateLimitError: Error code: 429 - {'error': {'message': 'Provider returned error', 'code': 429, 'metadata': {'raw

*84.161* Posted at: 3 hours ago 👁7

请求频繁触发429,请调大暂停时间: Error code: 429 - {'error': {'message': 'Provider returned error', 'code': 429, 'metadata': {'raw': 'moonshotai/kimi-k2:free is temporarily rate-limited upstream. Please retry shortly, or add your own key to accumulate your rate limits: https://openrouter.ai/settings/integrations', 'provider_name': 'OpenInference'}}, 'user_id': 'user_32BnJHMIYVOTXPPEth3eE9u6bzY'}:Traceback (most recent call last):

File "videotrans\util\TestSrtTrans.py", line 17, in run

File "videotrans\translator\__init__.py", line 850, in run

File "videotrans\translator\_base.py", line 81, in run

File "tenacity\__init__.py", line 480, in __call__

File "videotrans\translator\_openrouter.py", line 56, in _item_task

File "openai\_utils\_utils.py", line 287, in wrapper

File "openai\resources\chat\completions\completions.py", line 1150, in create

File "openai\_base_client.py", line 1259, in post

File "openai\_base_client.py", line 1047, in request

openai.RateLimitError: Error code: 429 - {'error': {'message': 'Provider returned error', 'code': 429, 'metadata': {'raw': 'moonshotai/kimi-k2:free is temporarily rate-limited upstream. Please retry shortly, or add your own key to accumulate your rate limits: https://openrouter.ai/settings/integrations', 'provider_name': 'OpenInference'}}, 'user_id': 'user_32BnJHMIYVOTXPPEth3eE9u6bzY'}

=====

Windows-10-10.0.26100-SP0

version:v3.80

frozen:True

language:zh

1 Replies

本条内容由 DeepSeek 回复
这个错误是由于您使用的 OpenRouter.ai 翻译渠道触发了频率限制(429错误)。具体来说,您正在使用免费版的 moonshotai/kimi-k2:free 模型,该模型有严格的请求频率限制。

解决方案:

1. 增加暂停时间(最直接的解决方法):

  • 进入软件菜单 → 工具 → 高级选项
  • 在"翻译调整"部分,找到"翻译后暂停时间/秒"
  • 将数值调大,建议从默认值增加到 5-10 秒
  • 同时可以将"AI翻译每次发送字幕行数"调小,比如从默认值降到 1-2 行

2. 考虑使用其他翻译渠道

  • OpenRouter.ai 的免费模型限制较严格,建议尝试其他翻译渠道
  • 如 Google 翻译、Microsoft 翻译等传统渠道
  • 或者使用其他 AI 翻译渠道如 Gemini、DeepSeek 等

3. 添加自己的 API 密钥

  • 按照错误提示,您可以在 OpenRouter.ai 网站添加自己的 API 密钥
  • 这样可以使用更高的频率限制

4. 批量翻译时注意事项

  • 如果您在进行批量翻译,建议减少同时处理的文件数量
  • 或者将大文件分批处理

这个错误不会影响软件的正常功能,只是需要调整请求频率来适应第三方服务的限制。

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