Retrieval Service efficiency optimization (#13543)

This commit is contained in:
Charlie.Wei
2025-02-17 14:09:57 +08:00
committed by GitHub
parent 566e548713
commit 222df44d21
2 changed files with 170 additions and 124 deletions

View File

@@ -1,3 +1,4 @@
import os
from typing import Any, Literal, Optional
from urllib.parse import quote_plus
@@ -166,6 +167,11 @@ class DatabaseConfig(BaseSettings):
default=False,
)
RETRIEVAL_SERVICE_WORKER: NonNegativeInt = Field(
description="If True, enables the retrieval service worker.",
default=os.cpu_count(),
)
@computed_field
def SQLALCHEMY_ENGINE_OPTIONS(self) -> dict[str, Any]:
return {