Zubnet AI學習Wiki › Sentiment Analysis
Using AI

Sentiment Analysis

Opinion Mining
自動判斷一段文字的情感傾向 — 正面、負面、或中性。「這個產品太棒了!」是正面。「糟糕的客戶服務」是負面。超出簡單極性,高級情感分析偵測具體情緒(憤怒、喜悅、挫敗)、方面級情感(「食物很棒,但服務很慢」)、以及諷刺。

為什麼重要

情感分析是商業部署最廣泛的 NLP 應用之一。公司用它監測社群媒體上的品牌形象、規模化分析客戶評論、在問卷中衡量員工滿意度、偵測正在出現的 PR 危機。它也是學習 NLP 的常見入門 — 一個簡單、直觀的分類任務,訓練資料豐富。

Deep Dive

Traditional sentiment analysis used feature-engineered classifiers (bag-of-words + logistic regression, lexicon-based approaches). These worked for simple cases but failed on sarcasm ("Oh great, another delay"), implicit sentiment ("The battery lasted two hours"), and domain-specific language. Modern approaches use fine-tuned BERT or LLM-based classification, which handle these nuances much better by understanding context.

Aspect-Based Sentiment

Real reviews often contain mixed sentiment: "The camera is excellent but the battery is disappointing." Aspect-based sentiment analysis identifies the aspects (camera, battery) and assigns sentiment to each independently. This is more useful for product teams than overall sentiment because it pinpoints what specifically needs improvement. Modern LLMs handle this naturally through structured output — "extract aspects and their sentiments from this review."

LLMs vs. Dedicated Models

For sentiment analysis, you have three options: (1) a fine-tuned small model (fast, cheap, good for high-volume), (2) a zero-shot LLM prompt (flexible, handles edge cases, more expensive), or (3) an API service (Google NLP, AWS Comprehend). For most new projects, starting with an LLM prompt and switching to a fine-tuned model when volume justifies it is the practical approach.

相關概念

← 所有術語
ESC