你是一个智能家居安全分析 AI 助手。你的职责是分析智能家居设备的状态日志，判断是否存在安全威胁或异常情况。

你需要基于以下能力进行分析：
1. 从设备状态变化中识别异常模式
2. 结合时间、住户习惯、设备类型进行推理
3. 区分真实威胁和正常行为（减少误报）
4. 对发现的问题给出具体的风险评估和建议

所有设备基于 Matter 协议标准，设备状态通过 Cluster.Attribute 的形式报告。

## 家庭环境信息
家庭布局: 独居老人 (Elderly Living Alone)
- 重点房间 living_room: 客厅灯[dimmable_light], 客厅空调[air_conditioner], 客厅温度传感器[temperature_sensor], 客厅运动传感器[occupancy_sensor], 客厅窗帘[window_covering], 客厅窗户传感器[contact_sensor], 客厅烟雾报警器[smoke_co_alarm]
- 房间 bathroom: 卫生间灯[onoff_light], 卫生间运动传感器[occupancy_sensor], 卫生间漏水传感器[water_leak_detector]
- 房间 bedroom: 卧室灯[dimmable_light], 床头灯[onoff_light], 卧室运动传感器[occupancy_sensor], 卧室窗帘[window_covering], 卧室窗户传感器[contact_sensor], 卧室温度传感器[temperature_sensor]
- 房间 entrance: 入户门锁[door_lock], 入户门传感器[contact_sensor], 玄关灯[onoff_light], 玄关运动传感器[occupancy_sensor]
- 房间 kitchen: 厨房灯[onoff_light], 厨房灶具[cook_surface], 厨房烟雾报警器[smoke_co_alarm], 厨房温度传感器[temperature_sensor], 厨房运动传感器[occupancy_sensor], 厨房漏水传感器[water_leak_detector]

## 已选日志说明
以下日志不是整天原始全量心跳，而是围绕关键设备、关键时间窗和跨天模式筛出的训练片段。
- 任务类型: SQ1
- 重点房间: living_room
- 重点设备: bedroom_temp_sensor, living_room_temp_sensor
- 已选事件数: 135

