HEART Embedded Systems logoHEART

Documentation

Every manual for HEART, in one place: how to use HEART Hub, how to build a HEART into a product, how to test and rate it, and how to run your own site. Each is also available as Markdown.

Understanding HEART

The important ideas in sixteen short sections, in plain words, below on this page.

Quick start

Five short paths: pick what you want to do, and be done in minutes.

HEART Hub owner's manual

Watch, change, ask AI and share, step by step with screenshots.

Templates manual

Starter code in 17 languages and platforms, and how to choose one.

Understanding HEART

The important ideas, in sixteen short sections
  1. The problem HEART solves
  2. What a HEART is
  3. Three principles
  4. The brain can live anywhere
  5. How a HEART speaks
  6. Fault codes everyone understands
  7. Small to start, room to grow
  8. Autonomy Levels: how much a product does on its own
  9. The Valve: privacy built into the data
  10. Every signal, declared once
  11. The model proposes, the HEART decides
  12. A person must really be there
  13. Never in the safety chain
  14. A switch that can take the AI away
  15. Proving it, honestly
  16. Three layers without delay

The important ideas behind HEART, in sixteen short sections. No code, and nothing to install. Each section ends with where to read more.


1. The problem HEART solves

AI is arriving in products one integration at a time. Each team picks its own model provider, its own prompts and its own way of failing, so two products from the same company may share nothing. And no common question can be put to an arbitrary product: are you healthy, what can you do, what may you share, and who approved what you just did?

Logs and dashboards collect signals for people to read, but the product itself does not act on them. The protocols that exist work at other layers: the Model Context Protocol gives models tools, Agent2Agent lets agents hand work to each other, and the W3C Web of Things describes what a device offers. None defines how any system knows itself, looks after itself, and proves what it disclosed. HEART does.

Read more: the standard, Part 1: Basics.

2. What a HEART is

A HEART is a small, standard part that lives inside a product, such as a thermostat, a camera, a pump station, a web shop or a robot. It is always aware of what happens inside its product, and it cares for it.

The name stands for Holistic, Evolving, AI, Reconnaissance and Tending: it sees the whole system, learns safely, can use AI, keeps watch, and acts on what it knows. The words borrow from the body. A Pulse says "I am alive, and this is how I am". An Arrhythmia is an alert. The Valve controls what leaves the product. The inner awareness that knows everything happening inside is called Antaryami, a Sanskrit word for the inner witness.

Read more: Part 1: Basics.

3. Three principles

  1. Awareness belongs inside the product. Intelligence may live in the cloud, but noticing that something is wrong must happen inside, with no network.
  2. Every product speaks one language. HEART reuses existing standards (CloudEvents, JSON Schema, OpenAPI, OAuth 2.0, Problem Details, MQTT) rather than inventing new ones.
  3. Models propose, products decide. Nothing a model says ever acts without passing the same checks as any other request.

An application's intelligence may live in the cloud, but its awareness and care must live within.

4. The brain can live anywhere

A HEART needs no large model built in. Its "brain" can be a small model on the device, a model on a nearby gateway, or a large model in the cloud. A HEART with no brain at all still works.

This is possible because understanding a product's own API is mostly a lookup problem, not a reasoning problem. The list of operations is finite and written down. So a small runtime can serve requests, notice faults and raise alerts with rules and lookup alone. A model helps with messy wording and hard diagnosis. Products stay small, need no special chip, and get better on their own when better models are released.

Knowledge lives in the system. Rules keep it safe. Models make it fluent.

Read more: Core Standard.

5. How a HEART speaks

Every HEART answers the same few questions in the same way, on the same port, 43278, which spells HEART on a telephone keypad (fallback 7685).

QuestionWhere to askWho may ask
Who are you?The Card, at /.well-known/heart-card.jsonAnyone
How are you now?The Pulse, at /heart/v1/pulse: healthy, degraded or failingAnyone
What is wrong?The alerts, at /heart/v1/arrhythmiasAnyone sees the codes; the owner sees more

Every message is a standard CloudEvent, so existing tools can route it unchanged. If a product's Pulse stops arriving for three of its intervals, everyone watching treats it as unknown: a Flatline. The full API has 117 operations, but a small product needs only a handful.

Read more: API Standard, Part 4: Connections.

6. Fault codes everyone understands

Since 1996, every car sold in the United States reports faults with standard OBD-II codes, so P0300 means "engine misfire" on any car. HEART does the same for any product, with readable codes of the form area.problem, such as storage.full, power.battery-low or sensors.drift.

