➀ HAP system optimizes SPMD model training on heterogeneous clusters by automating tensor sharding and communication methods. ➁ The system uses A* search algorithm to generate distributed programs and optimize sharding ratios. ➂ OEF framework enhances resource efficiency and fairness in heterogeneous GPU clusters, improving training throughput by up to 32%.