Spatial omics data provide rich molecular and structural information about tissues, enabling novel insights into the structure-function relationship. In particular, it facilitates the analysis of the local heterogeneity of tissues and holds promise to improve patient stratification by association of finer-grained representations with clinically relevant features. Here, we introduce Kasumi, a method for the identification of spatially localized neighborhoods of intra- and intercellular relationships, persistent across samples and conditions. We learn compressed explainable representations while preserving relevant biological signals that are readily deployable for data exploration and hypothesis generation, facilitating translational tasks. We address tasks of patient stratification for disease progression and response to treatment in cancer on data coming from different spatial antibody-based multiplexed proteomics platforms. Kasumi outperforms related neighborhood analysis approaches and offers explanations at the level of cell types or directly from the measurements, of the spatial coordination and multivariate relationships underlying observed disease progression and response to treatment. We show that persistent local patterns form spatially contiguous regions of different sizes. However, the abundance of the persistent local patterns is not associated with their relative importance in downstream tasks. We show that non-abundant, localized structural and functional relationships in the tissue are strongly associated with unfavorable outcomes in disease progression and response to treatment.