Surface defect detection is a challenging task in industrial manufacturing, and the detection method based on deep learning has become the mainstream trend in the industry. However, the task of detecting defects on transparent plastic bottles poses unique challenges due to their clear, smooth surfaces and minimal texture, which contribute to specular reflections and make small, low-contrast defects difficult to discern. To tackle these challenges, we introduce the BiD-YOLO framework, an advanced version of the YOLOv5 model, tailored for real-time surface defect detection on such substrates. This framework notably enhances the detection accuracy for small, low-contrast defects and minimizes miss rates. At its core, BiD-YOLO incorporates a dual-branch feature extractor (DBFE) that utilizes both standard, dilated convolutions and a specialized small-object feature extraction branch to capture a broad spectrum of contextual information, optimizing the detection of fine details. Additionally, the dynamic multi-scale pyramid fusion attention (DyMFA) block with coordinate attention (CA) effectively addresses the loss of information in small-scale defects—a typical shortfall in conventional attention mechanisms—thereby improving detection precision across both channel and spatial dimensions. To achieve an optimal balance between accuracy and computational efficiency, we introduce two versions of the dynamic multi-scale pyramid attention block: multi-scale pyramid channel attention and dynamic channel attention. We also curated and annotated the TPSD dataset, a specialized collection of images showcasing surface defects on transparent plastic bottles under diverse real-world production conditions. Together with the NEU-DET dataset, these resources were employed to validate the BiD-YOLO model's effectiveness. Experimental results demonstrate a substantial improvement in defect detection capabilities, achieving mean average precision (mAP) values of 63.1% and 85.6%, respectively. Moreover, the two working models exhibit FPS values of 47.23FPS and 50.21FPS respectively. These findings underscore the BiD-YOLO model's pivotal role in reducing oversight in defect detection, thereby enhancing quality control within industrial manufacturing environments. The BiD-YOLO framework represents a significant advancement in the automated detection of surface defects on transparent plastic bottles, merging innovative technical features with robust practical applicability for industrial use.