Skip to content

Commit

Permalink
current只保留role和content
Browse files Browse the repository at this point in the history
  • Loading branch information
yehaodong-genomics-cn committed Apr 21, 2023
1 parent 98f9cb1 commit 0662ae7
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

setup(
name="azureChatGPT",
version="0.0.4",
version="0.0.5",
description="ChatGPT is a reverse engineering of Azure ChatGPT API",
long_description=open(PATH, encoding="utf-8").read(),
long_description_content_type="text/markdown",
Expand Down
2 changes: 1 addition & 1 deletion src/azureChatGPT/azure.py
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ def __truncate_conversation(self, convo_id: str = "default") -> None:
Truncate the conversation
"""
self.conversation["current"] = [
dict((key, sentence[key]) for key in sentence if key != "name")
dict((key, sentence[key]) for key in ["role", "content"])
for sentence in self.conversation[convo_id]
]

Expand Down

0 comments on commit 0662ae7

Please sign in to comment.