From 7647193b40735a77fb5b75df62f496371477ab11 Mon Sep 17 00:00:00 2001 From: zxstty Date: Fri, 31 Oct 2025 17:21:16 +0800 Subject: [PATCH] =?UTF-8?q?=E5=BB=B6=E9=95=BFrag=E7=9A=84=E6=A3=80?= =?UTF-8?q?=E7=B4=A2=E6=97=B6=E9=97=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- apps/services/rag.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/apps/services/rag.py b/apps/services/rag.py index eb565791..0509eedc 100644 --- a/apps/services/rag.py +++ b/apps/services/rag.py @@ -249,7 +249,7 @@ Please generate a detailed, well-structured, and clearly formatted answer based tokensLimit=max_tokens, ) try: - async with httpx.AsyncClient(timeout=30) as client: + async with httpx.AsyncClient(timeout=300) as client: data_json = tmp_data.model_dump( exclude_none=True, by_alias=True) response = await client.post(url, headers=headers, json=data_json) @@ -260,7 +260,7 @@ Please generate a detailed, well-structured, and clearly formatted answer based logger.error(f"[RAG] 获取文档分片失败: {e}") if data.kb_ids: try: - async with httpx.AsyncClient(timeout=30) as client: + async with httpx.AsyncClient(timeout=300) as client: data_json = data.model_dump( exclude_none=True, by_alias=True) response = await client.post(url, headers=headers, json=data_json) -- Gitee