private static void addOnnxModels(Collection<OnnxModel> source,
                                      Map<String, OnnxModel> destination,
                                      String sourceName) {
        for (var model : source) {
            var existing = destination.get(model.getName());
            if ( existing != null && ! model.equals(existing)) {
                throw new IllegalArgumentException("Duplicate onnx model: " + sourceName + " have " + model +
                                                   ", but we already have " + existing +
                                                   ": Onnx models must be unique across all rank profiles/models");
            }
            destination.put(model.getName(), model);
        }
    }
Creates a rank profile list

@param schema the schema this is a rank profile from
@param attributeFields the attribute fields to create a ranking for
config-model/src/main/java/com/yahoo/schema/derived/RankProfileList.java