The DeepRisk network, based on digital pathology signatures (DPS) from whole-slide images, enhances the prognostic accuracy of the tumor, node, and metastasis (TNM) staging system for gastric cancer (GC). Validation across multiple datasets demonstrated that DeepRisk offers superior prognostic value and identifies patients who respond better to neoadjuvant chemotherapy. Additionally, spatial and multi-omics analyses reveal associations between DPS and immune suppression, providing insights into GC pathogenesis and aiding in personalized treatment strategies.