Gonka merged PR #1289 on 2026-06-19, prepared by @a-kuprin, packaging the devshard v2 release (v0.2.13-devshard-v2). Devshard is the off-chain subsystem that coordinates AI inference outside the main chain. This is the first time it ships on its own upgrade track, independent of a full chain upgrade. The change touches 375 files (+39,191 / -5,184 lines).
What changed
The release introduces a devshard-only upgrade path. Instead of bundling devshard changes into a chain upgrade, a governance proposal registers the new devshardd binary in DevshardEscrowParams.approved_versions with a name, download URL, and sha256 hash. If the vote passes, versiond downloads the binary and serves it under the /devshard/v2 prefix, where v2 runs in parallel with v1 until gateways move primary traffic over. No manual host steps are expected during this kind of upgrade.
On the storage side, the runtime now prunes old epoch data on epoch changes, selects exactly one backend (SQLite or Postgres) per process, and moves schema setup out of hot request paths. The seed reveal round was removed, completed inference stats are sealed, and served payloads are pruned so a long-running session no longer keeps every inference it served in RAM or in state.
Other concrete changes landed in the same PR: stale MsgFinishInference transactions are re-gossiped so another host's sequencer can pick them up; a governance-controlled maximum nonce limit is enforced on hosts before settlement; session fees are snapshotted from on-chain escrow (create_devshard_fee, fee_per_nonce) instead of hardcoded values; and per-inference validation counters move outside the state root into SQLite/Postgres, with per-slot totals exposed through devshard stats endpoints. The release also adds OpenTelemetry traces and Prometheus metrics across devshard, the decentralized API, and the inference chain, plus a Grafana / Jaeger / Loki / Prometheus observability stack in deploy.
Why it matters
Separating devshard upgrades from chain upgrades means the inference layer can ship fixes and features without waiting for a coordinated network-wide chain upgrade, and without manual host intervention. The parallel v1/v2 model lets contributors test v2 before any real traffic depends on it.
The pruning and payload-sealing work removes a class of slow memory and state growth on long-running sessions. Before this, a host serving many inferences would keep accumulating them in memory and state. Moving session timeouts, fees, validation rates, and grace periods into governance-controlled DevshardEscrowParams means these values can change by vote rather than by a code release.
Tradeoffs and follow-ups
The decentralized-api and inference-chain changes are backward and wire compatible and do not need to be activated before the next mainnet release. The settlement message proto renames its version field to state_root_and_protocol_version, separating the devshard runtime version from the state-root protocol version, which is now stamped at build time.