From 716824860bd18411221c15dc4ee0b2cd9d53adda Mon Sep 17 00:00:00 2001 From: Dev Khant Date: Thu, 19 Dec 2024 15:00:53 +0530 Subject: [PATCH] Openai proxy: allow system prompt from user (#2097) --- mem0/proxy/main.py | 1 - pyproject.toml | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/mem0/proxy/main.py b/mem0/proxy/main.py index f52177d0fd..8689ef3e1c 100644 --- a/mem0/proxy/main.py +++ b/mem0/proxy/main.py @@ -149,7 +149,6 @@ def create( def _prepare_messages(self, messages: List[dict]) -> List[dict]: if not messages or messages[0]["role"] != "system": return [{"role": "system", "content": MEMORY_ANSWER_PROMPT}] + messages - messages[0]["content"] = MEMORY_ANSWER_PROMPT return messages def _async_add_to_memory(self, messages, user_id, agent_id, run_id, metadata, filters): diff --git a/pyproject.toml b/pyproject.toml index 3358cb1491..60bc8f0270 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "mem0ai" -version = "0.1.35" +version = "0.1.36" description = "Long-term memory for AI Agents" authors = ["Mem0 "] exclude = [