Agent stack build plans · № 6 · 5 of 6
The prompts
Five stages, pasted into Hermes itself, in order. Days apart, not minutes.
These go straight into a hermes session (stage 3’s output
becomes the cron job). They assume setup is done:
token in place, gateway running, approvals.mode: manual. Note the
prompts name the real tools — ha_list_entities, not the
list_entities that circulates in AI answers.
1 · Map the house
Call ha_list_entities and build me a house map: every entity grouped by
room, with its exact entity_id, domain, and the human name we'd use for it
in conversation ("the reading lamp" -> light.living_room_lamp_2). Where a
name is ambiguous or an entity looks orphaned, ask me — do not guess.
Then create a skill called house-map (use skill_manage) whose SKILL.md
contains the final table, plus one hard rule at the top: never call
ha_call_service on an entity_id that is not in this map — ask me instead.
Finish by telling me which domains you'd suggest for watch_domains and
which chatty entities belong in ignore_entities, based on what you saw.
2 · Write the house rules into memory
I'm going to dictate our house rules. Use the memory tool to store them — terse, one line each, because MEMORY.md caps at 2,200 characters and I want room left for patterns you'll learn later. Confirm the character count after. Rules to start with (I'll add more): - Lamps on within 10 minutes of sunset on weekdays; silently. - Never touch light.living_room_lamp_2 (the reading lamp) unless asked. - Quiet hours 22:30–07:30: no messages unless it's a security or water issue. - Locks, alarm, and the garage NEVER move without an explicit yes from me. - If heating is on and a window sensor reads open for 15+ min, tell me. - When an action matches an established pattern, act silently; when it's novel, message me first.
3 · Build the pattern distiller (the learning loop)
Create a cron job with the cronjob tool: every night at 23:30, do this —
1. Use session_search to review today's Home Assistant events and our
conversations.
2. Look for recurring patterns worth remembering: arrival/departure times by
weekday, things repeatedly left on or open, nudges I said yes to, nudges
I ignored (an ignored nudge is a pattern too — stop sending it).
3. Message me on Telegram with at most 3 proposed memory changes, each one
line, with your evidence ("garage left open >60 min on 4 of the last 9
evenings"). Apply only what I approve, via the memory tool.
4. If MEMORY.md is within 200 characters of its cap, propose which existing
line to drop before adding anything.
Never auto-apply. Distill, propose, wait.
4 · Go live, gently
For the next 7 days, run in shadow mode: when an event suggests an action, message me what you WOULD do and why (cite the memory rule or pattern), but only act if I say yes. Keep count. After 7 days, send me a report: which proposed actions I approved every time (candidates for acting silently), which I rejected (delete or fix the rule that produced them), and what the week cost in model calls. We'll promote the reliable ones to act-without-asking one at a time.
5 · Get the household’s eyes on the rules — before they live in memory
You work for the whole household, and so far only I have written rules. Generate house-rules.html: one self-contained page, readable by a non-technical person, with the house map (rooms and plain names, not entity_ids), every current rule from memory, and what you do at each stage of the evening. Then add the twocents MCP server (https://twocents.page/mcp — you can connect any MCP server; add it to your config and restart so the tools load). Call share_page with the full contents of house-rules.html and give me the review link — I'll send it to the rest of the household. They pin notes directly on the page, no login: "never turn off my reading lamp", "the quiet hours should start at 21:30 on school nights". When the notes are in, call get_feedback with the room id, read me each note, and fold the ones I approve into memory — terse, under the cap.
Why stage 5 is not optional
Every rule so far encodes one person’s model of the house. The people the agent will actually annoy are the ones who never saw the config — and they won’t file an issue, they’ll just override the thermostat and quietly resent your robot. A page they can pin a note on is the lowest-friction way to find the reading-lamp rule before it becomes a Tuesday-night argument.