UNPKG

geneea-nlp-client

Version:

The TypeScript Client for Geneea Interpretor G3 API.

25 lines (24 loc) 801 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.Sentiment = void 0; const common_1 = require("../../common/common"); /** Class encapsulating sentiment of a document, sentence or relation. */ class Sentiment { /** * * @param mean Average sentiment. * @param label Human readable label describing the average sentiment. * @param positive Average sentiment of positive items. * @param negative Average sentiment of negative items. */ constructor(mean, label, positive, negative) { this.mean = mean; this.label = label; this.positive = positive; this.negative = negative; } toString() { return (0, common_1.objToStr)(this, Object.keys(this)); } } exports.Sentiment = Sentiment;