๐ผ Allfeat MIDDS
Music Industry Decentralized Data Structures (MIDDS) for the Allfeat blockchain ecosystem.
Overview
MIDDS provides standardized, type-safe data structures for music industry entities with full Substrate runtime compatibility.
Core Entities
| Entity |
Description |
Standard ID |
| Musical Works |
Compositions and songs |
ISWC |
| Party Identifiers |
Artists, labels, publishers |
IPI/ISNI |
| Releases |
Albums, EPs, compilations |
EAN/UPC |
| Tracks |
Individual recordings |
ISRC |
Quick Start
use allfeat_midds::{
party_identifier::Ipi,
musical_work::Iswc,
shared::conversion::Validatable,
};
use std::str::FromStr;
// Create identifiers
let ipi: Ipi = 123456789;
let iswc = Iswc::from_str("T1234567890").unwrap();
// Validate (std feature required)
#[cfg(feature = "std")]
{
assert!(iswc.validate().is_ok());
}
Features
- ๐ Type Safety: Strong typing with validation
- โก Performance: Optimized for on-chain storage
- ๐ Dual Types: SDK and Runtime type separation
- ๐ Standards Compliant: Music industry standards
- ๐งช Benchmarking: Built-in benchmark helpers
Architecture
midds/
โโโ src/
โ โโโ musical_work/ # Musical work data structures
โ โโโ party_identifier/ # Artist/entity identification
โ โโโ release/ # Music release structures
โ โโโ track/ # Track/recording structures
โ โโโ shared/ # Common utilities
โโโ midds-types-codegen/ # Procedural macros
Feature Flags
| Feature |
Description |
Default |
std |
SDK types and validation |
โ
|
js |
WebAssembly bindings |
โ |
runtime-benchmarks |
Benchmark utilities |
โ |
try-runtime |
Try-runtime support |
โ |
Benchmarking
use allfeat_midds::{benchmarking::BenchmarkHelperT, track::Track, Midds};
// Generate test data with varying complexity
let track = <Track as Midds>::BenchmarkHelper::variable_size(0.5);
let min_track = <Track as Midds>::BenchmarkHelper::min_size();
let max_track = <Track as Midds>::BenchmarkHelper::max_size();
Dependencies