Hyperparameters

min_allowed_weights

Minimum number of distinct weights a validator must include in one weight submission.

View as Markdown

min_allowed_weights is the floor on how many miners a validator must score in a single weight submission. Subnet owners raise it to force validators to evaluate a broad slice of the miner pool instead of concentrating weight on a favored few; validators care because a submission with too few entries is rejected outright.

How it works

set_weights validates the submission length in check_length (pallets/subtensor/src/subnets/weights.rs). The effective minimum is the smaller of min_allowed_weights and the subnet's current neuron count, so a freshly launched subnet with 5 neurons and a minimum of 50 still accepts 5-entry submissions. Anything below the effective minimum fails with WeightVecLengthIsLow. A single self-weight — one entry naming the validator's own UID — is exempt, as it is from most weight checks.

What counts is the number of weights that actually reach the chain. The SDK quantizes weights to u16 and drops zeros before submitting, then enforces the minimum on what remains — so btcli tx set-weights (the set_weights intent) fails fast client-side with the same rule instead of burning an on-chain submission. Assigning zero to a miner does not help you meet the minimum.

Weight clipping playground

Drag the raw weights: only nonzero entries count toward the length check, so zeroing a miner can push a submission below min_allowed_weights and get it rejected with WeightVecLengthIsLow.

Largest share

55.2% → 30.0%

exceeds limit — clipped

max_weights_limit

19661 / 65535 ≈ 30.0%

u16 fraction; 65535 = no cap

min_allowed_weights

4 nonzero / 3 required

passes length check

80
35
20
10
0
≈ 30%
3

Reading and setting

btcli sudo get --netuid N --name min_allowed_weights

Owner-settable; the value is a plain integer count:

btcli sudo set --netuid N --name min_allowed_weights --value 8