@camstack/addon-pipeline 1.2.629 → 1.2.630
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/audio-analyzer/index.js +3 -3
- package/dist/audio-analyzer/index.mjs +3 -3
- package/dist/{custom-model-catalog-DyFqiWQw.js → custom-model-catalog-CsHQljey.js} +2 -2
- package/dist/{custom-model-catalog--z5qDAbz.mjs → custom-model-catalog-qwNT0qE-.mjs} +2 -2
- package/dist/detection-pipeline/index.js +4 -4
- package/dist/detection-pipeline/index.mjs +4 -4
- package/dist/{dist-DkFeDO1Z.mjs → dist-C56NTN3j.mjs} +504 -40
- package/dist/{dist-vvIUo4Fg.js → dist-M09KjuSx.js} +504 -40
- package/dist/{model-catalogs-dHtp4VIV.js → model-catalogs-BmZHxpaD.js} +1 -1
- package/dist/{model-catalogs-DcAtdzQX.mjs → model-catalogs-vPj_kgtX.mjs} +1 -1
- package/dist/motion-wasm/index.js +1 -1
- package/dist/motion-wasm/index.mjs +1 -1
- package/dist/{node-j-hM0LYt.js → node-C0CzsJ0N.js} +1 -1
- package/dist/{node-CT-ETMWK.mjs → node-CdsOgsyN.mjs} +1 -1
- package/dist/pipeline-runner/index.js +3 -3
- package/dist/pipeline-runner/index.mjs +3 -3
- package/dist/{process-memory-B9lUUQZw.js → process-memory-BURe-pwd.js} +1 -1
- package/dist/{process-memory-BwZIeAKw.mjs → process-memory-DAhr_IbO.mjs} +1 -1
- package/dist/recorder/index.js +2 -2
- package/dist/recorder/index.mjs +2 -2
- package/dist/{segment-demux-js-BCBpOp5j.js → segment-demux-js-B391lmQZ.js} +1 -1
- package/dist/{segment-demux-js-CW7aiIml.mjs → segment-demux-js-CobIINvd.mjs} +1 -1
- package/dist/stream-broker/_stub.js +2 -2
- package/dist/stream-broker/{_virtual_mf-localSharedImportMap___mfe_internal__addon_stream_broker_widgets-DUUHEAPV.mjs → _virtual_mf-localSharedImportMap___mfe_internal__addon_stream_broker_widgets-Bxan5418.mjs} +2 -2
- package/dist/stream-broker/_virtual_mf___mfe_internal__addon_stream_broker_widgets__loadShare___mf_0_camstack_mf_1_types__loadShare__.js-inxALjZf.mjs +26 -0
- package/dist/stream-broker/_virtual_mf___mfe_internal__addon_stream_broker_widgets__loadShare___mf_0_camstack_mf_1_ui_mf_2_library__loadShare__.js-wSzIkKI-.mjs +26 -0
- package/dist/stream-broker/demux-worker-child.js +1 -1
- package/dist/stream-broker/demux-worker-child.mjs +1 -1
- package/dist/stream-broker/{hostInit-BiqKaq23.mjs → hostInit-CmFod5rw.mjs} +2 -2
- package/dist/stream-broker/index.js +3 -3
- package/dist/stream-broker/index.mjs +3 -3
- package/dist/stream-broker/remoteEntry.js +1 -1
- package/package.json +1 -1
- package/dist/stream-broker/_virtual_mf___mfe_internal__addon_stream_broker_widgets__loadShare___mf_0_camstack_mf_1_types__loadShare__.js-BQMKjVwR.mjs +0 -26
- package/dist/stream-broker/_virtual_mf___mfe_internal__addon_stream_broker_widgets__loadShare___mf_0_camstack_mf_1_ui_mf_2_library__loadShare__.js-Ca0Qmh7u.mjs +0 -26
|
@@ -5575,7 +5575,7 @@ var ZodIssueCode = {
|
|
|
5575
5575
|
var ZodFirstPartyTypeKind;
|
|
5576
5576
|
ZodFirstPartyTypeKind || (ZodFirstPartyTypeKind = {});
|
|
5577
5577
|
//#endregion
|
|
5578
|
-
//#region ../types/dist/sleep
|
|
5578
|
+
//#region ../types/dist/sleep--jXS9hWo.mjs
|
|
5579
5579
|
/**
|
|
5580
5580
|
* The audio chunk plane's byte format, and the ONE expansion from a coded
|
|
5581
5581
|
* window to float samples (D455).
|
|
@@ -9107,6 +9107,7 @@ var CAP_NAMES = Object.freeze([
|
|
|
9107
9107
|
"filesystem-browse",
|
|
9108
9108
|
"flood",
|
|
9109
9109
|
"gas",
|
|
9110
|
+
"group-active",
|
|
9110
9111
|
"group-commands",
|
|
9111
9112
|
"group-status",
|
|
9112
9113
|
"heating-valve",
|
|
@@ -9129,6 +9130,7 @@ var CAP_NAMES = Object.freeze([
|
|
|
9129
9130
|
"login-method",
|
|
9130
9131
|
"media-player",
|
|
9131
9132
|
"mesh-network",
|
|
9133
|
+
"meter",
|
|
9132
9134
|
"metrics-provider",
|
|
9133
9135
|
"model-convert",
|
|
9134
9136
|
"model-distributor",
|
|
@@ -9927,6 +9929,10 @@ Object.freeze({
|
|
|
9927
9929
|
"path": "detected",
|
|
9928
9930
|
"valueType": "boolean"
|
|
9929
9931
|
}],
|
|
9932
|
+
"group-active": [{
|
|
9933
|
+
"path": "active",
|
|
9934
|
+
"valueType": "boolean"
|
|
9935
|
+
}],
|
|
9930
9936
|
"group-status": [
|
|
9931
9937
|
{
|
|
9932
9938
|
"path": "included",
|
|
@@ -10186,6 +10192,10 @@ Object.freeze({
|
|
|
10186
10192
|
]
|
|
10187
10193
|
}
|
|
10188
10194
|
],
|
|
10195
|
+
"meter": [{
|
|
10196
|
+
"path": "value",
|
|
10197
|
+
"valueType": "number"
|
|
10198
|
+
}],
|
|
10189
10199
|
"motion": [
|
|
10190
10200
|
{
|
|
10191
10201
|
"path": "detected",
|
|
@@ -11081,7 +11091,7 @@ function sleep(ms) {
|
|
|
11081
11091
|
return new Promise((resolve) => setTimeout(resolve, Math.max(0, ms)));
|
|
11082
11092
|
}
|
|
11083
11093
|
//#endregion
|
|
11084
|
-
//#region ../types/dist/err-msg-
|
|
11094
|
+
//#region ../types/dist/err-msg-DIorGYeC.mjs
|
|
11085
11095
|
var DeviceType = /* @__PURE__ */ function(DeviceType) {
|
|
11086
11096
|
DeviceType["Camera"] = "camera";
|
|
11087
11097
|
DeviceType["Hub"] = "hub";
|
|
@@ -11175,8 +11185,14 @@ var DeviceType = /* @__PURE__ */ function(DeviceType) {
|
|
|
11175
11185
|
DeviceType["PetFeeder"] = "pet-feeder";
|
|
11176
11186
|
/** Built-in dishwasher — program lifecycle, door / remote-start gates,
|
|
11177
11187
|
* salt and rinse-aid levels. Installed with the `dishwasher` cap.
|
|
11178
|
-
* Sources: native Bosch Home Connect, reusable by similar integrations.
|
|
11188
|
+
* Sources: native Bosch Home Connect, reusable by similar integrations.
|
|
11189
|
+
* A plug-built dishwasher carries running-state and power instead. */
|
|
11179
11190
|
DeviceType["Dishwasher"] = "dishwasher";
|
|
11191
|
+
/** Washing machine. A plug-built one is running while its power stays
|
|
11192
|
+
* above a threshold. No program cap — that surface is the dishwasher's. */
|
|
11193
|
+
DeviceType["Washer"] = "washer";
|
|
11194
|
+
/** Tumble dryer. Same plug-built running surface as {@link Washer}. */
|
|
11195
|
+
DeviceType["Dryer"] = "dryer";
|
|
11180
11196
|
return DeviceType;
|
|
11181
11197
|
}({});
|
|
11182
11198
|
var DeviceFeature = /* @__PURE__ */ function(DeviceFeature) {
|
|
@@ -11434,7 +11450,7 @@ function errMsg(err) {
|
|
|
11434
11450
|
return String(err);
|
|
11435
11451
|
}
|
|
11436
11452
|
//#endregion
|
|
11437
|
-
//#region ../types/dist/composition-
|
|
11453
|
+
//#region ../types/dist/composition-Bb8iwHEJ.mjs
|
|
11438
11454
|
var AUDIO_ENCODER_BY_CODEC = {
|
|
11439
11455
|
opus: "libopus",
|
|
11440
11456
|
aac: "aac",
|
|
@@ -12585,6 +12601,13 @@ var table = {
|
|
|
12585
12601
|
apply: () => {
|
|
12586
12602
|
throw new ExpressionEvalError("latchedAt: stateful evaluation context is required");
|
|
12587
12603
|
}
|
|
12604
|
+
},
|
|
12605
|
+
schmitt: {
|
|
12606
|
+
minArgs: 3,
|
|
12607
|
+
maxArgs: 5,
|
|
12608
|
+
apply: () => {
|
|
12609
|
+
throw new ExpressionEvalError("schmitt: stateful evaluation context is required");
|
|
12610
|
+
}
|
|
12588
12611
|
}
|
|
12589
12612
|
};
|
|
12590
12613
|
Object.freeze(Object.assign(Object.create(null), table));
|
|
@@ -13026,6 +13049,99 @@ function validateExpressionSource(src) {
|
|
|
13026
13049
|
return null;
|
|
13027
13050
|
}
|
|
13028
13051
|
/**
|
|
13052
|
+
* One power reading becomes a washer, dryer or dishwasher (D944 helper).
|
|
13053
|
+
*
|
|
13054
|
+
* Standby of the control board is under 5 W; a motor or a heater is far
|
|
13055
|
+
* above that, so 5 W is the line. A door lock or a short pump spike is not
|
|
13056
|
+
* a cycle, so running starts only after 30 s above the line.
|
|
13057
|
+
*
|
|
13058
|
+
* A wash, dry or dishwasher pause (soak, heat-wait, heater off between
|
|
13059
|
+
* bursts) lasts several minutes. Ending the cycle on the first dip would
|
|
13060
|
+
* report "finished" in the middle of the program, so the stop dwell is
|
|
13061
|
+
* 10 minutes on every type. The number is stored per type so one machine
|
|
13062
|
+
* can move later without moving the others.
|
|
13063
|
+
*/
|
|
13064
|
+
var APPLIANCE_TEMPLATE_ID = "appliance";
|
|
13065
|
+
var APPLIANCE_KINDS = [
|
|
13066
|
+
"washer",
|
|
13067
|
+
"dryer",
|
|
13068
|
+
"dishwasher"
|
|
13069
|
+
];
|
|
13070
|
+
DeviceType.Washer, DeviceType.Dryer, DeviceType.Dishwasher;
|
|
13071
|
+
/**
|
|
13072
|
+
* Statistics and integrals over a history read (D944).
|
|
13073
|
+
*
|
|
13074
|
+
* Pure: the same points always give the same answer, so a restart recomputes
|
|
13075
|
+
* rather than trusting a buffer. A gauge mean is time-weighted (value × ms),
|
|
13076
|
+
* never the mean of the samples. A hole with no held value is not integrated
|
|
13077
|
+
* as zero. A truncated read is not published.
|
|
13078
|
+
*/
|
|
13079
|
+
var STATISTIC_STATS = [
|
|
13080
|
+
"min",
|
|
13081
|
+
"max",
|
|
13082
|
+
"mean",
|
|
13083
|
+
"sum",
|
|
13084
|
+
"count",
|
|
13085
|
+
"change"
|
|
13086
|
+
];
|
|
13087
|
+
/**
|
|
13088
|
+
* The range a statistics or integral helper asks history for (D944).
|
|
13089
|
+
*
|
|
13090
|
+
* Calendar edges are the hub's timezone, never UTC midnight: a day is 23, 24
|
|
13091
|
+
* or 25 hours across a DST change. A tier is eligible only when its retention
|
|
13092
|
+
* is strictly longer than the longest that range can be. Forever qualifies.
|
|
13093
|
+
* Equal to a tier's retention is a refusal, not a short answer.
|
|
13094
|
+
*/
|
|
13095
|
+
var MINUTE_MS = 6e4;
|
|
13096
|
+
var HOUR_MS = 60 * MINUTE_MS;
|
|
13097
|
+
var DAY_MS = 24 * HOUR_MS;
|
|
13098
|
+
var ROLLING_SPANS = [
|
|
13099
|
+
"1h",
|
|
13100
|
+
"24h",
|
|
13101
|
+
"2d",
|
|
13102
|
+
"7d",
|
|
13103
|
+
"30d",
|
|
13104
|
+
"custom"
|
|
13105
|
+
];
|
|
13106
|
+
var CALENDAR_PERIODS = [
|
|
13107
|
+
"today",
|
|
13108
|
+
"yesterday",
|
|
13109
|
+
"this-week",
|
|
13110
|
+
"this-month"
|
|
13111
|
+
];
|
|
13112
|
+
var RESET_PERIODS = [
|
|
13113
|
+
"never",
|
|
13114
|
+
"daily",
|
|
13115
|
+
"weekly",
|
|
13116
|
+
"monthly"
|
|
13117
|
+
];
|
|
13118
|
+
5 * MINUTE_MS;
|
|
13119
|
+
24 * HOUR_MS, 2 * DAY_MS, 7 * DAY_MS, 30 * DAY_MS;
|
|
13120
|
+
7 * DAY_MS, 30 * DAY_MS, 365 * DAY_MS;
|
|
13121
|
+
var rollingWindowObject = object({
|
|
13122
|
+
kind: literal("rolling"),
|
|
13123
|
+
span: _enum(ROLLING_SPANS),
|
|
13124
|
+
customMinutes: number().int().min(5).optional()
|
|
13125
|
+
}).check((payload) => {
|
|
13126
|
+
if (payload.value.span === "custom" && payload.value.customMinutes === void 0) payload.issues.push({
|
|
13127
|
+
code: "custom",
|
|
13128
|
+
message: "a custom range needs a duration in minutes",
|
|
13129
|
+
path: ["customMinutes"],
|
|
13130
|
+
input: payload.value
|
|
13131
|
+
});
|
|
13132
|
+
if (payload.value.span !== "custom" && payload.value.customMinutes !== void 0) payload.issues.push({
|
|
13133
|
+
code: "custom",
|
|
13134
|
+
message: "only a custom range carries a duration",
|
|
13135
|
+
path: ["customMinutes"],
|
|
13136
|
+
input: payload.value
|
|
13137
|
+
});
|
|
13138
|
+
});
|
|
13139
|
+
var RollingWindowSchema = rollingWindowObject;
|
|
13140
|
+
var StatisticWindowSchema = discriminatedUnion("kind", [rollingWindowObject, object({
|
|
13141
|
+
kind: literal("calendar"),
|
|
13142
|
+
period: _enum(CALENDAR_PERIODS)
|
|
13143
|
+
})]);
|
|
13144
|
+
/**
|
|
13029
13145
|
* A composition source identity: `(addonId, stableId)`, never a numeric device
|
|
13030
13146
|
* id. Split out so helper schemas can name it without a cycle through
|
|
13031
13147
|
* `composition.ts` (D659).
|
|
@@ -13051,7 +13167,13 @@ var GROUP_TEMPLATE_IDS = [
|
|
|
13051
13167
|
"occupancy",
|
|
13052
13168
|
"binary",
|
|
13053
13169
|
"switch",
|
|
13054
|
-
"light"
|
|
13170
|
+
"light",
|
|
13171
|
+
"fan",
|
|
13172
|
+
"cover",
|
|
13173
|
+
"valve",
|
|
13174
|
+
"lock",
|
|
13175
|
+
"media-player",
|
|
13176
|
+
"climate"
|
|
13055
13177
|
];
|
|
13056
13178
|
var NUMERIC_AGGREGATES = [
|
|
13057
13179
|
"mean",
|
|
@@ -13081,14 +13203,73 @@ var HelperMemberSchema = object({
|
|
|
13081
13203
|
cap: string().min(1),
|
|
13082
13204
|
fieldPath: string().min(1)
|
|
13083
13205
|
});
|
|
13084
|
-
var HelperSpecSchema = discriminatedUnion("kind", [
|
|
13085
|
-
|
|
13086
|
-
|
|
13087
|
-
|
|
13088
|
-
|
|
13089
|
-
|
|
13090
|
-
|
|
13091
|
-
|
|
13206
|
+
var HelperSpecSchema = discriminatedUnion("kind", [
|
|
13207
|
+
object({
|
|
13208
|
+
kind: literal("group"),
|
|
13209
|
+
templateId: GroupTemplateIdSchema,
|
|
13210
|
+
aggregate: AggregateReducerSchema,
|
|
13211
|
+
members: array(HelperMemberSchema).min(1).max(64),
|
|
13212
|
+
/** Actuator groups only. Readings leave this unset. */
|
|
13213
|
+
active: ActiveCriterionSchema.optional()
|
|
13214
|
+
}),
|
|
13215
|
+
object({
|
|
13216
|
+
kind: literal("appliance"),
|
|
13217
|
+
templateId: literal(APPLIANCE_TEMPLATE_ID),
|
|
13218
|
+
appliance: _enum(APPLIANCE_KINDS),
|
|
13219
|
+
thresholdWatts: number().positive(),
|
|
13220
|
+
startDwellMs: number().int().nonnegative(),
|
|
13221
|
+
stopDwellMs: number().int().nonnegative(),
|
|
13222
|
+
member: HelperMemberSchema
|
|
13223
|
+
}),
|
|
13224
|
+
object({
|
|
13225
|
+
kind: literal("statistic"),
|
|
13226
|
+
stat: _enum(STATISTIC_STATS),
|
|
13227
|
+
window: StatisticWindowSchema,
|
|
13228
|
+
source: HelperMemberSchema
|
|
13229
|
+
}),
|
|
13230
|
+
object({
|
|
13231
|
+
kind: literal("integral"),
|
|
13232
|
+
reset: _enum(RESET_PERIODS),
|
|
13233
|
+
output: _enum(["energy", "meter"]),
|
|
13234
|
+
source: HelperMemberSchema
|
|
13235
|
+
}),
|
|
13236
|
+
object({
|
|
13237
|
+
kind: literal("threshold"),
|
|
13238
|
+
source: HelperMemberSchema,
|
|
13239
|
+
high: number(),
|
|
13240
|
+
low: number(),
|
|
13241
|
+
onForMs: number().int().nonnegative(),
|
|
13242
|
+
offForMs: number().int().nonnegative()
|
|
13243
|
+
}),
|
|
13244
|
+
object({
|
|
13245
|
+
kind: literal("arithmetic"),
|
|
13246
|
+
op: _enum([
|
|
13247
|
+
"sum",
|
|
13248
|
+
"difference",
|
|
13249
|
+
"ratio"
|
|
13250
|
+
]),
|
|
13251
|
+
inputs: array(HelperMemberSchema).min(2).max(64)
|
|
13252
|
+
}),
|
|
13253
|
+
object({
|
|
13254
|
+
kind: literal("expression"),
|
|
13255
|
+
expr: string().min(1),
|
|
13256
|
+
inputs: array(object({
|
|
13257
|
+
name: string().min(1),
|
|
13258
|
+
member: HelperMemberSchema
|
|
13259
|
+
})).min(1).max(64),
|
|
13260
|
+
output: _enum(["number", "boolean"])
|
|
13261
|
+
}),
|
|
13262
|
+
object({
|
|
13263
|
+
kind: literal("derivative"),
|
|
13264
|
+
window: RollingWindowSchema,
|
|
13265
|
+
per: _enum([
|
|
13266
|
+
"second",
|
|
13267
|
+
"minute",
|
|
13268
|
+
"hour"
|
|
13269
|
+
]),
|
|
13270
|
+
source: HelperMemberSchema
|
|
13271
|
+
})
|
|
13272
|
+
]);
|
|
13092
13273
|
/** A composed device's stableId is this prefix plus the block id. */
|
|
13093
13274
|
var COMPOSED_DEVICE_STABLE_ID_PREFIX = "composed-";
|
|
13094
13275
|
/** Longest snippet a `code` source may carry (slice 4). */
|
|
@@ -13149,6 +13330,12 @@ var CompositionFieldSourceSchema = discriminatedUnion("kind", [
|
|
|
13149
13330
|
"all"
|
|
13150
13331
|
]),
|
|
13151
13332
|
reads: array(CompositionFieldReadSchema).min(1).max(64),
|
|
13333
|
+
/**
|
|
13334
|
+
* Set when the reads are an enum state, not a yes/no: the listed states
|
|
13335
|
+
* count as active (a cover is `open`). A state outside the list is inactive;
|
|
13336
|
+
* a read that is not a state at all is left out. Only `any` / `all` use it.
|
|
13337
|
+
*/
|
|
13338
|
+
activeWhen: array(string().min(1)).min(1).optional(),
|
|
13152
13339
|
/** `value` is the reading; the others are the member counts. */
|
|
13153
13340
|
publish: _enum([
|
|
13154
13341
|
"value",
|
|
@@ -13162,6 +13349,26 @@ var CompositionFieldSourceSchema = discriminatedUnion("kind", [
|
|
|
13162
13349
|
"omit",
|
|
13163
13350
|
"offline"
|
|
13164
13351
|
])
|
|
13352
|
+
}),
|
|
13353
|
+
object({
|
|
13354
|
+
kind: literal("series"),
|
|
13355
|
+
read: CompositionFieldReadSchema,
|
|
13356
|
+
/** `value` is the statistic or the integral. The others are the gap counts. */
|
|
13357
|
+
publish: _enum([
|
|
13358
|
+
"value",
|
|
13359
|
+
"included",
|
|
13360
|
+
"excluded",
|
|
13361
|
+
"total"
|
|
13362
|
+
]),
|
|
13363
|
+
/**
|
|
13364
|
+
* What an unanswered `value` does. Counts ignore this. `offline` leaves the
|
|
13365
|
+
* device unseeded until history answers, so a restart cannot publish 0.
|
|
13366
|
+
*/
|
|
13367
|
+
empty: _enum([
|
|
13368
|
+
"null",
|
|
13369
|
+
"omit",
|
|
13370
|
+
"offline"
|
|
13371
|
+
])
|
|
13165
13372
|
})
|
|
13166
13373
|
]);
|
|
13167
13374
|
var CompositionCommandTargetSchema = discriminatedUnion("kind", [object({
|
|
@@ -21148,7 +21355,8 @@ var CompositionProblemSchema = object({
|
|
|
21148
21355
|
"native-capability-replace",
|
|
21149
21356
|
"mixed-quantity",
|
|
21150
21357
|
"helper-mismatch",
|
|
21151
|
-
"member-constraint"
|
|
21358
|
+
"member-constraint",
|
|
21359
|
+
"retention"
|
|
21152
21360
|
]),
|
|
21153
21361
|
path: string(),
|
|
21154
21362
|
message: string()
|
|
@@ -21382,13 +21590,17 @@ Object.freeze({
|
|
|
21382
21590
|
latchedAt: {
|
|
21383
21591
|
kind: "fixed",
|
|
21384
21592
|
result: ["number", "null"]
|
|
21593
|
+
},
|
|
21594
|
+
schmitt: {
|
|
21595
|
+
kind: "fixed",
|
|
21596
|
+
result: ["boolean", "null"]
|
|
21385
21597
|
}
|
|
21386
21598
|
});
|
|
21387
21599
|
/**
|
|
21388
21600
|
* One catalog row per base reading a group helper can build (D944 §3).
|
|
21389
21601
|
* Data, not a form default written into the block.
|
|
21390
21602
|
*/
|
|
21391
|
-
var NOW = {
|
|
21603
|
+
var NOW$2 = {
|
|
21392
21604
|
fieldPath: "lastFetchedAt",
|
|
21393
21605
|
expr: "now"
|
|
21394
21606
|
};
|
|
@@ -21402,6 +21614,8 @@ function numeric(input) {
|
|
|
21402
21614
|
family: "numeric",
|
|
21403
21615
|
deviceType: DeviceType.Sensor,
|
|
21404
21616
|
memberDeviceType: DeviceType.Sensor,
|
|
21617
|
+
memberDeviceTypes: [DeviceType.Sensor],
|
|
21618
|
+
activeWhen: void 0,
|
|
21405
21619
|
commandCaps: [],
|
|
21406
21620
|
baseUnit: baseUnitOf(input.quantity),
|
|
21407
21621
|
aggregates: NUMERIC_AGGREGATES,
|
|
@@ -21417,6 +21631,8 @@ function binary(input) {
|
|
|
21417
21631
|
family: "binary",
|
|
21418
21632
|
deviceType: DeviceType.Sensor,
|
|
21419
21633
|
memberDeviceType: DeviceType.Sensor,
|
|
21634
|
+
memberDeviceTypes: [DeviceType.Sensor],
|
|
21635
|
+
activeWhen: void 0,
|
|
21420
21636
|
commandCaps: [],
|
|
21421
21637
|
quantity: "none",
|
|
21422
21638
|
baseUnit: void 0,
|
|
@@ -21434,7 +21650,7 @@ var GROUP_TEMPLATES = [
|
|
|
21434
21650
|
quantity: "temperature",
|
|
21435
21651
|
defaultAggregate: "mean",
|
|
21436
21652
|
empty: "null",
|
|
21437
|
-
companions: [NOW]
|
|
21653
|
+
companions: [NOW$2]
|
|
21438
21654
|
}),
|
|
21439
21655
|
numeric({
|
|
21440
21656
|
id: "humidity",
|
|
@@ -21445,7 +21661,7 @@ var GROUP_TEMPLATES = [
|
|
|
21445
21661
|
quantity: "humidity",
|
|
21446
21662
|
defaultAggregate: "mean",
|
|
21447
21663
|
empty: "null",
|
|
21448
|
-
companions: [NOW]
|
|
21664
|
+
companions: [NOW$2]
|
|
21449
21665
|
}),
|
|
21450
21666
|
numeric({
|
|
21451
21667
|
id: "pressure",
|
|
@@ -21456,7 +21672,7 @@ var GROUP_TEMPLATES = [
|
|
|
21456
21672
|
quantity: "pressure",
|
|
21457
21673
|
defaultAggregate: "mean",
|
|
21458
21674
|
empty: "null",
|
|
21459
|
-
companions: [NOW]
|
|
21675
|
+
companions: [NOW$2]
|
|
21460
21676
|
}),
|
|
21461
21677
|
numeric({
|
|
21462
21678
|
id: "illuminance",
|
|
@@ -21467,7 +21683,7 @@ var GROUP_TEMPLATES = [
|
|
|
21467
21683
|
quantity: "illuminance",
|
|
21468
21684
|
defaultAggregate: "mean",
|
|
21469
21685
|
empty: "null",
|
|
21470
|
-
companions: [NOW]
|
|
21686
|
+
companions: [NOW$2]
|
|
21471
21687
|
}),
|
|
21472
21688
|
numeric({
|
|
21473
21689
|
id: "power",
|
|
@@ -21478,7 +21694,7 @@ var GROUP_TEMPLATES = [
|
|
|
21478
21694
|
quantity: "power",
|
|
21479
21695
|
defaultAggregate: "sum",
|
|
21480
21696
|
empty: "omit",
|
|
21481
|
-
companions: [NOW]
|
|
21697
|
+
companions: [NOW$2]
|
|
21482
21698
|
}),
|
|
21483
21699
|
numeric({
|
|
21484
21700
|
id: "energy",
|
|
@@ -21489,7 +21705,7 @@ var GROUP_TEMPLATES = [
|
|
|
21489
21705
|
quantity: "energy",
|
|
21490
21706
|
defaultAggregate: "sum",
|
|
21491
21707
|
empty: "omit",
|
|
21492
|
-
companions: [NOW]
|
|
21708
|
+
companions: [NOW$2]
|
|
21493
21709
|
}),
|
|
21494
21710
|
numeric({
|
|
21495
21711
|
id: "battery",
|
|
@@ -21524,7 +21740,7 @@ var GROUP_TEMPLATES = [
|
|
|
21524
21740
|
quantity: "device",
|
|
21525
21741
|
defaultAggregate: "mean",
|
|
21526
21742
|
empty: "null",
|
|
21527
|
-
companions: [NOW]
|
|
21743
|
+
companions: [NOW$2]
|
|
21528
21744
|
}),
|
|
21529
21745
|
binary({
|
|
21530
21746
|
id: "motion",
|
|
@@ -21618,6 +21834,11 @@ var GROUP_TEMPLATES = [
|
|
|
21618
21834
|
summary: "On when at least one switch is on, or when all of them are. Offline and unknown members are left out of that decision, never read as off, and still receive the command.",
|
|
21619
21835
|
deviceType: DeviceType.Switch,
|
|
21620
21836
|
outputCap: "switch",
|
|
21837
|
+
outputField: "on",
|
|
21838
|
+
member: {
|
|
21839
|
+
cap: "switch",
|
|
21840
|
+
fieldPath: "on"
|
|
21841
|
+
},
|
|
21621
21842
|
commandCaps: ["switch"]
|
|
21622
21843
|
}),
|
|
21623
21844
|
actuator({
|
|
@@ -21625,34 +21846,136 @@ var GROUP_TEMPLATES = [
|
|
|
21625
21846
|
summary: "On when at least one light is on, or when all of them are. Brightness and colour are offered only when every member has them. A command is not sent to a member that lacks it.",
|
|
21626
21847
|
deviceType: DeviceType.Light,
|
|
21627
21848
|
outputCap: "switch",
|
|
21849
|
+
outputField: "on",
|
|
21850
|
+
member: {
|
|
21851
|
+
cap: "switch",
|
|
21852
|
+
fieldPath: "on"
|
|
21853
|
+
},
|
|
21628
21854
|
commandCaps: [
|
|
21629
21855
|
"switch",
|
|
21630
21856
|
"brightness",
|
|
21631
21857
|
"color"
|
|
21632
21858
|
]
|
|
21859
|
+
}),
|
|
21860
|
+
actuator({
|
|
21861
|
+
id: "fan",
|
|
21862
|
+
summary: "On when at least one fan is on, or when all of them are. Speed, preset, direction and oscillation are offered only when every fan has them. A command is not sent to a fan that lacks it.",
|
|
21863
|
+
deviceType: DeviceType.Fan,
|
|
21864
|
+
outputCap: "switch",
|
|
21865
|
+
outputField: "on",
|
|
21866
|
+
member: {
|
|
21867
|
+
cap: "switch",
|
|
21868
|
+
fieldPath: "on"
|
|
21869
|
+
},
|
|
21870
|
+
commandCaps: ["switch", "fan-control"]
|
|
21871
|
+
}),
|
|
21872
|
+
actuator({
|
|
21873
|
+
id: "cover",
|
|
21874
|
+
summary: "Open when at least one cover is open or part-open, or only when all of them are. Position and tilt are offered only when every cover has them. A cover that reports nothing is left out, never read as closed.",
|
|
21875
|
+
deviceType: DeviceType.Cover,
|
|
21876
|
+
outputCap: "group-active",
|
|
21877
|
+
outputField: "active",
|
|
21878
|
+
member: {
|
|
21879
|
+
cap: "cover",
|
|
21880
|
+
fieldPath: "state"
|
|
21881
|
+
},
|
|
21882
|
+
activeWhen: [
|
|
21883
|
+
"open",
|
|
21884
|
+
"opening",
|
|
21885
|
+
"stopped"
|
|
21886
|
+
],
|
|
21887
|
+
commandCaps: ["cover"]
|
|
21888
|
+
}),
|
|
21889
|
+
actuator({
|
|
21890
|
+
id: "valve",
|
|
21891
|
+
summary: "Open when at least one valve is open or part-open, or only when all of them are. Position is offered only when every valve has it. A valve that reports nothing is left out, never read as closed.",
|
|
21892
|
+
deviceType: DeviceType.Valve,
|
|
21893
|
+
outputCap: "group-active",
|
|
21894
|
+
outputField: "active",
|
|
21895
|
+
member: {
|
|
21896
|
+
cap: "valve",
|
|
21897
|
+
fieldPath: "state"
|
|
21898
|
+
},
|
|
21899
|
+
activeWhen: [
|
|
21900
|
+
"open",
|
|
21901
|
+
"opening",
|
|
21902
|
+
"stopped"
|
|
21903
|
+
],
|
|
21904
|
+
commandCaps: ["valve"]
|
|
21905
|
+
}),
|
|
21906
|
+
actuator({
|
|
21907
|
+
id: "lock",
|
|
21908
|
+
summary: "Locked when at least one lock is locked, or only when all of them are. A jammed or moving lock is not locked. Locking is one tap; unlocking the group needs a confirmation every time, and nothing is sent without it.",
|
|
21909
|
+
deviceType: DeviceType.Lock,
|
|
21910
|
+
outputCap: "group-active",
|
|
21911
|
+
outputField: "active",
|
|
21912
|
+
member: {
|
|
21913
|
+
cap: "lock-control",
|
|
21914
|
+
fieldPath: "state"
|
|
21915
|
+
},
|
|
21916
|
+
activeWhen: ["locked"],
|
|
21917
|
+
commandCaps: ["lock-control"]
|
|
21918
|
+
}),
|
|
21919
|
+
actuator({
|
|
21920
|
+
id: "media-player",
|
|
21921
|
+
summary: "Playing when at least one player is playing, or only when all of them are. Volume is offered only when every player has it. A player that reports nothing is left out, never read as stopped.",
|
|
21922
|
+
deviceType: DeviceType.MediaPlayer,
|
|
21923
|
+
outputCap: "group-active",
|
|
21924
|
+
outputField: "active",
|
|
21925
|
+
member: {
|
|
21926
|
+
cap: "media-player",
|
|
21927
|
+
fieldPath: "state"
|
|
21928
|
+
},
|
|
21929
|
+
activeWhen: ["playing", "buffering"],
|
|
21930
|
+
commandCaps: ["media-player"]
|
|
21931
|
+
}),
|
|
21932
|
+
actuator({
|
|
21933
|
+
id: "climate",
|
|
21934
|
+
summary: "Running when at least one thermostat or air conditioner is not off, or only when all of them are. Target temperature and fan are offered only when every device has them. A device that reports nothing is left out, never read as off.",
|
|
21935
|
+
deviceType: DeviceType.Thermostat,
|
|
21936
|
+
memberDeviceTypes: [DeviceType.Thermostat, DeviceType.Climate],
|
|
21937
|
+
outputCap: "group-active",
|
|
21938
|
+
outputField: "active",
|
|
21939
|
+
member: {
|
|
21940
|
+
cap: "climate-control",
|
|
21941
|
+
fieldPath: "mode"
|
|
21942
|
+
},
|
|
21943
|
+
activeWhen: [
|
|
21944
|
+
"heat",
|
|
21945
|
+
"cool",
|
|
21946
|
+
"auto",
|
|
21947
|
+
"heat_cool",
|
|
21948
|
+
"fan_only",
|
|
21949
|
+
"dry"
|
|
21950
|
+
],
|
|
21951
|
+
commandCaps: ["climate-control"]
|
|
21633
21952
|
})
|
|
21634
21953
|
];
|
|
21635
21954
|
function actuator(input) {
|
|
21636
21955
|
return {
|
|
21637
|
-
|
|
21956
|
+
id: input.id,
|
|
21957
|
+
summary: input.summary,
|
|
21958
|
+
deviceType: input.deviceType,
|
|
21959
|
+
outputCap: input.outputCap,
|
|
21960
|
+
outputField: input.outputField,
|
|
21961
|
+
commandCaps: input.commandCaps,
|
|
21638
21962
|
family: "actuator",
|
|
21639
21963
|
role: void 0,
|
|
21640
21964
|
memberDeviceType: input.deviceType,
|
|
21641
|
-
|
|
21965
|
+
memberDeviceTypes: input.memberDeviceTypes ?? [input.deviceType],
|
|
21966
|
+
activeWhen: input.activeWhen,
|
|
21642
21967
|
quantity: "none",
|
|
21643
21968
|
baseUnit: void 0,
|
|
21644
21969
|
aggregates: BINARY_AGGREGATES,
|
|
21645
21970
|
defaultAggregate: "any",
|
|
21646
21971
|
empty: "offline",
|
|
21647
|
-
accept: [
|
|
21648
|
-
cap: "switch",
|
|
21649
|
-
fieldPath: "on"
|
|
21650
|
-
}],
|
|
21972
|
+
accept: [input.member],
|
|
21651
21973
|
companions: [CHANGED]
|
|
21652
21974
|
};
|
|
21653
21975
|
}
|
|
21654
21976
|
new Map(GROUP_TEMPLATES.map((template) => [template.id, template]));
|
|
21655
21977
|
DeviceFeature.LightColorRgb, DeviceFeature.LightColorHsv, DeviceFeature.LightColorMired;
|
|
21978
|
+
DeviceType.Camera;
|
|
21656
21979
|
`${COMPOSED_DEVICE_STABLE_ID_PREFIX}`;
|
|
21657
21980
|
/**
|
|
21658
21981
|
* What a composition may BUILD on a device type (G2, D676): the caps a new
|
|
@@ -49755,7 +50078,20 @@ var NcRuleInputSchema = object({
|
|
|
49755
50078
|
* save by the hub's grouping guard). `.optional()`, never `.default()`: the addon cap
|
|
49756
50079
|
* path does not run Zod defaults.
|
|
49757
50080
|
*/
|
|
49758
|
-
groupingSec: number().int().min(5).max(60).optional()
|
|
50081
|
+
groupingSec: number().int().min(5).max(60).optional(),
|
|
50082
|
+
/**
|
|
50083
|
+
* ASK ME TO CONFIRM DETECTIONS (#243): a DETECTION notification of this rule
|
|
50084
|
+
* carries "Correct" / "Wrong" buttons (and, where the channel has room, a
|
|
50085
|
+
* "Wrong, it is a <class>" choice). A tap marks the track for retraining, the
|
|
50086
|
+
* same mark the Library writes, and records whose notification it was and
|
|
50087
|
+
* when. A channel with no buttons gets the same two choices as links.
|
|
50088
|
+
*
|
|
50089
|
+
* `.optional()`, never `.default()` (a Zod default does not run on the addon
|
|
50090
|
+
* cap path): absent and `false` both mean off, which is what every rule
|
|
50091
|
+
* authored before this field meant. An editor turns it off by writing
|
|
50092
|
+
* `false`, so it needs no `clear` key.
|
|
50093
|
+
*/
|
|
50094
|
+
askVerdict: boolean().optional()
|
|
49759
50095
|
});
|
|
49760
50096
|
/**
|
|
49761
50097
|
* Partial patch for `updateRule` — any subset of the input fields, plus the
|
|
@@ -62940,7 +63276,13 @@ results: array(object({
|
|
|
62940
63276
|
/** Ms epoch of the attempt. */
|
|
62941
63277
|
at: number()
|
|
62942
63278
|
})) });
|
|
62943
|
-
DeviceType.Switch, DeviceType.Light;
|
|
63279
|
+
DeviceType.Switch, DeviceType.Light, DeviceType.Fan, DeviceType.Cover, DeviceType.Valve, DeviceType.Lock, DeviceType.MediaPlayer, DeviceType.Thermostat, DeviceType.Climate;
|
|
63280
|
+
object({
|
|
63281
|
+
active: boolean().meta({ label: "Active" }),
|
|
63282
|
+
/** Ms epoch when the slice was last updated. */
|
|
63283
|
+
lastChangedAt: number()
|
|
63284
|
+
});
|
|
63285
|
+
DeviceType.Cover, DeviceType.Valve, DeviceType.Lock, DeviceType.MediaPlayer, DeviceType.Climate, DeviceType.Thermostat;
|
|
62944
63286
|
object({
|
|
62945
63287
|
/** Members whose current value entered the aggregate. */
|
|
62946
63288
|
included: number().int().nonnegative().meta(readingMeta("count", {
|
|
@@ -62958,7 +63300,7 @@ object({
|
|
|
62958
63300
|
label: "Members"
|
|
62959
63301
|
}))
|
|
62960
63302
|
});
|
|
62961
|
-
DeviceType.Sensor, DeviceType.Switch, DeviceType.Light;
|
|
63303
|
+
DeviceType.Sensor, DeviceType.Switch, DeviceType.Light, DeviceType.Fan, DeviceType.Cover, DeviceType.Valve, DeviceType.Lock, DeviceType.MediaPlayer, DeviceType.Thermostat, DeviceType.Climate;
|
|
62962
63304
|
object({
|
|
62963
63305
|
/** Radiator valve opening 0 (closed) .. 100 (open). Null = not yet known. */
|
|
62964
63306
|
position: number().min(0).max(100).nullable().meta(readingMeta("percentage")),
|
|
@@ -63865,7 +64207,14 @@ DeviceType.Lock, method(object({
|
|
|
63865
64207
|
auth: "protected"
|
|
63866
64208
|
}), method(object({
|
|
63867
64209
|
deviceId: number().int().nonnegative(),
|
|
63868
|
-
code: string().min(1).optional()
|
|
64210
|
+
code: string().min(1).optional(),
|
|
64211
|
+
/**
|
|
64212
|
+
* Honoured by a helper lock GROUP only (D944): unlocking several doors
|
|
64213
|
+
* with one call is refused unless the caller says it was confirmed. A
|
|
64214
|
+
* single lock ignores it. The refusal lives in the callee, so no
|
|
64215
|
+
* automation or API caller reaches the doors by skipping a dialog.
|
|
64216
|
+
*/
|
|
64217
|
+
confirm: boolean().optional()
|
|
63869
64218
|
}), _void(), {
|
|
63870
64219
|
kind: "mutation",
|
|
63871
64220
|
auth: "protected"
|
|
@@ -63873,6 +64222,11 @@ DeviceType.Lock, method(object({
|
|
|
63873
64222
|
kind: "mutation",
|
|
63874
64223
|
auth: "protected"
|
|
63875
64224
|
});
|
|
64225
|
+
object({
|
|
64226
|
+
value: number().nullable().meta(readingMeta("device", { label: "Total" })),
|
|
64227
|
+
lastFetchedAt: number()
|
|
64228
|
+
});
|
|
64229
|
+
DeviceType.Sensor;
|
|
63876
64230
|
/**
|
|
63877
64231
|
* Media-player cap. Models HA `media_player.*` (Sonos, Chromecast,
|
|
63878
64232
|
* Apple TV, Spotify, Roku, generic OTT receivers, …) on
|
|
@@ -65790,7 +66144,7 @@ object({
|
|
|
65790
66144
|
/** Ms epoch when the slice was last updated. */
|
|
65791
66145
|
lastFetchedAt: number()
|
|
65792
66146
|
});
|
|
65793
|
-
DeviceType.Sensor;
|
|
66147
|
+
DeviceType.Sensor, DeviceType.Washer, DeviceType.Dryer, DeviceType.Dishwasher;
|
|
65794
66148
|
/**
|
|
65795
66149
|
* Presence cap. Models HA `person.*` and `device_tracker.*` entities
|
|
65796
66150
|
* on `DeviceType.Presence`. Read-only — no setters: presence is
|
|
@@ -66237,7 +66591,7 @@ object({
|
|
|
66237
66591
|
phase: string().nullable()
|
|
66238
66592
|
});
|
|
66239
66593
|
Object.values(DeviceType);
|
|
66240
|
-
DeviceType.Dishwasher, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.MediaPlayer, DeviceType.WaterHeater, DeviceType.Humidifier, DeviceType.Fan, DeviceType.Climate, DeviceType.Thermostat, DeviceType.PetFeeder;
|
|
66594
|
+
DeviceType.Washer, DeviceType.Dryer, DeviceType.Dishwasher, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.MediaPlayer, DeviceType.WaterHeater, DeviceType.Humidifier, DeviceType.Fan, DeviceType.Climate, DeviceType.Thermostat, DeviceType.PetFeeder;
|
|
66241
66595
|
DeviceType.Camera, DeviceType.Sensor, DeviceType.Switch, method(object({ deviceId: number().int().nonnegative() }), object({ success: literal(true) }), {
|
|
66242
66596
|
kind: "mutation",
|
|
66243
66597
|
auth: "admin"
|
|
@@ -68800,7 +69154,7 @@ object({
|
|
|
68800
69154
|
/** Ms epoch of the last state change. Useful for UI "X minutes ago". */
|
|
68801
69155
|
lastChangedAt: number()
|
|
68802
69156
|
});
|
|
68803
|
-
DeviceType.Switch, DeviceType.Siren, DeviceType.Light, method(object({
|
|
69157
|
+
DeviceType.Switch, DeviceType.Siren, DeviceType.Light, DeviceType.Fan, method(object({
|
|
68804
69158
|
deviceId: number(),
|
|
68805
69159
|
on: boolean()
|
|
68806
69160
|
}), _void(), {
|
|
@@ -70532,8 +70886,9 @@ function dominantClipLabels(events) {
|
|
|
70532
70886
|
}
|
|
70533
70887
|
return [...counts.entries()].toSorted((x, y) => y[1] - x[1]).slice(0, 3).map(([name]) => name);
|
|
70534
70888
|
}
|
|
70889
|
+
DeviceFeature.FanSpeed, DeviceFeature.FanPreset, DeviceFeature.FanDirection, DeviceFeature.FanOscillating, DeviceFeature.CoverPositionable, DeviceFeature.CoverTilt, DeviceFeature.ValvePositionable, DeviceFeature.MediaPlayerVolume, DeviceFeature.ClimateFanMode;
|
|
70535
70890
|
SOURCE_CAPS.filter((cap) => cap !== "switch" && cap !== "motion");
|
|
70536
|
-
DeviceType.Camera, DeviceType.Sensor, DeviceType.Button, DeviceType.Switch, DeviceType.PetFeeder, DeviceType.Container, DeviceType.Thermostat, DeviceType.Camera, DeviceType.Hub, DeviceType.Light, DeviceType.Siren, DeviceType.Switch, DeviceType.Sensor, DeviceType.Thermostat, DeviceType.Climate, DeviceType.Button, DeviceType.EventEmitter, DeviceType.Update, DeviceType.Generic, DeviceType.Notifier, DeviceType.Script, DeviceType.Automation, DeviceType.Lock, DeviceType.Cover, DeviceType.Valve, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.Fan, DeviceType.MediaPlayer, DeviceType.AlarmPanel, DeviceType.Control, DeviceType.Presence, DeviceType.Weather, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.Container, DeviceType.Image, DeviceType.PetFeeder, DeviceType.Dishwasher, DeviceType.Camera, DeviceType.Camera, DeviceType.Dishwasher, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.MediaPlayer, DeviceType.WaterHeater, DeviceType.Humidifier, DeviceType.Fan, DeviceType.Climate, DeviceType.Thermostat, DeviceType.PetFeeder;
|
|
70891
|
+
DeviceType.Camera, DeviceType.Sensor, DeviceType.Button, DeviceType.Switch, DeviceType.PetFeeder, DeviceType.Container, DeviceType.Thermostat, DeviceType.Camera, DeviceType.Hub, DeviceType.Light, DeviceType.Siren, DeviceType.Switch, DeviceType.Sensor, DeviceType.Thermostat, DeviceType.Climate, DeviceType.Button, DeviceType.EventEmitter, DeviceType.Update, DeviceType.Generic, DeviceType.Notifier, DeviceType.Script, DeviceType.Automation, DeviceType.Lock, DeviceType.Cover, DeviceType.Valve, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.Fan, DeviceType.MediaPlayer, DeviceType.AlarmPanel, DeviceType.Control, DeviceType.Presence, DeviceType.Weather, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.Container, DeviceType.Image, DeviceType.PetFeeder, DeviceType.Dishwasher, DeviceType.Washer, DeviceType.Dryer, DeviceType.Camera, DeviceType.Camera, DeviceType.Washer, DeviceType.Dryer, DeviceType.Dishwasher, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.MediaPlayer, DeviceType.WaterHeater, DeviceType.Humidifier, DeviceType.Fan, DeviceType.Climate, DeviceType.Thermostat, DeviceType.PetFeeder;
|
|
70537
70892
|
String.raw`rose\(active(\d+), changed(\d+), (\d+(?:\.\d+)?)\)`;
|
|
70538
70893
|
DeviceRole.BinarySensor, DeviceRole.MotionSensor;
|
|
70539
70894
|
new Set(CAP_NAMES);
|
|
@@ -70604,7 +70959,7 @@ function deriveBatteryPresence(input) {
|
|
|
70604
70959
|
const budget = input.unreachableAfterMs ?? 216e5;
|
|
70605
70960
|
return input.nowMs - lastContactAt > budget ? "unreachable" : "sleeping";
|
|
70606
70961
|
}
|
|
70607
|
-
DeviceType.Cover, DeviceType.Valve, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.Camera, DeviceType.Hub, DeviceType.Switch, DeviceType.Siren, DeviceType.Light, DeviceType.Fan, DeviceType.Sensor, DeviceType.Thermostat, DeviceType.Climate, DeviceType.Button, DeviceType.EventEmitter, DeviceType.Update, DeviceType.Generic, DeviceType.Notifier, DeviceType.Script, DeviceType.Automation, DeviceType.Lock, DeviceType.MediaPlayer, DeviceType.AlarmPanel, DeviceType.Control, DeviceType.Presence, DeviceType.Weather, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.Container, DeviceType.Image, DeviceType.PetFeeder, DeviceType.Dishwasher;
|
|
70962
|
+
DeviceType.Cover, DeviceType.Valve, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.Camera, DeviceType.Hub, DeviceType.Switch, DeviceType.Siren, DeviceType.Light, DeviceType.Fan, DeviceType.Sensor, DeviceType.Thermostat, DeviceType.Climate, DeviceType.Button, DeviceType.EventEmitter, DeviceType.Update, DeviceType.Generic, DeviceType.Notifier, DeviceType.Script, DeviceType.Automation, DeviceType.Lock, DeviceType.MediaPlayer, DeviceType.AlarmPanel, DeviceType.Control, DeviceType.Presence, DeviceType.Weather, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.Container, DeviceType.Image, DeviceType.PetFeeder, DeviceType.Dishwasher, DeviceType.Washer, DeviceType.Dryer;
|
|
70608
70963
|
new Set(Object.values(DeviceType));
|
|
70609
70964
|
Object.freeze({
|
|
70610
70965
|
"accessories.getStatus": {
|
|
@@ -73827,6 +74182,13 @@ Object.freeze({
|
|
|
73827
74182
|
access: "view",
|
|
73828
74183
|
role: "viewer"
|
|
73829
74184
|
},
|
|
74185
|
+
"groupActive.getStatus": {
|
|
74186
|
+
capName: "group-active",
|
|
74187
|
+
capScope: "device",
|
|
74188
|
+
addonId: null,
|
|
74189
|
+
access: "view",
|
|
74190
|
+
role: "viewer"
|
|
74191
|
+
},
|
|
73830
74192
|
"groupCommands.getStatus": {
|
|
73831
74193
|
capName: "group-commands",
|
|
73832
74194
|
capScope: "device",
|
|
@@ -74793,6 +75155,13 @@ Object.freeze({
|
|
|
74793
75155
|
access: "create",
|
|
74794
75156
|
role: "admin"
|
|
74795
75157
|
},
|
|
75158
|
+
"meter.getStatus": {
|
|
75159
|
+
capName: "meter",
|
|
75160
|
+
capScope: "device",
|
|
75161
|
+
addonId: null,
|
|
75162
|
+
access: "view",
|
|
75163
|
+
role: "viewer"
|
|
75164
|
+
},
|
|
74796
75165
|
"metricsProvider.collectSnapshot": {
|
|
74797
75166
|
capName: "metrics-provider",
|
|
74798
75167
|
capScope: "system",
|
|
@@ -82891,7 +83260,39 @@ var APPLIANCE_CAP_VOCABULARY = {
|
|
|
82891
83260
|
phrase: t("When {device} finishes", "Quando {device} finisce"),
|
|
82892
83261
|
icon: "square"
|
|
82893
83262
|
}
|
|
82894
|
-
}
|
|
83263
|
+
},
|
|
83264
|
+
overrides: { byType: {
|
|
83265
|
+
[DeviceType.Washer]: {
|
|
83266
|
+
state: { running: {
|
|
83267
|
+
whenTrue: t("When the washing machine starts", "Quando la lavatrice inizia"),
|
|
83268
|
+
whenFalse: t("When the washing machine has finished", "Quando la lavatrice ha finito")
|
|
83269
|
+
} },
|
|
83270
|
+
events: {
|
|
83271
|
+
onStarted: { phrase: t("When the washing machine starts", "Quando la lavatrice inizia") },
|
|
83272
|
+
onFinished: { phrase: t("When the washing machine has finished", "Quando la lavatrice ha finito") }
|
|
83273
|
+
}
|
|
83274
|
+
},
|
|
83275
|
+
[DeviceType.Dryer]: {
|
|
83276
|
+
state: { running: {
|
|
83277
|
+
whenTrue: t("When the dryer starts", "Quando l'asciugatrice inizia"),
|
|
83278
|
+
whenFalse: t("When the dryer has finished", "Quando l'asciugatrice ha finito")
|
|
83279
|
+
} },
|
|
83280
|
+
events: {
|
|
83281
|
+
onStarted: { phrase: t("When the dryer starts", "Quando l'asciugatrice inizia") },
|
|
83282
|
+
onFinished: { phrase: t("When the dryer has finished", "Quando l'asciugatrice ha finito") }
|
|
83283
|
+
}
|
|
83284
|
+
},
|
|
83285
|
+
[DeviceType.Dishwasher]: {
|
|
83286
|
+
state: { running: {
|
|
83287
|
+
whenTrue: t("When the dishwasher starts", "Quando la lavastoviglie inizia"),
|
|
83288
|
+
whenFalse: t("When the dishwasher has finished", "Quando la lavastoviglie ha finito")
|
|
83289
|
+
} },
|
|
83290
|
+
events: {
|
|
83291
|
+
onStarted: { phrase: t("When the dishwasher starts", "Quando la lavastoviglie inizia") },
|
|
83292
|
+
onFinished: { phrase: t("When the dishwasher has finished", "Quando la lavastoviglie ha finito") }
|
|
83293
|
+
}
|
|
83294
|
+
}
|
|
83295
|
+
} }
|
|
82895
83296
|
},
|
|
82896
83297
|
update: {
|
|
82897
83298
|
scope: "device",
|
|
@@ -83663,6 +84064,10 @@ var SENSOR_CAP_VOCABULARY = {
|
|
|
83663
84064
|
icon: "flame"
|
|
83664
84065
|
}]
|
|
83665
84066
|
},
|
|
84067
|
+
"group-active": {
|
|
84068
|
+
scope: "device",
|
|
84069
|
+
noun: t("Group state", "Stato del gruppo")
|
|
84070
|
+
},
|
|
83666
84071
|
"group-commands": {
|
|
83667
84072
|
scope: "device",
|
|
83668
84073
|
noun: t("Group command", "Comando di gruppo")
|
|
@@ -83719,6 +84124,17 @@ var SENSOR_CAP_VOCABULARY = {
|
|
|
83719
84124
|
}],
|
|
83720
84125
|
events: { onMotionChanged: { notOperatorFacing: "the `detected` state trigger phrases both edges, from the mirror that survives a dropped event (D49)" } }
|
|
83721
84126
|
},
|
|
84127
|
+
meter: {
|
|
84128
|
+
scope: "device",
|
|
84129
|
+
noun: t("Meter", "Contatore"),
|
|
84130
|
+
state: [{
|
|
84131
|
+
kind: "numeric",
|
|
84132
|
+
field: "value",
|
|
84133
|
+
quantity: t("the total", "il totale"),
|
|
84134
|
+
label: t("Total", "Totale"),
|
|
84135
|
+
icon: "gauge"
|
|
84136
|
+
}]
|
|
84137
|
+
},
|
|
83722
84138
|
"numeric-sensor": {
|
|
83723
84139
|
scope: "device",
|
|
83724
84140
|
noun: t("Sensor", "Sensore"),
|
|
@@ -84191,8 +84607,47 @@ function projectAction(cap, action) {
|
|
|
84191
84607
|
};
|
|
84192
84608
|
}
|
|
84193
84609
|
Object.entries(CAP_VOCABULARY_BY_NAME).flatMap(([cap, entry]) => entry.scope === "device" ? (entry.actions ?? []).map((a) => projectAction(cap, a)) : []);
|
|
84194
|
-
DeviceType.Camera, DeviceType.Hub, DeviceType.Light, DeviceType.Siren, DeviceType.Switch, DeviceType.Sensor, DeviceType.Thermostat, DeviceType.Climate, DeviceType.Button, DeviceType.EventEmitter, DeviceType.Update, DeviceType.Generic, DeviceType.Notifier, DeviceType.Script, DeviceType.Automation, DeviceType.Lock, DeviceType.Cover, DeviceType.Valve, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.Fan, DeviceType.MediaPlayer, DeviceType.AlarmPanel, DeviceType.Control, DeviceType.Presence, DeviceType.Weather, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.Container, DeviceType.Image, DeviceType.PetFeeder, DeviceType.Dishwasher;
|
|
84610
|
+
DeviceType.Camera, DeviceType.Hub, DeviceType.Light, DeviceType.Siren, DeviceType.Switch, DeviceType.Sensor, DeviceType.Thermostat, DeviceType.Climate, DeviceType.Button, DeviceType.EventEmitter, DeviceType.Update, DeviceType.Generic, DeviceType.Notifier, DeviceType.Script, DeviceType.Automation, DeviceType.Lock, DeviceType.Cover, DeviceType.Valve, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.Fan, DeviceType.MediaPlayer, DeviceType.AlarmPanel, DeviceType.Control, DeviceType.Presence, DeviceType.Weather, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.Container, DeviceType.Image, DeviceType.PetFeeder, DeviceType.Dishwasher, DeviceType.Washer, DeviceType.Dryer;
|
|
84195
84611
|
DeviceFeature.BatteryOperated;
|
|
84612
|
+
DeviceType.Washer, DeviceType.Dryer, DeviceType.Dishwasher;
|
|
84613
|
+
var HA_AS = "a power sensor (device_class power). Home Assistant has no laundry domain. running-state stays unexported until a null reading can be published as unavailable.";
|
|
84614
|
+
var HOMEKIT_REASON = "HomeKit has no laundry-appliance service. The export tab would pair an accessory with nothing on it: running-state is withheld until a null reading can be unavailable, and power is not a HomeKit service this export honours.";
|
|
84615
|
+
var ALEXA_REASON = "Alexa has no laundry category in this export, and neither power nor running has an Alexa interface.";
|
|
84616
|
+
var GOOGLE_REASON = "Google WASHER, DRYER and DISHWASHER require RunCycle. A power threshold is not that trait, and this export does not publish RunCycle.";
|
|
84617
|
+
var MATTER_REASON = "No Matter export is built. The closest device types are Laundry Washer (0x0073) and Laundry Dryer (0x0074); a power threshold is not the Laundry Washer Mode cluster.";
|
|
84618
|
+
function withheld(reason) {
|
|
84619
|
+
return {
|
|
84620
|
+
[DeviceType.Washer]: {
|
|
84621
|
+
exported: false,
|
|
84622
|
+
reason
|
|
84623
|
+
},
|
|
84624
|
+
[DeviceType.Dryer]: {
|
|
84625
|
+
exported: false,
|
|
84626
|
+
reason
|
|
84627
|
+
},
|
|
84628
|
+
[DeviceType.Dishwasher]: {
|
|
84629
|
+
exported: false,
|
|
84630
|
+
reason
|
|
84631
|
+
}
|
|
84632
|
+
};
|
|
84633
|
+
}
|
|
84634
|
+
function offered(received) {
|
|
84635
|
+
return {
|
|
84636
|
+
[DeviceType.Washer]: {
|
|
84637
|
+
exported: true,
|
|
84638
|
+
as: received
|
|
84639
|
+
},
|
|
84640
|
+
[DeviceType.Dryer]: {
|
|
84641
|
+
exported: true,
|
|
84642
|
+
as: received
|
|
84643
|
+
},
|
|
84644
|
+
[DeviceType.Dishwasher]: {
|
|
84645
|
+
exported: true,
|
|
84646
|
+
as: received
|
|
84647
|
+
}
|
|
84648
|
+
};
|
|
84649
|
+
}
|
|
84650
|
+
offered(HA_AS), withheld(HOMEKIT_REASON), withheld(ALEXA_REASON), withheld(GOOGLE_REASON), withheld(MATTER_REASON);
|
|
84196
84651
|
Object.freeze({
|
|
84197
84652
|
"accessories.getStatus": [{
|
|
84198
84653
|
name: "deviceId",
|
|
@@ -85159,6 +85614,11 @@ Object.freeze({
|
|
|
85159
85614
|
form: "single",
|
|
85160
85615
|
optional: false
|
|
85161
85616
|
}],
|
|
85617
|
+
"groupActive.getStatus": [{
|
|
85618
|
+
name: "deviceId",
|
|
85619
|
+
form: "single",
|
|
85620
|
+
optional: false
|
|
85621
|
+
}],
|
|
85162
85622
|
"groupCommands.getStatus": [{
|
|
85163
85623
|
name: "deviceId",
|
|
85164
85624
|
form: "single",
|
|
@@ -85369,6 +85829,11 @@ Object.freeze({
|
|
|
85369
85829
|
form: "single",
|
|
85370
85830
|
optional: false
|
|
85371
85831
|
}],
|
|
85832
|
+
"meter.getStatus": [{
|
|
85833
|
+
name: "deviceId",
|
|
85834
|
+
form: "single",
|
|
85835
|
+
optional: false
|
|
85836
|
+
}],
|
|
85372
85837
|
"motion.getStatus": [{
|
|
85373
85838
|
name: "deviceId",
|
|
85374
85839
|
form: "single",
|
|
@@ -86976,7 +87441,6 @@ Object.freeze({
|
|
|
86976
87441
|
"network-access": "ingress",
|
|
86977
87442
|
"smtp-provider": "email"
|
|
86978
87443
|
});
|
|
86979
|
-
DeviceType.Camera;
|
|
86980
87444
|
/**
|
|
86981
87445
|
* A saved Customize assignment (D936). The schema is the type: callers use
|
|
86982
87446
|
* `z.infer`, they do not restate the shape.
|