fix: stream need query alt=sse

This commit is contained in:
zijiren233 2024-07-14 10:16:59 +08:00
parent 005fa5fc4a
commit ab8a56848f

View File

@ -63,13 +63,13 @@ func (a *Adaptor) GetRequestURL(meta *meta.Meta) (string, error) {
suffix := ""
if strings.HasPrefix(meta.ActualModelName, "gemini") {
if meta.IsStream {
suffix = "streamGenerateContent"
suffix = "streamGenerateContent?alt=sse"
} else {
suffix = "generateContent"
}
} else {
if meta.IsStream {
suffix = "streamRawPredict"
suffix = "streamRawPredict?alt=sse"
} else {
suffix = "rawPredict"
}