perf: server-side aggregate sensors and client-side optimizations#152
Open
flatline-84 wants to merge 3 commits into
Open
perf: server-side aggregate sensors and client-side optimizations#152flatline-84 wants to merge 3 commits into
flatline-84 wants to merge 3 commits into
Conversation
flatline-84
commented
Jun 9, 2026
| "type": "bind" | ||
| } | ||
| ], | ||
| // "mounts": [ |
Author
There was a problem hiding this comment.
Not sure what this folder is for?
flatline-84
commented
Jun 9, 2026
| # Composants essentiels (remplace default_config sans go2rtc) | ||
| automation: !include automations.yaml | ||
| script: !include scripts.yaml | ||
| # automation: !include automations.yaml |
Author
There was a problem hiding this comment.
Errors booting HA up if these are enabled, since the files don't exist
| # Start Home Assistant | ||
| dev: | ||
| @echo "📄 Loading environment..." | ||
| @if [ ! -e config/custom_components ]; then \ |
Author
There was a problem hiding this comment.
This allows LD to be present as an integration in the new HA setup
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Linus Dashboard is great but I find that my tablet struggles with it. Part of it is all my devices, part of it is the tablet is not very good. Hoping to make LD a little quicker. Also did some dev changes since it was hard to get this repo initialized and ready to work in.
sensorplatform creates server-side aggregate sensors per domain/floor, reducing home view template evaluations from ~60 to ~3Changes
Server-side aggregate sensors
aggregate.py: constants and pure computation functions (active states, icons, colors)sensor.py: diagnostic sensors, event-driven with 100ms debounce, hidden from default UIFrontend
AggregateChipuses server-side sensor when available (state_attr(...)instead of inlining 100 entity IDs), falls back gracefully if sensor doesn't existnow()fromgetLastChangedTemplate— was forcing allrelative_time()cards to re-evaluate every minutePromise.all()indexOf()in comparator with pre-builtMapexposedDomainIds.some(...)inner-loop calls with a pre-computedSetObject.keys(DEVICE_CLASSES).includes()with a module-levelSetentity_idarrays to AggregateChip and UnavailableChip for faster Mushroom subscriptionsPerformance
Test plan
Uh there was no real test plan. I put it in my personal HA with ~2000 entities / ~135 devices and it seemed a little faster? Probably a bit of placebo but I expect this to be a first pass for performance improves