Research University - Warsaw University of Technology

Home » News »

Work on the application of the dialogic system in CBT therapy

Professor Artur Janicki uses artificial intelligence methods to support mental illness therapy. His project is carried out as part of a POB SzIR research grant.

The photo shows the Terabot and a patient.

Having successfully cooperated with the Institute of Psychiatry and Neurology (IPiN) in Warsaw in the therapy of voice hallucinations, Professor Artur Janicki decided to go a step further and translate the gained experience into the creation of a dialogic system for cognitive-behavioural therapy (CBT).

“In an earlier project, we used a computer avatar resembling a human being,” says Professor Janicki. “The avatar was controlled by a therapist-psychiatrist. Initially, the computer character duplicated negative sentences that the patient heard in their head, only to change them into those with positive overtones as the therapy continued. Patients responded very well to this type of therapy, as evidenced by the reduction in VPDS and PSYRATS-AH metrics in patients,” he explains.

Although the results of the research provided motivation for further actions, the beginnings were not easy. PW scientists were afraid of patients’ reactions to the computer avatar. These, however, turned out to be very positive and people undergoing therapy appreciated the use of this technology in treatment.

“This motivated us to continue the topic, but in a slightly different context. We wanted to help more people, so we chose a more common use,” says Professor Janicki.

For this purpose, the researchers developed a dialogic system called Terabot, which was piloted in CBT therapy. Unlike the previous project, this system is not controlled by a psychiatrist who triggers specific issues at the right moment. Terabot conducts a conversation with the patient, recognizing what the patient is saying and what their emotional state is. Depending on the answers provided, the system matches the dialogue with the patient. On the screen, Terabot has a human form of a doctor wearing a  mask, so it resembles a bit regular tele-advice.

After launching the system, Terabot starts a conversation with the patient, asking them how they are feeling. Then, depending on the answer, it moves on to exercises, which aim to teach the patient to recognize their emotions and reactions to them.

“The pilot version of Terabot includes three exercises that were developed by Izabela Stefaniak, MD, PhD, from the Institute of Psychiatry and Neurology, a CBT therapist specialising in psychiatry. The tasks focus on practising mindfulness,” explains Professor Janicki.

In order for the Terabot to communicate with the patient, the test bench is equipped with a computer, and microphone, and an eye tracker, i.e. a module that observes the work of the eyeballs. Although the project did not originally intend to do so, the researchers also want to analyse the results obtained from the eye tracker and perhaps use them in future work.

To cooperate with the patients, Professor Janicki’s research team conducted a number of tests on themselves. The most persistent tester was Karolina Gabor-Siatkowska, MSc, a doctoral student conducting work under the supervision of Professor Janicki. When the team decided that Terabot was ready to deal with patients, they submitted a request to the Bioethics Committee at IPiN for permission to conduct research, which was granted in spring  2022.

Patients aged 18 to 65 are evaluated. About 30 people have been assessed so far, but a little more is needed so the research is underway.

“It is the doctors from the Institute of Psychiatry and Neurology who qualify patients for our project. Selected patients are examined and then divided into two groups: one of them undergoes treatment with the Terabot dialogic system, and the other undergoes standard therapy. Later, the results of both groups are compared. The second group also undergoes treatment with Terabot to support their therapy, but we do it later and do not take the results into account,” says Professor Janicki.

Terabot received a positive reception from patients. So far, about 70% of those surveyed have said they liked talking to it. Some of them wanted to tell Terabot rather complicated stories, which posed quite a challenge for the system.

“It may seem that at a time when ChatGPT is breaking popularity records, our project should be expanded with support for more complex dialogues. However, it is intentional that Terabot does not work like generative large language models (LLMs), like ChatGPT, for instance, as the Bioethics Committee would not allow it. Why? Because then we would have no control over this kind of model. We would never know exactly what it would answer and it would not be possible to propose a therapeutic exercise according to the exact scenario, etc. In the therapy, we must have control over the system,” explains Professor Janicki.


The project “Terabot – a dialogue system for cognitive-behavioural therapy" is financed under the research grant of the "Excellence Initiative – Research University" programme, which is implemented at the Warsaw University of Technology.

Research team:

Professor Artur Janicki; Marek Kozłowski, PhD; Izabela Stefaniak (IPiN), MD, PhD; Artur Zygadło, MSc; Karolina Gabor-Siatkowska, MSc; Marcin Sowański, MSc; Rafał Rzatkiewicz, BSc; Adam Serodziński, BSc.