diff --git a/docs/source/users/index.md b/docs/source/users/index.md index d7e85668a..898b6047b 100644 --- a/docs/source/users/index.md +++ b/docs/source/users/index.md @@ -471,8 +471,8 @@ use the `-a` or `--all-files` option. /learn -r arxiv 2404.18558 ``` -### Exporting chat history -Use the `/export` command to export the chat history from the current session to a markdown file named `chat_history-YYYY-MM-DD-HH-mm.md`. Using `/export ` will export the chat history to `-YYYY-MM-DD-HH-mm.md` instead. You can export chat history as many times as you like in a single session. Each successive export will include the entire chat history up to that point in the session. +### Exporting chat history +Use the `/export` command to export the chat history from the current session to a markdown file named `chat_history-YYYY-MM-DD-HH-mm.md`. Using `/export ` will export the chat history to `-YYYY-MM-DD-HH-mm.md` instead. You can export chat history as many times as you like in a single session. Each successive export will include the entire chat history up to that point in the session. ### Additional chat commands diff --git a/packages/jupyter-ai/jupyter_ai/chat_handlers/export.py b/packages/jupyter-ai/jupyter_ai/chat_handlers/export.py index 9b384870c..db4896318 100644 --- a/packages/jupyter-ai/jupyter_ai/chat_handlers/export.py +++ b/packages/jupyter-ai/jupyter_ai/chat_handlers/export.py @@ -28,8 +28,8 @@ def chat_message_to_markdown(self, message): # Multiple chat histories can be saved in separate files, each with a timestamp def get_chat_filename(self, file_id): - file_id = file_id.split(" ") - if len(file_id)>1: + file_id = file_id.split(" ") + if len(file_id) > 1: file_id = file_id[-1] else: file_id = "chat_history"