There are 11 areas (system, power, connectivity, storage, performance, software, ai, sensors, actuators, data, security) holding 64 standard codes. Makers add their own under their own domain name, so codes never clash, and a code never changes its meaning once published. An alert can carry two codes: what is seen, and why. A dashboard watching 500 products of different makes can count every storage.full without knowing a single brand.

Inside a message a code is written bare ("code": "storage.full"). In logs, tickets, manuals and searches it is written HEART storage.full, so anyone can tell which list it comes from. Each standard code also has a short fixed number, its H-number, for small screens, blinking lights and phone calls: H-04002 is storage.full (area 04, code 002). The name stays the main form, and maker codes have no H-number. Every code has its own page, with likely causes, fixes and what the HEART does by itself: look one up at /system-code, such as /system-code/H-04002. Things that simply happen, such as system.started, are event types, not faults.

Read more: Part 3: Information Model.

7. Small to start, room to grow

A standard for every product must fit the smallest one. So it has three Feature Sets, each including the one before:

Feature SetAddsSuits
BasicCard, Pulse, alerts, noticing and telling a person, privacyAny product
ConnectedEvents, questions, subscriptions, receipts of what was sharedMost applications
FullCommands, approvals, learning, and control of the product's own autonomySelf-healing systems

Everything else (updates, schedules, fleets, AI, lifecycle and more) is an optional module a product lists in its Card. One thing is required at every level: Tending. Even a Basic product must notice when its main job stops, raise an alert, explain it in plain words, and tell a person, with no network. A product that only reports is monitored, not tended.

Read more: Track 1: Basic.

8. Autonomy Levels: how much a product does on its own

"Has AI" says nothing about what a product will do by itself. Driving had the same problem until the six SAE levels gave everyone one scale. HEART does the same for any product. When something goes wrong, four jobs must be done: notice it, understand why, decide what to do, and do it.

LevelNameWho does what
A0UnawareA person does everything
A1AwareThe product notices; a person does the rest
A2ExplainsIt notices and explains the likely cause; a person decides
A3SuggestsIt proposes a fix; a person approves; it carries it out
A4Fixes known problemsIt follows rules ("Playbooks") a person adopted in advance
A5Fixes new problemsIt works out fixes itself, within limits a person set

A1 to A4 need no AI model and no network. Three rules hold at every level: Stop always works at once; only a person can raise a level; and a higher level never means less safety. Higher is not "better", only more automatic: a web service might be A5, a medical pump A2.

Read more: Part 2: Autonomy Levels.

9. The Valve: privacy built into the data

In HEART, privacy is not a policy document. It is a label on every piece of data, in four levels:

public โ†’ internal โ†’ private โ†’ never-share

The Valve checks everything that leaves the product against these labels, and keeps a receipt of what left, so the owner can prove what was shared. Data marked never-share, such as a Wi-Fi password, never leaves the chip, not even to the owner's own AI model. A good rule follows: the best way to keep a secret on a device is not to put it there. A birdhouse camera, for example, never stores its location at all.

Read more: API Standard, privacy.

10. Every signal, declared once

A product is full of signals: temperatures, speeds, currents, switch positions, counters. A HEART that knows them can notice problems early and give a model the facts it needs, but it could also leak one, or change one it should never touch.

So every signal is declared once, in a signal table: its unit, its normal range, where it is read from (a pin, a register, a firmware variable), its privacy level, and three flags: writable, physical (it moves, heats or switches something in the real world) and safety (it is part of a safety function, so the HEART may only read it). A signal not in the table is invisible. A tool drafts the table from files engineers already have, carefully: nothing is writable by default, and a person must review and seal it before the HEART will start.

Read more: Signal tables.

11. The model proposes, the HEART decides

When its own rules run out, a HEART may ask a model for help. It sends the fault and a summary of the signals, never raw private data. The model answers with a Proposal: what to change, to what value, the effect to expect, and how to undo it. A Proposal that cannot be checked or undone is refused.

The Proposal then passes the same gate as any request. It may run on its own only if the owner listed that change for the AI in advance, inside an envelope (a minimum, a maximum, a largest step, a daily count and a cooldown). Even then it runs as a Trial, in small steps, watched, and undone automatically if it does not help. A fix that worked can become a Playbook, but only once a person adopts it. Next time, the product handles it as a reflex, in milliseconds, with no network. Over time it needs its brain less. That is the Evolving in HEART.

Read more: Track 3: Advanced, Core Standard.

12. A person must really be there

