feat: support cloudflare worker ai

This commit is contained in:
CalciumIon
2024-07-13 19:55:22 +08:00
parent 1086340e14
commit fe4665fd99
15 changed files with 296 additions and 28 deletions
+2 -1
View File
@@ -68,7 +68,8 @@ func GenRelayInfo(c *gin.Context) *RelayInfo {
info.ApiVersion = GetAPIVersion(c)
}
if info.ChannelType == common.ChannelTypeOpenAI || info.ChannelType == common.ChannelTypeAnthropic ||
info.ChannelType == common.ChannelTypeAws || info.ChannelType == common.ChannelTypeGemini {
info.ChannelType == common.ChannelTypeAws || info.ChannelType == common.ChannelTypeGemini ||
info.ChannelType == common.ChannelCloudflare {
info.SupportStreamOptions = true
}
return info