Skip to content

feat(rewards): allocate OSS emissions by repository emission share#1221

Closed
gazeatcode wants to merge 1 commit into
entrius:testfrom
gazeatcode:feat/issue-1215-emission-share
Closed

feat(rewards): allocate OSS emissions by repository emission share#1221
gazeatcode wants to merge 1 commit into
entrius:testfrom
gazeatcode:feat/issue-1215-emission-share

Conversation

@gazeatcode
Copy link
Copy Markdown

Summary

  • Implements issue Convert per-repo weight from unbounded multiplier to emission_share (bounded pool slice) #1215 with bounded per-repo allocation via emission_share and per-repo PR/issue split via issue_discovery_share.
  • Removes repo weight from per-PR multiplier behavior in active scoring paths (repo multipliers are neutralized to 1.0 and allocation is enforced at emission blending).
  • Collapses top-level emissions to scoring pool + treasury (OSS_EMISSION_SHARE = 0.90, ISSUES_TREASURY_EMISSION_SHARE = 0.10) and routes recycle through allocation-time slack/inactivity behavior.
  • Adds share-bound and sum-bound validation for repository config loading.
  • Migrates master_repositories.json from weight to emission_share and adds issue_discovery_share.
  • Adds allocation and invariant coverage tests.

Related Issues

Closes #1215

Type of Change

  • Bug fix
  • New feature
  • Refactor
  • Documentation
  • Other (describe below)

Testing

  • Tests added/updated
  • Manually tested

Commands run:

uv run pytest tests/validator/test_load_weights.py tests/validator/test_emission_allocation.py tests/validator/oss_contributions/mirror/test_scored_pr.py tests/validator/oss_contributions/mirror/test_scoring.py tests/cli/test_miner_score.py -q
uv run ruff check gittensor/validator/utils/load_weights.py gittensor/validator/forward.py tests/validator/test_load_weights.py tests/validator/test_emission_allocation.py
uv run ruff format --check gittensor/validator/utils/load_weights.py gittensor/validator/forward.py tests/validator/test_load_weights.py tests/validator/test_emission_allocation.py

Checklist

  • Code follows project style guidelines
  • Self-review completed
  • Changes are documented (if applicable)

Context

This PR consolidates and republishes the strongest candidate from prior attempts:

under the gazeatcode fork/account with a single clean commit.

@anderdc
Copy link
Copy Markdown
Collaborator

anderdc commented May 13, 2026

Duplicate of #1219 (identical diff). Closing.

@anderdc anderdc closed this May 13, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

feature Net-new functionality

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Convert per-repo weight from unbounded multiplier to emission_share (bounded pool slice)

2 participants