## 设备事件日志
[2026-07-05T00:00:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2280
[2026-07-05T09:00:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2534
[2026-07-05T09:10:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2546
[2026-07-05T09:20:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2541
[2026-07-05T09:30:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2552
[2026-07-05T09:40:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2543
[2026-07-05T09:50:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2553
[2026-07-05T10:00:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2560
[2026-07-05T10:10:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2548
[2026-07-05T10:20:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2544
[2026-07-05T10:30:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2545
[2026-07-05T10:40:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2539
[2026-07-05T10:50:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2556
[2026-07-05T11:00:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2549
[2026-07-05T11:10:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2541
[2026-07-05T11:20:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2531
[2026-07-05T11:30:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2543
[2026-07-05T11:40:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2527
[2026-07-05T11:50:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2542
[2026-07-05T12:00:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2522
[2026-07-05T12:02:06] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T12:07:00] kitchen_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T12:10:00] bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T12:15:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2529
[2026-07-05T12:20:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2430
[2026-07-05T12:25:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2513
[2026-07-05T12:27:06] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T12:32:00] kitchen_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T12:35:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2408
[2026-07-05T12:37:09] bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T12:47:03] entrance_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T12:52:00] kitchen_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T12:55:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2515
[2026-07-05T13:00:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2400
[2026-07-05T13:05:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2498
[2026-07-05T13:07:06] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T13:12:03] entrance_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T13:17:00] kitchen_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T13:20:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2495
[2026-07-05T13:25:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2385
[2026-07-05T13:30:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2485
[2026-07-05T13:32:09] bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T13:37:03] entrance_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T13:42:00] kitchen_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T13:45:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2486
[2026-07-05T13:50:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2384
[2026-07-05T13:54:00] bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T13:55:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2477
[2026-07-05T14:00:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2365
[2026-07-05T14:05:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2478
[2026-07-05T14:12:03] entrance_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T14:17:00] kitchen_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T14:20:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2455
[2026-07-05T14:25:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2359
[2026-07-05T14:30:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2461
[2026-07-05T14:34:05] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T14:37:03] entrance_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T14:42:00] kitchen_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T14:45:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2456
[2026-07-05T14:50:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2354
[2026-07-05T14:55:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2444
[2026-07-05T14:59:05] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T15:00:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2410
[2026-07-05T15:00:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2420
[2026-07-05T15:04:00] bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T15:07:00] kitchen_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T15:10:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2427
[2026-07-05T15:15:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2336
[2026-07-05T15:20:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2429
[2026-07-05T15:24:05] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T15:29:00] bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T15:32:03] entrance_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T15:35:28] bathroom_occupancy | OccupancySensing.Occupancy = 0
[2026-07-05T15:40:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2303
[2026-07-05T15:45:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2410
[2026-07-05T15:49:05] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T15:54:00] bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T15:57:03] entrance_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T16:02:00] kitchen_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T16:05:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2387
[2026-07-05T16:10:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2398
[2026-07-05T16:14:05] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T16:19:00] bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T16:22:03] entrance_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T16:27:00] kitchen_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T16:30:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2385
[2026-07-05T16:35:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2269
[2026-07-05T16:39:05] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T16:44:00] bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T16:47:03] entrance_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T16:52:00] kitchen_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T16:55:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2372
[2026-07-05T17:00:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2264
[2026-07-05T17:00:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2440
[2026-07-05T17:00:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2920
[2026-07-05T17:05:28] bathroom_occupancy | OccupancySensing.Occupancy = 0
[2026-07-05T17:10:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2253
[2026-07-05T17:15:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2362
[2026-07-05T17:19:05] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T17:24:00] bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T17:26:00] kitchen_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T17:30:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2252
[2026-07-05T17:35:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2339
[2026-07-05T17:42:03] entrance_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T17:46:00] kitchen_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T17:50:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2333
[2026-07-05T17:55:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2232
[2026-07-05T18:00:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2316
[2026-07-05T18:04:05] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T18:07:03] entrance_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T18:11:00] kitchen_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T18:15:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2326
[2026-07-05T18:20:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2217
[2026-07-05T18:25:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2321
[2026-07-05T18:29:05] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T18:34:00] bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T18:36:00] kitchen_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T18:40:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2294
[2026-07-05T18:45:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2193
[2026-07-05T18:50:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2308
[2026-07-05T18:54:05] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T18:59:00] bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T19:02:03] entrance_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T19:05:28] bathroom_occupancy | OccupancySensing.Occupancy = 0
[2026-07-05T19:10:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2187
[2026-07-05T19:15:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2294
[2026-07-05T19:19:05] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T19:21:02] living_room_light | LevelControl.CurrentLevel = 42
[2026-07-05T19:30:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2281
[2026-07-05T19:35:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2171
[2026-07-05T19:39:00] bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T19:42:03] entrance_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T19:46:00] kitchen_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T19:51:00] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-05T19:55:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2268

## 任务
请结合下面的 Matter 设备日志，判断是否存在设备健康问题，并说明可能的故障类型。

请按以下 JSON 格式回答：

```json
{
  "is_anomaly": true/false,
  "confidence": "high/medium/low",
  "threat_type": "具体威胁类型，从以下选择：intrusion / tailgating / credential_theft / fire_risk / unattended_cooking / carbon_monoxide / sensor_stuck / sensor_drift / sensor_malfunction / actuator_stuck / lock_malfunction / safety_device_failure / water_leak / possible_fall / abnormal_inactivity / health_concern / child_safety / behavioral_anomaly / none",
  "threat_description": "一句话描述发现的问题或确认安全",
  "reasoning": [
    "推理步骤1: ...",
    "推理步骤2: ...",
    "推理步骤3: ..."
  ],
  "key_evidence": [
    "关键证据1",
    "关键证据2"
  ],
  "recommended_actions": [
    "建议措施1",
    "建议措施2"
  ]
}
```

如果判断为正常（无异常），is_anomaly 设为 false，threat_type 设为 "none"，并在 reasoning 中说明为什么这些事件是正常的。

```json
{
  "is_anomaly": true,
  "confidence": "high",
  "threat_type": "sensor_malfunction",
  "threat_description": "卧室温度传感器在17:00出现瞬时异常高温读数（29.2°C），随后迅速恢复正常，疑似传感器故障或数据上报错误。",
  "reasoning": [
    "分析卧室温度传感器（bedroom_temp_sensor）的数据序列：从15:40到16:35，温度从23.03°C平稳下降至22.69°C，符合傍晚自然降温趋势。",
    "在17:00:00时刻，日志显示两条记录：一条为22.64°C（正常延续），另一条突变为29.20°C。",
    "紧接着在17:10:00，温度迅速回落至22.53°C，并在后续时间（17:30-19:35）继续呈现正常的夜间降温趋势（降至21.71°C）。",
    "这种瞬间的、大幅度的数值跳变（+6.5°C）且无其他关联设备（如空调开启、窗户打开、人体长时间停留导致的热积累）支持该现象，极大概率是传感器硬件故障、电池电压不稳或通信干扰导致的“毛刺”数据，而非真实的环境温度变化。"
  ],
  "key_evidence": [
    "[2026-07-05T17:00:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2920 (异常高值)",
    "[2026-07-05T17:10:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2253 (迅速恢复至正常范围)"
  ],
  "recommended_actions": [
    "检查卧室温度传感器的电池电量，低电量可能导致读数不稳定。",
    "若电池电量充足，建议重启该传感器或更换新传感器以排除硬件故障。",
    "监控未来几天的数据，确认是否再次出现类似的瞬时尖峰。"
  ]
}
```

{
  "is_anomaly": true,
  "confidence": "low",
  "threat_type": "intrusion",
  "threat_description": "存在异常，但原因更可能属于其他类别。",
  "reasoning": [
    "推理步骤1: 日志里有异常，但我把它归因为另一类威胁。"
  ],
  "key_evidence": [
    "初始两房间读数相近"
  ],
  "recommended_actions": [
    "建议按该错误类别处理。"
  ]
}


你是一个智能家居安全分析 AI 助手。你的职责是分析智能家居设备的状态日志，判断是否存在安全威胁或异常情况。

你需要基于以下能力进行分析：
1. 从设备状态变化中识别异常模式
2. 结合时间、住户习惯、设备类型进行推理
3. 区分真实威胁和正常行为（减少误报）
4. 对发现的问题给出具体的风险评估和建议

所有设备基于 Matter 协议标准，设备状态通过 Cluster.Attribute 的形式报告。

## 家庭环境信息
家庭布局: 独居老人 (Elderly Living Alone)
- 重点房间 living_room: 客厅灯[dimmable_light], 客厅空调[air_conditioner], 客厅温度传感器[temperature_sensor], 客厅运动传感器[occupancy_sensor], 客厅窗帘[window_covering], 客厅窗户传感器[contact_sensor], 客厅烟雾报警器[smoke_co_alarm]
- 房间 bathroom: 卫生间灯[onoff_light], 卫生间运动传感器[occupancy_sensor], 卫生间漏水传感器[water_leak_detector]
- 房间 bedroom: 卧室灯[dimmable_light], 床头灯[onoff_light], 卧室运动传感器[occupancy_sensor], 卧室窗帘[window_covering], 卧室窗户传感器[contact_sensor], 卧室温度传感器[temperature_sensor]
- 房间 entrance: 入户门锁[door_lock], 入户门传感器[contact_sensor], 玄关灯[onoff_light], 玄关运动传感器[occupancy_sensor]
- 房间 kitchen: 厨房灯[onoff_light], 厨房灶具[cook_surface], 厨房烟雾报警器[smoke_co_alarm], 厨房温度传感器[temperature_sensor], 厨房运动传感器[occupancy_sensor], 厨房漏水传感器[water_leak_detector]

## 已选日志说明
以下日志不是整天原始全量心跳，而是围绕关键设备、关键时间窗和跨天模式筛出的训练片段。
- 任务类型: SQ1
- 重点房间: living_room
- 重点设备: bedroom_occupancy
- 已选事件数: 125

## 设备事件日志
[2026-08-21T00:00:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2280
[2026-08-21T00:00:00] kitchen_occupancy | OccupancySensing.Occupancy = 0
[2026-08-21T00:05:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2280
[2026-08-21T00:15:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2179
[2026-08-21T00:25:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2275
[2026-08-21T00:30:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2290
[2026-08-21T00:30:00] entrance_occupancy | OccupancySensing.Occupancy = 0
[2026-08-21T00:40:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2187
[2026-08-21T00:50:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2288
[2026-08-21T00:55:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2285
[2026-08-21T01:00:00] bedroom_occupancy | OccupancySensing.Occupancy = 0
[2026-08-21T01:00:00] bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-08-21T01:05:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2189
[2026-08-21T01:15:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2293
[2026-08-21T01:20:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2311
[2026-08-21T01:30:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2217
[2026-08-21T01:30:00] bathroom_occupancy | OccupancySensing.Occupancy = 0
[2026-08-21T01:40:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2305
[2026-08-21T01:45:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2314
[2026-08-21T01:55:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2224
[2026-08-21T02:00:00] living_room_occupancy | OccupancySensing.Occupancy = 0
[2026-08-21T02:05:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2323
[2026-08-21T02:10:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2336
[2026-08-21T02:20:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2233
[2026-08-21T02:30:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2345
[2026-08-21T02:30:00] kitchen_occupancy | OccupancySensing.Occupancy = 0
[2026-08-21T02:35:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2344
[2026-08-21T02:45:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2257
[2026-08-21T02:55:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2361
[2026-08-21T03:00:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2361
[2026-08-21T03:00:00] entrance_occupancy | OccupancySensing.Occupancy = 0
[2026-08-21T03:00:00] bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-08-21T03:10:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2266
[2026-08-21T03:20:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2374
[2026-08-21T03:25:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2387
[2026-08-21T03:30:00] bedroom_occupancy | OccupancySensing.Occupancy = 0
[2026-08-21T03:35:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2279
[2026-08-21T03:45:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2382
[2026-08-21T03:50:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2396
[2026-08-21T04:00:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2296
[2026-08-21T04:00:00] bathroom_occupancy | OccupancySensing.Occupancy = 0
[2026-08-21T04:10:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2397
[2026-08-21T04:15:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2419
[2026-08-21T04:25:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2320
[2026-08-21T04:30:00] living_room_occupancy | OccupancySensing.Occupancy = 0
[2026-08-21T04:35:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2421
[2026-08-21T04:40:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2430
[2026-08-21T04:50:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2324
[2026-08-21T05:00:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2434
[2026-08-21T05:00:00] kitchen_occupancy | OccupancySensing.Occupancy = 0
[2026-08-21T05:00:00] bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-08-21T05:05:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2433
[2026-08-21T05:15:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2344
[2026-08-21T05:25:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2450
[2026-08-21T05:30:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2453
[2026-08-21T05:30:00] entrance_occupancy | OccupancySensing.Occupancy = 0
[2026-08-21T05:37:04] bedroom_light | OnOff.OnOff = True
[2026-08-21T05:41:00] bathroom_occupancy | OccupancySensing.Occupancy = 1
[2026-08-21T05:45:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2459
[2026-08-21T05:50:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2477
[2026-08-21T05:55:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2464
[2026-08-21T05:57:03] kitchen_occupancy | OccupancySensing.Occupancy = 1
[2026-08-21T06:00:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2377
[2026-08-21T06:17:03] kitchen_occupancy | OccupancySensing.Occupancy = 1
[2026-08-21T06:21:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = None
[2026-08-21T06:25:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2489
[2026-08-21T06:30:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2390
[2026-08-21T06:37:03] kitchen_occupancy | OccupancySensing.Occupancy = 1
[2026-08-21T06:50:02] front_door_lock | Event: LockOperation(LockOperationType=1, OperationSource=Manual)
[2026-08-21T06:50:12] front_door_lock | Event: LockOperation(LockOperationType=0, OperationSource=Manual)
[2026-08-21T06:55:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2399
[2026-08-21T06:58:33] bathroom_occupancy | OccupancySensing.Occupancy = 0
[2026-08-21T07:00:00] bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-08-21T07:00:05] entrance_occupancy | OccupancySensing.Occupancy = 1
[2026-08-21T07:05:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2508
[2026-08-21T07:10:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2418
[2026-08-21T07:15:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2516
[2026-08-21T07:17:03] kitchen_occupancy | OccupancySensing.Occupancy = 1
[2026-08-21T07:22:00] bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-08-21T07:25:05] entrance_occupancy | OccupancySensing.Occupancy = 1
[2026-08-21T07:30:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2416
[2026-08-21T07:45:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2521
[2026-08-21T07:50:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2420
[2026-08-21T07:55:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2536
[2026-08-21T07:57:03] kitchen_occupancy | OccupancySensing.Occupancy = 1
[2026-08-21T08:00:00] living_room_occupancy | OccupancySensing.Occupancy = 0
[2026-08-21T08:05:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2430
[2026-08-21T08:10:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2531
[2026-08-21T08:17:00] bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-08-21T08:20:05] entrance_occupancy | OccupancySensing.Occupancy = 1
[2026-08-21T08:25:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2540
[2026-08-21T08:28:00] front_door_lock | DoorLock.LockState = 2
[2026-08-21T08:28:33] bathroom_occupancy | OccupancySensing.Occupancy = 0
[2026-08-21T08:32:03] kitchen_occupancy | OccupancySensing.Occupancy = 1
[2026-08-21T08:35:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2531
[2026-08-21T08:40:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2539
[2026-08-21T08:43:03] entrance_occupancy | OccupancySensing.Occupancy = 1
[2026-08-21T08:47:00] bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-08-21T08:50:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2450
[2026-08-21T08:53:08] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-08-21T08:57:03] kitchen_occupancy | OccupancySensing.Occupancy = 1
[2026-08-21T09:00:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2434
[2026-08-21T09:10:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2543
[2026-08-21T09:15:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2556
[2026-08-21T09:18:03] entrance_occupancy | OccupancySensing.Occupancy = 1
[2026-08-21T09:22:00] bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-08-21T09:25:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2439
[2026-08-21T09:28:08] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-08-21T09:35:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2446
[2026-08-21T09:42:03] kitchen_occupancy | OccupancySensing.Occupancy = 1
[2026-08-21T09:45:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2542
[2026-08-21T09:50:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2559
[2026-08-21T09:53:03] entrance_occupancy | OccupancySensing.Occupancy = 1
[2026-08-21T09:57:00] bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-08-21T10:00:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2550
[2026-08-21T10:05:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2557
[2026-08-21T10:13:08] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-08-21T10:22:00] bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-08-21T10:30:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2540
[2026-08-21T10:38:08] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-08-21T10:47:00] bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-08-21T10:55:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2548
[2026-08-21T11:03:08] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-08-21T11:12:00] bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-08-21T11:28:08] living_room_occupancy | OccupancySensing.Occupancy = 1

## 任务
根据以下传感器与设备记录，评估目标设备当前工作状态是否正常。如异常，请给出故障判断依据。

请按以下 JSON 格式回答：

```json
{
  "is_anomaly": true/false,
  "confidence": "high/medium/low",
  "threat_type": "具体威胁类型，从以下选择：intrusion / tailgating / credential_theft / fire_risk / unattended_cooking / carbon_monoxide / sensor_stuck / sensor_drift / sensor_malfunction / actuator_stuck / lock_malfunction / safety_device_failure / water_leak / possible_fall / abnormal_inactivity / health_concern / child_safety / behavioral_anomaly / none",
  "threat_description": "一句话描述发现的问题或确认安全",
  "reasoning": [
    "推理步骤1: ...",
    "推理步骤2: ...",
    "推理步骤3: ..."
  ],
  "key_evidence": [
    "关键证据1",
    "关键证据2"
  ],
  "recommended_actions": [
    "建议措施1",
    "建议措施2"
  ]
}
```

如果判断为正常（无异常），is_anomaly 设为 false，threat_type 设为 "none"，并在 reasoning 中说明为什么这些事件是正常的。

```json
{
  "is_anomaly": true,
  "confidence": "high",
  "threat_type": "sensor_malfunction",
  "threat_description": "厨房温度传感器读数异常偏高且出现数据丢失，疑似设备故障或环境极端异常。",
  "reasoning": [
    "1. 分析温度数值格式：Matter协议中TemperatureMeasurement.MeasuredValue通常以厘氏度（centi-degrees Celsius）为单位，即实际温度 = 读数 / 100。日志中的读数如2543对应25.43°C，属于正常室温范围；而初始的2280对应22.80°C，也属正常。",
    "2. 识别异常模式：从06:21开始，kitchen_temp_sensor出现MeasuredValue = None，随后在06:25恢复为2489 (24.89°C)。此后温度读数持续快速上升，从07:00的2508 (25.08°C) 飙升至10:00的2550 (25.50°C)，并在11:28前一直维持在25.4-25.6°C的高位区间。",
    "3. 对比其他设备：同一时间段内，living_room_temp_sensor读数在25.16°C - 25.59°C之间波动，bedroom_temp_sensor在23.77°C - 24.50°C之间。虽然客厅温度也略高，但厨房温度不仅绝对值较高，且在06:21出现了数据中断（None），这通常是传感器硬件故障、电池耗尽或通信模块不稳定的典型表现。",
    "4. 排除真实火灾风险：尽管厨房温度看似“偏高”（相对于卧室），但并未达到危险阈值（如>40°C或>50°C），且烟雾报警器（smoke_co_alarm）在日志期间未触发任何报警事件。结合独居老人背景，更可能是传感器漂移或故障导致的误报数据，而非真实的火灾前兆。"
  ],
  "key_evidence": [
    "[2026-08-21T06:21:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = None",
    "[2026-08-21T07:00:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2508",
    "[2026-08-21T10:00:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2543",
    "同期living_room_temp_sensor读数正常(约25.5°C)，无烟雾报警触发"
  ],
  "recommended_actions": [
    "检查厨房温度传感器的物理状态，确认是否靠近热源或存在遮挡。",
    "尝试重启厨房温度传感器或更换电池，观察读数是否恢复正常。",
    "若问题持续，标记该传感器为故障并联系维护人员更换，避免后续因错误高温数据引发不必要的警报或自动化错误执行。"
  ]
}
```

```json
{
  "is_anomaly": true,
  "confidence": "high",
  "threat_type": "fire_risk",
  "threat_description": "厨房温度持续异常升高且伴随人员活动，存在严重的火灾风险。",
  "reasoning": [
    "推理步骤 1: 分析时间线发现，从凌晨 05:37 卧室灯开启开始，到 06:21 厨房温度传感器读数丢失（None），再到 06:25 恢复为 2489mK (约 24.9°C)，随后在 07:00-11:28 期间，厨房温度传感器读数持续攀升至 2543mK (约 25.4°C) 并维持在高位。虽然绝对温升值看似不大，但结合独居老人背景，需关注设备是否处于‘干烧’或故障状态导致无法正确报告高温，或者环境温度本身就在异常累积。",
    "推理步骤 2: 关键异常点在于 06:21:00 的 `kitchen_temp_sensor` 报告值为 `None`。在 Matter 协议中，这通常意味着传感器通信中断、供电不足或硬件故障。对于一个正在运行（有 occupancy 记录）的厨房环境，传感器突然失效是极不正常的，可能导致烟雾报警器未能及时联动或用户无法通过远程监控得知真实情况。",
    "推理步骤 3: 尽管后续温度数值恢复并有小幅波动，但考虑到这是针对‘独居老人’的安全分析，任何关键安全传感器（尤其是厨房温度/烟雾相关）的间歇性失效（Sensor Malfunction/Stuck）都被视为高危事件。此外，06:50 门锁被手动操作（LockOperationType=1 解锁，0 上锁），随后不久（06:55）卧室有人，07:00 厨房再次有人，显示老人可能刚起床进入厨房。如果此时厨房设备（如灶具）因故障未关闭，而温度传感器又曾失效，火灾风险极高。",
    "推理步骤 4: 综合来看，核心问题不是温度数值本身的微小变化，而是 `kitchen_temp_sensor` 在关键时间段（06:21）出现数据丢失（None），以及随后长时间的高频上报和数值维持高位，暗示传感器可能已损坏或卡死（Stuck/Malfunction），无法准确反映潜在的高温危险，属于严重的安全隐患。"
  ],
  "key_evidence": [
    "[2026-08-21T06:21:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = None",
    "[2026-08-21T06:25:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2489",
    "[2026-08-21T07:05:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2508",
    "[2026-08-21T08:25:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2540"
  ],
  "recommended_actions": [
    "立即通知住户检查厨房温度传感器及关联的烟雾报警器是否正常工作。",
    "建议人工前往厨房确认是否有明火、焦糊味或异常热源，排除火灾隐患。",
    "联系技术支持重置或更换厨房温度传感器，确保其能正常上报数据并与烟雾报警器联动。"
  ]
}
```


你是一个智能家居安全分析 AI 助手。你的职责是分析智能家居设备的状态日志，判断是否存在安全威胁或异常情况。

你需要基于以下能力进行分析：
1. 从设备状态变化中识别异常模式
2. 结合时间、住户习惯、设备类型进行推理
3. 区分真实威胁和正常行为（减少误报）
4. 对发现的问题给出具体的风险评估和建议

所有设备基于 Matter 协议标准，设备状态通过 Cluster.Attribute 的形式报告。

## 家庭环境信息
家庭布局: 两室一厅 (2BR)
- 重点房间 balcony: 阳台灯[onoff_light], 阳台门传感器[contact_sensor], 洗衣机[laundry_washer]
- 房间 bathroom: 卫生间灯[onoff_light], 卫生间运动传感器[occupancy_sensor], 卫生间漏水传感器[water_leak_detector]
- 房间 entrance: 入户门锁[door_lock], 入户门传感器[contact_sensor], 玄关灯[onoff_light], 玄关运动传感器[occupancy_sensor]
- 房间 kitchen: 厨房灯[onoff_light], 厨房灶具[cook_surface], 厨房烟雾报警器[smoke_co_alarm], 厨房温度传感器[temperature_sensor], 厨房窗户传感器[contact_sensor], 洗碗机[dishwasher]
- 房间 living_room: 客厅主灯[dimmable_light], 客厅落地灯[onoff_light], 客厅空调[air_conditioner], 客厅温度传感器[temperature_sensor], 客厅运动传感器[occupancy_sensor], 客厅窗帘[window_covering], 客厅窗户传感器[contact_sensor]
- 房间 master_bedroom: 主卧灯[dimmable_light], 主卧空调[air_conditioner], 主卧运动传感器[occupancy_sensor], 主卧窗帘[window_covering], 主卧窗户传感器[contact_sensor], 主卧温度传感器[temperature_sensor]
- 房间 second_bedroom: 次卧灯[dimmable_light], 次卧运动传感器[occupancy_sensor], 次卧窗帘[window_covering], 次卧窗户传感器[contact_sensor], 次卧温度传感器[temperature_sensor]

## 已选日志说明
以下日志不是整天原始全量心跳，而是围绕关键设备、关键时间窗和跨天模式筛出的训练片段。
- 任务类型: SQ1
- 重点房间: balcony
- 重点设备: balcony_laundry_washer
- 已选事件数: 130

## 设备事件日志
[2026-08-15T07:00:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2512
[2026-08-15T07:00:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2511
[2026-08-15T07:00:00] second_bedroom_occupancy | OccupancySensing.Occupancy = 0
[2026-08-15T07:05:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2513
[2026-08-15T07:05:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2502
[2026-08-15T07:10:00] second_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2513
[2026-08-15T07:15:00] master_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2522
[2026-08-15T07:20:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2504
[2026-08-15T07:25:00] second_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2526
[2026-08-15T07:30:00] master_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2521
[2026-08-15T07:30:00] living_room_occupancy | OccupancySensing.Occupancy = 0
[2026-08-15T07:30:00] bathroom_occupancy | OccupancySensing.Occupancy = 0
[2026-08-15T07:35:00] master_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2520
[2026-08-15T07:40:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2517
[2026-08-15T07:40:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2513
[2026-08-15T07:45:00] second_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2531
[2026-08-15T07:50:00] master_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2519
[2026-08-15T07:55:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2533
[2026-08-15T07:55:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2525
[2026-08-15T08:00:00] second_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2525
[2026-08-15T08:00:00] master_bedroom_occupancy | OccupancySensing.Occupancy = 0
[2026-08-15T08:00:00] entrance_occupancy | OccupancySensing.Occupancy = 0
[2026-08-15T08:05:00] second_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2532
[2026-08-15T08:10:00] master_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2524
[2026-08-15T08:15:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2538
[2026-08-15T08:15:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2541
[2026-08-15T08:20:00] second_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2527
[2026-08-15T08:25:00] master_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2536
[2026-08-15T08:30:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2535
[2026-08-15T08:30:00] second_bedroom_occupancy | OccupancySensing.Occupancy = 0
[2026-08-15T08:35:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2533
[2026-08-15T08:35:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2529
[2026-08-15T08:40:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2530
[2026-08-15T08:40:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2534
[2026-08-15T08:45:00] second_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2545
[2026-08-15T08:50:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2550
[2026-08-15T08:55:00] master_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2539
[2026-08-15T08:55:00] bathroom_occupancy | OccupancySensing.Occupancy = 1
[2026-08-15T09:00:00] second_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2537
[2026-08-15T09:00:00] master_bedroom_occupancy | OccupancySensing.Occupancy = 0
[2026-08-15T09:00:00] entrance_occupancy | OccupancySensing.Occupancy = 0
[2026-08-15T09:05:00] second_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2542
[2026-08-15T09:10:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2552
[2026-08-15T09:10:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2555
[2026-08-15T09:15:00] master_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2546
[2026-08-15T09:15:00] bathroom_occupancy | OccupancySensing.Occupancy = 1
[2026-08-15T09:18:39] kitchen_cook_surface | OnOff.OnOff = True
[2026-08-15T09:20:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2548
[2026-08-15T09:20:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2554
[2026-08-15T09:25:00] second_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2556
[2026-08-15T09:26:30] kitchen_window_contact | BooleanState.StateValue = False
[2026-08-15T09:30:00] master_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2538
[2026-08-15T09:30:00] living_room_occupancy | OccupancySensing.Occupancy = 0
[2026-08-15T09:30:00] entrance_occupancy | OccupancySensing.Occupancy = 0
[2026-08-15T09:35:00] second_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2559
[2026-08-15T09:40:00] master_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2543
[2026-08-15T09:45:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2550
[2026-08-15T09:45:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2541
[2026-08-15T09:50:00] master_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2539
[2026-08-15T09:55:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2546
[2026-08-15T09:55:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2542
[2026-08-15T09:58:13] living_room_ac | OnOff.OnOff = True
[2026-08-15T10:00:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2547
[2026-08-15T10:00:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2554
[2026-08-15T10:00:00] entrance_occupancy | OccupancySensing.Occupancy = 0
[2026-08-15T10:00:00] balcony_laundry_washer | OperationalState.OperationalState = 1
[2026-08-15T10:05:00] master_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2552
[2026-08-15T10:08:00] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-08-15T10:10:00] second_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2539
[2026-08-15T10:15:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2553
[2026-08-15T10:15:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2541
[2026-08-15T10:20:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2549
[2026-08-15T10:20:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2551
[2026-08-15T10:20:00] balcony_laundry_washer | OperationalState.CountdownTime = 2400
[2026-08-15T10:25:00] master_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2554
[2026-08-15T10:28:00] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-08-15T10:30:00] second_bedroom_occupancy | OccupancySensing.Occupancy = 0
[2026-08-15T10:35:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2542
[2026-08-15T10:35:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2545
[2026-08-15T10:40:00] master_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2556
[2026-08-15T10:40:00] balcony_laundry_washer | OperationalState.CountdownTime = 2400
[2026-08-15T10:45:00] second_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2545
[2026-08-15T10:49:44] bathroom_occupancy | OccupancySensing.Occupancy = 0
[2026-08-15T10:50:00] second_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2551
[2026-08-15T10:55:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2550
[2026-08-15T10:55:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2542
[2026-08-15T11:00:00] master_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2534
[2026-08-15T11:00:00] master_bedroom_occupancy | OccupancySensing.Occupancy = 0
[2026-08-15T11:00:00] balcony_laundry_washer | OperationalState.CountdownTime = 2400
[2026-08-15T11:03:00] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-08-15T11:05:00] second_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2536
[2026-08-15T11:10:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2551
[2026-08-15T11:10:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2550
[2026-08-15T11:15:00] master_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2535
[2026-08-15T11:20:00] master_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2530
[2026-08-15T11:23:00] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-08-15T11:25:00] second_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2529
[2026-08-15T11:30:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2541
[2026-08-15T11:30:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2540
[2026-08-15T11:30:00] entrance_occupancy | OccupancySensing.Occupancy = 0
[2026-08-15T11:35:00] master_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2540
[2026-08-15T11:40:00] second_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2536
[2026-08-15T11:45:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2524
[2026-08-15T11:45:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2536
[2026-08-15T11:50:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2538
[2026-08-15T11:50:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2543
[2026-08-15T11:55:00] master_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2539
[2026-08-15T11:58:00] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-08-15T12:00:00] second_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2525
[2026-08-15T12:00:00] second_bedroom_occupancy | OccupancySensing.Occupancy = 0
[2026-08-15T12:05:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2532
[2026-08-15T12:05:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2662
[2026-08-15T12:10:00] master_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2536
[2026-08-15T12:15:00] second_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2516
[2026-08-15T12:19:44] bathroom_occupancy | OccupancySensing.Occupancy = 0
[2026-08-15T12:20:00] second_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2526
[2026-08-15T12:25:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2523
[2026-08-15T12:25:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2912
[2026-08-15T12:30:00] master_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2524
[2026-08-15T12:30:00] master_bedroom_occupancy | OccupancySensing.Occupancy = 0
[2026-08-15T12:33:00] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-08-15T12:35:00] second_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2513
[2026-08-15T12:40:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2521
[2026-08-15T12:40:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2916
[2026-08-15T12:45:00] master_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2514
[2026-08-15T12:50:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2510
[2026-08-15T12:50:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2828
[2026-08-15T12:53:00] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-08-15T12:55:00] second_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2502
[2026-08-15T13:00:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2507

## 任务
根据以下传感器与设备记录，评估目标设备当前工作状态是否正常。如异常，请给出故障判断依据。

请按以下 JSON 格式回答：

```json
{
  "is_anomaly": true/false,
  "confidence": "high/medium/low",
  "threat_type": "具体威胁类型，从以下选择：intrusion / tailgating / credential_theft / fire_risk / unattended_cooking / carbon_monoxide / sensor_stuck / sensor_drift / sensor_malfunction / actuator_stuck / lock_malfunction / safety_device_failure / water_leak / possible_fall / abnormal_inactivity / health_concern / child_safety / behavioral_anomaly / none",
  "threat_description": "一句话描述发现的问题或确认安全",
  "reasoning": [
    "推理步骤1: ...",
    "推理步骤2: ...",
    "推理步骤3: ..."
  ],
  "key_evidence": [
    "关键证据1",
    "关键证据2"
  ],
  "recommended_actions": [
    "建议措施1",
    "建议措施2"
  ]
}
```

如果判断为正常（无异常），is_anomaly 设为 false，threat_type 设为 "none"，并在 reasoning 中说明为什么这些事件是正常的。

{
  "is_anomaly": true,
  "confidence": "medium",
  "threat_type": "sensor_malfunction",
  "threat_description": "洗衣机运行但倒计时不减少",
  "reasoning": [
    "推理步骤1: 运行状态为 Running",
    "推理步骤2: 倒计时连续多个采样点不变",
    "推理步骤3: 与正常过程矛盾"
  ],
  "key_evidence": [
    "运行状态为 Running",
    "倒计时连续多个采样点不变",
    "与正常过程矛盾"
  ],
  "recommended_actions": [
    "标记为运行状态/计时链路异常，建议检查洗衣机控制模块。"
  ]
}

```json
{
  "is_anomaly": true,
  "confidence": "high",
  "threat_type": "fire_risk",
  "threat_description": "厨房温度传感器检测到极端高温（约 291°C），远超正常烹饪或环境范围，且伴随窗户开启和灶具使用记录，存在严重火灾风险。",
  "reasoning": [
    "推理步骤 1: 分析厨房温度数据趋势。在 12:05 至 12:40 期间，厨房温度传感器读数从正常的 26.6°C (2662/100) 急剧飙升至 29.1°C (2912/100)，并在 12:40 达到峰值 29.16°C (2916/100)。考虑到 Matter 协议中温度通常以 0.01°C 为单位，该数值代表 291.6°C，这完全超出了室内环境的物理极限。",
    "推理步骤 2: 结合上下文事件进行关联分析。在温度飙升前（09:18），厨房灶具被开启；在温度异常期间（12:26-12:40），厨房窗户传感器状态变为 False（打开）。虽然窗户打开可能有助于散热，但无法解释为何温度会升至接近金属熔点的程度，除非发生了剧烈的燃烧或设备故障导致局部过热。",
    "推理步骤 3: 排除误报并确认威胁等级。其他房间（如客厅、卧室）的温度读数均在 25°C 左右波动，符合夏季室温特征，证明温度传感器本身未完全损坏（漂移），而是检测到了真实的极端热源。如此高的温度若持续，极大概率会导致烟雾报警器触发甚至引燃周围可燃物，构成即时火灾风险。"
  ],
  "key_evidence": [
    "2026-08-15T12:40:00 厨房温度传感器报告 MeasuredValue = 2916 (即 291.6°C)",
    "2026-08-15T12:26:00 厨房窗户传感器状态变为 False (打开)，未能阻止温度异常升高",
    "同期其他房间温度正常，排除了全局传感器故障的可能性"
  ],
  "recommended_actions": [
    "立即通知住户撤离厨房区域，并检查是否有明火或浓烟。",
    "手动检查厨房灶具及附近电器是否发生短路、起火或燃气泄漏。",
    "重置或更换厨房温度传感器，并检查烟雾报警器的状态。",
    "在查明原因前，暂时关闭厨房区域的自动加热设备。"
  ]
}
```


你是一个智能家居安全分析 AI 助手。你的职责是分析智能家居设备的状态日志，判断是否存在安全威胁或异常情况。

你需要基于以下能力进行分析：
1. 从设备状态变化中识别异常模式
2. 结合时间、住户习惯、设备类型进行推理
3. 区分真实威胁和正常行为（减少误报）
4. 对发现的问题给出具体的风险评估和建议

所有设备基于 Matter 协议标准，设备状态通过 Cluster.Attribute 的形式报告。

## 家庭环境信息
家庭布局: 三室两厅 (3BR)
- 重点房间 living_room: 客厅主灯[dimmable_light], 客厅副灯[dimmable_light], 客厅氛围灯[onoff_light], 客厅空调[air_conditioner], 客厅温度传感器[temperature_sensor], 客厅运动传感器[occupancy_sensor], 客厅窗帘1[window_covering], 客厅窗户传感器1[contact_sensor], ... 共10个设备
- 房间 balcony: 阳台灯[onoff_light], 阳台门传感器[contact_sensor], 洗衣机[laundry_washer]
- 房间 dining_room: 餐厅灯[dimmable_light], 餐厅运动传感器[occupancy_sensor]
- 房间 entrance: 入户门锁[door_lock], 入户门传感器[contact_sensor], 玄关灯[onoff_light], 玄关运动传感器[occupancy_sensor]
- 房间 kids_room: 儿童房灯[dimmable_light], 儿童房运动传感器[occupancy_sensor], 儿童房窗帘[window_covering], 儿童房窗户传感器[contact_sensor], 儿童房温度传感器[temperature_sensor]
- 房间 kitchen: 厨房灯[onoff_light], 厨房灶具[cook_surface], 厨房烟雾报警器[smoke_co_alarm], 厨房温度传感器[temperature_sensor], 厨房窗户传感器[contact_sensor], 洗碗机[dishwasher], 厨房漏水传感器[water_leak_detector]
- 房间 master_bathroom: 主卫灯[onoff_light], 主卫运动传感器[occupancy_sensor], 主卫漏水传感器[water_leak_detector]
- 房间 master_bedroom: 主卧灯[dimmable_light], 主卧床头灯[onoff_light], 主卧空调[air_conditioner], 主卧运动传感器[occupancy_sensor], 主卧窗帘[window_covering], 主卧窗户传感器[contact_sensor], 主卧温度传感器[temperature_sensor]
- 房间 second_bathroom: 次卫灯[onoff_light], 次卫漏水传感器[water_leak_detector]
- 房间 second_bedroom: 次卧灯[dimmable_light], 次卧空调[air_conditioner], 次卧运动传感器[occupancy_sensor], 次卧窗帘[window_covering], 次卧窗户传感器[contact_sensor]

## 已选日志说明
以下日志不是整天原始全量心跳，而是围绕关键设备、关键时间窗和跨天模式筛出的训练片段。
- 任务类型: SQ1
- 重点房间: living_room
- 重点设备: living_room_light_1
- 已选事件数: 116

## 设备事件日志
[2026-07-31T14:10:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2462
[2026-07-31T14:30:00] living_room_occupancy | OccupancySensing.Occupancy = 0
[2026-07-31T14:55:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2451
[2026-07-31T15:15:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2434
[2026-07-31T15:35:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2407
[2026-07-31T16:00:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2399
[2026-07-31T16:20:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2390
[2026-07-31T16:40:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2383
[2026-07-31T17:00:00] living_room_occupancy | OccupancySensing.Occupancy = 0
[2026-07-31T17:10:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2361
[2026-07-31T17:14:47] master_bathroom_occupancy | OccupancySensing.Occupancy = 0
[2026-07-31T17:16:00] master_bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-07-31T17:20:00] master_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2345
[2026-07-31T17:24:02] kids_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-31T17:25:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2349
[2026-07-31T17:30:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2335
[2026-07-31T17:30:00] second_bedroom_occupancy | OccupancySensing.Occupancy = 0
[2026-07-31T17:36:03] dining_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-31T17:40:00] kids_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2332
[2026-07-31T17:44:03] entrance_occupancy | OccupancySensing.Occupancy = 1
[2026-07-31T17:45:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2334
[2026-07-31T17:50:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2330
[2026-07-31T17:55:00] kids_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2322
[2026-07-31T18:00:00] living_room_occupancy | OccupancySensing.Occupancy = 0
[2026-07-31T18:04:03] entrance_occupancy | OccupancySensing.Occupancy = 1
[2026-07-31T18:06:00] master_bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-07-31T18:10:00] master_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2323
[2026-07-31T18:14:02] kids_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-31T18:15:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2324
[2026-07-31T18:15:02] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-31T18:20:00] kids_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2324
[2026-07-31T18:21:03] dining_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-31T18:25:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2309
[2026-07-31T18:25:03] entrance_occupancy | OccupancySensing.Occupancy = 1
[2026-07-31T18:30:00] master_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2301
[2026-07-31T18:35:00] master_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2309
[2026-07-31T18:36:00] master_bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-07-31T18:40:00] kids_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2305
[2026-07-31T18:41:03] dining_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-31T18:45:00] kids_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2301
[2026-07-31T18:50:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2296
[2026-07-31T18:54:02] kids_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-31T18:55:02] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-31T19:00:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2291
[2026-07-31T19:05:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2296
[2026-07-31T19:05:03] entrance_occupancy | OccupancySensing.Occupancy = 1
[2026-07-31T19:10:00] master_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2294
[2026-07-31T19:11:00] master_bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-07-31T19:15:00] master_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2289
[2026-07-31T19:20:00] kids_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2285
[2026-07-31T19:22:05] dining_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-31T19:25:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2283
[2026-07-31T19:29:02] kids_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-31T19:30:00] second_bedroom_occupancy | OccupancySensing.Occupancy = 0
[2026-07-31T19:35:02] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-31T19:38:05] kitchen_dishwasher | OperationalState.OperationalState = 1
[2026-07-31T19:40:00] kids_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2287
[2026-07-31T19:42:05] dining_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-31T19:45:00] kids_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2279
[2026-07-31T19:50:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2265
[2026-07-31T19:54:02] kids_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-31T19:55:02] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-31T20:00:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2264
[2026-07-31T20:05:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2271
[2026-07-31T20:05:03] entrance_occupancy | OccupancySensing.Occupancy = 1
[2026-07-31T20:10:00] master_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2263
[2026-07-31T20:10:00] living_room_light_1 | OnOff.OnOff = False
[2026-07-31T20:10:00] living_room_light_1 | LevelControl.CurrentLevel = 180
[2026-07-31T20:11:00] master_bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-07-31T20:12:00] living_room_light_1 | OnOff.OnOff = False
[2026-07-31T20:15:00] master_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2276
[2026-07-31T20:20:00] kids_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2268
[2026-07-31T20:22:05] dining_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-31T20:25:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2255
[2026-07-31T20:29:02] kids_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-31T20:30:00] second_bedroom_occupancy | OccupancySensing.Occupancy = 0
[2026-07-31T20:35:02] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-31T20:40:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2255
[2026-07-31T20:40:03] entrance_occupancy | OccupancySensing.Occupancy = 1
[2026-07-31T20:45:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2260
[2026-07-31T20:50:00] master_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2252
[2026-07-31T20:51:00] master_bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-07-31T20:55:00] kids_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2262
[2026-07-31T20:57:05] dining_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-31T21:00:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2246
[2026-07-31T21:05:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2254
[2026-07-31T21:09:02] kids_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-31T21:10:02] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-31T21:14:47] master_bathroom_occupancy | OccupancySensing.Occupancy = 0
[2026-07-31T21:17:10] kids_room_window | WindowCovering.CurrentPositionLiftPercent100ths = 10000
[2026-07-31T21:20:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2248
[2026-07-31T21:30:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2251
[2026-07-31T21:30:02] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-31T21:35:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2256
[2026-07-31T21:35:03] entrance_occupancy | OccupancySensing.Occupancy = 1
[2026-07-31T21:40:00] master_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2261
[2026-07-31T21:41:00] master_bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-07-31T21:45:00] master_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2247
[2026-07-31T21:50:00] kids_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2258
[2026-07-31T21:52:05] dining_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-31T21:55:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2249
[2026-07-31T21:59:02] kids_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-31T22:00:00] second_bedroom_occupancy | OccupancySensing.Occupancy = 0
[2026-07-31T22:05:02] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-31T22:10:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2242
[2026-07-31T22:10:03] entrance_occupancy | OccupancySensing.Occupancy = 1
[2026-07-31T22:15:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2256
[2026-07-31T22:20:00] master_bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2247
[2026-07-31T22:21:00] master_bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-07-31T22:25:00] kids_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2242
[2026-07-31T22:27:05] dining_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-31T22:30:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2261
[2026-07-31T22:35:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2242
[2026-07-31T22:39:02] kids_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-31T22:40:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2258
[2026-07-31T22:40:24] master_bedroom_window | WindowCovering.CurrentPositionLiftPercent100ths = 10000

## 任务
根据以下传感器与设备记录，评估目标设备当前工作状态是否正常。如异常，请给出故障判断依据。

请按以下 JSON 格式回答：

```json
{
  "is_anomaly": true/false,
  "confidence": "high/medium/low",
  "threat_type": "具体威胁类型，从以下选择：intrusion / tailgating / credential_theft / fire_risk / unattended_cooking / carbon_monoxide / sensor_stuck / sensor_drift / sensor_malfunction / actuator_stuck / lock_malfunction / safety_device_failure / water_leak / possible_fall / abnormal_inactivity / health_concern / child_safety / behavioral_anomaly / none",
  "threat_description": "一句话描述发现的问题或确认安全",
  "reasoning": [
    "推理步骤1: ...",
    "推理步骤2: ...",
    "推理步骤3: ..."
  ],
  "key_evidence": [
    "关键证据1",
    "关键证据2"
  ],
  "recommended_actions": [
    "建议措施1",
    "建议措施2"
  ]
}
```

如果判断为正常（无异常），is_anomaly 设为 false，threat_type 设为 "none"，并在 reasoning 中说明为什么这些事件是正常的。

{
  "is_anomaly": true,
  "confidence": "medium",
  "threat_type": "actuator_stuck",
  "threat_description": "灯的 OnOff 与 Level 矛盾",
  "reasoning": [
    "推理步骤1: 同一时刻 OnOff=False 但亮度非零",
    "推理步骤2: 矛盾状态持续而非瞬时",
    "推理步骤3: 更像执行/上报故障"
  ],
  "key_evidence": [
    "同一时刻 OnOff=False 但亮度非零",
    "矛盾状态持续而非瞬时",
    "更像执行/上报故障"
  ],
  "recommended_actions": [
    "判断为灯具状态机异常，建议检查执行器或状态同步。"
  ]
}

```json
{
  "is_anomaly": false,
  "confidence": "high",
  "threat_type": "none",
  "threat_description": "目标设备 living_room_light_1 状态正常，无异常行为或安全威胁。",
  "reasoning": [
    "推理步骤 1: 检查目标设备日志，发现 living_room_light_1 在 20:10:00 和 20:12:00 两次执行了关闭操作 (OnOff.OnOff = False)，且亮度设置为 180 (约 60%)，这是典型的用户手动调节或自动化场景（如观影模式）下的正常行为，非故障表现。",
    "推理步骤 2: 分析上下文环境，日志显示该时间段内 (17:44 - 22:40) 入户门、玄关及客厅多次检测到人员活动 (Occupancy = 1)，表明家庭处于活跃居住状态，设备响应符合住户习惯。",
    "推理步骤 3: 排查关联风险，虽然厨房温度传感器读数较低（约 22-23°C），但结合洗碗机启动记录及整体环境温度趋势，属于夏季晚间正常室温范围；未发现烟雾报警、漏水或门窗非法开启等异常事件。"
  ],
  "key_evidence": [
    "living_room_light_1 在有人活动的背景下进行了正常的开关/调光操作。",
    "全屋多房间 occupancy_sensor 持续报告有人存在，排除了无人看管导致的误报可能。",
    "未检测到任何与安全相关的 Cluster.Attribute 异常变化（如门锁状态异常、烟雾浓度超标等）。"
  ],
  "recommended_actions": [
    "无需采取紧急措施，系统运行正常。",
    "建议继续保持对关键区域（如厨房、入户门）的实时监控。"
  ]
}
```


你是一个智能家居安全分析 AI 助手。你的职责是分析智能家居设备的状态日志，判断是否存在安全威胁或异常情况。

你需要基于以下能力进行分析：
1. 从设备状态变化中识别异常模式
2. 结合时间、住户习惯、设备类型进行推理
3. 区分真实威胁和正常行为（减少误报）
4. 对发现的问题给出具体的风险评估和建议

所有设备基于 Matter 协议标准，设备状态通过 Cluster.Attribute 的形式报告。

## 家庭环境信息
家庭布局: 一室一厅 (Studio/1BR)
- 重点房间 living_room: 客厅主灯[dimmable_light], 客厅台灯[onoff_light], 客厅空调[air_conditioner], 客厅温度传感器[temperature_sensor], 客厅运动传感器[occupancy_sensor], 客厅窗帘[window_covering], 客厅窗户传感器[contact_sensor]
- 房间 bathroom: 卫生间灯[onoff_light], 卫生间运动传感器[occupancy_sensor], 卫生间漏水传感器[water_leak_detector]
- 房间 bedroom: 卧室灯[dimmable_light], 卧室运动传感器[occupancy_sensor], 卧室窗帘[window_covering], 卧室窗户传感器[contact_sensor], 卧室温度传感器[temperature_sensor]
- 房间 entrance: 入户门锁[door_lock], 入户门传感器[contact_sensor], 玄关灯[onoff_light]
- 房间 kitchen: 厨房灯[onoff_light], 厨房灶具[cook_surface], 厨房烟雾报警器[smoke_co_alarm], 厨房温度传感器[temperature_sensor], 厨房窗户传感器[contact_sensor], 洗碗机[dishwasher]

## 已选日志说明
以下日志不是整天原始全量心跳，而是围绕关键设备、关键时间窗和跨天模式筛出的训练片段。
- 任务类型: SQ1
- 重点房间: living_room
- 重点设备: bedroom_temp_sensor, living_room_temp_sensor
- 已选事件数: 110

## 设备事件日志
[2026-08-22T00:00:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2263
[2026-08-22T08:00:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2433
[2026-08-22T09:05:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2446
[2026-08-22T09:20:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2540
[2026-08-22T09:40:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2454
[2026-08-22T09:49:16] living_room_ac | OnOff.OnOff = True
[2026-08-22T09:54:00] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-08-22T10:00:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2456
[2026-08-22T10:10:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2543
[2026-08-22T10:19:00] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-08-22T10:25:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2443
[2026-08-22T10:35:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2555
[2026-08-22T10:44:00] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-08-22T10:50:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2450
[2026-08-22T11:00:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2544
[2026-08-22T11:09:00] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-08-22T11:15:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2444
[2026-08-22T11:25:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2543
[2026-08-22T11:34:00] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-08-22T11:40:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2437
[2026-08-22T11:50:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2528
[2026-08-22T11:59:00] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-08-22T12:02:30] kitchen_cook_surface | OnOff.OnOff = True
[2026-08-22T12:05:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2521
[2026-08-22T12:10:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2517
[2026-08-22T12:15:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2519
[2026-08-22T12:20:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2516
[2026-08-22T12:25:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2522
[2026-08-22T12:34:00] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-08-22T12:40:30] kitchen_window_contact | BooleanState.StateValue = False
[2026-08-22T12:45:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2420
[2026-08-22T12:50:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2417
[2026-08-22T12:55:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2405
[2026-08-22T13:00:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2412
[2026-08-22T13:05:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2507
[2026-08-22T13:10:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2500
[2026-08-22T13:15:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2498
[2026-08-22T13:20:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2488
[2026-08-22T13:25:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2496
[2026-08-22T13:30:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2482
[2026-08-22T13:34:00] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-08-22T13:54:00] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-08-22T14:03:11] bathroom_occupancy | OccupancySensing.Occupancy = 0
[2026-08-22T14:08:00] bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-08-22T14:28:00] bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-08-22T14:35:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2464
[2026-08-22T14:40:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2452
[2026-08-22T14:45:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2446
[2026-08-22T14:55:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2451
[2026-08-22T15:00:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2432
[2026-08-22T15:00:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2410
[2026-08-22T15:00:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2420
[2026-08-22T15:05:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2330
[2026-08-22T15:10:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2340
[2026-08-22T15:15:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2328
[2026-08-22T15:20:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2325
[2026-08-22T15:25:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2329
[2026-08-22T15:30:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2310
[2026-08-22T15:35:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2413
[2026-08-22T15:40:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2415
[2026-08-22T15:45:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2409
[2026-08-22T15:55:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2401
[2026-08-22T16:00:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2410
[2026-08-22T16:04:00] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-08-22T16:24:00] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-08-22T16:33:11] bathroom_occupancy | OccupancySensing.Occupancy = 0
[2026-08-22T16:38:00] bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-08-22T16:58:00] bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-08-22T17:00:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2440
[2026-08-22T17:00:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2920
[2026-08-22T17:05:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2360
[2026-08-22T17:10:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2362
[2026-08-22T17:15:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2359
[2026-08-22T17:20:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2339
[2026-08-22T17:25:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2354
[2026-08-22T17:30:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2344
[2026-08-22T17:35:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2240
[2026-08-22T17:40:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2236
[2026-08-22T17:45:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2241
[2026-08-22T17:48:00] bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-08-22T18:05:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2326
[2026-08-22T18:10:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2321
[2026-08-22T18:15:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2309
[2026-08-22T18:20:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2304
[2026-08-22T18:30:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2308
[2026-08-22T18:33:11] bathroom_occupancy | OccupancySensing.Occupancy = 0
[2026-08-22T18:35:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2215
[2026-08-22T18:40:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2210
[2026-08-22T18:45:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2193
[2026-08-22T18:50:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2202
[2026-08-22T18:55:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2192
[2026-08-22T19:05:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2299
[2026-08-22T19:10:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2292
[2026-08-22T19:15:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2297
[2026-08-22T19:20:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2289
[2026-08-22T19:25:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2283
[2026-08-22T19:30:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2280
[2026-08-22T19:34:00] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-08-22T19:54:00] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-08-22T20:05:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2275
[2026-08-22T20:14:00] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-08-22T20:20:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2168
[2026-08-22T20:30:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2254
[2026-08-22T20:39:00] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-08-22T20:45:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2166
[2026-08-22T20:55:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2266
[2026-08-22T21:04:00] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-08-22T21:10:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2163
[2026-08-22T21:20:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2248
[2026-08-22T21:29:00] living_room_occupancy | OccupancySensing.Occupancy = 1

## 任务
请结合下面的 Matter 设备日志，判断是否存在设备健康问题，并说明可能的故障类型。

请按以下 JSON 格式回答：

```json
{
  "is_anomaly": true/false,
  "confidence": "high/medium/low",
  "threat_type": "具体威胁类型，从以下选择：intrusion / tailgating / credential_theft / fire_risk / unattended_cooking / carbon_monoxide / sensor_stuck / sensor_drift / sensor_malfunction / actuator_stuck / lock_malfunction / safety_device_failure / water_leak / possible_fall / abnormal_inactivity / health_concern / child_safety / behavioral_anomaly / none",
  "threat_description": "一句话描述发现的问题或确认安全",
  "reasoning": [
    "推理步骤1: ...",
    "推理步骤2: ...",
    "推理步骤3: ..."
  ],
  "key_evidence": [
    "关键证据1",
    "关键证据2"
  ],
  "recommended_actions": [
    "建议措施1",
    "建议措施2"
  ]
}
```

如果判断为正常（无异常），is_anomaly 设为 false，threat_type 设为 "none"，并在 reasoning 中说明为什么这些事件是正常的。

```json
{
  "is_anomaly": true,
  "confidence": "high",
  "threat_type": "sensor_malfunction",
  "threat_description": "卧室温度传感器在17:00出现异常高温跳变（29.2°C），随后迅速恢复正常，疑似传感器故障或数据上报错误。",
  "reasoning": [
    "分析卧室温度传感器（bedroom_temp_sensor）的数据序列：从上午到下午15:30，温度在23.1°C - 24.5°C之间缓慢波动，符合正常室内环境变化规律。",
    "在17:00时，卧室温度读数突然飙升至2920（即29.2°C），而同一时间客厅温度为24.4°C，厨房为23.6°C左右。考虑到房屋布局为一室一厅，卧室与客厅/厨房相邻，且无空调开启记录（AC仅在上午短暂开启），短时间内卧室温度比其它房间高出近5-6度是不合常理的。",
    "紧接着在17:35，卧室温度读数又骤降至22.4°C，并在此后维持在21.6°C - 22.4°C的正常范围内。这种‘尖峰’式的突变（Spike）而非渐变，排除了真实环境温度剧烈变化的可能性（如阳光直射通常会导致缓慢升温）。",
    "结合Matter协议标准，TemperatureMeasurement.MeasuredValue单位为厘氏度（celsius * 100）。该异常表现为典型的传感器硬件故障、校准漂移或通信数据包错误，属于设备健康问题。"
  ],
  "key_evidence": [
    "[2026-08-22T17:00:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2920 (异常高值)",
    "[2026-08-22T17:35:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2240 (迅速恢复至正常范围)",
    "对比同期其他房间温度：living_room ~24.4°C, kitchen ~23.6°C，卧室不可能在短时间内显著高于其他房间。"
  ],
  "recommended_actions": [
    "检查卧室温度传感器的电池电量，低电量可能导致读数不稳定。",
    "尝试重启或重新配对该温度传感器，以排除临时性固件或连接错误。",
    "如果问题持续出现，建议更换该温度传感器硬件。"
  ]
}
```

{
  "is_anomaly": false,
  "confidence": "medium",
  "threat_type": "none",
  "threat_description": "这些变化仍可视为正常波动。",
  "reasoning": [
    "推理步骤1: 没有看到必须报警的直接证据。"
  ],
  "key_evidence": [
    "设备状态变化幅度看起来仍在可接受范围内。"
  ],
  "recommended_actions": [
    "保持观察即可。"
  ]
}


你是一个智能家居安全分析 AI 助手。你的职责是分析智能家居设备的状态日志，判断是否存在安全威胁或异常情况。

你需要基于以下能力进行分析：
1. 从设备状态变化中识别异常模式
2. 结合时间、住户习惯、设备类型进行推理
3. 区分真实威胁和正常行为（减少误报）
4. 对发现的问题给出具体的风险评估和建议

所有设备基于 Matter 协议标准，设备状态通过 Cluster.Attribute 的形式报告。

## 家庭环境信息
家庭布局: 独居老人 (Elderly Living Alone)
- 重点房间 living_room: 客厅灯[dimmable_light], 客厅空调[air_conditioner], 客厅温度传感器[temperature_sensor], 客厅运动传感器[occupancy_sensor], 客厅窗帘[window_covering], 客厅窗户传感器[contact_sensor], 客厅烟雾报警器[smoke_co_alarm]
- 房间 bathroom: 卫生间灯[onoff_light], 卫生间运动传感器[occupancy_sensor], 卫生间漏水传感器[water_leak_detector]
- 房间 bedroom: 卧室灯[dimmable_light], 床头灯[onoff_light], 卧室运动传感器[occupancy_sensor], 卧室窗帘[window_covering], 卧室窗户传感器[contact_sensor], 卧室温度传感器[temperature_sensor]
- 房间 entrance: 入户门锁[door_lock], 入户门传感器[contact_sensor], 玄关灯[onoff_light], 玄关运动传感器[occupancy_sensor]
- 房间 kitchen: 厨房灯[onoff_light], 厨房灶具[cook_surface], 厨房烟雾报警器[smoke_co_alarm], 厨房温度传感器[temperature_sensor], 厨房运动传感器[occupancy_sensor], 厨房漏水传感器[water_leak_detector]

## 已选日志说明
以下日志不是整天原始全量心跳，而是围绕关键设备、关键时间窗和跨天模式筛出的训练片段。
- 任务类型: SQ1
- 重点房间: living_room
- 重点设备: bedroom_light
- 已选事件数: 115

## 设备事件日志
[2026-07-01T05:22:10] bedroom_light | OnOff.OnOff = True
[2026-07-01T14:18:11] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T14:38:11] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T14:58:11] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T15:18:11] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T15:38:11] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T15:58:11] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T16:18:11] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T16:38:11] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T16:58:11] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T17:11:03] entrance_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T17:15:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2362
[2026-07-01T17:18:00] bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T17:20:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2242
[2026-07-01T17:23:00] kitchen_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T17:25:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2341
[2026-07-01T17:28:11] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T17:31:03] entrance_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T17:35:00] kitchen_cook_surface | OnOff.OnOff = False
[2026-07-01T17:36:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = None
[2026-07-01T17:50:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2334
[2026-07-01T17:53:00] bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T17:55:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2218
[2026-07-01T17:58:00] kitchen_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T18:00:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2335
[2026-07-01T18:03:11] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T18:06:03] entrance_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T18:09:40] bathroom_occupancy | OccupancySensing.Occupancy = 0
[2026-07-01T18:15:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2320
[2026-07-01T18:18:00] bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T18:20:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2212
[2026-07-01T18:23:00] kitchen_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T18:25:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2313
[2026-07-01T18:28:11] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T18:31:03] entrance_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T18:35:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2309
[2026-07-01T18:38:00] bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T18:40:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2302
[2026-07-01T18:45:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2192
[2026-07-01T18:48:00] kitchen_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T18:50:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2308
[2026-07-01T18:53:11] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T18:56:03] entrance_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T19:00:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2299
[2026-07-01T19:03:00] bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T19:05:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2200
[2026-07-01T19:08:00] kitchen_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T19:10:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2181
[2026-07-01T19:15:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2294
[2026-07-01T19:18:11] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T19:21:03] entrance_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T19:25:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2290
[2026-07-01T19:28:00] bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T19:30:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2172
[2026-07-01T19:33:00] kitchen_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T19:35:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2289
[2026-07-01T19:38:11] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T19:40:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2176
[2026-07-01T19:45:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2274
[2026-07-01T19:55:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2274
[2026-07-01T19:56:03] entrance_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T20:00:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2181
[2026-07-01T20:03:00] bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T20:05:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2268
[2026-07-01T20:08:00] kitchen_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T20:10:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2272
[2026-07-01T20:10:00] bedroom_light | OnOff.OnOff = False
[2026-07-01T20:10:00] bedroom_light | LevelControl.CurrentLevel = 180
[2026-07-01T20:12:00] bedroom_light | OnOff.OnOff = False
[2026-07-01T20:15:00] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T20:20:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2256
[2026-07-01T20:21:03] entrance_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T20:23:04] bathroom_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T20:25:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2271
[2026-07-01T20:28:00] kitchen_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T20:30:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2260
[2026-07-01T20:35:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2251
[2026-07-01T20:40:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2160
[2026-07-01T20:40:10] front_door_contact | BooleanState.StateValue = True
[2026-07-01T20:40:17] bedroom_window | WindowCovering.CurrentPositionLiftPercent100ths = 10000
[2026-07-01T20:45:00] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T20:50:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2249
[2026-07-01T20:50:07] bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T20:55:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2157
[2026-07-01T20:56:03] entrance_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T21:00:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2260
[2026-07-01T21:03:00] kitchen_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T21:05:00] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T21:10:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2261
[2026-07-01T21:10:07] bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T21:15:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2243
[2026-07-01T21:20:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2151
[2026-07-01T21:21:03] entrance_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T21:25:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2252
[2026-07-01T21:28:00] kitchen_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T21:30:00] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T21:35:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2245
[2026-07-01T21:35:07] bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T21:40:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2154
[2026-07-01T21:41:03] entrance_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T21:45:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2150
[2026-07-01T21:50:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2243
[2026-07-01T21:53:00] kitchen_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T21:55:00] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T22:00:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2244
[2026-07-01T22:00:07] bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T22:05:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2147
[2026-07-01T22:06:03] entrance_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T22:10:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2247
[2026-07-01T22:11:16] bathroom_occupancy | OccupancySensing.Occupancy = 0
[2026-07-01T22:15:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2254
[2026-07-01T22:18:00] kitchen_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T22:20:00] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-01T22:25:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2252
[2026-07-01T22:25:07] bedroom_occupancy | OccupancySensing.Occupancy = 1

## 任务
请结合下面的 Matter 设备日志，判断是否存在设备健康问题，并说明可能的故障类型。

请按以下 JSON 格式回答：

```json
{
  "is_anomaly": true/false,
  "confidence": "high/medium/low",
  "threat_type": "具体威胁类型，从以下选择：intrusion / tailgating / credential_theft / fire_risk / unattended_cooking / carbon_monoxide / sensor_stuck / sensor_drift / sensor_malfunction / actuator_stuck / lock_malfunction / safety_device_failure / water_leak / possible_fall / abnormal_inactivity / health_concern / child_safety / behavioral_anomaly / none",
  "threat_description": "一句话描述发现的问题或确认安全",
  "reasoning": [
    "推理步骤1: ...",
    "推理步骤2: ...",
    "推理步骤3: ..."
  ],
  "key_evidence": [
    "关键证据1",
    "关键证据2"
  ],
  "recommended_actions": [
    "建议措施1",
    "建议措施2"
  ]
}
```

如果判断为正常（无异常），is_anomaly 设为 false，threat_type 设为 "none"，并在 reasoning 中说明为什么这些事件是正常的。

```json
{
  "is_anomaly": true,
  "confidence": "high",
  "threat_type": "sensor_malfunction",
  "threat_description": "卧室温度传感器读数出现异常跳变（从21.8°C骤降至21.5°C以下并持续下降），且与客厅、厨房等其他区域温度变化趋势不一致，疑似传感器故障或电池电量不足导致的数据漂移。",
  "reasoning": [
    "1. 分析温度数据趋势：在19:00至20:40期间，卧室温度传感器读数从21.81°C缓慢下降至21.60°C，这符合夜间环境温度自然降低的规律。然而，在20:40之后，读数变为21.57°C，随后在21:20降至21.51°C，21:45降至21.50°C，22:05降至21.47°C。虽然数值仍在合理范围内，但结合其他房间来看存在异常。",
    "2. 对比跨房间数据一致性：在同一时间段内，客厅温度从22.99°C降至22.44°C，厨房温度从22.94°C降至22.47°C。通常卧室与客厅/厨房的温度差异不会如此显著地反向或独立波动，除非有独立的空调控制。日志中未显示卧室空调开启，且卧室窗帘在20:40被打开（CurrentPositionLiftPercent100ths = 10000，即100%打开），理论上应引入室外热量或保持室内平衡，但卧室温度却呈现持续微弱下降趋势，与其他房间趋于一致或略高的环境不符。",
    "3. 识别设备行为模式：Matter协议中的TemperatureMeasurement.MeasuredValue通常以厘度（centi-degrees）为单位。观察卧室传感器数据，其变化幅度极小且在某些时间点（如21:45到22:05）几乎停滞或微降，而同一时刻其他房间传感器数据正常更新。这种‘孤立’的微小漂移且缺乏物理原因（如开窗后无升温反而降温）支持，高度指向传感器硬件故障、校准失效或电池电压不稳导致的读数错误。对于独居老人，错误的温度读数可能导致空调误判，引发健康风险。"
  ],
  "key_evidence": [
    "[2026-07-01T20:40:10] front_door_contact | BooleanState.StateValue = True (入户门关闭)",
    "[2026-07-01T20:40:17] bedroom_window | WindowCovering.CurrentPositionLiftPercent100ths = 10000 (卧室窗帘完全打开)",
    "[2026-07-01T20:40:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2160",
    "[2026-07-01T22:05:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2147",
    "[2026-07-01T22:00:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2244 (客厅温度稳定在22.4°C左右)"
  ],
  "recommended_actions": [
    "检查卧室温度传感器的电池电量，低电量常导致读数漂移或不稳定。",
    "尝试重置或重新配对该卧室温度传感器，若问题依旧则更换设备。",
    "建议用户手动测量卧室实际温度，以确认是否为传感器故障，避免空调系统因错误低温信号而过度制冷。"
  ]
}
```

{
  "is_anomaly": true,
  "confidence": "high",
  "threat_type": "actuator_stuck",
  "threat_description": "灯的 OnOff 与 Level 矛盾",
  "reasoning": [
    "推理步骤1: 日志中出现了不存在的额外报警事件。"
  ],
  "key_evidence": [
    "我假设看到了一个未在日志中出现的 critical 告警。"
  ],
  "recommended_actions": [
    "判断为灯具状态机异常，建议检查执行器或状态同步。"
  ]
}


你是一个智能家居安全分析 AI 助手。你的职责是分析智能家居设备的状态日志，判断是否存在安全威胁或异常情况。

你需要基于以下能力进行分析：
1. 从设备状态变化中识别异常模式
2. 结合时间、住户习惯、设备类型进行推理
3. 区分真实威胁和正常行为（减少误报）
4. 对发现的问题给出具体的风险评估和建议

所有设备基于 Matter 协议标准，设备状态通过 Cluster.Attribute 的形式报告。

## 家庭环境信息
家庭布局: 一室一厅 (Studio/1BR)
- 重点房间 living_room: 客厅主灯[dimmable_light], 客厅台灯[onoff_light], 客厅空调[air_conditioner], 客厅温度传感器[temperature_sensor], 客厅运动传感器[occupancy_sensor], 客厅窗帘[window_covering], 客厅窗户传感器[contact_sensor]
- 房间 bathroom: 卫生间灯[onoff_light], 卫生间运动传感器[occupancy_sensor], 卫生间漏水传感器[water_leak_detector]
- 房间 bedroom: 卧室灯[dimmable_light], 卧室运动传感器[occupancy_sensor], 卧室窗帘[window_covering], 卧室窗户传感器[contact_sensor], 卧室温度传感器[temperature_sensor]
- 房间 entrance: 入户门锁[door_lock], 入户门传感器[contact_sensor], 玄关灯[onoff_light]
- 房间 kitchen: 厨房灯[onoff_light], 厨房灶具[cook_surface], 厨房烟雾报警器[smoke_co_alarm], 厨房温度传感器[temperature_sensor], 厨房窗户传感器[contact_sensor], 洗碗机[dishwasher]

## 已选日志说明
以下日志不是整天原始全量心跳，而是围绕关键设备、关键时间窗和跨天模式筛出的训练片段。
- 任务类型: SQ1
- 重点房间: living_room
- 重点设备: living_room_ac, living_room_temp_sensor
- 已选事件数: 117

## 设备事件日志
[2026-07-11T00:00:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2267
[2026-07-11T07:05:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2510
[2026-07-11T07:25:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2523
[2026-07-11T07:40:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2527
[2026-07-11T08:00:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2528
[2026-07-11T08:15:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2542
[2026-07-11T08:30:00] living_room_occupancy | OccupancySensing.Occupancy = 0
[2026-07-11T08:50:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2552
[2026-07-11T09:05:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2554
[2026-07-11T09:25:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2550
[2026-07-11T09:40:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2545
[2026-07-11T09:57:00] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-11T09:57:23] living_room_window | WindowCovering.CurrentPositionLiftPercent100ths = 0
[2026-07-11T10:05:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2541
[2026-07-11T10:10:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2454
[2026-07-11T10:13:00] bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-07-11T10:17:00] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-11T10:20:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2554
[2026-07-11T10:25:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2450
[2026-07-11T10:30:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2538
[2026-07-11T10:33:00] bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-07-11T10:37:00] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-11T10:40:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2549
[2026-07-11T10:45:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2548
[2026-07-11T10:55:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2545
[2026-07-11T11:00:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2439
[2026-07-11T11:05:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2546
[2026-07-11T11:08:00] bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-07-11T11:11:45] bathroom_occupancy | OccupancySensing.Occupancy = 0
[2026-07-11T11:15:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2440
[2026-07-11T11:20:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2544
[2026-07-11T11:27:00] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-11T11:30:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2943
[2026-07-11T11:35:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2432
[2026-07-11T11:40:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2530
[2026-07-11T11:45:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2888
[2026-07-11T11:50:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2437
[2026-07-11T11:54:00] kitchen_light | OnOff.OnOff = True
[2026-07-11T11:55:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2434
[2026-07-11T12:00:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2523
[2026-07-11T12:03:00] bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-07-11T12:07:00] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-11T12:10:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2678
[2026-07-11T12:15:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2516
[2026-07-11T12:25:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2568
[2026-07-11T12:30:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2418
[2026-07-11T12:35:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2506
[2026-07-11T12:38:00] bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-07-11T12:41:45] bathroom_occupancy | OccupancySensing.Occupancy = 0
[2026-07-11T12:45:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2412
[2026-07-11T12:55:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2503
[2026-07-11T12:58:00] bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-07-11T13:00:00] living_room_ac | OnOff.OnOff = True
[2026-07-11T13:02:00] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-11T13:10:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2393
[2026-07-11T13:15:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2920
[2026-07-11T13:20:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2493
[2026-07-11T13:25:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2398
[2026-07-11T13:30:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2482
[2026-07-11T13:33:00] bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-07-11T13:35:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2940
[2026-07-11T13:37:00] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-11T13:40:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2495
[2026-07-11T13:45:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2487
[2026-07-11T13:55:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2486
[2026-07-11T13:55:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2960
[2026-07-11T14:00:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2381
[2026-07-11T14:05:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2482
[2026-07-11T14:08:00] bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-07-11T14:11:45] bathroom_occupancy | OccupancySensing.Occupancy = 0
[2026-07-11T14:15:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2359
[2026-07-11T14:20:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2468
[2026-07-11T14:27:00] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-11T14:30:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2457
[2026-07-11T14:35:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2354
[2026-07-11T14:40:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2449
[2026-07-11T14:45:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2438
[2026-07-11T14:50:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2355
[2026-07-11T14:55:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2443
[2026-07-11T14:58:00] bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-07-11T15:02:00] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-11T15:05:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2425
[2026-07-11T15:10:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2332
[2026-07-11T15:20:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2419
[2026-07-11T15:25:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2314
[2026-07-11T15:30:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2409
[2026-07-11T15:33:00] bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-07-11T15:37:00] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-11T15:40:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2407
[2026-07-11T15:45:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2419
[2026-07-11T15:55:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2398
[2026-07-11T16:00:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2303
[2026-07-11T16:05:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2397
[2026-07-11T16:08:00] bedroom_occupancy | OccupancySensing.Occupancy = 1
[2026-07-11T16:11:45] bathroom_occupancy | OccupancySensing.Occupancy = 0
[2026-07-11T16:15:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2288
[2026-07-11T16:20:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2377
[2026-07-11T16:27:00] living_room_occupancy | OccupancySensing.Occupancy = 1
[2026-07-11T16:30:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2386
[2026-07-11T16:35:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2284
[2026-07-11T16:40:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2369
[2026-07-11T16:45:00] kitchen_temp_sensor | TemperatureMeasurement.MeasuredValue = 2365
[2026-07-11T16:50:00] bedroom_temp_sensor | TemperatureMeasurement.MeasuredValue = 2270
[2026-07-11T16:55:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2366
[2026-07-11T17:00:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2362
[2026-07-11T17:10:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2363
[2026-07-11T17:20:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2340
[2026-07-11T17:30:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2342
[2026-07-11T17:40:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2334
[2026-07-11T17:50:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2340
[2026-07-11T18:00:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2315
[2026-07-11T18:10:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2327
[2026-07-11T18:20:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2317
[2026-07-11T18:30:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2314
[2026-07-11T18:40:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2306
[2026-07-11T18:50:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2291
[2026-07-11T19:00:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2288

## 任务
请结合下面的 Matter 设备日志，判断是否存在设备健康问题，并说明可能的故障类型。

请按以下 JSON 格式回答：

```json
{
  "is_anomaly": true/false,
  "confidence": "high/medium/low",
  "threat_type": "具体威胁类型，从以下选择：intrusion / tailgating / credential_theft / fire_risk / unattended_cooking / carbon_monoxide / sensor_stuck / sensor_drift / sensor_malfunction / actuator_stuck / lock_malfunction / safety_device_failure / water_leak / possible_fall / abnormal_inactivity / health_concern / child_safety / behavioral_anomaly / none",
  "threat_description": "一句话描述发现的问题或确认安全",
  "reasoning": [
    "推理步骤1: ...",
    "推理步骤2: ...",
    "推理步骤3: ..."
  ],
  "key_evidence": [
    "关键证据1",
    "关键证据2"
  ],
  "recommended_actions": [
    "建议措施1",
    "建议措施2"
  ]
}
```

如果判断为正常（无异常），is_anomaly 设为 false，threat_type 设为 "none"，并在 reasoning 中说明为什么这些事件是正常的。

```json
{
  "is_anomaly": true,
  "confidence": "high",
  "threat_type": "sensor_malfunction",
  "threat_description": "客厅温度传感器出现严重的读数跳变和异常高温峰值，疑似硬件故障或传感器损坏。",
  "reasoning": [
    "1. 分析客厅温度传感器的数据趋势：在07:05至09:40期间，温度从22.67°C缓慢上升至25.45°C，符合早晨室温自然回升的正常物理规律。",
    "2. 识别异常点：在13:15、13:35和13:55三个时间点，客厅温度传感器分别报告了29.20°C、29.40°C和29.60°C的极高值。",
    "3. 对比验证：在同一时间段（13:10-14:00），厨房温度传感器读数在24.86°C-24.95°C之间波动，卧室温度传感器读数在23.54°C-23.98°C之间下降。其他房间温度正常且呈夏季傍晚降温趋势，唯独客厅温度出现与整体环境完全不符的剧烈飙升。",
    "4. 排除外部因素：虽然13:00开启了空调，但通常空调开启会导致温度下降而非瞬间飙升至近30度；且随后的读数迅速回落至24.82°C（13:30），这种“尖峰”状的数据特征不符合热惯性原理，更符合电子元件故障或接触不良导致的错误读数。"
  ],
  "key_evidence": [
    "[2026-07-11T13:15:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2920 (29.20°C)",
    "[2026-07-11T13:35:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2940 (29.40°C)",
    "[2026-07-11T13:55:00] living_room_temp_sensor | TemperatureMeasurement.MeasuredValue = 2960 (29.60°C)",
    "同期厨房温度传感器读数稳定在 ~24.9°C，卧室温度传感器读数稳定在 ~23.8°C，证明室内实际环境温度并未升高。"
  ],
  "recommended_actions": [
    "检查客厅温度传感器的安装位置，确认是否靠近热源（如阳光直射、电器散热口）或存在遮挡。",
    "尝试重启该温度传感器或重新配网，观察异常读数是否复现。",
    "若问题持续，建议更换客厅温度传感器，因为其读数已明显偏离真实环境值，可能导致基于此数据的自动化场景（如空调控制）失效。"
  ]
}
```

{
  "is_anomaly": true,
  "confidence": "high",
  "threat_type": "sensor_malfunction",
  "threat_description": "空调运行但温度不下降",
  "reasoning": [
    "推理步骤1: 日志中出现了不存在的额外报警事件。"
  ],
  "key_evidence": [
    "我假设看到了一个未在日志中出现的 critical 告警。"
  ],
  "recommended_actions": [
    "判断为空调侧制冷失效或相关传感异常，建议检修。"
  ]
}