mirror of
https://github.com/nomic-ai/gpt4all.git
synced 2025-09-04 10:04:35 +00:00
Clear chat history between chat sessions (#1116)
This commit is contained in:
@@ -237,13 +237,13 @@ class GPT4All:
|
|||||||
'''
|
'''
|
||||||
# Code to acquire resource, e.g.:
|
# Code to acquire resource, e.g.:
|
||||||
self._is_chat_session_activated = True
|
self._is_chat_session_activated = True
|
||||||
self._current_chat_session = []
|
self.current_chat_session = []
|
||||||
try:
|
try:
|
||||||
yield self
|
yield self
|
||||||
finally:
|
finally:
|
||||||
# Code to release resource, e.g.:
|
# Code to release resource, e.g.:
|
||||||
self._is_chat_session_activated = False
|
self._is_chat_session_activated = False
|
||||||
self._current_chat_session = []
|
self.current_chat_session = []
|
||||||
|
|
||||||
def _format_chat_prompt_template(
|
def _format_chat_prompt_template(
|
||||||
self, messages: List[Dict], default_prompt_header=True, default_prompt_footer=True
|
self, messages: List[Dict], default_prompt_header=True, default_prompt_footer=True
|
||||||
|
@@ -61,7 +61,7 @@ copy_prebuilt_C_lib(SRC_CLIB_DIRECtORY,
|
|||||||
|
|
||||||
setup(
|
setup(
|
||||||
name=package_name,
|
name=package_name,
|
||||||
version="1.0.0",
|
version="1.0.1",
|
||||||
description="Python bindings for GPT4All",
|
description="Python bindings for GPT4All",
|
||||||
author="Richard Guo",
|
author="Richard Guo",
|
||||||
author_email="richard@nomic.ai",
|
author_email="richard@nomic.ai",
|
||||||
|
Reference in New Issue
Block a user