Importing & Exporting Models
You can import and export AI model configurations — including their bindings — as CSV files. This is useful for migrating models between Koios instances, bulk-editing binding settings in a spreadsheet, or backing up model configurations before making changes.
How Models and Bindings Relate
Each AI model has a set of bindings — input bindings that map tags to model inputs, and output bindings that map model outputs back to tags. When you export models, Koios exports both the model settings and all of their bindings together.
The export produces a ZIP file containing two CSV files:
Exporting Models
How to Export
There are two ways to export model configurations:
- From the model table — select one or more models using the checkboxes, then click Export config in the bulk actions menu. Only the selected models and their bindings are exported.
- Export all — if no models are selected, the export includes every model and binding in the system.
The export downloads a file named models_export.zip.
What's Included
Both CSVs contain all configuration fields. Columns that don't apply to a particular model or binding will be empty.
Model CSV Columns
Core fields:
Inference settings:
References:
System-managed fields (read-only):
Binding CSV Columns
Core fields:
Normalization:
Calibration:
Output settings:
Failure detection:
Rate-of-change detection:
Audit fields (read-only):
Importing Models
How to Import
- Navigate to the Models page
- Click the Import button in the table toolbar
- Select a file — either a ZIP (with
models.csvand/orbindings.csv) or a single CSV - Review the preview to verify what will change
- Click Confirm Import to apply the changes
File Formats
The import accepts three file formats:
Koios auto-detects whether a CSV contains models or bindings based on the column headers.
Models: Create or Update
How the import determines what to do with each model row:
Bindings: Update Only
How the import determines what to do with each binding row:
Import Order
When importing a ZIP with both files, Koios processes models first, then bindings. This ensures any new models exist before their bindings are updated.
Example: Creating New Models
To create new models, leave the id column empty. Provide at least a name:
Example: Bulk-Editing Binding Normalization
Export your models, then edit the bindings CSV to set normalization for all input bindings at once:
This sets Min-Max normalization with custom ranges on three bindings.
Example: Assigning Tags to Bindings
This assigns tag IDs 42, 43, and 44 to the three input bindings.
Preview Step
After selecting a file, Koios performs a dry run — it processes the CSV(s) without saving anything and shows you exactly what will happen:
- Summary — counts of items that will be created, updated, skipped, or rejected
- Row details — click any row to see a field-by-field diff of what will change
- Diff table — click Show Diff Table for a full-width view of all changes, with changed fields highlighted
If the import includes both models and bindings (from a ZIP), the preview shows results for both.
Validation Rules
Model validation:
Binding validation:
Boolean fields accept: True/False, true/false, 1/0, yes/no.
Foreign key fields (tag, aiopmodel, scan_group, remote_enable_tag, parent) expect integer IDs.
After Import
Once you confirm the import:
- Models and bindings are created or updated in a single transaction — if anything fails, all changes are rolled back
- An audit event is recorded (e.g. "Imported 5 models") with your username
- The model table automatically refreshes to show the updated list
- Updated models pick up changes on the next inference cycle if they are enabled
Tips
- Typical workflow for new models — create models via import (or the UI), upload model files to generate bindings, export the bindings, bulk-edit tag assignments and normalization in a spreadsheet, then re-import the bindings.
- Bulk-edit normalization — export, filter the bindings CSV to input bindings (
usage=0), setnormalization_type,normalization_source, and custom range columns, then import just the bindings CSV. - Move models between Koios instances — export from one instance, clear the
idandslugcolumns in the models CSV (and theid,slugcolumns in the bindings CSV), adjust anytagandscan_groupIDs to match the target instance, and import on the target. You'll also need to re-upload the model files. - Audit trail — every import creates an event visible on the Events page, grouped under a single parent event so you can see what was imported in one action.
- Read-only columns —
id,slug,inputs,outputs,aiopmodel_file,created_at,updated_at, andlast_modified_byare ignored on model create. You can leave them in the CSV but they won't overwrite system-managed values.
