Fabien Lotte

Camille Jeunet

Jelena Mladenovic

Bernard N'kaoua

Léa Pillette

A BCI challenge for the signal processing community: considering the user in the loop

Introduction

ElectroEncephaloGraphy (EEG)-based Brain-Computer Interfaces (BCIs) have proven promising for a wide range of applications, from communication and control for severely motor-impaired users, to gaming targeted at the general public, real-time mental state monitoring and stroke rehabilitation, to name a few [START_REF] Clerc | Brain-Computer Interfaces 2: Technology and Applications[END_REF][START_REF] Lotte | Electroencephalography Brain-Computer Interfaces[END_REF]. Despite this promising potential, BCIs are still scarcely used outside laboratories for practical applications. The main reason preventing EEG-based BCIs from being widely used is arguably their poor usability, which is notably due to their low robustness and reliability. To operate a BCI, the user has to encode commands in his/her EEG signals, typically using mental imagery tasks, such as imagining hand movement or mental calculations. The execution of these tasks leads to specific EEG patterns, which the machine has to decode by using signal processing and machine learning. So far, to address the reliability issue of BCI, most research efforts have been focused on command decoding only. This present book contains numerous examples of advanced machine learning and signal processing techniques to robustly decode EEG signals, despite their low spatial resolution, their noisy and non-stationary nature. Such algorithms contributed a lot to make BCI systems more efficient and effective, and thus more usable.

However, if users are unable to encode commands in their EEG patterns, no signal processing or machine learning algorithm would be able to decode them. There-1 fore, we argue in this chapter that BCI design is not only a decoding challenge (i.e., translating EEG signals into control commands), but also a human-computer interaction challenge, which aims at ensuring the user can control the BCI. Indeed, BCI control has been shown to be a skill, that needs to be learned and mastered [START_REF] Neuper | Neurofeedback Training for BCI Control[END_REF][START_REF] Jeunet | Human Learning for Brain-Computer Interfaces[END_REF]. Recent research results have actually shown that the way BCI users are currently trained was suboptimal, both theoretically [START_REF] Lotte | Flaws in current human training protocols for spontaneous Brain-Computer Interfaces: lessons learned from instructional design[END_REF][START_REF] Lotte | Towards Improved BCI based on Human Learning Principles[END_REF] and practically [START_REF] Jeunet | Why Standard Brain-Computer Interface (BCI) Training Protocols Should be Changed: An Experimental Study[END_REF]. Moreover, the user is known to be one of the main cause of EEG signals variability in BCI, due to his/her change in mood, fatigue, attention, etc. [START_REF] Mladenovic | A generic framework for adaptive EEGbased BCI training and operation[END_REF][START_REF] Shenoy | Towards adaptive classification for BCI[END_REF].

Therefore, there are a number of open challenges to take the user into account during BCI design and training, for which signal processing and machine learning methods could provide solutions. These challenges notably concern 1) the modeling of the user and 2) understanding and improving how and what the user is learning.

More precisely, the BCI community should first work on user modeling, i.e. modeling and updating the user's mental states and skills overtime from their EEG signals, behavior, BCI performances, and possibly other sensors. This would enable us to design individualized BCI, tailored for each user, and thus maximally efficient for each user. The community should also identify new performance metrics -beyond classification accuracy -that could better describe users' skills at BCI control.

Second, the BCI community has to understand how and what the user learns to control the BCI. This includes thoroughly identifying the features to be extracted and the classifier to be used to ensure the user's understanding of the feedback resulting from them, as well as how to present this feedback. Being able to update machine learning parameters in a specific manner and a precise moment to favor learning without confusing the user with the ever-changeable feedback is another challenge. Finally, it is necessary to gain a clearer understanding of the reasons why mental commands are sometimes correctly decoded and sometimes not; what makes people sometimes fail at BCI control, in order to be able to guide them to do better.

Altogether, solving these challenges could have a substantial impact in improving BCI efficiency, effectiveness and user-experience, i.e., BCI usability. Therefore, this chapter aims at identifying and describing these various open and important challenges for the BCI community, at the user level, to which experts in machine learning and signal processing could contribute. It is organized as follows: Section 1.2 addresses challenges in BCI user modeling, while Section 1.3 targets the understanding and improvement of BCI user learning. For each section, we identify the corresponding challenges, the possible impact of solving them, and first research directions to do so. Finally the chapter summarizes these open challenges and possible solutions in Section 1.4.

Modeling the User

In order to be fully able to take the user into account into BCI design and training, the ideal solution would be to have a full model of the users, and in particular of the users' traits, e.g., cognitive abilities or personality, and states, e.g., current attention level or BCI skills at that stage of training. Signal processing and machine learning tools and research can contribute to these aspects by developing algorithms to estimate the users' mental states (e.g., workload) from EEG and other physiological signals, by estimating how well users can self-modulate their EEG signals, i.e., their BCI skills, and by dynamically modeling, using machine learning, all these aspects together. We detail these points below.

Estimating and tracking the user's mental states from multimodal sensors

Increase in the number of available low-cost sensors [START_REF] Swan | Sensor mania! the internet of things, wearable computing, objective metrics, and the quantified self 2.0[END_REF] and development in machine learning enables real time assessment of some cognitive, affective and motivational processes influencing learning, such as attention for instance. Numerous types of applications are already taking advantage of these pieces of information, such as health [START_REF] Jovanov | A wireless body area network intelligent motion sensors for computer assisted physical rehabilitation[END_REF], sport [START_REF] Baca | Rapid feedback systems for elite sports training[END_REF] or intelligent tutoring systems [START_REF] Woolf | Affective tutors: Automatic detection of and response to student emotion[END_REF]. Such states could thus be relevant to improve BCI learning as well. Among the cognitive states influencing learning, attention deserves a particular care since it is necessary for memorization to occur [START_REF] Fisk | Memory as a function of attention, level of processing, and automatization[END_REF]. It is a key factor in several models of instructional design, e.g., in the ARCS model where A stands for Attention [START_REF] Keller | The Arcs model of motivational design[END_REF]. Attention levels can be estimated in several ways. Based on the resource theory of Wickens, task performance is linked to the amount of attentional resources needed [START_REF] Wickens | Multiple resources and performance prediction[END_REF]. Therefore, performances can provide a first estimation of the level of attentional resources the user dedicates to the task. However, this metric also reflects several other mental processes, and should thus be considered with care. Moreover, attention is a broad term that encompasses several types of concepts [START_REF] Posner | Components of attention[END_REF][START_REF] Cohen | The neuropsychology of attention[END_REF]. For example, focused attention refers to the amount of information that can be processed at a given time whereas vigilance refers to the ability to pay attention to the apparition of an infrequent stimulus over a long period of time. Each type of attention has particular ways to be monitored, for example vigilance can be detected using blood flow velocity measured by transcranial Doppler sonography (TCD) [START_REF] Shaw | Effects of sensory modality on cerebral blood flow velocity during vigilance[END_REF]. Focused visual attention, which refers to the selection of visual information to process, can be assessed by measuring eye movements [START_REF] Glaholt | Eye tracking in the cockpit: a review of the relationships between eye movements and the aviators cognitive state[END_REF]. While physiological sensors provide information about the physiological reactions associated with processes taking place in the central nervous system, neuroimaging has the advantage of recording information directly from the source [START_REF] Frey | Review of the use of electroencephalography as an evaluation method for human-computer interaction[END_REF]. EEG recordings enable to discriminate some types of attention with various levels of reliability given the method used. For instance, alpha band (7.5 to 12.5 Hz) can be used for the discrimination of several levels of attention [START_REF] Klimesch | Induced alpha band power changes in the human EEG and attention[END_REF], while the amplitude of event related potentials (ERP) are modulated by visual selective attention [START_REF] Saavedra | Processing stages of visual stimuli and event-related potentials[END_REF]. While specific experiments need to be carried out to specify the exact nature of the type(s) of attention involved in BCI training, a relationship between gamma power (30 to 70 Hz) in attentional network and mu rhythm-based BCI performance have already been shown by Grosse-Wentrup et al. [START_REF] Grosse-Wentrup | Causal influence of gamma oscillations on the sensorimotor rhythm[END_REF][START_REF] Grosse-Wentrup | High gamma-power predicts performance in sensorimotor-rhythm braincomputer interfaces[END_REF]. Such linear correlation suggests the implication of focused attention and working memory [START_REF] Grosse-Wentrup | High gamma-power predicts performance in sensorimotor-rhythm braincomputer interfaces[END_REF] in BCI learning.

