Rice is one of the most widely distributed staple crops in China and its production plays an important role in the economic development and social stability in China.The process of rice planting is complicated,requires high planting technology.In order to increase rice production,it is necessary to rely on agricultural technology services.However,our country’s agricultural technology services face many difficulties,such as shortage of funds and shortage of manpower.With the development of artificial intelligence,more and more areas are solving common users’ problems by constructing intelligent question-answering systems in the field.Therefore,a rice FAQ(Frequently asked questions)question-answering system is of great significance to the improvement of rice yield by analyzing the problems encountered by farmers in the process of rice planting and returning the corresponding answers directly.Sentence similarity computation is the key to understand users’ questions in FAQ question-answering system,and its accuracy directly determines the quality of the answers to the system.In order to solve the problem of low accuracy of the traditional sentence similarity algorithms,this study uses the word vectors and LSTM(Long-short term memory)in deep learning.The word vectors solve the problems of the dimension explosion and the semantic insufficiency in the traditional text representation.LSTM can automatically extract the features of the sentences,and its special network structure determines that it can better obtain the semantics of the text.A sentence similarity model based on LSTM is constructed by using word vectors as input,and the model is applied to the rice FAQ question-answering system.In this paper,three aspects of construction of rice FAQ knowledge base and labeling of questions similarities,construction and experiment of sentence similarity model,and implementation of question-answering system are studied and discussed.The main contents are as follows:(1)Construction of rice FAQ knowledge base and labeling of questions similarities.A total of 22,533 rice-related questions and answers were collected by web crawlers from various agricultural web sites as a knowledge base for the rice FAQ question-answering system.For the lack of datasets used to train sentence similarity model,this study designed a semi-automated data annotation method.Firstly,the 3007 original questions were manually categorized,and then 32,072 question pairs were obtained as training dataset and test dataset through automatically labeling by this method.(2)Construction and experiment of sentence similarity model.Based on LSTM,a sentence similarity model was designed including input layer,embedding layer,LSTM layer,full connection layer and output layer.For rice-related questions,there are a large number of domain-specific vocabularies that do not appear or have a low frequency in general corpus.This study first collected a large-scale rice-related corpus and trained word vectors model based on general corpus and rice corpus.Then,using the word vectors model,the training dataset were mapped into vectors and used as input to train the sentence similarity model.Optimized the model by adjusting the parameters to obtain the best results for sentence similarity calculation.Finally,the model was validated on the test dataset and compared with the two baseline methods:the method based on HowNet and the method based on cosine distance of word vectors.Sampling results of the sentence similarity calculation indicated that the result of this model was more reasonable for human.Furthermore,the analysis results of the accuracy and ROC curves showed that our model was obviously superior to the other two methods,and the accuracy was 93.1%.(3)Implementation of question-answering system.Develop a rice FAQ question-answering system for farmers and agricultural technicians based on the sentence similarity model.The system provides web and WeChat Mini Program to meet the different needs of users.Users can ask questions through web pages or Mini Program,the system can accurately match users’ questions and the questions in rice FAQ,and automatically return the corresponding answers.When the system can’t find the answers to the users’questions,the questions will be temporarily added to the "list of unanswered questions".The experts log in to the system regularly to answer these questions,and then add these questions and corresponding answers to the rice FAQ knowledge base.The interface of the question-answering system is concise and intuitive.In particular,the Mini Program,which is very suitable for farmers to ask questions at any time under the limited conditions of the field,can better help farmers solve problems in rice production.The system not only has realistic guiding significance for rice production,but also promotes the development of intelligent agriculture. |