diff --git a/src/khoj/interface/web/chat.html b/src/khoj/interface/web/chat.html
index 67004923..062798a2 100644
--- a/src/khoj/interface/web/chat.html
+++ b/src/khoj/interface/web/chat.html
@@ -1449,6 +1449,8 @@ To get started, just start typing below. You can also type / to see a list of co
overflow-y: scroll;
text-align: left;
transition: width 0.3s ease-in-out;
+ max-height: 85vh;
+ overflow-y: auto;
}
div#side-panel.collapsed {
diff --git a/src/khoj/routers/helpers.py b/src/khoj/routers/helpers.py
index 65e197d9..469bfa40 100644
--- a/src/khoj/routers/helpers.py
+++ b/src/khoj/routers/helpers.py
@@ -118,7 +118,7 @@ def construct_chat_history(conversation_history: dict, n: int = 4) -> str:
if chat["by"] == "khoj" and chat["intent"].get("type") == "remember":
chat_history += f"User: {chat['intent']['query']}\n"
chat_history += f"Khoj: {chat['message']}\n"
- elif chat["by"] == "khoj" and chat["intent"].get("type") == "text-to-image":
+ elif chat["by"] == "khoj" and ("text-to-image" in chat["intent"].get("type")):
chat_history += f"User: {chat['intent']['query']}\n"
chat_history += f"Khoj: [generated image redacted for space]\n"
return chat_history