From a9a05c19e95fc2cc4fd0bc95f875573a56194213 Mon Sep 17 00:00:00 2001 From: renzhiyuan <465386466@qq.com> Date: Sat, 27 Dec 2025 15:41:57 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E4=BF=AE=E6=94=B9=E8=AE=A2=E5=8D=95?= =?UTF-8?q?=E5=8F=B7=E5=8F=82=E6=95=B0=E7=B1=BB=E5=9E=8B=E4=B8=BAinterface?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- internal/biz/do/prompt.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/internal/biz/do/prompt.go b/internal/biz/do/prompt.go index b216db5..a27d698 100644 --- a/internal/biz/do/prompt.go +++ b/internal/biz/do/prompt.go @@ -8,9 +8,9 @@ import ( "ai_scheduler/internal/pkg" "ai_scheduler/internal/pkg/utils_vllm" "context" + "fmt" "strings" - "github.com/gofiber/fiber/v2/log" "github.com/ollama/ollama/api" ) @@ -31,7 +31,7 @@ func (f *WithSys) CreatePrompt(ctx context.Context, rec *entitys.Recognize) (mes if err != nil { return nil, err } - log.Infof("生成prompt:%s", content.String()) + // 构建提示消息列表,包含系统提示、助手回复和用户内容 mes = append(prompt, api.Message{ Role: "system", // 系统角色 @@ -43,7 +43,7 @@ func (f *WithSys) CreatePrompt(ctx context.Context, rec *entitys.Recognize) (mes Role: "user", // 用户角色 Content: content.String(), // 用户输入内容 }) - + fmt.Printf("[意图识别]最终prompt:%v", mes) return }