This study introduces a scheduling model for a two-machine flow shop batch system to minimize the actual flow time. In this system, two machines are responsible for processing raw materials and producing finished products, with a single bottleneck machine. The entity overseeing the manufacturing process organizes demand units into batches, ensures the accurate and timely arrival of raw materials, and delivers all finished products punctually to meet an expected due date. The study addresses crucial challenges, including determining the optimal number of batches, sizes, and sequences to achieve the specified objective. The analysis adopted an algorithm grounded in the Lagrange relaxation method to tackle these challenges. Moreover, the algorithm is operated by identifying the bottleneck machine as a scheduling reference and determining the appropriate number of batches and sizes. The analysis showed the efficacy of the developed algorithm by using Johnson's rule for making batch sequence decisions through numerical experiments conducted across 1000 cases. The results showed a 1.44% to 4.43% improvement in efficiency compared to previous research, accompanied by a 2–8 times reduction in computational time.