Skip to content

🌟 The Multi-Agent Framework: First AI Software Company, Towards Natural Language Programming

refactor: brain memory

莘权 马1df4121b1286
diff --git a/metagpt/memory/brain_memory.py b/metagpt/memory/brain_memory.py
index 39e2ec43d..2d191ccaa 100644
--- a/metagpt/memory/brain_memory.py
+++ b/metagpt/memory/brain_memory.py
@@ -194,7 +194,7 @@ class BrainMemory(pydantic.BaseModel):
@staticmethod
def to_metagpt_history_format(history) -> str:
mmsg = []
- for m in reversed(history):
+ for m in history:
msg = Message(**m)
r = RawMessage(role="user" if MessageType.Talk.value in msg.tags else "assistant", content=msg.content)
mmsg.append(r)