Skip to content

Commit

Permalink
🔧 Update type annotations
Browse files Browse the repository at this point in the history
  • Loading branch information
shroominic committed Jan 27, 2024
1 parent 0938096 commit 8e70866
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions src/funcchain/utils/memory.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
"""langchain_community.chat_message_histories.in_memory.ChatMessageHistory"""

from typing import List

from langchain_core.chat_history import BaseChatMessageHistory
from langchain_core.messages import BaseMessage
from langchain_core.pydantic_v1 import BaseModel, Field
Expand All @@ -13,7 +11,7 @@ class ChatMessageHistory(BaseChatMessageHistory, BaseModel):
Stores messages in an in memory list.
"""

messages: List[BaseMessage] = Field(default_factory=list)
messages: list[BaseMessage] = Field(default_factory=list)

def add_message(self, message: BaseMessage) -> None:
"""Add a self-created message to the store"""
Expand Down

0 comments on commit 8e70866

Please sign in to comment.