feat: add system prompt override functionality in channel settings and request handling #1468

This commit is contained in:
CaIon
2025-08-09 12:53:06 +08:00
parent 3b61617cb1
commit 2a804b6c02
10 changed files with 153 additions and 92 deletions

View File

@@ -267,6 +267,8 @@ func SetupContextForSelectedChannel(c *gin.Context, channel *model.Channel, mode
common.SetContextKey(c, constant.ContextKeyChannelKey, key)
common.SetContextKey(c, constant.ContextKeyChannelBaseUrl, channel.GetBaseURL())
common.SetContextKey(c, constant.ContextKeySystemPromptOverride, false)
// TODO: api_version统一
switch channel.Type {
case constant.ChannelTypeAzure: