Your lightweight open-source personal agent.
Python agent-frameworkai-agentai-agentschatbotchatopsdiscord-botllm-agentsllmslocal-llmmcpmodel-context-protocolmulti-agentopenai-compatibleopenclawpersonal-ai-assistantpythonself-hostedtelegram-bot-ai-assistantwebuiworkflow-automation
fix(tools): correct DeepSeek Search rate-limit guidance
chengyongru29d0023fcadf
diff --git a/docs/configuration.md b/docs/configuration.mdindex eda37d498..95bcf3380 100644--- a/docs/configuration.md+++ b/docs/configuration.md@@ -2117,7 +2117,7 @@ AnySearch works out of the box with no key, via its anonymous quota (lower rateCreate a key at [platform.deepseek.com](https://platform.deepseek.com). Set `tools.web.search.apiKey` directly or with a `${VAR_NAME}` reference. Missing credentials cause a configuration error, with no provider fallback.-Queries are limited to 128 Unicode characters after trimming whitespace; longer queries are rejected. Pricing is ¥5 per 1,000 successful requests, with an account-wide limit of 5 QPS across API keys. See the [DeepSeek Search API documentation](https://api-docs.deepseek.com/zh-cn/guides/search/) for search syntax and billing details.+Queries are limited to 128 Unicode characters after trimming whitespace; longer queries are rejected. See the [DeepSeek Search API documentation](https://api-docs.deepseek.com/zh-cn/guides/search/) for search syntax, pricing, and account-wide rate limits.#### `tools.web.search`diff --git a/nanobot/agent/tools/web.py b/nanobot/agent/tools/web.pyindex e7ca4bb99..ac8ff96ca 100644--- a/nanobot/agent/tools/web.py+++ b/nanobot/agent/tools/web.py@@ -972,8 +972,8 @@ class WebSearchTool(Tool):)if r.status_code == 429:return ToolResult.error(- "Error: DeepSeek search rate limited after retry. The account "- "limit is 5 QPS; retry later or reduce the frequency of concurrent web_search calls."+ "Error: DeepSeek search rate limited after retry. "+ "Retry later or reduce the frequency of concurrent web_search calls.")if _deepseek_is_retryable(r.status_code):return ToolResult.error(diff --git a/tests/tools/test_web_search_tool.py b/tests/tools/test_web_search_tool.pyindex 1eee4aac1..425212949 100644--- a/tests/tools/test_web_search_tool.py+++ b/tests/tools/test_web_search_tool.py@@ -733,6 +733,11 @@ async def test_deepseek_search_gives_up_after_retry_budget(assert is_tool_error_result(result)assert expected_text in resultassert "after retry" in result+ if status == 429:+ assert result == (+ "Error: DeepSeek search rate limited after retry. "+ "Retry later or reduce the frequency of concurrent web_search calls."+ )@pytest.mark.asyncio