The most dangerous attack on a system that lets AI act needs no bug at all: an AI agent holding a person's login looks exactly like the person, and could approve its own proposals. The rule that stops it applies far beyond HEART: a token says which account is calling, not who is there.

So any step that must involve a person needs proof of presence, tied to exactly what they approve: a passkey, a confirmation on a registered phone, or a button on the device itself. Every change to who may do what is treated as dangerous, and needs approval too. A physical change asked for by an AI always waits for a person. And Stop always works, at once, with no approval and no network.

Read more: Part 6: Human Control and Safety, the security advisory.

13. Never in the safety chain

Physical safety comes before everything. A HEART stays out of the safety chain and out of fast control loops, and never bypasses an interlock.

LayerRun byThe HEART's role
SafetyA certified safety systemNone. It may read, at most.
Real-time controlThe existing controllerNone in the loop. It may read values.
SupervisionOperatorsIt advises, and acts only with guards and approval
MaintenanceEngineersIts main value: it explains, predicts and gathers evidence

This is why, in the example products, the EV charger's certified controller, the pump station's PLC and the 3D printer's firmware keep full control, and a pacemaker's software is never touched. Following HEART does not certify anything as safe: a product's own safety standards still apply.

Read more: From simulator to real device.

14. A switch that can take the AI away

Trust in a model must be earned by watching what it does. A model can be tricked or poisoned, and a new version may behave in ways nobody has seen. So an owner, or anyone responsible for many devices, needs a way to take the brain away, even from a device they cannot reach.

A message saying "stop" can be blocked or lost. So HEART turns the switch around: a device may use a brain only while it holds a short lease, signed by a Command Center that also holds the model keys and signs every answer. The switch is pulled by not renewing. Within one lease period (5 minutes by default), every device it covers becomes brainless, even if no message reaches it. Brainless is a safe, defined state: the device loses its advice, never its heart. It keeps noticing, alerting and following the rules a person adopted. And the switch never stops the machine: a car's brakes belong to its certified controller, not to its AI.

Read more: Command Center profile.

15. Proving it, honestly

A claim such as "this thermostat is HEART A4" is worthless if nobody checks it. HEART-Rating runs the standard's tests against a product and gives one number from 0 to 10, with caps so that one critical failure can never be hidden by many passes: any critical failure caps the rating at 3.9, labelled Unsafe. One rule outweighs the rest: a product may claim only what it has passed.

What exists today, honestly:

Not yet: nothing has run on physical hardware, and a real model has so far only advised an owner on HEART Hub. The threat analysis was done by the standard's author, so an independent security review is still needed.

Read more: HEART-Rating, Part 9: Testing and Certification.

16. Three layers without delay

HEART has one rule for time: nothing fast ever waits for anything slow.

A product with a HEART can have three layers, each slower than the one before it. None waits on a slower one.

LayerWhereWorks inIts job
HEARTInside the productMillisecondsNotice, alert, follow the rules a person adopted, stop
HEART HubA website, such as heartcortex.aiSecondsShow health to the owner, email when a device goes quiet, carry the owner's signed changes
Hub AI (optional)A model, called with the owner's own API keysSeconds to a minuteExplain and recommend, when the owner asks

Ten ways keep that promise:

  1. Noticing happens inside, with rules, and never asks the network.
  2. A Playbook a person adopted runs as a reflex, in milliseconds.
  3. Stop works at once, with no approval and no network.
  4. Reporting runs beside the HEART's own work, with a short time limit. If the Hub is slow or away, the HEART carries on.
  5. The Hub answers a report from what it holds. It never calls a model on the way.
  6. Watching for silence is a separate sweep. No report waits for it.
  7. Hub AI runs only when the owner asks, and it only recommends. Its answer is used when it comes; nothing waits for it.
  8. A late decision is refused. An owner's signed decision more than 300 seconds old never acts, so it cannot act on a situation that has changed.
  9. The brain works on a lease. When the lease lapses, the device becomes brainless at once. It is never stuck waiting for a model.
  10. Nobody waits on a guess. While the owner makes a change, the device reports every 2 seconds (the faster channel). A device that sleeps says how long, so its silence is not mistaken for a fault.

How long things take:

