# AgriEnt: A Knowledge-Based Web Platform for Managing Insect Pests of Field Crops
## 4 Case Study: Diagnosing the Insect Pest Affecting a Crop
### Results and Discussion  
The rule-based inference engine allows AgriEnt to analyze crop symptoms collected by farmers aiming to contribute to the insect pest diagnosis and their management. The set of crop symptoms used in this case study were analyzed to gain insight into the main causes of incorrect diagnosis performed by the inference engine. The obtained results and the findings and recommendations of the evaluation are below described.  
Table 5 presents the results obtained by AgriEnt concerning the diagnosis of crop insect pests. On average, AgriEnt obtained a 0.8221 score of accuracy in the reasoning of crop insect pest diagnosis, thus producing correct diagnosis in 123 test cases for all crops considered in this version. As can be noted, there is no big difference between the accuracy scores obtained for all crops considered in this case study. The accuracy scores range from 0.7857 to 0.875, specifically, the AgriEnt platform obtained the highest accuracy score (0.875) diagnosing insect pests that affect corn crops. On the other hand, this platform obtained the lowest accuracy score (0.7857) for insect pests affecting rice crops.  
As can be noted from Table 5, a similar diagnosis was performed by both the group of professionals and the inference engine implemented in AgriEnt. However, this platform could not provide a correct diagnostic in 26 test cases thereafter due to the following facts:  
* Most of the insect pest cases (11 test cases) were incorrectly diagnosed since farmers provided a small number of symptoms, which were not enough to determine the correct insect pest. Regarding this fact, most of these cases were related to the lack of experience of farmers in collecting sufficient crop symptoms.
* The remaining incorrect diagnosis cases were due to incorrect reasoning done by the rule-based inference engine. Once these cases were analyzed, we found that the incorrect reasoning occurs due to rules inconsistency that happens when several crop insect pests have symptoms in common. Regarding this issue, we are planning to add a symptom ranking mechanism i.e., when two or more crop insect pests share a symptom, this mechanism will allow to select the pest whose symptoms in common have a higher rank. The implementation of this mechanism will require the agreement of entomology experts.  
\begin{table}
\begin{tabular}{c c c c c} \hline \hline
**Test** & **Crop** & **Test Cases** & **Correct Test Cases** & **Accuracy** \\ \hline
1 & Sugar & 24 & 20 & 0.8333 \\
2 & Cocoa & 19 & 15 & 0.7894 \\
3 & Corn & 32 & 28 & 0.875 \\
4 & Rice & 28 & 22 & 0.7857 \\
5 & Banana & 25 & 21 & 0.84 \\
6 & Soya & 21 & 17 & 0.8095 \\ Total & & 149 & 123 & 0.8221 (Avg.) \\ \hline \hline \end{tabular}
\end{table}
Table 5: Test results—diagnosis of crop insect pests.  
We know that the current version of AgriEnt is not able to deal with crop insect pests other than those used in the case study presented above. This fact is due to the insufficiency of data and rules, which causes the inference engine to fail to provide a correct insect pest diagnosis. However, the AgriEnt-Ontology has the flexibility of extending i.e., it can be updated with more data and rules, which is difficult in a database system [11]. The next section presents our conclusions and describes future research directions which are mainly focused on addressing the issues that caused an incorrect diagnosis.