Code Generators

BESSER offers a suite of code generators designed for diverse technologies and purposes. These generators play a pivotal role in translating your model, created using the B-UML Language, into executable code suitable for various applications.

Note

Most generators consume structural models (class diagrams). Some generators require additional model types (GUI, agent, quantum, deployment) as noted below.

Choosing a Generator

Generator

Input Model

Output

Use When

Full Web App

Structural + GUI

ZIP (React + FastAPI)

You want a complete web application with frontend, backend, and database

Django

Structural

ZIP (Django project)

You want a Django admin panel with ORM models

Backend (FastAPI)

Structural

ZIP (FastAPI + SQLAlchemy)

You need only a REST API backend without frontend

REST API

Structural

Python files

You need API endpoints and Pydantic models without database setup

Python

Structural

.py

You need plain Python classes from your model

Pydantic

Structural

.py

You need Pydantic validation models with OCL constraints

Test Cases

Structural

.py (pytest + Hypothesis)

You want an auto-generated pytest + Hypothesis test suite for your model

Java

Structural

.java files

You need Java class files

SQL

Structural

.sql

You need DDL statements for any SQL dialect

SQLAlchemy

Structural

.py

You need SQLAlchemy ORM models

JSON Schema

Structural

.json

You need JSON Schema or Smart Data Models

RDF

Structural

.ttl

You need an RDF vocabulary in Turtle format

React

Structural + GUI

ZIP

You need only the React frontend (no backend)

Flutter

Structural + GUI

ZIP

You need a Flutter mobile application

Terraform

Deployment

ZIP

You need infrastructure-as-code for AWS or GCP

PyTorch

Neural Network

.py

You need a PyTorch neural network

TensorFlow

Neural Network

.py

You need a TensorFlow neural network

Qiskit

Quantum Circuit

.py

You need Qiskit quantum circuit code

BAF Agent

Agent

ZIP

You need a BESSER Agentic Framework conversational agent

BAF Agent (personalized)

Agent + UserDiagram

ZIP

You want a BAF agent adapted to an end-user profile (language, style, accessibility, modality); see Agent Personalization

BPMN

BPMN

.bpmn (XML)

You need vendor-neutral BPMN 2.0 XML readable by every BPMN-aware tool

Docker Compose

Deployment

.yml

You need a docker-compose.yml to run a swarm (deploy.replicas: N from the diagram multiplicity)

Web Application

Generate complete web applications with frontend, backend, and database:

Frameworks & Languages

Generate code for various frameworks and programming languages:

Data & API

Generate database schemas, APIs, and data formats:

Machine Learning

Generate machine learning model code:

Quantum Computing

Generate quantum circuit code:

Agents

Generate conversational agents:

Business Process

Generate BPMN 2.0 XML for any BPMN-aware engine or modeller:

Build Your Own

Create custom code generators: