Introduce Vibe Metadata v1: Smart Properties

1. Introduction

The emergence of non-fungible tokens (NFTs) has revolutionized the digital assets landscape by providing unique ownership and provenance for various digital items. The traditional ERC721 NFT standard has helped bridge static details into the digital realm, but has been restrictive in introducing interactivity and customization. While the ERC721 and ERC1155 standards have laid a robust foundation for representing ownership of unique assets on the blockchain, the static nature of their metadata has posed limitations for use cases that require a dynamic approach. Smart Properties V1 comes into play by offering a solution to this challenge by proposing a schema that builds transparency and calculability into the existing standards. The following sections explains the components that
make up the dynanism that Smart Properties provide.

2. Vibe Metadata V1: Smart Properties Format and Implementations

With Metadata Standards likes ERC721 and ERC1155 commonly found on OpenSea, attributes largely remain static. Vibe Metadata v1 introduces a way to dynamically update properties of your NFTs so that they can evolved over time.conditions are defined to describe which properties should be updated, when, and how.

Both ERC721 and ERC1155 NFTs support the properties format. This field allows you to specify custom attributes that your NFT can display or contain. Here’s an example of the properties field:

{
  "properties": {
    "levels": {
      "type": "integer",
      "description": "The level for the NFT",
      "value": 1
    },
    "ranking": {
      "type": "string",
      "description": "The ranking for the NFT",
      "value": "bronze"
    }
  }
}

2.1 Conditions

The conditions field allows you to define a set of rules that can be run on the existing metadata properties.
With conditions, your metadata can react to its own properties and make updates to their values. In this example, the condition is tracking the loyalty points rule engine template.

If holding days is more than 30 days, then update the attribute loyalty points by 10.

{
  "properties": [
    {
      "level": [
        {
          "name": "level",
          "type": "number",
          "description": "The level of the NFT",
          "value": 1
        }
      ]
    },
    {
      "rarity": [
        {
          "name": "rarity",
          "type": "string",
          "description": "The rarity of the NFT",
          "value": "common"
        }
      ]
    }
  ],
  "conditions": {
    "rules": [
      {
        "property": "level",
        "rule": "greater_than",
        "value": 5,
        "update": [
          {
            "property": "rarity",
            "value": "rare"
          }
        ]
      }
    ]
  }
}

2.2 Rules

The following different types of rules are supported.

greater_than

The greater_than rule allows you to compare against a numerical properties to check if the property exceeds the rule's value.

{
  "properties": {
    "level": {
      "name": "level",
      "type": "number",
      "description": "The level of the NFT",
      "value": 1
    },
    "rarity": {
      "name": "rarity",
      "type": "string",
      "description": "The rarity of the NFT",
      "value": "common"
    }
  },
  "conditions": {
    "rules": [
      {
        "property": "level",
        "rule": "greater_than",
        "value": 5,
        "update": [
          {
            "property": "rarity",
            "value": "rare"
          }
        ]
      }
    ]
  }
}

In this example, the rarity property will now be updated to the value of rare.

less_than

The less_than rule allows you to compare against a numerical properties to check if the property is below the rule's value.

{
  "properties": {
    "level": {
      "name": "level",
      "type": "number",
      "description": "The level of the NFT",
      "value": 1
    },
    "rarity": {
      "name": "rarity",
      "type": "string",
      "description": "The rarity of the NFT",
      "value": "common"
    }
  },
  "conditions": {
    "rules": [
      {
        "property": "level",
        "rule": "less_than",
        "value": 5,
        "update": [
          {
            "property": "rarity",
            "value": "basic"
          }
        ]
      }
    ]
  }
}

In this example, the rarity property will now be updated to the value of basic.

equal

The equal rule allows you to compare against a numerical properties to check if the property is equal the rule's value.

{
  "properties": {
    "level": {
      "name": "level",
      "type": "number",
      "description": "The level of the NFT",
      "value": 1
    },
    "rarity": {
      "name": "rarity",
      "type": "string",
      "description": "The rarity of the NFT",
      "value": "common"
    }
  },
  "conditions": {
    "rules": [
      {
        "property": "level",
        "rule": "equal",
        "value": 1,
        "update": [
          {
            "property": "rarity",
            "value": "basic"
          }
        ]
      }
    ]
  }
}

In this example, the rarity property will now be updated to the value of basic.

match

The match rule allows you to compare against a numerical properties to check if the property partially matches the rule's value.

{
  "properties": {
    "level": {
      "name": "level",
      "type": "number",
      "description": "The level of the NFT",
      "value": 1
    },
    "rarity": {
      "name": "rarity",
      "type": "string",
      "description": "The rarity of the NFT",
      "value": "Silver Cat"
    }
  },
  "conditions": {
    "rules": [
      {
        "property": "rarity",
        "rule": "match",
        "value": "Silver",
        "update": [
          {
            "property": "level",
            "value": 10
          }
        ]
      }
    ]
  }
}

