# Import Semantic Layer & Agents

Actian AI Analyst supports importing your semantic layer and agent configurations from files. Use imports to migrate between environments, restore from backups, or bulk-update your semantic layer.

#### What Can Be Imported

* **Models** — Dimensions, measures, filters, grain, and data source mappings
* **Relationships** — Joins between models
* **Metrics** — Definitions, anchors, time dimensions, joins, and filters
* **Glossary** — Terms with synonyms, tags, and mappings
* **Agents** — Configurations and semantic layer access

#### Import Formats

| Format                          | File Types               | Use Case                                                                 |
| ------------------------------- | ------------------------ | ------------------------------------------------------------------------ |
| Actian AI Analyst (YAML/JSON)   | `.yaml`, `.yml`, `.json` | Full imports, backups, migrations between Actian AI Analyst environments |
| Actian AI Analyst (Excel)       | `.xlsx`, `.xls`          | Simplified bulk updates via spreadsheet                                  |
| OSI (Open Semantic Interchange) | `.yaml`                  | Importing semantic models from other tools via Steward                   |

#### How to Import

1. Go to **Studio > Settings > Import Data**
2. Click **Import**
3. Drag and drop your file(s) or click to select — you can upload multiple files at once
4. Click **Upload & Analyze**
5. Review the analysis: Actian AI Analyst shows what will be created, updated, or skipped, with field-level diffs for updates
6. Select or deselect individual entities using the checkboxes
7. Click **Apply Import**

#### How Matching Works

Actian AI Analyst uses a two-step matching strategy to determine whether an entity should be created or updated:

1. **ID match** — If the import file includes an `id` field and it matches an existing entity, Actian AI Analyst treats it as an update (this also enables rename detection)
2. **Name match** — If no ID is provided or found, Actian AI Analyst falls back to matching by name

Data sources are automatically matched by the `data_source_name` field in your import file against your organization's connected data sources.

#### Import History

All past imports are visible at **Studio > Settings > Import Data**. Each entry shows:

* **Status** — Queued, Processing, Completed, or Failed
* **Started by** — Who initiated the import
* **Date** — When the import was started
* **Summary** — Counts of created, updated, and skipped entities

#### Notes

* All import operations are applied in a single transaction — if any entity fails, the entire import is rolled back
* Entities are processed in dependency order: Models → Relationships → Metrics → Glossary → Agents
* All import operations are audit logged
* For OSI files from other tools, use Steward instead of direct import


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.wobby.ai/governance/import-semantic-layer-and-agents.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