The working memory (WM) load or workload is another cognitive factor of influence for learning [START_REF] Baddeley | Working memory. Psychology of learning and motivation[END_REF][START_REF] Mayer | Multimedia learning (2nd)[END_REF]. It is related to the difficulty of the task, depends on the user's available resources and to the quantity of information given to the user.

An optimal amount of load is reached when the user is challenged enough not to get bored and not too much compared with his abilities [START_REF] Gerjets | Cognitive state monitoring and the design of adaptive instruction in digital environments: lessons learned from cognitive workload assessment using a passive braincomputer interface approach[END_REF]. Behavioral measures of workload include accuracy and response time, when physiological measures comprise eye-movements [START_REF] Sr | Analytical techniques of pilot scanning behavior and their application[END_REF], eye blinks [START_REF] Ahlstrom | Using eye movement activity as a correlate of cognitive workload[END_REF], pupil dilatation [START_REF] De Greef | Eye movement as indicators of mental workload to trigger adaptive automation[END_REF] or galvanic skin response [START_REF] Verwey | Detecting short periods of elevated workload: A comparison of nine workload assessment techniques[END_REF]. However, as most behavioral measures, these measures change due to WM load, but not only, making them unreliable to measure uniquely WM load. EEG is a more reliable measure of workload [START_REF] Wobrock | Continuous Mental Effort Evaluation during 3D Object Manipulation Tasks based on Brain and Physiological Signals[END_REF]. Gevins et al. [START_REF] Gevins | Monitoring working memory load during computer-based tasks with EEG pattern recognition methods[END_REF] showed that WM load could be monitored using theta (4 to 7 Hz), alpha (8 to 12Hz) and beta (13 to 30 Hz) bands from EEG data. Low amount of workload could be discriminated from high amount of workload in 27s long epochs of EEG with a 98% accuracy using Joseph-Vigliones neural network algorithm [START_REF] Joseph | Contributions to perceptron theory[END_REF][START_REF] Viglione | Applications of pattern recognition technology[END_REF]. Interestingly they also obtained significant classification accuracies when training their network using data from another day (ie. 95%), another person (ie. 83%) and another task (ie. 94%) than the data used for classification. Several experiments have since reported online (ie. real time) classification rate ranging from 70 to 99% to distinguish between two types of workload [START_REF] Blankertz | The Berlin braincomputer interface: non-medical uses of BCI technology[END_REF][START_REF] Grimes | Feasibility and pragmatics of classifying working memory load with an electroencephalograph[END_REF]. Results depend greatly on the length of the signal epoch used: the longer the epoch, the better the performance [START_REF] Grimes | Feasibility and pragmatics of classifying working memory load with an electroencephalograph[END_REF][START_REF] Mühl | EEG-based Workload Estimation Across Affective Contexts[END_REF]. The importance of monitoring working memory in BCI applications is all the more important because BCI illiteracy is associated with high theta waves [START_REF] Ahn | High theta and low alpha powers may be indicative of BCI-illiteracy in motor imagery[END_REF] which is an indicator of cognitive overload [START_REF] Yamamoto | Topographic EEG study of visual display terminal (VDT) performance with special reference to frontal midline theta waves[END_REF]. Finally, another brain imaging modality can be used to estimate mental workload: functional Near Infrared Spectroscopy (fNIRS). Indeed, it was shown that hemodynamic activity in the prefrontal cortex, as measured using fNIRS, could be used to discriminate various workload levels [START_REF] Herff | Mental workload during N-back taskquantified in the prefrontal cortex using fNIRS[END_REF][START_REF] Peck | Using fNIRS to measure mental workload in the real world[END_REF][START_REF] Durantin | Using near infrared spectroscopy and heart rate variability to detect mental overload[END_REF].

Learners state assessment has mostly focused on cognitive components, such as the ones presented above, because learning has often been considered as information processing. However, affects also play a central role in learning [START_REF] Philippot | Emotion and memory[END_REF]. For example, Isen [START_REF] Isen | Positive Affect and Decision Making, Handbook of emotions[END_REF] has shown that positive affective states facilitate problem solving. Emotions are often inferred using contextual data, performances and models describing the succession of affective states the learner goes through while learning. The model of Kort et al. [START_REF] Kort | An affective model of interplay between emotions and learning: Reengineering educational pedagogy-building a learning companion[END_REF] is an example of such model. Though physiological signals can also be used such as electromyogram, electrocardiogram, skin conductive resistance and blood volume pressure [START_REF] Picard | Affective wearables[END_REF][START_REF] Picard | Toward computers that recognize and respond to user emotion[END_REF]. Arroyo et al. [START_REF] Arroyo | Emotion Sensors Go To School[END_REF] developed a system composed of four different types of physiological sensors. Their results show that the facial recognition system was the most efficient and could predict more than 60% of the variance of the four emotional states. Several classification methods have been tried to classify EEG data and deduce the emotional state of the subject. Methods such as multilayer perceptron [START_REF] Lin | Multilayer perceptron for EEG signal classification during listening to emotional music[END_REF], K Nearest Neighbor (KNN), Linear Discriminant Analysis (LDA), Fuzzy K-Means (FKM) or Fuzzy C Means (FCM) were explored [START_REF] Murugappan | Timefrequency analysis of EEG signals for human emotion detection[END_REF][START_REF] Murugappan | Classification of human emotion from EEG using discrete wavelet transform[END_REF], using as input alpha, beta and gamma frequency bands power. Results are promising and vary around 75% accuracy for two to five types of emotions. Note, however, that the use of gamma band power features probably means that the classifiers were also using EMG activity due to different facial expressions. For emotion monitoring as well, fNIRS can prove useful. For instance, in [START_REF] Heger | Continuous affective states recognition using functional near infrared spectroscopy[END_REF], fNIRS was shown to be able to distinguish two classes of affective stimuli with different valence levels with average classification accuracies around 65%. Recognizing emotion represents a challenge because most of the studies rely on the assumption that people are accurate in recognizing their emotional state and that the emotional cues used have a similar and the intended effect on subject. Moreover, many brain structures involved into emotion are deep in the brain, e.g., the amygdala, and as such activity from these areas are often very weak or even invisible in EEG and fNIRS.

Motivation is interrelated with emotions [START_REF] Harter | A new self-report scale of intrinsic versus extrinsic orientation in the classroom: Motivational and informational components[END_REF][START_REF] Stipek | Motivation to learn: From theory to practice[END_REF]. It is often approximated using the performances [START_REF] Blankertz | The Berlin braincomputer interface: non-medical uses of BCI technology[END_REF]. Several EEG characteristics are modulated by the level of motivation. For example, this is the case for the delta rhythm (0.5 to 4 Hz) which could originate from the brain reward system [START_REF] Knyazev | EEG delta oscillations as a correlate of basic homeostatic and motivational processes[END_REF]. Motivation is also known to modulate the amplitude of the P300 event related potential (ERP) and therefore increases performance with ERP-based BCI [START_REF] Kleih | Motivation modulates the P300 amplitude during braincomputer interface use[END_REF]. Both motivation and emotions play a major role in biofeedback learning [START_REF] Miller | Some directions for clinical and experimental research on biofeedback. Clinical biofeedback: Efficacy and mechanisms[END_REF][START_REF] Yates | Biofeedback and the modification of behavior[END_REF][START_REF] Kübler | Braincomputer communication: Unlocking the locked in[END_REF][START_REF] Kübler | Brain-computer communication: self-regulation of slow cortical potentials for verbal communication[END_REF][START_REF] Hernandez | Low motivational incongruence predicts successful EEG resting-state neurofeedback performance in healthy adults[END_REF] and in BCI performances [START_REF] Hammer | Psychological predictors of SMR-BCI performance[END_REF][START_REF] Neumann | Predictors of successful self control during braincomputer communication[END_REF].

