The article is devoted to the task of the sentiment detection towards an aspect of economic and social development in Russian sentences. The aspect, the attitude to which is determined, can be either explicitly mentioned or implied. The authors investigated possibilities of using neural network classifiers and proposed an algorithm for determining the sentiment towards an aspect based on semantic rules implemented with the use of constituency trees. The sentiment towards an aspect is determined in two stages. At the first stage, aspect terms (explicitly mentioned events or phenomena associated with the aspect) are found in the sentence. At the second stage, the sentiment towards an aspect is calculated as the sentiment towards the aspect term that is most closely associated with the aspect. The paper proposes several methods for searching the aspect terms. The performance was assessed on a corpus of 468 sentences extracted from election campaign materials. The best result for neural network classifiers was obtained using the BERT-SPC neural network pretrained on the task of identifying the sentiment towards an explicitly mentioned aspect, the macro F-score was 0.74. The best result for the semantic rule-based algorithm was obtained using the method of aspect term searching based on semantic similarity, the macro-F-score was 0.63. When combining BERT-SPC and the rule-based algorithm into an ensemble, the macro-F-score was 0.79, which is the best result obtained in this work.