madewithlaya

Catalog / Tools & apps

0086GitHub

A public test of Laya on a home energy system: fast enough, but a tariff EMS still wins

One simulated Swedish villa, four controllers on the same minutes. Laya with a safety clip cut the bill from 985 to 530 SEK at p95 179 ms; a plain tariff EMS reached 385 SEK.

Open source ↗ github.comcostfree, localtimep95 179 ms / decision
frahlg/laya-ems-testREADME ↗
# A test of Laya on a house

Laya does not write a paragraph. You give it the situation and the answers it is allowed to pick. It returns the pick and a probability, in one pass, on the machine in the house.

We wanted to know if that is useful in a home energy system. The ordinary job is when to charge the car, when to use the battery, and how to stay under the fuse. The job we hoped for is the messy minute: a charger that vanishes, a meter that disagrees with the devices, a register that freezes while the sun moves. Those are the cases that turn into a long list of special rules.

This repository is that test. One simulated Swedish villa. Four controllers on the same minutes. The record of the day is below, and the lab notes are in [docs/EMS_FEASIBILITY.md](docs/EMS_FEASIBILITY.md).

## What happened

| Controller | Bill | 15-min peak | Car at 07:00 | Decision time |
|---|---:|---:|---:|---:|
| Naive charger | 985 SEK | 11.04 kW | 100% | under 1 ms |
| Laya, then a safety clip | 530 SEK | 6.25 kW | 100% | p95 179 ms |
| Tariff EMS | 385 SEK | 4.66 kW | 80% | under 1 ms |
| Mathematical plan | 258 SEK | 2.95 kW | 80% | 158 ms, once |

The tariff EMS is the better controller. Laya is fast enough for a one-minute loop, and the fuse holds. It is useful against a charger that has no plan. It is not a replacement for a short program that knows the prices, and it did not read the fuzzy faults well enough to trust it with them.

## The house

A 16 A villa. The fuse is 11.04 kW. On the roof, 10 kWp of PV. In the garage, a 10 kWh battery that can move 5 kW, and an EV with a 60 kWh pack and an 11 kW charger. The car comes home at 17:30 with 35% charge and should leave at 07:00 with 80%. Export is paid at 80% of the spot price. The grid fee we care about is 81 SEK for each kW of 

Also filed under Tools & apps

  1. 0005

    laya-mlx plays Snake at 60 decisions per second

    介绍比Jev快50倍,在你设备上跑的laya-mlx! 只在你的设备上占用最高1G内存 Laya是一个开源的类似于Jev的,基于文本输出概率的分类系统 我将其移植到MLX,并且做了一些性能优化! 视频中就是这个模型在我的本地M3Max上玩贪吃蛇 这个模型能够以每秒决策60次的速度玩贪吃蛇! https://t.co/31KGUiNunb

    @mizorewww · Tools & apps · free, local · 60 decisions/s

  2. 0112

    Laya on Axera AX650 and AX8850 edge NPUs, under 70 ms

    AXERA-TECH's conversion of all three Laya checkpoints for its edge AI chips, reported at latency under 70 ms per decision on AX650/AX8850.

    AXERA-TECH · Tools & apps · free, on-device · < 70 ms on AX650 / AX8850

  3. 0099

    laya-mcp (PerryLink): a warm sidecar that fixes Laya's silent truncation and constant noul

    MCP server plus HTTP sidecar: token-budget preflight that reports what would be cut, a persisted calibration store, structured errors, and a noul fix (P(true) 0.5 → 1.0).

    @PerryLink · Tools & apps · free, local

  4. 0097

    Gomoku against Laya-MLX: you play black, the model picks white's move from six candidates

    Local 15x15 Gomoku on Apple Silicon. Rules in Python, board in the browser, every AI move one real Laya choice over up to six candidates, probabilities shown. No Gomoku training.

    smile-magic · Tools & apps · free, local