feat(iace): Sprint 3B — Human Interaction Model
- 6 Standard-Rollen: operator, maintenance_tech, programmer, cleaning_staff, bystander, supervisor - HumanRoles []string Feld in HazardPattern, MatchInput, PatternMatch - patternMatches() filtert Patterns nach Rolle (nil = feuert fuer alle Rollen) - MatchReason um human_role Typ erweitert (Explainability) - 25 bestehende Patterns mit Rollen annotiert: - Cobot HP059/062/064 → operator/programmer - Maintenance HP700-714 → maintenance_tech/programmer - Operational HP070/073-078/080 → operator/maintenance_tech/programmer - Init + Parser Handler reichen Roles an MatchInput durch - 4 neue Tests: NilFiresAlways, MaintenanceTechFilter, ProgrammerTeachMode, RoleCount Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -72,7 +72,7 @@ func GetOperationalHazardPatterns() []HazardPattern {
|
||||
DefaultSeverity: 4, DefaultExposure: 3,
|
||||
},
|
||||
{
|
||||
ID: "HP070", NameDE: "Eingriff in laufende Maschine bei Stoerung", OperationalStates: []string{"recovery_mode"}, NameEN: "Intervention in running machine during fault",
|
||||
ID: "HP070", NameDE: "Eingriff in laufende Maschine bei Stoerung", OperationalStates: []string{"recovery_mode"}, HumanRoles: []string{"operator"}, NameEN: "Intervention in running machine during fault",
|
||||
RequiredComponentTags: []string{"moving_part"},
|
||||
RequiredLifecycles: []string{"fault_clearing"},
|
||||
ExcludedComponentTags: []string{"interlocked"},
|
||||
@@ -120,7 +120,7 @@ func GetOperationalHazardPatterns() []HazardPattern {
|
||||
// Wartung / Instandhaltung (HP073-HP079)
|
||||
// ================================================================
|
||||
{
|
||||
ID: "HP073", NameDE: "Wartung ohne LOTO (Lockout/Tagout)", OperationalStates: []string{"maintenance"}, NameEN: "Maintenance without LOTO",
|
||||
ID: "HP073", NameDE: "Wartung ohne LOTO (Lockout/Tagout)", OperationalStates: []string{"maintenance"}, HumanRoles: []string{"maintenance_tech"}, NameEN: "Maintenance without LOTO",
|
||||
RequiredComponentTags: []string{"moving_part"},
|
||||
RequiredLifecycles: []string{"maintenance"},
|
||||
GeneratedHazardCats: []string{"maintenance_hazard"},
|
||||
@@ -136,7 +136,7 @@ func GetOperationalHazardPatterns() []HazardPattern {
|
||||
DefaultSeverity: 5, DefaultExposure: 3,
|
||||
},
|
||||
{
|
||||
ID: "HP074", OperationalStates: []string{"maintenance"}, NameDE: "Sturz von Wartungsbuehne / Leiter", NameEN: "Fall from maintenance platform / ladder",
|
||||
ID: "HP074", OperationalStates: []string{"maintenance"}, HumanRoles: []string{"maintenance_tech"}, NameDE: "Sturz von Wartungsbuehne / Leiter", NameEN: "Fall from maintenance platform / ladder",
|
||||
RequiredComponentTags: []string{"structural_part"},
|
||||
RequiredLifecycles: []string{"maintenance", "cleaning"},
|
||||
GeneratedHazardCats: []string{"mechanical_hazard"},
|
||||
@@ -150,7 +150,7 @@ func GetOperationalHazardPatterns() []HazardPattern {
|
||||
DefaultSeverity: 4, DefaultExposure: 2,
|
||||
},
|
||||
{
|
||||
ID: "HP075", OperationalStates: []string{"maintenance"}, NameDE: "Kontakt mit heissen Teilen bei Wartung", NameEN: "Contact with hot parts during maintenance",
|
||||
ID: "HP075", OperationalStates: []string{"maintenance"}, HumanRoles: []string{"maintenance_tech"}, NameDE: "Kontakt mit heissen Teilen bei Wartung", NameEN: "Contact with hot parts during maintenance",
|
||||
RequiredComponentTags: []string{"high_temperature"},
|
||||
RequiredLifecycles: []string{"maintenance"},
|
||||
GeneratedHazardCats: []string{"thermal_hazard"},
|
||||
@@ -165,7 +165,7 @@ func GetOperationalHazardPatterns() []HazardPattern {
|
||||
DefaultSeverity: 3, DefaultExposure: 3,
|
||||
},
|
||||
{
|
||||
ID: "HP076", OperationalStates: []string{"maintenance"}, NameDE: "Kontakt mit Gefahrstoffen bei Wartung", NameEN: "Contact with hazardous substances during maintenance",
|
||||
ID: "HP076", OperationalStates: []string{"maintenance"}, HumanRoles: []string{"maintenance_tech"}, NameDE: "Kontakt mit Gefahrstoffen bei Wartung", NameEN: "Contact with hazardous substances during maintenance",
|
||||
RequiredComponentTags: []string{"chemical_risk"},
|
||||
RequiredLifecycles: []string{"maintenance", "cleaning"},
|
||||
GeneratedHazardCats: []string{"material_environmental"},
|
||||
@@ -179,7 +179,7 @@ func GetOperationalHazardPatterns() []HazardPattern {
|
||||
DefaultSeverity: 3, DefaultExposure: 3,
|
||||
},
|
||||
{
|
||||
ID: "HP077", OperationalStates: []string{"maintenance"}, NameDE: "Elektrischer Schlag bei Wartungsarbeiten", NameEN: "Electric shock during maintenance",
|
||||
ID: "HP077", OperationalStates: []string{"maintenance"}, HumanRoles: []string{"maintenance_tech"}, NameDE: "Elektrischer Schlag bei Wartungsarbeiten", NameEN: "Electric shock during maintenance",
|
||||
RequiredComponentTags: []string{"high_voltage"},
|
||||
RequiredLifecycles: []string{"maintenance", "fault_clearing"},
|
||||
GeneratedHazardCats: []string{"electrical_hazard"},
|
||||
@@ -195,7 +195,7 @@ func GetOperationalHazardPatterns() []HazardPattern {
|
||||
DefaultSeverity: 5, DefaultExposure: 3,
|
||||
},
|
||||
{
|
||||
ID: "HP078", OperationalStates: []string{"maintenance"}, NameDE: "Ergonomische Belastung bei Wartungszugang", NameEN: "Ergonomic strain at maintenance access",
|
||||
ID: "HP078", OperationalStates: []string{"maintenance"}, HumanRoles: []string{"maintenance_tech"}, NameDE: "Ergonomische Belastung bei Wartungszugang", NameEN: "Ergonomic strain at maintenance access",
|
||||
RequiredComponentTags: []string{"structural_part"},
|
||||
RequiredLifecycles: []string{"maintenance"},
|
||||
GeneratedHazardCats: []string{"ergonomic"},
|
||||
@@ -228,7 +228,7 @@ func GetOperationalHazardPatterns() []HazardPattern {
|
||||
// Einrichten / Umruesten / Werkzeugwechsel (HP080-HP085)
|
||||
// ================================================================
|
||||
{
|
||||
ID: "HP080", NameDE: "Quetschen bei Werkzeugwechsel", OperationalStates: []string{"maintenance", "teach_mode"}, NameEN: "Crushing during tool change",
|
||||
ID: "HP080", NameDE: "Quetschen bei Werkzeugwechsel", OperationalStates: []string{"maintenance", "teach_mode"}, HumanRoles: []string{"maintenance_tech", "programmer"}, NameEN: "Crushing during tool change",
|
||||
RequiredComponentTags: []string{"crush_point", "high_force"},
|
||||
RequiredLifecycles: []string{"changeover", "setup"},
|
||||
GeneratedHazardCats: []string{"mechanical_hazard"},
|
||||
|
||||
Reference in New Issue
Block a user