mirror of
https://github.com/alibaba/higress.git
synced 2026-05-29 23:27:28 +08:00
fix(ai-proxy): restrict the stream_options parameter to be effective only in the openai/v1/chatcompletions (#2524)
Signed-off-by: Xijun Dai <daixijun1990@gmail.com>
This commit is contained in:
@@ -82,7 +82,7 @@ func (m *doubaoProvider) TransformRequestBody(ctx wrapper.HttpContext, apiName A
|
||||
// 移除火山 responses 接口暂时不支持的参数
|
||||
// 参考: https://www.volcengine.com/docs/82379/1569618
|
||||
// TODO: 这里应该用 DTO 处理
|
||||
for _, param := range []string{"parallel_tool_calls", "tool_choice", "stream_options"} {
|
||||
for _, param := range []string{"parallel_tool_calls", "tool_choice"} {
|
||||
body, err = sjson.DeleteBytes(body, param)
|
||||
if err != nil {
|
||||
log.Warnf("[doubao] failed to delete %s in request body, err: %v", param, err)
|
||||
|
||||
Reference in New Issue
Block a user