On-premise data and software modeling

Model your systems
on your own servers

Bluetong is a modeling tool for drawing and editing ERD, REST API, sequence and architecture (C4) diagrams in a web browser and in a native macOS app. The server is installed inside your company, so models, edit history and conversations with AI stay on your servers. Databases your AI builds show up as ERDs people can see at once, and AI and people โ€” and people and people โ€” shape one model together.

Web app ยท macOS app ยท iPad and iPhone apps in testing ยท 10 languages ยท Server: Java 21 ยท Tomcat 11 ยท PostgreSQL 17 ยท Levelupsoft Inc.

A cute blue elephant at a desk drawing a diagram with a pen, next to a stack of books labelled UML, BPMN and ERD
Blueprint + Tong = Bluetong
Bluetongโ€™s blueprint studio
Web ยท macOS ยท iPad
The same features everywhere โ€” the browser, a native Mac app and an iPad app (in testing)
PostgreSQL ยท Oracle ยท MySQL
DDL export and import, and import straight from a live database
In-house AI
Point it at Ollama or any OpenAI-compatible endpoint you choose
The Bluetong web app: a diagram list on the left and, in the middle, an ERD of member, address, product, order, order item, product option, payment and delivery tables joined by relationship lines. Table and column names are shown as their comments

The screenshots show the app in English. The shopping-mall model is a made-up example.

Why on-premise

A data model is the blueprint of how a company works

Tables, columns and relationships spell out how your business runs. Bluetong keeps that blueprint on servers you own, lets many people edit it together, and lets AI help โ€” inside your company.

01

Models stay on your servers

The server runs on your hardware; models, edit history, sharing records and AI chat history are stored in your PostgreSQL. Every edit is saved to the server, so nobody passes files around to keep versions in step.

02

Use AI without sending data out

AI chat only calls the AI endpoints registered on your server. Connect an Ollama you run in-house and diagram content never leaves your network. Without any AI, every editing feature still works.

03

Your company controls access and records

Only invited people can sign up, and administrators decide who the members are and which AI they may use. Sign-ins, shares and deletions are kept as an audit log in your own database.

AI, people and team, working together

Check the database your AI built while developing โ€” right away

Tables a coding AI creates while writing code end up scattered across migration files and the development database, and people struggle to follow what appeared. Bluetong shows them at once as an ERD with its relationship lines. People check and correct quickly, and the AI reads back the model people refined to carry on developing. AI and people โ€” and people and people โ€” work on one model.

  1. 1

    The AI draws it

    When a coding AI draws with the MCP tools โ€” tables (add_tables, change_tables), and now sequences (add_sequence), REST APIs (add_rest_api) and architecture (add_architecture) too โ€” it appears on the spot for everyone with that diagram open.

  2. 2

    Bring in the DDL it wrote

    A migrationโ€™s CREATE TABLE statements go into the diagram with one command โ€” bluetong apply <project> <diagram> --ddl schema.sql

  3. 3

    Straight from the dev database

    โ€œImport from databaseโ€ reads the tables the AIโ€™s code created in your development database (PostgreSQL, MySQL, Oracle) and turns them into an ERD.

  4. 4

    Tidy it and review

    One auto arrange puts referenced tables on top and lines at right angles โ€” see what appeared at a glance and fix it right there.

How AI and people work together: an AI agent creates or changes tables through MCP or the command line; the Bluetong server checks its permissions, saves the change and sends it at once, as an ERD, to person A (web) and person B (macOS app) who have the diagram open. Their edits go to the same server, and the AI reads back the model as people left it AI agentcoding AI ยท MCP ยท CLIAPI key (read / edit scope) Bluetong serverpermissions ยท save ยท orderaudit log Person Aweb ยท reviews the ERD Person BmacOS app ยท names, comments create ยท change tables read the model now live โ€” straight to the ERD peopleโ€™s edits

