mirror of
https://github.com/csunny/DB-GPT.git
synced 2025-09-01 09:06:55 +00:00
Merge remote-tracking branch 'origin/Agent_Hub_Dev' into feat_rag_graph
This commit is contained in:
@@ -371,6 +371,7 @@ class ApiCall:
|
||||
else:
|
||||
api_call_element = ET.Element("chart-view")
|
||||
api_call_element.attrib["content"] = self.__to_antv_vis_param(api_status)
|
||||
api_call_element.text = "\n"
|
||||
# api_call_element.set("content", self.__to_antv_vis_param(api_status))
|
||||
# api_call_element.text = self.__to_antv_vis_param(api_status)
|
||||
result = ET.tostring(api_call_element, encoding="utf-8")
|
||||
@@ -487,7 +488,6 @@ class ApiCall:
|
||||
value.end_time = datetime.now().timestamp() * 1000
|
||||
except Exception as e:
|
||||
logging.error("Api parsing exception", e)
|
||||
value.status = Status.FAILED.value
|
||||
value.err_msg = "Api parsing exception," + str(e)
|
||||
raise ValueError("Api parsing exception," + str(e))
|
||||
|
||||
return self.api_view_context(llm_text, True)
|
||||
|
@@ -25,7 +25,7 @@ class Scene:
|
||||
class ChatScene(Enum):
|
||||
ChatWithDbExecute = Scene(
|
||||
code="chat_with_db_execute",
|
||||
name="Chat DB",
|
||||
name="Chat Data",
|
||||
describe="Dialogue with your private databse data through natural language.",
|
||||
param_types=["DB Select"],
|
||||
)
|
||||
|
@@ -21,7 +21,7 @@ Constraint:
|
||||
4.Give priority to answering using data analysis. If the user's question does not involve data analysis, you can answer according to your understanding.
|
||||
5.The sql part of the output content is converted to: <api-call><name>[data display mode]</name><args><sql>[correct duckdb data analysis sql]</sql></args></api - call> For this format, please refer to the return format requirements.
|
||||
|
||||
Please respond in the following format:
|
||||
Please think step by step and give your answer, and make sure your answer is formatted as follows:
|
||||
thoughts summary to say to user.<api-call><name>[Data display method]</name><args><sql>[Correct duckdb data analysis sql]</sql></args></api-call>
|
||||
|
||||
User Questions:
|
||||
@@ -38,7 +38,7 @@ _DEFAULT_TEMPLATE_ZH = """
|
||||
4.优先使用数据分析的方式回答,如果用户问题不涉及数据分析内容,你可以按你的理解进行回答
|
||||
5.输出内容中sql部分转换为:<api-call><name>[数据显示方式]</name><args><sql>[正确的duckdb数据分析sql]</sql></args></api- call> 这样的格式,参考返回格式要求
|
||||
|
||||
请确保你的输出内容格式如下:
|
||||
请一步一步思考,给出回答,并确保你的回答内容格式如下:
|
||||
对用户说的想法摘要.<api-call><name>[数据展示方式]</name><args><sql>[正确的duckdb数据分析sql]</sql></args></api-call>
|
||||
|
||||
用户问题:{user_input}
|
||||
|
Reference in New Issue
Block a user