AML Dataset
A grasp of these concepts will help you understand this documentation better:
Please note that the dataset file has the extension .dataset.aml
. Its full name is dataset_name.dataset.aml
.
(This feature is currently in active development. Please reach out if you want to become beta tester)
Dataset syntax definition
Dataset syntax defines the Dataset inside a project which will be then deployed to production as Ready-to-explore Dataset for end users to explore and get insights.
The syntax of Dataset includes 4 main components
- Dataset metadata: dataset labels, descriptions, owners
- Data Source reference: users' exploration activities will use this source
- Data models included
- Relationship
Parameter definition
Parameter name | Description |
---|---|
import | Add other files to the current dataset file |
dataset | Create Dataset |
label | Specifies how the dataset will appear in the Ready-to-explore Dataset |
description | Add dataset description |
owner | Define who should be in charge of managing the current dataset |
data_source_name | Specify the database that Holistics will execute the generated query against (in dataset) |
relationships | Specify relationship and their configuration among added models |
models | Specify which models will be used in the dataset |
view | Define how models and fields are displayed in Preview / Dataset Exploration |
Dataset syntax example
- AML 1.0
- AML 2.0
import 'path/to/model_a.model.aml' { model_a }
import 'path/to/model_b.model.aml' { model_b }
Dataset demo_ecommerce {
label: '[Demo] Ecommerce (Official)'
description: "Official dataset for demoing E-commerce use cases test"
owner: "[email protected]"
data_source_name: 'demodb'
models: [
order_master,
ecommerce_orders,
ecommerce_users,
ecommerce_products,
ecommerce_merchants,
ecommerce_cities,
ecommerce_countries
]
relationships: [
// define relationship between orders and users is many to one
relationship(ecommerce_cities_ecommerce_countries, true)
]
}
// You don't need import statements in AML 2.0
Dataset demo_ecommerce {
label: '[Demo] Ecommerce (Official)'
description: "Official dataset for demoing E-commerce use cases test"
owner: "[email protected]"
data_source_name: 'demodb'
models: [
order_master,
ecommerce_orders,
ecommerce_users,
ecommerce_products,
ecommerce_merchants,
ecommerce_cities,
ecommerce_countries
]
relationships: [
// define relationship between orders and users is many to one
relationship(ecommerce_cities_ecommerce_countries, true)
]
}
The output
Dataset view example
Holistics provides the capability to break down your datasets into smaller groups, curate specific fields and models, and present them using Dataset view
Dataset raw_ecommerce {
label: 'Raw Ecommerce'
description: "This Dataset is about Ecommerce data"
owner: '[email protected]'
data_source_name: 'demodb'
models: [users, orders]
relationships: [relationship(orders.user_id > users.id, true)]
view {
model orders // Display all fields from model orders. Put model orders first
model users {
field first_name
field last_name
field full_name
field id
field sign_up_at
field acquisition_cohort
field number_of_orders
}
}
}
The output
FAQs
Why is my AML Datasets only available in Preview, but not in Reporting Tab?
This page is applicable to AML 1.0 only. AML 2.0 deprecates the use of index.aml
. For more information, refer to index.aml file.
See Your Dataset is able to be explored in Preview mode, but it is not available in Production for mor information.