WhatTimeHow we know
A fault noticed inside the product0.4 to 1.6 s (an out-of-memory kill, a failing health check); 2.9 to 3.3 s for a restart loop, which needs several restartsMeasured: Docker with a HEART, real containers, on two machines
StopAt once, on the deviceBy design: no network, no approval
An owner's change reaching the deviceAbout 2 s after the owner confirms it, and its result on the page in about 4 s, plus the network. Without the faster channel: up to one reporting interval (30 s by default).Measured in HEART Hub's tests with a test clock: 1.3 s and 3.3 s
A silent device shown as "Not heard from"After three reporting intervals, at least 90 s; for a sleeping device, after its sleep and a graceBy design
Its owner emailedWithin 5 minutes after thatBy design: the sweep runs every 5 minutes
A Hub AI answerSeconds to a minuteDepends on the model. Nothing waits for it.
A brain cut by its Command CenterWithin one lease period, 5 minutes by defaultBy design

Read more: API Standard, design principles, HEART Hub, Sections 5.5 and 7, HEART for IoT.

All manuals

Jump to: Get started Use HEART Hub IoT devices Build a HEART into your product Test and rate Run your own monitor site Docker with a HEART From simulator to real device Product guides Demo simulators Reference

Get started

New to HEART? Start here.
Understanding HEART The important ideas in sixteen short sections: what a HEART is, fault codes, Autonomy Levels, privacy, how AI is kept in check, the safety boundary, the brain switch, what is proven so far, and why nothing fast waits for anything slow.
Quick start Five paths, 5 to 20 minutes each: watch the live demos, give a program a HEART, choose a template, pick a reading track, or try Docker with a HEART.
Start here: the three reading tracks Four questions tell you which parts of the standard your product needs, in order, and where to stop.
Live demos Nine simulated products with a HEART, running now: watch faults being noticed and resolved.

Use HEART Hub

Watch your devices from anywhere, change their settings, and ask an AI about them.
HEART Hub: the owner's manual Every step, with screenshots: sign in, register, read the device page, change a setting with an emailed code, connect Claude, Ask AI, approvals, sharing and troubleshooting.
HEART Hub The rules behind it: what a device sends, how the site signs requests, what the device checks, and the privacy rules.

IoT devices

Small connected devices: report health to HEART Hub in a few lines, over HTTPS or MQTT.
HEART for IoT What a small device sends: the light report, alerts, up to 64 figures, sleeping without looking dead, changes from the owner, MQTT, what it can claim, and privacy.
IoT examples for HEART Hub A sensor in about 30 lines on MicroPython or the Arduino core for the ESP32, and a bridge from MQTT to HEART Hub, with their tests.

Build a HEART into your product

Starter code in 17 languages and platforms, and the reference runtime.
HEART Templates 17 templates, from Python and Go to bare-metal C, assembly and WebAssembly: what each does, how they are versioned and tested, and how to choose.
HEART Full starter for ESP32 The first Full starter: signals, a cloud model through a gateway, HEART Hub, and physical commands only after a press of the device's button.
HEART Core (Rust) The reference runtime in Rust: the Core library, the heartd daemon, the Gateway, WebAssembly, examples and results.
Configuring heartd Every setting of heartd: the system, the API, approvals, the brain lease, the Gateway and HEART Hub.

Test and rate

Check a product against the standard.
HEART-Rating A score from 0 to 10 for how closely a system follows the standard, with caps so one critical failure is never hidden. For testers and for the rating service.
Conformance statement The conformance suite, and which parts of the standard the reference Core meets.
Testing HEART Core How the reference Core is tested: unit, property and end-to-end tests.

Run your own monitor site

The same open code as heartcortex.ai, on your own machine or domain.
Do not wish to use heartcortex.ai/monitor? Run your own HEART Hub server Step by step: start it with one command on your own computer, sign in, register a device, add HTTPS, keep it running and back it up.
HEART Hub site Deploy the HEART Hub site on Cloudflare Workers with DynamoDB: tables, keys, email, Turnstile, signing keys, AI models and the Command Center.

Docker with a HEART

Docker Engine given a HEART in two real ways, and tested with real containers.
Docker Engine with a HEART: built in, or as a sidecar (experimental) What it adds, what it notices with no network and no AI, its privacy rules, and how to run it.
Docker with a HEART on heartcortex.ai: screenshots A live run on heartcortex.ai: Claude recommends more CPU, the owner changes it, and Docker applies it in 23 seconds.
Replicating the Docker HEART experiment, step by step Every step to rebuild and test it yourself, with the exact versions, commands and results.

From simulator to real device

