🌟 The Multi-Agent Framework: First AI Software Company, Towards Natural Language Programming
feat: truncated history
莘权 马92402bedd4e2
diff --git a/metagpt/memory/brain_memory.py b/metagpt/memory/brain_memory.pyindex d83611af1..04ae6593a 100644--- a/metagpt/memory/brain_memory.py+++ b/metagpt/memory/brain_memory.py@@ -110,6 +110,7 @@ class BrainMemory(pydantic.BaseModel):if self.to_int(msg.id, 0) <= self.to_int(self.last_history_id, -1):returnself.history.append(msg.dict())+ self.last_history_id = str(msg.id)self.is_dirty = Truedef exists(self, text) -> bool: