add 加入资金流向特大的标地

This commit is contained in:
yanweidong
2026-02-12 20:29:02 +08:00
parent 8de6c2a23a
commit c4fb37761b
6 changed files with 64 additions and 36 deletions

View File

@@ -6,8 +6,8 @@ import (
"git.apinb.com/quant/gostock/internal/config"
"git.apinb.com/quant/gostock/internal/impl"
"git.apinb.com/quant/gostock/internal/logic/mock"
"git.apinb.com/quant/gostock/internal/logic/strategy"
"git.apinb.com/quant/gostock/internal/logic/strategy/rule"
"git.apinb.com/quant/gostock/internal/logic/types"
"git.apinb.com/quant/gostock/internal/models"
"github.com/gocarina/gocsv"
@@ -21,41 +21,42 @@ func main() {
log.Println("Hello Cli!")
config.New(ServiceKey)
impl.NewImpl()
ymd := models.GetYmd()
for _, code := range strategy.GetStocks() {
strategy.InitCacheByCode(code)
model := models.NewStratModel("selector", code, ymd)
stratRule := rule.NewRule(model)
{
stratRule.RunUpDate(strategy.Cache[code].Basic.ListDate)
stratRule.RunST(strategy.Cache[code].Basic.Name)
stratRule.RunIndustry(strategy.Cache[code].Basic.Industry)
stratRule.RunPrice(code)
stratRule.RunAmount(code)
stratRule.RunRoe(code)
stratRule.RunRsi(code)
// 过滤无需AI分析
if model.StScore > 0 && model.IndustryScore > 0 && model.GtPrice > 0 && model.GtAmount > 0 && model.GtRoe > 0 && model.ScoreRsi > 0 {
model.AiScore = 0 // 待分析
} else {
model.AiScore = -2
model.AddDesc("无需AI分析")
}
}
model.Save()
}
strategy.BootAiStart("selector", models.GetYmd())
mock.Run("selector", models.GetYmd())
}
func ai() {
log.Println("Hello Cli!")
config.New(ServiceKey)
impl.NewImpl()
// func main() {
// log.Println("Hello Cli!")
// config.New(ServiceKey)
// impl.NewImpl()
}
// ymd := models.GetYmd()
// for _, code := range strategy.GetStocks() {
// strategy.InitCacheByCode(code)
// model := models.NewStratModel("selector", code, ymd)
// stratRule := rule.NewRule(model)
// {
// stratRule.RunUpDate(strategy.Cache[code].Basic.ListDate)
// stratRule.RunST(strategy.Cache[code].Basic.Name)
// stratRule.RunIndustry(strategy.Cache[code].Basic.Industry)
// stratRule.RunPrice(code)
// stratRule.RunAmount(code)
// stratRule.RunRoe(code)
// stratRule.RunRsi(code)
// // 过滤无需AI分析
// if model.StScore > 0 && model.IndustryScore > 0 && model.GtPrice > 0 && model.GtAmount > 0 && model.GtRoe > 0 && model.ScoreRsi > 0 {
// model.AiScore = 0 // 待分析
// } else {
// model.AiScore = -2
// model.AddDesc("无需AI分析")
// }
// }
// model.Save()
// }
// strategy.BootAiStart("selector", models.GetYmd())
// }
func main3() {
log.Println("Hello Cli!")