natural-language

Tokenize, identify language, tag parts of speech, extract entities, assess sentiment, and produce embeddings on-device.

Updated Jun 5, 2026
One-click install
npx skills add https://github.com/harshav167/build-ios-apps --skill natural-language-harshav167
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: natural-language
Source: https://github.com/harshav167/build-ios-apps/tree/main/skills/natural-language
Command: npx skills add https://github.com/harshav167/build-ios-apps --skill natural-language-harshav167

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

Tokenize, tag, and analyze natural language text on-device using Apple's NaturalLanguage framework, enabling language identification, named entity recognition, part-of-speech tagging, sentiment analysis, and embeddings, while supporting in-app translation to other languages.

Core Features & Use Cases

  • Tokenization with NLTokenizer to segment text into words, sentences, or paragraphs.
  • Language identification and POS tagging using NLTagger and NLLanguageRecognizer.
  • Named Entity Recognition to extract people, places, and organizations.
  • Sentiment analysis and text embeddings for semantic understanding.
  • Translation between languages via the Translation framework, including programmatic and batch workflows.
  • Use cases include building language-aware UIs, search, localization, and on-device analytics.

Quick Start

Analyze a sample text by tokenizing, detecting language, tagging parts of speech and named entities, and translating to another language.

Frequently Asked Questions about natural-language

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I perform on-device sentiment analysis and named entity recognition in my app?▼

On-device sentiment analysis and named entity recognition use the NaturalLanguage framework to evaluate text polarity and extract people, places, or organizations locally, ensuring privacy and low latency.

Can I tokenize text into words and sentences locally using NaturalLanguage?▼

Yes, text tokenization uses NLTokenizer to segment text into words, sentences, or paragraphs directly on-device, enabling language-aware UIs and search without external dependencies.

What's the best way to identify text language and tag parts of speech on-device?▼

Language identification and POS tagging are handled by NLTagger and NLLanguageRecognizer to detect languages and assign grammatical categories on-device, requiring optional result handling and thread-safety checks.

Does the Translation framework support programmatic and batch translation workflows?▼

Yes, the Translation framework supports both programmatic and batch translation workflows across available languages, requiring LanguageAvailability checks to verify supported target translations.

How do I generate text embeddings for semantic understanding in iOS?▼

Text embeddings for semantic understanding are generated on-device using the NaturalLanguage framework, producing vector representations that capture meaning while maintaining privacy and low latency.

What limitations exist when checking language availability for translation?▼

Language availability checks via LanguageAvailability must be performed before translation to confirm target language support, as optional results and thread-safety constraints apply to on-device language analysis workflows.