See How Data Is Changing: The LensVM Transformation

// January 30, 2024

Building decentralized infrastructure means making sure everybody is singing from the same song sheet, even if the sounds of our voices differ.

In database terms, rapidly diverging schemas, versions, and even coding languages quickly create a screeching discordant choir of interoperability that makes entire enterprises - industries even - shudder to a halt. If we can’t understand each other’s data, we can’t get anything done. 

Effective database management, even in centralized terms, is essential to the smooth operation of every type of application. In Web3, where teams work independently and where applications are (supposed to be) sovereign, ensuring data interoperability is key to the creation of a decentralized open internet where things still actually work, and work fast. 

At Source Network, we have supported the creation of LensVM from inception to its current state, realizing how vital data-transformation is to the open web, and believing that without it, all attempts at decentralized databases will simply not work - or not work efficiently at any rate. We are committed, along with an open community of developers, in building out LensVM so that any project can have the chance to finally see the potential of their data clearly.

What is LensVM?

LensVM is an engine that allows data to be transformed from one schema to another and - crucially - back again. This bi-directionalism is essential to create data compatibility in situations where different versions and systems are being used. Legacy data can automatically be transformed into an application’s newer data models, AND new data in the new model can automatically sync up with the legacy model in the all-too-often situation where certain functions rely on that legacy data structure. 

In decentralized environments, where this kind of fractured staccato interoperability is common, this is a life-saver, saving thousands of hours of development time writing specific transformational code or plug-in transformers that inevitably get outmoded over time anyway.

Using LensVM, applications can ensure their data is interoperable to whichever decentralized application they are hooking up to, whichever coding language they are using. As LensVM uses WebAssembly for its runtime, it doesn’t matter if you code in Go, Rust, Javascript, C++ or even AssemblyScript itself, you can use LensVM to migrate your data efficiently and effectively. 

Why LensVM is Great for Developers

Managing hot databases is not easy, even in centralized circumstances. For many teams, the concept of moving their applications data from a centralized to a decentralized format can be overwhelming. It’s easy to go mad worrying about your types and your ints. If the data is actively underpinning core functions of your application, migrating, transforming or updating it can be among the most headache-inducing tasks your project ever has to face. 

LensVM makes that process - if perhaps not easy - then manageable. And, as more developers within the Web3 community use LensVM to craft specific data lenses, the easier it will become. This is because lenses are fully composable with one another, and multiple lenses can operate simultaneously to help migrate data. 

LensVM can modify any JSON object, and it works on them directly. A Lens module is a combination of the lens compiled in WebAssembly, and its associated meta-data - stored as a Content Identified data model. Lens definitions can only do a single transformation, but that transformation can be dependent on preexisting lenses. Each lens does one simple task, and lens files are the main gateway to the LensVM ecosystem. It is through lens files that the basic activity of data transformation is achieved. 

If a specific lens doesn’t exist, a developer can write their own lens and add it, helping others achieve the data structures they require. These Lens can also be written in a language of the developer’s own preference. This process is infinitely scalable, and LensVM itself can scale infinitely. Nothing is stopping LensVM being a throughway for all data to be accessible, clean, and useful to all other applications. 

How LensVM Is Core to the Vision of the Open Web

Over time, LensVM will grow into a ever-expanding kaleidoscope through which all possible colors will abound, a giant community-driven data-transformation matrix where any developer can ensure their data structures seamlessly connect to wider Web3 applications, while never needing to lose sovereignty of that data at any point. 

In this way, the community will organically create the organization and consistency for Web3, and the language of the shared songsheet will be collectively defined, without having to rely on the domineering conducting of a single pastor. Even at that point, applications will be free to create their own data models, and then transform them easily through the Lens virtual machine. This ongoing collective standardization means even newer developers for whom data transformation is arduous and difficult will find it easy to mold their data appropriately.

It’s only through easy multi-platform, multi-language data migration that a truly decentralized web can exist. An idealized open web rests upon everyone being able to operate freely within the language and structures that work for them, without having to constantly integrate with disparate and far-flung teams they have no connection with just to make their project work. LensVM creates a solution for all data structures, both legacy and novel, to be refracted towards a unified, interoperability matrix, and by doing so, give them the freedom to go their own way without compromising their accessibility to a wider decentralized web. 

Stay up to date with latest from Source.

Unsubscribe any time. Privacy Policy