Understanding the Metamodel (M2) vs Model (M1)

Beginner

Metamodel (M2) vs Model (M1)

Metapad organizes your data in two layers:

The Metamodel (M2) — Your Schema

The metamodel defines what kinds of things can exist. It contains:

  • Node Types: Categories of elements (e.g., "Server", "Application", "Person")
  • Relationship Types: Kinds of connections (e.g., "runs_on", "manages", "depends_on")
  • Allowed Connections: Rules for which types can connect (e.g., "Application can run_on Server")

Think of the metamodel as a template or class definition.

The Model (M1) — Your Data

The model contains concrete instances that follow the metamodel:

  • Nodes: Specific elements (e.g., "web-server-01", "payment-service", "Alice")
  • Relationships: Specific connections (e.g., "payment-service runs_on web-server-01")

Think of the model as the actual data or object instances.

Analogy

Metamodel (M2)Model (M1)
"Person" (type)"Alice", "Bob" (instances)
"manages" (type)"Alice manages Bob" (instance)
BlueprintBuilding
ClassObject
Table schemaTable rows

How to Tell Them Apart in Metapad

In the Tree View, you'll see sections for:

  • Node Types and Relationship Types → these are M2 (metamodel)
  • Nodes and Relationships → these are M1 (model)

Key Rule

You always define the metamodel (types) first, then create model instances. You can't create a "Server" node without first defining "Server" as a Node Type.