Interface SearchResponse.Summary.SafetyAttributesOrBuilder (0.20.0)

public static interface SearchResponse.Summary.SafetyAttributesOrBuilder extends MessageOrBuilder

Implements

MessageOrBuilder

Methods

getCategories(int index)

public abstract String getCategories(int index)

The display names of Safety Attribute categories associated with the generated content. Order matches the Scores.

repeated string categories = 1;

Parameter
NameDescription
indexint

The index of the element to return.

Returns
TypeDescription
String

The categories at the given index.

getCategoriesBytes(int index)

public abstract ByteString getCategoriesBytes(int index)

The display names of Safety Attribute categories associated with the generated content. Order matches the Scores.

repeated string categories = 1;

Parameter
NameDescription
indexint

The index of the value to return.

Returns
TypeDescription
ByteString

The bytes of the categories at the given index.

getCategoriesCount()

public abstract int getCategoriesCount()

The display names of Safety Attribute categories associated with the generated content. Order matches the Scores.

repeated string categories = 1;

Returns
TypeDescription
int

The count of categories.

getCategoriesList()

public abstract List<String> getCategoriesList()

The display names of Safety Attribute categories associated with the generated content. Order matches the Scores.

repeated string categories = 1;

Returns
TypeDescription
List<String>

A list containing the categories.

getScores(int index)

public abstract float getScores(int index)

The confidence scores of the each category, higher value means higher confidence. Order matches the Categories.

repeated float scores = 2;

Parameter
NameDescription
indexint

The index of the element to return.

Returns
TypeDescription
float

The scores at the given index.

getScoresCount()

public abstract int getScoresCount()

The confidence scores of the each category, higher value means higher confidence. Order matches the Categories.

repeated float scores = 2;

Returns
TypeDescription
int

The count of scores.

getScoresList()

public abstract List<Float> getScoresList()

The confidence scores of the each category, higher value means higher confidence. Order matches the Categories.

repeated float scores = 2;

Returns
TypeDescription
List<Float>

A list containing the scores.