## 3 Method
### Model Architecture  
The AraConv model's generation process is based on a single multi-lingual Seq2 Seq (mSeq2 Seq) model that uses the pre-trained model mT5 [5], a multilingual variant of T5 [57], which can be formally defined as follows:  
Assume the dialogue D represents a set of user utterances (Ut) and system utterances (St) at turn t, where D = {U\({}_{1}\), S\({}_{1}\), \(\ldots\), U\({}_{t}\), S\({}_{t}\)}.  
The dialogue history (H) holds the previous user and system utterances of turn t, specified by the context window size (w), where H\({}_{t}\) = {U\({}_{t-w}\), S\({}_{t-w}\), \(\ldots\), S\({}_{t-1}\); U\({}_{t}\)}. For turn t, the dialogue state is represented as B\({}_{t}\), and the knowledge state is represented as K\({}_{t}\).  
Figure 2 illustrates the proposed workflow for response generation using the mSeq2 Seq model based on the BiToD dataset [1].  
Initially, we set the dialogue state and knowledge state to empty strings as B\({}_{0}\) and K\({}_{0}\). Then, we considered the current dialogue history (H\({}_{t}\)), previous dialogue state (B\({}_{t-1}\)), and previous knowledge state (K\({}_{t-1}\)) as input at turn t. We added the prompt PB = \"TrackDialogueState:\" to indicate the generation task [57]. Therefore, the mSeq2 Seq model produces Levenshtein Belief Spans at turn t (Levt), indicating a text span that contains the information for updating the dialogue state from (B\({}_{t-1}\)) to B\({}_{t}\). Levt can be represented by the following equation:  
\[\text{Lev}_{t}=\text{ mSeq2 Seq(PB, H}_{t},\text{ B}_{t-1},\text{ K}_{t-1}) \tag{1}\]  
\begin{table}
\begin{tabular}{c c c c c c c} \hline \hline
**Dataset** & **Languages** & **Number of Dialogues** & **Avg. Turn Length** & **Number of Domains (Tasks)** & **Deterministic API** & **Mixed- Language Context** \\ \hline TM-1 & EN & 13,215 & 21.99 & 6 & No & No \\ \hline Schema & EN & 22,825 & 20.3 & 17 & No & No \\ \hline SGD & EN & 16,142 & 20.44 & 16 & No & No \\ \hline STAR & EN & 5820 & 21.71 & 13 & No & No \\ \hline Frames & EN & 1369 & 14.6 & 3 & No & No \\ \hline Multi-lingual & \multirow{2}{*}{EN, DE, IT} & \multirow{2}{*}{3600} & \multirow{2}{*}{–} & \multirow{2}{*}{1} & \multirow{2}{*}{No} & Yes \\ WOZ 2.0 & & & & & & \\ \hline
**Arabic-TOD** & AR & 1500 & 19.98 & 4 & Yes & Yes \\ \hline \hline \end{tabular}
\end{table}
Table 3: _Cont._Then, the model generates an output (o/p) based on the new input as the updated dialogue state (B\({}_{t}\)), and the response generation prompt--referred to as PR = \"Response:\" --at the current turn t. If there is a need for an API call, the model will generate an API name according to the following:  
\[\text{API}=\text{mSeq2 Seq}(\text{PR},\;\text{H}_{t},\;\text{B}_{t},\;\text{K}_{ t-1}) \tag{2}\]  
In this case, the system queries the API with particular constraints in the dialogue state and updates the knowledge state form (K\({}_{t-1}\)) to (K\({}_{t}\)). The updated knowledge state (K\({}_{t}\)) and API name (API) are subsequently combined to generate the next turn response. Otherwise, the model generates a textual response (R) that is returned directly to the user:  
\[\text{R}=\text{mSeq2 Seq}(\text{PR},\;\text{H}_{t},\;\text{B}_{t},\;\text{K}_{ t},\;\text{API}\;) \tag{3}\]