webbrain-one's picture
Add files using upload-large-folder tool
2b30238 verified
|
Raw History Blame Contribute Delete
2.24 kB
metadata
license: mit
base_model: webbrain-one/WebBrain-RingLoop-16B-A1.4B
library_name: transformers
pipeline_tag: text-generation
tags:
  - webbrain
  - int3
  - 8gb-vram
  - moe
  - looped-transformer

WebBrain-RingLoop-16B-A1.4B-INT3 (<=8 GB VRAM)

Low-VRAM quantized edition of webbrain-one/WebBrain-RingLoop-16B-A1.4B compressed to 7.01 GiB so the full 2-pass looped 16.4B MoE runs natively on 8 GB VRAM consumer GPUs via transformers (trust_remote_code=True).

  • Routed Experts (Layers 1–19, 256 experts): Symmetric Group-64 NF3 (3-bit NormalFloat codebook) (uint8 packed + bfloat16 scale) with active-only chunked unpacking.
  • Embeddings & LM Head: Per-row symmetric INT8 (int8 + bfloat16 scale).
  • Precision-Critical Weights: Attention, routers, shared experts, Layer 0 dense MLP, norms (BF16) and all 10.53M cross-pass looped bridge weights (FP32) kept unquantized.

Verified 8 GB VRAM Parity Benchmarks (dev_80, Greedy, RTX 5090 Measured)

Metric FP8 Reference (phase2_2pass) WebBrain-RingLoop-16B-A1.4B-INT3
Loaded Model VRAM 16.25 GiB 7.01 GiB
Peak VRAM (BS=1, 2-Pass) — 7.31 GiB
Peak VRAM (BS=8, 2-Pass) — 15.10 GiB
dev_80 No-CoT Accuracy 35.00% 35.00%
dev_80 Short-CoT-192 Accuracy 57.50% 50.00%

Quickstart (8 GB GPU)

import torch
from transformers import AutoModelForCausalLM, AutoTokenizer

repo_id = "webbrain-one/WebBrain-RingLoop-16B-A1.4B-INT3"
tok = AutoTokenizer.from_pretrained(repo_id, trust_remote_code=True)
model = AutoModelForCausalLM.from_pretrained(
    repo_id, torch_dtype=torch.bfloat16, device_map={"": "cuda:0"}, trust_remote_code=True
).eval()

prompt = (
    "<role>SYSTEM</role>You are Ring, an assistant created by inclusionAI"
    "<role>HUMAN</role>Find the remainder when 7^100 is divided by 10.<role>ASSISTANT</role><think>\n"
)
inp = tok(prompt, return_tensors="pt", return_token_type_ids=False).to("cuda:0")
out = model.generate(**inp, max_new_tokens=256, do_sample=False)
print(tok.decode(out[0][inp["input_ids"].shape[1]:], skip_special_tokens=True))