Cognitive, affective and motivational states have a great impact on learning outcome and machine learning plays a key role in monitoring them. Though challenges remain to be overcome, such as detecting and removing artifacts in real time. For example, facial expressions often occur due to change in mental states and may create artifacts polluting EEG data and for which real time removal still represents an issue. Limitations also arise from the number of different states we are able to differentiate. The quantity of data to train the classifier increasing with the number of classes to differentiate. Future studies should also focus on the reliability and stability of the classification within and across individuals [START_REF] Christensen | The effects of day-today variability of physiological data on operator functional state classification[END_REF]. Indeed, classification accuracy, particularly online one, still needs to be improved. Furthermore, calibration of classifiers is often needed for each new subject or session which is time consuming and might impede the use of such technology on a larger scale. Finally, while several emotional states can be recognized from user's behavior, there is usually very limited overt behavior, e.g., movements or speech, during BCI use. Thus, future studies should try to differentiate more diverse emotional states, e.g., frustration, directly from EEG and physiological data.

Quantifying users' skills

As mentioned above, part of the user modeling consists in measuring the users' skills at BCI control. Performance measurement in BCI is an active research topic, and various metrics were proposed [START_REF] Thompson | Performance measurement for brain-computer or brain-machine interfaces: a tutorial[END_REF][START_REF] Hill | A general method for assessing braincomputer interface performance and its limitations[END_REF]. However, so far, the performance considered and measured was that of the whole BCI system. Therefore, such performance metrics reflected the combined performances of the signal processing pipeline, the sensors, the user, the BCI interface and application, etc. Standard performance metrics used cannot quantify specifically and uniquely the BCI users' skills, i.e., how well the user can self-modulate their brain activity to control the BCI. This would be necessary to estimate how well the user is doing, where are their strengths and weaknesses, in order to provide optimal instructions, feedback, application interface and training exercises.

We recently proposed some new metrics to go in that direction, i.e., to estimate specifically users' skills at BCI control, independently of a given classifier [START_REF] Lotte | Online classification accuracy is a poor metric to study mental imagery-based BCI user learning: an experimental demonstration and new metrics[END_REF]. In particular, we proposed to quantify the users' skills at BCI control, by estimating their EEG patterns distinctiveness between commands, and their stability. We notably used Riemannian geometry to quantify how far apart from each other the EEG patterns of each command are, as represented using EEG spatial covariance matrices, and how variable over trials these patterns are. We showed that such metrics could reveal clear user learning effects, i.e., improvements of the metrics over training runs, when classical metrics such as online classification accuracy often failed to do so [START_REF] Lotte | Online classification accuracy is a poor metric to study mental imagery-based BCI user learning: an experimental demonstration and new metrics[END_REF].

This work thus stressed the need for new and dedicated measures of user skills and learning. The metrics we proposed are however only a first attempt at doing so, with more refined and specific metrics being still needed. For instance, our metrics can mostly quantify control over spatial EEG activity (EEG being represented using spatial covariance matrices). We also need metrics to quantify how much control the user has over their spectral EEG activity, as well as over their EEG temporal dynamics. Notably, it would seem useful to be able to quantify how fast, how long and how precisely a user can self-modulate their EEG activity, i.e., produce a specific EEG pattern at a given time and for a given duration. Moreover, such new metrics should be able to estimate successful voluntary self-regulation of EEG signals amidst noise and natural EEG variabilities, and independently of a given EEG classifier. We also need metrics that are specific for a given mental task, to quantify how well the user can master this mental command, but also a single holistic measure summarizing their control abilities over multiple mental tasks (i.e., multiclass metrics), to easily compare users and give them adapted training and BCI systems. The signal processing and machine learning community should thus address all these open and difficult research problems by developing new tools to quantify the multiple aspects of BCI control skills.

Creating a dynamic model of the users' states and skills

A conceptual model of Mental Imagery BCI performance

In order to reach a better understanding of the user-training process, a model of the factors impacting Mental Imagery (MI)-BCI skill acquisition is required. In other words, we need to understand which users traits and states impact BCI performance, how these factors do interact and how to influence them through the experimental design or specific cognitive training procedures. We call such a model a Cognitive Model. Busemeyer and Diederich describe cognitive models as models which aim to scientifically explain one or more cognitive processes or how these processes interact [START_REF] Busemeyer | Cognitive modeling[END_REF]. Three main features characterize cognitive models: (1) their goal: they aim at explaining cognitive processes scientifically, (2) their format: they are described in a formal language, (3) their background: they are derived from basic principles of cognition [START_REF] Busemeyer | Cognitive modeling[END_REF]. Cognitive models guarantee the production of logically valid predictions, they allow precise quantitative predictions to be made and they enable generalization [START_REF] Busemeyer | Cognitive modeling[END_REF].

In the context of BCIs, developing a cognitive model is a huge challenge due to the complexity and imperfection of BCI systems. Indeed, BCIs suffer from many limitations, independent from human learning aspects, that could explain users modest performance. For instance, the sensors are often very sensitive to noise and do not enable the recording of high quality brain signals while the signal processing algorithms sometimes fail to recognize the encoded mental command. But it is also a huge challenge due to the lack of literature on the topic and to the complexity and cost associated with BCI experiments that are necessary to increase the quantity of experimental data required to implement a complete and precise model [START_REF] Jeunet | Towards a cognitive model of MI-BCI user training[END_REF].

Still, a cognitive model would enable us to reach a better understanding of the MI-BCI user-training process, and consequently to design adapted and adaptive training protocols. Additionally, it would enable BCI scientists to guide neurophysiological analyses by targeting the cognitive and neurophysiological processes involved in the task. Finally, it would make it possible to design classifiers robust to variabilities, i.e., able to adapt to the neurophysiological correlates of the factors included in the model. To summarize, building such a model, by gathering the research done by the whole BCI community, could potentially lead to substantial improvements in MI-BCI reliability and acceptability.

Different steps are required to build a cognitive model [START_REF] Busemeyer | Cognitive modeling[END_REF]. First, it requires a formal description of the cognitive process(es) / factors to be described based on conceptual theories. Next, since the conceptual theories are most likely incomplete, ad hoc assumptions should be made to complete the formal description of the targeted factors. Third, the parameters of the model, e.g., the probabilities associated with each factors included in the model, should be determined. Then, the predictions made by the model should be compared to empirical data. Finally, this process should be iterated to constrain and improve the relevance of the model.

By gathering the results of our experimental studies and of a review of the literature, we proposed a first formal description of the factors influencing MI-BCI performance [START_REF] Jeunet | Towards a cognitive model of MI-BCI user training[END_REF]. We grouped these factors into 3 categories [START_REF] Jeunet | Advances in user-training for mental-imagerybased BCI control: Psychological and cognitive factors and their neural correlates[END_REF]. The first category is "task-specific", i.e., it includes factors related to the BCI paradigm considered. Here, as we focused on Mental-Imagery based BCIs, this category gathers factors related to Spatial Abilities (SA), i.e., the ability to produce, transform and manipulate mental images [START_REF] Poltrock | Individual differences in visual imagery and spatial ability[END_REF]. Both the second and third categories include "task-unspecific" factors, or, in other words, factors that could potentially impact performance whatever the paradigm considered. More precisely, the second category includes motivational and cognitive factors, such as attention (state and trait) or engagement. These factors are likely to be modulated by the factors of the third category that are related to the technology-acceptance, i.e., to the way users perceive the BCI system. This last category includes different states such as the level of anxiety, self efficacy, mastery confidence, perceived difficulty or the sense of agency.

The challenge is thus to modulate these factors to optimize the user's state and trait and thus increase the probability of a good BCI performance and/or of an efficient learning. In order to modulate these factors -that can be either states (e.g., motivation) or malleable traits (e.g., spatial abilities), one can act on specific effectors: design artefacts or cognitive activities/training.

The effectors we will introduce hereafter are mainly based on theoretical hypotheses. Their impact on the users' states, traits and performance are yet to be quantified. Thus, although these links make sense from a theoretical point of view, they should still be considered with caution. We determined three types of links between the factors and effectors. "Direct influence on user state": these effectors are suggested to influence the user's state and, consequently, are likely to have a direct impact on performance. For instance, proposing a positively biased feedback -making users believe they are doing better than what they really are -has been suggested to improve (novice) users' sense of agency (i.e., the feeling of being in control, see Section 1.3.3.1 for more details) [START_REF] Kübler | Brain-computer communication: self-regulation of slow cortical potentials for verbal communication[END_REF]. "Help for users with a specific profile": these effectors could help users who have a specific profile and consequently improve their performance. For instance, proposing an emotional support has been suggested to benefit highly tensed/anxious users [START_REF] N'kambou | Advances in intelligent tutoring systems[END_REF] (see Section 1.3.3.2 for more details). "Improved abilities": this link connects effectors of type cognitive activities/exercises to abilities (malleable traits) that could be improved thanks to these activities. For instance, attentional neurofeedback has been suggested to improve attentional abilities [START_REF] Zander | Towards neurofeedback for improving visual attention[END_REF]. For more details, see [START_REF] Jeunet | Towards a cognitive model of MI-BCI user training[END_REF].

