IDEAS home Printed from https://ideas.repec.org/a/gam/jmathe/v14y2026i7p1237-d1915472.html

ReDyGait: Representation Disentanglement with Gated Attention for Invariant-Contextual Transfer in Stance Detection

Author

Listed:
  • Yanzhou Ma

    (College of International Studies, National University of Defense Technology, Nanjing 210012, China
    These authors contributed equally to this work.)

  • Yun Luo

    (College of International Studies, National University of Defense Technology, Nanjing 210012, China
    These authors contributed equally to this work.)

  • Mingyang Peng

    (College of International Studies, National University of Defense Technology, Nanjing 210012, China)

Abstract

Cross-topic stance detection degrades when encoders entangle stance signals with topic-specific vocabulary, causing representations that fail to transfer to unseen targets. Existing methods commit to either topic-invariant or topic-aware representations and apply the same strategy uniformly to every input, sacrificing complementary information. We propose ReDyGait, a three-stage framework that disentangles these two types of signals through dedicated contrastive pre-training and recombines them adaptively at inference time. Stage 1 trains a topic-invariant encoder with supervised contrastive loss over cross-topic positives. Stage 2 trains a topic-contextual encoder with bidirectional pair contrastive loss over within-topic positives; both stages employ topic-aware hard negative mining to prevent shortcut learning. Stage 3 freezes the two contrastive encoders and learns a gating network that produces per-instance weights over invariant, contextual, and base-encoder pathways. On VAST, ReDyGait achieves a macro-averaged F1 of 0.782 in the zero-shot setting and 0.752 in the few-shot setting, improving over the strongest baseline by 1.1 points in both; on SEM16t6 in a leave-one-target-out setup, ReDyGait reaches an average F1 of 0.612. Analysis of the learned gate weights shows that the model shifts toward the invariant pathway for unfamiliar topics and toward the contextual pathway when topic-specific patterns are available, confirming that the disentanglement operates as intended.

Suggested Citation

  • Yanzhou Ma & Yun Luo & Mingyang Peng, 2026. "ReDyGait: Representation Disentanglement with Gated Attention for Invariant-Contextual Transfer in Stance Detection," Mathematics, MDPI, vol. 14(7), pages 1-24, April.
  • Handle: RePEc:gam:jmathe:v:14:y:2026:i:7:p:1237-:d:1915472
    as

    Download full text from publisher

    File URL: https://www.mdpi.com/2227-7390/14/7/1237/pdf
    Download Restriction: no

    File URL: https://www.mdpi.com/2227-7390/14/7/1237/
    Download Restriction: no
    ---><---

    More about this item

    Keywords

    ;
    ;
    ;
    ;
    ;
    ;

    Statistics

    Access and download statistics

    Corrections

    All material on this site has been provided by the respective publishers and authors. You can help correct errors and omissions. When requesting a correction, please mention this item's handle: RePEc:gam:jmathe:v:14:y:2026:i:7:p:1237-:d:1915472. See general information about how to correct material in RePEc.

    If you have authored this item and are not yet registered with RePEc, we encourage you to do it here. This allows to link your profile to this item. It also allows you to accept potential citations to this item that we are uncertain about.

    We have no bibliographic references for this item. You can help adding them by using this form .

    If you know of missing items citing this one, you can help us creating those links by adding the relevant references in the same way as above, for each refering item. If you are a registered author of this item, you may also want to check the "citations" tab in your RePEc Author Service profile, as there may be some citations waiting for confirmation.

    For technical questions regarding this item, or to correct its authors, title, abstract, bibliographic or download information, contact: MDPI Indexing Manager (email available below). General contact details of provider: https://www.mdpi.com .

    Please note that corrections may take a couple of weeks to filter through the various RePEc services.

    IDEAS is a RePEc service. RePEc uses bibliographic data supplied by the respective publishers.