## 3 System Architecture  
The system is based on the architecture proposed by [2] (see Figure 1). The main improvement we made for the architecture was its extension with the NRG Barista (see Section 4) together with its integration within traditional dialogue trees; thus, a hybrid architecture was built. Barista is used for out-of-domain conversations and in our hybrid dialogues, where several nodes in a dialogue tree are generated dynamically by our NRG. Barista is a neural response generator designed for open-domain conversations that access external knowledge sources to provide knowledgeable responses. We utilize Barista in various conversational contexts, as described in Section 7. The invention of the hybrid architecture had several motivations:  
1. In the previous iteration of the Amazon Alexa Prize SocialBot Grand Challenge (4) ([[https://www.amazon.science/alexa-prize/socialbot-grand-challenge/2020](https://www.amazon.science/alexa-prize/socialbot-grand-challenge/2020)]([https://www.amazon.science/alexa-prize/socialbot-grand-challenge/2020](https://www.amazon.science/alexa-prize/socialbot-grand-challenge/2020)), accessed on 14 August 2021), the best-performing SocialBots were generally based on manually prepared dialogues with some ability in handling out-of-domain cases by a neural response generator. No SocialBot that was based entirely (or almost entirely) on large language models has been provided with an award (although some SocialBots have had this architecture, e.g., Genuine by [32]). 2. Furthermore, some of the current chatbots solely based on LLMs, such as Meena [33] or BlenderBot ([34; 35; 36; 37]), still have several qualitative problems [38; 37]. We assume that carefully designed dialogues (with consultation help from linguists from PrometheistAI ([[https://promethist.ai/](https://promethist.ai/)]([https://promethist.ai/](https://promethist.ai/)), accessed on 1 January 2022)) for most common topics (hobbies, movies, food, books, music, etc.) will perform better (in the particular domains) as the dialogues should produce sensible and even interesting engaging outputs. This is not guaranteed for general LLMs. Using only handcrafted dialogue trees poses huge limitations regarding generalization. Moreover, returning users might experience that conversations with such rule-based systems are (in longer periods) repetitive, which we assume would have a significant negative impact on the user experience. Incorporating our Barista NRG allows our SocialBot to converse about any topic. Furthermore, hybrid dialogues ensure within-dialogue variability. Hence, the ratio behind the architecture choice is to combine the advantages of traditional rule-based chatbots with the advantages of LLM-based conversational systems. From the dialogue design perspective, the main building block of the proposed SocialBot is the _main dialogue_. Within the main dialogue, we have a collection of dialogue groups composed of multiple dialogues. Each group is dedicated to a specific topic, such as sports, movies, or music. This design allows our SocialBot to engage in conversations about a wide range of subjects, providing a comprehensive and diverse user experience. Furthermore, each dialogue follows a tree graph structure. This means that we have the flexibility to specify a conversational flow, defining how the system should respond to different user utterances. By organizing the dialogue in this structured manner, we can ensure a coherent and intuitive conversation experience for the users. In order to effectively understand user utterances, we followed the practice established by [2]. We classified every utterance into an in-domain or out-of-domain intent. In-domain intents are designed to handle user utterances that are anticipated within the context of the dialogue.