Prompt Hermes Agent Sysadmin Build

Instead of sharing the code, I am sharing a prompt that should help you build it. This is the build prompt that Hermes gave me when I asked it what it would tell another Hermes to build out a sysadmin agent. Your systems are not my systems, so code written for my TrueNAS, UniFi & Proxmox setup would need rewriting anyway. This prompt will let you learn how to build and customize it to your needs.

What it builds

  • A monitoring suite that runs on a schedule, writes one report per run, and only alerts you when something needs a human.
  • Instructed to be read-only everywhere. It never fixes anything. It reports, and you do the fixing.
  • The checks are plain scripts. Once they are built, they run on a schedule with no LLM and no tokens.

How to use it

  1. Paste the whole thing into Hermes as its brief.
  2. Build one system at a time over several sessions, and verify each one before adding the next.

My advice is to start small: one system, one read-only token, one check, and build from there.

Before you paste it

  • Review it like code. A prompt is a set of instructions an agent will act on with your credentials.
  • The prompt is a request. The prompt says read-only, but what actually keeps you safe is only handing it read-only tokens. Do not give it admin credentials if you want to keep things read only.
  • Know what goes to the model. If you build with a remote model such as OpenRouter like I do, the API responses Hermes reads during the build go to that provider. Hermes holds on to the credentials such as an API key within itself but If you are asking to review the logs of your firewall those logs are being sent to that model.
  • The traps come from my lab. The examples mention specific gear (UniFi, Z-Wave, Docker). The lessons are general, so keep them even if you do not run that gear.

The prompt

Copy everything in the block below.

# Build prompt: a read-only infrastructure monitoring suite with Hermes

Last updated: 2026-10-18. Deliberately estate-neutral - no hostnames, addresses
or credentials - so it can be handed to any agent on any estate.

Hand this whole file to Hermes. It is written to be pasted, not read as
documentation - the agent should treat it as its brief.

**Paste it as-is.** There is nothing to fill in: the agent interviews you
first and asks only for what it needs. Describe your systems, never your
secrets: anything you type into the chat goes to the model. It will take
several sessions, not one. Build one system at a time and verify each before
adding the next; a suite half-built against unverified assumptions is worse
than no suite, because it will tell you things are fine when it has never once
checked.

---

## Start by interviewing me

Do not build anything until you have asked me these, one at a time, and
written my answers into the inventory file (and the knowledge base, if I name
one):

1. What must never be touched, on any system?
2. Where does durable documentation live (a wiki, notes dir, or repo path),
   and is there anything you must not write there?
