Lunaria - AI-supported low-code architecture with Lua and Go

Lunaria - AI-supported low-code architecture with Lua and Go
By Matthias Petermann / on 17.08.2025

Introduction

Lunaria is not a framework in the classic sense, but a practical learning and prototyping system. The aim is to make modern technologies such as messaging, storage, or web rendering controllable through a simple, human-readable scripting language. The platform combines a Go-based runtime environment with the Lua scripting language – lightweight, expandable and ideal for Experiment.

At the center is the idea:

Complex systems are only truly understood when you can control them yourself - and with minimal barriers to entry.


Architecture and philosophy

Lunaria is based on a clear, modular principle: Go forms the technical foundation – stable, high-performance and safe. Lua serves as Interface for learners, developers or makers that features want to call, combine modules or build small workflows.

Communication between both levels takes place via defined APIs that encapsulate specific task areas:

  • bus – Messaging via ZeroMQ or MQTT
  • config – configuration management and interactive input
  • storage – access to persistent data
  • forms – HTML and template based form logic
  • timer / cron – time-controlled processes
  • log – consistent logging across all modules

This structure makes it possible to turn small Lua scripts into full-fledged ones Build prototypes or learning environments.


The first script: “Hello from Lunaria”

The classic “Hello World” is shown in its simplest form in Lunaria:

-- main.lua
log.info("Hello from Lunaria!")

Behind this one-liner is already the complete interaction with the runtime system. log.info is not a simple console call, but an API function provided directly via the Go engine will.

This means that entry is low-threshold – but technically “real”. This Logging ends up in the central system, which has one for each script execution Creates a session with context information.


Communication via script: The bus system

A central learning goal of Lunaria is the understanding of Messaging. There are the modules bus_pub and bus_sub, which Demonstrate publisher and subscriber logic in pure Lua scripts.

A simple publisher example looks like this:

local cfg = config.expect("APP_", {
  pub_port = { type = "number", default = 5557, prompt = "ZMQ PUB Port" },
  number = { type = "number", required = true, prompt = "How many messages?" }
})

bus.listen(cfg.pub_port)
timer.sleep(1000)

for i = 1, tonumber(cfg.number) do
  bus.publish("example.topic", {
    name = "button",
    event = "click",
    counter = i
  })
  timer.sleep(500)
end

The script interactively queries configurations (config.expect), binds a ZeroMQ publisher and sends structured messages a topic. Everything happens declaratively and comprehensibly – an ideal one Getting started with event-based systems without having to be involved directly Network protocols or message brokers must work.


Forms, flows and interaction

Lunaria is not limited to technical backends. Another one Module allows the definition and control of form logic and User Interactions - ideal for teaching purposes, UI experiments or simple web apps.

An example from forms_flow/main.lua shows a small one Authentication flow:

local USERS = { demo = "secret", alice = "wonderland" }

local login_form = {
  title = "Please log in",
  fields = {
    { label = "Username", name = "username", type = "text", required = true },
    { label = "Password", name = "password", type = "password", required = true }
  },
  buttons = {
    { label = "Login", action = "submit" }
  }
}

These structures are converted into a dynamic environment by the runtime environment HTML interface translated – completely generated by Lua data structures. This is how the separation of logic and representation can be done and directly understand data flow.

Such examples are not finished apps, but didactic ones Tools**: They show how logic gradually evolves from the User interface lets you think down to the system level.


Multi-level proof of concept

Lunaria is not just a platform, but a series coordinated proof-of-concepts:

  1. Abstraction of complex technologies through an easy-to-learn scripting language
  2. Combination of compiled (Go) and interpreted (Lua) code
  3. Integration of generative AI via OpenAI modules
  4. Deploy on alternative platforms like Nomad
  5. Automatic code and documentation generation in the development process

Each of these levels was specifically used to create boundaries between To examine system architecture, learning systems and AI-supported coding.


Conclusion

Lunaria is a structured prototyping system. It combines the pragmatism of a scripting language with the robustness of a modern runtime, creating a learning space in which technology remains understandable.

Whether as a basis for workshops, teaching material or as Proof-of-concept platform for hybrid architectures: Lunaria shows that simplicity and joy of experimentation should be taken seriously are tools for system understanding and innovation.


In short: Lunaria is not a product, but a reliable prototyping base to explain modern technology in a transparent way and evolve it iteratively.


Image credit: The Lua logo is a copyrighted design of the Lua developers at the Pontifical Catholic University of Rio de Janeiro (PUC-Rio). Use in the context of editorial reporting in accordance with the Information on logo use on lua.org.