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/w1ne/kernelcad-web/kernelcad-fieldsnpx skills add w1ne/kernelCAD-web --skill kernelcad-fieldsgit clone --depth 1 https://github.com/w1ne/kernelCAD-webWhat 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 | $0.00052 | $0.01704 |
| Opus 5 | $0.00026 | $0.00852 |
| Sonnet 5 | $0.00010 | $0.00341 |
| Haiku 4.5 | $0.00005 | $0.00170 |
Grade A, and why
kernelcad-fields 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.
How it starts
The opening of the file, as written. The whole thing — 103 lines — stays where its author put it; the contents beside it link to each section on GitHub.
kernelCAD — signed-distance fields
Compose signed-distance fields (sdf.sphere/.box/.cylinder/.torus), blend them smoothly with sdf.smoothBlend, then call sdf.materialize(field, { resolution }) to obtain a standard Shape that flows through booleans / fillets / exports.
const a = sdf.box([60, 40, 6]); // base plate, axis-aligned, centred at origin
const b = sdf.cylinder(8, 30); // pin, axis +Z, centred at origin
const field = sdf.smoothBlend(a, b, 3); // 3 mm smooth fillet at the junction
return sdf.materialize(field, { resolution: 30 });
sdf primitive math (mm; centred at origin in local frame)
| Field | Returns |
|---|---|
sdf.sphere(r) |
SdfField (kind 'sphere') |
sdf.box([sx, sy, sz]) |
SdfField (kind 'box', axis-aligned, centred) |
sdf.cylinder(r, h) |
SdfField (kind 'cylinder', axis +Z, centred) |
sdf.torus(R, r) |
SdfField (kind 'torus', ring axis +Z, centred) |
sdf.smoothBlend(a, b, k) |
SdfField (kind 'smoothBlend', polynomial smin with blend radius k mm) |
sdf.materialize(field, { resolution? }) |
Shape (kind sdfMaterialize; default resolution 30, clamped to [10, 200]) |
sdf.bind(name, field) |
binds a field on the session so evaluate_sdf can sample it later (side effect; returns void) |
Composition rules (slice 1)
- No
field.translate(...). Slice-1 primitives live in their local frame. To position the result, compose primitives whose origins align (e.g. two coaxial spheres), callsdf.materialize, then translate the resultingShape(.translate(x, y, z)). smoothBlendis union-only. Smooth-intersect / smooth-difference are deferred to slice 2+.materializeis synchronous. It runs marching-cubes on the host (Node + browser) and synchronously sews via OCCT WASM. No async surface.
Resulting Shape limitations
- The output is polyhedral — thousands of triangular planar faces, not
analytic surfaces. Canonical face refs (
'top','bottom', ...) do not apply (sphere / box face semantics are lost at materialize). fillet({ face: 'top' })-style canonical face calls returnfeature.face-ref.not-applicable; use inline FaceQuery / EdgeQuery if edge-feature scoping is needed.- Downstream
fillet/chamferon materialized SDF edges is supported in principle but quality is poor and OOM risk is real at high resolution; surface asfeature.kernel-failed. - Booleans (
union/subtract/intersect) do work — standard OCCT BREP booleans operate on the polyhedral solid.
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.
- 2d ago First seen · 103 lines · 52 tokens per session scan A 661432f8e0fd
kernelcad-fields is a skill published in the GitHub repository w1ne/kernelCAD-web (17 stars, last pushed 4d ago), licensed MIT. It adds 52 tokens to every session and 1,704 once invoked, about $0.0003 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-30.
Other skills, from other repositories
simplecadapi
Thin SimpleCAD SDK reference skill focused on the public API surface, core types, and current modeling workflows.
opengis-skills
Use when AI coding assistant needs GIS/CAD/C#/AI/IoT/3D domain expertise for 72+ 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.
cad
Use when doing parametric 3D modeling, 2D drafting, geometric kernel development, BIM/IFC processing, PCB design, or AutoCAD .NET development. Index of 19 skills: FreeCAD, OpenSCAD, OCCT, CadQuery, KiCad, SolveSpace, QCAD, xBIM, Clipper2, TongWen and more.
cadquery-modeling
Generate CAD models with CadQuery using an adaptive CAD Compiler workflow: plan-mode skill constraint handoff, focused iteration scopes, fail-first challenge review, compact review packets, real-product reference fidelity, visual/functional audits, source-first repair, and STEP/STL export. Use for CadQuery, CQ, 建模…
aieng-cad-authoring
Active MCP-first CAD authoring skill for AIENG Workbench. Use when the user asks to create, design, draft, model, or iteratively build CAD geometry through the active cad. MCP tools. Do not use for solver/result review, schema/library implementation, or editing legacy IR plans.
aieng-cad-cae-copilot
MCP-first evidence workflow for AIENG CAD/CAE setup, solver preflight, approval-gated solver execution, and result extraction. Use when the user asks to inspect CAE readiness, patch setup, prepare/run CalculiX, or report stress/displacement evidence.