About the picture

  • The solid orange line is the AI agentโ€™s edit: a coding AI creates or changes tables, columns and relationships with the MCP tools (add_tables, change_tables) or the command line.
  • The server checks permissions. The AI comes in with an API key a member made, and edits only within that keyโ€™s scope (read only or edit, and the projects it may use).
  • The dashed blue lines are live delivery: tables the AI creates appear at once, as an ERD, on the screens of everyone with that diagram open.
  • The solid grey line is peopleโ€™s edits. Several people can refine the model at once; the server sets the order so every screen ends up the same.
  • The dashed orange line is the AI reading the current model back (describe_diagram), so the names, comments and relationships people refined are what it builds on next.

AI writes, people see

What the AI created shows up as an ERD with its relationship lines, not as SQL text. Tidy it with auto arrange (arrange_diagram) and review what changed at a glance.

People refine, the AI reads it back

When people refine names, comments and relationships, the AI reads the current model and uses it for the next code and SQL. One model becomes the agreement between the AI and the team.

Permissions and records for AI too

AI agents come in only with API keys. Each key is read only or may edit, can be limited to some projects, and can be revoked at any time. In-app AI chat changes nothing until a person presses โ€œApplyโ€.

# keys per repository โ€” keep an API key made on the web or app as an account (asked hidden, not in shell history)
$ bluetong account add --name shop --server https://modeling.example.com --key-stdin
# link that account in the repository folder โ€” AI tools and commands there and below use this key
$ bluetong link . shop

# no key in the AI tool โ€” it uses the account linked to each folder (a read-only key works too)
{
  "mcpServers": {
    "bluetong": { "command": "bluetong", "args": ["mcp"] }
  }
}
# Claude Code in one line: claude mcp add bluetong -s user -- ~/.local/bin/bluetong mcp
# tools: whoami ยท list_projects ยท create_project ยท list_diagrams ยท add_diagram ยท rename_diagram ยท
#   describe_diagram ยท add_tables ยท change_tables ยท add_sequence ยท add_rest_api ยท add_architecture ยท add_state ยท
#   arrange_diagram ยท edit_diagram ยท export_ddl ยท export_openapi ยท delete_diagram ยท delete_elements ยท delete_model ยท trash_project
#   project_history ยท restore_revision ยท name_version

Features

Everything modeling needs, in one place

From drawing the diagram to exporting SQL and API documents โ€” without switching tools.

ERD

Pick tables, views, 1:1, 1:N and M:N relationships, DB sequences, stored procedures, triggers, generalization and notes from the notation palette. Column rows carry PK, FK, unique (U) and index marks, and a โ€œCommentsโ€ view shows column comments in place of names.

REST API diagrams

Draw REST resources (method, URI, summary) with their request and response bodies and the classes those bodies refer to, on one diagram. Import a Swagger (OpenAPI) document straight into a diagram, and export the diagram you refined back to Swagger. Edit class attributes and operations in place.

Sequence diagrams

Lifelines, messages, return, create and recursive messages, and combined fragments such as alt and loop with their guards.

Architecture (C4) NEW

System landscape, context, container, component, dynamic and deployment diagrams. Draw people, software systems, containers (database and message-queue shapes), components, groups and deployment nodes with their relationships (and technology); drop an element at a boundaryโ€™s edge and the boundary grows to fit. Paste the same element from another diagram to keep one model.

API docs NEW

See a REST API diagram as OpenAPI YAML (with line numbers) beside a Swagger-like page. Edit the YAML and โ€œApplyโ€ changes the diagram. Press an operation on the page to jump to its YAML lines, or a YAML line to jump to its operation. Three layouts: YAML only, side by side, docs only.

Format ยท same size NEW

โ€œFormatโ€ for the chosen shapes and lines sets the background, line color, weight and style (22 kinds), and the font size, bold, italic and text color. โ€œSame Width and Heightโ€ (or width or height only) makes the chosen shapes as wide and tall as the first one you chose.

Editing that fits the hand

