publish

A local publishing command for openEHR specification components. It builds an HTML preview from the specification source files.

In plain words
What is it for?
Previewing a whole component or a selected specification and reporting the generated HTML location and build problems.
Why use it?
It lets developers inspect the rendered document and publishing warnings before committing to a release or deploying anything.

Command

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add commands/openehr/ai-plugins/publish
Clone the repo
git clone --depth 1 https://github.com/openEHR/ai-plugins
Per session 19 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 479 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00019 $0.00479
Opus 5 $0.00010 $0.00239
Sonnet 5 $0.00004 $0.00096
Haiku 4.5 $0.00002 $0.00048

Measured 2d ago against content hash 9ec05c8027be, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

publish scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

plugins/openehr-specs/commands/publish.md · 37 lines

What it actually says

Produce a local HTML preview of an openEHR specification component using the shared publishing toolchain in specifications-AA_GLOBAL. This is the publish step described in the openehr-specs:authoring skill — this command is the action wrapper. It builds a local preview only; it does not tag, commit, or deploy a release (that is the governance skill / release process).

Arguments: $ARGUMENTS — the component abbreviation (e.g. RM, BASE, AM) and optionally a single spec id to limit the build.

Do the following:

  1. Locate the publisher. Confirm a sibling specifications-AA_GLOBAL checkout exists next to the component repo (the parent directory should contain both specifications-AA_GLOBAL/ and specifications-<component>/). If not, report what is missing and stop.
  2. Run from the parent directory containing the specifications-* repos. Prefer the script, fall back to Docker:
    ./specifications-AA_GLOBAL/bin/spec_publish.sh -f -v $ARGUMENTS
    # or:
    docker run -u $(id -u):$(id -g) -v "$(pwd):/documents/" openehr/asciidoctor development $ARGUMENTS
    
  3. Surface the result — report the generated HTML output location and any Asciidoctor warnings/errors (unresolved attributes, missing includes, missing images) verbatim, since those are exactly what a pre-publish check should catch.
  4. If the build fails, summarise the first actionable error and suggest the relevant skill (authoring for include/attribute issues, xref-auditor agent for cross-reference failures).

Do not pass release flags (-r -t -q -l Release-N.N.N) — releasing is a governed process; use the governance skill for that.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2d ago First seen · 37 lines · 19 tokens per session scan A 9ec05c8027be

Subscribe to this mod's changes

publish is a command published in the GitHub repository openEHR/ai-plugins (3 stars, last pushed 2mo ago), licensed Apache-2.0. It adds 19 tokens to every session and 479 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.