2024-10-21 10:03:40 +08:00
|
|
|
from typing import Annotated, Literal, Optional
|
|
|
|
|
|
|
|
from pydantic import (
|
|
|
|
AliasChoices,
|
|
|
|
Field,
|
|
|
|
HttpUrl,
|
|
|
|
NegativeInt,
|
|
|
|
NonNegativeInt,
|
|
|
|
PositiveFloat,
|
|
|
|
PositiveInt,
|
|
|
|
computed_field,
|
|
|
|
)
|
2024-07-07 12:18:15 +08:00
|
|
|
from pydantic_settings import BaseSettings
|
2024-06-19 13:41:12 +08:00
|
|
|
|
2024-06-22 17:41:17 +08:00
|
|
|
from configs.feature.hosted_service import HostedServiceConfig
|
|
|
|
|
2024-06-19 13:41:12 +08:00
|
|
|
|
2024-07-07 12:18:15 +08:00
|
|
|
class SecurityConfig(BaseSettings):
|
2024-06-19 13:41:12 +08:00
|
|
|
"""
|
2024-09-22 13:38:41 +08:00
|
|
|
Security-related configurations for the application
|
2024-06-19 13:41:12 +08:00
|
|
|
"""
|
2024-08-23 23:46:01 +08:00
|
|
|
|
2024-10-21 10:43:49 +08:00
|
|
|
SECRET_KEY: str = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Secret key for secure session cookie signing."
|
2024-08-23 23:46:01 +08:00
|
|
|
"Make sure you are changing this key for your deployment with a strong key."
|
2024-09-22 13:38:41 +08:00
|
|
|
"Generate a strong key using `openssl rand -base64 42` or set via the `SECRET_KEY` environment variable.",
|
2024-10-21 10:43:49 +08:00
|
|
|
default="",
|
2024-06-19 13:41:12 +08:00
|
|
|
)
|
|
|
|
|
2024-10-21 18:14:26 +08:00
|
|
|
RESET_PASSWORD_TOKEN_EXPIRY_MINUTES: PositiveInt = Field(
|
|
|
|
description="Duration in minutes for which a password reset token remains valid",
|
|
|
|
default=5,
|
2024-07-05 13:38:51 +08:00
|
|
|
)
|
2024-06-19 13:41:12 +08:00
|
|
|
|
2024-10-22 11:01:32 +08:00
|
|
|
LOGIN_DISABLED: bool = Field(
|
|
|
|
description="Whether to disable login checks",
|
|
|
|
default=False,
|
|
|
|
)
|
|
|
|
|
|
|
|
ADMIN_API_KEY_ENABLE: bool = Field(
|
|
|
|
description="Whether to enable admin api key for authentication",
|
|
|
|
default=False,
|
|
|
|
)
|
|
|
|
|
|
|
|
ADMIN_API_KEY: Optional[str] = Field(
|
|
|
|
description="admin api key for authentication",
|
|
|
|
default=None,
|
|
|
|
)
|
|
|
|
|
2024-07-17 02:31:30 +08:00
|
|
|
|
2024-07-07 12:18:15 +08:00
|
|
|
class AppExecutionConfig(BaseSettings):
|
2024-06-19 13:41:12 +08:00
|
|
|
"""
|
2024-09-22 13:38:41 +08:00
|
|
|
Configuration parameters for application execution
|
2024-06-19 13:41:12 +08:00
|
|
|
"""
|
2024-08-23 23:46:01 +08:00
|
|
|
|
2024-06-19 13:41:12 +08:00
|
|
|
APP_MAX_EXECUTION_TIME: PositiveInt = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Maximum allowed execution time for the application in seconds",
|
2024-06-19 13:41:12 +08:00
|
|
|
default=1200,
|
|
|
|
)
|
2024-07-10 21:31:35 +08:00
|
|
|
APP_MAX_ACTIVE_REQUESTS: NonNegativeInt = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Maximum number of concurrent active requests per app (0 for unlimited)",
|
2024-07-10 21:31:35 +08:00
|
|
|
default=0,
|
|
|
|
)
|
2024-06-19 13:41:12 +08:00
|
|
|
|
|
|
|
|
2024-07-07 12:18:15 +08:00
|
|
|
class CodeExecutionSandboxConfig(BaseSettings):
|
2024-06-19 13:41:12 +08:00
|
|
|
"""
|
2024-09-22 13:38:41 +08:00
|
|
|
Configuration for the code execution sandbox environment
|
2024-06-19 13:41:12 +08:00
|
|
|
"""
|
2024-08-23 23:46:01 +08:00
|
|
|
|
2024-08-27 19:38:33 +08:00
|
|
|
CODE_EXECUTION_ENDPOINT: HttpUrl = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="URL endpoint for the code execution service",
|
2024-08-23 23:46:01 +08:00
|
|
|
default="http://sandbox:8194",
|
2024-06-19 13:41:12 +08:00
|
|
|
)
|
|
|
|
|
|
|
|
CODE_EXECUTION_API_KEY: str = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="API key for accessing the code execution service",
|
2024-08-23 23:46:01 +08:00
|
|
|
default="dify-sandbox",
|
2024-06-19 13:41:12 +08:00
|
|
|
)
|
|
|
|
|
2024-08-27 19:38:33 +08:00
|
|
|
CODE_EXECUTION_CONNECT_TIMEOUT: Optional[float] = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Connection timeout in seconds for code execution requests",
|
2024-08-27 19:38:33 +08:00
|
|
|
default=10.0,
|
|
|
|
)
|
|
|
|
|
|
|
|
CODE_EXECUTION_READ_TIMEOUT: Optional[float] = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Read timeout in seconds for code execution requests",
|
2024-08-27 19:38:33 +08:00
|
|
|
default=60.0,
|
|
|
|
)
|
|
|
|
|
|
|
|
CODE_EXECUTION_WRITE_TIMEOUT: Optional[float] = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Write timeout in seconds for code execution request",
|
2024-08-27 19:38:33 +08:00
|
|
|
default=10.0,
|
|
|
|
)
|
|
|
|
|
2024-08-23 22:40:07 +08:00
|
|
|
CODE_MAX_NUMBER: PositiveInt = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Maximum allowed numeric value in code execution",
|
2024-08-23 22:40:07 +08:00
|
|
|
default=9223372036854775807,
|
|
|
|
)
|
|
|
|
|
|
|
|
CODE_MIN_NUMBER: NegativeInt = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Minimum allowed numeric value in code execution",
|
2024-08-23 22:40:07 +08:00
|
|
|
default=-9223372036854775807,
|
|
|
|
)
|
|
|
|
|
|
|
|
CODE_MAX_DEPTH: PositiveInt = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Maximum allowed depth for nested structures in code execution",
|
2024-08-23 22:40:07 +08:00
|
|
|
default=5,
|
|
|
|
)
|
|
|
|
|
|
|
|
CODE_MAX_PRECISION: PositiveInt = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="mMaximum number of decimal places for floating-point numbers in code execution",
|
2024-08-23 22:40:07 +08:00
|
|
|
default=20,
|
|
|
|
)
|
|
|
|
|
|
|
|
CODE_MAX_STRING_LENGTH: PositiveInt = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Maximum allowed length for strings in code execution",
|
2024-08-23 22:40:07 +08:00
|
|
|
default=80000,
|
|
|
|
)
|
|
|
|
|
|
|
|
CODE_MAX_STRING_ARRAY_LENGTH: PositiveInt = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Maximum allowed length for string arrays in code execution",
|
2024-08-23 22:40:07 +08:00
|
|
|
default=30,
|
|
|
|
)
|
|
|
|
|
|
|
|
CODE_MAX_OBJECT_ARRAY_LENGTH: PositiveInt = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Maximum allowed length for object arrays in code execution",
|
2024-08-23 22:40:07 +08:00
|
|
|
default=30,
|
|
|
|
)
|
|
|
|
|
|
|
|
CODE_MAX_NUMBER_ARRAY_LENGTH: PositiveInt = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Maximum allowed length for numeric arrays in code execution",
|
2024-08-23 22:40:07 +08:00
|
|
|
default=1000,
|
|
|
|
)
|
|
|
|
|
2024-06-19 13:41:12 +08:00
|
|
|
|
2024-07-07 12:18:15 +08:00
|
|
|
class EndpointConfig(BaseSettings):
|
2024-06-19 13:41:12 +08:00
|
|
|
"""
|
2024-09-22 13:38:41 +08:00
|
|
|
Configuration for various application endpoints and URLs
|
2024-06-19 13:41:12 +08:00
|
|
|
"""
|
2024-08-23 23:46:01 +08:00
|
|
|
|
2024-06-19 13:41:12 +08:00
|
|
|
CONSOLE_API_URL: str = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Base URL for the console API,"
|
|
|
|
"used for login authentication callback or notion integration callbacks",
|
2024-08-23 23:46:01 +08:00
|
|
|
default="",
|
2024-06-19 13:41:12 +08:00
|
|
|
)
|
|
|
|
|
|
|
|
CONSOLE_WEB_URL: str = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Base URL for the console web interface," "used for frontend references and CORS configuration",
|
2024-08-23 23:46:01 +08:00
|
|
|
default="",
|
2024-06-19 13:41:12 +08:00
|
|
|
)
|
|
|
|
|
|
|
|
SERVICE_API_URL: str = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Base URL for the service API, displayed to users for API access",
|
2024-08-23 23:46:01 +08:00
|
|
|
default="",
|
2024-06-19 13:41:12 +08:00
|
|
|
)
|
|
|
|
|
|
|
|
APP_WEB_URL: str = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Base URL for the web application, used for frontend references",
|
2024-08-23 23:46:01 +08:00
|
|
|
default="",
|
2024-06-19 13:41:12 +08:00
|
|
|
)
|
|
|
|
|
|
|
|
|
2024-07-07 12:18:15 +08:00
|
|
|
class FileAccessConfig(BaseSettings):
|
2024-06-19 13:41:12 +08:00
|
|
|
"""
|
2024-09-22 13:38:41 +08:00
|
|
|
Configuration for file access and handling
|
2024-06-19 13:41:12 +08:00
|
|
|
"""
|
2024-08-23 23:46:01 +08:00
|
|
|
|
2024-06-19 13:41:12 +08:00
|
|
|
FILES_URL: str = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Base URL for file preview or download,"
|
|
|
|
" used for frontend display and multi-model inputs"
|
2024-08-23 23:46:01 +08:00
|
|
|
"Url is signed and has expiration time.",
|
|
|
|
validation_alias=AliasChoices("FILES_URL", "CONSOLE_API_URL"),
|
2024-06-19 13:41:12 +08:00
|
|
|
alias_priority=1,
|
2024-08-23 23:46:01 +08:00
|
|
|
default="",
|
2024-06-19 13:41:12 +08:00
|
|
|
)
|
|
|
|
|
|
|
|
FILES_ACCESS_TIMEOUT: int = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Expiration time in seconds for file access URLs",
|
2024-06-19 13:41:12 +08:00
|
|
|
default=300,
|
|
|
|
)
|
|
|
|
|
|
|
|
|
2024-07-07 12:18:15 +08:00
|
|
|
class FileUploadConfig(BaseSettings):
|
2024-06-19 13:41:12 +08:00
|
|
|
"""
|
2024-09-22 13:38:41 +08:00
|
|
|
Configuration for file upload limitations
|
2024-06-19 13:41:12 +08:00
|
|
|
"""
|
2024-08-23 23:46:01 +08:00
|
|
|
|
2024-06-19 13:41:12 +08:00
|
|
|
UPLOAD_FILE_SIZE_LIMIT: NonNegativeInt = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Maximum allowed file size for uploads in megabytes",
|
2024-06-19 13:41:12 +08:00
|
|
|
default=15,
|
|
|
|
)
|
|
|
|
|
|
|
|
UPLOAD_FILE_BATCH_LIMIT: NonNegativeInt = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Maximum number of files allowed in a single upload batch",
|
2024-06-19 13:41:12 +08:00
|
|
|
default=5,
|
|
|
|
)
|
|
|
|
|
|
|
|
UPLOAD_IMAGE_FILE_SIZE_LIMIT: NonNegativeInt = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Maximum allowed image file size for uploads in megabytes",
|
2024-06-19 13:41:12 +08:00
|
|
|
default=10,
|
|
|
|
)
|
|
|
|
|
2024-10-21 10:43:49 +08:00
|
|
|
UPLOAD_VIDEO_FILE_SIZE_LIMIT: NonNegativeInt = Field(
|
|
|
|
description="video file size limit in Megabytes for uploading files",
|
|
|
|
default=100,
|
|
|
|
)
|
|
|
|
|
|
|
|
UPLOAD_AUDIO_FILE_SIZE_LIMIT: NonNegativeInt = Field(
|
|
|
|
description="audio file size limit in Megabytes for uploading files",
|
|
|
|
default=50,
|
|
|
|
)
|
|
|
|
|
2024-06-19 13:41:12 +08:00
|
|
|
BATCH_UPLOAD_LIMIT: NonNegativeInt = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Maximum number of files allowed in a batch upload operation",
|
2024-06-19 13:41:12 +08:00
|
|
|
default=20,
|
|
|
|
)
|
|
|
|
|
2024-11-04 15:55:34 +08:00
|
|
|
WORKFLOW_FILE_UPLOAD_LIMIT: PositiveInt = Field(
|
|
|
|
description="Maximum number of files allowed in a workflow upload operation",
|
|
|
|
default=10,
|
|
|
|
)
|
|
|
|
|
2024-06-19 13:41:12 +08:00
|
|
|
|
2024-07-07 12:18:15 +08:00
|
|
|
class HttpConfig(BaseSettings):
|
2024-06-19 13:41:12 +08:00
|
|
|
"""
|
2024-09-22 13:38:41 +08:00
|
|
|
HTTP-related configurations for the application
|
2024-06-19 13:41:12 +08:00
|
|
|
"""
|
2024-08-23 23:46:01 +08:00
|
|
|
|
2024-06-19 13:41:12 +08:00
|
|
|
API_COMPRESSION_ENABLED: bool = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Enable or disable gzip compression for HTTP responses",
|
2024-06-19 13:41:12 +08:00
|
|
|
default=False,
|
|
|
|
)
|
|
|
|
|
2024-06-25 15:48:02 +08:00
|
|
|
inner_CONSOLE_CORS_ALLOW_ORIGINS: str = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Comma-separated list of allowed origins for CORS in the console",
|
2024-08-23 23:46:01 +08:00
|
|
|
validation_alias=AliasChoices("CONSOLE_CORS_ALLOW_ORIGINS", "CONSOLE_WEB_URL"),
|
|
|
|
default="",
|
2024-06-25 15:48:02 +08:00
|
|
|
)
|
|
|
|
|
|
|
|
@computed_field
|
|
|
|
@property
|
|
|
|
def CONSOLE_CORS_ALLOW_ORIGINS(self) -> list[str]:
|
2024-08-23 23:46:01 +08:00
|
|
|
return self.inner_CONSOLE_CORS_ALLOW_ORIGINS.split(",")
|
2024-06-25 15:48:02 +08:00
|
|
|
|
2024-07-02 08:50:02 +08:00
|
|
|
inner_WEB_API_CORS_ALLOW_ORIGINS: str = Field(
|
2024-08-23 23:46:01 +08:00
|
|
|
description="",
|
|
|
|
validation_alias=AliasChoices("WEB_API_CORS_ALLOW_ORIGINS"),
|
|
|
|
default="*",
|
2024-06-25 15:48:02 +08:00
|
|
|
)
|
|
|
|
|
|
|
|
@computed_field
|
|
|
|
@property
|
|
|
|
def WEB_API_CORS_ALLOW_ORIGINS(self) -> list[str]:
|
2024-08-23 23:46:01 +08:00
|
|
|
return self.inner_WEB_API_CORS_ALLOW_ORIGINS.split(",")
|
2024-06-25 15:48:02 +08:00
|
|
|
|
2024-08-30 19:09:10 +08:00
|
|
|
HTTP_REQUEST_MAX_CONNECT_TIMEOUT: Annotated[
|
2024-09-22 13:38:41 +08:00
|
|
|
PositiveInt, Field(ge=10, description="Maximum connection timeout in seconds for HTTP requests")
|
2024-08-30 19:09:10 +08:00
|
|
|
] = 10
|
2024-08-23 22:40:07 +08:00
|
|
|
|
2024-08-30 19:09:10 +08:00
|
|
|
HTTP_REQUEST_MAX_READ_TIMEOUT: Annotated[
|
2024-09-22 13:38:41 +08:00
|
|
|
PositiveInt, Field(ge=60, description="Maximum read timeout in seconds for HTTP requests")
|
2024-08-30 19:09:10 +08:00
|
|
|
] = 60
|
2024-08-23 22:40:07 +08:00
|
|
|
|
2024-08-30 19:09:10 +08:00
|
|
|
HTTP_REQUEST_MAX_WRITE_TIMEOUT: Annotated[
|
2024-09-22 13:38:41 +08:00
|
|
|
PositiveInt, Field(ge=10, description="Maximum write timeout in seconds for HTTP requests")
|
2024-08-30 19:09:10 +08:00
|
|
|
] = 20
|
2024-08-23 22:40:07 +08:00
|
|
|
|
|
|
|
HTTP_REQUEST_NODE_MAX_BINARY_SIZE: PositiveInt = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Maximum allowed size in bytes for binary data in HTTP requests",
|
2024-08-23 22:40:07 +08:00
|
|
|
default=10 * 1024 * 1024,
|
|
|
|
)
|
|
|
|
|
|
|
|
HTTP_REQUEST_NODE_MAX_TEXT_SIZE: PositiveInt = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Maximum allowed size in bytes for text data in HTTP requests",
|
2024-08-23 22:40:07 +08:00
|
|
|
default=1 * 1024 * 1024,
|
|
|
|
)
|
|
|
|
|
|
|
|
SSRF_PROXY_HTTP_URL: Optional[str] = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Proxy URL for HTTP requests to prevent Server-Side Request Forgery (SSRF)",
|
2024-08-23 22:40:07 +08:00
|
|
|
default=None,
|
|
|
|
)
|
|
|
|
|
|
|
|
SSRF_PROXY_HTTPS_URL: Optional[str] = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Proxy URL for HTTPS requests to prevent Server-Side Request Forgery (SSRF)",
|
2024-08-23 22:40:07 +08:00
|
|
|
default=None,
|
|
|
|
)
|
|
|
|
|
2024-11-06 08:50:57 +08:00
|
|
|
SSRF_DEFAULT_TIME_OUT: PositiveFloat = Field(
|
|
|
|
description="The default timeout period used for network requests (SSRF)",
|
|
|
|
default=5,
|
|
|
|
)
|
|
|
|
|
|
|
|
SSRF_DEFAULT_CONNECT_TIME_OUT: PositiveFloat = Field(
|
|
|
|
description="The default connect timeout period used for network requests (SSRF)",
|
|
|
|
default=5,
|
|
|
|
)
|
|
|
|
|
|
|
|
SSRF_DEFAULT_READ_TIME_OUT: PositiveFloat = Field(
|
|
|
|
description="The default read timeout period used for network requests (SSRF)",
|
|
|
|
default=5,
|
|
|
|
)
|
|
|
|
|
|
|
|
SSRF_DEFAULT_WRITE_TIME_OUT: PositiveFloat = Field(
|
|
|
|
description="The default write timeout period used for network requests (SSRF)",
|
|
|
|
default=5,
|
|
|
|
)
|
|
|
|
|
2024-10-09 14:42:30 +08:00
|
|
|
RESPECT_XFORWARD_HEADERS_ENABLED: bool = Field(
|
|
|
|
description="Enable or disable the X-Forwarded-For Proxy Fix middleware from Werkzeug"
|
|
|
|
" to respect X-* headers to redirect clients",
|
|
|
|
default=False,
|
|
|
|
)
|
|
|
|
|
2024-06-19 13:41:12 +08:00
|
|
|
|
2024-07-07 12:18:15 +08:00
|
|
|
class InnerAPIConfig(BaseSettings):
|
2024-06-19 13:41:12 +08:00
|
|
|
"""
|
2024-09-22 13:38:41 +08:00
|
|
|
Configuration for internal API functionality
|
2024-06-19 13:41:12 +08:00
|
|
|
"""
|
2024-08-23 23:46:01 +08:00
|
|
|
|
2024-06-19 13:41:12 +08:00
|
|
|
INNER_API: bool = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Enable or disable the internal API",
|
2024-06-19 13:41:12 +08:00
|
|
|
default=False,
|
|
|
|
)
|
|
|
|
|
|
|
|
INNER_API_KEY: Optional[str] = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="API key for accessing the internal API",
|
2024-06-19 13:41:12 +08:00
|
|
|
default=None,
|
|
|
|
)
|
|
|
|
|
|
|
|
|
2024-07-07 12:18:15 +08:00
|
|
|
class LoggingConfig(BaseSettings):
|
2024-06-19 13:41:12 +08:00
|
|
|
"""
|
2024-09-22 13:38:41 +08:00
|
|
|
Configuration for application logging
|
2024-06-19 13:41:12 +08:00
|
|
|
"""
|
|
|
|
|
|
|
|
LOG_LEVEL: str = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Logging level, default to INFO. Set to ERROR for production environments.",
|
2024-08-23 23:46:01 +08:00
|
|
|
default="INFO",
|
2024-06-19 13:41:12 +08:00
|
|
|
)
|
|
|
|
|
|
|
|
LOG_FILE: Optional[str] = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="File path for log output.",
|
2024-06-19 13:41:12 +08:00
|
|
|
default=None,
|
|
|
|
)
|
|
|
|
|
2024-10-23 17:24:36 +08:00
|
|
|
LOG_FILE_MAX_SIZE: PositiveInt = Field(
|
|
|
|
description="Maximum file size for file rotation retention, the unit is megabytes (MB)",
|
|
|
|
default=20,
|
|
|
|
)
|
|
|
|
|
|
|
|
LOG_FILE_BACKUP_COUNT: PositiveInt = Field(
|
|
|
|
description="Maximum file backup count file rotation retention",
|
|
|
|
default=5,
|
|
|
|
)
|
|
|
|
|
2024-06-19 13:41:12 +08:00
|
|
|
LOG_FORMAT: str = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Format string for log messages",
|
2024-08-23 23:46:01 +08:00
|
|
|
default="%(asctime)s.%(msecs)03d %(levelname)s [%(threadName)s] [%(filename)s:%(lineno)d] - %(message)s",
|
2024-06-19 13:41:12 +08:00
|
|
|
)
|
|
|
|
|
|
|
|
LOG_DATEFORMAT: Optional[str] = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Date format string for log timestamps",
|
2024-06-19 13:41:12 +08:00
|
|
|
default=None,
|
|
|
|
)
|
|
|
|
|
2024-10-30 22:06:10 +08:00
|
|
|
LOG_TZ: Optional[str] = Field(
|
|
|
|
description="Timezone for log timestamps (e.g., 'America/New_York')",
|
2024-06-19 15:51:00 +08:00
|
|
|
default=None,
|
|
|
|
)
|
|
|
|
|
2024-06-19 13:41:12 +08:00
|
|
|
|
2024-07-07 12:18:15 +08:00
|
|
|
class ModelLoadBalanceConfig(BaseSettings):
|
2024-06-19 13:41:12 +08:00
|
|
|
"""
|
2024-09-22 13:38:41 +08:00
|
|
|
Configuration for model load balancing
|
2024-06-19 13:41:12 +08:00
|
|
|
"""
|
2024-08-23 23:46:01 +08:00
|
|
|
|
2024-06-19 13:41:12 +08:00
|
|
|
MODEL_LB_ENABLED: bool = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Enable or disable load balancing for models",
|
2024-06-19 13:41:12 +08:00
|
|
|
default=False,
|
|
|
|
)
|
|
|
|
|
|
|
|
|
2024-07-07 12:18:15 +08:00
|
|
|
class BillingConfig(BaseSettings):
|
2024-06-19 13:41:12 +08:00
|
|
|
"""
|
2024-09-22 13:38:41 +08:00
|
|
|
Configuration for platform billing features
|
2024-06-19 13:41:12 +08:00
|
|
|
"""
|
2024-08-23 23:46:01 +08:00
|
|
|
|
2024-06-19 13:41:12 +08:00
|
|
|
BILLING_ENABLED: bool = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Enable or disable billing functionality",
|
2024-06-19 13:41:12 +08:00
|
|
|
default=False,
|
|
|
|
)
|
|
|
|
|
|
|
|
|
2024-07-07 12:18:15 +08:00
|
|
|
class UpdateConfig(BaseSettings):
|
2024-06-19 13:41:12 +08:00
|
|
|
"""
|
2024-09-22 13:38:41 +08:00
|
|
|
Configuration for application update checks
|
2024-06-19 13:41:12 +08:00
|
|
|
"""
|
2024-08-23 23:46:01 +08:00
|
|
|
|
2024-06-19 13:41:12 +08:00
|
|
|
CHECK_UPDATE_URL: str = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="URL to check for application updates",
|
2024-08-23 23:46:01 +08:00
|
|
|
default="https://updates.dify.ai",
|
2024-06-19 13:41:12 +08:00
|
|
|
)
|
|
|
|
|
|
|
|
|
2024-07-07 12:18:15 +08:00
|
|
|
class WorkflowConfig(BaseSettings):
|
2024-06-19 13:41:12 +08:00
|
|
|
"""
|
2024-09-22 13:38:41 +08:00
|
|
|
Configuration for workflow execution
|
2024-06-19 13:41:12 +08:00
|
|
|
"""
|
|
|
|
|
|
|
|
WORKFLOW_MAX_EXECUTION_STEPS: PositiveInt = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Maximum number of steps allowed in a single workflow execution",
|
2024-06-19 13:41:12 +08:00
|
|
|
default=500,
|
|
|
|
)
|
|
|
|
|
|
|
|
WORKFLOW_MAX_EXECUTION_TIME: PositiveInt = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Maximum execution time in seconds for a single workflow",
|
2024-06-19 13:41:12 +08:00
|
|
|
default=1200,
|
|
|
|
)
|
|
|
|
|
|
|
|
WORKFLOW_CALL_MAX_DEPTH: PositiveInt = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Maximum allowed depth for nested workflow calls",
|
2024-06-19 13:41:12 +08:00
|
|
|
default=5,
|
|
|
|
)
|
|
|
|
|
2024-08-23 22:40:07 +08:00
|
|
|
MAX_VARIABLE_SIZE: PositiveInt = Field(
|
2024-10-21 10:43:49 +08:00
|
|
|
description="Maximum size in bytes for a single variable in workflows. Default to 200 KB.",
|
|
|
|
default=200 * 1024,
|
2024-08-23 22:40:07 +08:00
|
|
|
)
|
|
|
|
|
2024-06-19 13:41:12 +08:00
|
|
|
|
2024-10-12 23:46:30 +08:00
|
|
|
class AuthConfig(BaseSettings):
|
2024-06-19 13:41:12 +08:00
|
|
|
"""
|
2024-10-12 23:46:30 +08:00
|
|
|
Configuration for authentication and OAuth
|
2024-06-19 13:41:12 +08:00
|
|
|
"""
|
2024-08-23 23:46:01 +08:00
|
|
|
|
2024-06-19 13:41:12 +08:00
|
|
|
OAUTH_REDIRECT_PATH: str = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Redirect path for OAuth authentication callbacks",
|
2024-08-23 23:46:01 +08:00
|
|
|
default="/console/api/oauth/authorize",
|
2024-06-19 13:41:12 +08:00
|
|
|
)
|
|
|
|
|
|
|
|
GITHUB_CLIENT_ID: Optional[str] = Field(
|
2024-10-12 23:46:30 +08:00
|
|
|
description="GitHub OAuth client ID",
|
2024-06-19 13:41:12 +08:00
|
|
|
default=None,
|
|
|
|
)
|
|
|
|
|
|
|
|
GITHUB_CLIENT_SECRET: Optional[str] = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="GitHub OAuth client secret",
|
2024-06-19 13:41:12 +08:00
|
|
|
default=None,
|
|
|
|
)
|
|
|
|
|
|
|
|
GOOGLE_CLIENT_ID: Optional[str] = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Google OAuth client ID",
|
2024-06-19 13:41:12 +08:00
|
|
|
default=None,
|
|
|
|
)
|
|
|
|
|
|
|
|
GOOGLE_CLIENT_SECRET: Optional[str] = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Google OAuth client secret",
|
2024-06-19 13:41:12 +08:00
|
|
|
default=None,
|
|
|
|
)
|
|
|
|
|
2024-10-12 23:46:30 +08:00
|
|
|
ACCESS_TOKEN_EXPIRE_MINUTES: PositiveInt = Field(
|
|
|
|
description="Expiration time for access tokens in minutes",
|
|
|
|
default=60,
|
|
|
|
)
|
|
|
|
|
2024-06-19 13:41:12 +08:00
|
|
|
|
2024-07-07 12:18:15 +08:00
|
|
|
class ModerationConfig(BaseSettings):
|
2024-06-19 13:41:12 +08:00
|
|
|
"""
|
2024-09-22 13:38:41 +08:00
|
|
|
Configuration for content moderation
|
2024-06-19 13:41:12 +08:00
|
|
|
"""
|
|
|
|
|
2024-08-23 22:40:07 +08:00
|
|
|
MODERATION_BUFFER_SIZE: PositiveInt = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Size of the buffer for content moderation processing",
|
2024-06-19 13:41:12 +08:00
|
|
|
default=300,
|
|
|
|
)
|
|
|
|
|
|
|
|
|
2024-07-07 12:18:15 +08:00
|
|
|
class ToolConfig(BaseSettings):
|
2024-06-19 13:41:12 +08:00
|
|
|
"""
|
2024-09-22 13:38:41 +08:00
|
|
|
Configuration for tool management
|
2024-06-19 13:41:12 +08:00
|
|
|
"""
|
|
|
|
|
|
|
|
TOOL_ICON_CACHE_MAX_AGE: PositiveInt = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Maximum age in seconds for caching tool icons",
|
2024-06-19 13:41:12 +08:00
|
|
|
default=3600,
|
|
|
|
)
|
|
|
|
|
|
|
|
|
2024-07-07 12:18:15 +08:00
|
|
|
class MailConfig(BaseSettings):
|
2024-06-19 13:41:12 +08:00
|
|
|
"""
|
2024-09-22 13:38:41 +08:00
|
|
|
Configuration for email services
|
2024-06-19 13:41:12 +08:00
|
|
|
"""
|
|
|
|
|
|
|
|
MAIL_TYPE: Optional[str] = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Email service provider type ('smtp' or 'resend'), default to None.",
|
2024-06-19 13:41:12 +08:00
|
|
|
default=None,
|
|
|
|
)
|
|
|
|
|
|
|
|
MAIL_DEFAULT_SEND_FROM: Optional[str] = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Default email address to use as the sender",
|
2024-06-19 13:41:12 +08:00
|
|
|
default=None,
|
|
|
|
)
|
|
|
|
|
|
|
|
RESEND_API_KEY: Optional[str] = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="API key for Resend email service",
|
2024-06-19 13:41:12 +08:00
|
|
|
default=None,
|
|
|
|
)
|
|
|
|
|
|
|
|
RESEND_API_URL: Optional[str] = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="API URL for Resend email service",
|
2024-06-19 13:41:12 +08:00
|
|
|
default=None,
|
|
|
|
)
|
|
|
|
|
|
|
|
SMTP_SERVER: Optional[str] = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="SMTP server hostname",
|
2024-06-19 13:41:12 +08:00
|
|
|
default=None,
|
|
|
|
)
|
|
|
|
|
|
|
|
SMTP_PORT: Optional[int] = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="SMTP server port number",
|
2024-06-26 21:01:16 +08:00
|
|
|
default=465,
|
2024-06-19 13:41:12 +08:00
|
|
|
)
|
|
|
|
|
|
|
|
SMTP_USERNAME: Optional[str] = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Username for SMTP authentication",
|
2024-06-19 13:41:12 +08:00
|
|
|
default=None,
|
|
|
|
)
|
|
|
|
|
|
|
|
SMTP_PASSWORD: Optional[str] = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Password for SMTP authentication",
|
2024-06-19 13:41:12 +08:00
|
|
|
default=None,
|
|
|
|
)
|
|
|
|
|
|
|
|
SMTP_USE_TLS: bool = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Enable TLS encryption for SMTP connections",
|
2024-06-19 13:41:12 +08:00
|
|
|
default=False,
|
|
|
|
)
|
|
|
|
|
|
|
|
SMTP_OPPORTUNISTIC_TLS: bool = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Enable opportunistic TLS for SMTP connections",
|
2024-06-19 13:41:12 +08:00
|
|
|
default=False,
|
|
|
|
)
|
|
|
|
|
2024-10-21 10:03:40 +08:00
|
|
|
EMAIL_SEND_IP_LIMIT_PER_MINUTE: PositiveInt = Field(
|
|
|
|
description="Maximum number of emails allowed to be sent from the same IP address in a minute",
|
|
|
|
default=50,
|
|
|
|
)
|
|
|
|
|
2024-06-19 13:41:12 +08:00
|
|
|
|
2024-07-07 12:18:15 +08:00
|
|
|
class RagEtlConfig(BaseSettings):
|
2024-06-19 13:41:12 +08:00
|
|
|
"""
|
2024-09-22 13:38:41 +08:00
|
|
|
Configuration for RAG ETL processes
|
2024-06-19 13:41:12 +08:00
|
|
|
"""
|
|
|
|
|
2024-10-21 10:43:49 +08:00
|
|
|
# TODO: This config is not only for rag etl, it is also for file upload, we should move it to file upload config
|
2024-06-19 13:41:12 +08:00
|
|
|
ETL_TYPE: str = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="RAG ETL type ('dify' or 'Unstructured'), default to 'dify'",
|
2024-08-23 23:46:01 +08:00
|
|
|
default="dify",
|
2024-06-19 13:41:12 +08:00
|
|
|
)
|
|
|
|
|
|
|
|
KEYWORD_DATA_SOURCE_TYPE: str = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Data source type for keyword extraction"
|
|
|
|
" ('database' or other supported types), default to 'database'",
|
2024-08-23 23:46:01 +08:00
|
|
|
default="database",
|
2024-06-19 13:41:12 +08:00
|
|
|
)
|
|
|
|
|
|
|
|
UNSTRUCTURED_API_URL: Optional[str] = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="API URL for Unstructured.io service",
|
2024-06-19 13:41:12 +08:00
|
|
|
default=None,
|
|
|
|
)
|
|
|
|
|
|
|
|
UNSTRUCTURED_API_KEY: Optional[str] = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="API key for Unstructured.io service",
|
2024-06-19 13:41:12 +08:00
|
|
|
default=None,
|
|
|
|
)
|
|
|
|
|
|
|
|
|
2024-07-07 12:18:15 +08:00
|
|
|
class DataSetConfig(BaseSettings):
|
2024-06-19 13:41:12 +08:00
|
|
|
"""
|
2024-09-22 13:38:41 +08:00
|
|
|
Configuration for dataset management
|
2024-06-19 13:41:12 +08:00
|
|
|
"""
|
|
|
|
|
2024-10-17 10:40:22 +08:00
|
|
|
PLAN_SANDBOX_CLEAN_DAY_SETTING: PositiveInt = Field(
|
|
|
|
description="Interval in days for dataset cleanup operations - plan: sandbox",
|
2024-06-19 13:41:12 +08:00
|
|
|
default=30,
|
|
|
|
)
|
|
|
|
|
2024-10-17 10:40:22 +08:00
|
|
|
PLAN_PRO_CLEAN_DAY_SETTING: PositiveInt = Field(
|
|
|
|
description="Interval in days for dataset cleanup operations - plan: pro and team",
|
|
|
|
default=7,
|
|
|
|
)
|
|
|
|
|
2024-07-09 17:47:54 +08:00
|
|
|
DATASET_OPERATOR_ENABLED: bool = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Enable or disable dataset operator functionality",
|
2024-07-09 17:47:54 +08:00
|
|
|
default=False,
|
|
|
|
)
|
|
|
|
|
2024-10-25 13:57:03 +08:00
|
|
|
TIDB_SERVERLESS_NUMBER: PositiveInt = Field(
|
|
|
|
description="number of tidb serverless cluster",
|
|
|
|
default=500,
|
|
|
|
)
|
|
|
|
|
2024-08-21 11:16:43 +08:00
|
|
|
|
2024-07-07 12:18:15 +08:00
|
|
|
class WorkspaceConfig(BaseSettings):
|
2024-06-19 13:41:12 +08:00
|
|
|
"""
|
2024-09-22 13:38:41 +08:00
|
|
|
Configuration for workspace management
|
2024-06-19 13:41:12 +08:00
|
|
|
"""
|
|
|
|
|
|
|
|
INVITE_EXPIRY_HOURS: PositiveInt = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Expiration time in hours for workspace invitation links",
|
2024-06-19 13:41:12 +08:00
|
|
|
default=72,
|
|
|
|
)
|
|
|
|
|
|
|
|
|
2024-07-07 12:18:15 +08:00
|
|
|
class IndexingConfig(BaseSettings):
|
2024-06-19 13:41:12 +08:00
|
|
|
"""
|
2024-09-22 13:38:41 +08:00
|
|
|
Configuration for indexing operations
|
2024-06-19 13:41:12 +08:00
|
|
|
"""
|
|
|
|
|
|
|
|
INDEXING_MAX_SEGMENTATION_TOKENS_LENGTH: PositiveInt = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Maximum token length for text segmentation during indexing",
|
2024-06-19 13:41:12 +08:00
|
|
|
default=1000,
|
|
|
|
)
|
|
|
|
|
|
|
|
|
2024-07-07 12:18:15 +08:00
|
|
|
class ImageFormatConfig(BaseSettings):
|
2024-10-21 10:43:49 +08:00
|
|
|
MULTIMODAL_SEND_IMAGE_FORMAT: Literal["base64", "url"] = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Format for sending images in multimodal contexts ('base64' or 'url'), default is base64",
|
2024-08-23 23:46:01 +08:00
|
|
|
default="base64",
|
2024-06-19 13:41:12 +08:00
|
|
|
)
|
|
|
|
|
|
|
|
|
2024-07-17 02:31:30 +08:00
|
|
|
class CeleryBeatConfig(BaseSettings):
|
|
|
|
CELERY_BEAT_SCHEDULER_TIME: int = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Interval in days for Celery Beat scheduler execution, default to 1 day",
|
2024-07-17 02:31:30 +08:00
|
|
|
default=1,
|
|
|
|
)
|
|
|
|
|
|
|
|
|
2024-08-21 11:16:43 +08:00
|
|
|
class PositionConfig(BaseSettings):
|
|
|
|
POSITION_PROVIDER_PINS: str = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Comma-separated list of pinned model providers",
|
2024-08-23 23:46:01 +08:00
|
|
|
default="",
|
2024-08-21 11:16:43 +08:00
|
|
|
)
|
|
|
|
|
|
|
|
POSITION_PROVIDER_INCLUDES: str = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Comma-separated list of included model providers",
|
2024-08-23 23:46:01 +08:00
|
|
|
default="",
|
2024-08-21 11:16:43 +08:00
|
|
|
)
|
|
|
|
|
|
|
|
POSITION_PROVIDER_EXCLUDES: str = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Comma-separated list of excluded model providers",
|
2024-08-23 23:46:01 +08:00
|
|
|
default="",
|
2024-08-21 11:16:43 +08:00
|
|
|
)
|
|
|
|
|
|
|
|
POSITION_TOOL_PINS: str = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Comma-separated list of pinned tools",
|
2024-08-23 23:46:01 +08:00
|
|
|
default="",
|
2024-08-21 11:16:43 +08:00
|
|
|
)
|
|
|
|
|
|
|
|
POSITION_TOOL_INCLUDES: str = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Comma-separated list of included tools",
|
2024-08-23 23:46:01 +08:00
|
|
|
default="",
|
2024-08-21 11:16:43 +08:00
|
|
|
)
|
|
|
|
|
|
|
|
POSITION_TOOL_EXCLUDES: str = Field(
|
2024-09-22 13:38:41 +08:00
|
|
|
description="Comma-separated list of excluded tools",
|
2024-08-23 23:46:01 +08:00
|
|
|
default="",
|
2024-08-21 11:16:43 +08:00
|
|
|
)
|
|
|
|
|
|
|
|
@computed_field
|
|
|
|
def POSITION_PROVIDER_PINS_LIST(self) -> list[str]:
|
2024-08-23 23:46:01 +08:00
|
|
|
return [item.strip() for item in self.POSITION_PROVIDER_PINS.split(",") if item.strip() != ""]
|
2024-08-21 11:16:43 +08:00
|
|
|
|
|
|
|
@computed_field
|
|
|
|
def POSITION_PROVIDER_INCLUDES_SET(self) -> set[str]:
|
2024-08-23 23:46:01 +08:00
|
|
|
return {item.strip() for item in self.POSITION_PROVIDER_INCLUDES.split(",") if item.strip() != ""}
|
2024-08-21 11:16:43 +08:00
|
|
|
|
|
|
|
@computed_field
|
|
|
|
def POSITION_PROVIDER_EXCLUDES_SET(self) -> set[str]:
|
2024-08-23 23:46:01 +08:00
|
|
|
return {item.strip() for item in self.POSITION_PROVIDER_EXCLUDES.split(",") if item.strip() != ""}
|
2024-08-21 11:16:43 +08:00
|
|
|
|
|
|
|
@computed_field
|
|
|
|
def POSITION_TOOL_PINS_LIST(self) -> list[str]:
|
2024-08-23 23:46:01 +08:00
|
|
|
return [item.strip() for item in self.POSITION_TOOL_PINS.split(",") if item.strip() != ""]
|
2024-08-21 11:16:43 +08:00
|
|
|
|
|
|
|
@computed_field
|
|
|
|
def POSITION_TOOL_INCLUDES_SET(self) -> set[str]:
|
2024-08-23 23:46:01 +08:00
|
|
|
return {item.strip() for item in self.POSITION_TOOL_INCLUDES.split(",") if item.strip() != ""}
|
2024-08-21 11:16:43 +08:00
|
|
|
|
|
|
|
@computed_field
|
|
|
|
def POSITION_TOOL_EXCLUDES_SET(self) -> set[str]:
|
2024-08-23 23:46:01 +08:00
|
|
|
return {item.strip() for item in self.POSITION_TOOL_EXCLUDES.split(",") if item.strip() != ""}
|
2024-08-21 11:16:43 +08:00
|
|
|
|
|
|
|
|
2024-10-21 10:03:40 +08:00
|
|
|
class LoginConfig(BaseSettings):
|
|
|
|
ENABLE_EMAIL_CODE_LOGIN: bool = Field(
|
|
|
|
description="whether to enable email code login",
|
|
|
|
default=False,
|
|
|
|
)
|
|
|
|
ENABLE_EMAIL_PASSWORD_LOGIN: bool = Field(
|
|
|
|
description="whether to enable email password login",
|
|
|
|
default=True,
|
|
|
|
)
|
|
|
|
ENABLE_SOCIAL_OAUTH_LOGIN: bool = Field(
|
|
|
|
description="whether to enable github/google oauth login",
|
|
|
|
default=False,
|
|
|
|
)
|
2024-10-21 18:14:26 +08:00
|
|
|
EMAIL_CODE_LOGIN_TOKEN_EXPIRY_MINUTES: PositiveInt = Field(
|
|
|
|
description="expiry time in minutes for email code login token",
|
|
|
|
default=5,
|
2024-10-21 10:03:40 +08:00
|
|
|
)
|
|
|
|
ALLOW_REGISTER: bool = Field(
|
|
|
|
description="whether to enable register",
|
|
|
|
default=False,
|
|
|
|
)
|
|
|
|
ALLOW_CREATE_WORKSPACE: bool = Field(
|
|
|
|
description="whether to enable create workspace",
|
|
|
|
default=False,
|
|
|
|
)
|
|
|
|
|
|
|
|
|
2024-06-22 09:54:25 +08:00
|
|
|
class FeatureConfig(
|
2024-06-19 13:41:12 +08:00
|
|
|
# place the configs in alphabet order
|
2024-06-22 09:54:25 +08:00
|
|
|
AppExecutionConfig,
|
2024-10-12 23:46:30 +08:00
|
|
|
AuthConfig, # Changed from OAuthConfig to AuthConfig
|
2024-06-22 09:54:25 +08:00
|
|
|
BillingConfig,
|
|
|
|
CodeExecutionSandboxConfig,
|
|
|
|
DataSetConfig,
|
|
|
|
EndpointConfig,
|
|
|
|
FileAccessConfig,
|
|
|
|
FileUploadConfig,
|
|
|
|
HttpConfig,
|
|
|
|
ImageFormatConfig,
|
|
|
|
InnerAPIConfig,
|
|
|
|
IndexingConfig,
|
|
|
|
LoggingConfig,
|
|
|
|
MailConfig,
|
|
|
|
ModelLoadBalanceConfig,
|
|
|
|
ModerationConfig,
|
2024-10-12 23:46:30 +08:00
|
|
|
PositionConfig,
|
2024-06-22 09:54:25 +08:00
|
|
|
RagEtlConfig,
|
|
|
|
SecurityConfig,
|
|
|
|
ToolConfig,
|
|
|
|
UpdateConfig,
|
|
|
|
WorkflowConfig,
|
|
|
|
WorkspaceConfig,
|
2024-10-21 10:03:40 +08:00
|
|
|
LoginConfig,
|
2024-06-22 17:41:17 +08:00
|
|
|
# hosted services config
|
|
|
|
HostedServiceConfig,
|
2024-07-17 02:31:30 +08:00
|
|
|
CeleryBeatConfig,
|
2024-06-19 13:41:12 +08:00
|
|
|
):
|
|
|
|
pass
|