rust-invariants

rust-invariants is a skill for Claude Code, Codex from KalarisLabs/Skill-Doctor. It costs 48 tokens per session (380 once invoked), scanned A, original, Apache-2.0.

A list of non-negotiable rules for the Skill Doctor product, including offline operation, repeatable output, additive findings, secret handling, and package boundaries.

In plain words
What is it for?
Use it when changing scans, scoring, command-line options, networking, model or MCP paths, features, or other core behavior.
Why use it?
It helps prevent changes that silently weaken safety, determinism, or the product's default behavior.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it when changing scans, scoring, command-line options, networking, model or MCP paths, features, or other core behavior.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/kalarislabs/skill-doctor/rust-invariants
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.

Any agent
npx skills add KalarisLabs/Skill-Doctor --skill rust-invariants
Clone the repo
git clone --depth 1 https://github.com/KalarisLabs/Skill-Doctor

Made for: Claude Code, Codex.

Wrote 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.

agentmods badge for rust-invariants

README.md
[![agentmods](https://agentmods.dev/badge/skills/kalarislabs/skill-doctor/rust-invariants/github.svg)](https://agentmods.dev/skills/kalarislabs/skill-doctor/rust-invariants)
Your own site
<a href="https://agentmods.dev/skills/kalarislabs/skill-doctor/rust-invariants"><img src="https://agentmods.dev/badge/skills/kalarislabs/skill-doctor/rust-invariants/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for rust-invariants

Your own site · 80×15
<a href="https://agentmods.dev/skills/kalarislabs/skill-doctor/rust-invariants"><img src="https://agentmods.dev/badge/skills/kalarislabs/skill-doctor/rust-invariants.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 48 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 380 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
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.1 $0.00048 $0.00380
Opus 5.5 $0.00019 $0.00152
Sonnet 5.5 $0.00010 $0.00076
Haiku 4.5 $0.00005 $0.00038

Measured 1mo ago against content hash fc2cab476182, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

rust-invariants 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 1mo 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.

skills/rust-invariants/SKILL.md · 28 lines

What it actually says

Invariants — stop and redesign if a change breaks one

  1. Rust-only product runtime. npm is a binary installer. Node never scans.
  2. No mandatory LLM. Default is --offline --deterministic. L1 needs zero network, zero key.
  3. Additive-only. L2 may add findings or raise confidence. L2 may never delete or downgrade L1.
  4. Determinism. Two --deterministic runs → identical JSON/SARIF bytes (sorted maps, pinned time, sorted walks).
  5. Rules compiled at build time in skill-doctor-rules. Never per scan.
  6. SD-11. Any bytes sent to any model pass through skill-doctor-neutralize first.
  7. Secrets. Emit environment key names only, never values.
  8. CLI-first. TUI is feature tui plus an explicit flag. Never default.
  9. Four frozen contributions. Do not invent SD-12 or a fifth claim.

Tests that must exist

  • cargo tree -e features -p skill-doctor has no LLM crate on default features.
  • Table test: L1 CRITICAL survives an L2 verdict of "benign".
  • Two deterministic JSON reports, equal SHA-256.
  • Neutralize is not a no-op on bidi / zero-width / homoglyph fixtures.

CI grep (keep in ci.yml)

Fail the job if default-path sources match forbidden OpenAI or Anthropic SDK imports.

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. 1mo ago First seen · 28 lines · 48 tokens per session scan A fc2cab476182

Subscribe to this mod's changes

rust-invariants is a skill published in the GitHub repository KalarisLabs/Skill-Doctor (13 stars, last pushed yesterday), licensed Apache-2.0. It adds 48 tokens to every session and 380 once invoked, about $0.0002 per session on Opus 5.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-09-11.