Rootformer Stage 15.2 (rootformers_stage_v15.2) โ€” Bฤb al-Naแบ“m wa-แธคidhฤสพ al-Alfฤแบ“ (ุจุงุจ ุงู„ู†ุธู… ูˆุญุฐุงุก ุงู„ุฃู„ูุงุธ)

Rootformer Stage 15.2 is a self-contained, BPE-Free Arabic-to-English scholarly translation and morphological-syntactic intelligence engine grounded in the non-concatenative morphological theory of al-Khalฤซl ibn Aแธฅmad al-Farฤhฤซdฤซ, the 16-state syntactic governance (สฟAmal) of Sฤซbawayh, and สฟAbd al-Qฤhir al-Jurjฤnฤซ's theory of al-Naแบ“m (Dalฤสพil al-Iสฟjฤz).

This repository is a 100% turnkey standalone deployment package: clone or download it onto any Linux GPU or CPU server and run two commands (./install.sh && ./run_standalone_server.sh) to launch the full Widescreen Desktop & Mobile Sovereign Workbench UI, REST JSON API, CLI, and Python SDK.


What Can Rootformer Stage 15.2 Do?

1. Asymmetric 64-Layer Maสฟnฤ Prefill + Fast Hub-Guided Lafแบ“ BPE Decode (Stage 15.2)

In al-Jurjฤnฤซ's Dalฤสพil al-Iสฟjฤz, deep relational deduction (ุชุฑุชูŠุจ ุงู„ู…ุนุงู†ูŠ ููŠ ุงู„ู†ูุณ โ€” Tartฤซb al-Maสฟฤnฤซ fฤซ al-Nafs) occurs when comprehending the Arabic clause and its syntactic dependencies (Taสฟalluq), whereas uttering the target words (ุญุฐุงุก ุงู„ุฃู„ูุงุธ โ€” แธคidhฤสพ al-Alfฤแบ“) follows the already-constructed semantic blueprint:

  • During Arabic Prefill (seq_len > 16): Executes all 64 layers (100% of Qwen3.8-27B) together with the 12-Slot Stage 13.2 Books Mastery Bridge (scale = 0.65) + 6-Pillar GSCA MoE + Sabk Anaphora so the KV/recurrent cache holds the exact 64-layer semantic state $Z_{\text{maสฟnฤ}}$.
  • During English BPE Decode & Speculative Verification (seq_len <= 16): Elides $K \in {4, 8, 12}$ upper linear-attention blocks and replaces each with a lightweight 64-rank HidhaAlAlfazResidualAdapter (120 MB total across 24 layers) conditioned on a cached Semantic Hub Summary ($z_8, z_{12}$) from Layers 31 and 47.
  • Intact English BPE Vocabulary (SibawayhSlicedLMHead): Preserves 100% of the active English & Arabic tokens (148,891 tokens, 0.000000 logit divergence) while pruning 99,429 unused CJK tokens (-1.95 GB VRAM saved).
  • 100% Pure Original Arabic Script (ุงู„ุญุฑูˆู ุงู„ุฃุตู„ูŠุฉ ุงู„ุนุฑุจูŠุฉ): Technical parenthetical anchors are always emitted in original Arabic script ((ุงู„ุตุงู†ุน), (ุญุงุฏุซ), (ุชุฑุฌูŠุญ ุจู„ุง ู…ุฑุฌุญ), (ุชู…ู‡ูŠุฏ), (ุถุฑูˆุฑุฉ), (ู‚ูŠุงุณ)), never Latin transliterations.
  • Bundled Native Triton causal_conv1d Kernel: Includes a zero-compile Triton causal_conv1d.py drop-in module so Qwen3.8-27B's GatedDeltaNet layers run at full hardware speed without C++ wheel compilation errors or slow fallback warnings.

2. Measured Benchmark Performance (Qwen3.8-27B 4-Bit NF4 on NVIDIA A40)

Decode Mode Active Decode Depth Mean Speed (tok/s) Peak Speed (tok/s) Word Throughput (words/s) Total Time (10 Gold Passages) Wall-Clock Speedup Classical Gold chrF++ Classical Gold BLEU Modern MSA-12 chrF++
Pure Autoregressive Baseline (K=0) 64L / 64L 11.03 tok/s 11.24 tok/s 8.59 words/s 124.03s 1.00x 60.102 32.52 92.090
Stage 15.2 Ultra-Fidelity (--ultra-fidelity, K=4) 64L Prefill / 60L Decode 28.82 tok/s 52.87 tok/s 22.49 words/s 50.02s 2.48x 60.599 33.67 92.090
Stage 15.2 Balanced Default (--27b, K=8) 64L Prefill / 56L Decode 30.36 tok/s 38.61 tok/s 23.53 words/s 43.77s 2.83x 59.734 32.86 92.090 (81.85 BLEU)
Stage 15.2 Turbo Mode (--turbo, K=12) 64L Prefill / 52L Decode 34.57 tok/s 49.50 tok/s 26.90 words/s 37.32s 3.32x 58.822 33.39 92.090

