.ha_mcp/logs/mcp_usage.jsonl, zigbee2mqtt/state.json

This commit is contained in:
Home Assistant Version Control
2026-10-15 17:22:10 +00:00
parent 220c9b6774
commit 82a0a06cfb
2 changed files with 17 additions and 16 deletions
+1
View File
@@ -4644,3 +4644,4 @@
{"timestamp": "2026-10-15T17:11:37.587187+00:00", "tool_name": "ha_config_get_dashboard", "parameters": {"url_path": "3d-printer-cellphone", "list_only": false, "force_reload": false, "entity_id": null, "card_type": null, "heading": null, "include_config": false, "include_screenshot": false, "view_path": null, "query": null, "describe": false}, "execution_time_ms": 288.5122299194336, "success": true, "error_message": null, "response_size_bytes": 9014, "user_context": null}
{"timestamp": "2026-10-15T17:14:21.836968+00:00", "tool_name": "ha_config_get_automation", "parameters": {"identifier": "1792076023718"}, "execution_time_ms": 299.9892234802246, "success": true, "error_message": null, "response_size_bytes": 2946, "user_context": null}
{"timestamp": "2026-10-15T17:14:21.943547+00:00", "tool_name": "ha_config_get_automation", "parameters": {"identifier": "1791477238799"}, "execution_time_ms": 405.3964614868164, "success": true, "error_message": null, "response_size_bytes": 7549, "user_context": null}
{"timestamp": "2026-10-15T17:22:03.162165+00:00", "tool_name": "ha_config_set_dashboard", "parameters": {"url_path": "3d-printer-cellphone", "config": null, "python_transform": "c = config['views'][0]['sections'][0]['cards']\nlogic = '''{% set gcm = states('input_number.sparkx_i7_filament_g_cm') | float(0.0298) %}\n{% set lencm = states('sensor.sparkx_i7_expected_material_length') | float(0) %}\n{% set wgt = states('sensor.sparkx_i7_expected_material_weight') | float(0) %}\n{% set job_g = ((wgt if wgt > 0 else lencm * gcm) | round(1)) %}\n{% set used_g = ((states('sensor.sparkx_i7_used_material_length') | float(0)) * gcm) | round(1) %}\n{% set rem_g = ([job_g - used_g, 0] | max) | round(1) %}\n{% set gc = namespace(list=[]) %}\n{% for p in (state_attr('sensor.sparkx_i7_expected_material_length','color') | default('', true) | string).split(';') %}\n{% set q = p | replace('#','') | lower | trim %}\n{% if q not in ['','none','unknown','unavailable'] %}{% set gc.list = gc.list + [q] %}{% endif %}\n{% endfor %}\n{% set single = (gc.list | length) == 1 %}\n{% set aslot = (states('sensor.sparkx_i7_active_filament_slot') | default('', true) | string).split('_')[-1] %}\n{% set aslot = aslot if aslot in ['1','2','3','4'] else '' %}\n{% set s = namespace(short=false, ok=false, matched=0, active=false) %}\n{% for n in ['1','2','3','4'] %}\n{% set sp = namespace(id='', rem=-1) %}\n{% for e in integration_entities('spoolman') if e.endswith('_color_hex') %}\n{% if sp.id == '' and (state_attr(e[:-10],'location') | default('', true) | lower) == ('cfs lite ' ~ n) %}\n{% set sp.id = e[:-10] %}\n{% set sp.rem = states(e[:-10]) | float(-1) %}\n{% endif %}\n{% endfor %}\n{% if sp.id != '' and sp.rem >= 0 %}\n{% set s.matched = s.matched + 1 %}\n{% if single %}\n{% if n == aslot %}\n{% set s.active = true %}\n{% if sp.rem < job_g %}{% set s.short = true %}{% else %}{% set s.ok = true %}{% endif %}\n{% endif %}\n{% else %}\n{% if sp.rem < job_g %}{% set s.short = true %}{% else %}{% set s.ok = true %}{% endif %}\n{% endif %}\n{% endif %}\n{% endfor %}\n{% set v = namespace(state='unknown', label='check unavailable') %}\n{% if job_g <= 0 %}\n{% set v.state = 'none' %}\n{% set v.label = 'no slicer estimate yet' %}\n{% elif s.short %}\n{% set v.state = 'short' %}\n{% set v.label = 'NOT ENOUGH' %}\n{% elif s.ok %}\n{% set v.state = 'ok' %}\n{% set v.label = 'enough' %}\n{% elif single and aslot == '' %}\n{% set v.state = 'unknown' %}\n{% set v.label = 'no active CFS slot' %}\n{% elif single and not s.active %}\n{% set v.state = 'unknown' %}\n{% set v.label = 'active slot has no spool' %}\n{% elif s.matched == 0 %}\n{% set v.state = 'unknown' %}\n{% set v.label = 'no spool loaded' %}\n{% endif %}\n'''\ncard = {\n 'type': 'custom:mushroom-template-card',\n 'entity': 'sensor.sparkx_i7_expected_material_length',\n 'name': 'Filament Sufficiency',\n 'icon': 'mdi:scale-balance',\n 'icon_color': logic + '''{% if v.state == 'ok' %}green{% elif v.state == 'short' %}red{% elif v.state == 'none' %}grey{% else %}orange{% endif %}''',\n 'primary': logic + '{{ job_g }} g needed · {{ used_g }} g used',\n 'secondary': logic + '{{ rem_g }} g left to print · {{ v.label }}',\n 'multiline_secondary': True,\n 'grid_options': {'columns': 6, 'rows': 'auto'}\n}\nc.insert(9, card)", "config_hash": "74d2ffc9bdc7b809", "title": null, "icon": null, "require_admin": null, "show_in_sidebar": null, "MandatoryBPS": false, "BestPracticeKey": null, "return_screenshot": false, "view_path": null, "patch": null}, "execution_time_ms": 22836.2557888031, "success": true, "error_message": null, "response_size_bytes": 3669, "user_context": null}
+16 -16
View File
@@ -4,7 +4,7 @@
"state": "ON",
"led_brightness": 100,
"countdown_to_turn_off": 0,
"voltage": 119.9,
"voltage": 119.8,
"countdown_to_turn_on": 0,
"ac_frequency": 60,
"power_factor": 0.14,
@@ -45,10 +45,10 @@
"state": "ON",
"led_brightness": 100,
"countdown_to_turn_off": 0,
"voltage": 119.7,
"voltage": 119.3,
"countdown_to_turn_on": 0,
"energy": 109.7,
"power_factor": 0.2,
"energy": 109.71,
"power_factor": 0.94,
"ac_frequency": 60,
"update": {
"state": "idle",
@@ -58,8 +58,8 @@
"latest_release_notes": null
},
"linkquality": 145,
"power": 0.2,
"current": 0.01,
"power": 98.1,
"current": 0.89,
"power_on_behavior": "on"
},
"0xb40e060fffe031e3": {
@@ -74,11 +74,11 @@
"led_brightness": 100,
"countdown_to_turn_off": 0,
"countdown_to_turn_on": 0,
"voltage": 117.9,
"voltage": 117.8,
"state": "ON",
"ac_frequency": 60,
"energy": 222.82,
"power": 97,
"energy": 222.83,
"power": 94.7,
"current": 0.87,
"power_factor": 0.94,
"update": {
@@ -95,13 +95,13 @@
"led_brightness": 100,
"countdown_to_turn_off": 0,
"countdown_to_turn_on": 0,
"voltage": 119.7,
"voltage": 119.2,
"energy": 104.34,
"state": "ON",
"power": 44.7,
"current": 0.47,
"power": 43.6,
"current": 0.59,
"ac_frequency": 60,
"power_factor": 0.74,
"power_factor": 0.76,
"update": {
"state": "idle",
"installed_version": 268513381,
@@ -114,12 +114,12 @@
},
"0xffffb40e060895b3": {
"state": "ON",
"voltage": 119.8,
"voltage": 119.7,
"ac_frequency": 60,
"energy": 15.31,
"current": 0.01,
"power": 0.1,
"power_factor": 0.22,
"power_factor": 0.11,
"linkquality": 116,
"update": {
"state": "idle",
@@ -171,7 +171,7 @@
},
"0xa4c1380d0679ffff": {
"battery": 100,
"temperature": 11.4,
"temperature": 11.3,
"temperature_units": "celsius",
"temperature_calibration": 0,
"update": {