This model has been built based on the literature related to mental-imagery based BCIs (and mainly to motor-imagery based BCIs). It would be interesting to investigate the relevance of this model for other BCI paradigms, such as BCIs based on Steady-State Visual Evoked Potentials (SSVEP) or BCIs based on P300. It is noteworthy that for instance, motivation has already been shown to modulate P300 amplitude and performance [START_REF] Kleih | Motivation modulates the P300 amplitude during braincomputer interface use[END_REF]. The effect of mastery confidence (which is included in the "technology-acceptance factors" in our model) on P300-based BCI performance has also been investigated [START_REF] Kleih | Does mastery confidence influence P300 based braincomputer interface (BCI) performance? In: Systems, Man, and Cybernetics[END_REF]. The results of this study were not conclusive, which led the authors to hypothesize that either this variable had no effect on performance or that they may not have succeeded to manipulate participants' mastery confidence. Further investigation is now required. Besides, the same authors proposed a model of BCI performance [START_REF] Kleih | Psychological factors influencing brain-computer interface (BCI) performance[END_REF]. This model gathers physiological, anatomical and psychological factors. Once again, it is interesting to see that, while organized differently, similar factors were included in the model. To summarize, it would be relevant to further investigate the factors influencing performance in different BCI paradigms, and then investigate to which extent some of these factors are common to all paradigms (i.e., task-unspecific), while determining which factors are specific to the paradigm/task. Then, the next step would be to propose a full and adaptive model of BCI performance. Now, from a signal processing and machine learning point of view, many challenges are remaining. We should aim at determining some physiological or neurophysiological correlates of the factors included in this model in order to be able to estimate, in real time, the state of the BCI user. Therefore, the signal processing community should design tools to recognize these neural correlates in real-time, from noisy signals. Besides, the model itself requires machine learning expertise to be implemented, as detailed in the next Section, i.e., Section 1.2.3.2. Then, one of the main challenges will be to determine, for each user, based on the recorded signals and performance, when the training procedure should be adapted in order to optimize the performance and learning process. Machine learning techniques could be used in order to determine, based on a pool of previous data (e.g., using case-based reasoning) and on theoretical knowledge (e.g., using rule-based reasoning), when to make the training procedure evolve. In the field of Intelligent Tutoring Systems (ITS), where the object is to adapt the training protocol dynamically to the state (e.g., level of skills) of the learner, a popular approach is to use multi-arm bandit algorithms [START_REF] Clement | Multi-arm bandits for intelligent tutoring systems[END_REF]. Such an approach could be adapted for BCI training. The evolution of the training procedure could be either continuous or divided into different steps, in which case it would be necessary to determine relevant thresholds on users' states values, from which the training procedures should evolve, e.g., to become more complex, to change the context and propose a variation of the training tasks, to go back to a previous step that may have not been assimilated correctly, etc.

A computational model for BCI adaptation

As discussed in previous sections, it is necessary to identify the psychological factors, user skills and traits which will determine a successful BCI performance. Coadaptive BCIs, i.e., dynamically adaptive systems which adjust to signal variabilities during a BCI task, and in such way adapt to the user, while the user adapts to the machine via learning -showed tremendous improvement in the system performance ( [START_REF] Schwarz | A co-adaptive sensory motor rhythms Brain-Computer Interface based on common spatial patterns and Random Forest[END_REF] for MI; [START_REF] Thomas | CoAdapt P300 speller: optimized flashing sequences and online learning[END_REF] for P300). However, these techniques dwell mostly within the signal variabilities, by only adjusting to them, without acknowledging and possibly influencing the causes of such variabilities -human factors. These factors, once acknowledged, should be structured in a conceptual framework as in [START_REF] Mladenovic | A generic framework for adaptive EEGbased BCI training and operation[END_REF] in order to be properly influenced or to be adapted upon. In this framework for adaptive BCI methods, the human psychological factors are grouped by their degree of stability or changeability in time, e.g., skills could take multiple sessions (months) to change, while attention drops operate within short time periods. All these changes might have certain EEG signatures, thus considering the time necessary for these factors to change, the machine could be notified to adapt accordingly, and could predict and prevent negative behavior. To influence user behavior, the framework contains a BCI task model, arranged within the same time scales as the user's factors. Consequently, if the user does not reach a certain minimal threshold of performance for one BCI task, the system would switch to another, e.g., if kinesthetic imagination of hand movements is worse than tongue than it would switch to tongue MI. Additionally, if the user shows MI illiteracy, after a session, then the system would switch to other paradigms, and so on. Hence, the task model represents the possible BCI tasks managed by the exploration/exploitation ratio to adapt to the users and optimally influence them, within the corresponding time scales. Once identified and modeled theoretically, we need to search for computational models generic enough which could encompass such complex and unstable behavior, and enable us to design adaptive BCIs, whose signal processing, training tasks and feedback are dynamically adapted to these factors.

Several behavioral sciences and neuroscience theories strive to explain the brain's cognitive abilities based on statistical principles. They assume that the nervous system maintains internal probabilistic models that are updated by neural processing of sensory information using Bayesian probability methods. Kenneth Craik suggested in 1943 that the mind constructs "small-scale models" of reality -later named Men-tal Models [START_REF] Pn | Mental models: Towards a cognitive science of language, inference, and consciousness[END_REF] -that it uses to anticipate events. Using a similar principle, Active Inference, a generic framework based on Bayesian inference, models any adaptive system, as the brain, in a perception/action context [START_REF] Friston | The anatomy of choice: active inference and agency[END_REF]. Active Inference describes the world to be in a true state which can never be completely revealed as the only information the adaptive system has are observations obtained through sensory input. The true state of the world is in fact hidden to the observers, and as such is set in their internal, generative model of the world, as hidden states. The true state of the world is inferred through sensory input or observations and is updated in a generative model, i.e., an internal representation of the world containing empirical priors and prior beliefs. The empirical priors are the hidden states and the possible actions to be made when an observation occurs. The event anticipation and action selection are defined with the free energy minimization principle or minimization of the surprise, and utility function, i.e., a measure of preferences over some set of outcomes. In other words, a set of possible actions which were previously generated in the internal model as empirical priors are favored in order to get a desired outcome. For instance, if a stranger -A -asks a person -B -to borrow him a phone in the street, the outcome of this event or the decision of B would depend on his model of the world, or empirical priors that relate to such an event. B's decision will also depend on his prior beliefs, for instance a religious man would have principles such that one should always help those in need. B can never reveal the absolute truth about A's intentions. So, if B's experience, i.e., empirical priors were negative, and no prior beliefs or higher values govern his actions, he will be likely to refuse. However, if it was positive, B will be likely to accept to help A. Additionally, B's reaction time will depend on a specific prior which encodes the exploration/ exploitation ratio. Hence, B anticipates an outcome, and acts in such a way and in a certain time to reach that event imagined in the future. He inferred the true state -the stranger's intentions-with his empirical priors and he acted to achieve a desired outcome or comply to prior beliefs. The promotion of certain outcomes is encoded in the utility function, and are set as prior beliefs. The free energy minimization principle relies on minimizing the Kullback-Leibler divergence or the relative entropy between two probability distributions -the current state and the desired state. It can be thought of as a prediction error that reports the difference between what can be attained from the current state and the goals encoded by prior beliefs. So, by favoring a certain action, one can reduce the prediction error, and in this way the action becomes the cause of future sensory input. This computational framework enables us to model the causes of sensory input in order to better anticipate and favor certain outcomes, which is indeed what we are looking for in BCI systems.

A P300-speller is a communication BCI device which relies on a neurophysiological phenomenon -called the oddball effect -that triggers a peak in the EEG signal, around 300ms after a rare and unexpected event -a P300. This is why this type of BCI is also called a reactive BCI, as the machine elicits and detects event-related potentials (ERPs), i.e., the brain's reaction to stimuli. In the case of P300-speller, a set of letters are randomly flashed and the users need to focus their visual attention on the letter they wish to spell. Once the target letter is flashed (as an unexpected and rare event) the brain reacts enabling the machine to detect the ERP and spell the desired letter.