3. Core Capabilities Across Classical & Modern Arabic

  1. BPE-Free Non-Concatenative Morphological Factorization ($\phi(w_t) = (r_t, w_t, p_t, s_t)$):
    • Deterministically decomposes Arabic surface words into 10,899 trilateral/quadrilateral roots (Judhลซr), 160 morphological templates (Awzฤn), proclitics, and enclitics via the 329,695-entry Farฤhฤซdฤซ Lookup Table (O(1) latency) plus algorithmic fallback.
  2. 100% แนขarfฤซ Active vs. Passive Participle Disambiguation (25/25):
    • Distinguishes unvocalized homographs such as ู…ุญุฏุซ (muแธฅdith [Originator] vs. muแธฅdath [originated]), ู…ุคุซุฑ (muสพaththir [Effective Cause] vs. muสพaththar [effected]), and ู…ุฑุฌุญ (murajjiแธฅ [Determiner] vs. murajjaแธฅ [preponderated]) via Sฤซbawayhian governance and theological constraints (100.0% accuracy).
  3. 16-State Sฤซbawayhian Syntactic Governance ($B_{\text{Sฤซbawayh}}$) & Passive Voice (al-Mabnฤซ lil-Majhลซl):
    • Tracks Ibtidฤสพ, Khabar, Fฤสฟil, Mafสฟลซl bihi, Nฤสพib al-Fฤสฟil, Iแธฤfah, and สฟAแนญf transitions across clauses (100.0% passive voice accuracy).
  4. 6-Pillar Classical Mastery & Zero Modern Polysemy Drift (0.00% Trap Leakage):
    • Separates Classical Kalฤm, Uแนฃลซl al-Fiqh, Mฤlikฤซ Fiqh, Taแนฃawwuf (Sฤซdฤซ Aแธฅmad Zarrลซq), Manแนญiq, and Balฤghah from Modern Standard Arabic (92.09 chrF++ on MSA-12; 0.00% modern drift on classical polysemous terms like ุงู„ุนุงู„ู…, ุงู„ุฏูˆุฑ, ุงู„ุดุงุฑุน, ุงู„ูุงุนู„, ุงู„ุญุงู„, ุงู„ุนูŠู†, ุงู„ู‚ุฏุฑ, ุงู„ู…ุญู„).
  5. Cross-Boundary Pronominal Anaphora (Sabk โ€” 100% on 8/8 Multi-Clause Chains):
    • Tracks enclitic pronouns (ู€ู‡, ู€ู‡ุง, ู€ู‡ู…) back to their exact antecedents across long multi-sentence passages.

Quickstart (2 Commands on Any GPU or CPU Server)

git clone https://huggingface.co/enver/rootformers_stage_v15.2
cd rootformers_stage_v15.2
chmod +x install.sh run_standalone_server.sh
./install.sh
./run_standalone_server.sh

Or download with huggingface_hub (automatically tracked by Hugging Face download metrics):

from huggingface_hub import snapshot_download

local_dir = snapshot_download(repo_id="enver/rootformers_stage_v15.2")
print("Downloaded standalone release to:", local_dir)

Then open http://localhost:17800 in your desktop or mobile browser.

Server Launch Modes (./run_standalone_server.sh)

