public Recommender addModelMetricsEntry(String key, Double value) {
        if (null == this.modelMetrics) {
            this.modelMetrics = new java.util.HashMap<String, Double>();
        }
        if (this.modelMetrics.containsKey(key))
            throw new IllegalArgumentException("Duplicated keys (" + key.toString() + ") are provided.");
        this.modelMetrics.put(key, value);
        return this;
    }
Add a single ModelMetrics entry

@see Recommender#withModelMetrics
@returns a reference to this object so that method calls can be chained together.
aws-java-sdk-personalize/src/main/java/com/amazonaws/services/personalize/model/Recommender.java