Skip to content

Commit 6dddd89

Browse files
authored
Merge pull request lightspeed-core#1579 from tisnik/lcore-1891-all-identifiers-in-constants-are-real-constants
LCORE-1891: All identifiers in constants.py are real constants
2 parents d6ba6dd + 4544967 commit 6dddd89

1 file changed

Lines changed: 6 additions & 6 deletions

File tree

src/constants.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
TOPIC_SUMMARY_INTERRUPT_TIMEOUT_SECONDS: Final[float] = 30.0
1919

2020
# Supported attachment types
21-
ATTACHMENT_TYPES = frozenset(
21+
ATTACHMENT_TYPES: Final[frozenset] = frozenset(
2222
{
2323
"alert",
2424
"api object",
@@ -31,7 +31,7 @@
3131
)
3232

3333
# Supported attachment content types
34-
ATTACHMENT_CONTENT_TYPES = frozenset(
34+
ATTACHMENT_CONTENT_TYPES: Final[frozenset] = frozenset(
3535
{"text/plain", "application/json", "application/yaml", "application/xml"}
3636
)
3737

@@ -120,7 +120,7 @@
120120
AUTH_MOD_JWK_TOKEN: Final[str] = "jwk-token"
121121
AUTH_MOD_RH_IDENTITY: Final[str] = "rh-identity"
122122
# Supported authentication modules
123-
SUPPORTED_AUTHENTICATION_MODULES = frozenset(
123+
SUPPORTED_AUTHENTICATION_MODULES: Final[frozenset] = frozenset(
124124
{
125125
AUTH_MOD_K8S,
126126
AUTH_MOD_NOOP,
@@ -130,7 +130,7 @@
130130
AUTH_MOD_RH_IDENTITY,
131131
}
132132
)
133-
DEFAULT_AUTHENTICATION_MODULE = AUTH_MOD_NOOP
133+
DEFAULT_AUTHENTICATION_MODULE: Final[str] = AUTH_MOD_NOOP
134134
# Maximum allowed size for base64-encoded x-rh-identity header (bytes)
135135
DEFAULT_RH_IDENTITY_MAX_HEADER_SIZE: Final[int] = 8192
136136

@@ -216,7 +216,7 @@
216216
SOLR_DEFAULT_EMBEDDING_DIMENSION: Final[int] = 384
217217

218218
# Default score multiplier for BYOK RAG vector stores
219-
DEFAULT_SCORE_MULTIPLIER = 1.0
219+
DEFAULT_SCORE_MULTIPLIER: Final[float] = 1.0
220220

221221
# Special RAG ID that activates the OKP provider when listed in rag.inline or rag.tool
222222
OKP_RAG_ID: Final[str] = "okp"
@@ -243,7 +243,7 @@
243243
# Placeholder slug used in responses when the server substituted its own
244244
# system prompt for the client's instructions. Avoids leaking the actual
245245
# server prompt back to the client.
246-
SUBSTITUTED_INSTRUCTIONS_PLACEHOLDER = "<server prompt applied>"
246+
SUBSTITUTED_INSTRUCTIONS_PLACEHOLDER: Final[str] = "<server prompt applied>"
247247
# Input size limits for API request validation
248248
# Maximum character length for the question field in /v1/infer requests (32 KiB)
249249
RLSAPI_V1_QUESTION_MAX_LENGTH: Final[int] = 32_768

0 commit comments

Comments
 (0)