Command Hardware / Backbone Loaded RAM / VRAM Description
./run_standalone_server.sh Auto (27B 4-Bit K=8 Naแบ“m on GPU / 1.7B on CPU) ~14.2 GB VRAM (27B) or ~4.5 GB RAM (CPU) Automatically loads Stage 15.2 Qwen3.8-27B 4-Bit NF4 + Asymmetric Naแบ“m (K=8, 30.36 tok/s, 2.83x speedup) on CUDA GPUs, or Qwen3-1.7B Sovereign (3.3 GB) + BPE-Free Bridge on CPU.
./run_standalone_server.sh --ultra-fidelity Qwen3.8-27B 4-Bit NF4 (K=4 Naแบ“m, 64Lโ†’60L) ~14.2 GB VRAM Highest Classical Gold fidelity (60.599 chrF++ / 33.67 BLEU) at 28.82 tok/s mean (52.87 tok/s peak, 2.48x speedup).
./run_standalone_server.sh --27b Qwen3.8-27B 4-Bit NF4 (K=8 Naแบ“m, 64Lโ†’56L) ~14.2 GB VRAM Balanced default: runs all 64 layers + 12-Slot Bridge on Arabic prefill and 56 layers + แธคidhฤสพ al-Alfฤแบ“ Residual Adapters on English BPE decode (30.36 tok/s, 23.53 words/sec, 59.734 chrF++, 92.09 chrF++ on MSA-12).
./run_standalone_server.sh --turbo Qwen3.8-27B 4-Bit NF4 (K=12 Naแบ“m, 64Lโ†’52L) ~14.2 GB VRAM Turbo mode: 34.57 tok/s mean (49.50 tok/s peak, 26.90 words/sec, 33.39 BLEU, 3.32x speedup).
./run_standalone_server.sh --8gb Strict 8GB VRAM Mode (27B 4-Bit) < 7.2 GB Peak VRAM Runs the 27B model on 8 GB consumer GPUs (RTX 3070/4060) using Dual-Stream Pinned-Memory Asynchronous Layer Prefetch (Taqdฤซm al-สฟฤ€mil).
./run_standalone_server.sh --1.7b Force Qwen3-1.7B Sovereign (GPU or CPU) ~4.0 GB VRAM/RAM Loads the bundled 3.3 GB 1.7B safetensors + 12-Layer BPE-Free Foundation + Tri-Layer Bridge.
./run_standalone_server.sh --cpu Force CPU Full Neural (1.7B) ~4.5 GB System RAM Runs full neural translation + 6-tab workbench 100% on CPU (zero GPU required).
./run_standalone_server.sh --fast-cpu Instant Light CPU (<5 ms) < 800 MB RAM Runs the 12-Layer BPE-Free Foundation Model + Khalฤซlian Root/Wazn Analyzer + Sฤซbawayh 16-State Syntax + แนขarfฤซ Disambiguator in milliseconds on any laptop CPU.

Python SDK & REST API Usage

1. Python SDK (rootformer_sdk.py)

from rootformer_sdk import RootformerStage12

# Mode A: Instant BPE-Free Analysis + 12-Layer Foundation Encoding (CPU or GPU, <5 ms)
rf = RootformerStage12(device="cpu", load_foundation=True, load_qwen=False)
analysis = rf.analyze(
    "ุงู„ุนุงู„ู… ุญุงุฏุซ ูˆูƒู„ ุญุงุฏุซ ูู„ุง ุจุฏ ู„ู‡ ู…ู† ู…ุญุฏุซ ูˆู…ุคุซุฑ ุชุงู… ุจุงู„ุฐุงุช ูŠุฑุฌุญ ูˆุฌูˆุฏู‡ ุนู„ู‰ ุนุฏู…ู‡ุŒ ู„ุฃู† ุงู„ุชุฑุฌูŠุญ ุจู„ุง ู…ุฑุฌุญ ู…ุญุงู„ ููŠ ุงู„ุนู‚ู„."
)
print("Rational Triad:", analysis["rational_triad"])
print("Sarfi Homographs:", analysis["sarfi_homographs"])

# Mode B: End-to-End Scholarly Translation
rf_translator = RootformerStage12(device="cuda", load_foundation=True, load_qwen=True)
result = rf_translator.translate(
    "ู†ุฏุนูŠ ุฃู† ู…ุญุฏุซ ุงู„ุนุงู„ู… ู‚ุงุฏุฑุŒ ู„ุฃู† ุงู„ุนุงู„ู… ูุนู„ ู…ุญูƒู… ู…ุฑุชุจ ู…ุชู‚ู† ู…ู†ุธูˆู… ู…ุดุชู…ู„ ุนู„ู‰ ุฃู†ูˆุงุน ู…ู† ุงู„ุนุฌุงุฆุจ ูˆุงู„ุขูŠุงุช"
)
print("English Translation:\n", result["translation"])

2. HTTP JSON API (POST /api/translate)

When ./run_standalone_server.sh is running on port 17800:

