Solutions · Text Analysis · Sentiment

Understand emotions behind every word.

Three specialized engines working together: SentimentAnalysis for polarity detection, EmotionDetection for nuanced feelings, and SarcasmDetection for ironic undertones. Run 100% on-device with 99.5% accuracy. Fine-tune with your domain data. Ship to production in hours.

99.5% accuracy 3 engines Fine-tunable
Engine

SentimentAnalysis

Positive / negative / neutral polarity.

Engine

EmotionDetection

Six primary emotions with scores.

Engine

SarcasmDetection

Catch ironic undertones.

Problem

Why sentiment analysis matters.

Every customer interaction generates unstructured text data. Reviews, support tickets, social mentions, survey responses. Without intelligent analysis, critical insights remain buried. Cloud APIs introduce latency, privacy concerns, and unpredictable costs.

01

Three-engine precision

Combine SentimentAnalysis, EmotionDetection, and SarcasmDetection for nuanced understanding that catches what others miss.

02

100% on-device privacy

All processing happens locally. No data leaves your infrastructure. Perfect for healthcare, finance, and regulated industries.

03

Fine-tune with your data

Generate LoRA adapters using your domain data. Custom models that understand your industry's unique language and context.

04

Dynamic Sampling technology

Our proprietary sampling delivers 99.5% accuracy even with smaller models running on CPU. Enterprise performance, edge deployment.

Three engines

Three engines, complete understanding.

Each engine specializes in a different dimension of text analysis. Use them individually or combine them for comprehensive emotional intelligence.

Engine 01

SentimentAnalysis

Classify text polarity with industry-leading accuracy. Enable NeutralSupport for three-way classification of objective content.

Engine 03

SarcasmDetection

Detect ironic and sarcastic undertones that would otherwise mislead analysis. Essential for social media and customer feedback.

Class detail

SentimentAnalysis class.

The foundation of emotional intelligence in your .NET applications. SentimentAnalysis delivers production-grade polarity detection with multilingual support, neutral classification, and fine-tuning capabilities. Powered by LM-Kit's Dynamic Sampling for maximum accuracy on any hardware.

  • NeutralSupport property enables three-way classification for objective content
  • GetSentimentCategory returns Positive, Negative, or Neutral
  • GetConfidenceScores returns probability distribution across categories
  • Multilingual support with automatic language detection
  • CreateTrainingObject for custom fine-tuning with LoRA adapters
  • Pre-built training datasets for rapid domain customization
SentimentAnalysis.cs
using LMKit.TextAnalysis;

var model = LM.LoadFromModelID("lmkit-sentiment-analysis");
var sentiment = new SentimentAnalysis(model) { NeutralSupport = true };

// Single classification
var result = sentiment.GetSentimentCategory(
    "This product exceeded all my expectations!");
Console.WriteLine($"Sentiment: {result}");
// Output: Positive

// Get detailed confidence scores
var scores = sentiment.GetConfidenceScores(text);
Class detail

EmotionDetection class.

Go beyond polarity to understand why content feels a certain way. EmotionDetection identifies six primary emotions based on Ekman's model: joy, anger, sadness, fear, surprise, and disgust. Essential for nuanced customer experience analysis and mental health applications.

  • GetEmotionCategory returns the primary emotion detected
  • GetEmotionScores returns confidence for all six emotions
  • Distinguish angry customers from disappointed ones for better routing
  • Detect fear and surprise for crisis detection in social media
  • Fine-tune with domain-specific emotional expressions
EmotionDetection.cs
using LMKit.TextAnalysis;

var model = LM.LoadFromModelID("qwen3.5:4b");
var emotions = new EmotionDetection(model);

// Detect primary emotion
var emotion = emotions.GetEmotionCategory(
    "I can't believe they cancelled my order!");
Console.WriteLine($"Emotion: {emotion}");
// Output: Anger

// Get full emotion distribution
var scores = emotions.GetEmotionScores(
    "The news left me speechless");
Class detail

SarcasmDetection class.

The missing piece in sentiment analysis. SarcasmDetection identifies ironic undertones that would otherwise mislead polarity classifiers. "Oh great, another meeting" reads as positive to basic sentiment analysis but negative to humans. Sarcasm detection bridges that gap.

  • IsSarcastic returns boolean detection result
  • GetSarcasmScore returns confidence level (0.0 to 1.0)
  • Essential for social media monitoring where sarcasm is prevalent
  • Combine with SentimentAnalysis to adjust polarity based on irony
  • Fine-tune for platform-specific sarcasm patterns (Twitter, Reddit, etc.)
