This repository was archived by the owner on Aug 3, 2026. It is now read-only.
Feat/ninja commitment - #73
Merged
Merged
Conversation
Port of SN66 Ninja's content-addressed commitment to Ralph. - chain_layer/submission_commitment.py: readable, content-addressed commitment `ralph-submission:<submission_id>:<bundle_sha256>` (one per hotkey). build/parse/verify + canonical submission_id derivation (<hotkey[:16]>-<sha[:16]>) that resists id-spoofing - BittensorChain.commit_submission() (miner) + .verify_submission _commitment_onchain() (validator) — additive, do NOT change the legacy op1 handshake path; op1 cutover is a coordinated follow-up - vs legacy: validator reads WHICH bundle is current straight from chain (no hash reconstruction), and overwrite=update (no nonce race) - 9 tests: content-addressing, overwrite-as-update, anti-spoof, malformed Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
- validator/inflight.py: InFlightGuard — at most one submission per hotkey evaluated at a time; the hotkey can submit again the moment its prior one is scored (NOT Ninja's one-shot). File-backed; claim/release/reconcile. - wire into run_epoch behind RALPH_ONE_IN_FLIGHT=1 (default OFF, so pulling it never changes live behavior): claim at loop top (defer extras), reconcile at epoch start (frees scored/crash-orphaned claims) — one bundle per hotkey per epoch, no per-bundle release needed - bounds validator GPU to <=1 eval/hotkey, kills the overwrite-race, zero tax on honest iterators; pairs with the on-chain set_commitment rate-limit + (future) op1 novelty-rejection for churn - 7 tests: claim/defer/release, idempotent reprocess, restart-persist, reconcile stale claims, corrupt-state safe Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.