srt-adapter-gptoss20b โ€” SRT read-out + closed-loop adapter for gpt-oss-20b

๐Ÿ”ฌ Live demo: RiverRider/srt-nla-gptoss20b-trace โ€” full inputโ†’output hidden-state trace, magic-number state grid, A/B state-identity compare.

A 12.7M-parameter side-channel adapter on a fully frozen openai/gpt-oss-20b (MXFP4 MoE, 24 layers). It taps the residual stream between the frozen decoder layers and exposes a calibrated introspection channel: discourse-community assignment, regime classification, interpretant-divergence vectors, a bifurcation order-parameter rฬ‚, and a divergence-chain prediction. Trained in combined Phase A+B mode: the read-out heads and the closed-loop RRM injection (inject-CE through the frozen backbone) train in one run.

TL;DR: regime monitoring is essentially perfectly calibrated (ECE 0.0009, AUROC 0.974 on 510K held-out tokens). rฬ‚ tracks the ground-truth order parameter at Pearson 0.69 (under-predicts magnitude; an affine rescale fixes the scale, as on every prior backbone). Community NMI 0.42 is the soft spot. Frame this as a monitoring channel, not a capability lift.

Held-out probe (3,000 val passages, 510,777 tokens)

Signal Metric Value
Regime ECE 0.0009
Regime Brier 0.0152
Regime AUROC 0.9742 (base rate 0.9455)
rฬ‚ (bifurcation) Pearson 0.6894 (pred 0.569 / true 1.027 โ€” affine-rescalable)
rฬ‚ MAE 0.6156
Community NMI / ARI 0.4226 / 0.1347 (n=3000, 35 ids, k=64)
Divergence norms L6 / L12 / L18 20.7 / 30.0 / 29.0 (non-degenerate)

Raw probe output ships as phaseAB_probe.json.

Architecture / training

Backbone (frozen) openai/gpt-oss-20b, MXFP4, 24 layers, d=2880, 12/24 sliding-window layers
Taps MAH @ L6, L12, L18 ยท community @ L3 ยท RRM inject @ L12, L18
Trainable params 12,713,923 (backbone: 1.8B frozen)
Mode Phase A+B: read-out heads + inject-CE (gradient flows through frozen MXFP4 experts โ€” verified differentiable)
Data 1M labeled discourse passages (community ids, per-token r_true, chain labels). Corpus not redistributable (Reddit terms); schema + rebuild recipe in the SRT repo.
Recipe bs=8, lr=1e-4, warmup 1000, val every 2000; best val at step ~18K
Backbone-scale fix gpt-oss residual scale is ~10ร— Qwen's (div-std โ‰ˆ 26 vs 1โ€“3). Divergence-magnitude losses were rescaled: chain_weight 0.5โ†’0.05, divergence_supcon 1.0โ†’0.1, bif_weight 1.0โ†’0.5. Without this the val loss climbs after warmup.

The adapter autodetects gpt-oss's alternating sliding-window/full attention (config.layer_types) and builds explicit per-layer masks โ€” forward is bit-exact vs the HF reference (max|diff| = 0.0 in the port smoke).

How to load

import torch
from huggingface_hub import hf_hub_download
from srt.config import SRTConfig
from srt.adapter import SRTAdapter   # pip install "srt-adapter @ git+https://github.com/space-bacon/SRT.git"

cfg = SRTConfig(backbone_id="openai/gpt-oss-20b", backbone_dtype="bfloat16")
adapter = SRTAdapter(cfg).to("cuda")   # resolves MAH@[6,12,18], inject@[12,18], community@3
sd = torch.load(hf_hub_download("RiverRider/srt-adapter-gptoss20b", "best_adapter.pt"),
                map_location="cuda", weights_only=False)
adapter.load_adapter_weights(sd) if hasattr(adapter, "load_adapter_weights") else \
    adapter.load_state_dict(sd, strict=False)

Requires transformers>=4.55,<5 (gpt_oss support), accelerate, and โ€” for native MXFP4 โ€” recent triton + the kernels package (otherwise transformers dequantizes to bf16, ~40 GB).

Honest caveat

SRT's validated value is read-out / monitoring. On prior backbones the closed-loop injection did not improve task accuracy; the pre-registered, replicated finding is that low divergence predicts wrong answers. Use this as a calibrated introspection channel on a frozen open reasoning model, not as a way to make gpt-oss answer better.

Siblings

  • RiverRider/srt-nla-av-gptoss20b โ€” activation verbalizer (see its card for the honest K-curve)
  • RiverRider/srt-nla-gptoss20b-artifacts โ€” NLA pairs, VQ state codebook, anchors, K-curve
Downloads last month

-

Downloads are not tracked for this model. How to track
Inference Providers NEW
This model isn't deployed by any Inference Provider. ๐Ÿ™‹ Ask for provider support

Model tree for RiverRider/srt-adapter-gptoss20b

Adapter
(258)
this model

Space using RiverRider/srt-adapter-gptoss20b 1