
Description
Analyze text content and produce statistics including word count, line count, character count, most frequent words, and readability metrics. Works on any plain text input provided inline or from a file path.
SKILL.md
Text Analyzer
Analyze text and produce structured statistics.
Purpose
Provide quick text analytics — word counts, line counts, character counts, top frequent words, average word length, and sentence count — for any plain-text input.
Agent Instructions
- Read this SKILL.md to understand capabilities.
- Run
scripts/analyze_text.pywith the appropriate arguments. - Return the analysis results to the user.
Examples
Usage
# Analyze inline text
python scripts/analyze_text.py --text "Your text content here"
# Analyze a file
python scripts/analyze_text.py --file /path/to/file.txt
# JSON output (default is human-readable)
python scripts/analyze_text.py --text "Hello world" --json
Output
The script prints a structured report with:
- Word count — total words
- Line count — total lines
- Character count — total characters (including whitespace)
- Sentence count — estimated sentence count
- Average word length — mean characters per word
- Top 5 words — most frequent words and their counts
Limitations
- Sentence detection uses simple period/question/exclamation splitting; may be inaccurate for abbreviations (e.g., "U.S.A.").
- Non-UTF-8 files will be read with errors replaced.
Troubleshooting
| Problem | Fix |
|---|---|
FileNotFoundError | Check the --file path exists |
| Empty output | Ensure --text or --file is provided |
More skills from the SkillEvaluator repository
View all 5 skillsapi-caller
execute dynamic REST API calls
Aug 31API DevelopmentAutomationREST APIcalculator
evaluate mathematical expressions and unit conversions
Aug 31AnalysisMathematicscreate-custom-grader
create custom SkillEvaluator graders
Aug 31EvalsNVIDIATestingtask-list
manage multi-step task lists
Aug 31NVIDIAProductivityTask Management
More from NVIDIA
View publishernemoclaw-user-guide
retrieve NemoClaw documentation and configuration
NemoClaw
Aug 25DocumentationMCPSearchmcore-build-and-dependency
manage Megatron-LM development environments
Megatron-LM
Jul 27ContainersDeploymentPythonmcore-bump-base-image
update NVIDIA PyTorch base images
Megatron-LM
Jul 14CI/CDDeploymentmcore-cicd
manage CI/CD pipelines for Megatron-LM
Megatron-LM
Aug 28CI/CDDeploymentGitHubmcore-create-issue
investigate CI failures and create issues
Megatron-LM
Jul 14DebuggingGitHubTriagemcore-linting-and-formatting
lint and format Megatron-LM code
Megatron-LM
Jul 14Best PracticesCode Analysis