Multimodal content analysis for .NET.
Extract meaning from text and images with six specialized engines: sentiment analysis, custom classification, keyword extraction, named entity recognition, PII detection, and semantic embeddings. Fine-tune with your data. Run 100% on-device with Dynamic Sampling for maximum accuracy on any hardware.
Custom classification
Keyword extraction
Named entity recognition
PII extraction
Text & image embeddings
Complete text intelligence toolkit.
Six specialized engines working together to extract meaning, detect patterns, and transform unstructured content into actionable insights.
Multimodal
Multimodal processing
Analyze both text and images with unified APIs. Automatic OCR integration extracts content from scanned documents, screenshots, and photos.
Sampling
Dynamic Sampling
LM-Kit's innovative sampling technology delivers up to 75% error reduction and 2x faster processing, even with smaller models on CPU.
Custom
Fine-tunable models
Every analysis engine includes CreateTrainingObject methods for custom fine-tuning. Generate LoRA adapters tailored to your domain and data.
Sentiment & emotion analysis.
Understand the emotional tone behind any content with three specialized engines. SentimentAnalysis classifies text as positive, negative, or neutral with up to 99.5% accuracy. EmotionDetection identifies specific emotions: joy, anger, sadness, fear, surprise, and disgust. SarcasmDetection captures ironic tones that might otherwise mislead analysis. Visit our dedicated Sentiment Analysis page for detailed implementation guidance and advanced use cases.
- Multilingual support with no configuration required
- Neutral sentiment support for objective content
- Fine-tune with your domain data via LoRA adapters
- Pre-built training datasets for rapid customization
- Confidence scores for every classification
var model = LM.LoadFromModelID("lmkit-sentiment-analysis"); var sentiment = new SentimentAnalysis(model) { NeutralSupport = true }; // Analyze sentiment var result = sentiment.GetSentimentCategory("The product exceeded all expectations!"); Console.WriteLine($"Sentiment: {result}"); // Output: Positive // Detect specific emotions var emotions = new EmotionDetection(model);
Custom text & image classification.
Build classification engines tailored to your exact requirements with the Categorization class. Define any number of categories with optional descriptions, then classify text or images with lightning-fast inference and confidence scores. Works with both text input and multimodal attachments. Visit our dedicated Content Classification page for detailed implementation guidance and advanced use cases.
- Define unlimited custom categories
- Multimodal: classify both text and images
GetBestCategoryfor single result,GetTopCategoriesfor ranked listGuidanceproperty for custom classification instructionsHandleUnknownCategoryfor out-of-scope inputs
var model = LM.LoadFromModelID("qwen3.5:4b"); var classifier = new Categorization(model); // Define your categories var categories = new[] { "Technical Support", "Billing Inquiry", "Feature Request", "General Feedback" }; // Classify incoming text int result = classifier.GetBestCategory( categories, "My payment didn't go through"); Console.WriteLine(categories[result]); // Output: Billing Inquiry
Keyword extraction.
Surface the most relevant terms and phrases from any content with the KeywordExtraction engine. Configure the number of keywords to extract, handle large documents with TextShrinkingStrategy, and optionally specify a target language for multilingual content. Works with both text and image attachments. Visit our dedicated Keyword Extraction page for detailed implementation guidance and advanced use cases.
- Configurable keyword count with
KeywordCountproperty TextShrinkingStrategyfor handling large documentsTargetLanguagefor multilingual keyword extraction- Extract from images with multimodal support
- Dynamic Sampling for high accuracy with small models
var model = LM.LoadFromModelID("qwen3.5:4b"); var extractor = new KeywordExtraction(model) { KeywordCount = 8, TargetLanguage = "English" }; string article = File.ReadAllText("article.txt"); var keywords = extractor.ExtractKeywords(article); foreach (var kw in keywords) { Console.WriteLine($"- {kw.Value}"); } // Extract from image var attachment = new Attachment("infographic.png");
Named entity recognition (NER).
Extract structured information from unstructured content with the NamedEntityRecognition engine. Identify people, organizations, locations, dates, and any custom entity types you define. Each extracted entity includes occurrence positions, enabling precise highlighting or redaction in source documents. Visit our dedicated NER page for detailed implementation guidance and advanced use cases.
- Built-in entity types: Person, Organization, Location, Date, Money, Percent
- Define custom entity types with
EntityDefinition Occurrencesproperty with character offsets for each mention- Multimodal: extract entities from images with OCR
Guidanceproperty for domain-specific extraction rules
var model = LM.LoadFromModelID("qwen3.5:4b"); var ner = new NamedEntityRecognition(model); // Define entity types to extract ner.EntityDefinitions.Add(new EntityDefinition(NamedEntityType.Person)); ner.EntityDefinitions.Add(new EntityDefinition(NamedEntityType.Organization)); ner.EntityDefinitions.Add(new EntityDefinition( "Product", "Product names mentioned")); string text = "...";
PII extraction.
Detect and extract personally identifiable information for privacy compliance, data masking, and audit workflows with the PiiExtraction engine. Supports built-in PII types plus unlimited custom labels for organization-specific identifiers. Works on both text and images with integrated OCR. Visit our dedicated PII Detection page for in-depth guidance on implementing privacy-compliant workflows.
- Built-in types: Name, Email, Phone, Address, SSN, DateOfBirth, URL, IP
- Define custom PII labels: PatientID, AccountNumber, PassportNumber
- Character offsets for precise masking and redaction
- Batch processing for high-volume document scanning
- Multimodal: extract from scanned documents and screenshots
var model = LM.LoadFromModelID("qwen3.5:4b"); var pii = new PiiExtraction(model); // Configure PII types to detect pii.PiiTypes.Add(PiiEntityType.Name); pii.PiiTypes.Add(PiiEntityType.Email); pii.PiiTypes.Add(PiiEntityType.Phone); pii.PiiTypes.Add(PiiEntityType.SSN); // Add custom PII type pii.CustomLabels.Add("PatientID"); string text = "Contact Jane Doe at [email protected]";
Text & image embeddings.
Generate dense vector representations that capture semantic meaning with the Embedder class. Power semantic search, clustering, recommendations, and RAG pipelines with high-quality embeddings from both text and images. Supports batch processing and multiple embedding models optimized for different use cases.
- Text embeddings with models like
nomic-embed-text,bge-m3 - Image embeddings with
nomic-embed-vision - Batch processing with
GetEmbeddingsAsyncfor multiple inputs GetCosineSimilarityfor measuring semantic similarity- Seamless integration with RAG engine and vector stores
var model = LM.LoadFromModelID("nomic-embed-text"); var embedder = new Embedder(model); // Generate text embeddings float[] queryVec = await embedder.GetEmbeddingsAsync( "machine learning algorithms"); // Batch embed multiple texts var docs = new[] { "AI overview", "Neural networks" }; float[][] docVecs = await embedder.GetEmbeddingsAsync(docs); // Calculate similarity float sim = Embedder.GetCosineSimilarity(queryVec, docVecs[0]);
Real-world use cases.
Organizations across industries leverage LM-Kit's content analysis to automate workflows, ensure compliance, and unlock insights.
Support
Customer support triage
Classify incoming tickets by sentiment and category, route to appropriate teams, and extract key entities for faster resolution.
Privacy
Privacy compliance
Scan documents for PII before sharing or archiving. Automate GDPR, CCPA, and HIPAA compliance workflows with precise detection.
Documents
Document intelligence
Extract entities from contracts, invoices, and forms. Classify document types and route to appropriate processing pipelines.
Social
Social media monitoring
Track brand sentiment across platforms. Detect emerging issues, measure campaign impact, and identify influencer content.
Search
Semantic search
Build intelligent search with embeddings that understand meaning, not just keywords. Find similar content across documents and images.
Moderation
Content moderation
Automatically classify user-generated content. Detect toxic language, spam, and policy violations before publication.
API reference.
Complete documentation for all content analysis classes and methods.
SentimentAnalysis
Classify text sentiment as positive, negative, or neutral with multilingual support and fine-tuning capabilities.
EmotionDetection
Identify specific emotions: joy, anger, sadness, fear, surprise, and disgust with optional neutral support.
Categorization
Custom classification with unlimited categories. Supports text and image inputs with confidence scores.
KeywordExtraction
Extract key terms and phrases with configurable count and language targeting.
NamedEntityRecognition
Extract people, organizations, locations, dates, and custom entity types with occurrence tracking.
PiiExtraction
Detect PII including names, emails, SSNs, and custom identifiers for compliance workflows.
SarcasmDetection
Detect ironic and sarcastic tones that might mislead sentiment analysis.
Embedder
Generate semantic embeddings from text and images for search, clustering, and RAG applications.
Reranker
Rerank search results by semantic relevance for improved RAG accuracy.
Build it. Read it. Try it.
Working console demos on GitHub, step-by-step how-to guides on the docs site, and the API reference for the classes used on this page.
Sentiment analysis
Console demo: classify text as positive, negative, or neutral with confidence.
Open on GitHub → DemoNamed entity recognition
Console demo: extract names, places, organizations, dates from text.
Open on GitHub → DemoBatch PII extraction
Console demo: high-throughput PII detection across many documents.
Open on GitHub → API referenceLMKit.TextAnalysis
Namespace landing for every text-analysis engine.
Open the reference →Seven pillars, one foundation.
The seven pillars of LM-Kit.NET, plus the local runtime they share. Highlighted card is where you are now.
01 · AI Agents
Orchestration patterns
ReAct planning, supervisors, parallel and pipeline orchestrators, persistent memory, MCP clients, custom tools.
AI Agents02 · Document Intelligence
Parse PDFs, images, EML
PDF text and table extraction, on-device OCR reaching SOTA benchmark scores, structured field extraction with grammar-constrained generation.
Document Intelligence03 · Vision & Multimodal
VLMs, image classification, chat with image
Image understanding, classification, labeling, multimodal chat, image embeddings, VLM-OCR, background removal. Same conversation surface as LLMs.
Vision & Multimodal04 · RAG & Knowledge
Vector search and retrieval
Built-in vector store, Qdrant connector, embeddings, hybrid retrieval, document chunking, source citations.
RAG & Knowledge05 · Text Analysis
Classification, NER, PII, sentiment
Built-in classifiers and an extractor that emits typed C# objects via grammar-constrained sampling. Sentiment, keywords, language detection.
You are here06 · Speech & Audio
Audio transcription, STT
A growing local speech-to-text stack: hallucination suppression, Voice Activity Detection, real-time translation, streaming output, 100+ languages.
Speech & Audio07 · Text Generation
Conversations, rewriting, summaries
Single-turn, multi-turn, and stateless conversation primitives. Translate, correct, rewrite, summarise. Prompt templates, streaming, grammar-constrained outputs.
Text GenerationThe foundation
Every capability above runs on this runtime.
Foundation
Local Inference
The runtime all seven pillars sit on. The LM-Kit.NET NuGet ships the complete inference system: open-weight LLMs, vision-language models, embeddings, on-device speech-to-text, OCR and classifiers, accelerated on CPU, AVX2, CUDA 12/13, Vulkan or Metal. One package, zero cloud calls, predictable latency, full data and technology sovereignty.
Ready to analyze your content?
Six powerful engines. Multimodal support. 100% on-device. Start building intelligent .NET applications today.