Drag relationship lines to bend them and square them up, right-click menus, column and attribute editing in the inspector, undo and redo, copy, paste and duplicate, renaming and deleting diagrams.

Auto arrange

Re-routes tangled relationship lines at right angles around the tables and spreads lines that share a gap so they never overlap. If you like, it lays out the tables too. Computed on the server โ€” no AI involved.

SQL

DDL for PostgreSQL (the default), Oracle and MySQL, plus CRUD SQL. Import DDL from pg_dump, mysqldump or Oracle, or connect to a live database and reverse-engineer it. ALTER TABLE โ€ฆ FOREIGN KEY between tables already drawn becomes a relationship line too. SQL is syntax-highlighted.

OpenAPI ยท Swagger

Import an OpenAPI 3 or Swagger 2 document and it becomes a REST API diagram; export the diagram as an OpenAPI document (YAML or JSON). API design and documentation come from one model.

3D view

Walk around a table and the tables that refer to it on a carousel, or stack several ERDs as floors in 3D with their relationship lines. Cards can look like glass.

File management

Put your own tags on server files, then search by tag and sort. Deleted files wait in a trash for a set period (7 days by default), which you change on the settings screen. Recent files and favorites are kept per account on the server, the same on the web, Mac and iPad.

ERwin import

Open ERwin files (.erwin) directly, without ERwin. Tables, columns, identifying and non-identifying relationships, subtypes (generalizations), keys and indexes and user-defined properties come across, with one ERD per subject area laid out as in ERwin. DDL exported from ERwin reads too.

Indexes

Create indexes, unique indexes and unique constraints on the Indexes tab of the Table Specification and reorder their columns. Generate DDL writes CREATE INDEX; Import DDL reads the indexes of pg_dump, Oracle, MySQL and SQL Server.

10 languages

Screens, menus, errors and share-notice emails in English, Korean, Japanese, Chinese (Simplified and Traditional), Spanish, French, German, Portuguese (Brazil) or Vietnamese, with a System, Light or Dark theme. The web, Mac and iPad apps share the same phrase tables and settings. Diagram content (names, comments) stays as written.

Screens

A tour of the real screens

Every picture below is a screenshot of the Bluetong web app. In dark mode you see the dark screens.

The screenshots show the app in English. The shopping-mall model is a made-up example.

Auto arrange

Import the DDL, then tidy it up with one click

Imported tables land in rows and their lines cross each other. โ€œAuto arrange โ€บ including tablesโ€ puts referenced tables above the tables that refer to them and re-routes every line at right angles around the tables. Lines that share a gap are spread apart, and lines between facing sides are straightened. One undo puts it all back.

The ERD right after a DDL import: 17 tables in a grid with relationship lines cutting diagonally across tables
As imported โ€” 17 tables, 24 relationships
The same ERD after auto arrange: member, category and brand on top, order, review and product option in the middle, payment, delivery and order item on the bottom row, with lines running at right angles around the tables
After auto arrange โ€” tables in layers, right-angle lines

Pick a center table and arrange around it

Choose one table and pick โ€œArrange around this tableโ€: that table stays exactly where it is and the rest is laid out around it. Layered puts its parents in the row above and its children in the row below; radial rings the tables joined to it around it, and those one step further on an outer ring. Use it to read a large ERD from one piece of business.

The ERD arranged in layers around Order: Order stays where it was, Member and Address, which it refers to, sit in the row above, and Payment, Delivery, Point history, Member coupon and Order item, which refer to it, in the row below
Layered around it โ€” Order stays put, parents above, children below
The ERD arranged radially around Order: Member, Payment, Delivery, Point history and Member coupon ring it, and tables further away such as Product and Category sit further out
Radial around it โ€” joined tables around it, farther ones on an outer ring

The server does the computing (no AI). The web app, the macOS and iPad apps, the command line (bluetong arrange, with --center for a center table) and MCP all get the same result.

AI chat

Talk to AI about the diagram you have open

