Logo
NeoArc Studio

Data Model

The central model file is the single source of truth for every entity, relationship, and property in a NeoArc project. Abstract database-agnostic types, key roles, per-property projections for persistence, search, and API, governance classifications (PII, confidential, retention policies), shared property sets with live inheritance, comprehensive validation rules, and import/export across a wide range of formats.

The data model (model.neoarc) is the foundation of everything in NeoArc Studio. Every entity, relationship, and property is defined here. API schemas, database DDL, search index mappings, ERD diagrams, graph views, governance documentation, all of these are projections of this single file. When you change the model, every downstream artefact reflects the change. When you break a contract, the validation engine tells you immediately. The model is the single source of truth that makes model-first architecture possible.

The model uses database-agnostic abstract types that map to any vendor via profiles. Each property carries three independent projection configurations (persistence, search, API), governance metadata (data classification, encryption, retention), and validation constraints. Shared property sets provide live inheritance for common patterns. Validation rules check for errors at design time.

Key Capabilities

Central Source of Truth
One model file holds all entities, relationships, properties, and projections. Every view and export derives from this single source.
Abstract Types
Database-agnostic types (string, integer, float, decimal, boolean, date, datetime, uuid, json, text, binary, enum) that map to concrete DB types via profiles.
Property Projections
Each property carries persistence, search, and API projections, controlling how data appears in each output channel.
Derived Views
ERD views, graph views, and search views are lightweight projections of the model. They store layout positions only; entity data comes from the model.

Model Structure

The model organises data around a small set of core concepts.

ConceptDescription
Entity (Node)A named data object with properties, key roles, and governance metadata. Rendered as a node in the graph.
Relationship (Edge)A labelled connection between two entities, with optional source and target labels for cardinality.
PropertyA typed field on an entity: name, abstract type, key role, validation constraints, projections, governance, and derivation mode.
GroupA logical subdomain grouping entities together. Rendered as a convex hull boundary with colour coding.
Composite ConstraintA multi-property constraint (e.g. composite unique keys) applied across properties on the same entity.
Foreign Key ResolutionLinks a foreign key property to its target entity and target property, generating visual edges in the model.

Property System

Abstract Types

Properties use database-agnostic abstract types. Database profiles map each abstract type to a concrete type for a specific vendor (e.g. string maps to NVARCHAR in SQL Server, TEXT in PostgreSQL). Parameterised templates such as NVARCHAR({maxLength}) use property constraints to produce the final DDL type.

Abstract TypeCategoryTypical Use
stringTextShort text values, identifiers, codes
textTextLong-form content, descriptions, notes
integerNumericWhole numbers, counts, quantities
floatNumericFloating-point values, measurements
decimalNumericPrecise values, monetary amounts
booleanLogicTrue/false flags, feature toggles
dateTemporalCalendar dates without time
datetimeTemporalTimestamps with date and time
uuidIdentityUniversally unique identifiers
jsonStructuredArbitrary JSON payloads
binaryBinaryBinary data, file contents
enumEnumerationFixed set of allowed values

Key Roles

Every property has a key role that describes its function in the entity's identity and relationships.

RoleBadgeDescription
none-No key significance. The default for ordinary data fields.
primaryPKThe primary identifier for the entity. Validation warns if an entity has zero or more than one primary key.
naturalNKA business-meaningful unique identifier (e.g. email address, SKU code).
surrogateSKA system-generated unique identifier with no business meaning.
composite-partCKOne field in a multi-field composite key, defined via composite constraints.
foreignFKReferences a key property on another entity. Requires foreign key resolution to specify the target entity and property.

Derivation Modes

Properties support three derivation modes that indicate how values are produced.

ModeDescription
storedValue is persisted directly in the data store. This is the default.
derivedValue is calculated from other properties during write or ETL processes.
computed-on-readValue is computed at query time, not stored. Useful for aggregations and calculated fields.

Projections

Each property carries per-channel projections that control how it appears in different output targets. The property table editor offers four lens modes: schema (the base definition), persistence, search, and API.

Persistence Projection
Controls whether a property is included in the physical data store. Column mapping and inclusion flags determine what gets persisted.
Search Projection
Configures search index behaviour per property: searchable, filterable, sortable, facetable, retrievable, highlightable, aggregatable. Includes analyser, normaliser, synonym map, language, vector search dimensions, and similarity metric settings.
API Projection
Defines API-layer representation: field name override, inclusion flag, and read-only status. Controls what consumers see in the API contract.

Governance

Validation

The model editor runs validation rules across three categories. Rules are mode-aware: structural rules always apply, semantic rules apply in conceptual and graph-db modes, and domain rules apply only in graph-db mode.

Data Views

Data Views are interactive, model-derived visualisations that display entities as nodes on a force-directed graph canvas with edges inferred from relationships. Click any node to open the Entity Overlay with the full property table. Two view modes target different concerns.

Persistence Mode
Assign a database profile to resolve abstract types to vendor-specific types (SQL Server, PostgreSQL, MySQL, Oracle, MongoDB). The Entity Overlay shows key roles, concrete column types, nullable flags, unique constraints, defaults, and FK references.
Search Mode
Assign a search profile to visualise how entities project into search indices. The Entity Overlay shows search behaviours (searchable, filterable, sortable, facetable, retrievable), analysers, sub-fields, and drift indicators.
Entity Overlay
Click any node or press Alt+Enter to open a floating property table. Relationship pills navigate to connected entities. Pin overlays to dock them below the canvas for side-by-side entity comparison.

Groups and Subdomains

Entities are organised into groups that represent logical subdomains. Each group has a name, a colour, and a list of member entities. The editor renders groups as convex hull boundaries around their members, with group-aware physics in the force simulation to keep related entities together. The entity picker supports group filtering to narrow selection when working with large models (the 50-entity cap per view makes this essential for navigation).

Entity Lifecycle Management

The model supports lifecycle tagging on every entity. Each entity carries a status of active, planned, or deprecated. When an entity is deprecated, it can be linked to its replacement via a replaced-by edge (the reverse evolved-from edge is created automatically). The repoint wizard migrates downstream references from deprecated entities to their replacements. Deprecation impact reports show remaining reference counts, and the safe-to-delete report confirms when deprecated entities can be removed.

Import and Export

The data model supports importing entities from a wide range of external file formats and exporting to numerous schema and DDL formats.

Import
Import entities from SQL DDL (multiple dialects including DBML), draw.io, GraphML, GEXF, DOT, PlantUML, Mermaid ERD, Cypher, ERDPlus, StarUML, RDF/OWL, JSON Graph Format, Microsoft Visio, and OpenAPI.
Export
Export to multiple SQL DDL dialects, GraphQL SDL, TypeScript, Prisma, Protobuf, Avro, Mongoose, DBML, Mermaid ERD, PlantUML, XSD, GraphML, JSON Schema, Cypher, and NeoArc JSON.
Group Filtering
Multi-select group filtering on both import and export allows working with specific subdomains of a large model.

Getting Started

Begin by creating a project in NeoArc Studio, which generates the model.neoarc file automatically. Add entities manually, or import them from existing SQL DDL, diagram files, or other schema formats. Define properties with abstract types and key roles, then create views to visualise specific subsets of the model.