Bayesian inference has been successfully used for instance in designing adaptive P300-spellers [START_REF] Mattout | Improving BCI performance through co-adaptation: applications to the P300-speller[END_REF]. In this example, the outcome of a probabilistic classifier (two multivariate-Gaussian mixture) is updated online. In such a way, the machine spells a letter once it attains a certain confidence level, i.e., the decision speed or reaction time depends on the reliability of accumulated evidence. This permits the machine to stop at an optimal moment, while maximizing both speed and accuracy. However, as we mentioned earlier, this example is user-dependent and adaptive, but does not go further by considering the cause of such EEG variability in order to reduce or anticipate it. To achieve this, we could endow the machine with a certain intelligence, with Active Inference [START_REF] Mladenović | Endowing the Machine with Active Inference: A Generic Framework to Implement Adaptive BCI[END_REF]. As we explained, Active Inference is used to model cognitive behavior and decision making processes. However, in our case, we wish to equip the machine with such generative models, in order to achieve a full symbiotic user-machine co-adaptation. The true states, in this case, belong to the user characteristics and intentions, and are in fact hidden to the machine. Concretely, the hidden states are the letters or words the user intends to spell with the BCI. In the beginning all the letters have equal probability to be spelled, but the more the machine flashes letters, the more it accumulates empirical priors and becomes confident about the target letter. In such way, the user intentions are represented as empirical priors (hidden states) which the machine has to update through the accumulation of observations -the classifier output. Furthermore, the machine will act (flash) in such a way to achieve the desired outcome -to reveal the target letter in minimal time. Hence, by using these principles, we could not only achieve optimal stopping [START_REF] Mattout | Improving BCI performance through co-adaptation: applications to the P300-speller[END_REF] but also optimal flashing [START_REF] Mladenović | Endowing the Machine with Active Inference: A Generic Framework to Implement Adaptive BCI[END_REF], i.e., flashing such group of letters to maximize the P300 effect. The flashing would be in an intelligent order yet appear to the user to be in a random order, so that the oddball effect stays uncompromised.

The criteria of optimization, i.e., whether one would favor subjective user's experience over the system performance, depends on the purpose of the BCI system [START_REF] Mladenovic | A generic framework for adaptive EEGbased BCI training and operation[END_REF]. For example, for entertainment or rehabilitation purposes, it is important to motivate the user to keep playing or keep giving effort. To achieve this can be possible by using positively biased feedback. On the other hand, for controlling a wheelchair using a BCI, then the system's accuracy is of essential importance. Active Inference could provide such adaptive power, setting the BCI goals within an intelligent artificial agent which would encode the utility function, and would manipulate the exploration/exploitation factor, see Fig. 1.

The remaining challenges comprise using Active Inference to adapt tasks of other BCI paradigms such as Motor Imagery. The ultimate goal would be to use Active Inference to create a fully adaptive and user customizable BCI. In this case, the hidden states which the machine needs to infer and learn would be more than trial-wise user intentions, but also user's states, skills and traits (measured with passive BCI for instance) and provided to the machine as additional (neuro)physiological observations. The convenience about Active Inference is that it is applicable to any adaptive system. So, we can use any information as input (higher level user observations) and tune the parameters (priors) to each user, in order to provide them with optimal tasks. tive BCI. The machine "observes" one or several (neuro)physiological measurements which serve to infer the user's immediate intentions, or states, skills and traits in longer periods of time. Depending on the purpose of the BCI, its paradigm and exercise, and considering the information the machine learned about the user, it will provide optimal action (feedback or instructions in different modalities or difficulty). An intelligent agent will encode the priors (utility and exploration/exploitation ratio) that are regulated for each user and specific context; favoring the optimal paradigm, exercise and action within specific time-scales of adaptation.

The optimal tasks would be governed by the BCI purpose (control, communication, neuro-rehabilitation etc.), paradigm (P300, MI, SSEP) and exercise (MI of hands, feet, or counting the number of flashes etc).

Regarding signal processing, the adaptive processes which arise such as adapting spatial or temporal filters should not only adjust to the signal variabilities, but be also guided by the context and purpose of the BCI. This way, the signal processing techniques could extend their adaptive power and be more applicable and flexible across contexts and users. Furthermore, the signal processing pipeline would need to expand and include other possible (neuro)physiological measurements in order to measure high level user factors. The machine learning techniques will have to accommodate for more dimensions, not only the features extracted from EEG but the variable states of the user should be taken into account. Active inference would fit this landscape and add such a layer through an internal model of the various causes of signal variability and by its single cost function -free energy.

Improving BCI user training

Machine learning and signal processing tools can also be used to deepen our understanding of BCI user learning as well as to improve this learning. Notably, such tools can be used to design features and classifiers that are not only good to discriminate the different BCI commands, but also good to ensure that the user can understand and learn from the feedback resulting for this classifier/features. This feedback can also be further improved by using signal processing tools to preprocess it, in order to design an optimal display for this feedback, maximizing learning. Finally, rather than designing adaptive BCI algorithms solely to increase BCI command decoding accuracy, it seems also promising to adapt BCI algorithms in a way and at a rate that favor user learning. Altogether, current signal processing and machine learning algorithms should not be designed solely for the machine, but also with the user in mind, to ensure that the resulting feedback and training enable the user to learn efficiently. We detail these aspects below.

Designing features and classifiers that the user can understand and learn from

So far the features, e.g., the power in some frequency bands and channels, and classifiers, e.g., LDA or Support Vector Machine (SVM), used to design EEG-based BCI are optimized based solely on the basis of their discriminative power [START_REF] Lotte | A Review of classification algorithms for EEG-based Brain-Computer Interfaces[END_REF][START_REF] Blankertz | Optimizing spatial filters for robust EEG single-trial analysis[END_REF][START_REF]A Tutorial on EEG Signal-processing Techniques for Mental-state Recognition in Brain-Computer Interfaces[END_REF]. In other words, features and classifiers are built solely to maximize the separation between the classes/mental imagery tasks used to control the BCI, e.g., left versus right hand imagined movement. Thus, a purely machine-oriented criteria -namely data separation -is used to optimize features and classifiers, without any consideration for whether such features and classifiers lead to a feedback that 1) is understandable by the user and 2) can enable the user to learn to self-regulate those features. In the algorithms used so far, while the features are by design as separable as possible, there is no guarantee that they can become more separable with training. Actually, it is theoretically possible that some features with an initially lower discriminative power can be easier to learn to self-regulate. As such, while on the short-term selecting features that are initially as discriminant as possible makes sense, on the longer-term, if the user can learn EEG self-regulation successfully, then it may make more sense to select features that will lead to a possibly even better discrimination after user learning. Similarly, while the classifier output, e.g., the distance between the input feature vector and the LDA/SVM discriminant hyperplane [START_REF] Pfurtscheller | Motor Imagery and Direct Brain-Computer Communication[END_REF], is typically used as feedback to the user, it is also unknown whether such feedback signal variations can be understood or make sense for the user. Maybe a different feedback signal, possibly less discriminant, would be easier to understand and learn to control by the user. Interestingly enough, there are very relevant research results from neuroscience, psychology and human-computer interaction that suggest that there are some constraints and principles that need to be respected so as to favor user learning of selfregulation, or to enable users to understand as best as possible some visualization and feedback. In particular, it was shown with motor related invasive BCIs on monkeys, that using features that lie in the natural subspace of their motor-related activity, i.e., in their natural motor repertoire, leads to much more efficient learning of BCI control than using features that lie outside this subspace/natural repertoire [START_REF] Sadtler | Neural constraints on learning[END_REF][START_REF] Hwang | Volitional control of neural activity relies on the natural motor repertoire[END_REF]. This suggests that not all features have the same user-learning potential, and thus that features should be designed with such considerations in mind. Similarly, regarding feedback and visualization, humans perceive with more or less ease variations of a visual stimuli, depending on the spatial and temporal characteristics of these variations, e.g., how fast the stimuli changes, and what the amplitude of this change is, see, e.g., [START_REF] Ware | Information visualization: perception for design[END_REF] for an overview. For instance, it is recommended to provide visualizations that are consistent over time, i.e., whose meaning should be interpreted in the same way from one trial to the next, and that vary smoothly over time [START_REF] Ware | Information visualization: perception for design[END_REF]. This as well suggests that the feedback should ideally be designed while taking such principles into consideration. There are also many other human learning principles that are in general not respected by current BCI designs, see notably [START_REF] Lotte | Flaws in current human training protocols for spontaneous Brain-Computer Interfaces: lessons learned from instructional design[END_REF] as well as section 1.3.3. There is thus a lot of room for improvement.

