## 2 Study Design  
### The NAO Robot and the Interactive Games Designed for the Study  
NAO is a humanoid robot that is the size of a large doll; it has extensive capabilities in terms of perception, mobility, behavioral expression and human-oriented communication. The software interface of the NAO platform enables the implementation of complex human-robot interaction (HRI) scenarios that include verbal and non-verbal communication, human recognition and tracking, visual contact and choreography of movements [39]. It is important to note that when investigating the potential of applying social robots in ASD diagnosis (described in the second last paragraph of the Introduction), the specific features of the robot that will be used are of importance. These important features include the way the robot behaves, communicates, perceives objects and expresses its states. These features should match the child's capabilities, sensitivities and individual preferences. To the best of our knowledge, despite several studies on social robots and autism therapy, there is no off-the-shelf robotic technology that matches the present research problem well. However, a good starting point may be the ASK NAO software [26]. It is important to note that the ASK NAO software was developed for specific user requirements that do not consider autism diagnosis. Thus, for the purpose of the study, we have developed dedicated software applications for NAO. Here, we discuss users' requirements for implementing interactive scenarios for both games on the NAO platform (see below). Taking into account the requirements of the diagnosis of autism, as well as the implementation requirements for the perceptual and expressive capabilities of NAO, we have proposed detailed scenarios of an interactive game for preschool children that facilitate the differentiation of turn-taking behaviors between autistic children and typically developing children. The scenario was developed over two iterations, each containing three phases: design, implementation and evaluation [40]. An additional phase was used to adjust the scenario and software parameters to the specific experimental conditions associated with children experiencing symptoms of ASD; this phase was previously reported in the pilot study [41]. In terms of the finite-state machine (FSM) shown in Figure 1, the interaction scenario included three main states: conversation, playing _Touch me_ and playing _Dance with me_. In the state called _conversation_, the robot sits on the floor, initiates verbal communication with a child (in particular, it introduces itself), invites the child to play and asks him/her to choose one of the two available games. In the state called _Dance with Me_, the robot performs a choreographed dance to a piece of music entitled Rainy Day Games by the Green Orbs band. The melody is rhythmic, but not very fast. The choreography involves all the parts of the robot's body, where the complexity of its movements increases gradually, and individual parts of the body are activated alternately. First, the arms of the robot are raised to the side alternately, then the movement is formed of a combination of squats and synchronous sideways movement of the arms; this is followed by alternating movements of the arms up and down, alternating with forward and backward movements; sideways movements of the hips follow, then back to the squats and synchronous sideways movements of the arms. Then there is alternating bending of the elbow joints with the arms extending outwards, rocking of the hips and finally swinging of upright arms. Before returning to the conversation state, [PERSON] bows and thanks the child for dancing with it. In the state called _Touch me_, [PERSON] first sits on the floor and asks the child to touch one of its body parts: the head, the palm or the leg. If the child reacts correctly, the robot rewards the child with a verbal applause (by saying bravo). The correctness of a child's response is confirmed by raising a hand.