air-dml 2.1.10 → 2.1.12

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/README.md +31 -18
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -4,7 +4,7 @@
4
4
 
5
5
  *The Open Standard for AI-Ready Data Modeling*
6
6
 
7
- AIR-DML is an extended DBML (Database Markup Language) parser designed for AI-driven development. It adds powerful features for modern data modeling while maintaining full backward compatibility with standard DBML.
7
+ AIR-DML is a data modeling language designed for AI-driven development. It provides a structured, human- and machine-readable syntax for database schemas enriched with business context.
8
8
 
9
9
  [![npm version](https://badge.fury.io/js/air-dml.svg)](https://www.npmjs.com/package/air-dml)
10
10
  [![License](https://img.shields.io/badge/License-Apache%202.0-blue.svg)](https://opensource.org/licenses/Apache-2.0)
@@ -21,7 +21,7 @@ Generate ER diagrams from natural language using AI. Mode-ai is the reference im
21
21
 
22
22
  - Natural language to ER diagram generation
23
23
  - Interactive visual editor with drag & drop
24
- - Export to SQL, DBML, and more
24
+ - Export to SQL, AIR-DML, and more
25
25
 
26
26
  <br clear="left"/>
27
27
 
@@ -32,7 +32,7 @@ Generate ER diagrams from natural language using AI. Mode-ai is the reference im
32
32
  🌍 **Multilingual**: Logical names (aliases) in any language
33
33
  🎨 **Visual Design**: Coordinate and color information for diagram rendering
34
34
  🔄 **Polyglot Persistence**: Different database types per area
35
- đŸ“Ļ **Extends DBML**: Fully compatible with standard DBML syntax
35
+ đŸ“Ļ **Zero Dependencies**: Independent parser with no external dependencies
36
36
  đŸ’Ŧ **Comment Preservation**: Leading comments are preserved and associated with elements
37
37
 
38
38
  ## Installation
@@ -49,7 +49,7 @@ import { parseAirDML, exportToAirDML } from 'air-dml';
49
49
  // Parse AIR-DML text
50
50
  const airDmlText = `
51
51
  Project "My Project" {
52
- database_type: 'PostgreSQL'
52
+ database_type: "PostgreSQL"
53
53
  }
54
54
 
55
55
  // ãƒĻãƒŧã‚ļãƒŧįŽĄį†
@@ -228,6 +228,22 @@ Export a Diagram object to AIR-DML text.
228
228
 
229
229
  **Returns:** AIR-DML formatted text
230
230
 
231
+ ### `getDataTypesForDatabase(database: string): string[]`
232
+
233
+ Get the list of supported data types for a specific database.
234
+
235
+ **Parameters:**
236
+ - `database` - Database name: `"PostgreSQL"` | `"MySQL"` | `"SQLite"` | `"SQL Server"` | `"Oracle"` | `"BigQuery"` | `"Redshift"` | `"Snowflake"`
237
+
238
+ **Returns:** Array of data type strings
239
+
240
+ ```typescript
241
+ import { getDataTypesForDatabase } from 'air-dml';
242
+
243
+ const types = getDataTypesForDatabase('PostgreSQL');
244
+ // ["integer", "bigint", "varchar", "text", "boolean", "timestamp", ...]
245
+ ```
246
+
231
247
  ## Type Definitions
232
248
 
233
249
  ```typescript
@@ -301,17 +317,17 @@ interface Area {
301
317
  }
302
318
  ```
303
319
 
304
- ## Comparison: DBML vs AIR-DML
320
+ ## Key Features At a Glance
305
321
 
306
- | Feature | DBML | AIR-DML |
307
- |---------|------|---------|
308
- | **Focus** | Database schema | AI-ready + Business context |
309
- | **Logical names** | ❌ | ✅ `alias` attribute |
310
- | **Area management** | TableGroup (basic) | Area (extended: CommonColumns, database_type) |
311
- | **Visual info** | ❌ | ✅ Coordinates, colors, sizes |
312
- | **Multi-DB** | Project-level | Area-level (polyglot persistence) |
313
- | **AI optimization** | ❌ | ✅ LLM-friendly design |
314
- | **Comment preservation** | ❌ | ✅ Leading comments (v1.2.0+) |
322
+ | Feature | Description |
323
+ |---------|-------------|
324
+ | **Logical names** | `alias` attribute for human-readable names in any language |
325
+ | **Classification values** | `values` attribute for enums and status codes |
326
+ | **Area management** | Bounded context grouping with CommonColumns and per-area database type |
327
+ | **Visual layout** | Coordinates, colors, and sizes for diagram rendering |
328
+ | **Multi-DB** | Area-level database type (polyglot persistence) |
329
+ | **AI-optimized** | LLM-friendly syntax designed for generation and interpretation |
330
+ | **Zero dependencies** | Independent recursive descent parser |
315
331
 
316
332
  ## Changelog
317
333
 
@@ -367,13 +383,10 @@ For the complete AIR-DML specification, see [SPECIFICATION.md](./SPECIFICATION.m
367
383
 
368
384
  Apache-2.0 License - see [LICENSE](./LICENSE) file for details.
369
385
 
370
- AIR-DML extends [DBML](https://github.com/holistics/dbml) (also Apache-2.0).
371
-
372
386
  ## Credits
373
387
 
374
388
  - **Created by**: Data-mination Partners
375
- - **Technical collaboration**: Claude Opus 4.5 (Anthropic)
376
- - **Based on**: [@dbml/core](https://www.npmjs.com/package/@dbml/core) by Holistics
389
+ - **Technical collaboration**: Claude Sonnet 4.6 (Anthropic)
377
390
 
378
391
  ## Links
379
392
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "air-dml",
3
- "version": "2.1.10",
3
+ "version": "2.1.12",
4
4
  "description": "AI-Ready Data Modeling Language - Independent AIR-DML parser with zero dependencies",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",