In this example, the level property will now be updated to the value of 10.

exists

The exists rule allows you to compare against a numerical properties to check if the property exists in the metadata.

{
  "properties": {
    "level": {
      "name": "level",
      "type": "number",
      "description": "The level of the NFT",
      "value": 1
    },
    "rarity": {
      "name": "rarity",
      "type": "string",
      "description": "The rarity of the NFT",
      "value": "Silver Cat"
    }
  },
  "conditions": {
    "rules": [
      {
        "property": "rarity",
        "rule": "exists",
        "update": [
          {
            "property": "level",
            "value": 10
          }
        ]
      }
    ]
  }
}

In this example, the level property will now be updated to the value of 10.

absent

The absent rule allows you to compare against a numerical properties to check if the property is absent in the metadata.

{
  "properties": {
    "level": {
      "name": "level",
      "type": "number",
      "description": "The level of the NFT",
      "value": 1
    },
    "rarity": {
      "name": "rarity",
      "type": "string",
      "description": "The rarity of the NFT",
      "value": "Silver Cat"
    }
  },
  "conditions": {
    "rules": [
      {
        "property": "ranking",
        "rule": "absent",
        "update": [
          {
            "property": "level",
            "value": 1
          }
        ]
      }
    ]
  }
}

In this example, the level property will now be updated to the value of 1.

2.3 Conditional Operators

In the section "Conditional Operators," the and and or operators are introduced as tools to create compound conditions for multiple rules. The and operator connects conditions that all need to be fulfilled, while the or operator connects conditions where either needs to be fulfilled. These operators can be used to create complex conditions and updates for NFT metadata.

🚧 and

To specify conditions that all need to be fulfilled, we can use the and operator to join them together.

{
  "properties": [
    {
      "level": [
        {
          "name": "level",
          "type": "number",
          "description": "The level of the NFT",
          "value": 1
        }
      ]
    },
    {
      "rarity": [
        {
          "name": "rarity",
          "type": "string",
          "description": "The rarity of the NFT",
          "value": "Silver Cat"
        }
      ]
    }
  ],
  "conditions": {
    "operator": "and"
    "rules": [
      {
        "property": "ranking",
        "rule": "absent",
        "update": [
          {
            "property": "level",
            "value": 1
          }
        ]
      },
      {
        "property": "rarity",
        "rule": "equal",
        "value": "Silver Cat",
        "update": [
          {
            "property": "level",
            "value": 10
          }
        ]
      }
    ]
  }
}

In the case above, if the ranking is absent and the rarity is Silver Cat, the updates will occur in the following order:

  • level will be updated to 1.
  • level will then be updated to 10.
🚧 or

To specify conditions where either needs to be fulfilled, we can use the or operator to join them together.

In the case below, if either case is fulfilled, the updates will occur. The property ranking is absent so the level will be updated to 1.

{
  "properties": [
    {
      "level": [
        {
          "name": "level",
          "type": "number",
          "description": "The level of the NFT",
          "value": 1
        }
      ]
    },
    {
      "rarity": [
        {
          "name": "rarity",
          "type": "string",
          "description": "The rarity of the NFT",
          "value": "Silver Cat"
        }
      ]
    }
  ],
  "conditions": {
    "operator": "or"
    "rules": [
      {
        "property": "ranking",
        "rule": "absent",
        "update": [
          {
            "property": "level",
            "value": 1
          }
        ]
      },
      {
        "property": "rarity",
        "rule": "equal",
        "value": "Blue Cat",
        "update": [
          {
            "property": "level",
            "value": 10
          }
        ]
      }
    ]
  }
}

2.4 Triggers

Triggers enable the execution of rules defined in conditions. At a fundamental level, this entails setting a recurring schedule for evaluating these conditions. When rules are triggered, the NFT metadata is integrated into the UA flow.

2.5 Schedule

Vibe Metadata attributes can be set to interact based on a schedule, with specified starting time, ending time, or a recurring frequency.
For this scenario, the rules are activated on a regular schedule, starting on 2021-01-01 and ending on 2021-01-03.
Please note the last_updated field, which is a meta field that displays the last time the NFT conditions were run, as defined by the metadata evaluator.

{
  "conditions": [
    {
      "operator": "and",
      "rules": [
        {
          "property": "level",
          "rule": "greater_than",
          "value": 1
        },
        {
          "property": "rarity",
          "rule": "equal",
          "value": "Silver Cat",
          "update": {
            "property": "level",
            "value": 2
          }
        }
      ],
      "trigger": [
        {
          "last_updated_at": "2021-01-01T00:00:00Z"
        },
        {
          "type": "schedule",
          "config": {
            "start": "2021-01-01T00:00:00Z",
            "end": "2021-01-03T00:00:00Z"
          }
        }
      ]
    }
  ]
}

