From 947ed233c58828e66d87067c1c63b763b936a10d Mon Sep 17 00:00:00 2001 From: fiatrete Date: Fri, 16 Jun 2023 15:58:57 +0800 Subject: [PATCH] No need for wrap user input into a json any more --- agent_jarvis/jarvis/ai_agent/gpt_agent.py | 3 --- 1 file changed, 3 deletions(-) diff --git a/agent_jarvis/jarvis/ai_agent/gpt_agent.py b/agent_jarvis/jarvis/ai_agent/gpt_agent.py index 8b7011b..18009fd 100644 --- a/agent_jarvis/jarvis/ai_agent/gpt_agent.py +++ b/agent_jarvis/jarvis/ai_agent/gpt_agent.py @@ -65,9 +65,6 @@ class GptAgent(BaseAgent): # Send message to AI, get response logger.debug(f"Trigger: {prompt}") reply: Dict = None - # It seems that after the message is wrapped in JSON format, - # the probability that GPT will reply to the message in JSON format is much higher - prompt = json.dumps({"message": prompt}) for i in range(3): try: if i == 0: