> ## Documentation Index
> Fetch the complete documentation index at: https://docs.mantrixflow.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Core Concepts

> The current MantrixFlow concepts: connections, source streams, destination tables, Normalisation, SQL Layer, runs, and schedules.

## Connections

Connections store reusable credentials. The live public workflow supports PostgreSQL as both source and destination.

Source connections need read access. Destination connections need write access to tables that already exist.

## Pipeline shell

A pipeline shell has a name and a source connection. It is intentionally minimal because the builder owns the operational configuration.

## Source node

The **Source** node is where you:

* test the source connection
* discover schemas and tables
* include one or more source streams
* preview the active source stream

Streams are represented as `schema.table`, for example `public.orders`.

## Destination node

The **Destination** node is where you:

* choose the destination connection
* choose Full Table or Incremental sync
* set a replication key for Incremental sync
* keep the live write mode as Upsert
* add optional Normalisation rules
* write SQL models
* validate and preview model output
* save destination configuration
* run manually or configure a schedule

## Normalisation

Normalisation is destination-scoped and runs before the SQL Layer. The live rule types are:

* Rename a column
* Cast a column to a compatible type

## SQL Layer

The SQL Layer is the live SQL transformation surface. Models read from temporary raw staging tables using:

```sql theme={"theme":{"light":"github-light","dark":"github-dark"}}
{{ source('raw', 'public__orders') }}
```

The double underscore maps the source stream `public.orders` to the staging table name `public__orders`.

## Destination tables

Destination tables must already exist. During pre-flight and delivery, MantrixFlow validates:

* the final table exists
* the model output columns match destination columns
* primary keys are available for merge-style Upsert when possible

If a destination table has no primary key, rows are appended and the run records a warning.

## Sync modes

* **FULL\_TABLE** rereads the selected source stream for manual validation or controlled refreshes.
* **INCREMENTAL** uses a replication key and stored checkpoint for recurring runs.

Scheduling is available only for Incremental destinations.
