diff --git a/src/khoj/interface/web/base_config.html b/src/khoj/interface/web/base_config.html index 309fdba6..05119fad 100644 --- a/src/khoj/interface/web/base_config.html +++ b/src/khoj/interface/web/base_config.html @@ -109,7 +109,7 @@ display: grid; grid-template-rows: repeat(3, 1fr); gap: 8px; - padding: 24px 16px; + padding: 24px 16px 8px; width: 320px; height: 180px; background: var(--background-color); @@ -162,10 +162,13 @@ color: grey; font-size: 16px; } - .card-button-row { + .card-description-row { + padding-top: 4px; + } + .card-action-row { display: grid; - grid-template-columns: auto; - text-align: right; + grid-auto-flow: row; + justify-content: left; } .card-button { border: none; @@ -287,6 +290,7 @@ select#chat-models { margin-bottom: 0; + padding: 8px; } diff --git a/src/khoj/interface/web/config.html b/src/khoj/interface/web/config.html index b2b7fbb3..34a4f642 100644 --- a/src/khoj/interface/web/config.html +++ b/src/khoj/interface/web/config.html @@ -29,12 +29,12 @@ {% endif %} - -
- +
+ +
@@ -61,13 +61,13 @@ {% endif %} -
-
- +
+ +
@@ -94,13 +94,13 @@ {% endif %} -
-
- +
+ +
diff --git a/tests/conftest.py b/tests/conftest.py index 08ff7033..8cf0a391 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -235,7 +235,7 @@ def chat_client(search_config: SearchConfig, default_user2: KhojUser): OpenAIProcessorConversationConfigFactory() UserConversationProcessorConfigFactory(user=default_user2, setting=chat_model) - state.anonymous_mode = False + state.anonymous_mode = True app = FastAPI() @@ -253,7 +253,9 @@ def chat_client_no_background(search_config: SearchConfig, default_user2: KhojUs # Initialize Processor from Config if os.getenv("OPENAI_API_KEY"): + chat_model = ChatModelOptionsFactory(chat_model="gpt-3.5-turbo", model_type="openai") OpenAIProcessorConversationConfigFactory() + UserConversationProcessorConfigFactory(user=default_user2, setting=chat_model) state.anonymous_mode = True diff --git a/tests/test_openai_chat_director.py b/tests/test_openai_chat_director.py index 14a73f15..c7d2e0ec 100644 --- a/tests/test_openai_chat_director.py +++ b/tests/test_openai_chat_director.py @@ -307,6 +307,7 @@ def test_ask_for_clarification_if_not_enough_context_in_question(chat_client_no_ "which one is", "which of namita's sons", "the birth order", + "provide more context", ] assert response.status_code == 200 assert any([expected_response in response_message.lower() for expected_response in expected_responses]), (