In foundation pit engineering, the deformation prediction of adjacent pipelines is crucial for construction safety. Existing approaches depend on constitutive models, grey correlation prediction, or traditional feedforward neural networks. Due to the complex hydrological and geological conditions, as well as the nonstationary and nonlinear characteristics of monitoring data, this problem remains a challenge. By formulating the deformation of monitoring points as multivariate time series, a deep learning-based prediction model is proposed, which utilizes the convolutional neural network to extract the spatial dependencies among various monitoring points, and leverages the bi-directional long-short memory unit network to extract temporal features. Notably, an attention mechanism is introduced to adjust the trainable weights of spatial-temporal features extracted in the prediction. The evaluation of a real-world subway project demonstrates that the proposed model has advantages compared with current models, particularly in long-term prediction. It improves the Adjusted R2 index averagely by from 19.4 to 61.6%\\documentclass[12pt]{minimal} \\usepackage{amsmath} \\usepackage{wasysym} \\usepackage{amsfonts} \\usepackage{amssymb} \\usepackage{amsbsy} \\usepackage{mathrsfs} \\usepackage{upgreek} \\setlength{\\oddsidemargin}{-69pt} \\begin{document}$$\\%$$\\end{document} compared with existing models. The proposed model also exhibits a decrease in mean absolute error ranging from 51.5 to 70.3%\\documentclass[12pt]{minimal} \\usepackage{amsmath} \\usepackage{wasysym} \\usepackage{amsfonts} \\usepackage{amssymb} \\usepackage{amsbsy} \\usepackage{mathrsfs} \\usepackage{upgreek} \\setlength{\\oddsidemargin}{-69pt} \\begin{document}$$\\%$$\\end{document} compared to others. Experiments and analyses verify that the spatial-temporal dependencies in time series and the attention learning for spatial-temporal features can improve the prediction of such engineering problems.