The learning and feedback principles mentioned above could be used as constraints into the objective functions of machine learning and signal processing algorithms used in BCI. For instance, to respect human perception principles [START_REF] Ware | Information visualization: perception for design[END_REF], we could add these perception properties as regularization terms in regularized machine learning algorithms such as regularized spatial filters [START_REF] Lotte | Regularizing Common Spatial Patterns to Improve BCI Designs: Unified Theory and New Algorithms[END_REF] or classifiers [START_REF] Lotte | A Review of classification algorithms for EEG-based Brain-Computer Interfaces[END_REF][START_REF] Lotte | A Review of Classification Algorithms for EEG-based Brain-Computer Interfaces: A 10-year Update[END_REF]. Similarly, regularization terms could be added to ensure that the features/classifier lie in the natural motor repertoire of the user, to promote efficient learning with motorrelated BCIs. This could be achieved for instance, by transferring data between users [START_REF] Lotte | Learning from other Subjects Helps Reducing Brain-Computer Interface Calibration Time[END_REF][START_REF]Signal Processing Approaches to Minimize or Suppress Calibration Time in Oscillatory Activity-Based Brain-Computer Interfaces[END_REF], to promote features that were shown to lead to efficient learning in other users. In other words, rather than designing features/classifiers using objective functions that reflect only discrimination, such objective functions should consider both discrimination and human learning/perception principles. This would ensure the design of both discriminative and learnable/understandable features.

It could also be interesting to explore the extraction and possibly simultaneous use of two types of features: features that will be used for visualization and feedback only (and thus that may not be optimal from a classification point of view), and features that will be used by the machine to recognize the EEG patterns produced by the user (but not used as user training feedback). To ensure that such features are related, and thus that learning to modulate them is also relevant to send mental commands, they could be optimized and extracted jointly, e.g., using multi-task learning [START_REF] Caruana | Multitask learning[END_REF].

Identifying when to update classifiers to enhance learning

It is already well accepted that in order to obtain better performances, adaptive BCI systems should be used [START_REF] Millán | Asynchronous BCI and Local Neural Classifiers: An Overview of the Adaptive Brain Interface Project[END_REF][START_REF] Shenoy | Towards adaptive classification for BCI[END_REF][START_REF] Mladenovic | A generic framework for adaptive EEGbased BCI training and operation[END_REF]. Due to the inherent variability of EEG signals, as well as to the change in users' states, e.g., fatigue or attention, it was indeed shown that adaptive classifiers and features generally gave higher classification accuracy than fixed ones [START_REF] Shenoy | Towards adaptive classification for BCI[END_REF][START_REF] Mladenovic | A generic framework for adaptive EEGbased BCI training and operation[END_REF]. Typically, this adaptation consists in re-estimating parameters of the classifiers/features during online BCI use, in order to keep track of the changing features distribution. However, again, such adaptation is typically performed only from a machine perspective to maximize data discriminability, without considering the user in the loop. The user is using the classifier output as feedback to learn and to use the BCI. If the classifier is continuously adapted, this means the feedback is changing continuously, which can be very confusing for the user, or even prevent them from learning properly. Indeed, both the user and the machine need to adapt to each other -the so-called co-adaptation in BCI [START_REF] Vidaurre | Machine-learning-based coadaptive calibration for brain-computer interfaces[END_REF]. A very recent and interesting work proposed a simple computational model to represent this interplay between the user learning and the machine learning, and how this co-adaptation takes place [START_REF] Müller | A mathematical model for the two-learners problem[END_REF]. While such work is only a simulation, it has nonetheless suggested that an adaptation speed that is either too fast or too slow prevents this co-adaptation from converging, and leads to a decreased learning and performance.

Therefore, when to adapt, e.g., how often, and how to adapt, e.g., how much, should be made with the user in mind. Ideally, the adaptation should be performed at a rate and strength that suits each specific user, to ensure that it does not confuse users but rather that it helps them to learn. To do so seems to stress once more the need for a model of the user (discussed in Section 1.2). such model would infer from the data, among other, how much change the user can deal with, to adapt the classifier accordingly. In this model, being able to measure the users' BCI skills (see also Section 1.2.2) would also help in that regard. It would indeed enable to know when the classifier should be updated because the user had improved and thus their EEG patterns have changed. It would also be interesting to quantify which variations in the EEG feature distribution would require an adaptation that may be confusing to the user -e.g., those changing the EEG source used -and those that should not be -e.g., just tracking change in feature amplitude. This would enable to perform only adaptation that is as harmless as possible for the user. A point that would need to be explored is whether classifiers and features should only be adapted when the user actually changes strategy, e.g., when the user has learned a better mental imagery task. This indeed requires the classifier to be able to recognize such new or improved mental tasks, whether other adaptations may just add some feedback noise and would be confusing to the user.

Designing BCI feedbacks ensuring learning

Feedback is generally considered as an important facilitator of learning and skill acquisition [START_REF] Azevedo | A meta-analysis of the effects of feedback in computer-based instruction[END_REF][START_REF] Bangert-Drowns | The instructional effect of feedback in test-like events[END_REF] with a specific effect on the motivation to learn, see e.g., [START_REF] Narciss | How to design informative tutoring feedback for multimedia learning. Instructional design for multimedia learning[END_REF].

Black and William [START_REF] Black | Assessment and classroom learning. Assessment in Education: principles, policy & practice[END_REF] proposed that to be effective, feedback must be directive (indicate what needs to be revised) and facilitative (provides suggestions to guide learners). In the same way, Kulhavy and Stock proposed that effective feedback must allow verification, i.e., specify if the answer is correct or incorrect and elaboration, i.e., provide relevant cues to guide the learner) [START_REF] Kulhavy | Feedback in written instruction: The place of response certitude[END_REF].

In addition to guidance, informative feedback had to be goal-directed by providing learners with information about their progress toward the goal to be achieved. The feeling that the goal can be met is an important way to enhance the motivation and the engagement of the learners [START_REF] Fisher | Differential effects of learner effort and goal orientation on two learning outcomes[END_REF].

Feedback should also be specific to avoid being considered as useless or frustrating [START_REF] Williams | Teachers' Written Comments and Students' Responses: A Socially Constructed Interaction[END_REF]. It needs to be clear, purposeful, meaningful [START_REF] Hattie | The Power of Feedback[END_REF] and to lead to a feeling of competence in order to increase motivation [START_REF] Ryan | Self-determination theory and the facilitation of intrinsic motivation, social development, and well-being[END_REF].

Another consideration that requires to be much more deeply explored is that feedback must be adapted to the characteristics of the learners. For example, [START_REF] Hanna | Effects of total and partial feedback in multiple-choice testing upon learning[END_REF] showed that elaborated feedback enhances performances of low-ability students, while verification condition enhance performances of high-ability students. In the BCI field, Kübler et al. showed that positive feedback (provided only for a correct response) was beneficial for new or inexperienced BCI users, but harmful for advanced BCI users [START_REF] Kübler | Brain-computer communication: self-regulation of slow cortical potentials for verbal communication[END_REF].

As underlined in [START_REF] Lotte | Flaws in current human training protocols for spontaneous Brain-Computer Interfaces: lessons learned from instructional design[END_REF], classical BCI feedback satisfies few of such requirements. Feedback typically specifies if the answer is correct or not -i.e., the feedback is corrective -but does not aim at providing suggestions to guide the learner -i.e., it is not explanatory. Feedback is also usually not goal directed and does not provide details about how to improve the answer. Moreover, the feedback may often be unclear and meaningless, since it is based on a classifier build using calibration data recorded at the beginning of the session, during which the user does not master the mental imagery task they must perform.

