Non-intrusive load monitoring (NILM) aims at decomposing the aggregate electricity load to identify the individual contribution of different appliances and detecting outliers. In traditional methods, NILM is considered as a classification task, which causes ignoration of details in signals, and when the number of appliances rises, complexity of model increases rapidly, and applicability is limited. To overcome these shortcomings, a long short-term memory (LSTM) based method where NILM is treated as a regression task from sequence to sequence. LSTM is exploited to learn long-term dependence in sequence for improving performance of the regressor. Furthermore, non-causal structure and Bayesian optimization frame are introduced for dealing with appliances with multiple states. Experimental results on real-world dataset indicate the superiority of the proposed method compared to current mainstream methods.