Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: improved reward system #227

Merged
merged 91 commits into from
Sep 5, 2024
Merged

Conversation

grantdfoster
Copy link
Contributor

@grantdfoster grantdfoster commented Aug 28, 2024

Description

Problem Statement
Currently, our Bittensor subnet's reward system for Twitter data scraping is based solely on whether the provided data is valid or not. This binary approach doesn't incentivize miners to continuously improve the quantity and quality of data they provide. As a result, we may be missing opportunities to gather more valuable data and encourage healthy competition among miners.

Proposed Solution
Implement a more sophisticated reward mechanism that takes into account multiple factors:

Quantity of valid tweets (we should not verify every tweet)
Quality of tweets (this needs thought)
Continuous improvement over time
A kurtosis-based distribution to reward top performers while maintaining broader participation

Notes for Reviewers

Signed commits

  • Yes, I signed my commits.

Copy link

PR description is too short and seems to not fulfill PR template, please fill in

@teslashibe
Copy link
Contributor

teslashibe commented Aug 28, 2024

@grantdfoster added this here:

Refined Initial Solution: v0.8.0 release

Implement a more sophisticated reward mechanism that takes into account multiple factors that rewards higher performing miners:

  1. Quantity of valid tweets as defined by the count returned in a request for the GET Tweets/Posts endpoint.
  2. A validator requests continuous data from miners as a synthetic request job from a centralized queue for now
  3. Organic requests can still be sent to the network through a validator
  4. Round robin miner selection, if a miner returns 429 or no workers eligible, skip to the next miner. Issue here is latency will increase. We will worry about latency later. Set a parameter or constant that we can change for the number of miners selected in the round robin before return, "no miners available to fulfill the request"
  5. Use a static representative JSON comparison using the LLM i.e. comparison >0.50
  6. A kurtosis-based distribution to reward top performers while maintaining broader participation
  7. Generate an Jupyter model showing the curves for the new Kurtosis curve

Next iteration: future release

  1. Think about how similarity check can be compared to a source of truth for 'quality'
  2. Quality of tweets (this needs thought)
  3. Continuous improvement over time

How can miners self-optimize for higher rewards

Miners can work independently to setup private clusters/networks using the Masa Protocol that is configured as its own private network with its their own set of Twitter Scraper Nodes. This allows miners to optimize and grow their capacity on the network which benefits the subnet by rewarding miners that bring the greatest capacity to the network. This capacity is harnessed by validators to scrape static data sets that are ranked by download volume in HF as well as organic requests that are submitted to validator API endpoints by developers who want real time data access.

Screenshot 2024-08-28 at 11 30 51 AM

@teslashibe
Copy link
Contributor

@grantdfoster implementation ticket to track this here: #227

@teslashibe teslashibe linked an issue Aug 28, 2024 that may be closed by this pull request
grantdfoster and others added 25 commits September 3, 2024 17:03
Update the Rewards Simulation notebook to include execution count and outputs,
providing a complete view of the simulation results and enhancing reproducibility.
…tats

- Incorporate real-world miner data for more accurate simulation
- Calculate mean and standard deviation from real data
- Use real-world statistics to generate realistic synthetic dataset
- Adjust number of periods to match real data entries
- Update plotting to show multiple scale factor scenarios
- Add top cryptocurrencies and memecoins
- Include price-specific search terms
- Add relevant hashtags (#memecoin, #defi, etc.)
- Incorporate crypto market and trading terminology
- Add influential crypto personalities using 'from:' operator
- Increase tweet count to 75 for broader coverage

chore(notebook): update Python version to 3.12.4
@teslashibe teslashibe self-requested a review September 5, 2024 02:00
Copy link
Contributor

@teslashibe teslashibe left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Lets go

@grantdfoster grantdfoster merged commit c0d6955 into main Sep 5, 2024
3 checks passed
@grantdfoster grantdfoster deleted the feat--improved-rewards-system branch September 5, 2024 02:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

feat: miner reward updates to kurtosis curve spike: Improve Bittensor Subnet Reward System
3 participants