3. In plain words, what do I want to be told about, and what should stay
   quiet? (e.g. "Tell me when a disk is filling, a backup did not run, a
   service died, or a device is hot - and stay quiet when everything is fine.")
4. What do I care about backing up, and where do the backups land?

Then ask me for ONE system to start with: its name, address, product and
version, and what kind of read-only access I can give you. Ask for the
credential TYPE only. Never ask for, accept, or repeat a secret value: tell me
the variable name and file, and I will add it to `.env` myself.

Build and verify that one system completely before asking for the next. At the
start of every later session, read the inventory and knowledge base first, and
only ask me what is missing.

---

# The brief

Build a read-only monitoring suite that runs on this host on a schedule,
publishes one report per run, and alerts only when something needs a human.

Write it so that in six months, when an alert fires, you can tell me **what is
wrong and why** without me having to go and look.

## Hard rules - non-negotiable

**1. Read-only, everywhere, forever.** Every credential you ask for must be
read-only. Ask for it to be read-only; then *verify* it is, rather than assuming
(the APIs often expose a permissions endpoint - use it, and make the check
report a CRIT if it ever finds write privileges, because a monitor that silently
acquires write access is worth shouting about). Do that on *every*
credential-bearing check where the API makes it possible, and expect the early
ones to be uneven - name the credentials you have NOT proved read-only rather
than leaving that implied. Never remediate anything. Report
findings; I perform every fix myself. A finding is never an invitation to act.

**2. Alert on the cause, not the symptom.** "Disk is 92% full" is a symptom with
no cause attached. Wherever possible detect *why*: a log directory that nothing
rotates, an old version still installed, a job that stopped producing output, a
configuration pointing at a superseded version. A cause-level finding tells me
what to change; a symptom tells me to go and investigate.

**3. Every alarm must be proved to fire.** Before you claim a check works, make
it alert - deliberately, with bad input - and show me the output. A check you
have never seen fire is a guess, and a guess that reports OK is actively
harmful. If you cannot prove an alarm path, say so rather than shipping it.

**4. Absent is not zero.** A metric that could not be collected must be *omitted*,
never written as 0 - "0 failures" and "could not read failures" are opposite
meanings. A finding that could not be evaluated is a CRIT, or an explicit
`UNAVAILABLE`, never silence.

**5. A monitor that stops running must not look like a monitor that found
nothing.** The worst failure mode in this whole project. Make failed checks
visible as findings. Declare the list of checks in code rather than discovering
them by probing for files, so a rename cannot silently disable one.

**6. Exit codes mean "did it run", not "did it find anything".** `0` = the run
completed, read the findings from the report. Non-zero = it genuinely failed.
Never let severity be the exit code - it collides with argument-parser usage
codes (a typo'd flag and a CRIT become indistinguishable) and it makes "found a
warning" look to the scheduler like "the monitoring crashed".

**7. One machine-readable document per run; text is a rendering of it.** Keep a
stable contract (`findings`, `metrics`) and mark anything you might change as
non-contract (`details`). One system should appear **once** even when two checks
cover it.

**8. Stdlib only if you can.** No dependency management is a feature.

**9. Credentials live in `.env` files I edit myself, outside version control.**
Write a `.gitignore` that excludes them *before* anything else. Never print a
secret value into a report, a log, or the chat. When you need a credential,
tell me the variable name and the file, and I will add the value myself. If I
ever paste a secret into the chat anyway, do not repeat it, and tell me to
rotate it.

**10. Tell me what you are deliberately NOT checking, and why.** The gaps matter
as much as the coverage. A check that silently covers 80% of a thing is worse
than one that says "I cannot see X from this API". That includes knowing which
of my devices produce no logs at all: where a box ships nothing to the log
store, a counter or a report is the only witness to its events, and you should
say so rather than let me assume the logs are there.

**11. Read the knowledge base before you write, and keep it current.** If the
store named in the interview exists, its index is the first thing you read:
the recon you are about to do has usually been done before, and re-deriving it
wastes a session. When you finish a check, or learn a fact about a system, it
belongs there - one page per system, one per mechanism, plus that store's own
append-only log, in whatever structure it already uses. The division of labour
matters: this brief and the skills carry *portable rules* that should be reusable
on another estate, while the knowledge base carries *this* estate's facts, gaps
and history. Do not copy a lesson into both, or they drift and a future reader
cannot tell which is authoritative.

## When I authorise a change

Rule 1 is the default forever. When I explicitly ask for a repair or a
migration, that authorisation covers exactly that request - do it and nothing
adjacent; a finding is still never an invitation. Then:

- **Prove the rollback path before the first destructive step.** Back up what
  you replace to a durable file, and restore from it once so you know the
  restore works. Backups record identifiers that may not survive a restore -
  re-read live state afterwards; do not trust the backup's metadata.
- **Measure the replacement with the old path switched off.** When both write
  the same field names, output presence proves nothing about which path
  produced it. One real case: a replacement parser that produced nothing
  appeared to reach 87.6% coverage - the entire figure was the old path still
  running underneath.
- **Leave the system no worse than you found it.** If the replacement
  measurably regresses, restore the old path and say so plainly. Continuing
  past a regression is how partial failures become outages.
- **Acceptance is not execution.** An API that validates and stores your
  change proves only that it stored it. Prove execution with an artefact only
  the new path can produce - an unconditional canary separates "not running
  at all" from "running but failing on this shape" - and prove it on data
  that arrived *strictly after* the change: records processed before it are
  never retroactively updated, and a sampling window that overlaps the change
  reads success as partial failure.

## How to work

**Recon before writing.** For each system, find out what the API *actually*
exposes. Do not write a check from documentation alone - query the live system
and read the real field names and shapes out of the response. Documentation lies
by omission constantly.

**Build in this order, stopping to verify each stage:**

1. **Inventory** - a declarative file listing systems, thresholds, and what is
   enabled. Adding a system should mean editing this, not editing code.
2. **A shared core** - severity levels, finding/metric builders, the report
   schema, report writing, retention, environment loading, HTTP/SSH helpers, CLI
   scaffolding, and a last-resort exception handler. Write this before any check.
3. **One check, end to end**, as the worked example. Get the text output, the
   JSON output, the exit codes, the disabled-entry behaviour, and the
   missing-credentials behaviour all correct on this one before writing a second.
4. **The runner** - runs every declared check, merges results per system, writes
   the document and the text report, applies retention, prints a short digest
   suitable for a phone.
5. **Tests that prove the alarm paths.** Test the failure modes, not the happy
   path: unreachable host, missing credential, malformed inventory, bad flag,
   and *the alert actually firing*.
6. **Schedule it** and prove delivery end to end, with whatever scheduler you
   have to hand (system cron, systemd timers, the agent runtime's own scheduler).
   Be explicit about whose behaviour "silent when healthy" actually is: the job
   must print nothing on a good day, and the *scheduler* must then send nothing -
   not an empty message, not a "job completed" notice, either of which looks like
   a real alert on a phone. Then prove it stays silent - an alert-only job that
   speaks every day is noise.
7. **Document it** - in the knowledge base the interview named, not in a
   README inside the code directory: every system, every mechanism you built,
   and every known limitation, with that store's index updated in the same pass.
   If you cannot reach the destination, say so and write it where I will see it.

**Verification discipline.** These are the techniques that caught real bugs here:

- Keep a **baseline** of each check's text output. After any refactor, diff
  against it. Volatile values (timestamps, temperatures, ages) will differ, so
  **mask them and diff again** - that separates live drift from a broken
  renderer.
- Feed a **frozen payload** through the renderer before and after a change and
  compare byte-for-byte. This proves a refactor changed nothing, which is much
  stronger than "it looks right".
- Test trend/delta logic **in isolation**, by injecting a fake "previous run"
  and asserting the comparison fires - and equally that it stays quiet when
  nothing changed, when there is no previous run at all, and when a counter has
  moved *backwards* (a reboot, not an improvement). This is easy to get
  silently wrong. Then prove it against reality too: a change-based rule cannot
  be shown to work by one run, so run it twice against the real report store -
  the first establishes the baseline, and only the second can show that an
  unchanged world stays quiet.
- Run each check standalone *and* through the runner. Bugs hide in the
  integration: a renderer that returns a joined string instead of a list prints
  perfectly on its own and one character per line inside the combined report.
- **Sample adversarially.** "The newest N records" on a busy source can be
  minutes of data; sparse, rare, or newly-enabled shapes will be absent and
  your 100% pass will be a lie. Mix spread time windows, targeted queries for
  rare classes, and fixed vectors taken from every reported production
  failure. And test with the engine's real semantics - a prefix-match harness
  hides whole-message-match failures.
- **Never assert the estate's health in a test.** "This host is OK today" goes
  red the day the host legitimately warns, which conflates "the check works"
  with "the box is well" - and someone eventually deletes the inconvenient
  assertion. Assert structure instead: that the check ran, that the finding
  names what it should, and that a row carries the threshold that applied to it.
- **Assert the value IN FORCE, not the value you edited.** Read thresholds back
  through the checker's own loader, the same path the check uses at runtime,
  because a per-entry override can quietly reinstate the number you just changed
  in the default while the file you edited looks perfect.

## The traps

Each of these cost real time here. Read them before writing a check, and add to
the list whenever you hit a new one.

**1. Absent-by-default is not absent.** Before concluding "the API doesn't expose
X", check more than one query shape and more than one endpoint. A field may need
to be *requested*; it may be a nested object rather than a scalar; and - most
importantly - a second, less documented surface may expose it. One real case: a
modern API had no temperature or port data at all, and an earlier version of the
check wrongly reported them as unavailable. The older API had both. **When
something looks unavailable, look harder before saying so.**

**2. Two APIs, two ID spaces.** A modern endpoint may list entities with UUIDs
while an older one references them by legacy ObjectId. Joining them by ID returns
`[]` - no error, no warning, just an empty result that looks like "nothing
configured". Verify that your joins actually match something.

**3. Silent-empty is not an error.** An endpoint can return `0 records` for a
malformed request while returning an error for a nonexistent one. One real case:
a report endpoint silently returned nothing because it wanted **milliseconds**
and was given seconds. If you get an empty list where you expected data, assume
*your request* is wrong before assuming the data is absent.

**4. Sentinels masquerading as values.** `general_temperature: -1` with
`has_temperature: true` means "no reading", not −1 °C. Look for the sentinel and
treat it as absent; print `n/a`, never the sentinel.

**5. Lifetime counters are not live faults.** A link that has dropped 10,000
times since boot, or a port carrying 200,000 accumulated errors, is describing
its history, not its current state. One of those was a desktop whose NIC powers
down when it sleeps; another had gained **one** error between runs. **Alert on
the delta, not the total.**

**6. The peer's capability is unknowable.** A 10G port linked at 1G is the
*correct* state when the far end is 1G - an ISP handoff does exactly this. If the
API has no peer-capability field, "negotiated below rating" is not a fault
signal, and alarming on it is a false positive you will end up disabling.

**7. Placeholder names are not labels.** Devices ship with auto-generated names -
`Port 7`, `SFP+ 2`, `Outlet 5` - and some allow a completely **empty** name. If
you write a "this is undocumented" check, treat those as unnamed, or it will
silently pass on things nobody labelled.

**8. "Not applicable" is not "broken".** A replication target with no tasks of
its own is a *role*, not a fault. Distinguish "nothing configured" from "nothing
working", and never let the first raise the same alarm as the second. The same
three-way split applies to version checks: "there is no upstream release to
compare against" is definitive, "could not reach upstream" is unknown, and only
the second is a finding - a fail-fast path that trips on the first turns a
not-comparable item into a false alarm.

**9. Derived values lie far more often than measurements.** Every genuinely wrong
number in this project was *computed*, while every measurement was sound:

- `uptime_days` calculated as `(now - uptime_seconds) / 86400` treats a *duration*
  as an epoch timestamp → 20,680 days.
- A capacity projection from a slightly negative fill trend → "full in −43,398
  days (1907-12-03)", on a datastore that was 92% empty.

Prefer a direct measurement. When you must derive, sanity-check the range before
you alert on it, and ask what a *negative* or absurd value would mean.

**10. A trend is often the real signal.** For anything noisy, alert on change
rather than on an absolute. A fill-rate projection is useless in absolute terms
but a sudden halving is meaningful; accumulated error counts are history, but new
errors mean a degrading cable. Record the value so the next run can diff it.

**11. One aggregated finding per maintenance category, never one per item.** Nine
warnings for nine unlabelled ports, when the task is "label your ports", is how a
report stops being read. Report the count, list a few, and say how many more. If
you have a trend, include it - "9, down from 15" reads as progress; "9" reads as
an unfixed failure.

**12. Do not hardcode an exception to silence one false positive.** Fix the rule.
Special-casing a single port or host leaves the same bad rule firing on every
other legitimate case, and needs revisiting every time hardware changes. Where a
whole *class* is legitimately in the alarmed state - a device flag that is only
ever populated when something is wrong, or a controller's own status entity -
silence the class by matching the pattern, not by listing the ids you happened to
see today. Keep the silenced ones counted in the report so they stay visible
without being findings, and prove both directions: the by-design case silent, and
a genuine one from the same synthetic run still reported.

**13. Check a fact from both ends.** A backup job reporting `SUCCESS` proves the
source thinks it sent data; it does not prove the data arrived. Where it matters,
verify independently at the destination.

**14. Say when you were wrong.** Several findings in this project were the
check's fault, not the estate's - and the estate owner was right every time he
pushed back. When that happens, fix the rule, correct the documentation that
recorded the wrong claim, and tell him plainly. A monitor that argues with its
operator is worse than useless.

**15. A success label set after a silently-failing step is a guess.** One real
case: a log parser marked every message "classified" while its extraction step
silently did nothing on a new message variant - the label was set
unconditionally after a no-op, and the failure stayed invisible until a human
noticed raw text. Cross-check labels against artefacts (`status=X AND
artefact-missing` is the query to run), and give failure its own visible state:
an "unparsed" marker beats an optimistic default.

**16. No trace at the receiver is a finding about the path.** When "X isn't
working" and the receiver's logs show nothing, the event probably never
arrived. A handler that saw and rejected it leaves a line - learn first what
rejection looks like there (wrong method, disallowed source), because the
*kind* of absence localises the fault. One real case: an automation blamed for
weeks of silence was fine; a firewall rule upstream was dropping the call
before it ever reached the receiver. The missing rejection log was the
evidence.

**17. `.env` is for secrets, not config.** When a value can come from both the
declarative inventory and the secrets environment, the inventory must win by
design. Config that leaks into `.env` gets edited in the wrong file and
silently pins behaviour - one real case: a stale URL variable in the secrets
store overrode the inventory and held three checks on an old API version while
the inventory declared a newer one.

**18. A finding that is always present is indistinguishable from one that never
fires.** The delta rule in trap 5 is not only about numbers - it applies to any
SET a check reports. Six labelled ports sat down permanently on this fabric, so
"labelled port down" was a warning present on every single run, and the operator
read it the way you would read a dead smoke alarm. Report the CHANGE instead:
newly in the state, and newly out of it - a recovery line is worth sending,
because it tells me the fix worked or that something moved.

- **With no baseline, stay silent.** On the first run of such a rule there is
  nothing to compare against, and announcing six ports as "newly down"
  reproduces exactly the noise you are removing. Say what the baseline *is* in
  the report body, and alert on nothing.
- **A baseline is not a metric.** Metrics are numbers; the set of things in a
  state belongs in the non-contract part of the document, which is also where
  the next run reads it back from. A set stored where numbers are expected
  breaks the report write - assert that the document still serialises.
- **Known-off items are configuration, not code.** Some things are in the bad
  state on purpose: spare hardware, a seasonal device, the standby half of an
  HA pair, a cache for something nobody launches. List them in the config,
  matched in BOTH forms (by name and by index, so a rename cannot silently
  un-ignore one), and never alert on them in either direction.
- **Keep counting what you no longer alert on.** The count stays in the report
  body. That is also the mechanism that makes all of this possible: the body is
  for context and may carry OK-level lines, while the phone payload carries only
  what needs a human. Anything recorded at OK level is visible to me and never
  reaches my phone - which is exactly what "tell me, without alerting me"
  requires.
- **An expected item that changes state is not automatically noise.** The
  standby gateway's link coming *up* is worth an OK line: it means a failover
  happened.

**19. Never alert on a TOTAL that includes things you have already declared
legitimate.** Compute the residual and name the parts. One check warned for weeks
that 30GB of docker images was "reclaimable" - 26.7GB of it was the local cache
for workspaces that were enabled and working, and the rest was the rollback
images that the cleanup script protects on purpose. No amount of pruning could
clear it, so the operator ran his cleanup script, saw no change, and reasonably
concluded the script had failed. Worse, the check's own message said "includes
rollback targets, so review before pruning" - that sentence is the defect: it
admits the rule cannot tell intentional from waste. A rule that cannot be made
honest by fixing the estate is not a rule, it is noise. Watch the same shape in
reverse: an item that stops being legitimate (a cached image for a workspace
somebody disabled) must start being reported again, so the code that explains the
total also tells you when the explanation no longer applies.

**20. Accepted is not applied.** A write that returns success may only have been
QUEUED. Changing a threshold on a battery-powered Z-Wave sensor returned HTTP
200 - the driver had accepted the instruction, not the device, which was asleep
and would not take it until it next woke, hours later. The value read back as the
old number in the meantime, and reporting "done" then would have been a guess
presented as a fact. So: know which of your targets are intermittently
reachable, say plainly when a change is pending rather than applied, and make the
follow-up check report EITHER WAY - silence-on-success is right for an alert-only
monitor and exactly wrong for a verification, where "no message" cannot be told
apart from "never ran".

## Acceptance criteria

Before you tell me this is finished:

- Every enabled system has at least one check, and each check runs standalone
  with both human-readable and machine-readable output.
- I have **seen** the alert fire and arrive on my phone. Not "it should work".
- A check that fails, hangs, or cannot read its credentials produces a visible
  finding - never a silent skip and never a crash.
- No secret appears in any report, log, or commit. `.gitignore` came first.
- Killing the run mid-flight leaves no temp files behind (test it).
- There is one document per run, one entry per machine, and retention is applied
  and reported.
- The docs state what is checked, what is deliberately not checked, and every
  known limitation - and they live in the knowledge base named in the
  interview, indexed, rather than in a README beside the code.
- I can add a new system by editing one config file and nothing else.

## Finally

Ask me before deciding anything that changes what I get alerted about, and ask
before touching anything on my systems. Build the properly-considered version
rather than the quick one - I would rather wait for something I can trust than
have something working today that lies to me in a month.
4 Likes

Thanks for sharing your insights into Hermes-Agent. I’ve been running Hermes locally (VPS first and eventually transferred to local VM once I’d gotten comfortable with the framework) since the end of June. It is an INCREDIBLY powerful tool, and very easy to use. I’ve started 5 or six projects using Hermes and some combination of OpenRouter/nvidia API and eventually over to locally-hosted LLMs once Hermes and I got my GPU rig up and running ( 3 3090s is what my home’s local circuit will allow in terms of a 15 AMP circuit). It’s been a rush, between quick and direct access to information I’d have spent hours or more looking up myself, learning how/why a particular piece of code/bash command works as it does, etc. It’s been super fun, and while it is a somewhat contentious topic, locally hosted AI is an INCREDIBLE tool.
Most recent and current project on hand is building a Desktop Robot AI (esp32+LLMs) with full voice, vision, reasoning, and faux personalities. Working with Google Gemma (locally hosted) to design the 3D printed body next.
Seems I may have gone on a bit of a rant there, but yeah, it’s fun! :smiley:

1 Like

I’ve spent a few hundred hours on OpenClaw and Hermes Agent. A few things I’d suggest:

  1. Use git for version control. This gives you a way to review changes and go back to past checkpoints if something goes wrong. I push that to a self-hosted forgejo instance.

  2. Use the hermes desktop app. The UI shown in your video was the solution before the desktop app existed. Generally more polish and user friendliness.

  3. Be wary of skills. Skills help with repeat work, but they can be overfit to specific tasks and conflict with other skills. As the number of skills grows, managing skills can become a significant chore. Similar comment about plugins.

  4. Profiles are still clunky. Hermes agent is really one-player with additional profiles bolted on. For example, profiles don’t share skills or sessions,so you may wind up with split brain problems. They started pushing for a bot-based solution but it isn’t there yet.

  5. Working on mobile. You can work from your phone via an app like telegram. That’s good for chat only and you can get away with it for some technical tasks, but adding the telegram layer reduces stability. I did setup a self-hosted matrix/element server to not expose data to a third party but that also added stability issues. I played with mobile early on but now I don’t use it much and it will stay that way until a native stable mobile solution is out.

I have not really bothered with the Desktop App because I prefer to limit what software I have on my system especially things build with Electron.

The rich text chat window in the Desktop app over the CLI in the browser alone makes it worth it for me to use. I also like being able to toggle between different hermes-agent instances and gateways from a single interface. I haven’t looked at resource utilization for the desktop app because it has been pretty stable the last few months.

If HA is your only agent, I’d suggest giving it a try - I’m sure you’ll notice edges, gotchas, and tradeoffs that I didn’t. Alternatively, if you have multiple agents or multiple concurrent sessions and prefer the CLI, try herdr.

I might give it a try, but it’s less about resource hogging and more about security. If the Hermes desktop app get’s compromised it’s running on my system that has session tokens, ssh keys, etc… I will have to look into how it’s sandboxed. To keep good security posture I really try to limit what apps I have installed on any system I use.

1 Like

read only tokens are the only thing that stops a rogue agent from messing with ssh keys (or any creds) but you still need to lock down the host itself (firewall and limited user) just in case the app is compromised

With respect to open router on your video here do you use a business account for OpenRouter so you only use the US-based data centers, or are you allowing general routing?

I ask because I have a hook for FreeCAD to do some 3d printing but anything related to it just eats my tokens. I also have these on a VM that I can silo down using Unifi to use DeepSeek or alternative models in the event we want to use a open-weight model that does not train on your data or prompts.

I have it as a personal account so just general routing.

1 Like