Skip to content
Closed
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions core/mcp.go
Original file line number Diff line number Diff line change
Expand Up @@ -899,9 +899,9 @@ func (m *MCPManager) addMCPToolsToBifrostRequest(ctx context.Context, req *schem
req.Params = &schemas.ModelParameters{}
}
if req.Params.Tools == nil {
req.Params.Tools = &[]schemas.Tool{}
req.Params.Tools = []schemas.Tool{}
}
tools := *req.Params.Tools
tools := req.Params.Tools

// Create a map of existing tool names for O(1) lookup
existingToolsMap := make(map[string]bool)
Expand All @@ -917,7 +917,7 @@ func (m *MCPManager) addMCPToolsToBifrostRequest(ctx context.Context, req *schem
existingToolsMap[mcpTool.Function.Name] = true
}
}
req.Params.Tools = &tools
req.Params.Tools = tools

}
return req
Expand Down
Loading