In [START_REF] Lotte | Flaws in current human training protocols for spontaneous Brain-Computer Interfaces: lessons learned from instructional design[END_REF], we discussed the limits of feedback used in BCI, and proposed solutions, some of which having already yielded positive results [START_REF] Hwang | Neurofeedback-based motor imagery training for brain-computer interface (BCI)[END_REF][START_REF] Pfurtscheller | Motor Imagery and Direct Brain-Computer Communication[END_REF]. A possibility would be to provide the user with richer and more informative feedback by using, for example, a global picture of his/her brain activity, eg., a 2D or 3D topography of cortical activation obtained by inverse solutions. Another proposal is to collect a better information on the mental task achieved by the subject (for example by recording Event Related Desynchonisation/Synchronisation activity) to evaluate users' progress and give them relevant insights about how to perform the mental task. Finally, it would be relevant to use more attractive feedback by using game-like, 3D or Virtual Reality, thus increasing user engagement and motivation [START_REF] Lécuyer | Brain-Computer Interfaces, Virtual Reality and Videogames[END_REF][START_REF] Leeb | Brain-Computer Communication: Motivation, aim and impact of exploring a virtual apartment[END_REF].

In a recent study, [START_REF] Jeunet | Continuous Tactile Feedback for Motor-Imagery based Brain-Computer Interaction in a Multitasking Context[END_REF] tested a continuous tactile feedback by comparing it to an equivalent visual feedback. Performance was higher with tactile feedback indicating that this modality can be a promising way to enhance BCI performances.

To conclude, the feedbacks used in BCI are simple and often poorly informative, which may explain some of the learning difficulties encountered by many users. Based on the literature identifying the parameters that maximize the effectiveness of feedback in general, BCI studies have already identified possible theoretical improvements. However, further investigations will be necessary to explore new research directions in order to make BCI accessible to a greater number of people. In particular, the machine learning and signal processing communities have the skills and tools necessary to design BCI feedback that are clearer, adaptive and adapted to the user, more informative and explanatory. In the following we provide more details on some of these aspects. In particular, we discuss the importance to design adaptive biased feedback, emotional and explanatory feedback, and provide related research directions in which the machine learning and signal processing communities can contribute.

Designing adaptive biased feedback

As stated earlier in this chapter, it is essential to compute and understand the user's emotional, motivational and cognitive states in order to provide them with an appropriate, adapted and adaptive feedback that will favor the acquisition of skills especially during the primary training phases of the user [START_REF] Mcfarland | EEG-based communication and control: short-term role of feedback[END_REF]. Indeed, in the first stages, the fact that the technology and the interaction paradigm (through MI tasks) are both new for the users is likely to induce a pronounced computer anxiety associated with a low sense of agency. Yet, given the strong impact that the sense of agency (i.e., the feeling of being in control) has on performance -see Section 1.2.3.1 -it seems important to increase it as far as possible. Providing the users with a sensory feedback informing them about the outcome of their action (MI task) seems to be necessary in order to trigger a certain sense of agency at the beginning of their training. This sense of agency will in turn unconsciously encourage users to persevere, increase their motivation, and thus promote the acquisition of MI-BCI related skills, which is likely to lead to better performances [START_REF] Achim | Computer usage: the impact of computer anxiety and computer self-efficacy[END_REF][START_REF] Saadé | Computer anxiety in e-learning: The effect of computer self-efficacy[END_REF][START_REF] Simsek | The relationship between computer anxiety and computer selfefficacy[END_REF]. This process could underlie the (experimentally proven) efficiency of positively biased feedback for MI-BCI user-training.

Positively biased feedback consists in leading users to believe that their performance was better than it actually was. Literature [START_REF] Barbero | Biased feedback in brain-computer interfaces[END_REF][START_REF] Kübler | Brain-computer communication: self-regulation of slow cortical potentials for verbal communication[END_REF] reports that providing MI-BCI users with a biased (only positive) feedback is associated with improved performances while they are novices. However, that is no longer the case once they have progressed to the level of expert users. This result could be due to the fact that positive feedback provides users with an illusion of control which increases their motivation and will to succeed. As explained by [START_REF] Achim | Computer usage: the impact of computer anxiety and computer self-efficacy[END_REF], once users reach a higher level of performance, they also experience a high level of self-efficacy which leads them to consider failure no longer as a threat [START_REF] Kleih | Motivation and SMR-BCI: fear of failure affects BCI performance[END_REF] but as a challenge. And facing these challenges leads to improvement. Another explanation is the fact that experts develop the ability to generate a precise predicted outcome that usually matches the actual outcome (when the feedback is not biased). This could explain why when the feedback is biased, and therefore the predicted and actual outcomes do not match, expert users attribute the discrepancy to external causes more easily. In other words, it can be hypothesized that experts might be disturbed by a biased feedback because they can perceive that it does not truly reflect their actions, thus decreasing their sense of being in control.

To summarize, it is noteworthy that the experience level of the user needs to be taken into account when designing the optimal feedback system, and more specifically the bias level. As discussed before, the user experience is nonetheless difficult to assess (see also Section 1.2.2). For instance, when using LDA to discriminate 2 classes, the LDA will typically always output a class, even if it is uncertain about it. This might lead to a class seemingly always recognized, even if the user does not do much. Hence, if both classes are equally biased, the user would most likely not gain motivation for the one always recognized -performing good, but could feel bored. Note that even if one class is always recognized (seemingly giving higher performances than the other class) that does not mean that the user is actually performing well when imagining such class, it can be due to the classifier being unbalanced and providing as output this class more often (e.g., due to a faulty electrode). On the other hand, if the biased feedback is applied to the class which is not well recognized the user would probably gain motivation. Thus, in [START_REF] Mladenović | The Impact of Flow in an EEG-based Brain Computer Interface[END_REF] the task was adaptively biased, depending on the user performances in real time, e.g., positively for the class which was recognized less often, and negatively for the one recognized more often, in order to keep the user engaged. This idea came from the Flow theory [START_REF] Csikszentmihalyi | Toward a psychology of optimal experience[END_REF] which explains that the intrinsic motivation, full immersion in the task and concentration can be attained if the task is adapted to user skills. Following the requirements of Flow theory, in [START_REF] Mladenović | The Impact of Flow in an EEG-based Brain Computer Interface[END_REF] the environment is designed to be engaging and entertaining, the goals clear with immediate visual and audio feedback, and task difficulty adapted to user performance in real-time. It is shown that the users feel more in control, and more in flow when the task is adapted. Additionally, the offline performance and flow level correlated. This suggests that adapting the task may create a virtuous loop, potentially increasing flow with performance.

The approach of providing an adapted and adaptive feedback, obtained by modulating the bias level, sounds very promising in order to maintain BCI users in a flow state, with a high sense of agency. Nonetheless, many challenges remain in order to optimize the efficiency of this approach. First, once more, it is necessary to be able to infer the state of the user, and especially their skill level, from their performance and physiological data. Second, we will have to determine the bias to be applied to the BCI output as a function of the evolution of the users' skills, but also as a function of their profile. Indeed, the basic level of sense of agency is not the same for everybody. Also, as shown in our models [START_REF] Jeunet | Towards a cognitive model of MI-BCI user training[END_REF][START_REF] Mladenovic | A generic framework for adaptive EEGbased BCI training and operation[END_REF], both the sense of agency and the flow are influenced by several factors: they do not depend only upon the performance. Thus, many parameters -related to users' states and traits -should be taken into account to know how to adapt the bias.

Designing adaptive emotional feedback

