Update config import to use settings module

Replaced imports from config_manager with settings in chat_service.py and langflow_file_service.py to use get_openrag_config from config.settings. This change ensures consistency with the updated configuration structure.
This commit is contained in:
Edwin Jose 2025-11-25 19:40:24 -05:00
parent 0bb0b621f0
commit 07b84e373a
2 changed files with 4 additions and 4 deletions

View file

@ -66,7 +66,7 @@ class ChatService:
extra_headers["X-LANGFLOW-GLOBAL-VAR-JWT"] = jwt_token
# Pass the selected embedding model as a global variable
from config.config_manager import get_openrag_config
from config.settings import get_openrag_config
config = get_openrag_config()
embedding_model = config.knowledge.embedding_model
extra_headers["X-LANGFLOW-GLOBAL-VAR-SELECTED_EMBEDDING_MODEL"] = embedding_model
@ -181,7 +181,7 @@ class ChatService:
extra_headers["X-LANGFLOW-GLOBAL-VAR-JWT"] = jwt_token
# Pass the selected embedding model as a global variable
from config.config_manager import get_openrag_config
from config.settings import get_openrag_config
config = get_openrag_config()
embedding_model = config.knowledge.embedding_model
extra_headers["X-LANGFLOW-GLOBAL-VAR-SELECTED_EMBEDDING_MODEL"] = embedding_model
@ -305,7 +305,7 @@ class ChatService:
extra_headers["X-LANGFLOW-GLOBAL-VAR-JWT"] = jwt_token
# Pass the selected embedding model as a global variable
from config.config_manager import get_openrag_config
from config.settings import get_openrag_config
config = get_openrag_config()
embedding_model = config.knowledge.embedding_model
extra_headers["X-LANGFLOW-GLOBAL-VAR-SELECTED_EMBEDDING_MODEL"] = embedding_model

View file

@ -141,7 +141,7 @@ class LangflowFileService:
mimetype = str(file_tuples[0][2]) if file_tuples and len(file_tuples) > 0 and len(file_tuples[0]) > 2 else ""
# Get the current embedding model from config
from config.config_manager import get_openrag_config
from config.settings import get_openrag_config
config = get_openrag_config()
embedding_model = config.knowledge.embedding_model