Skip to content

Commit

Permalink
Fix info panel overflow (#33)
Browse files Browse the repository at this point in the history
* update chatbot placeholder

* fix chat info panel overflow bug

* set azure_endpoint to required in AzureChatOpenAI

* update screenshots
  • Loading branch information
lone17 authored Apr 14, 2024
1 parent 8985963 commit 5286ff4
Show file tree
Hide file tree
Showing 8 changed files with 9 additions and 5 deletions.
Binary file modified docs/images/chat-tab-demo.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/images/chat-tab.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/images/file-index-tab.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/images/resources-tab.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 2 additions & 1 deletion libs/kotaemon/kotaemon/llms/chats/openai.py
Original file line number Diff line number Diff line change
Expand Up @@ -299,7 +299,8 @@ class AzureChatOpenAI(BaseChatOpenAI):
"HTTPS endpoint for the Azure OpenAI model. The azure_endpoint, "
"azure_deployment, and api_version parameters are used to construct "
"the full URL for the Azure OpenAI model."
)
),
require=True,
)
azure_deployment: str = Param(help="Azure deployment name", required=True)
api_version: str = Param(help="Azure model version", required=True)
Expand Down
2 changes: 1 addition & 1 deletion libs/ktem/ktem/assets/css/main.css
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ button.selected {

#chat-info-panel {
max-height: var(--main-area-height) !important;
overflow-y: scroll !important;
overflow: auto !important;
}

#conv-settings-panel {
Expand Down
4 changes: 2 additions & 2 deletions libs/ktem/ktem/pages/chat/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -63,9 +63,9 @@ def on_building_ui(self):
with gr.Column(scale=6, elem_id="chat-area"):
self.chat_panel = ChatPanel(self._app)

with gr.Column(scale=3):
with gr.Column(scale=3, elem_id="chat-info-panel"):
with gr.Accordion(label="Information panel", open=True):
self.info_panel = gr.HTML(elem_id="chat-info-panel")
self.info_panel = gr.HTML()

def on_register_events(self):
gr.on(
Expand Down
5 changes: 4 additions & 1 deletion libs/ktem/ktem/pages/chat/chat_panel.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,10 @@ def __init__(self, app):
def on_building_ui(self):
self.chatbot = gr.Chatbot(
label="Kotaemon",
placeholder="This is the beginning of a new conversation.",
placeholder=(
"This is the beginning of a new conversation.\nMake sure to have added"
" a LLM by following the instructions in the Help tab."
),
show_label=False,
elem_id="main-chat-bot",
show_copy_button=True,
Expand Down

0 comments on commit 5286ff4

Please sign in to comment.