The adoption of Smart Data Models is transforming the way we structure and share data across industries. These models provide a standardized approach to ensure interoperability, scalability, and semantic richness, making them particularly valuable in domains like IoT, Smart Cities, Industry 4.0, and the upcoming 6G networks.

However, creating and maintaining these models can be a daunting task, especially when it comes to generating JSON Schemas that align with Smart Data Models standards led by Fiware, IUDX, Open and Agile Smart Cities and others.

To address this challenge, we are thrilled to introduce our new Smart Data JSON Schema Generator, a new addition to the BESSER platform. This generator is designed to simplify the process of creating JSON Schemas from B-UML models, enabling developers to focus on innovation rather than manual schema creation.

This generator is available directly online via our modeling editorhttps://editor.besser-pearl.org (no install or download of anything required, just click and model!).

At its core, the Smart Data JSON Schema Generator bridges the gap between abstract modeling and practical implementation.

  • By automating the generation of JSON Schemas, it eliminates the need for repetitive, error-prone manual work.
  • More importantly, it ensures that the generated schemas are fully compliant with Smart Data Models standards and NGSI-LD (https://www.etsi.org/committee/cim).

Why a modeling editor and generator for Smart Data Models?

Any new domain where some data has to be published and exchange can benefit from a standard schema for the data that can be agreed upon by everybody to simplify the writing / reading of the data for that domain. As we have said before, this is the key goal of the Smart Data Models initiative.

But until now, there was not graphical editor you could use to define such schema. Nor to define examples that can help adopters to understand the semantics of your schema.

This is the “gap” we are filling.

Key Features

You can use our standard modeling editor to model online your data model (as a class diagram) and examples (as object diagram). Then, our generator will create all the smart data model artifacts you need.

Indeed, the generator comes packed with features that make it a must-have tool for anyone working with Smart Data Models:

  • Automatic Type Mapping: Converts B-UML types (e.g., IntegerType, StringType, DateTimeType) into their corresponding JSON Schema types.
  • Smart Data Enrichment: Adds metadata and descriptions to schemas, linking properties to schema.org (https://schema.org).
  • Example Generation: Automatically creates example files in multiple formats, including JSON, JSON-LD, and NGSI-LD normalized examples.
  • Support for Relationships: Handles associations between classes, representing them as URI references in the schemas.
  • Customizable Templates: Built on Jinja2, the generator allows users to tailor the schema templates to their specific needs.

How It Works

The generator operates in two modes:

  • Regular Mode: Produces standard JSON Schemas for your domain models.
  • Smart Data Mode: Tailored for Smart Data Models, this mode enriches the schemas with additional metadata and generates example files to demonstrate their usage.

An example: a 6G network model

To illustrate with a more advanced use case, let’s assume you’d like to create a new “standard” model to exchange information about the configuration of a 6G network. An obvious choice is proposing a new Smart Data Model that all vendors/ providers / users could adhere to when publishing and exchanging information.

Let’s see the B-UML model for this data model, showing the user equipment (UE), the distributed and centralized Cell units, the Session connectors…

Using the Smart Data JSON Schema Generator in Smart Data Mode, this UML model is automatically transformed into:

  • A schema.json for each class (e.g., UE/schema.json)
  • Example files such as:
  • Example.json (simple key-value)
  • Example-normalized.json (NGSI v2 normalized)
  • Example.jsonld (JSON-LD format)
  • Example-normalized.jsonld (NGSI-LD normalized, ready to use in brokers)

For instance, the generated NGSI-LD normalized example for the UE class could look like this:

{
  "id": "urn:ngsi-ld:UE:UE-001",
  "type": "UE",
  "rnti": {
    "type": "Property",
    "value": "example-rnti"
  },
  "position": {
    "type": "Property",
    "value": 10
  },
  "pdus": {
    "type": "Relationship",
    "object": "urn:ngsi-ld:PDUSESSION:PDUSESSION-01"
  },
  "@context": [
    "https://smartdatamodels.org/context.jsonld"
  ]
}

This means that a telecom 6G model described visually in UML can be directly turned into NGSI-LD compliant data models, drastically reducing the time between design and deployment in real-world systems.

Conclusions

By integrating the Smart Data JSON Schema Generator, we are making it easier for developers to adopt Smart Data Models and contribute to a more connected digital ecosystem. Whether you’re working on IoT applications, smart city projects, or any other data-driven initiative, this generator is designed to simplify your workflow and enhance your productivity.

Try It Today! -> The Smart Data JSON Schema Generator is available now in the latest version of BESSER.

Want to build better software faster?

Want to build better software faster?

Get the latest news in software modeling, model-based and low-code development

Thanks for your interest. Check your inbox and confirm your subscription!

Pin It on Pinterest

Share This