Objective. Rapid serial visual presentation (RSVP) based on electroencephalography (EEG) has been widely used in the target detection field, which distinguishes target and non-target by detecting event-related potential (ERP) components. However, the classification performance of the RSVP task is limited by the variability of ERP components, which is a great challenge in developing RSVP for real-life applications. Approach. To tackle this issue, a classification framework based on the ERP feature enhancement to offset the negative impact of the variability of ERP components for RSVP task classification named latency detection and EEG reconstruction was proposed in this paper. First, a spatial-temporal similarity measurement approach was proposed for latency detection. Subsequently, we constructed a single-trial EEG signal model containing ERP latency information. Then, according to the latency information detected in the first step, the model can be solved to obtain the corrected ERP signal and realize the enhancement of ERP features. Finally, the EEG signal after ERP enhancement can be processed by most of the existing feature extraction and classification methods of the RSVP task in this framework. Main results. Nine subjects were recruited to participate in the RSVP experiment on vehicle detection. Four popular algorithms (spatially weighted Fisher linear discrimination-principal component analysis (PCA), hierarchical discriminant PCA, hierarchical discriminant component analysis, and spatial-temporal hybrid common spatial pattern-PCA) in RSVP-based brain–computer interface for feature extraction were selected to verify the performance of our proposed framework. Experimental results showed that our proposed framework significantly outperforms the conventional classification framework in terms of area under curve, balanced accuracy, true positive rate, and false positive rate in four feature extraction methods. Additionally, statistical results showed that our proposed framework enables better performance with fewer training samples, channel numbers, and shorter temporal window sizes. Significance. As a result, the classification performance of the RSVP task was significantly improved by using our proposed framework. Our proposed classification framework will significantly promote the practical application of the RSVP task.