In recent years, the proportion of building energy consumption (BEC) in my country’s total social energy consumption is also close to 25%, and it shows an upward trend year by year. How to deeply mine the relationship between BEC data and energy-consuming equipment, extract relevant information features, and then provide optimization measures to reduce the operating energy consumption of energy-consuming equipment is a bottleneck that needs to be broken through in the field of BEC monitoring and management. Based on these problems, this paper firstly analyzes the current BEC and points out the current problems. Then the main factors of BEC are analyzed, and the energy consumption measurement and detection model is established. Finally, based on LSTM, an energy consumption prediction model based on LSMT is established, and the accuracy and other scores of the model are analyzed by taking the library as an example. The experimental verification shows that the LSTM neural network model used in this study has wider applicability.