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.
npx agentmods add skills/hermeticormus/libreembed-claude-code/safety-critical-patternsnpx skills add HermeticOrmus/LibreEmbed-Claude-Code --skill safety-critical-patternsgit clone --depth 1 https://github.com/HermeticOrmus/LibreEmbed-Claude-CodeWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/hermeticormus/libreembed-claude-code/safety-critical-patterns)<a href="https://agentmods.dev/skills/hermeticormus/libreembed-claude-code/safety-critical-patterns"><img src="https://agentmods.dev/badge/skills/hermeticormus/libreembed-claude-code/safety-critical-patterns.svg" alt="Measured on agentmods" height="20"></a>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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00000 | $0.01445 |
| Opus 5 | $0.00000 | $0.00723 |
| Sonnet 5 | $0.00000 | $0.00289 |
| Haiku 4.5 | $0.00000 | $0.00145 |
Grade A, and why
safety-critical-patterns 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 6d 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.
How it starts
The opening of the file, as written. The whole thing — 197 lines — stays where its author put it; the contents beside it link to each section on GitHub.
safety-critical-patterns
Knowledge Base
MISRA C compliance and safety-critical firmware patterns.
Pattern 1: MISRA C Compliant Type Annotations
MISRA mandates explicit types. Use <stdint.h> types throughout.
/* Non-compliant (implicit types): */
int i;
unsigned char flags;
/* MISRA compliant: */
#include <stdint.h>
#include <stdbool.h>
int32_t i;
uint8_t flags;
bool enable;
/* Rule 7.1: Octal constants */
/* VIOLATION: */
uint8_t val = 010; /* Octal 8, not decimal 10 */
/* COMPLIANT: */
uint8_t val = 0x08U;
/* Rule 7.2: Unsigned constants must have U suffix */
/* VIOLATION: */
uint32_t x = 100;
/* COMPLIANT: */
uint32_t x = 100U;
Pattern 2: Single-Exit Function Pattern (Rule 15.5)
MISRA 15.5: a function shall have a single point of exit.
/* NON-COMPLIANT: multiple returns */
int32_t process(uint8_t *buf, uint32_t len)
{
if (buf == NULL) { return -1; }
if (len == 0U) { return -2; }
/* process */
return 0;
}
/* COMPLIANT: single exit */
int32_t process(uint8_t *buf, uint32_t len)
{
int32_t result = 0;
if (buf == NULL) {
result = -1;
} else if (len == 0U) {
result = -2;
} else {
/* process */
result = 0;
}
return result;
}
This is advisory in MISRA 2012 (was required in MISRA 2004), but required for DO-178C DAL-A.
Pattern 3: MISRA Suppression Comments
When a violation is justified, document it with a suppression comment and deviation record.
/* MISRA C:2012 Rule 11.5 Deviation:
Reason: CMSIS HAL requires void* for peripheral handle cast.
Risk: Low — type verified by HAL layer.
Reviewed by: J.Smith, 2024-03-15, ref: DEV-2024-011 */
/*lint -e9087 */ /* PC-lint suppression */
void *handle = (void *)&hspi1; /* PRQA S 0306 */ /* Polyspace suppression */
/*lint +e9087 */
Deviation records must be maintained in a deviation log linked to each suppression.
Pattern 4: RAM Test (March-C Algorithm)
March-C tests SRAM integrity at startup (required for IEC 61508 SIL 2+).
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.
- 6d ago First seen · 197 lines · 0 tokens per session scan A 1d024ad6c418
safety-critical-patterns is a skill published in the GitHub repository HermeticOrmus/LibreEmbed-Claude-Code (44 stars, last pushed 3mo ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 1,445 tokens. 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-30.
Other skills, from other repositories
new-cpp-lint
Create a new C++ lint rule, test it, run it across the codebase, and selectively apply fixes. Usage - /new-cpp-lint.
expert-rmt5
ESP-IDF v5.x RMT5 API expert for LED protocols, encoders, and multi-channel control. Use when working with RMT peripheral programming, LED strip control, or migrating from RMT4 to RMT5.
fix-int
Fix integer type definitions for specified platform. Researches correct primitive type mappings and applies fixes to platform-specific int headers.
opengis-skills
Use when AI coding assistant needs GIS/CAD/C#/AI/IoT/3D domain expertise for 73+ open-source projects. One-stop skill index with tag-based search and on-demand loading for GDAL, GeoServer, QGIS, PostGIS, JTS, CesiumJS, FreeCAD, OpenSCAD, OCCT, NPOI, SqlSugar, Furion, Dify, SuperSplat, Go and more.
qt-cpp-review
Qt6/C++ deep code review for Serial Studio. Use when asked to "review", "audit", "check", "look over", or "sanity check" C++ — or before committing. Runs the repo linter (scripts/code-verify.py) as Phase 1, then six parallel read-only analysis agents covering Qt model contracts, ownership/lifecycle, thread-safety +…
cpp-compiler-flags
C++ compiler/linker flag guidance for Serial Studio's build (GCC, Clang, AppleClang, MSVC cl.exe, clang-cl, MinGW, IntelLLVM). Use when reading, changing, or reasoning about the cmake flag modules (Optimization/Hardening/Sanitizers/MiMalloc), tuning -O/-march/LTO/PGO, adding a per-toolchain branch, debugging a flag…