The functioning of the brain has often been compared to that of a computer, which is probably why the social and emotional components of learning have long been ignored. However, emotional and social contexts play an important role in learning [START_REF] Johnson | An educational psychology success story: Social interdependence theory and cooperative learning[END_REF][START_REF] Salancik | A social information processing approach to job attitudes and task design[END_REF]. The learner's affective state has an influence on problem solving strategies [START_REF] Isen | Positive Affect and Decision Making, Handbook of emotions[END_REF], and motivational outcome [START_REF] Stipek | Motivation to learn: From theory to practice[END_REF]. Expert teachers can detect such emotional states and react accordingly to the latter to positively impact learning [START_REF] Goleman | Emotional Intelligence[END_REF]. However, the majority of feedback used for BCI training users typically do not benefit from adaptive social and emotional feedback during BCI training. In [START_REF] Bonnet | Two brains, one game: design and evaluation of a multiuser BCI video game based on motor imagery[END_REF], we added some social context to BCI training by creating a game where BCI users had to compete or collaborate against or with each others, which resulted in improved motivation and better BCI performances for some of the participants. Other studies tried to provide a non adaptive emotional feedback, under the form of smileys indicating whether the mental command was successfully recognized [START_REF] Kübler | Brain-computer communication: self-regulation of slow cortical potentials for verbal communication[END_REF][START_REF] Leeb | Brain-Computer Communication: Motivation, aim and impact of exploring a virtual apartment[END_REF]. No formal comparisons without such emotional feedback was performed though, making the efficiency of such feedback still unknown. Intelligent tutoring Systems (ITS) providing an emotional and motivational support can be considered as a substitute and have been used in distant learning protocols where such feedback components were also missing. Indeed, they have proven to be successful in improving learning, self-confidence and affective outcome [START_REF] Woolf | Affective tutors: Automatic detection of and response to student emotion[END_REF]. We tested such method for BCI in [START_REF] Pillette | PEANUT: Personalised Emotional Agent for Neurotechnology User-Training[END_REF], where we implemented a learning companion for BCI training purpose. The companion provided both an adapted emotional support and social presence. Its interventions were composed of spoken sentences and facial expressions adapted based on the performance and progress of the user. Results show that emotional support and social presence have a beneficial impact on users' experience. Indeed, users that trained with the learning companion felt it was easier to learn and memorize than the group that only trained with the usual training protocol (i.e., with no emotional support or social presence). This learning companion did not lead to any significant increase in online classification performance so far, though, which suggests that it should be further improved. It could for example consider the user's profile which influences BCI performances [START_REF] Jeunet | Predicting Mental Imagery-Based BCI Performance from Personality, Cognitive Profile and Neurophysiological Patterns[END_REF], and monitor the user's emotional state and learning phase [START_REF] Kort | An affective model of interplay between emotions and learning: Reengineering educational pedagogy-building a learning companion[END_REF]. Indeed, both social and emotional feedback can have a positive, neutral or negative influence on learning depending on the task design, the type of feedback provided and the variables taken into account to provide the feedback [START_REF] Kennedy | The robot who tried too hard: Social behaviour of a robot tutor can negatively affect child learning[END_REF][START_REF] Johnson | An educational psychology success story: Social interdependence theory and cooperative learning[END_REF]. In this context, machine learning could have a substantial impact for the future applications of ITS in BCI training applications. In particular, it seems promising to use machine learning to learn from the students EEG, reactions and from its previous experience, what is the most appropriate emotional feedback it should provide to the user.

Designing explanatory feedback

As mentioned above, in many learning tasks -BCI included -the role of the feedback has been found to be essential in supporting learning, and to make this learning efficient [START_REF] Shute | Focus on Formative Feedback[END_REF][START_REF] Hattie | The Power of Feedback[END_REF]. While feedbacks can be of several types, for BCI training, this feedback is almost always corrective only [START_REF] Lotte | Flaws in current human training protocols for spontaneous Brain-Computer Interfaces: lessons learned from instructional design[END_REF]. A corrective feedback is a feedback that tells the user whether the task they just performed is correct or incorrect. Indeed, in most BCIs, the feedback is typically a bar or a cursor indicating whether the mental task performed by the user was correctly recognized. Unfortunately human learning theories and instructional design principles all recommend to provide a feedback that is explanatory, i.e., which does not only indicate correctness, but also why it was correct or not. Indeed, across many learning tasks, explanatory feedback, which thus explains the reasons of the feedback, was shown to be superior to corrective one [START_REF] Shute | Focus on Formative Feedback[END_REF][START_REF] Hattie | The Power of Feedback[END_REF].

Consequently, it would be promising to try to design explanatory feedback for BCI. This is nonetheless a substantial challenge. Indeed, being able to provide explanatory feedback means being able to understand the cause of success or failure of a given mental command. so far, the BCI community has very little knowledge about these possible causes. Some works did identify some predictors of BCI performances [START_REF] Jeunet | Advances in user-training for mental-imagerybased BCI control: Psychological and cognitive factors and their neural correlates[END_REF][START_REF] Ahn | Performance variation in motor imagery brain-computer interface: A brief review[END_REF][START_REF] Grosse-Wentrup | What are the Causes of Performance Variation in Brain-Computer Interfacing[END_REF][START_REF] Blankertz | Neurophysiological predictor of SMR-based BCI performance[END_REF]. However, most of these works identified predictors of performance variations across many trials and possibly many runs or sessions. Exceptions are [START_REF] Grosse-Wentrup | Causal Influence of Gamma Oscillations on the Sensorimotor Rhythm[END_REF] and [START_REF] Schumacher | Towards explanatory feedback for user training in brain-computer interfaces[END_REF], who showed respectively than cortical gamma activity in attentional networks as well as tension in forehead and neck muscles were correlated to single trial performances. In [START_REF] Schumacher | Towards explanatory feedback for user training in brain-computer interfaces[END_REF] we designed a first explanatory feedback for BCI, informing users of their forehead and neck muscle tension, identifying when it was too strong, to guide them to be relaxed. Unfortunately this did not lead to significant increase in online BCI performance. Such work was however only a preliminary attempt that should thus be explored further, to identify new predictors of single trial performance, and use them as feedback.

We denote features measuring causes of success or failure of a trial or group of trials as feedback features. We thus encourage the feedback community to design and explore new feedback features. This is another machine learning and signal processing problem, in which rather than classifying EEG as corresponding to a given mental command or another, we should classify them as predicting a successful or a failed trial. Thus with different labels than before, machine learners can explore and design various tools to identify the most predictive feedback features. Such features could then be used as additional feedback during online BCI experiments, possibly supporting efficient BCI skills learning.

Conclusion

In this chapter, we tried to highlight to our readers that when designing Brain-Computer Interfaces, both the machine (EEG signal decoding) and the user (BCI skill learning and performance) should be taken into account. Actually, in order to really enable BCIs to reach their full potential, both aspects should be explored and improved. So far, the vast majority of the machine learning community has worked on improving and robustifying the EEG signal decoding, without considering the human in the loop. Here, we hope we convinced our readers that considering the human user is necessary -notably to guide and boost BCI user training and performanceand that machine learning and signal processing can bring useful and innovative solutions to do so. In particular, throughout the chapter we identified 9 challenges that would need to be solved to enable users to use and to learn to use BCI efficiently, and for each suggested potential machine learning and signal processing research directions to address them. These various challenges and solutions are summarized in Table 1.1.

We hope this summary of open research problems in BCI will inspire the machine learning and signal processing communities, and will motivate their scientists to explore these less traveled but essential research directions. In the end, BCI research does need contributions from these communities to improve the user experience and learnability of BCI, and enable them to become finally usable and useful in practice, outside laboratories.

Figure 1 . 1 :

 11 Figure 1.1: A concept of how Active Inference could be used to implement a fully adap-

Table 1 .

 1 1: Summary of signal processing and machine learning challenges to BCI user training and experience, and potential solutions to be explored.

		Challenges	Potential solutions
	Modelling the BCI user	Robust recognition of users' mental states from physiological signals	exploring features, denoising and classification algorithms for each mental state
		Quantifying the	Riemannian geometry
		many aspects of	to go beyond
		users' BCI skills	classification accuracy
		Determining when to adapt the training procedure, based on the user's state, to optimise performance and learning	Case-based / Rule-based reasoning algorithms; Multi-arm bandits to adapt automatically the training procedure
		Computationally modeling the users states and traits and adaptation tools	Exploiting Active Inference tools
	Understanding and improving BCI user learning	Designing features and classifiers resulting in feedback favoring learning	Regularizers incorporating human learning and perception principles
		Adapting classifiers	Triggering adaptation
		with a way and timing	based on a
		favoring learning	user's model
		Adapting the bias based on the user's level of skills to maintain their flow and agency	Triggering adaptation based on a model of the bias*skill relationship
		Adapting feedback
		to include	Build on the existing
		emotional support	work of the ITS field
		and social presence
		Identifying/Designing	Designing features
		explanatory	to classify correct
		feedback features	vs incorrect commands

Acknowledgments

This work was supported by the French National Research Agency with the REBEL project (grant ANR-15-CE23-0013-01), the European Research Council with the BrainConquest project (grant ERC-2016-STG-714567), the Inria Project-Lab BCI-LIFT and the EPFL/Inria International lab.