curl -s http://localhost:17800/api/translate \
  -H "Content-Type: application/json" \
  -d '{
    "text": "ุงู„ุนุงู„ู… ุญุงุฏุซ ูˆูƒู„ ุญุงุฏุซ ูู„ุง ุจุฏ ู„ู‡ ู…ู† ู…ุญุฏุซ ูˆู…ุคุซุฑ ุชุงู… ุจุงู„ุฐุงุช ูŠุฑุฌุญ ูˆุฌูˆุฏู‡ ุนู„ู‰ ุนุฏู…ู‡ุŒ ู„ุฃู† ุงู„ุชุฑุฌูŠุญ ุจู„ุง ู…ุฑุฌุญ ู…ุญุงู„ ููŠ ุงู„ุนู‚ู„.",
    "mode": "translate"
  }' | jq .

Repository Contents & Checkpoints

rootformers_stage_v15.2/
โ”œโ”€โ”€ config.json                        # Root Hugging Face model configuration (enables Hub download tracking)
โ”œโ”€โ”€ generation_config.json             # Root generation configuration
โ”œโ”€โ”€ tokenizer_config.json              # Root tokenizer configuration
โ”œโ”€โ”€ tokenizer.json                     # Root tokenizer vocabulary & merges
โ”œโ”€โ”€ chat_template.jinja                # Root chat template
โ”œโ”€โ”€ model.safetensors                  # Root Qwen3-1.7B Sovereign safetensors (3.3 GB)
โ”œโ”€โ”€ install.sh                         # One-click dependency & checkpoint verifier (27B GPU & 1.7B CPU/GPU)
โ”œโ”€โ”€ run_standalone_server.sh           # One-click server launcher (--ultra-fidelity, --27b, --turbo, --8gb, --1.7b, --cpu, --fast-cpu)
โ”œโ”€โ”€ server_stage15_2.py                # Stage 15.2 unified 27B 4-bit GPU & 1.7B CPU/GPU HTTP server & UI host
โ”œโ”€โ”€ causal_conv1d.py                   # Native Triton causal_conv1d kernel (zero C++ wheel compilation needed)
โ”œโ”€โ”€ rootformer_sdk.py                  # Self-contained Python SDK, CLI & Fast-CPU server
โ”œโ”€โ”€ requirements.txt                   # Minimal Python dependencies
โ”œโ”€โ”€ README.md                          # Hugging Face Model Card & Quickstart Guide
โ”œโ”€โ”€ aynengine_web_ui_11/               # Responsive 3-Column Desktop IDE & Mobile Web UI (6 Interactive Tabs)
โ”œโ”€โ”€ checkpoints/                       # All safetensors & bridge weights included
โ”‚   โ”œโ”€โ”€ qwen3_8_27b_4bit/              # Qwen3.8-27B 4-Bit NF4 safetensors + tokenizer (21 GB, for GPU)
โ”‚   โ”œโ”€โ”€ stage15_2/                     # Stage 15.2 Asymmetric Naแบ“m 24-Layer Residual Adapters (120 MB)
โ”‚   โ”œโ”€โ”€ stage14_5/                     # Stage 14.5 Learned Neural BPE-Free-to-BPE Drafter (50 MB)
โ”‚   โ”œโ”€โ”€ stage13_2/                     # Stage 13.2 Books Mastery 12-Slot Bridge + GSCA MoE (142 MB)
โ”‚   โ”œโ”€โ”€ stage7_3_mujtahid_sovereign/   # Qwen3-1.7B Sovereign safetensors + tokenizer (3.3 GB, for CPU/GPU)
โ”‚   โ””โ”€โ”€ stage12_bpe_free_foundation_best.pt # 12-Layer (101.55M) BPE-Free Foundation Model (388 MB)
โ”œโ”€โ”€ data/                              # 329K Farฤhฤซdฤซ NMFE LUT, 2,469 Lexicon, Qur'an & Consensus Graph
โ”œโ”€โ”€ engine/                            # Deterministic Khalฤซlian, Sฤซbawayhian, แนขarfฤซ & Sabk engines
โ”œโ”€โ”€ scripts/                           # Self-contained Stage 11โ€“15.2 architecture & evaluation modules
โ””โ”€โ”€ stage15_2/                         # Stage 15.2 evaluation suites, training scripts & benchmark logs
Downloads last month
9
Safetensors
Model size
2B params
Tensor type
BF16
ยท
Inference Providers NEW
This model isn't deployed by any Inference Provider. ๐Ÿ™‹ Ask for provider support

Model tree for enver/rootformers_stage_v15.2

Finetuned
Qwen/Qwen3-1.7B
Finetuned
(1333)
this model