feat(iace): generic cross-domain leak gates + norm vocab reconciliation

- Domain-gate ~15 foreign machine classes (pool, amusement, paint booth,
  tank farm, reactor, lathe/chips, saw, film/carton, robot, mobile cab,
  asbestos, playground swing) in pattern_domain_gates.go so ungated hazard
  patterns stop leaking into unrelated machines; matching emit keywords
  added in keyword_dictionary.go (gate+emit share one vocabulary).
- Extend the cross-domain precision guard to 6 machine classes (press,
  cobot, motor, welding + the 2 GTs) with per-case homeDomains, so a
  machine's own domain terms are never flagged. GT coverage stays 100%.
- Reconcile the fine-grained norm machine-type vocabulary (455 keys) with
  the 68 canonical dropdown keys via canonicalMachineType() family folding
  in matchNorm — welding 0->17, robotics_cobot 0->6, press 8->13,
  circular_saw 1->35 machine-specific C-norms. Pattern gating left strict.
- Fix initialize?force=true summary index-shift that mislabeled counts
  (reported matched-patterns as "hazards"); now uses named step vars.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
Benjamin Admin
2026-06-10 22:29:10 +02:00
parent b7a7e70731
commit 005a2ed711
10 changed files with 656 additions and 9 deletions
@@ -74,8 +74,20 @@ func GetKeywordDictionary() []KeywordEntry {
{Keywords: []string{"kuehlschmierstoff", "kss-anlage", "kss-kreislauf", "kss-aufbereitung", "bearbeitungszentrum", "kuehlturm"}, ExtraTags: []string{"dom_machining"}},
{Keywords: []string{"silo", "schuettgut", "gaerbehaelter", "getreidesilo", "mehlsilo", "schuettgutfoerder"}, ExtraTags: []string{"dom_bulk"}},
{Keywords: []string{"palettierer", "palettieranlage", "palettierroboter"}, ExtraTags: []string{"dom_palletizer"}},
{Keywords: []string{"spielplatz", "klettergeraet", "spielgeraet", "spielturm"}, ExtraTags: []string{"dom_playground"}},
{Keywords: []string{"spielplatz", "klettergeraet", "spielgeraet", "spielturm", "schaukel", "wippe", "rutsche", "sandkasten"}, ExtraTags: []string{"dom_playground"}},
{Keywords: []string{"kraftstation", "fitnessgeraet", "trainingsgeraet", "kraftgeraet", "langhantel"}, ExtraTags: []string{"dom_fitness"}},
{Keywords: []string{"schwimmbad", "schwimmbecken", "schwimmhalle", "planschbecken", "whirlpool", "badebecken"}, ExtraTags: []string{"dom_aquatic"}},
{Keywords: []string{"karussell", "fahrgeschaeft", "freizeitpark", "vergnuegungspark", "riesenrad", "achterbahn"}, ExtraTags: []string{"dom_amusement"}},
{Keywords: []string{"fahrersitz", "fahrerkabine", "fahrerstand", "fahrerhaus", "gabelstapler", "radlader", "baumaschine"}, ExtraTags: []string{"dom_mobile_cab"}},
{Keywords: []string{"lackier", "lackierkabine", "pulverbeschicht", "beschichtungsanlage", "spritzlackier", "tauchlackier"}, ExtraTags: []string{"dom_coating"}},
{Keywords: []string{"tanklager", "raffinerie", "tankfarm", "chemiepark", "tankfeld"}, ExtraTags: []string{"dom_exproc"}},
{Keywords: []string{"reaktor", "chemieanlage", "ruehrkessel", "mischreaktor", "reaktionsbehaelter"}, ExtraTags: []string{"dom_chem"}},
{Keywords: []string{"sauerstoffanlage", "sauerstoff-versorgung", "sauerstoffversorgung", "medizinische gase"}, ExtraTags: []string{"dom_o2"}},
{Keywords: []string{"roboter", "roboterarm", "roboterzelle", "cobot", "industrieroboter", "knickarm", "manipulatorarm"}, ExtraTags: []string{"dom_robot"}},
{Keywords: []string{"bandsaege", "saegemaschine", "gattersaege", "saegewerk", "blockbandsaege"}, ExtraTags: []string{"dom_sawing"}},
{Keywords: []string{"folienwickler", "wickelmaschine", "konfektioniermaschine", "folienverpackung", "wellpappe"}, ExtraTags: []string{"dom_converting"}},
{Keywords: []string{"bergbau", "untertage", "tunnelbau", "off-grid"}, ExtraTags: []string{"dom_remote"}},
{Keywords: []string{"asbest", "asbestsanierung", "asbestexposition"}, ExtraTags: []string{"dom_asbestos"}},
// Ghost-Closure (Emit-Seite): macht die 34 toten Required-Tags
// emittierbar, jeweils NUR via domaenenspezifische Keywords -> die 120
// Ghost-Patterns feuern wieder, aber nur fuer ihre echte Maschine (kein