The remaining useful life (RUL) of a lithium battery is an important index for an efficient battery management system, and the accurate prediction of RUL is beneficial for designing a reliable battery system, ensuring the safety and reliability of actual operation, and therefore playing a crucial role in the field of new energy. This study introduces an integrated data-driven approach for predicting the RUL of lithium-ion batteries. The method employs a variety of techniques, including signal decomposition techniques, attention mechanisms, and temporal convolutional neural networks (TCN). Initially, the measured capacity data are decoupled by the Variational Mode Decomposition (VMD) algorithm to separate the overall trend and the high-frequency oscillations in the capacity data. Subsequently, an attention mechanism is incorporated when processing temporal capacitance sequences, empowering automatic relevance determination across timepoints to dynamically optimize model training. In addition, a TCN structure is designed to efficiently capture key features of time series data. A series of comparative experiments are conducted on the lithium battery dataset from the University of Maryland to verify the accuracy and effectiveness of the proposed method. The experimental results show that the method performs well in lithium battery RUL prediction.