feat: 解析记忆操作 json 解析兼容
This commit is contained in:
@@ -9,6 +9,7 @@
|
||||
|
||||
import asyncio
|
||||
import json
|
||||
import json_repair
|
||||
import re
|
||||
from datetime import datetime
|
||||
from typing import Any
|
||||
@@ -573,7 +574,7 @@ class LongTermMemoryManager:
|
||||
json_str = re.sub(r"/\*.*?\*/", "", json_str, flags=re.DOTALL)
|
||||
|
||||
# 解析
|
||||
data = json.loads(json_str)
|
||||
data = json_repair.loads(json_str)
|
||||
|
||||
# 转换为 GraphOperation 对象
|
||||
operations = []
|
||||
|
||||
Reference in New Issue
Block a user