All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.amazonaws.services.bedrock.model.EvaluationDataset Maven / Gradle / Ivy

Go to download

The AWS Java SDK for Amazon Bedrock module holds the client classes that are used for communicating with Amazon Bedrock Service

The newest version!
/*
 * Copyright 2019-2024 Amazon.com, Inc. or its affiliates. All Rights Reserved.
 * 
 * Licensed under the Apache License, Version 2.0 (the "License"). You may not use this file except in compliance with
 * the License. A copy of the License is located at
 * 
 * http://aws.amazon.com/apache2.0
 * 
 * or in the "license" file accompanying this file. This file is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
 * CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions
 * and limitations under the License.
 */
package com.amazonaws.services.bedrock.model;

import java.io.Serializable;
import javax.annotation.Generated;
import com.amazonaws.protocol.StructuredPojo;
import com.amazonaws.protocol.ProtocolMarshaller;

/**
 * 

* Used to specify the name of a built-in prompt dataset and optionally, the Amazon S3 bucket where a custom prompt * dataset is saved. *

* * @see AWS API * Documentation */ @Generated("com.amazonaws:aws-java-sdk-code-generator") public class EvaluationDataset implements Serializable, Cloneable, StructuredPojo { /** *

* Used to specify supported built-in prompt datasets. Valid values are Builtin.Bold, * Builtin.BoolQ, Builtin.NaturalQuestions, Builtin.Gigaword, * Builtin.RealToxicityPrompts, Builtin.TriviaQa, Builtin.T-Rex, * Builtin.WomensEcommerceClothingReviews and Builtin.Wikitext2. *

*/ private String name; /** *

* For custom prompt datasets, you must specify the location in Amazon S3 where the prompt dataset is saved. *

*/ private EvaluationDatasetLocation datasetLocation; /** *

* Used to specify supported built-in prompt datasets. Valid values are Builtin.Bold, * Builtin.BoolQ, Builtin.NaturalQuestions, Builtin.Gigaword, * Builtin.RealToxicityPrompts, Builtin.TriviaQa, Builtin.T-Rex, * Builtin.WomensEcommerceClothingReviews and Builtin.Wikitext2. *

* * @param name * Used to specify supported built-in prompt datasets. Valid values are Builtin.Bold, * Builtin.BoolQ, Builtin.NaturalQuestions, Builtin.Gigaword, * Builtin.RealToxicityPrompts, Builtin.TriviaQa, Builtin.T-Rex, * Builtin.WomensEcommerceClothingReviews and Builtin.Wikitext2. */ public void setName(String name) { this.name = name; } /** *

* Used to specify supported built-in prompt datasets. Valid values are Builtin.Bold, * Builtin.BoolQ, Builtin.NaturalQuestions, Builtin.Gigaword, * Builtin.RealToxicityPrompts, Builtin.TriviaQa, Builtin.T-Rex, * Builtin.WomensEcommerceClothingReviews and Builtin.Wikitext2. *

* * @return Used to specify supported built-in prompt datasets. Valid values are Builtin.Bold, * Builtin.BoolQ, Builtin.NaturalQuestions, Builtin.Gigaword, * Builtin.RealToxicityPrompts, Builtin.TriviaQa, Builtin.T-Rex, * Builtin.WomensEcommerceClothingReviews and Builtin.Wikitext2. */ public String getName() { return this.name; } /** *

* Used to specify supported built-in prompt datasets. Valid values are Builtin.Bold, * Builtin.BoolQ, Builtin.NaturalQuestions, Builtin.Gigaword, * Builtin.RealToxicityPrompts, Builtin.TriviaQa, Builtin.T-Rex, * Builtin.WomensEcommerceClothingReviews and Builtin.Wikitext2. *

* * @param name * Used to specify supported built-in prompt datasets. Valid values are Builtin.Bold, * Builtin.BoolQ, Builtin.NaturalQuestions, Builtin.Gigaword, * Builtin.RealToxicityPrompts, Builtin.TriviaQa, Builtin.T-Rex, * Builtin.WomensEcommerceClothingReviews and Builtin.Wikitext2. * @return Returns a reference to this object so that method calls can be chained together. */ public EvaluationDataset withName(String name) { setName(name); return this; } /** *

* For custom prompt datasets, you must specify the location in Amazon S3 where the prompt dataset is saved. *

* * @param datasetLocation * For custom prompt datasets, you must specify the location in Amazon S3 where the prompt dataset is saved. */ public void setDatasetLocation(EvaluationDatasetLocation datasetLocation) { this.datasetLocation = datasetLocation; } /** *

* For custom prompt datasets, you must specify the location in Amazon S3 where the prompt dataset is saved. *

* * @return For custom prompt datasets, you must specify the location in Amazon S3 where the prompt dataset is saved. */ public EvaluationDatasetLocation getDatasetLocation() { return this.datasetLocation; } /** *

* For custom prompt datasets, you must specify the location in Amazon S3 where the prompt dataset is saved. *

* * @param datasetLocation * For custom prompt datasets, you must specify the location in Amazon S3 where the prompt dataset is saved. * @return Returns a reference to this object so that method calls can be chained together. */ public EvaluationDataset withDatasetLocation(EvaluationDatasetLocation datasetLocation) { setDatasetLocation(datasetLocation); return this; } /** * Returns a string representation of this object. This is useful for testing and debugging. Sensitive data will be * redacted from this string using a placeholder value. * * @return A string representation of this object. * * @see java.lang.Object#toString() */ @Override public String toString() { StringBuilder sb = new StringBuilder(); sb.append("{"); if (getName() != null) sb.append("Name: ").append("***Sensitive Data Redacted***").append(","); if (getDatasetLocation() != null) sb.append("DatasetLocation: ").append(getDatasetLocation()); sb.append("}"); return sb.toString(); } @Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (obj instanceof EvaluationDataset == false) return false; EvaluationDataset other = (EvaluationDataset) obj; if (other.getName() == null ^ this.getName() == null) return false; if (other.getName() != null && other.getName().equals(this.getName()) == false) return false; if (other.getDatasetLocation() == null ^ this.getDatasetLocation() == null) return false; if (other.getDatasetLocation() != null && other.getDatasetLocation().equals(this.getDatasetLocation()) == false) return false; return true; } @Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getName() == null) ? 0 : getName().hashCode()); hashCode = prime * hashCode + ((getDatasetLocation() == null) ? 0 : getDatasetLocation().hashCode()); return hashCode; } @Override public EvaluationDataset clone() { try { return (EvaluationDataset) super.clone(); } catch (CloneNotSupportedException e) { throw new IllegalStateException("Got a CloneNotSupportedException from Object.clone() " + "even though we're Cloneable!", e); } } @com.amazonaws.annotation.SdkInternalApi @Override public void marshall(ProtocolMarshaller protocolMarshaller) { com.amazonaws.services.bedrock.model.transform.EvaluationDatasetMarshaller.getInstance().marshall(this, protocolMarshaller); } }




© 2015 - 2025 Weber Informatics LLC | Privacy Policy