diff --git a/llm-server/routes/root_service.py b/llm-server/routes/root_service.py index 38c0d1e66..87e64ad2e 100644 --- a/llm-server/routes/root_service.py +++ b/llm-server/routes/root_service.py @@ -52,7 +52,7 @@ def handle_request(data: Dict[str, Any]) -> Any: base_prompt = data.get("base_prompt", "") headers = data.get("headers", {}) server_base_url = cast(str, data.get("server_base_url", "")) - app = headers["X-App-Name"] or None + app = headers.get("X-App-Name") or None logging.info("[OpenCopilot] Got the following user request: {}".format(text)) for required_field, error_msg in [ @@ -81,7 +81,7 @@ def handle_request(data: Dict[str, Any]) -> Any: "of them" ) current_state = process_state(app, headers) - + logging.info(f"Received app configuration: {app}") bot_response = hasSingleIntent(swagger_doc, text, session_id, current_state) if len(bot_response.ids) >= 1: