Sentiment Analysis
Zia Sentiment Analysisは、Text Analyticsの一部で、テキストコンテンツを処理してメッセージのトーンと、そこから伝わる感情を認識します。テキスト内の各文を分析して、そのトーンがpositive、negative、またはneutralのいずれであるかを判定します。次に、各文で認識された感情に基づいて、テキスト全体のトーンをこれら3つの感情のいずれかとして判定します。
レスポンスには、各文で検出された感情の信頼度スコアも返され、分析の精度が示されます。信頼度スコアは0から1の範囲です。全体的な分析の信頼度スコアも返されます。
1回のリクエストで最大1500文字のテキストブロックを入力として渡すことができます。入力テキストはgetSentimentAnalysis()に渡されます。
テキストに対してオプションのキーワードを渡すこともできます。これにより、Sentiment Analysisはそれらのキーワードを含む文のみを処理して、感情を判定します。他の文は無視されます。
以下で使用されているziaリファレンスは、 コンポーネントインスタンスページで定義されています。
copy
zia.getSentimentAnalysis(['Zoho Corporation, is an Indian multinational technology company that makes web-based business tools. It is best known for Zoho Office Suite. The company was founded by Sridhar Vembu and Tony Thomas and has a presence in seven locations with its global headquarters in Chennai, India, and corporate headquarters in Pleasanton, California.'], ['Zoho'])
//テキストとオプションのキーワードを渡して処理する
.then((result) => console.log(result))
.catch((error) => console.log(error.toString()));
受信するサンプルレスポンスを以下に示します。レスポンスはNode.jsの両方のバージョンで同じです。
Node js
copy
"sentiment_prediction": [
{
"document_sentiment": "Neutral",
"sentence_analytics": [
{
"sentence": "Zoho Corporation, is an Indian multinational technology company that makes web-based business tools.",
"sentiment": "Neutral",
"confidence_scores": {
"negative": 0,
"neutral": 1,
"positive": 0
}
},
{
"sentence": "It is best known for Zoho Office Suite.",
"sentiment": "Neutral",
"confidence_scores": {
"negative": 0,
"neutral": 0.6,
"positive": 0.4
}
},
{
"sentence": "The company was founded by Sridhar Vembu and Tony Thomas and has a presence in seven locations with its global headquarters in Chennai, India, and corporate headquarters in Pleasanton, California.",
"sentiment": "Neutral",
"confidence_scores": {
"negative": 0,
"neutral": 0.88,
"positive": 0.12
}
}
],
"overall_score": 0.83
}
]
最終更新日 2026-03-30 13:40:30 +0530 IST
Yes
No
Send your feedback to us
Skip
Submit