Struct Response::SentenceQualityScore

Nested Relationships

This struct is a nested type of Struct Response.

Struct Documentation

struct SentenceQualityScore

SentenceQualityScore contains the quality data of a given translated sentence.

It includes the confidence (proxied by log probabilities) of each decoded word (higher logprobs imply better-translated words), the ByteRanges of each term, and logprobs of the whole sentence, represented as the mean word scores.

Public Members

std::vector<float> wordScores

Quality score of each translated word.

std::vector<SubwordRange> wordRanges

Position of start and end token of each word in the translated text.

float sentenceScore = 0.0

Whole sentence quality score (it is composed by the mean of its words)