Skip to content

Commit

Permalink
[docs] Update doc-string for buffer_as_messages method in Conversatio…
Browse files Browse the repository at this point in the history
…nBufferWindowMemory (langchain-ai#18136)

minor fix stated in langchain-ai#18080
  • Loading branch information
lgabs authored and gkorland committed Mar 30, 2024
1 parent db57e85 commit 62150f6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion libs/langchain/langchain/memory/buffer_window.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ def buffer_as_str(self) -> str:

@property
def buffer_as_messages(self) -> List[BaseMessage]:
"""Exposes the buffer as a list of messages in case return_messages is False."""
"""Exposes the buffer as a list of messages in case return_messages is True."""
return self.chat_memory.messages[-self.k * 2 :] if self.k > 0 else []

@property
Expand Down

0 comments on commit 62150f6

Please sign in to comment.