BeanstalkFarms/Beanstalk

RFC: On-Chain Fert Metadata

Closed this issue · 1 comments

RFC: On-Chain Fert Metadata

Authors

Brean, Guy, Brendan Sanderson, Ben Weintraub, Deadmanwalking

Summary

Migrate the Fertilizer metadata hosted at fert.bean.money to a decentralized alternative.

Problem

Currently, Fertilizer metadata is currently hosted on centralized infrastructure (this was done in order to Replant Beanstalk in a timely manner). This includes the SVG, the traits, etc. Any data hosted on centralized infrastructure requires maintenance and is subject to downtime.

Context

Fertilizer Metadata repository: https://github.com/BeanstalkFarms/Fertilizer-Metadata

See #120 (h/t @PatrickAlphaC and @silochad) for more information:

Once an hour, a Cloudflare worker triggers a new deployment, which regenerates SVGs and their corresponding webpages, such as this one: 3_500_000.

Some data relevant to each Fertilizer is not available on-chain, or requires regular updating.

  • Season & Humidity are useful info for Farmers who own Fertilizer and want to assess performance of that FERT over time. These currently requires off-chain processing to be derived.
  • The number of Beans per Fertilizer ("BPF") remaining to be paid to a particular Fertilizer changes can change between Seasons when Beanstalk mints more Beans. This piece of metadata is important for Farmers to understand when assessing the value of Fertilizer.
  • The BPF is actually included in the SVG for easy viewing, see here as an example.
    We use a combination of subgraph and Beanstalk contract calls to refresh this information each hour after the Sunrise is called. See here for the relevant metadata generation code, and here for the indexing code used to track transfers of FERT (which is an ERC-1155 token).

We use a combination of subgraph and Beanstalk contract calls to refresh this information each hour after the Sunrise is called. See here for the relevant metadata generation code, and here for the indexing code used to track transfers of FERT (which is an ERC-1155 token).

Solution

TBD! Currently exploring different options for hosting the Fertilizer metadata in a decentralized fashion. This will likely look something like the Silo Deposit metadata deployed in BIP-36.

Specification

TBD.

#802 addresses this issue.