feat: 放大 AI 规格候选上限至150条 (#284)

This commit is contained in:
chengma
2026-08-21 10:52:32 +08:00
parent c7f0ba9f9e
commit b50987824c
2 changed files with 13 additions and 13 deletions
+3 -3
View File
@@ -17,9 +17,9 @@ import (
const (
AISpecMatchPromptVersion = "spec_prompt_v1"
// 单次模型调用最多携带 100 个已过滤的可购买候选。超过这个数量时,
// 单次模型调用最多携带 150 个已过滤的可购买候选。超过这个数量时,
// 候选本身仍会写入审计记录,但不会让模型在过于宽泛的范围里猜测。
maxAIModelCandidates = 100
maxAIModelCandidates = 150
)
type AIMatchSnapshot struct {
@@ -151,7 +151,7 @@ func MatchSybSpecWithAI(ctx context.Context, db *sql.DB, actor *model.User, snap
}
if len(eligible) > maxAIModelCandidates {
baseDecision.CandidatesJSON = candidateAuditJSON(bindAICandidates(eligible))
return recordAIMatchWithoutSave(db, baseDecision, "rejected", "可购买候选超过 100 条,请先人工核对")
return recordAIMatchWithoutSave(db, baseDecision, "rejected", "可购买候选超过 150 条,请先人工核对")
}
bindings := bindAICandidates(eligible)
baseDecision.CandidatesJSON = candidateAuditJSON(bindings)