Skip to content

Dataset

Source: src/AWS/Forecast/Dataset.ts

An Amazon Forecast dataset — a typed, domain-scoped collection of time-series (or metadata) records described by a schema. Creating the dataset is a cheap metadata operation; bulk imports and training happen through separate import jobs and predictors.

const dataset = yield* Forecast.Dataset("Demand", {
domain: "CUSTOM",
datasetType: "TARGET_TIME_SERIES",
dataFrequency: "D",
schema: {
attributes: [
{ attributeName: "item_id", attributeType: "string" },
{ attributeName: "timestamp", attributeType: "timestamp" },
{ attributeName: "target_value", attributeType: "float" },
],
},
});