or / README.md
omarkamali's picture
Upload all models and assets for or (latest)
09021ed verified
|
Raw
History Blame Contribute Delete
37.5 kB
---
language: or
language_name: Odia
language_family: indoaryan_eastern
tags:
- wikilangs
- nlp
- tokenizer
- embeddings
- n-gram
- markov
- wikipedia
- feature-extraction
- sentence-similarity
- tokenization
- n-grams
- markov-chain
- text-mining
- fasttext
- babelvec
- vocabulous
- vocabulary
- monolingual
- family-indoaryan_eastern
license: mit
library_name: wikilangs
pipeline_tag: text-generation
datasets:
- omarkamali/wikipedia-monthly
dataset_info:
name: wikipedia-monthly
description: Monthly snapshots of Wikipedia articles across 300+ languages
metrics:
- name: best_compression_ratio
type: compression
value: 4.964
- name: best_isotropy
type: isotropy
value: 0.8415
- name: vocabulary_size
type: vocab
value: 0
generated: 2026-01-10
---
# Odia - Wikilangs Models
## Comprehensive Research Report & Full Ablation Study
This repository contains NLP models trained and evaluated by Wikilangs, specifically on **Odia** Wikipedia data.
We analyze tokenizers, n-gram models, Markov chains, vocabulary statistics, and word embeddings.
## 📋 Repository Contents
### Models & Assets
- Tokenizers (8k, 16k, 32k, 64k)
- N-gram models (2, 3, 4, 5-gram)
- Markov chains (context of 1, 2, 3, 4 and 5)
- Subword N-gram and Markov chains
- Embeddings in various sizes and dimensions (aligned and unaligned)
- Language Vocabulary
- Language Statistics
![Performance Dashboard](visualizations/performance_dashboard.png)
### Analysis and Evaluation
- [1. Tokenizer Evaluation](#1-tokenizer-evaluation)
- [2. N-gram Model Evaluation](#2-n-gram-model-evaluation)
- [3. Markov Chain Evaluation](#3-markov-chain-evaluation)
- [4. Vocabulary Analysis](#4-vocabulary-analysis)
- [5. Word Embeddings Evaluation](#5-word-embeddings-evaluation)
- [6. Morphological Analysis (Experimental)](#6--morphological-analysis-experimental)
- [7. Summary & Recommendations](#7-summary--recommendations)
- [Metrics Glossary](#appendix-metrics-glossary--interpretation-guide)
- [Visualizations Index](#visualizations-index)
---
## 1. Tokenizer Evaluation
![Tokenizer Compression](visualizations/tokenizer_compression.png)
![Tokenizer Fertility](visualizations/tokenizer_fertility.png)
![Tokenizer OOV](visualizations/tokenizer_oov.png)
![Total Tokens](visualizations/tokenizer_total_tokens.png)
### Results
| Vocab Size | Compression | Avg Token Len | UNK Rate | Total Tokens |
|------------|-------------|---------------|----------|--------------|
| **8k** | 3.812x | 3.81 | 0.1748% | 431,339 |
| **16k** | 4.280x | 4.28 | 0.1962% | 384,250 |
| **32k** | 4.668x | 4.67 | 0.2140% | 352,257 |
| **64k** | 4.964x 🏆 | 4.97 | 0.2276% | 331,277 |
### Tokenization Examples
Below are sample sentences tokenized with each vocabulary size:
**Sample 1:** `ଘଟଣାବଳୀ ଜନ୍ମ କଳ୍ପନା ଦାଶ, ପର୍ବତାରୋହୀ ମୃତ୍ୟୁ ପର୍ବପର୍ବାଣି ବାହାର ଲିଙ୍କ BBC: ଏହି ଦିନ ...`
| Vocab | Tokens | Count |
|-------|--------|-------|
| 8k | `▁ଘଟଣାବଳୀ ▁ଜନ୍ମ ▁କଳ୍ପନା ▁ଦାଶ , ▁ପର୍ବ ତାର ୋ ହୀ ▁ମୃତ୍ୟୁ ... (+13 more)` | 23 |
| 16k | `▁ଘଟଣାବଳୀ ▁ଜନ୍ମ ▁କଳ୍ପନା ▁ଦାଶ , ▁ପର୍ବ ତାର ୋ ହୀ ▁ମୃତ୍ୟୁ ... (+13 more)` | 23 |
| 32k | `▁ଘଟଣାବଳୀ ▁ଜନ୍ମ ▁କଳ୍ପନା ▁ଦାଶ , ▁ପର୍ବତାର ୋହୀ ▁ମୃତ୍ୟୁ ▁ପର୍ବପର୍ବାଣି ▁ବାହାର ... (+11 more)` | 21 |
| 64k | `▁ଘଟଣାବଳୀ ▁ଜନ୍ମ ▁କଳ୍ପନା ▁ଦାଶ , ▁ପର୍ବତାରୋହୀ ▁ମୃତ୍ୟୁ ▁ପର୍ବପର୍ବାଣି ▁ବାହାର ▁ଲିଙ୍କ ... (+10 more)` | 20 |
**Sample 2:** `ଘଟଣାବଳୀ ଜନ୍ମ ଦେହାନ୍ତ ପର୍ବପର୍ବାଣି ବାହାର ଲିଙ୍କ BBC: ଏହି ଦିନ କାନାଡାରେ ଏହି ଦିନ ତିଆରି...`
| Vocab | Tokens | Count |
|-------|--------|-------|
| 8k | `▁ଘଟଣାବଳୀ ▁ଜନ୍ମ ▁ଦେହାନ୍ତ ▁ପର୍ବପର୍ବାଣି ▁ବାହାର ▁ଲିଙ୍କ ▁bbc : ▁ଏହି ▁ଦିନ ... (+6 more)` | 16 |
| 16k | `▁ଘଟଣାବଳୀ ▁ଜନ୍ମ ▁ଦେହାନ୍ତ ▁ପର୍ବପର୍ବାଣି ▁ବାହାର ▁ଲିଙ୍କ ▁bbc : ▁ଏହି ▁ଦିନ ... (+6 more)` | 16 |
| 32k | `▁ଘଟଣାବଳୀ ▁ଜନ୍ମ ▁ଦେହାନ୍ତ ▁ପର୍ବପର୍ବାଣି ▁ବାହାର ▁ଲିଙ୍କ ▁bbc : ▁ଏହି ▁ଦିନ ... (+6 more)` | 16 |
| 64k | `▁ଘଟଣାବଳୀ ▁ଜନ୍ମ ▁ଦେହାନ୍ତ ▁ପର୍ବପର୍ବାଣି ▁ବାହାର ▁ଲିଙ୍କ ▁bbc : ▁ଏହି ▁ଦିନ ... (+6 more)` | 16 |
**Sample 3:** `ଆମଷ୍ଟରଡ଼ମ, ନେଦରଲାଣ୍ଡର ରାଜଧାନୀ । ଭୂଗୋଳ ଇତିହାସ ପର୍ଯ୍ୟଟନ ଆଧାର ବାହାର ତଥ୍ୟ ସହର`
| Vocab | Tokens | Count |
|-------|--------|-------|
| 8k | `▁ଆମ ଷ୍ଟର ଡ଼ ମ , ▁ନେ ଦର ଲା ଣ୍ଡର ▁ରାଜଧାନୀ ... (+8 more)` | 18 |
| 16k | `▁ଆମ ଷ୍ଟର ଡ଼ ମ , ▁ନେ ଦର ଲାଣ୍ଡର ▁ରାଜଧାନୀ ▁। ... (+7 more)` | 17 |
| 32k | `▁ଆମ ଷ୍ଟର ଡ଼ ମ , ▁ନେଦର ଲାଣ୍ଡର ▁ରାଜଧାନୀ ▁। ▁ଭୂଗୋଳ ... (+6 more)` | 16 |
| 64k | `▁ଆମ ଷ୍ଟର ଡ଼ମ , ▁ନେଦର ଲାଣ୍ଡର ▁ରାଜଧାନୀ ▁। ▁ଭୂଗୋଳ ▁ଇତିହାସ ... (+5 more)` | 15 |
### Key Findings
- **Best Compression:** 64k achieves 4.964x compression
- **Lowest UNK Rate:** 8k with 0.1748% unknown tokens
- **Trade-off:** Larger vocabularies improve compression but increase model size
- **Recommendation:** 32k vocabulary provides optimal balance for production use
---
## 2. N-gram Model Evaluation
![N-gram Perplexity](visualizations/ngram_perplexity.png)
![N-gram Unique](visualizations/ngram_unique.png)
![N-gram Coverage](visualizations/ngram_coverage.png)
### Results
| N-gram | Variant | Perplexity | Entropy | Unique N-grams | Top-100 Coverage | Top-1000 Coverage |
|--------|---------|------------|---------|----------------|------------------|-------------------|
| **2-gram** | Word | 29,849 | 14.87 | 100,627 | 11.3% | 29.3% |
| **2-gram** | Subword | 2,236 🏆 | 11.13 | 49,387 | 34.1% | 70.8% |
| **3-gram** | Word | 24,001 | 14.55 | 101,801 | 15.3% | 35.2% |
| **3-gram** | Subword | 18,474 | 14.17 | 248,330 | 13.5% | 36.9% |
| **4-gram** | Word | 38,336 | 15.23 | 175,673 | 15.6% | 32.6% |
| **4-gram** | Subword | 86,597 | 16.40 | 939,792 | 8.5% | 23.8% |
| **5-gram** | Word | 26,841 | 14.71 | 131,848 | 18.5% | 36.0% |
| **5-gram** | Subword | 206,339 | 17.65 | 1,508,952 | 6.0% | 17.6% |
### Top 5 N-grams by Size
**2-grams (Word):**
| Rank | N-gram | Count |
|------|--------|-------|
| 1 | `ଓଡ଼ିଶା ବିଧାନ` | 9,207 |
| 2 | `ସେପ୍ଟେମ୍ବର ଅକ୍ଟୋବର` | 5,589 |
| 3 | `ଅକ୍ଟୋବର ଡିସେମ୍ବର` | 5,588 |
| 4 | `ଜାନୁଆରୀ ମାର୍ଚ୍ଚ` | 5,585 |
| 5 | `ଜୁଲାଇ ସେପ୍ଟେମ୍ବର` | 5,585 |
**3-grams (Word):**
| Rank | N-gram | Count |
|------|--------|-------|
| 1 | `ଜୁଲାଇ ସେପ୍ଟେମ୍ବର ଅକ୍ଟୋବର` | 5,580 |
| 2 | `ସେପ୍ଟେମ୍ବର ଅକ୍ଟୋବର ଡିସେମ୍ବର` | 5,580 |
| 3 | `ଜୁନ ଜୁଲାଇ ସେପ୍ଟେମ୍ବର` | 5,578 |
| 4 | `ଜାନୁଆରୀ ମାର୍ଚ୍ଚ ଅପ୍ରେଲ` | 5,575 |
| 5 | `ଅପ୍ରେଲ ଜୁନ ଜୁଲାଇ` | 5,575 |
**4-grams (Word):**
| Rank | N-gram | Count |
|------|--------|-------|
| 1 | `ଜୁଲାଇ ସେପ୍ଟେମ୍ବର ଅକ୍ଟୋବର ଡିସେମ୍ବର` | 5,580 |
| 2 | `ଅପ୍ରେଲ ଜୁନ ଜୁଲାଇ ସେପ୍ଟେମ୍ବର` | 5,575 |
| 3 | `ଜୁନ ଜୁଲାଇ ସେପ୍ଟେମ୍ବର ଅକ୍ଟୋବର` | 5,575 |
| 4 | `ଜାନୁଆରୀ ମାର୍ଚ୍ଚ ଅପ୍ରେଲ ଜୁନ` | 5,574 |
| 5 | `ମାର୍ଚ୍ଚ ଅପ୍ରେଲ ଜୁନ ଜୁଲାଇ` | 5,571 |
**5-grams (Word):**
| Rank | N-gram | Count |
|------|--------|-------|
| 1 | `ଜୁନ ଜୁଲାଇ ସେପ୍ଟେମ୍ବର ଅକ୍ଟୋବର ଡିସେମ୍ବର` | 5,575 |
| 2 | `ଅପ୍ରେଲ ଜୁନ ଜୁଲାଇ ସେପ୍ଟେମ୍ବର ଅକ୍ଟୋବର` | 5,572 |
| 3 | `ମାର୍ଚ୍ଚ ଅପ୍ରେଲ ଜୁନ ଜୁଲାଇ ସେପ୍ଟେମ୍ବର` | 5,571 |
| 4 | `ଜାନୁଆରୀ ମାର୍ଚ୍ଚ ଅପ୍ରେଲ ଜୁନ ଜୁଲାଇ` | 5,571 |
| 5 | `ଓଡ଼ିଶା ବିଧାନ ସଭାରେ ଜଣେ ବିଧାୟକ` | 1,965 |
**2-grams (Subword):**
| Rank | N-gram | Count |
|------|--------|-------|
| 1 | `ର _` | 374,450 |
| 2 | `ରେ _` | 325,653 |
| 3 | `। _` | 280,176 |
| 4 | `_ ।` | 264,038 |
| 5 | `_ କ` | 222,101 |
**3-grams (Subword):**
| Rank | N-gram | Count |
|------|--------|-------|
| 1 | `_ । _` | 256,912 |
| 2 | `_ କ ରି` | 90,546 |
| 3 | `ଥି ଲେ _` | 77,030 |
| 4 | `_ ଓ _` | 75,329 |
| 5 | `ଲେ _ ।` | 66,216 |
**4-grams (Subword):**
| Rank | N-gram | Count |
|------|--------|-------|
| 1 | `ଲେ _ । _` | 64,694 |
| 2 | `ଥି ଲେ _ ।` | 58,856 |
| 3 | `_ ଏ ହି _` | 44,903 |
| 4 | `_ କ ରି ଥି` | 43,331 |
| 5 | `_ । _ ଏ` | 42,881 |
**5-grams (Subword):**
| Rank | N-gram | Count |
|------|--------|-------|
| 1 | `ଥି ଲେ _ । _` | 57,518 |
| 2 | `_ କ ରି ଥି ଲେ` | 36,616 |
| 3 | `କ ରି ଥି ଲେ _` | 33,661 |
| 4 | `ରି ଥି ଲେ _ ।` | 28,715 |
| 5 | `ଥି ଲା _ । _` | 27,225 |
### Key Findings
- **Best Perplexity:** 2-gram (subword) with 2,236
- **Entropy Trend:** Decreases with larger n-grams (more predictable)
- **Coverage:** Top-1000 patterns cover ~18% of corpus
- **Recommendation:** 4-gram or 5-gram for best predictive performance
---
## 3. Markov Chain Evaluation
![Markov Entropy](visualizations/markov_entropy.png)
![Markov Contexts](visualizations/markov_contexts.png)
![Markov Branching](visualizations/markov_branching.png)
### Results
| Context | Variant | Avg Entropy | Perplexity | Branching Factor | Unique Contexts | Predictability |
|---------|---------|-------------|------------|------------------|-----------------|----------------|
| **1** | Word | 0.8072 | 1.750 | 6.67 | 340,484 | 19.3% |
| **1** | Subword | 0.9446 | 1.925 | 13.59 | 10,595 | 5.5% |
| **2** | Word | 0.2495 | 1.189 | 1.58 | 2,269,616 | 75.0% |
| **2** | Subword | 0.6564 | 1.576 | 4.70 | 143,947 | 34.4% |
| **3** | Word | 0.0678 | 1.048 | 1.11 | 3,579,859 | 93.2% |
| **3** | Subword | 0.5343 | 1.448 | 3.26 | 676,398 | 46.6% |
| **4** | Word | 0.0235 🏆 | 1.016 | 1.04 | 3,976,608 | 97.6% |
| **4** | Subword | 0.3939 | 1.314 | 2.07 | 2,202,293 | 60.6% |
### Generated Text Samples (Word-based)
Below are text samples generated from each word-based Markov chain model:
**Context Size 1:**
1. `ଓ ସେତେବେଳେ ଥିଲା ଯୁକ୍ତରାଷ୍ଟ୍ରରେ ଏହାକୁ ପାଇବାରେ ଲାଗିଛି ବୁଦ୍ଧିମତା ପ୍ରଭୃତି ବିଶେଷ ସୁବିଧା ଉପଲବ୍ଧ ଯୁକ୍ତରାଜ୍ୟ...`
2. `ସେ ଅଂଶଗ୍ରହଣ କରନ୍ତି ପ୍ରତି ଆଗ୍ରହ ଦେଖି ସେମାନେ ନିଜ ବୃତ୍ତି ସହାୟକ ହୁଅନ୍ତି ଶିବଙ୍କ ସମ୍ପର୍କିତ ବିବାଦର ସମାଧାନ ହ...`
3. `ଏହି ପ୍ରବନ୍ଧଟି ହେଉଛି ଜୋର୍ଡାନ ଏବଂ ବର୍ଷା ପ୍ରିୟଦର୍ଶିନୀ ଅଭିନେତ୍ରୀ କଥାଚିତ୍ର ଅଭିନେତା ଯିଏକି ଜଣେ ଜନନାୟକ ଜନତା ...`
**Context Size 2:**
1. `ଓଡ଼ିଶା ବିଧାନ ସଭାରେ ସେ ମସିହାରୁ ଅନୁବାଦ ସାହିତ୍ୟରେ କେନ୍ଦ୍ର ସାହିତ୍ୟ ଏକାଡେମୀ ପୁରସ୍କାର ସମ୍ମାନିତ ପୁରସ୍କାର ବି...`
2. `ସେପ୍ଟେମ୍ବର ଅକ୍ଟୋବର ଡିସେମ୍ବର ଅଜ୍ଞାତ ତିଥି ଘଟଣା ଜନ୍ମ ଜାନୁଆରୀ ମାର୍ଚ୍ଚ ଅପ୍ରେଲ ଜୁନ ଜୁଲାଇ ସେପ୍ଟେମ୍ବର ଅକ୍ଟୋବ...`
3. `ଅକ୍ଟୋବର ଡିସେମ୍ବର ଅଜ୍ଞାତ ତିଥି ଘଟଣା ଜନ୍ମ ଜାନୁଆରୀ ମାର୍ଚ୍ଚ ଅପ୍ରେଲ ଜୁନ ଜୁଲାଇ ସେପ୍ଟେମ୍ବର ଅକ୍ଟୋବର ଡିସେମ୍ବର ...`
**Context Size 3:**
1. `ଜୁଲାଇ ସେପ୍ଟେମ୍ବର ଅକ୍ଟୋବର ଡିସେମ୍ବର ମୃତ୍ୟୁ ଜାନୁଆରୀ ମାର୍ଚ୍ଚ ଅପ୍ରେଲ ଜୁନ ଜୁଲାଇ ସେପ୍ଟେମ୍ବର ଅକ୍ଟୋବର ଡିସେମ୍ବ...`
2. `ସେପ୍ଟେମ୍ବର ଅକ୍ଟୋବର ଡିସେମ୍ବର ମୃତ୍ୟୁ ଜାନୁଆରୀ ମାର୍ଚ୍ଚ ଅପ୍ରେଲ ଜୁନ ଜୁଲାଇ ସେପ୍ଟେମ୍ବର ଅକ୍ଟୋବର ଡିସେମ୍ବର ମୃତ୍...`
3. `ଜୁନ ଜୁଲାଇ ସେପ୍ଟେମ୍ବର ଅକ୍ଟୋବର ଡିସେମ୍ବର ଅଜ୍ଞାତ ତିଥି ଘଟଣା ଜନ୍ମ ଜାନୁଆରୀ ମାର୍ଚ୍ଚ ଅପ୍ରେଲ ଜୁନ ଜୁଲାଇ ସେପ୍ଟେମ...`
**Context Size 4:**
1. `ଜୁଲାଇ ସେପ୍ଟେମ୍ବର ଅକ୍ଟୋବର ଡିସେମ୍ବର ମୃତ୍ୟୁ ଜାନୁଆରୀ ମାର୍ଚ୍ଚ ଅପ୍ରେଲ ଜୁନ ଜୁଲାଇ ସେପ୍ଟେମ୍ବର ଅକ୍ଟୋବର ଡିସେମ୍ବ...`
2. `ଜୁନ ଜୁଲାଇ ସେପ୍ଟେମ୍ବର ଅକ୍ଟୋବର ଡିସେମ୍ବର ମୃତ୍ୟୁ ଜାନୁଆରୀ ମାର୍ଚ୍ଚ ଅପ୍ରେଲ ଜୁନ ଜୁଲାଇ ସେପ୍ଟେମ୍ବର ଅକ୍ଟୋବର ଡିସ...`
3. `ଅପ୍ରେଲ ଜୁନ ଜୁଲାଇ ସେପ୍ଟେମ୍ବର ଅକ୍ଟୋବର ଡିସେମ୍ବର ମୃତ୍ୟୁ ଜାନୁଆରୀ ମାର୍ଚ୍ଚ ଅପ୍ରେଲ ଜୁନ ଜୁଲାଇ ସେପ୍ଟେମ୍ବର ଅକ୍ଟ...`
### Generated Text Samples (Subword-based)
Below are text samples generated from each subword-based Markov chain model:
**Context Size 1:**
1. `_ଏହା_ଉତ୍ତମ_କେଓ_f)_ରା_`
2. `ର_ଛାନ୍ଦର_ତ_ଇଥିବଙ୍ଗ_।_ଓ`
3. `କ_ସକୁ_ରାଜୀବର_ପ୍ରସ୍ତୁ_ଶେଖଣି`
**Context Size 2:**
1. `ର_ବନ୍ଧାଯାଏ_।_ଦୀର୍ଘ_ଆନାରେ_ଜ`
2. `ରେ_ପଡିଲା_।_ଯଥା-_୩୦_ଜାତି`
3. `।_ସବୁର_ପ୍ରଗତୀୟ_(ସେତେବେଳେ_`
**Context Size 3:**
1. `_।_ପ୍ରାରମ୍ଭିକ_ଅବରୋଧ_କରିଛନ୍ତି।`
2. `_କରିଥାଏ,_ଯାହାକି_ପୂଜା_ପାଇଥିଲେ`
3. `ଥିଲେ_ମଧ୍ୟ_ଭଜନ_ଗୃହମନ୍ତ୍ରୀ_ରହିଲା`
**Context Size 4:**
1. `ଲେ_।_ଜନ୍ମ,_ପରିବାର_ଆବଶ୍ୟକୀୟ_`
2. `ଥିଲେ_।_ସେଇ_ମହମ୍ମଦ_ଖାନଙ୍କ_ମନୋ`
3. `_ଏହି_ବିଷୟରେ_ଜାଣିହେବ_।_ସାନ୍_`
### Key Findings
- **Best Predictability:** Context-4 (word) with 97.6% predictability
- **Branching Factor:** Decreases with context size (more deterministic)
- **Memory Trade-off:** Larger contexts require more storage (2,202,293 contexts)
- **Recommendation:** Context-3 or Context-4 for text generation
---
## 4. Vocabulary Analysis
![Zipf's Law](visualizations/zipf_law.png)
![Top Words](visualizations/top20_words.png)
![Coverage Curve](visualizations/vocab_coverage.png)
### Statistics
| Metric | Value |
|--------|-------|
| Vocabulary Size | 136,870 |
| Total Tokens | 4,501,470 |
| Mean Frequency | 32.89 |
| Median Frequency | 4 |
| Frequency Std Dev | 438.76 |
### Most Common Words
| Rank | Word | Frequency |
|------|------|-----------|
| 1 | ଓ | 75,711 |
| 2 | ସେ | 45,611 |
| 3 | ଏହି | 45,373 |
| 4 | ଏବଂ | 41,576 |
| 5 | ଏକ | 38,494 |
| 6 | କରିଥିଲେ | 36,605 |
| 7 | ଏହା | 26,828 |
| 8 | ପାଇଁ | 24,033 |
| 9 | ଆଧାର | 21,330 |
| 10 | ମଧ୍ୟ | 18,417 |
### Least Common Words (from vocabulary)
| Rank | Word | Frequency |
|------|------|-----------|
| 1 | ଚେଳେଶ୍ୱର | 2 |
| 2 | କୁରିୟନ | 2 |
| 3 | ଆଲାପ୍ପୁଝା | 2 |
| 4 | ଚେରଥାଲା | 2 |
| 5 | cherthala | 2 |
| 6 | ପୁଥିୟାଭିଲା | 2 |
| 7 | puthiyavila | 2 |
| 8 | ମାଭେଲିକ୍କର | 2 |
| 9 | cheriyanad | 2 |
| 10 | padanilam | 2 |
### Zipf's Law Analysis
| Metric | Value |
|--------|-------|
| Zipf Coefficient | 1.0564 |
| R² (Goodness of Fit) | 0.989694 |
| Adherence Quality | **excellent** |
### Coverage Analysis
| Top N Words | Coverage |
|-------------|----------|
| Top 100 | 24.7% |
| Top 1,000 | 54.1% |
| Top 5,000 | 74.9% |
| Top 10,000 | 82.2% |
### Key Findings
- **Zipf Compliance:** R²=0.9897 indicates excellent adherence to Zipf's law
- **High Frequency Dominance:** Top 100 words cover 24.7% of corpus
- **Long Tail:** 126,870 words needed for remaining 17.8% coverage
---
## 5. Word Embeddings Evaluation
![Embedding Isotropy](visualizations/embedding_isotropy.png)
![Similarity Matrix](visualizations/embedding_similarity.png)
![t-SNE Words](visualizations/tsne_words.png)
![t-SNE Sentences](visualizations/tsne_sentences.png)
### 5.1 Cross-Lingual Alignment
![Alignment Quality](visualizations/embedding_alignment_quality.png)
![Multilingual t-SNE](visualizations/embedding_tsne_multilingual.png)
### 5.2 Model Comparison
| Model | Dimension | Isotropy | Semantic Density | Alignment R@1 | Alignment R@10 |
|-------|-----------|----------|------------------|---------------|----------------|
| **mono_32d** | 32 | 0.8415 🏆 | 0.3599 | N/A | N/A |
| **mono_64d** | 64 | 0.8361 | 0.2726 | N/A | N/A |
| **mono_128d** | 128 | 0.8229 | 0.2022 | N/A | N/A |
| **aligned_32d** | 32 | 0.8415 | 0.3633 | 0.0280 | 0.2100 |
| **aligned_64d** | 64 | 0.8361 | 0.2795 | 0.0380 | 0.2660 |
| **aligned_128d** | 128 | 0.8229 | 0.2078 | 0.1060 | 0.3460 |
### Key Findings
- **Best Isotropy:** mono_32d with 0.8415 (more uniform distribution)
- **Semantic Density:** Average pairwise similarity of 0.2809. Lower values indicate better semantic separation.
- **Alignment Quality:** Aligned models achieve up to 10.6% R@1 in cross-lingual retrieval.
- **Recommendation:** 128d aligned for best cross-lingual performance
---
## 6. Morphological Analysis (Experimental)
This section presents an automated morphological analysis derived from the statistical divergence between word-level and subword-level models. By analyzing where subword predictability spikes and where word-level coverage fails, we can infer linguistic structures without supervised data.
### 6.1 Productivity & Complexity
| Metric | Value | Interpretation | Recommendation |
|--------|-------|----------------|----------------|
| Productivity Index | **5.000** | High morphological productivity | Reliable analysis |
| Idiomaticity Gap | **1.043** | High formulaic/idiomatic content | - |
### 6.2 Affix Inventory (Productive Units)
These are the most productive prefixes and suffixes identified by sampling the vocabulary for global substitutability patterns. A unit is considered an affix if stripping it leaves a valid stem that appears in other contexts.
#### Productive Prefixes
| Prefix | Examples |
|--------|----------|
| `-ସ` | ସିଡ଼ନୀ, ସାମ୍ୟବାଦର, ସାଧକଙ୍କୁ |
| `-ବ` | ବଣ୍ଡଲ, ବ୍ରହ୍ନ, ବନଜ୍ୟୋତ୍ସ୍ନା |
| `-କ` | କୋତୋ, କୃପାସିନ୍ଧୁଙ୍କୁ, କବକଦ୍ୱାରା |
| `-ପ` | ପ୍ରଗାଢ, ପରିଚୟର, ପ୍ରତ୍ନ‌ତ‌ତ୍ୱବିଦ |
| `-ମ` | ମରମେର, ମୁଣ୍ଡକ, ମାରିଦେବାକୁ |
| `-ଅ` | ଅପେକ୍ଷା, ଅନାଥ, ଅନୈତିକ |
| `-ନ` | ନେଫାଜୋଡୋନ, ନିରଜ, ନିଆଁପେଣ୍ଡୁ |
| `-ଆ` | ଆକାଶଗଙ୍ଗା, ଆଭିମୁଖ୍ୟର, ଆଞ୍ଜିଓଡେମା |
#### Productive Suffixes
| Suffix | Examples |
|--------|----------|
| `-ର` | ଷ୍ଟଡ଼ିଜର, ମରମେର, ପରିଚୟର |
| `-କ` | ମୁଣ୍ଡକ, ଭାଷାଗୁଡ଼ିକ, ଇମ୍ମ୍ୟୁନୋଲୋଜିକ |
| `-ନ` | ଲୋକରତ୍ନ, ନେଫାଜୋଡୋନ, ବ୍ରହ୍ନ |
| `-s` | endocarditis, notes, colours |
| `-କର` | ଡାକ୍ତରମାନଙ୍କର, ତୀର୍ଥଙ୍କରଙ୍କର, ପ୍ରଣୀତାଙ୍କର |
| `-ତ` | ଲଣ୍ଡନସ୍ଥିତ, କାର୍ଯରତ, ମର୍ମାହତ |
| `-e` | commemorate, define, triple |
| `-ୟ` | ଦୀର୍ଘସମୟ, ଋଷିୟ, ସଦୀୟ |
### 6.3 Bound Stems (Lexical Roots)
Bound stems are high-frequency subword units that are semantically cohesive but rarely appear as standalone words. These often correspond to the 'core' of a word that requires inflection or derivation to be valid.
| Stem | Cohesion | Substitutability | Examples |
|------|----------|------------------|----------|
| `ther` | 3.09x | 37 contexts | other, ether, there |
| `atio` | 3.04x | 34 contexts | ratio, ration, nation |
| `tion` | 2.94x | 35 contexts | option, action, ration |
| `indi` | 3.19x | 26 contexts | hindi, india, indie |
| `ture` | 3.19x | 25 contexts | nature, mature, future |
| `vers` | 3.09x | 26 contexts | verso, overs, versa |
| `ment` | 3.07x | 25 contexts | moment, cement, mentor |
| `ress` | 2.99x | 27 contexts | dress, press, stress |
| `nter` | 2.90x | 29 contexts | enter, inter, center |
| `ctio` | 2.94x | 19 contexts | action, section, actions |
| `stor` | 3.07x | 16 contexts | istor, store, story |
| `tern` | 2.88x | 17 contexts | stern, sternal, externa |
### 6.4 Affix Compatibility (Co-occurrence)
This table shows which prefixes and suffixes most frequently co-occur on the same stems, revealing the 'stacking' rules of the language's morphology.
| Prefix | Suffix | Frequency | Examples |
|--------|--------|-----------|----------|
| `-ସ` | `-ର` | 75 words | ସାକ୍ଷାତର, ସ୍ଥଳବହିନୀର |
| `-ପ` | `-ର` | 57 words | ପତିଙ୍କର, ପ୍ରଧାନମନ୍ତ୍ରୀଙ୍କର |
| `-କ` | `-ର` | 53 words | କୂଳର, କଥକଳୀର |
| `-ବ` | `-ର` | 46 words | ବାଉଦପୁର, ବିହେଭିଅର |
| `-ମ` | `-ର` | 45 words | ମାତୃକାମାନଙ୍କର, ମୁରୁଜର |
| `-ବ` | `-କ` | 44 words | ବାସନ୍ତୀଙ୍କ, ବାଇଫେଜିକ |
| `-ସ` | `-କ` | 43 words | ସମୟତକ, ସୁଷେଣଙ୍କ |
| `-ପ` | `-କ` | 36 words | ପୁଷ୍ପକ, ପ୍ରାଗ୍ଐତିହାସିକ |
| `-ନ` | `-ର` | 35 words | ନବକଳେବରର, ନକ୍ଷତ୍ରପୁର |
| `-ମ` | `-କ` | 33 words | ମିକୋତୋଙ୍କ, ମାନସାଙ୍କ |
### 6.5 Recursive Morpheme Segmentation
Using **Recursive Hierarchical Substitutability**, we decompose complex words into their constituent morphemes. This approach handles nested affixes (e.g., `prefix-prefix-root-suffix`).
| Word | Suggested Split | Confidence | Stem |
|------|-----------------|------------|------|
| ବରଗାଁଠାରୁ | **`ବ-ର-ଗାଁଠାରୁ`** | 7.5 | `ଗାଁଠାରୁ` |
| helminths | **`helminth-s`** | 4.5 | `helminth` |
| ମହାରାଷ୍ଟ୍ରର | **`ମହାରାଷ୍ଟ୍ର-ର`** | 4.5 | `ମହାରାଷ୍ଟ୍ର` |
| ପର୍ବତଗୁଡ଼ିକର | **`ପର୍ବତଗୁଡ଼ିକ-ର`** | 4.5 | `ପର୍ବତଗୁଡ଼ିକ` |
| କୃଷ୍ଣଚନ୍ଦ୍ରଙ୍କର | **`କୃଷ୍ଣଚନ୍ଦ୍ରଙ୍କ-ର`** | 4.5 | `କୃଷ୍ଣଚନ୍ଦ୍ରଙ୍କ` |
| ଉଚ୍ଚବର୍ଗର | **`ଉଚ୍ଚବର୍ଗ-ର`** | 4.5 | `ଉଚ୍ଚବର୍ଗ` |
| inventory | **`inventor-y`** | 4.5 | `inventor` |
| ଆସେସ୍ମେଣ୍ଟର | **`ଆସେସ୍ମେଣ୍ଟ-ର`** | 4.5 | `ଆସେସ୍ମେଣ୍ଟ` |
| ଯୋଦ୍ଧାଙ୍କର | **`ଯୋଦ୍ଧାଙ୍କ-ର`** | 4.5 | `ଯୋଦ୍ଧାଙ୍କ` |
| analytics | **`analytic-s`** | 4.5 | `analytic` |
| ରାୟଗଡ଼଼ାର | **`ରାୟଗଡ଼଼ା-ର`** | 4.5 | `ରାୟଗଡ଼଼ା` |
| ସିଗିରିୟାର | **`ସିଗିରିୟା-ର`** | 4.5 | `ସିଗିରିୟା` |
| ଏମାନ‌ଙ୍କୁ | **`ଏ-ମ-ାନ‌ଙ୍କୁ`** | 4.5 | `ାନ‌ଙ୍କୁ` |
| ପ୍ରାସାଦଟିର | **`ପ୍ରାସାଦଟି-ର`** | 4.5 | `ପ୍ରାସାଦଟି` |
| ସୃଷ୍ଟିକରିବ | **`ସୃଷ୍ଟିକରି-ବ`** | 4.5 | `ସୃଷ୍ଟିକରି` |
### 6.6 Linguistic Interpretation
> **Automated Insight:**
The language Odia shows high morphological productivity. The subword models are significantly more efficient than word models, suggesting a rich system of affixation or compounding.
> **Note on Idiomaticity:** The high Idiomaticity Gap suggests a large number of frequent multi-word expressions or formulaic sequences that are statistically distinct from their component parts.
---
## 7. Summary & Recommendations
![Performance Dashboard](visualizations/performance_dashboard.png)
### Production Recommendations
| Component | Recommended | Rationale |
|-----------|-------------|-----------|
| Tokenizer | **64k BPE** | Best compression (4.96x) |
| N-gram | **2-gram** | Lowest perplexity (2,236) |
| Markov | **Context-4** | Highest predictability (97.6%) |
| Embeddings | **100d** | Balanced semantic capture and isotropy |
---
## Appendix: Metrics Glossary & Interpretation Guide
This section provides definitions, intuitions, and guidance for interpreting the metrics used throughout this report.
### Tokenizer Metrics
**Compression Ratio**
> *Definition:* The ratio of characters to tokens (chars/token). Measures how efficiently the tokenizer represents text.
>
> *Intuition:* Higher compression means fewer tokens needed to represent the same text, reducing sequence lengths for downstream models. A 3x compression means ~3 characters per token on average.
>
> *What to seek:* Higher is generally better for efficiency, but extremely high compression may indicate overly aggressive merging that loses morphological information.
**Average Token Length (Fertility)**
> *Definition:* Mean number of characters per token produced by the tokenizer.
>
> *Intuition:* Reflects the granularity of tokenization. Longer tokens capture more context but may struggle with rare words; shorter tokens are more flexible but increase sequence length.
>
> *What to seek:* Balance between 2-5 characters for most languages. Arabic/morphologically-rich languages may benefit from slightly longer tokens.
**Unknown Token Rate (OOV Rate)**
> *Definition:* Percentage of tokens that map to the unknown/UNK token, indicating words the tokenizer cannot represent.
>
> *Intuition:* Lower OOV means better vocabulary coverage. High OOV indicates the tokenizer encounters many unseen character sequences.
>
> *What to seek:* Below 1% is excellent; below 5% is acceptable. BPE tokenizers typically achieve very low OOV due to subword fallback.
### N-gram Model Metrics
**Perplexity**
> *Definition:* Measures how "surprised" the model is by test data. Mathematically: 2^(cross-entropy). Lower values indicate better prediction.
>
> *Intuition:* If perplexity is 100, the model is as uncertain as if choosing uniformly among 100 options at each step. A perplexity of 10 means effectively choosing among 10 equally likely options.
>
> *What to seek:* Lower is better. Perplexity decreases with larger n-grams (more context). Values vary widely by language and corpus size.
**Entropy**
> *Definition:* Average information content (in bits) needed to encode the next token given the context. Related to perplexity: perplexity = 2^entropy.
>
> *Intuition:* High entropy means high uncertainty/randomness; low entropy means predictable patterns. Natural language typically has entropy between 1-4 bits per character.
>
> *What to seek:* Lower entropy indicates more predictable text patterns. Entropy should decrease as n-gram size increases.
**Coverage (Top-K)**
> *Definition:* Percentage of corpus occurrences explained by the top K most frequent n-grams.
>
> *Intuition:* High coverage with few patterns indicates repetitive/formulaic text; low coverage suggests diverse vocabulary usage.
>
> *What to seek:* Depends on use case. For language modeling, moderate coverage (40-60% with top-1000) is typical for natural text.
### Markov Chain Metrics
**Average Entropy**
> *Definition:* Mean entropy across all contexts, measuring average uncertainty in next-word prediction.
>
> *Intuition:* Lower entropy means the model is more confident about what comes next. Context-1 has high entropy (many possible next words); Context-4 has low entropy (few likely continuations).
>
> *What to seek:* Decreasing entropy with larger context sizes. Very low entropy (<0.1) indicates highly deterministic transitions.
**Branching Factor**
> *Definition:* Average number of unique next tokens observed for each context.
>
> *Intuition:* High branching = many possible continuations (flexible but uncertain); low branching = few options (predictable but potentially repetitive).
>
> *What to seek:* Branching factor should decrease with context size. Values near 1.0 indicate nearly deterministic chains.
**Predictability**
> *Definition:* Derived metric: (1 - normalized_entropy) × 100%. Indicates how deterministic the model's predictions are.
>
> *Intuition:* 100% predictability means the next word is always certain; 0% means completely random. Real text falls between these extremes.
>
> *What to seek:* Higher predictability for text generation quality, but too high (>98%) may produce repetitive output.
### Vocabulary & Zipf's Law Metrics
**Zipf's Coefficient**
> *Definition:* The slope of the log-log plot of word frequency vs. rank. Zipf's law predicts this should be approximately -1.
>
> *Intuition:* A coefficient near -1 indicates the corpus follows natural language patterns where a few words are very common and most words are rare.
>
> *What to seek:* Values between -0.8 and -1.2 indicate healthy natural language distribution. Deviations may suggest domain-specific or artificial text.
**R² (Coefficient of Determination)**
> *Definition:* Measures how well the linear fit explains the frequency-rank relationship. Ranges from 0 to 1.
>
> *Intuition:* R² near 1.0 means the data closely follows Zipf's law; lower values indicate deviation from expected word frequency patterns.
>
> *What to seek:* R² > 0.95 is excellent; > 0.99 indicates near-perfect Zipf adherence typical of large natural corpora.
**Vocabulary Coverage**
> *Definition:* Cumulative percentage of corpus tokens accounted for by the top N words.
>
> *Intuition:* Shows how concentrated word usage is. If top-100 words cover 50% of text, the corpus relies heavily on common words.
>
> *What to seek:* Top-100 covering 30-50% is typical. Higher coverage indicates more repetitive text; lower suggests richer vocabulary.
### Word Embedding Metrics
**Isotropy**
> *Definition:* Measures how uniformly distributed vectors are in the embedding space. Computed as the ratio of minimum to maximum singular values.
>
> *Intuition:* High isotropy (near 1.0) means vectors spread evenly in all directions; low isotropy means vectors cluster in certain directions, reducing expressiveness.
>
> *What to seek:* Higher isotropy generally indicates better-quality embeddings. Values > 0.1 are reasonable; > 0.3 is good. Lower-dimensional embeddings tend to have higher isotropy.
**Average Norm**
> *Definition:* Mean magnitude (L2 norm) of word vectors in the embedding space.
>
> *Intuition:* Indicates the typical "length" of vectors. Consistent norms suggest stable training; high variance may indicate some words are undertrained.
>
> *What to seek:* Relatively consistent norms across models. The absolute value matters less than consistency (low std deviation).
**Cosine Similarity**
> *Definition:* Measures angular similarity between vectors, ranging from -1 (opposite) to 1 (identical direction).
>
> *Intuition:* Words with similar meanings should have high cosine similarity. This is the standard metric for semantic relatedness in embeddings.
>
> *What to seek:* Semantically related words should score > 0.5; unrelated words should be near 0. Synonyms often score > 0.7.
**t-SNE Visualization**
> *Definition:* t-Distributed Stochastic Neighbor Embedding - a dimensionality reduction technique that preserves local structure for visualization.
>
> *Intuition:* Clusters in t-SNE plots indicate groups of semantically related words. Spread indicates vocabulary diversity; tight clusters suggest semantic coherence.
>
> *What to seek:* Meaningful clusters (e.g., numbers together, verbs together). Avoid over-interpreting distances - t-SNE preserves local, not global, structure.
### General Interpretation Guidelines
1. **Compare within model families:** Metrics are most meaningful when comparing models of the same type (e.g., 8k vs 64k tokenizer).
2. **Consider trade-offs:** Better performance on one metric often comes at the cost of another (e.g., compression vs. OOV rate).
3. **Context matters:** Optimal values depend on downstream tasks. Text generation may prioritize different metrics than classification.
4. **Corpus influence:** All metrics are influenced by corpus characteristics. Wikipedia text differs from social media or literature.
5. **Language-specific patterns:** Morphologically rich languages (like Arabic) may show different optimal ranges than analytic languages.
### Visualizations Index
| Visualization | Description |
|---------------|-------------|
| Tokenizer Compression | Compression ratios by vocabulary size |
| Tokenizer Fertility | Average token length by vocabulary |
| Tokenizer OOV | Unknown token rates |
| Tokenizer Total Tokens | Total tokens by vocabulary |
| N-gram Perplexity | Perplexity by n-gram size |
| N-gram Entropy | Entropy by n-gram size |
| N-gram Coverage | Top pattern coverage |
| N-gram Unique | Unique n-gram counts |
| Markov Entropy | Entropy by context size |
| Markov Branching | Branching factor by context |
| Markov Contexts | Unique context counts |
| Zipf's Law | Frequency-rank distribution with fit |
| Vocab Frequency | Word frequency distribution |
| Top 20 Words | Most frequent words |
| Vocab Coverage | Cumulative coverage curve |
| Embedding Isotropy | Vector space uniformity |
| Embedding Norms | Vector magnitude distribution |
| Embedding Similarity | Word similarity heatmap |
| Nearest Neighbors | Similar words for key terms |
| t-SNE Words | 2D word embedding visualization |
| t-SNE Sentences | 2D sentence embedding visualization |
| Position Encoding | Encoding method comparison |
| Model Sizes | Storage requirements |
| Performance Dashboard | Comprehensive performance overview |
---
## About This Project
### Data Source
Models trained on [wikipedia-monthly](https://huggingface.co/datasets/omarkamali/wikipedia-monthly) - a monthly snapshot of Wikipedia articles across 300+ languages.
### Project
A project by **[Wikilangs](https://wikilangs.org)** - Open-source NLP models for every Wikipedia language.
### Maintainer
[Omar Kamali](https://omarkamali.com) - [Omneity Labs](https://omneitylabs.com)
### Citation
If you use these models in your research, please cite:
```bibtex
@misc{wikilangs2025,
author = {Kamali, Omar},
title = {Wikilangs: Open NLP Models for Wikipedia Languages},
year = {2025},
doi = {10.5281/zenodo.18073153},
publisher = {Zenodo},
url = {https://huggingface.co/wikilangs}
institution = {Omneity Labs}
}
```
### License
MIT License - Free for academic and commercial use.
### Links
- 🌐 Website: [wikilangs.org](https://wikilangs.org)
- 🤗 Models: [huggingface.co/wikilangs](https://huggingface.co/wikilangs)
- 📊 Data: [wikipedia-monthly](https://huggingface.co/datasets/omarkamali/wikipedia-monthly)
- 👤 Author: [Omar Kamali](https://huggingface.co/omarkamali)
- 🤝 Sponsor: [Featherless AI](https://featherless.ai)
---
*Generated by Wikilangs Models Pipeline*
*Report Date: 2026-01-10 17:17:27*