mirror of
https://github.com/CodePhiliaX/Chat2DB.git
synced 2025-09-21 20:13:34 +08:00
ai config update
This commit is contained in:
@ -367,7 +367,12 @@ public class ChatController {
|
||||
if (CollectionUtils.isEmpty(tableNames)) {
|
||||
return Maps.newHashMap();
|
||||
}
|
||||
List<TableColumn> tableColumns = tableService.queryColumns(tableQueryParam);
|
||||
List<TableColumn> tableColumns = Lists.newArrayList();
|
||||
try {
|
||||
tableColumns = tableService.queryColumns(tableQueryParam);
|
||||
} catch (Exception exception) {
|
||||
log.error("query table error, do nothing");
|
||||
}
|
||||
if (CollectionUtils.isEmpty(tableColumns)) {
|
||||
return Maps.newHashMap();
|
||||
}
|
||||
|
@ -110,11 +110,6 @@ public class AzureOpenAIEventSourceListener extends EventSourceListener {
|
||||
try {
|
||||
if (Objects.isNull(response)) {
|
||||
String message = t.getMessage();
|
||||
if ("No route to host".equals(message)) {
|
||||
message = "网络连接超时,请检查网络连通性,参考文章<https://github.com/chat2db/Chat2DB/blob/main/CHAT2DB_AI_SQL.md>";
|
||||
} else {
|
||||
message = "Azure AI无法正常访问,请参考文章<https://github.com/chat2db/Chat2DB/blob/main/CHAT2DB_AI_SQL.md>进行配置";
|
||||
}
|
||||
Message sseMessage = new Message();
|
||||
sseMessage.setContent(message);
|
||||
sseEmitter.send(SseEmitter.event()
|
||||
|
Reference in New Issue
Block a user