mirror of
https://github.com/csunny/DB-GPT.git
synced 2025-08-22 10:08:34 +00:00
web bug fix
This commit is contained in:
parent
9ac402e55a
commit
94fb112979
@ -44,7 +44,7 @@ class ChatWithDbAutoExecute(BaseChat):
|
|||||||
raise ValueError("Could not import DBSummaryClient. ")
|
raise ValueError("Could not import DBSummaryClient. ")
|
||||||
client = DBSummaryClient()
|
client = DBSummaryClient()
|
||||||
try:
|
try:
|
||||||
table_infos = client.get_similar_tables(dbname=self.db_name, query=self.current_user_input, topk=self.top_k)
|
table_infos = client.get_db_summary(dbname=self.db_name, query=self.current_user_input, topk=self.top_k)
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
print("db summary find error!" + str(e))
|
print("db summary find error!" + str(e))
|
||||||
table_infos = self.database.table_simple_info()
|
table_infos = self.database.table_simple_info()
|
||||||
|
@ -48,13 +48,13 @@ class ChatWithDbQA(BaseChat):
|
|||||||
if self.db_name:
|
if self.db_name:
|
||||||
client = DBSummaryClient()
|
client = DBSummaryClient()
|
||||||
try:
|
try:
|
||||||
table_infos = client.get_similar_tables(dbname=self.db_name, query=self.current_user_input,
|
table_infos = client.get_db_summary(dbname=self.db_name, query=self.current_user_input,
|
||||||
topk=self.top_k)
|
topk=self.top_k)
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
print("db summary find error!" + str(e))
|
print("db summary find error!" + str(e))
|
||||||
table_infos = self.database.table_simple_info()
|
table_infos = self.database.table_simple_info()
|
||||||
|
|
||||||
# table_info = self.database.table_simple_info(self.db_connect)
|
# table_infos = self.database.table_simple_info()
|
||||||
dialect = self.database.dialect
|
dialect = self.database.dialect
|
||||||
|
|
||||||
input_values = {
|
input_values = {
|
||||||
|
Loading…
Reference in New Issue
Block a user