ProductHELM 8Γ: F2 and F4 final checkpoints
Native PyTorch training checkpoints for the Product Lorentz MiCE + TangentAttnRes models, trained from scratch for one full epoch, ending at optimizer update 4372. Each file contains the FP32 model/master tensors, AdamW and RiemannianAdam optimizer states, and both scheduler states. Training used BF16 autocast. Native RNG state is absent.
Files and architecture
| Variant | Checkpoint | Bytes | Total parameters | Active parameters per token (estimate) |
|---|---|---|---|---|
| F2 | producthelm_8x_f2_final.pt |
21,904,416,639 | 1,824,920,468 | 1,532,857,288 |
| F4 | producthelm_8x_f4_final.pt |
17,145,507,291 | 1,428,316,654 | 1,282,269,494 |
Both models have 6 layers, width 3120, 48 heads, vocabulary 128256, and context 2048. The first block has a dense feedforward network; the remaining five blocks use four routed experts, two active experts, and one shared expert. Expert intermediate width is 6240. The Product Lorentz factor count is 2 or 4; each factor has fixed squared radius 1 and curvature β1.
configs/ gives the exact constructor inputs. checkpoint_manifest.json records the source commit, scientific source hashes, tokenizer fingerprint, and checkpoint checksums. SHA256SUMS covers the checkpoints and all companion files.
Original four-corpus evaluation
Token-level perplexity at update 4372; lower is better. Exact values and token counts are in evaluation_results.json and benchmark.csv.
| Variant | WikiText | LAMBADA | C4 | OpenWebText |
|---|---|---|---|---|
| F2 | 34.7708 | 108.8540 | 68.2704 | 50.0823 |
| F4 | 37.6895 | 120.6565 | 73.4507 | 53.8963 |
Scored-token counts are 288,794 / 150,053 / 229,303 / 399,610, respectively. LAMBADA is full-passage next-token perplexity across 2,000 accepted passages. OpenWebText uses the saved first 500 training-split documents. These numbers follow the original project evaluation protocol.
Reconstruct and load
Loading requires the ProductHELM source in the private achiverram28/product-helm-mice-tangentattnres repository. Use model reconstruction/base commit a42aadd7d761a3bd3974c7cc44661f19b4e9a0f6 and its dependencies (requirements-source.txt). Source code is MIT licensed; the source notice is included in SOURCE_NOTICE.txt.
The trained source snapshot additionally generalizes scripts/train_product.sh for 6Γ/8Γ scale selection. Model code, runs.py, and numerical training flags match the base commit. The exact native snapshot hashes are recorded in checkpoint_manifest.json.
git clone https://github.com/achiverram28/product-helm-mice-tangentattnres.git
cd product-helm-mice-tangentattnres
git checkout a42aadd7d761a3bd3974c7cc44661f19b4e9a0f6
Run the following from that checkout. Choose F2 or F4. For a reproducible download, pass the desired Hub commit as revision to hf_hub_download.
import torch
from huggingface_hub import hf_hub_download
from runs import mice_args
from helm.hypercore.manifolds.product_lorentz import ProductLorentz
from helm.modules.product_helm_d import ProductLTransformerDecoder
F = 2 # or 4
repo_id = "zimplex/producthelm-8x-checkpoints"
path = hf_hub_download(repo_id, f"producthelm_8x_f{F}_final.pt")
checkpoint = torch.load(path, map_location="cpu", weights_only=False, mmap=True)
assert checkpoint["global_step"] == 4372
state = {k.removeprefix("module."): v for k, v in checkpoint["model_state_dict"].items()}
assert tuple(state["mapping.weight"].shape) == (128256, 3120)
assert all(tuple(state[f"token_embed.embedding.{i}"].shape) == (128256, 3120 // F) for i in range(F))
model = ProductLTransformerDecoder(
ProductLorentz(1.0, n_factors=F),
ProductLorentz(1.0, n_factors=F),
ProductLorentz(1.0, n_factors=F),
"L6_W3120_A48", 128256, 2048,
residual="tangentattnres", ffn="mice",
moe_args=mice_args("8x"), n_dense_layers=1,
)
model.load_state_dict(state, strict=True)
del state, checkpoint
model.to("cuda").eval()
The decoder returns logits with shape [batch, sequence, 128256]. Preserve the FP32 model for reproducing the reported evaluation. The native checkpoint also contains optimizer_state_dict, scheduler_euc_state_dict, and scheduler_hyp_state_dict; resume training with the original trainer and its two-optimizer setup.
Tokenizer and data
The three bundled tokenizer files come from NousResearch/Meta-Llama-3.1-8B. They preserve the tokenizer used for training. The model was trained from scratch using this vocabulary. Model context is 2048; enforce this limit when using the tokenizer.
from pathlib import Path
from huggingface_hub import snapshot_download
from transformers import AutoTokenizer
assets = Path(snapshot_download(repo_id, allow_patterns=["tokenizer/*"]))
tokenizer = AutoTokenizer.from_pretrained(assets / "tokenizer", use_fast=True, local_files_only=True)
tokenizer.pad_token = tokenizer.eos_token
assert len(tokenizer) == 128256
assert tokenizer.bos_token_id == 128000
assert tokenizer.eos_token_id == tokenizer.pad_token_id == 128001
Tokenizer backend SHA-256: 0303711c1a871dafacf838f2f855bc3608eedf462fb8d265b909c82e9ff3c1dc.
Training dataset: achiverram28/producthelm-wikipedia-tokenized, pinned to 8be3fbb638bc9b473d113173fad8f017c512ce6c. Training recipe: seed 1234, eight processes, 16 accumulation steps per process, global batch 128 sequences, peak learning rate 4e-4, and 3% warmup. See training_recipe.json and the original source commit for the remaining settings.