SarcasmDetection.cs
using LMKit.TextAnalysis;

var model = LM.LoadFromModelID("qwen3.5:4b");
var sarcasm = new SarcasmDetection(model);

// Quick boolean check
bool isSarcastic = sarcasm.IsSarcastic(
    "Oh wonderful, another Monday morning meeting.");
Console.WriteLine($"Sarcastic: {isSarcastic}");
// Output: Sarcastic: True

// Get confidence score
float score = sarcasm.GetSarcasmScore(
    "Best customer service ever");
Customization

Fine-tune with your data.

Generic models struggle with industry-specific language. Medical sentiment differs from e-commerce. Financial news has unique emotional signals. LM-Kit's fine-tuning system lets you generate custom LoRA adapters that understand your domain's unique vocabulary and context.

  • CreateTrainingObject method on all sentiment classes
  • Generate LoRA adapters for efficient, targeted model updates
  • Pre-built training datasets for common domains: e-commerce, support, social
  • Train on-device without sending data to external services
  • Hot-swap adapters without reloading the base model

Domain

E-commerce reviews

Train on product reviews with star ratings. Understand "runs small" as negative for clothing, neutral for equipment.

Domain

Customer support

Learn your ticket language. Recognize urgency signals, escalation indicators, and resolution satisfaction.

Domain

Financial news

Interpret market sentiment from earnings calls, analyst reports, and news. "Beat expectations" vs. "met expectations."

Domain

Healthcare feedback

Understand patient sentiment with medical terminology. Detect emotional distress signals in clinical notes.

Performance

Benchmark results.

Industry-leading accuracy powered by Dynamic Sampling technology. Tested on standard sentiment analysis benchmarks.

99.5%

Classification accuracy

<50ms

Average inference time

75%

Error reduction vs. baseline

2x

Faster than cloud APIs

Benchmarked on SST-2, IMDB, and Yelp datasets. Results with lm-kit-sentiment-analysis-2.0-1b model. View full benchmark methodology

Applications

Real-world use cases.

Organizations across industries leverage LM-Kit's sentiment engines to automate workflows, detect issues early, and understand their customers.

Support

Customer support triage

Route angry customers to senior agents. Detect frustration early in conversations. Prioritize tickets by emotional urgency, not just keywords.

Social

Social media monitoring

Track brand sentiment in real-time. Detect emerging crises before they go viral. Identify sarcastic mentions that skew sentiment metrics.

Reviews

Review analysis

Extract actionable insights from product reviews. Understand what drives positive vs. negative feedback. Identify feature requests hidden in complaints.

VOC

Voice of customer

Aggregate sentiment across all channels: email, chat, surveys, calls. Build unified dashboards showing customer happiness trends over time.

Research

Market research

Analyze competitor sentiment. Track public opinion on industry topics. Measure campaign effectiveness through emotional response.

HR

Employee engagement

Analyze internal survey responses. Detect morale issues in team communications. Track sentiment changes after organizational changes.

Integration

Integrate in minutes.

From NuGet install to production sentiment analysis in under 10 minutes. No cloud keys, no API limits, no surprises.

Quick start

  1. Install via NuGet: dotnet add package LMKit.NET
  2. Load a model: LM.LoadFromModelID("lmkit-sentiment-analysis")
  3. Create analyzer: new SentimentAnalysis(model)
  4. Analyze text: sentiment.GetSentimentCategory(text)
Developer Resources

API reference.

Complete documentation for all sentiment analysis classes, methods, and properties.

SentimentAnalysis

Core sentiment classification with positive, negative, and optional neutral categories. Includes confidence scores and fine-tuning support.

View docs

EmotionDetection

Six-emotion classification: joy, anger, sadness, fear, surprise, disgust. Full probability distribution for multi-emotion analysis.

View docs

SarcasmDetection

Binary sarcasm classification with confidence scores. Essential for accurate social media and review sentiment analysis.

View docs

SentimentCategory

Enumeration of sentiment categories: Positive, Negative, Neutral. Returned by GetSentimentCategory method.

View docs

EmotionCategory

Enumeration of emotion categories: Joy, Anger, Sadness, Fear, Surprise, Disgust. Based on Ekman's emotion model.

View docs

TrainingObject

Object for creating fine-tuning datasets. Used with CreateTrainingObject to generate LoRA adapters for custom models.

View docs

Ready to understand your customers?

Three powerful engines. 99.5% accuracy. 100% on-device privacy. Fine-tunable with your data. Start building intelligent .NET applications today.

Download free API documentation