## 6 Discussion  
In the presented research, we considered the task detection problem, which is a multiclass classification problem. Given the dataset [19] containing Python programs solving tasks of different types, the classifiers are trained to find the type of the task that a program solves (see Section 3). The classification algorithms considered in this study are KNN, SVM, RF, and MLP. These algorithms take vectors as their input, so we perform a preliminary transform of the source codes of programs into vector-based representations. We consider approaches to source code embedding into vector space such as the token-based word2 vec model [39], the token and AST-based code2 vec model [9], AST-based Markov chains [15; 16] of order 1 and 2, histograms of assembly language instruction opcodes [18; 28], and histograms of AST node types. The approaches are discussed in detail in Section 4. Aiming to determine how the size of the dataset and the selected approach to source code embedding into vector space influence the cross-validated _Accuracy_ (13), _Precision_ (14), _Recall_ (15), and _F1 Score_ (16) of classification algorithms such as KNN, SVM, RF, and MLP (RQ1), we conducted the numerical experiments using the experimental setup and methodology as described in Section 5.1. The results are provided and discussed in Section 5.2. Overall, we reached the following conclusions:  
* Simple AST-based or bytecode-based representations of programs such as Markov chains and histograms outperform complex neural network-based embeddings with many hyperparameters in the considered task detection problem, especially when the amount of training data is limited (see Figures 15-17). * Embeddings of programs that are based on either AST or bytecode outperform token-based embeddings on small-sized datasets; however, with the increase in the dataset size, the difference in the quality of classifiers decreases and has the potential to vanish on larger datasets (see, for example, Figures 15 and 16). * Source code embeddings that are based on first-order Markov chains built for ASTs used with RF demonstrate the best classification quality in the sense of (13)-(16) (see Tables 4 and 5); the results were verified using the Wilcoxon signed rank statistical test (see Tables 6 and 7). * Increasing the order of AST-based Markov chains offers no noticeable improvement in classifier quality in the sense of (13)-(16), and can even lead to quality degradation in the case of KNN (see Figures 19 and 20); this makes AST-based Markov chains of order 1 most suitable for practical applications. Aiming to determine which of the considered approaches to program embedding is least sensitive to the used classification algorithm in the considered task detection problem (RQ2), we numerically assessed the sensitivity using (17) and cross-validated _Accuracy_ (13), _Precision_ (14), _Recall_ (15), and _F1 Score_ (16) of KNN, SVM, RF, and MLP. According to the results provided in Section 5.3, code2 vec and first-order AST-based Markov chains are the embeddings that are least sensitive to the used classifier on a small dataset containing 100 programs, whereas word2 vec and first-order AST-based Markov chains are the embeddings that are least sensitive to the used classifier on a dataset containing 1000 programs. Overall, first-order AST-based Markov chains are program embeddings that are least sensitive to the used classifier. Higher-order Markov chains show worse results in the sense of (17) when compared to simple first-order AST-based Markov chains. Algorithms 1 and 2, which are responsible for construction of Markov chains of any order, have limitations, as they only support the Python programming language and construct program ASTs using the Python standard library [41]; this also applies to Algorithm 4.