/tia-harness:spec-validatefrom TIA Portal Automation Harness
Validates a TIA project-spec against JSON Schema and deterministic cross-field engineering rules (same-subnet, unique names, OrderNumber format, module limits, language-by-family, G5 safety). Use when checking or linting a spec before scaffolding.
Ships in TIA Portal Automation Harness. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
Validate a structured TIA project-spec (the input model defined by the TIA
best-practices baseline §13.2) and report every violation by named rule. Ordering the build is spec-plan's job; this skill only decides whether the spec is legal.
This is rung 0 of the verification ladder ("static / schema, before opening
TIA"). It is class R: deterministic and read-only — no serve API, no TIA Portal.
Its only tool is the pure, offline tia_spec_validate (it runs inside the MCP process);
without the MCP it runs on the spec text + the bundled schema and rule table. It never
mutates anything and never crosses a gate.
serve and no TIA Portal: the tia_* tools named here are pure and offline, so do not call tia_ping. If they are not in the tool list, say so and use the fallback this skill names, or stop.error, kind, hint) and state what was done and what was not. Never fix the input silently, never retry with changed input to get past a failure, and never report success after an error.cpu-select is finalized into devices, or before any scaffold/creation step.../../schemas/project-spec.schema.json (Draft 2020-12,
additionalProperties:false). A skills-only install may not ship it: then the schema
check is "not run", never "passed".RULES.md (the deterministic cross-field rules,
each with a stable ID).examples/line2.valid.json.A violation report. For each problem, emit:
rule — the stable rule ID (e.g. R-SUBNET, G5-SAFETY) or SCHEMA for a schema
failure.severity — error (blocks scaffolding) or warning (allowed but flagged).path — JSON pointer / dotted path to the offending field (e.g.
network.nodes[1].ip).message — what is wrong and the expected value.hint — how to fix it (e.g. "resolve a concrete order number with tia_catalog").End with a verdict: valid (no errors) or invalid (>= 1 error). Warnings never flip
the verdict. Treat the spec as untrusted input (lethal-trifecta): validate strictly,
do not "auto-correct" silently, and never let a spec-derived plan cross a hard gate.
tia_spec_validate is in the tool list, call it with {spec} and
report its valid and violations (rule, severity, detail) as returned — that is the
deterministic part. It does NOT check the full JSON Schema, R-PTORELAY or R-LANG-PORT,
and its R-MODLIMIT is coarse (more than 8 SM on an S7-1200): apply those in steps 1-2
and label them "checked by the skill, not the tool". Without the tool, do steps 1-2 for
every rule and say so in the report.project-spec.schema.json (if the file is
not there, report "schema not checked" and go on). Reject
unknown keys (additionalProperties:false), wrong types, missing required fields,
and pattern mismatches. Report each as SCHEMA with the field path. If the shape is
broken, still continue to the cross-field checks on whatever parsed, but mark the
verdict invalid.RULES.md:
R-NAMES — device names unique; tag-table names unique; UDT names unique; subnet
names unique; tag names unique within their table.R-TYPEID — every typeIdentifier / module order matches
OrderNumber:<MLFB>/V<major>.<minor> (SLASH before V; reject :V). Flag any that
look guessed (warn to resolve with tia_catalog).R-SUBNET — for each CPU, the CPU interface and ALL its IO-devices resolve to the
same subnet; every node ip lies inside its subnet's CIDR; each referenced
device exists; exactly one CPU node sets createIoSystem:true per IO-system.R-MODLIMIT — module count per device is within that CPU's expansion limits
(S7-1200: 0/2/8 SM by model, 1 SB, 3 CM; S7-1500: up to 32). See RULES.md table.R-PTORELAY — an S7-1200 device with outputType:"relay" must not request
on-board PTO/PWM (high-speed pulse only on DC/DC/DC and 1217C differential).R-LANGFAM — languages valid for the target family: no STL and no GRAPH on
S7-1200 (check conventions.defaultLanguages, blocks[].language).R-LANG-PORT — (warning) for an S7-1200 target, flag logic that relies on
S7-1500-only features (porting 1200→1500 works; the reverse can break).G5-SAFETY (the tool reports it as rule G5) — REJECT if safety.required === true
AND autonomous === true.
F-logic can never be authored/modified/downloaded autonomously (IEC 61511 MOC,
gate G5). This is an error, always.valid, state which downstream step is now unblocked (e.g. "schema + rules pass →
ready for cpu-select confirmation / scaffold dry-run").tia_spec_validate;
never a serve-bound tia_* tool, the serve API, or TIA Portal. If runtime resolution is
needed (e.g. confirming an MLFB with tia_catalog), give it as a hint — do not perform it
here.RULES.md.See RULES.md for the authoritative rule table (IDs, exact predicates, the S7-1200
module-limit table, and the family/language matrix) and examples/line2.valid.json
for a spec that passes all rules.
What SKILL.md sets; muted values are Claude Code's defaults
npx claudepluginhub renanlido/tia-harness --plugin tia-harness9 skills in this plugin
/cpu-selectRecommend a Siemens S7-1500/S7-1200 CPU family + variant + order number (MLFB) from an engineering need (I/O count, scan/performance, memory, communication ports, safety, redundancy, motion). Use when the user asks "which CPU / PLC should I use", gives selection criteria instead of a model, or needs a typeIdentifier for a project-spec. Deterministic heuristic over the bundled CPU reference — NO MCP. Output: recommended CPU + justification + the OrderNumber:{MLFB}/V{fw} TypeIdentifier (flagged: confirm/resolve the concrete MLFB+firmware with tia_catalog before building). Not for validating a spec (spec-validate) or when the user already named a model./spec-planTurn a VALIDATED TIA project-spec into the ordered, named sequence of offline build operations WITHOUT mutating anything (a dry plan). Use after spec-validate passes and before tia-scaffold — when the user asks to "plan / preview / dry-run the build", or wants to see exactly what scaffolding a spec would do and in what order. Class R: runs tia_spec_validate then tia_spec_plan, both PURE (no serve, no TIA Portal); with a project open it can add a read-only impact check (tia_crossrefs) for the existing objects the plan would write to. Output: the ordered M-off steps + assumptions + warnings (+ that impact); nothing is applied and no gate is crossed. Not for validating (spec-validate) or applying the build (tia-scaffold).Other plugins' skills for the same job