Active

Storage Map v101 → current

Whether neurons are active on a subnet .

Explore chain
Queried by: validatorssubnet ownersanalyticsdevelopers

The Big Picture

Not all registered neurons are actively participating. Some may be offline, misconfigured, or abandoned. Active tracks which neurons are currently contributing to the subnet - receiving queries, setting weights, or otherwise participating.

Why This Matters

Is this neuron actually doing anything? Active tells you if they're participating. Inactive neurons take up slots but don't contribute - they're pruning candidates.

Example Scenario

Query Active(netuid=1, uid=47) returns true/false. True means this neuron is actively participating. False suggests they're dormant - not serving, not setting weights.

Common Questions

How is activity determined?
Based on recent actions - serving requests, setting weights, etc. The specific criteria depends on subnet configuration (ActivityCutoff).
Does inactive mean they'll be pruned?
Inactivity contributes to lower pruning scores. Consistently inactive neurons are more likely to be replaced by new registrations.
Can a neuron become active again?
Yes, resume operations and activity status updates. It's not permanent - just reflects recent behavior.

Use Cases

  • Check if a neuron is currently active
  • Filter leaderboards to show only active neurons
  • Calculate subnet utilization rates
  • Identify dormant neurons for pruning consideration
  • Build health dashboards showing active participation

Purpose & Usage

Purpose

Track neuron activity status - identifies neurons currently participating vs dormant.

Common Query Patterns

  • Query by netuid-uid
  • Filter active neurons for analysis
  • Count active vs inactive neurons

Query Keys

#NameTypeDescription
1
key1
u16 key1 (u16)

Stored Value

value (Vec<bool>)

Relationships

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 Active storage
const key1 = 0;

const result = await api.query
  [stringCamelCase("SubtensorModule")]
  [stringCamelCase("Active")](
  key1
);

console.log("Active:", result.toHuman());

On-Chain Activity

Write Frequency
●●●●○○ Medium 100K–1M est. writes

100K–1M estimated writes

#30 most written storage item

Write Source Calls + Hooks

Modified by both user extrinsics and runtime hooks

As of block 7,429,232

Runtime Info

View Source
Pallet
SubtensorModule
Storage Kind
Map
First Version
v101
Current Version
v393