{
  "format": "dataset-manifest/1",
  "slug": "smart-home-control",
  "version": 2,
  "seed": "smart-home-control:1",
  "spec": {
    "format": "dataset/1",
    "slug": "smart-home-control",
    "name": "Home Automation Insights",
    "tagline": "Home automation events detailing interactions among smart devices for enhanced comfort and security.",
    "description": "Residents control various devices to enhance comfort and security within their living spaces. This dataset provides insights into interactions between smart lights, security cameras, smart locks, energy consumption readings, and automated routines. Each row represents a unique event timestamp, capturing device status changes, energy usage metrics, and user interactions throughout the day. This can help in understanding daily energy usage patterns and the effectiveness of automated routines. The dataset is designed to highlight both common interactions and rare events, allowing for a comprehensive analysis of smart home dynamics. Practitioners can leverage this synthetic data to explore trends, identify anomalies, and optimize user experiences in smart home setups. The data is structured in a way that encourages both basic and advanced analytics, making it suitable for use in BI dashboards and analytics demonstrations.",
    "domain": "iot",
    "shape": "time-series",
    "useCases": [
      "analytics-demo",
      "bi-dashboards"
    ],
    "keywords": [
      "smart home",
      "iot",
      "automation",
      "energy consumption",
      "device interactions",
      "security",
      "sensors",
      "data analysis"
    ],
    "locale": "en",
    "license": "CC0-1.0",
    "version": 1,
    "tables": {
      "home_automation_events": {
        "description": "Each row records an event in the smart home environment, linking various devices and their states over time. It captures device interactions, energy readings, and user activities.",
        "rows": 500,
        "columns": {
          "event_id": {
            "kind": "pk",
            "description": "Unique identifier for the event."
          },
          "timestamp": {
            "kind": "datetime",
            "from": "2023-01-01",
            "to": "2023-12-31",
            "description": "Date and time of the event."
          },
          "device_type": {
            "kind": "enum",
            "values": [
              "light",
              "security_camera",
              "smart_lock",
              "energy_monitor"
            ],
            "weights": [
              0.4,
              0.3,
              0.2,
              0.1
            ],
            "description": "Type of device that triggered the event."
          },
          "action": {
            "kind": "enum",
            "values": [
              "turned_on",
              "turned_off",
              "locked",
              "unlocked",
              "motion_detected",
              "energy_read"
            ],
            "weights": [
              0.25,
              0.25,
              0.2,
              0.2,
              0.05,
              0.05
            ],
            "description": "Action performed by the device."
          },
          "energy_usage": {
            "kind": "decimal",
            "min": 0,
            "max": 3000,
            "scale": 2,
            "description": "Energy consumed in watts during the event, applicable for energy monitor devices.",
            "nullable": true,
            "when": {
              "column": "device_type",
              "in": [
                "light",
                "energy_monitor"
              ]
            },
            "distribution": "normal"
          },
          "user_interaction": {
            "kind": "bool",
            "trueRate": 0.15,
            "description": "Indicates whether a user directly interacted with the device during the event.",
            "nullable": true,
            "when": {
              "column": "action",
              "in": [
                "motion_detected"
              ]
            }
          }
        }
      }
    },
    "structure": "single-table",
    "traits": [
      "timestamped",
      "categorical",
      "monetary"
    ],
    "analysisQuestions": [
      "What are the peak energy usage times throughout the day?",
      "How often do users interact with their smart devices?",
      "What types of actions are most common for each device type?",
      "Are there any unusual spikes in security events, and when do they occur?",
      "How do automated routines affect energy consumption?"
    ],
    "suggestedQueries": [
      {
        "title": "Select all events for a specific device type",
        "sql": "SELECT * FROM home_automation_events WHERE device_type = 'light';",
        "dialect": "postgres"
      },
      {
        "title": "Count events by action type",
        "sql": "SELECT action, COUNT(*) FROM home_automation_events GROUP BY action;",
        "dialect": "postgres"
      },
      {
        "title": "Average energy usage per device type",
        "sql": "SELECT device_type, AVG(energy_usage) FROM home_automation_events WHERE device_type = 'energy_monitor' GROUP BY device_type;",
        "dialect": "postgres"
      },
      {
        "title": "Find the most common user interactions",
        "sql": "SELECT COUNT(*) AS interaction_count FROM home_automation_events WHERE user_interaction = true;",
        "dialect": "postgres"
      }
    ],
    "usageScenarios": [
      {
        "title": "Energy Consumption Analysis",
        "body": "Energy analysts can utilize this dataset to monitor and analyze daily energy consumption patterns across smart home devices. By identifying peak usage times, they can recommend adjustments to optimize energy efficiency."
      },
      {
        "title": "Security Event Monitoring",
        "body": "Security professionals can leverage the dataset to track unusual activity reported by smart cameras and locks. Analyzing the frequency and timing of security events can enhance the overall safety measures in smart homes."
      },
      {
        "title": "User Interaction Insights",
        "body": "User experience researchers can study how frequently residents interact with their smart devices, identifying trends in usage and engagement. This analysis can inform design improvements for smarter, more intuitive home automation systems."
      }
    ]
  },
  "counts": {
    "home_automation_events": 500
  },
  "stats": {
    "home_automation_events": {
      "rows": 500,
      "columns": {
        "event_id": {
          "nulls": 0,
          "distinct": 500,
          "min": 1,
          "max": 500
        },
        "timestamp": {
          "nulls": 0,
          "distinct": 499,
          "min": "2023-01-01 13:05:14",
          "max": "2023-12-31 22:59:39"
        },
        "device_type": {
          "nulls": 0,
          "distinct": 4,
          "min": "energy_monitor",
          "max": "smart_lock"
        },
        "action": {
          "nulls": 0,
          "distinct": 6,
          "min": "energy_read",
          "max": "unlocked"
        },
        "energy_usage": {
          "nulls": 246,
          "distinct": 253,
          "min": 285.55,
          "max": 2361.98
        },
        "user_interaction": {
          "nulls": 467,
          "distinct": 2,
          "min": "false",
          "max": "true"
        }
      }
    }
  },
  "artifacts": [
    {
      "file": "csv/home_automation_events.csv",
      "format": "csv",
      "table": "home_automation_events",
      "key": "datasets/smart-home-control/v2/csv/home_automation_events.csv",
      "url": "https://database-sample-website.s3.eu-north-1.amazonaws.com/datasets/smart-home-control/v2/csv/home_automation_events.csv",
      "bytes": 25848,
      "sha256": "1f7253bd15f494059d525592b5884bc8a7d781a82eb09493606c4244aaf60ee9",
      "rows": 500,
      "contentType": "text/csv; charset=utf-8"
    },
    {
      "file": "smart-home-control.json",
      "format": "json",
      "table": null,
      "key": "datasets/smart-home-control/v2/smart-home-control.json",
      "url": "https://database-sample-website.s3.eu-north-1.amazonaws.com/datasets/smart-home-control/v2/smart-home-control.json",
      "bytes": 101128,
      "sha256": "3d511686038d15dd3b0eb3c3fec162999109feae535c6e236a5f3007f08ee89d",
      "rows": null,
      "contentType": "application/json; charset=utf-8"
    },
    {
      "file": "sql/postgres.sql",
      "format": "sql-postgres",
      "table": null,
      "key": "datasets/smart-home-control/v2/sql/postgres.sql",
      "url": "https://database-sample-website.s3.eu-north-1.amazonaws.com/datasets/smart-home-control/v2/sql/postgres.sql",
      "bytes": 38232,
      "sha256": "2771c876722d58de055a0147ea554d03a439ef56ec1dfbf93f6809d4b4ffbb22",
      "rows": null,
      "contentType": "application/sql; charset=utf-8"
    },
    {
      "file": "sql/mysql.sql",
      "format": "sql-mysql",
      "table": null,
      "key": "datasets/smart-home-control/v2/sql/mysql.sql",
      "url": "https://database-sample-website.s3.eu-north-1.amazonaws.com/datasets/smart-home-control/v2/sql/mysql.sql",
      "bytes": 37967,
      "sha256": "f22a1293053ec1a0c3c42c6f2779b5960cc706e969616a0f6cee32d12c5665b7",
      "rows": null,
      "contentType": "application/sql; charset=utf-8"
    },
    {
      "file": "sql/mssql.sql",
      "format": "sql-mssql",
      "table": null,
      "key": "datasets/smart-home-control/v2/sql/mssql.sql",
      "url": "https://database-sample-website.s3.eu-north-1.amazonaws.com/datasets/smart-home-control/v2/sql/mssql.sql",
      "bytes": 39552,
      "sha256": "0d01124dfe2fd16d51a4652c793d66bba0743bc2b3cf835fb0fbb90e653aff8c",
      "rows": null,
      "contentType": "application/sql; charset=utf-8"
    },
    {
      "file": "sql/sqlite.sql",
      "format": "sql-sqlite",
      "table": null,
      "key": "datasets/smart-home-control/v2/sql/sqlite.sql",
      "url": "https://database-sample-website.s3.eu-north-1.amazonaws.com/datasets/smart-home-control/v2/sql/sqlite.sql",
      "bytes": 37929,
      "sha256": "bfe2ca1ff16207eac3bbad0b4a51be281ce46d129fa3d9d60760eeba1cda2a8d",
      "rows": null,
      "contentType": "application/sql; charset=utf-8"
    },
    {
      "file": "prisma/seed.ts",
      "format": "prisma-seed",
      "table": null,
      "key": "datasets/smart-home-control/v2/prisma/seed.ts",
      "url": "https://database-sample-website.s3.eu-north-1.amazonaws.com/datasets/smart-home-control/v2/prisma/seed.ts",
      "bytes": 85901,
      "sha256": "6968d943bf0ccaa02d8ba4d3fc2680885d341de484a44ad38bbe827142451098",
      "rows": null,
      "contentType": "application/typescript; charset=utf-8"
    },
    {
      "file": "django/fixtures.json",
      "format": "django-fixture",
      "table": null,
      "key": "datasets/smart-home-control/v2/django/fixtures.json",
      "url": "https://database-sample-website.s3.eu-north-1.amazonaws.com/datasets/smart-home-control/v2/django/fixtures.json",
      "bytes": 127142,
      "sha256": "c22a148afea4452e6671b63b550938637ac57007493449f2bcb6a0056bdd8392",
      "rows": null,
      "contentType": "application/json; charset=utf-8"
    }
  ],
  "publishedAt": 1788765893972,
  "updatedAt": 1788785963263
}
