πŸ¦™πŸ§­ MatterWaveAI / llama2c-gok β€” karpathy/llama2.c Trained on the MatterWave Graph of Knowledge (GoK) Curriculum

Base Architecture Curriculum Ontology Inference Overhead

This model card summarizes a controlled 4-arm ablation study evaluating a standard 1.31M-parameter LLaMA-2 Transformer (karpathy/llama2.c: dim = 128, n_layers = 4, n_heads = 4, vocab_size = 2048) trained on the MatterWave Graph of Knowledge (GoK) curriculum (22K+ prerequisite-ordered concepts) under an identical token and step budget:

  • Arm B (+GoK Curriculum Ordering) modifies only the data ordering (0 model or optimizer changes), achieving a 1.33Γ— convergence speedup, reducing prerequisite hierarchy inversions from 31.40% to 8.40%, and boosting 2-hop reasoning recall from 48.2% to 74.8%.
  • Arm C (+GoK Representation Alignment) adds train-time representation alignment while exporting a 100% standard llama2.c checkpoint (0.00% inference parameter or FLOP overhead, compatible with unmodified run.c), achieving a 2.67Γ— convergence speedup, 94.8% 1-hop recall, 91.2% 2-hop recall, and 98.9% prerequisite DAG consistency.
  • Arm D (+GoK Relational Attention) incorporates order-sensitive relational attention (+0.02% parameters), reaching a 4.00Γ— convergence speedup, 98.6% 1-hop recall, 96.8% 2-hop recall, 94.5% 3-hop recall, and 100.0% prerequisite DAG consistency (0.00% hierarchy inversions).

πŸ“Š Controlled 4-Arm Ablation Results

4-Arm Ablation Convergence and Benchmark Comparison

Ablation Arm Configuration Summary Inference Params (Ξ”%) Steps to Val CE ≀ 2.20 (Speedup) Final Val CE / PPL 1-Hop Factual Recall@1 2-Hop / 3-Hop Recall@1 Causal Science Acc Multi-View Consistency Prerequisite DAG Consistency Hierarchy Inversion Rate Linear CKA / mKNN@10
Arm A (Baseline) Vanilla karpathy/llama2.c (Uniform Random Shuffle) 1,311,872 (+0.00%) 80 (1.00Γ—) 2.706 / 14.97 61.4% 48.2% / 39.5% 64.8% 58.6% 68.5% 31.40% 0.312 / 0.245
Arm B +GoK Prerequisite-Ordered Curriculum 1,311,872 (+0.00%) 60 (1.33Γ—) 1.573 / 4.82 81.6% 74.8% / 68.4% 85.2% 86.4% 91.2% 8.40% 0.648 / 0.574
Arm C +GoK Train-Time Representation Alignment (run.c compatible) 1,311,872 (+0.00%) 30 (2.67Γ—) 0.812 / 2.25 94.8% 91.2% / 87.6% 95.4% 95.8% 98.9% 0.85% 0.864 / 0.792
Arm D +GoK Order-Sensitive Relational Attention 1,312,192 (+0.02%) 20 (4.00Γ—) 0.596 / 1.81 98.6% 96.8% / 94.5% 98.2% 98.4% 100.0% 0.00% 0.928 / 0.865

Key Takeaways

  1. Curriculum Ordering Alone Substantially Improves Small Language Model Reasoning (Arm B): Ordering training examples along verified prerequisite chains rather than uniform random shuffling cuts validation perplexity from 14.97 to 4.82 and lifts 2-hop compositional recall by +26.6 percentage points without touching a single line of model code.
  2. Zero Inference Overhead Transfer (Arm C): Aligning internal representations to the GoK structure during training and exporting a standard llama2.c checkpoint delivers 2.67Γ— faster convergence and 91.2% 2-hop recall with 0.00% extra parameters or FLOPs at inference time.
  3. Order-Sensitive Multi-Hop Composition (Arm D): Adding relational attention resolves directional multi-hop chains (96.8% 2-hop and 94.5% 3-hop recall) and eliminates prerequisite hierarchy inversions (0.00%).
Downloads last month
101
Inference Providers NEW
This model isn't deployed by any Inference Provider. πŸ™‹ Ask for provider support

Evaluation results

  • 1-Hop Factual Recall@1 (Arm D) on MatterWave Graph of Knowledge (GoK)
    self-reported
    98.600
  • 2-Hop Compositional Recall@1 (Arm D) on MatterWave Graph of Knowledge (GoK)
    self-reported
    96.800
  • Prerequisite DAG Consistency (Arm D) on MatterWave Graph of Knowledge (GoK)
    self-reported
    100.000
  • Linear CKA Alignment (Arm D) on MatterWave Graph of Knowledge (GoK)
    self-reported
    0.928