validate-accuracy

A release check that independently verifies electrical calculator results against National Electrical Code (NEC) tables and formulas.

In plain words
What is it for?
Re-deriving expected values, comparing them with calculator output, checking NEC source data, and cross-checking a scenario with another tool.
Why use it?
It catches wrong calculations that ordinary tests may miss when the code and tests share the same misunderstanding. A failing check blocks the change from being merged.

Skill for Claude CodeCodex

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 skills/jared833/claude-code-hooks/validate-accuracy
Any agent
npx skills add jared833/claude-code-hooks --skill validate-accuracy
Clone the repo
git clone --depth 1 https://github.com/jared833/claude-code-hooks

Made for: Claude Code, Codex.

Per session 77 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,077 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.00077 $0.01077
Opus 5 $0.00039 $0.00539
Sonnet 5 $0.00015 $0.00215
Haiku 4.5 $0.00008 $0.00108

Measured yesterday against content hash 4d3bc77532b2, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

validate-accuracy 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 yesterday.

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/validate-accuracy/SKILL.md · 98 lines

How it starts

The opening of the file, as written. The whole thing — 98 lines — stays where its author put it; the contents beside it link to each section on GitHub.

validate-accuracy

Validate site/src/lib/calculators/<slug>.js against the NEC source it claims to implement. This is the accuracy check: a tool that fails here does not merge.

Core principle: do not trust the test file. The same model that wrote the calculator wrote its tests, so a shared misunderstanding passes tests while being wrong. Derivations here must come from the NEC data and formula directly.

Procedure

1. Fresh derivation (before reading the test file)

Open docs/specs/<slug>-spec.md and every site/src/data/nec-tables/*.json the calculator imports. Choose at least 3 scenarios, covering every code path/branch of the calculator (each conditional rule, for example NEC 240.4(B) round-up versus 240.4(D) small-conductor caps, gets at least one scenario). For each, re-derive the expected outputs by hand from the table values and the formula, writing out the arithmetic. Do NOT read <slug>.test.js expectations until your derivations are committed to the worksheet.

2. Compare against actual output

Run the real calculator on each scenario, with a scratch node invocation:

cd site && node -e "import('./src/lib/calculators/<slug>.js').then(m => console.log(JSON.stringify(m.calculate({...}))))"

Any mismatch between derived and actual = FAIL. (Rounding: match the precision the tool displays; a discrepancy beyond display precision is a mismatch.)

3. Source-data spot check

For each NEC data JSON the tool uses, verify at least 3 entries against the published NEC values cited in the file's header comment (edition, table number). This catches transcription errors, the most likely failure mode for table-driven tools. A file whose header lacks the edition + table citation also fails.

4. External cross-check

Cross-check at least 1 scenario against a named independent third-party calculator (WebFetch). Name the specific tool and paste its URL in the worksheet; if the first one is unreachable, use a different named tool rather than skipping the step.

Read the full file on GitHub · 98 lines

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. yesterday First seen · 98 lines · 77 tokens per session scan A 4d3bc77532b2

Subscribe to this mod's changes

validate-accuracy is a skill published in the GitHub repository jared833/claude-code-hooks (2 stars, last pushed 13d ago), licensed MIT. It adds 77 tokens to every session and 1,077 once invoked, about $0.0004 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.

Related

Other skills, from other repositories

systematic-debugging

Use when encountering any bug, test failure, or unexpected behavior, before proposing fixes.

obra/superpowers · 21 tokens

chat-pet-sprite-creation

Use when creating or changing VS Code chat pet sprite art, sprite sheets, state animations, eye treatments, Stable/Insiders variants, or pet transitions under src/vs/workbench/contrib/chat/browser/widget/media/chatPet.

microsoft/vscode · 53 tokens

cpu-profile-analysis

Analyze V8/Chrome CPU profiles (.cpuprofile) and DevTools trace files (Trace-.json). Use when: profiling performance, investigating slow functions, comparing code paths, finding bottlenecks, analyzing timeToRequest, understanding call trees from sampling profiler data, analyzing layout/paint/rendering, investigating…

microsoft/vscode · 71 tokens

babysit-pr

Babysit a GitHub pull request after creation by continuously polling review comments, CI checks/workflow runs, and mergeability state until the PR is merged/closed or user help is required. Diagnose failures, retry likely flaky failures up to 3 times, auto-fix/push branch-related issues when appropriate, and keep…

openai/codex · 114 tokens

imagegen

Generate or edit raster images when the task benefits from AI-created bitmap visuals such as photos, illustrations, textures, sprites, mockups, or transparent-background cutouts. Use when Codex should create a brand-new image, transform an existing image, or derive visual variants from references, and the output…

openai/codex · 113 tokens

agent-host-chat-contributions

Build and review cross-cutting agent-host chat behavior through lifecycle contributions. Use when adding turn lifecycle side effects, prompt or context injection, restored-history transformation, protocol-action observation, or when reviewing changes that add code to AgentSideEffects or AgentService.

microsoft/vscode · 56 tokens