Ask โ€œadd tables so we can take returnsโ€ and the AI proposes new tables, columns and relationships. A proposal only enters the diagram when you press โ€œApplyโ€.

The AI chat panel beside an ERD: the user asks for a returns table and a delivery memo column, and the AIโ€™s proposal card โ€” a new return_request table and a memo column on delivery โ€” has an Apply button
  • Propose โ†’ apply โ†’ undo in one stepThe AIโ€™s proposal is only a preview. An applied proposal is undone as a whole with a single undo.
  • Choose your AIConnect an OpenAI-compatible endpoint or Ollama. With an in-house Ollama, diagram content never leaves your company. Keys are stored on the server only.
  • Per-member accessAdministrators register an AI and grant it member by member. Members may also register their own AI endpoint. A granted AI shows members only its name and model.
  • Chats kept per diagramChat history is stored on the server for each diagram, so you can reopen it and carry on. Drop text files and pictures in to send them along. Copy an answer, or download it as a Markdown file (.md).

The AI answer in the picture is an example. Real answers depend on the model you connect. Bluetong sends the AI a description of the open diagramโ€™s tables, columns, comments and relationships, and applies only the parts of its proposal that fit the diagram.

Teamwork

Many people, one diagram, at the same time

Edits are saved to the server as they happen and appear at once on everyone elseโ€™s screen. The server sets the order, so every screen ends up in the same state.

How real-time co-editing flows: edits from user A (web) and user B (macOS app) go to the Bluetong server, which orders and merges them, stores them in PostgreSQL and sends them to every screen in the same order User Aweb app ยท renames a table User BmacOS app ยท moves a table Bluetong serverrevision order r41 โ†’ r423-way merge ยท character-level merge PostgreSQLprojects ยท change history edit edit save real-time delivery โ€” same order everywhere

About the diagram

  • Solid lines are edits going up. Edits from the web and from the macOS app reach the same server.
  • The server sets the order. Edits that arrive together are numbered by revision and merged field by field (3-way merge).
  • Names and descriptions merge character by character, so letters two people type at once are all kept.
  • Blue dotted lines are real-time delivery. Every screen receives the same order and reaches the same state, and you see other peopleโ€™s pointers and selections.

Share a project or one diagram

Share a whole project or a single diagram. Permissions: view, edit, save to the ownerโ€™s copy, save to your own copy, print. When a share is withdrawn, open screens close right away.

Share notices

When something is shared with you, you hear about it at once through the in-app bell, browser push, Mac, iPad and iPhone push, and email โ€” in your language. Email goes through your companyโ€™s SMTP.

Saved on every edit, with history

Every edit is saved to the server and bumps the revision. The change history stays on the server, so a screen that joins late fetches the revisions it missed and catches up.

Security

One more layer, even inside the company

Being on the intranet is no reason to send plain text. Every request after sign-in is sealed, and the browser and the app check for themselves that what they run has not been changed.

Session envelope

At sign-in a session key is agreed with ECDH P-256 and HKDF; from then on every API request and response is sealed with AES-256-GCM. Change one byte and it is refused.

Invitation and email check

Sign-up needs an invitation code and a verification number sent by email. Passwords are stored with argon2id.

Audit log

The server records events such as sign-in, sign-up, account locks, password resets and AI use.

.blue files

A .blue downloaded from the server is sealed with AES-256-GCM and signed, so only the server that made it can open it.

Web bundle integrity

The deployed web appโ€™s scripts and WebAssembly carry integrity hashes (SRI) under a Content Security Policy. The browser will not run a changed file.

Obfuscation and a WebAssembly core

Release builds are obfuscated, and the core that reads and writes the file format runs as WebAssembly.

Notarized macOS app

The macOS app is notarized by Apple and checks its own signature before it loads its core. Its automatic updates take only a new build with the same signature and notarization.

API keys

An API key is a P-256 key pair. The server keeps only the public key, and each key can be read-only and limited to certain projects.