For illustration only: the hardware, code, install steps and owner experience of each example as a real product.
From simulator to real device Start here: the three ways a HEART is placed (inside, beside a controller, or outside), what every real device needs, and what to expect.
3D printer: on a real device The device we assume, where its HEART runs, the code to change, build and install, the factory, the owner's view and bench tests.
Birdhouse camera: on a real device The device we assume, where its HEART runs, the code to change, build and install, the factory, the owner's view and bench tests.
Dog tracking collar: on a real device The device we assume, where its HEART runs, the code to change, build and install, the factory, the owner's view and bench tests.
EV charger: on a real device The device we assume, where its HEART runs, the code to change, build and install, the factory, the owner's view and bench tests.
Greenhouse irrigation: on a real device The device we assume, where its HEART runs, the code to change, build and install, the factory, the owner's view and bench tests.
Online shop server: on a real system The device we assume, where its HEART runs, the code to change, build and install, the factory, the owner's view and bench tests.
Pacemaker: on a real system The device we assume, where its HEART runs, the code to change, build and install, the factory, the owner's view and bench tests.
Smart thermostat: on a real device The device we assume, where its HEART runs, the code to change, build and install, the factory, the owner's view and bench tests.
Water pump station: on a real device The device we assume, where its HEART runs, the code to change, build and install, the factory, the owner's view and bench tests.

Product guides

Whole products worked through, from what to watch to which faults matter.
Guide 9: A HEART-Embedded 3D printer How HEART fits this product: its main job, what its HEART watches, its faults and what it may change.
Guide 1: A HEART-Embedded air-conditioner controller How HEART fits this product: its main job, what its HEART watches, its faults and what it may change.
Guide 3: A HEART-Embedded birdhouse camera How HEART fits this product: its main job, what its HEART watches, its faults and what it may change.
Guide 11: A HEART-Embedded dog tracking collar How HEART fits this product: its main job, what its HEART watches, its faults and what it may change.
Guide 8: A HEART-Embedded EV charger How HEART fits this product: its main job, what its HEART watches, its faults and what it may change.
Guide 6: A HEART-Embedded greenhouse irrigation system How HEART fits this product: its main job, what its HEART watches, its faults and what it may change.
Guide 10: A HEART-Embedded online shop server How HEART fits this product: its main job, what its HEART watches, its faults and what it may change.
Guide 4: A HEART-Embedded pacemaker system How HEART fits this product: its main job, what its HEART watches, its faults and what it may change.
Guide 2: HEART-Embedded photo editing software How HEART fits this product: its main job, what its HEART watches, its faults and what it may change.
Guide 5: A HEART-Embedded smart thermostat How HEART fits this product: its main job, what its HEART watches, its faults and what it may change.
Guide 7: A HEART-Embedded water pump station How HEART fits this product: its main job, what its HEART watches, its faults and what it may change.

Demo simulators

Each demo is one Python file you can run on your own computer, with its own end-to-end test.
Birdhouse camera simulator: a HEART-embedded system you can run and watch Run it, stage its faults, and watch its HEART notice them. Also live under Live demos.
Dog tracking collar simulator: a HEART-embedded system you can run and watch Run it, stage its faults, and watch its HEART notice them. Also live under Live demos.
EV charger simulator: a HEART-embedded system you can run and watch Run it, stage its faults, and watch its HEART notice them. Also live under Live demos.
Greenhouse irrigation simulator: a HEART-embedded system you can run and watch Run it, stage its faults, and watch its HEART notice them. Also live under Live demos.
Online shop server simulator: a HEART that fixes known problems Run it, stage its faults, and watch its HEART notice them. Also live under Live demos.
Pacemaker simulator: a HEART-embedded system you can run and watch Run it, stage its faults, and watch its HEART notice them. Also live under Live demos.
3D printer simulator: a HEART-embedded system you can run and watch Run it, stage its faults, and watch its HEART notice them. Also live under Live demos.
Water pump station simulator: a HEART-embedded system you can run and watch Run it, stage its faults, and watch its HEART notice them. Also live under Live demos.
Smart thermostat simulator: a HEART-embedded system you can run, watch and ask to change things Run it, stage its faults, and watch its HEART notice them. Also live under Live demos.

Reference

The standard itself, and what machines read.
The standard Every document: the API and Core standards, the nine parts, profiles, advisories and design notes.
OpenAPI description All 117 operations of the HEART API, in YAML.
Problem types The meaning of every HEART error type.
Fault codes Every standard fault code with its H-number, such as HEART storage.full (H-04002): likely causes, how to fix it, and what the HEART does by itself.
Downloads Every template, all templates in one zip, and the Rust HEART Core, in every version.
Contributing How to contribute: issues, changes and tests.
Security Policy How to report a security problem.