Flat-File Templates

Generate deterministic field-mapping templates from sample instrument exports, review the detected file shape and proposed HL7 mappings, and approve templates to activate them for runtime file-ingest channels.

What It Does

Many lab instruments — especially legacy chemistry analyzers, hematology counters, and coagulation platforms — export results as flat files: CSV, TSV, or fixed-width text. Vorian Connect reads these files through watched-folder source channels, but it needs a template that describes the file structure and maps each column to its HL7 target.

Flat-file Templates let interface engineers generate these templates from a single sample export. Upload a sample file or paste sample text, and Vorian produces a deterministic draft with detected columns, inferred data types, and automatic HL7 field mapping — all without calling a hosted model provider. You then review the proposal, edit mappings if needed, and approve the template. Once approved, runtime file-ingest channels can use it immediately.

Local and deterministic. Sample files stay on the dashboard path. No hosted model provider is involved — format detection, column inference, and HL7 target mapping are all run locally.

How It Works

  1. Select a source — pick the instrument from your configured sources.
  2. Provide a sample — upload a sample export file (up to 5 MiB) or paste sample text. Supported formats: CSV, TSV, and fixed-width.
  3. Generate a draft — Vorian detects the file format, delimiter, field boundaries, data types, and proposed HL7 targets. A draft template is created in draft status.
  4. Review the proposal — inspect the detected file shape (format, delimiter, skip rows, footer rows), examine each proposed field mapping (column, header, sample, data type, HL7 target), and read the generator notes.
  5. Edit or reject — if the draft needs corrections, edit field mappings directly and save. If the proposal is fundamentally wrong, reject it with a reviewer reason; the draft returns to editable state.
  6. Approve and activate — when the template is correct, approve it. Approval retires any previously approved template for the same vendor and instrument model, and atomically moves any affected source channels to the new template.

Template Fields

Each field mapping row includes:

Activation Impact

Approving a template is an atomic replacement. If a previously approved template exists for the same vendor and instrument, it is retired, and all source channels currently using it are moved to the new template in a single transaction. The approval panel lists every affected source channel and requires explicit confirmation before proceeding.

There is no "approve without activating" option — approving a replacement replaces the runtime template atomically. Templates that replace nothing (no previously approved template for the same vendor+instrument) activate without moving channels.

Where It Fits

Flat-file Templates are part of the Interface Builder workflow, accessed at /flatfile-templates in the dashboard under Configure. The feature requires the interface:build permission scoped to the selected source.

It complements the Interface Analyzer (/hl7-analyzer), which handles ad-hoc sample classification and mapping proposals, and the Flat File Parser, which performs the actual runtime parsing of CSV, TSV, and fixed-width files using approved templates.

Vendor implementation guides and PDF specification documents should use the separate Docbuilder extraction path, not Flat-file Templates.

Technical Details

Last updated: August 7, 2026