GroupId | Title | Description | Topics | Authors | ||
---|---|---|---|---|---|---|
ANS-113 |
Related Assets |
This document describes the Related Asset specification for association of assets with a primary asset through tags. |
|
|
Status: Draft
Authors: Jim Toth ([email protected])
This document describes a tagging specification meant to associate related assets published to Arweave.
As the permaweb grows in popularity, complexity, and use there has been a growing need to associate assets as related to a logical asset, work, or publication. One major pain point for many permaweb builders is the large size of data assets. For example, a photographer may wish to publish a high-definition photograph ranging in size from hundreds of megabytes to one or more gigabytes. Another example would be video or 3D model assets that would tax the end user's browser when consuming these assets through aggregation dapps. A standard specification is thus proposed as a way to enhance composability and consumption of assets across the permaweb.
As an added benefit, when appropriate "hint tags" such as Width
and Height
are added to related assets, developers are able to audit this information against HTTP headers of the asset fetch from a gateway. This way, developers are protected against content that may be too large or deny service of their dapp.
This specification unlocks numerous potential use cases of associating related assets:
- Thumbnail/preview asset association to represent primary assets
- Example: A photographer wants to associate smaller, web-friendly versions of large photographs
- Example: A 3D artist wants to associate an animated GIF to act as a thumbnail of their model
- Example: A musician wants to publish in a lossless format and associate a streamable transcoding
- Example: A musician wants to associate album cover art with their audio publications
- Association of related assets
- Example: A musician wants to include audio stems and samples with their song publication
- Example: A digital artist wants to include project files with their publication (e.g. PSDs)
- Summarization/aggregates, manifest extensions
- Example: A data scientist wants to associate an aggregation summary of raw data
- Allow permaweb dapps and users to consume alternate or lighter versions of assets
- Example: A permaweb aggregation dapp developer wants to offer a lighter, more data-usage-friendly feed
- Associate translations with a primary asset
- Example: i18n of text-based content
- Example: Subtitles of videos
- Third party composability
- Example: A 3D artist creates a model that can have a texture applied. The original artist or a third party could publish a texture meant for the model.
- Example: A musician creates a remix of a previously published song.
- Example: Comments, discussion, reviews of assets
In order to associate a related asset to a primary asset, the related asset is tagged with the tag name Related-To
with the value being the transaction of the primary asset.
Additionally, in the interest of developers being able to quickly determine which related assets they are interested in, minimal but powerful "hint tags" could optionally be included. This way, when the primary asset is discovered, developers already have enough information to begin figuring out which related assets they're interested in, minimizing additional queries or parsing of custom manifests.
If relevant, as may be the case of related media assets such as images or video, resolution hints may be provided via Width
and Height
tags. Similarly, translations could include an i18n
tag with value of the language code, like en-us
.
This specification is not meant to be exhaustive or restrictive of optional asset "hint tags". Image/video resolution-based hint tags are included as an example of how hint tags could be utilized where appropriate.
Tag Name | Optional? | Tag Value |
---|---|---|
Related-To |
False | Transaction ID of related asset |
Content-Type |
True | This tag describes the mime type of the body of the transaction. This tag is used by gateways when serving transaction data over HTTP to set the Content-Type header of the HTTP response. From BP-105 |
Width |
True | Hint Tag - Pixel width of content, e.g. 1920 |
Height |
True | Hint Tag - Pixel height of content, e.g. 1080 |
i18n |
True | Hint Tag - Internationalization Translation, e.g. en-us |