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