3. Rule Engines

Rule engines are interactive conditions of NFTs that execute continuous upgrade and automation (UA) flows. The logic can be defined through the Vibe platform by developers, third party integrations, or community creatives. Rule engines can modify NFT metadata parameters autonomously, adding new features and functionalities to transform static NFTs into fully-fledged applications or products. Example functionalities include:

  • Increasing an NFT’s loyalty points as it’s held over time
  • Advancing an NFT’s levels based on liquidity provided on a DEX like Uniswap
  • Unlocking new access with longer listening times on third party platforms like Spotify

All rule engines will be available to implement via no-code for creatives to build the most dynamic and smart NFTs, empowering their brands and communities. We also envision developers to augment the the Vibe Open Library with custom rule engines to better support creatives.

4. Vibe Metadata Rendering Library

Vibe Metadata Rendering Library is a software tool and framework designed to streamline the process of generating and displaying metadata associated with NFT built on top of Smart Properties.

The primary purpose of Vibe Metadata Rendering Library is to facilitate integration and presentation of metadata within various applications, platforms, or marketplaces.

Key Features and Functionality:

  1. Metadata Generation: The library allows content creators, publishers, or administrators to input relevant metadata associated with digital assets. It may offer a user-friendly interface or API for data entry and validation.
  2. Formatting and Structuring: The library ensures that metadata is formatted correctly and adheres to predefined standards or schemas, ensuring consistency and accuracy.
  3. Dynamic Rendering: It provides the capability to dynamically render metadata in different formats, such as HTML, JSON, XML, or custom formats, based on the specific requirements of the application or platform.
  4. Customization: Users can often customize the appearance and layout of metadata elements to suit their branding or design preferences.
  5. Localization: For global applications, the library may support multiple languages and provide localization options to display metadata in the user's preferred language.
  6. Integration: The metadata rendering library can integrate with other software systems, databases, or APIs to retrieve and display metadata from external sources.
  7. Search Engine Optimization (SEO): In web applications, the library may offer SEO-friendly features, such as metadata tags, to improve the visibility and searchability of digital content on search engines.
  8. Versioning and History: Some libraries may include versioning capabilities, allowing users to track changes in metadata over time.

Benefits:

  1. Time-Saving: The library automates the process of metadata generation and rendering, reducing manual efforts and potential errors.

Consistency: By enforcing standardized formats and structures, the library ensures consistent and uniform display of metadata across various applications and platforms.

  1. Improved User Experience: Well-rendered metadata enhances the overall user experience by providing users with clear and relevant information about digital content.
  2. Enhanced Discoverability: Properly formatted metadata, especially in web applications, improves the chances of content being discovered and indexed by search engines.
  3. Scalability: For applications dealing with a large volume of digital assets, the metadata rendering library can handle the scaling requirements efficiently.

Overall, the metadata rendering library plays a vital role in optimizing the management and presentation of metadata, empowering content creators and administrators to effectively showcase their digital assets to the target audience.

5. Use Cases and Demonstrations

Vibe Platform Data Layer
Smart Properties framework can leverage Vibe's platform data, built with Vibe's own rule engine microservices. The initial rule engines are designed indexing insights from sale volume to customer insights, enabling gamified experiences of NFT upgradability.

Introductory use cases:

  • For every 1 week of holding the NFT, property loyalty points upgrades by 10.
  • If loyalty points are more than 50, then upgrade property level from basic to advanced.

Onchain Data Layer
Onchain data represents a decentralized repository information and insights, and will be a key integration to the Smart Properties framework. Through rule engines, specific conditions are executed using on-chain parameters. This enables NFTs to respond dynamically to real-time onchain interactions and events.

Introductory use cases:

  • For every $100,000 liquidity provided on Uniswap, attribute level upgrades to legendary
  • For every week your health factor on Aave maintains above 2, attribute health rate increases by 10.

Offchain Data Layer
Beyond on-chain open data, Smart Properties framework will also enable integration with third party services and applications like Spotify, Amazon, Twitter, and more.

Introductory use cases:

  • With the integration of an offchain data layer and Spotify's API, we can create a dynamic music NFT that responds to the user's music preferences and listening habits. For every 1000 stream of the song on Spotify, attribute engagement points multiplies by 10.

6. Smart Properties Trigger Architecture

Conclusion

Programmability of NFTs will unlock the true potential of digital assets. We envision Smart Properties activating many more use cases, asset classes, and liquidity into the space.

We are building open-source protocol and infrastructure. If you are excited about contributing, please reach out to engineering@vibe.xyz.

Join our working group to explore current developments in the pipeline
Apply to join our core team

See you on GitHub

Subscribe to vibe.xyz

Don’t miss out on the latest issues. Sign up now to get access to the library of members-only issues.
jamie@example.com
Subscribe