Developers

Beyond the screen โ€” command line, MCP, SDKs

What people do on screen, scripts and AI agents can do too. The server decides permissions exactly as it does for the screens.

# install the command line and the Claude Code skill from your company's server in one go (Node.js 22 or later)
$ curl -fsSL https://modeling.example.com/download/cli/install.sh | sh

# sign in to your company's server (the password is asked without echo)
$ bluetong login --server https://modeling.example.com --email kim@example.com

# your projects and those shared with you
$ bluetong projects
๋‚ด ํ”„๋กœ์ ํŠธ
  J8K2M4Q7R1T5V9X3  r42  ์‡ผํ•‘๋ชฐ ๋ฐ๋ชจ
๊ณต์œ ๋ฐ›์€ ํ”„๋กœ์ ํŠธ
  J3N6P9S2U5W8Y1Z4  ํšŒ๊ณ„ ๋ชจ๋ธ  (lee@example.com)

# keep Order where it is and arrange the rest around it โ€” the server works out lines and layout
$ bluetong arrange <projectId> "์ฃผ๋ฌธ ยท ๊ฒฐ์ œ" --center orders --radial

# draw an architecture (C4 container) diagram from Mermaid C4 text
$ bluetong architecture <projectId> "์‡ผํ•‘๋ชฐ ๊ตฌ์„ฑ" shop-c4.mmd

# draw a state machine (state diagram) from Mermaid stateDiagram text
$ bluetong state <projectId> "์ฃผ๋ฌธ ์ƒํƒœ" order-states.mmd

# see the history (who ยท when ยท what) and restore an earlier revision
$ bluetong history <projectId>
$ bluetong restore <projectId> 12

# ask the AI your company connected, and apply its proposal
$ bluetong ai <projectId> "์ฃผ๋ฌธ ยท ๊ฒฐ์ œ" "Add a returns table linked to order items" --apply

# hand it to an AI agent (an MCP client)
$ claude mcp add -s user bluetong -- ~/.local/bin/bluetong mcp

bluetong CLI

login ยท account ยท link ยท whoami ยท projects ยท new ยท add-diagram ยท rename-diagram ยท import ยท export ยท diagrams ยท show ยท apply (DDL and operations) ยท sequence ยท rest ยท openapi ยท architecture ยท ddl ยท ai ยท arrange ยท delete-diagram ยท delete ยท delete-model ยท trash ยท skill ยท api. Output as a table or as JSON.

MCP server

bluetong mcp โ€” with 27 tools, AI agents create projects, draw ERDs, sequences (Mermaid text), REST APIs (OpenAPI), architecture (Mermaid C4) and state machines (Mermaid stateDiagram), arrange them, rename diagrams, attach a Markdown documentation to each diagram, delete the diagrams, elements and empty models they no longer need, and export DDL and OpenAPI, and diagrams as Markdown (Mermaid + documentation), HTML and SVG. The Claude Code skill bluetong-modeling that comes with it teaches the order to draw in. They also read the history, read or restore an earlier revision, and name revisions.

API keys

Key pairs are made on screen and only the public key goes to the server. A signature opens the session; keys can be read-only or limited to projects.

TypeScript and Python SDKs

Client libraries that handle the session envelope for you, to connect Bluetong with your in-house systems.

macOS ยท iPad ยท iPhone apps

On a Mac, a Mac app โ€” on an iPad, an iPad app

The same features as the web, as native SwiftUI apps. They connect to the same server and edit alongside web users. The iPad and iPhone app is in TestFlight testing now.

