{
  "format": "dataset-manifest/1",
  "slug": "smart-home-automation-controller",
  "version": 1,
  "seed": "smart-home-automation-controller:1",
  "spec": {
    "format": "dataset/1",
    "slug": "smart-home-automation-controller",
    "name": "Smart Home Activity Log",
    "tagline": "User interactions with smart home devices, including energy consumption and sensor readings.",
    "description": "The Smart Home Activity Log captures interactions between residents and their smart home devices, providing valuable insights into user behavior and energy consumption patterns. This synthetic dataset includes records of device usage events, energy readings, and automated actions triggered by user-defined conditions. Each record represents a unique interaction, detailing the type of device, the nature of the interaction, and the associated timestamps. The dataset is structured to reflect the dynamic nature of smart home environments, where common devices like lights and thermostats are frequently used, while interactions with multimedia systems and specialized sensors are less common, creating a rich yet sparse dataset in those areas. Practitioners can utilize this dataset to analyze patterns in device usage, optimize energy consumption, and enhance the user experience in smart homes. The logs enable users to answer questions about device performance and user engagement over time, offering a practical resource for analytics and visualization efforts, especially in BI dashboards.",
    "domain": "iot",
    "shape": "time-series",
    "useCases": [
      "analytics-demo",
      "bi-dashboards"
    ],
    "keywords": [
      "smart home",
      "device interactions",
      "energy consumption",
      "sensor readings",
      "automation",
      "analytics"
    ],
    "locale": "en",
    "license": "CC0-1.0",
    "version": 1,
    "tables": {
      "activity_log": {
        "description": "Each row in the activity_log table represents a unique interaction event with a smart home device, including details about the device type, action performed, and associated energy readings. The table captures timestamps to track usage patterns over time.",
        "rows": 500,
        "columns": {
          "id": {
            "kind": "pk",
            "description": "Unique identifier for each interaction event."
          },
          "device_type": {
            "kind": "enum",
            "values": [
              "light",
              "thermostat",
              "camera",
              "speaker",
              "sensor"
            ],
            "description": "Type of device that was interacted with."
          },
          "action": {
            "kind": "enum",
            "values": [
              "turned_on",
              "turned_off",
              "adjusted",
              "alert_triggered"
            ],
            "description": "Action performed by the user or the system."
          },
          "energy_consumed": {
            "kind": "decimal",
            "min": 0,
            "max": 1000,
            "scale": 2,
            "description": "Amount of energy consumed by the device during the interaction in kilowatt-hours.",
            "nullable": true,
            "when": {
              "column": "device_type",
              "in": [
                "light",
                "thermostat",
                "camera"
              ]
            }
          },
          "timestamp": {
            "kind": "datetime",
            "from": "2023-01-01",
            "to": "2023-12-31",
            "description": "Date and time when the interaction took place.",
            "dayProfile": "waking"
          },
          "user_id": {
            "kind": "uuid",
            "description": "Identifier for the user who interacted with the device.",
            "nullable": true,
            "when": {
              "column": "action",
              "in": [
                "alert_triggered"
              ]
            }
          }
        }
      }
    },
    "structure": "single-table",
    "traits": [
      "timestamped",
      "monetary",
      "high-cardinality"
    ],
    "analysisQuestions": [
      "What devices are most frequently used in the home?",
      "How does energy consumption vary by device type over time?",
      "What time of day do users interact with their devices the most?",
      "Are there any patterns in automated actions triggered by user interactions?"
    ],
    "suggestedQueries": [
      {
        "title": "Retrieve all interactions for a specific device type",
        "sql": "SELECT * FROM activity_log WHERE device_type = 'light';",
        "dialect": "postgres"
      },
      {
        "title": "Count interactions by action type",
        "sql": "SELECT action, COUNT(*) FROM activity_log GROUP BY action;",
        "dialect": "postgres"
      },
      {
        "title": "Calculate total energy consumption per device type",
        "sql": "SELECT device_type, SUM(energy_consumed) FROM activity_log GROUP BY device_type;",
        "dialect": "postgres"
      },
      {
        "title": "Find the most active hour of the day for device usage",
        "sql": "SELECT EXTRACT(HOUR FROM timestamp) AS hour, COUNT(*) FROM activity_log GROUP BY hour ORDER BY COUNT(*) DESC LIMIT 1;",
        "dialect": "postgres"
      }
    ],
    "usageScenarios": [
      {
        "title": "Home Automation Analysis",
        "body": "Home automation companies can use this dataset to analyze user interactions with devices, allowing them to identify trends and improve product features. By examining energy consumption patterns linked to device usage, they can offer insights to customers on optimizing their smart home configurations."
      },
      {
        "title": "Energy Management Research",
        "body": "Researchers focused on energy management in smart homes can leverage this data to study how energy consumption correlates with device usage. This analysis can inform strategies for reducing energy costs and enhancing efficiency in residential environments."
      },
      {
        "title": "User Experience Improvement",
        "body": "UX designers can utilize this dataset to gain insights into how users interact with smart home devices. Understanding the frequency and timing of interactions can help them design more intuitive interfaces and improve the overall user experience."
      }
    ]
  },
  "counts": {
    "activity_log": 500
  },
  "stats": {
    "activity_log": {
      "rows": 500,
      "columns": {
        "id": {
          "nulls": 0,
          "distinct": 500,
          "min": 1,
          "max": 500
        },
        "device_type": {
          "nulls": 0,
          "distinct": 5,
          "min": "camera",
          "max": "thermostat"
        },
        "action": {
          "nulls": 0,
          "distinct": 4,
          "min": "adjusted",
          "max": "turned_on"
        },
        "energy_consumed": {
          "nulls": 200,
          "distinct": 300,
          "min": 2.16,
          "max": 998.7
        },
        "timestamp": {
          "nulls": 0,
          "distinct": 500,
          "min": "2023-01-01 10:04:06",
          "max": "2023-12-31 15:28:36"
        },
        "user_id": {
          "nulls": 380,
          "distinct": 120
        }
      }
    }
  },
  "artifacts": [
    {
      "file": "csv/activity_log.csv",
      "format": "csv",
      "table": "activity_log",
      "key": "datasets/smart-home-automation-controller/v1/csv/activity_log.csv",
      "url": "https://database-sample-website.s3.eu-north-1.amazonaws.com/datasets/smart-home-automation-controller/v1/csv/activity_log.csv",
      "bytes": 29177,
      "sha256": "756aae695b11d0c8f8368571a9791c2ba6a124f3a750cfa2e0435dde86df708b",
      "rows": 500,
      "contentType": "text/csv; charset=utf-8"
    },
    {
      "file": "smart-home-automation-controller.json",
      "format": "json",
      "table": null,
      "key": "datasets/smart-home-automation-controller/v1/smart-home-automation-controller.json",
      "url": "https://database-sample-website.s3.eu-north-1.amazonaws.com/datasets/smart-home-automation-controller/v1/smart-home-automation-controller.json",
      "bytes": 98182,
      "sha256": "a3a465611a2aab2c5bf7f75db38f40f99920024aef088458b1ed70ed13bbd1bf",
      "rows": null,
      "contentType": "application/json; charset=utf-8"
    },
    {
      "file": "sql/postgres.sql",
      "format": "sql-postgres",
      "table": null,
      "key": "datasets/smart-home-automation-controller/v1/sql/postgres.sql",
      "url": "https://database-sample-website.s3.eu-north-1.amazonaws.com/datasets/smart-home-automation-controller/v1/sql/postgres.sql",
      "bytes": 41185,
      "sha256": "005bac34b7d18aa382c4e6548522be72080a085a79aca71bbf4e5c7ce51db39b",
      "rows": null,
      "contentType": "application/sql; charset=utf-8"
    },
    {
      "file": "sql/mysql.sql",
      "format": "sql-mysql",
      "table": null,
      "key": "datasets/smart-home-automation-controller/v1/sql/mysql.sql",
      "url": "https://database-sample-website.s3.eu-north-1.amazonaws.com/datasets/smart-home-automation-controller/v1/sql/mysql.sql",
      "bytes": 41081,
      "sha256": "7d1f3d44c3b220e39f1ceff6f0571d2394a4c122fa70dab4c5ab461af95f0560",
      "rows": null,
      "contentType": "application/sql; charset=utf-8"
    },
    {
      "file": "sql/mssql.sql",
      "format": "sql-mssql",
      "table": null,
      "key": "datasets/smart-home-automation-controller/v1/sql/mssql.sql",
      "url": "https://database-sample-website.s3.eu-north-1.amazonaws.com/datasets/smart-home-automation-controller/v1/sql/mssql.sql",
      "bytes": 42781,
      "sha256": "d5cbfea4f5bfb68295784fa0d1194ba7d995c6fe9a64933a129ebe7adb13d657",
      "rows": null,
      "contentType": "application/sql; charset=utf-8"
    },
    {
      "file": "sql/sqlite.sql",
      "format": "sql-sqlite",
      "table": null,
      "key": "datasets/smart-home-automation-controller/v1/sql/sqlite.sql",
      "url": "https://database-sample-website.s3.eu-north-1.amazonaws.com/datasets/smart-home-automation-controller/v1/sql/sqlite.sql",
      "bytes": 41042,
      "sha256": "3757bada730aadfe0317f5da560267dee3dc428e4d9abfa40739da7357f633c7",
      "rows": null,
      "contentType": "application/sql; charset=utf-8"
    },
    {
      "file": "prisma/seed.ts",
      "format": "prisma-seed",
      "table": null,
      "key": "datasets/smart-home-automation-controller/v1/prisma/seed.ts",
      "url": "https://database-sample-website.s3.eu-north-1.amazonaws.com/datasets/smart-home-automation-controller/v1/prisma/seed.ts",
      "bytes": 83035,
      "sha256": "948aa258af4d3ceecb628272a237ed4204983c1fdad0bfe23d11e65cc9807ca5",
      "rows": null,
      "contentType": "application/typescript; charset=utf-8"
    },
    {
      "file": "django/fixtures.json",
      "format": "django-fixture",
      "table": null,
      "key": "datasets/smart-home-automation-controller/v1/django/fixtures.json",
      "url": "https://database-sample-website.s3.eu-north-1.amazonaws.com/datasets/smart-home-automation-controller/v1/django/fixtures.json",
      "bytes": 123283,
      "sha256": "4dc8027167e2cf3a049a13d3ce1468b98dfc466cdfd93aeea189038943476da1",
      "rows": null,
      "contentType": "application/json; charset=utf-8"
    }
  ],
  "publishedAt": 1788734416334,
  "updatedAt": 1788734416334
}
