  By incorporating ergonomics principles into the task allocation processes,
human-robot collaboration (HRC) frameworks can favour the prevention of
work-related musculoskeletal disorders (WMSDs). In this context, existing
offline methodologies do not account for the variability of human actions and
states; therefore, planning and dynamically assigning roles in human-robot
teams remains an unaddressed challenge.This study aims to create an ergonomic
role allocation framework that optimises the HRC, taking into account task
features and human state measurements. The presented framework consists of two
main modules: the first provides the HRC task model, exploiting AND/OR Graphs
(AOG)s, which we adapted to solve the allocation problem; the second module
describes the ergonomic risk assessment during task execution through a risk
indicator and updates the AOG-related variables to influence future task
allocation. The proposed framework can be combined with any time-varying
ergonomic risk indicator that evaluates human cognitive and physical burden. In
this work, we tested our framework in an assembly scenario, introducing a risk
index named Kinematic Wear.The overall framework has been tested with a
multi-subject experiment. The task allocation results and subjective
evaluations, measured with questionnaires, show that high-risk actions are
correctly recognised and not assigned to humans, reducing fatigue and
frustration in collaborative tasks.
