Upper limit on registration difficulty .
Current Value
4611686018427387903Relevant for: minersvalidatorssubnet ownersdevelopers
The Big Picture
Difficulty adjusts with demand, but this constant caps how high it can go. Without a ceiling, extremely popular subnets could have astronomical difficulty, making POW registration practically impossible (days or weeks of computation). The cap ensures POW remains a viable registration path even on popular subnets.
Why This Matters
This tells you the worst-case POW difficulty. Even on the most popular subnet, difficulty won't exceed this. You can calculate maximum registration time.
Example
If MaxDifficulty is 10^12, that's the hardest POW can get. A GPU doing 100M hashes/second would take ~10,000 seconds (~2.7 hours) worst case. If burn is 10 TAO and you value your time, you might choose burn.
Common Questions
- What happens if demand would push difficulty above max?
- Difficulty stays at max. More people attempting registration means more competition for slots, but each individual's POW time is capped.
- Can subnet owners lower the max difficulty?
- Yes, within network limits. Lower max makes POW more accessible but may increase registration spam.
Use Cases
- POW registration
- Difficulty limits
Code Examples
import { ApiPromise, WsProvider } from "@polkadot/api";
import { stringCamelCase } from "@polkadot/util";
const provider = new WsProvider("wss://entrypoint-finney.opentensor.ai:443");
const api = await ApiPromise.create({ provider });
// Query InitialMaxDifficulty constant
const value = api.consts[stringCamelCase("SubtensorModule")][stringCamelCase("InitialMaxDifficulty")];
console.log("InitialMaxDifficulty:", value.toHuman());
// Convert RAO to TAO if this is a balance value
const taoValue = value.toBigInt() / BigInt(1e9);
console.log("TAO:", taoValue.toString());Type Information
- Type
- u64
- Byte Size
- 8 bytes
- Encoding
- fixed
- Raw Hex
- 0xffffffffffffff3f
Runtime Info
- Pallet
- SubtensorModule
- First Version
- v101
- Latest Version
- v101
- Current Runtime
- v393