henhaobio
Sign in

bioRxivBioinformaticsPreprint

conST: an interpretable multi-modal contrastive learning framework for spatial transcriptomics

Yongshuo ZongiD, Tingyang YuiD, Xuesong WangiD, Yixuan WangiD, Zhihang HuiD, Yu LiiD

PDFDOI

Abstract

MotivationSpatially resolved transcriptomics (SRT) shows its impressive power in yielding biological insights into neuroscience, disease study, and even plant biology. However, current methods do not sufficiently explore the expressiveness of the multi-modal SRT data, leaving a large room for improvement of performance. Moreover, the current deep learning based methods lack interpretability due to the "black box" nature, impeding its further applications in the areas that require explanation. ResultsWe propose conST, a powerful and flexible SRT data analysis framework utilizing contrastive learning techniques. conST can learn low-dimensional embeddings by effectively integrating multi-modal SRT data, i.e. gene expression, spatial information, and morphology (if applicable). The learned embeddings can be then used for various downstream tasks, including clustering, trajectory and pseudotime inference, cell-to-cell interaction, etc. Extensive experiments in various datasets have been conducted to demonstrate the effectiveness and robustness of the proposed conST, achieving up to 10% improvement in clustering ARI in the commonly used benchmark dataset. We also show that the learned embedding can be used in complicated scenarios, such as predicting cancer progression by analyzing the tumour microenvironment and cell-to-cell interaction (CCI) of breast cancer. Our framework is interpretable in that it is able to find the correlated spots that support the clustering, which matches the CCI interaction pairs as well, providing more confidence to clinicians when making clinical decisions.

In-depth summary

Claude Opus 5.5 · max effort · 8 Nov 2026 · from the full text of version 1 (17 Jan 2022) · CC BY-NC 4.0

conST learns embeddings from gene expression, spatial neighbors, and histology via three-level contrastive learning, reaching adjusted Rand index 0.65 on spatialLIBD slice 151673, with GNNExplainer-based explanations.

Prior spatial transcriptomics tools either lack reusable embeddings (hidden Markov random fields, Giotto, BayesSpace) or reduce histology to fixed pretrained-CNN features, simple statistics, or nothing (SpaCell, stLearn, SpaGCN, SEDR), underuse sub-cluster and global structure, and are hard to interpret. conST trains with morphology as a node attribute, adds node-, cluster-, and graph-level contrastive objectives, and explains predictions via GNNExplainer.

Key results

  1. ShownconST embeddings produced the most accurate cortical layer clustering on the spatialLIBD human dorsolateral prefrontal cortex Visium benchmark, and ablations indicate all three contrastive levels help, with local-local feature-masking contrast contributing most.

    Slice 151673 adjusted Rand index (ARI) 0.65 (65%), about 10% above the best prior method (baselines include SpaGCN, SEDR, BayesSpace); best mean and median ARI across all 12 slices. Table 1 ablation (ARI) found the full three-loss model best and local-local most influential; per-method and ablation values are not given in the text. · 3.2 Clustering; Ablation Study; Figure legends; Tables

  2. SuggestedconST generalized to mouse imaging-based data lacking histology (hypothalamus MERFISH, visual cortex seqFISH) and to mouse olfactory bulb Stereo-seq, giving more internally consistent MERFISH clusters than SpaGCN and SEDR.

    Mouse hypothalamus MERFISH has no ground truth, so silhouette coefficient and Calinski Harabasz score (higher better) plus Davies Bouldin index (lower better) were used; conST beat SpaGCN and SEDR on all three, called significant without values or tests in the text. Mouse seqFISH and Stereo-seq results appear only in supplementary figures. · 3.1 Datasets and Implementation Details; 3.2 Clustering; Figure legends

  3. SuggestedSubstituting conST embeddings for default principal components gave more orderly Monocle3 and PAGA trajectories and smoother pseudotime from white matter to Layer 6, spatially variable genes (SVGs) with stronger spatial autocorrelation than SpaGCN's, and better-mixed batches.

    Human spatialLIBD slice 151673: conST-based SVGs scored better on Moran's I and Geary's C than SpaGCN's using SpaGCN's own detection settings; PCP4 localized to Layer 2 as in ground truth vs Layer 3 for SpaGCN. Trajectories, pseudotime, and three-slice batch mixing (UMAP) were judged visually against SpaGCN and SEDR without numeric scores. · 3.3 Trajectory and Pseudotime Inference; 3.4 SVGs Detection; 3.5 Batch Correction; Figure legends

  4. SuggestedOn one 10x Genomics human breast cancer section, conST clusters and pseudotime fed TraSig ligand-receptor analysis that labeled lesion clusters as invasive ductal carcinoma (IDC, c2), tumor edge (c6), and ductal carcinoma in situ (DCIS, c10), and suggested DCIS progression toward invasion.

    Lesion clusters c2, c6, c10 analyzed: c2 and c10 showed active BRCA1, BRCA2, BRCC3, TP53 interactions and c10 the strongest migration/motility Gene Ontology (GO) terms; SMAD5-LINC00645 and IGFBP2-IGF1R were more active in IDC, ERBB2-CCND1 at the IDC/edge border, RABEP1-GGA2 and RABEP1-RAB4A in DCIS. No statistical tests of interaction differences are reported. · 3.6.1 Cross-clusters: Morphotype Prediction; IDC Region (c2); Tumor Edge Region (c6); DCIS Region (c10)

  5. SuggestedGNNExplainer subgraphs gave spot-level rationales: a boundary spot drew on same-cluster neighbors, another's subgraph included a neighbor clustered differently despite sharing its annotated layer (a likely misclustering), and a breast cancer spot's subgraph held only ligand-receptor-active spots.

    Human spatialLIBD slice 151673: node 971's explanatory subgraph was all same-cluster; node 1765's included node 1577, predicted in another cluster yet in the same ground-truth layer. Breast cancer node 3278: every subgraph spot passed the SMAD5-LINC00645 activity threshold. Only these anchor nodes are reported, without aggregate statistics. · 3.7.1 Clustering Explanation; 3.7.2 CCI Explanation; Figure legends

