to:sync
This commit is contained in:
parent
fd338e363b
commit
64ec45e822
@ -14,7 +14,7 @@ type aiApiImpl struct {
|
|||||||
func (aiApiImpl) Completions(ctx context.Context, prompt, groupId string) (*dto.AiRes, error) {
|
func (aiApiImpl) Completions(ctx context.Context, prompt, groupId string) (*dto.AiRes, error) {
|
||||||
logger := utils.NewLog("")
|
logger := utils.NewLog("")
|
||||||
|
|
||||||
url := "https://ai-service.mylomen.com/text/v3/completions"
|
url := "http://ai-service.service.consul:8080/text/v3/completions"
|
||||||
|
|
||||||
var aiResult Result[dto.AiRes]
|
var aiResult Result[dto.AiRes]
|
||||||
resp, err := httpClient.R().
|
resp, err := httpClient.R().
|
||||||
|
2
main.go
2
main.go
@ -44,7 +44,7 @@ func main() {
|
|||||||
|
|
||||||
//健康检测
|
//健康检测
|
||||||
e.GET("/health", func(c echo.Context) error { return c.JSON(http.StatusOK, "ok") })
|
e.GET("/health", func(c echo.Context) error { return c.JSON(http.StatusOK, "ok") })
|
||||||
e.GET("/name", func(c echo.Context) error { return c.JSON(http.StatusOK, "wx-server") })
|
e.GET("/name", func(c echo.Context) error { return c.JSON(http.StatusOK, "ai-gateway") })
|
||||||
e.GET("/v1/subscribeEmail", func(c echo.Context) error { return c.JSON(http.StatusOK, "ok") })
|
e.GET("/v1/subscribeEmail", func(c echo.Context) error { return c.JSON(http.StatusOK, "ok") })
|
||||||
e.GET("/v1/unsubscribeEmail", func(c echo.Context) error { return c.JSON(http.StatusOK, "ok") })
|
e.GET("/v1/unsubscribeEmail", func(c echo.Context) error { return c.JSON(http.StatusOK, "ok") })
|
||||||
e.GET("/v1/subscribeTopic", func(c echo.Context) error { return c.JSON(http.StatusOK, "ok") })
|
e.GET("/v1/subscribeTopic", func(c echo.Context) error { return c.JSON(http.StatusOK, "ok") })
|
||||||
|
@ -21,7 +21,7 @@ job "${APP_NAME}-${CI_COMMIT_BRANCH}-job" {
|
|||||||
|
|
||||||
env = {
|
env = {
|
||||||
"API_ENV" : "prod"
|
"API_ENV" : "prod"
|
||||||
"ST_CONSUL_datacenter" = "dj01"
|
"ST_CONSUL_datacenter" = "sh01"
|
||||||
|
|
||||||
"APP_NAME" = "${APP_NAME}"
|
"APP_NAME" = "${APP_NAME}"
|
||||||
"CI_COMMIT_BRANCH" = "${CI_COMMIT_BRANCH}"
|
"CI_COMMIT_BRANCH" = "${CI_COMMIT_BRANCH}"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user