The Bluetong macOS app window in dark mode: Project, Diagram and Tools tabs with a ribbon at the top, the model tree and diagram list on the left, and the full shopping-mall ERD of 17 tables on the right
  • Feels like a MacAn Xcode-like split layout, the standard menu bar and shortcuts, right-click menus, an inspector and a Settings window.
  • Same features as the webEditing, the notation palette, auto arrange, C4 architecture, API docs, format, SQL, AI chat, sharing and real-time co-editing. The 3D view is drawn with RealityKit.
  • Notarized, self-updatingDistributed as a DMG notarized by Apple. When a new build is out, the app downloads it, checks its signature and notarization, and swaps itself.
  • Edit on iPad in testingThe notation palette, drawing with Apple Pencil, bending relationship lines, keyboard shortcuts, real-time co-editing and an AI chat on the right that leaves the model in view โ€” drawn by the same engine and renderer.
  • View on iPhone in testingOpen server projects and files shared with you, browse and search diagrams, get share notices, view DDL and OpenAPI and share pictures.
  • 10 languagesChoose the language and theme in Settings โ€” the same words as the web.

macOS 15 or later ยท Apple silicon ยท Intel ยท notarized DMG

Setup and rollout

Installed in one place, on your servers

The Bluetong server is a Java web application on Tomcat, storing its data in PostgreSQL. The same Tomcat serves the web app, so there is not much to bring in.

On-premise layout: inside the company server zone are the users (browser, macOS app, CLI), the Bluetong server, PostgreSQL 17, an in-house AI, settings and keys, the company SMTP server and backups; the only line leaving the zone is a dotted one to optional push services Company servers ยท intranet Usersbrowser ยท macOS app ยท CLI ยท MCP Bluetong serverJava 21 ยท Tomcat 11 ยท web app + API PostgreSQL 17models ยท edit history ยท AI chats In-house AIOllama ยท OpenAI-compatible Settings ยท keyssession envelope ยท signing keys Company SMTPverification ยท share notices Backupsdaily pg_dump + keys ยท restore check Push (optional)Apple ยท browser push HTTPS

About the diagram

  • Top row, left to right: users โ†’ Bluetong server โ†’ PostgreSQL. One Tomcat serves both the web app and the API, so there is a single address.
  • Models, edit history, sharing and AI chat history live in PostgreSQL; the keys for the session envelope and signing sit in the serverโ€™s settings folder. Backups take both, every day.
  • Orange dotted lines go only where your company decides: AI calls to the endpoints registered by administrators or members, email through your SMTP. With an in-house Ollama both stay inside.
  • The only line leaving the zone is push, and it is optional: only when macOS or browser push notices are used does a notice go to Appleโ€™s or the browser vendorโ€™s push service.
ComponentDetails
ServerJava 21 WAR on Tomcat 11; the reference runtime is a Docker image. The same Tomcat serves the web app.
DatabasePostgreSQL 17 โ€” projects (models and diagrams), edit history, sharing, AI chat history, audit log.
EmailSign-up verification numbers and share notices go out through your SMTP server.
AI (optional)An OpenAI-compatible endpoint or Ollama. Everything else works without one.
BackupsDaily pg_dump plus a key bundle, with a check that restores the backup into a throw-away database and compares row counts table by table.
Deploy and roll backOne command each. Schema changes only ever add, so going back to the previous server build is safe.
  1. 1

    Bring up the server

    Install the Bluetong server (Java 21, Tomcat 11) and PostgreSQL 17 on your servers and create the schema.

  2. 2

    First administrator

    The first administrator signs up with a start code the server makes at install time. From then on, administrators invite members.

  3. 3

    Email, domain and AI

    Set your SMTP server and HTTPS address, register the AI you will use (an in-house Ollama, for instance) and grant it to members.

  4. 4

    Invite the team and start

    An administrator invites the team; members sign up with e-mail verification and start modeling together right away.

Contact

Considering Bluetong for your company?

Tell us your team size, the databases you use and where you want AI to run, and we will walk you through the setup and the rollout.

halo@levelupsoft.com

Helpful to include

  • Company, contact person and expected number of users
  • Databases in use (PostgreSQL, Oracle, MySQL)
  • Your AI plan โ€” an in-house Ollama, or another endpoint

Levelupsoft Inc. ยท Modeling makes ideas real.