mirror of
https://github.com/ArvinLovegood/go-stock.git
synced 2025-07-19 00:00:09 +08:00
feat(frontend):添加AI市场资讯总结功能
- 在市场组件中增加 AI 总结按钮和模态框 - 实现 SummaryStockNews 函数用于获取 AI 总结 - 添加 GetNewsList 方法获取市场新闻列表 - 优化市场资讯的展示和交互
This commit is contained in:
parent
3535ba57ab
commit
c4caea5be8
@ -564,7 +564,7 @@ func AskAi(o OpenAi, err error, messages []map[string]interface{}, ch chan map[s
|
||||
}
|
||||
return
|
||||
}
|
||||
location, _ := time.LoadLocation("Asia/Shanghai")
|
||||
//location, _ := time.LoadLocation("Asia/Shanghai")
|
||||
|
||||
scanner := bufio.NewScanner(body)
|
||||
for scanner.Scan() {
|
||||
@ -598,7 +598,7 @@ func AskAi(o OpenAi, err error, messages []map[string]interface{}, ch chan map[s
|
||||
"chatId": streamResponse.Id,
|
||||
"model": streamResponse.Model,
|
||||
"content": content,
|
||||
"time": time.Now().In(location).Format(time.DateTime),
|
||||
"time": time.Now().Format(time.DateTime),
|
||||
}
|
||||
|
||||
//logger.SugaredLogger.Infof("Content data: %s", content)
|
||||
@ -611,7 +611,7 @@ func AskAi(o OpenAi, err error, messages []map[string]interface{}, ch chan map[s
|
||||
"chatId": streamResponse.Id,
|
||||
"model": streamResponse.Model,
|
||||
"content": reasoningContent,
|
||||
"time": time.Now().In(location).Format(time.DateTime),
|
||||
"time": time.Now().Format(time.DateTime),
|
||||
}
|
||||
|
||||
//logger.SugaredLogger.Infof("ReasoningContent data: %s", reasoningContent)
|
||||
|
Loading…
x
Reference in New Issue
Block a user