Methods, data and reproducibility

A K-nearest-neighbor spot graph carries PCA-reduced expression and ImageNet-pretrained MAE Vision Transformer histology features; autoencoder and variational graph autoencoder encoders pretrained by reconstruction are refined with local-local, local-context, and local-global contrastive losses plus a clustering KL term, then probed with GNNExplainer.

  • spatialLIBD dorsolateral prefrontal cortex 10x Visium sections with ground-truth layer labels; slice 151673 featured, three slices used for batch correction · human · n = 12 slices
  • MERFISH imaging-based spatial transcriptomics of hypothalamus, without histology or ground-truth labels · mouse
  • seqFISH imaging-based spatial transcriptomics of visual cortex, without histology · mouse
  • Stereo-seq spatial transcriptomics of olfactory bulb · mouse
  • 10x Genomics Human Breast Cancer (Block A Section 1); clustered into 20 regions, with lesion clusters c2, c6, c10 used for cell-cell interaction analysis · human
Methods & tools
MAE Vision Transformer, self-supervised ImageNet pretraining (H&E morphology features), Variational graph autoencoder with two-layer graph convolutional encoder, NT-Xent-style node contrast with attribute masking (local-local), Deep Graph Infomax-style objective (local-global), Graph InfoClust-style differentiable K-means (local-context), GNNExplainer, Leiden clustering, Monocle3 and PAGA (trajectory and pseudotime), TraSig (ligand-receptor cell-cell interaction), Seurat (label transfer), SpaGCN SVG detection procedure; Moran's I and Geary's C, Baselines: SpaGCN, SEDR, BayesSpace
Reagents & environment
No software versions or framework stated; reported settings: KNN graph K = 20, PCA to 300 dimensions, 768-dimensional MAE morphology features, 200 training epochs for each of the two stages.
Reproducibility gaps
No code repository, data link, or accession is printed even though tutorials are mentioned; dataset descriptions, implementation details, the MAE description, and seqFISH/Stereo-seq results are deferred to supplementary material.
Limitations (4)
  • Few H&E-stained images from spatial transcriptomics were available, so the MAE morphology encoder was pretrained self-supervised on ImageNet instead of on histology images. · stated by the authors
  • Mouse hypothalamus MERFISH has no ground-truth labels, so its clustering was judged only by internal metrics (silhouette, Calinski Harabasz, Davies Bouldin); the imaging-based datasets also carry fewer genes per spot and no morphology. · stated by the authors
  • Breast cancer morphotypes are inferred from GO and ligand-receptor reasoning on one section without pathologist labels, and are inconsistent: c10 shows the strongest migration signal yet is called DCIS, the tumor-edge section swaps c2 and c6, and an IDC pair is explained within c10. · noted in this summary
  • Robustness is not quantified: no variance across random seeds or statistical tests accompany the ARI and MERFISH comparisons, and trajectory, batch-correction, and explainer claims rest on visual inspection of a few slices or spots. · noted in this summary

Read this if you build graph-based embeddings for Visium or imaging-based spatial transcriptomics and want a contrastive design that folds in histology features and GNNExplainer-style explanations of spot clustering.

Citations
113

Reproducibility ledger

Nobody has reported trying to reproduce this paper yet. Did you replicate an experiment or run the code? Your report saves the next lab a week.

Sign in to file a reproducibility report.

Similarity Map
SelectedSame fieldCross-field
THISYu '26Li '24Dai '26Zhang '24Avesani '22Heydari '23
64% semantic matchBioinformatics
Na Yu, Daoliang Zhang, Wen Zhang+8 more·Genome biology·Jan 28, 2026· 10 citations