Skip to content

Commit 222df44

Browse files
authored
Retrieval Service efficiency optimization (langgenius#13543)
1 parent 566e548 commit 222df44

File tree

2 files changed

+170
-124
lines changed

2 files changed

+170
-124
lines changed

api/configs/middleware/__init__.py

+6
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
import os
12
from typing import Any, Literal, Optional
23
from urllib.parse import quote_plus
34

@@ -166,6 +167,11 @@ def SQLALCHEMY_DATABASE_URI(self) -> str:
166167
default=False,
167168
)
168169

170+
RETRIEVAL_SERVICE_WORKER: NonNegativeInt = Field(
171+
description="If True, enables the retrieval service worker.",
172+
default=os.cpu_count(),
173+
)
174+
169175
@computed_field
170176
def SQLALCHEMY_ENGINE_OPTIONS(self) -> dict[str, Any]:
171177
return {

0 commit comments

Comments
 (0)