对用户说的想法摘要.[response_table]SELECT * FROM excel_data WHERE "月工资金额" < 2000--- Logging error ---
Traceback (most recent call last):
File "/Users/luoxin/Desktop/git_repo/DB-GPT-main/dbgpt/agent/util/api_call.py", line 283, in display_sql_llmvis
self.update_from_context(llm_text)
File "/Users/luoxin/Desktop/git_repo/DB-GPT-main/dbgpt/agent/util/api_call.py", line 159, in update_from_context
api_call_element = ET.fromstring(api_context)
File "/Users/luoxin/miniforge3/envs/lx/dbgpt_env/lib/python3.10/xml/etree/ElementTree.py", line 1347, in XML
parser.feed(text)
xml.etree.ElementTree.ParseError: not well-formed (invalid token): line 1, column 90
During handling of the above exception, another exception occurred:
What you expected to happen
该输出结果应该可以被update_from_context方法所解析: <api-call><name>[response_table]</name><args><sql>SELECT * FROM excel_data WHERE "月工资金额" < 2000</sql></args></api-call>
How to reproduce
revise ./dbgpt/agent/util/api_call.py in update_from_context
def update_from_context(self, all_context):
"""Modify the plugin status map based on the context."""
api_context_map: Dict[int, str] = extract_content(
all_context, self.agent_prefix, self.agent_end, True
)
for api_index, api_context in api_context_map.items():
api_context = api_context.replace("\\n", "").replace("\n", "")
api_call_element = ET.fromstring(api_context)
Search before asking
Operating system information
Linux
Python version information
DB-GPT version
main
Related scenes
Installation Information
[ ] Installation From Source
[ ] Docker Installation
[ ] Docker Compose Installation
[ ] Cluster Installation
[ ] AutoDL Image
[ ] Other
Device information
GPI count 1 : 24G
Models information
LLM: chatglm3-6b
What happened
对用户说的想法摘要.[response_table] SELECT * FROM excel_data WHERE "月工资金额" < 2000 --- Logging error ---
Traceback (most recent call last):
File "/Users/luoxin/Desktop/git_repo/DB-GPT-main/dbgpt/agent/util/api_call.py", line 283, in display_sql_llmvis
self.update_from_context(llm_text)
File "/Users/luoxin/Desktop/git_repo/DB-GPT-main/dbgpt/agent/util/api_call.py", line 159, in update_from_context
api_call_element = ET.fromstring(api_context)
File "/Users/luoxin/miniforge3/envs/lx/dbgpt_env/lib/python3.10/xml/etree/ElementTree.py", line 1347, in XML
parser.feed(text)
xml.etree.ElementTree.ParseError: not well-formed (invalid token): line 1, column 90
During handling of the above exception, another exception occurred:
What you expected to happen
该输出结果应该可以被update_from_context方法所解析:
<api-call><name>[response_table]</name><args><sql>SELECT * FROM excel_data WHERE "月工资金额" < 2000</sql></args></api-call>
How to reproduce
revise ./dbgpt/agent/util/api_call.py in update_from_context
Additional context
No response
Are you willing to submit PR?