From 201f833bba138563d9432825700b0620bcb2f8b0 Mon Sep 17 00:00:00 2001 From: jiulinxiri Date: Fri, 25 Aug 2023 15:09:49 +0800 Subject: [PATCH] =?UTF-8?q?=E9=A1=B9=E7=9B=AE=E8=AE=BF=E9=97=AE=E4=BF=AE?= =?UTF-8?q?=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .gitea/workflows/deploy.yml | 1 + pom.xml | 4 ++-- src/main/java/cn/honour/controller/ErnieBotController.java | 6 ++---- 3 files changed, 5 insertions(+), 6 deletions(-) create mode 100644 .gitea/workflows/deploy.yml diff --git a/.gitea/workflows/deploy.yml b/.gitea/workflows/deploy.yml new file mode 100644 index 0000000..8b13789 --- /dev/null +++ b/.gitea/workflows/deploy.yml @@ -0,0 +1 @@ + diff --git a/pom.xml b/pom.xml index be1d01d..a44e738 100644 --- a/pom.xml +++ b/pom.xml @@ -11,9 +11,9 @@ - org.example + cn.ourhonour QAI - 1.0-SNAPSHOT + 1.0 diff --git a/src/main/java/cn/honour/controller/ErnieBotController.java b/src/main/java/cn/honour/controller/ErnieBotController.java index 4f833f0..2a8e408 100644 --- a/src/main/java/cn/honour/controller/ErnieBotController.java +++ b/src/main/java/cn/honour/controller/ErnieBotController.java @@ -6,10 +6,7 @@ import com.gearwenxin.client.ernie.ErnieBotClient; import com.gearwenxin.entity.chatmodel.ChatErnieRequest; import com.gearwenxin.entity.response.ChatResponse; import org.springframework.http.MediaType; -import org.springframework.web.bind.annotation.PostMapping; -import org.springframework.web.bind.annotation.RequestBody; -import org.springframework.web.bind.annotation.RequestMapping; -import org.springframework.web.bind.annotation.RestController; +import org.springframework.web.bind.annotation.*; import reactor.core.publisher.Flux; import javax.annotation.Resource; @@ -18,6 +15,7 @@ import javax.annotation.Resource; * 文心一言的相关接口 * @author qiaoxiaoxu */ +@CrossOrigin @RestController @RequestMapping("/ernie") public class ErnieBotController {