BiasNet
FTNCT08 · Procedia Computer Science 282 (2026) 1973–1983

BiasNet: A Contrastive GNN-Based Framework for Classifying Political Stance in News

T. Bhat · M. Saqlain · A. Muralidharan · B. Das
Department of Computer Science and Engineering (AI & ML), PES University, Bengaluru 560085, India

Abstract

Hyperpartisan news — content that leans strongly left or right and distorts public discourse — is conventionally detected by treating each article as an isolated block of text. BiasNet challenges that assumption. It represents a corpus of news articles as a graph, with edges drawn between articles that are semantically similar, and applies Graph Neural Networks (GCN and GAT) to propagate contextual signal across related articles. A supervised contrastive objective (NT-Xent) is layered on top, pulling embeddings of same-stance articles together and pushing opposite-stance articles apart. Evaluated on the SemEval-2019 Task 4 benchmark (left / right / center), the approach reaches 95.02% test accuracy — well above prior top systems (82.2%) — and generalizes to 86.0% accuracy on 150 freshly published, manually labeled articles.

News Bias Detection Hyperpartisan News Graph Neural Networks Contrastive Learning
95.02%
Best test accuracy (GAT / GCN + Contrastive)
86.0%
Accuracy on 150 unseen 2026 articles
3,832
Labeled articles used (SemEval 2019 Task 4)
+12.8 pt
Improvement over prior SemEval best (82.2%)
Read Paper

01 Introduction

News shapes public opinion and underpins accountable, democratic decision-making — which is exactly why the rise of hyperpartisan content is a problem. Hyperpartisan articles display strong ideological lean toward the left or right, distort perception, and widen political divides. Detecting this lean automatically is a prerequisite for balanced information consumption, yet conventional text classifiers process each article in isolation, in a vacuum, missing the relational signals — shared sources, overlapping topics, similar phrasing — that connect biased narratives to one another.

BiasNet addresses this gap directly: instead of classifying articles one at a time, it models the corpus as a graph and lets a Graph Neural Network propagate context between related articles, while a contrastive objective sharpens the separation between ideological clusters in embedding space.

Core idea. Articles that share a political stance tend to occupy the same neighborhoods — topically and stylistically. A graph makes that neighborhood structure explicit; contrastive learning makes the model exploit it.

03 Methodology

BiasNet combines a graph representation of the news corpus with a message-passing GNN encoder and a dual training objective: standard classification plus supervised contrastive alignment.

News articlesraw text corpus
LaBSE embedding768-d node features
Graph constructioncosine sim > 0.8
GNN encoderGCN / GAT · 2 layers
Readout + MLPclassification head
Edge dropout viewaugmentation 1
Shared GNN + projection headtwo augmented graph views
Feature masking viewaugmentation 2
NT-Xent losscontrastive alignment
Original recreation of the BiasNet pipeline: node embedding → graph construction → dual-view contrastive GNN training → joint classification / contrastive loss.

3.1 Dataset

BiasNet uses the SemEval-2019 Task 4 dataset, which labels political news either byarticle (crowdsourced, article-level, high annotator agreement) or bypublisher (inferred from the publisher's overall lean, per BuzzFeed / MediaBiasFactCheck.com). For tractability, the study uses a subset of 3,832 articles split 80 / 10 / 10 into train / validation / test, moderately imbalanced across classes.

Class Articles Share
Right 1,416 36.9%
Left 1,255 32.8%
Center 1,161 30.3%

A second, independent set of 150 recently published articles — spanning publishers across the political spectrum (Counterpunch, FoxBusiness, DailyWire, Texas Tribune) — was manually labeled with the AllSides bias-checker tool, purely for out-of-distribution evaluation.

3.2 Graph construction

The corpus is modeled as an undirected graph G = (V, E). Each node is an article, initialized with its 768-dimensional LaBSE embedding — chosen over English-only encoders like vanilla BERT for its multilingual, cross-source robustness. Two articles are connected by an edge when their embedding cosine similarity exceeds a tuned threshold of 0.8: low enough to link genuinely related articles, high enough to avoid a dense, uninformative graph.

3.3 Graph Neural Network model

A K-layer message-passing GNN learns node and graph-level representations. At each layer, every node aggregates its neighbors' representations and combines them with its own:

an(k) = AGGREGATION(k)({ hn'(k-1) : n' ∈ 𝒩(n) }),   hn(k) = COMBINE(k)(hn(k-1), an(k))(1)

After K layers, a READOUT function pools node embeddings into a graph-level summary, which an MLP maps to classification logits:

f(G) = READOUT({ hn(k) : n ∈ V, k ∈ {1,…,K} })(2) zG = MLP( f(G) )(3)

Two GNN variants are compared:

GCN

Aggregates uniformly from all neighbors — effective when local neighborhoods are relatively homogeneous.

GAT

Learns attention weights per edge, emphasizing informative neighbors and downweighting noisy connections.

Both variants share two task heads: a classification head producing stance logits, and a projection head (2-layer MLP) mapping embeddings into the contrastive space.

3.4 Training objectives

Classification uses standard cross-entropy over the three stance classes:

Lcls = −(1/M) Σi=1..M Σc∈C yi,c log softmax(zGi)c(4)

To sharpen the embedding space itself, a supervised NT-Xent contrastive loss pulls together projections of same-label articles and pushes apart the rest. For anchor i with positive set P(i) = { j ≠ i : label(j) = label(i) }:

Lcont,i = −log[ Σj∈P(i) exp(sim(zi,zj)/τ) / Σk≠i exp(sim(zi,zk)/τ) ](5) Lcont = (1/|{i:|P(i)|>0}|) Σ Lcont,i(6)

The two objectives are combined with weight λ:

L = Lcls + λ·Lcont(7)

3.5 Graph augmentation for contrastive views

Each training step generates two stochastic views of the article graph:

  • Edge dropout — randomly removes a fraction of edges, reducing reliance on any single neighbor and mitigating spurious publisher-specific links.
  • Feature masking — randomly masks a fraction of node features, simulating partial or noisy text representations.

Both views pass through the same GNN encoder and projection head; NT-Xent is then applied across the two views so same-label nodes are pulled together regardless of which perturbation they saw.

3.6 Optimization & hyperparameters

Models train for 100 epochs with Adam, weight decay, and early stopping on validation accuracy. Depth is kept shallow (K = 2) with dropout to counter over-smoothing.

Table 1 — Key hyperparameters used across BiasNet's components.
Category Hyperparameter Value
Graph construction Cosine similarity threshold 0.8
Train / Val / Test split 0.8 / 0.1 / 0.1
Architecture Hidden dimension 64
GNN layers (K) 2
GAT attention heads 4
Dropout rate 0.3
Contrastive model Projection head dimension 128
Optimization Optimizer / LR Adam / 0.01
Weight decay 5×10⁻⁴
Epochs 100
Contrastive learning Temperature (τ) 0.5
Contrastive weight (λ) 0.5
Edge drop / feature mask prob. 0.2 / 0.2

A similarity threshold of 0.7 produced an over-dense, less discriminative graph; 0.9 was too sparse for effective aggregation. 0.8 offered the best trade-off. Lower NT-Xent temperature (τ = 0.5) sharpened positive/negative contrast and improved cluster separation.

3.7 Application to unseen articles

For real-time use, a new article is embedded with the same LaBSE model, added as a node connected by cosine similarity to the existing graph, and classified by the trained GNN using its own features and its neighbors' influence — enabling continuous, incremental classification.

04 Results

Four architectures were evaluated: GCN and GAT, each with and without the contrastive objective. All metrics are averaged over five runs with 95% confidence intervals.

Table 2 — Performance on the political bias classification task (accuracy: mean ± std over 5 runs).
Model Train Acc. Val Acc. Test Acc. Precision Recall F1 (95% CI)
GATvanilla 0.9557 ± .0018 0.9392 ± .0063 0.9327 ± .0053 0.9283 0.9205 [.9266, .9321]
GCNvanilla 0.9910 ± .0006 0.9397 ± .0055 0.9468 ± .0057 0.9422 0.9393 [.9417, .9477]
GCN+Contrastive 0.9980 ± .0002 0.9462 ± .0137 0.9502 ± .0114 0.9482 0.9465 [.9427, .9544]
GAT+Contrastive 0.9993 ± .0002 0.9478 ± .0069 0.9502 ± .0065 0.9431 0.9426 [.9419, .9507]

4.1 Comparison with prior SemEval systems

Table 3 — BiasNet vs. representative prior systems on SemEval-2019 Task 4.
System Accuracy Precision Recall F1
Jiang et al. (SemEval winner) 0.822 0.871 0.755 0.809
Srivastava et al. 0.820 0.815 0.828 0.821
Hanawa et al. 0.809 0.823 0.787 0.805
Isbister & Johansson 0.803 0.793 0.818 0.806
Shaprin et al. 0.646 0.646 0.646 0.646
Mohan & Pengyu (2025, LLaMA embeddings) 0.926
BiasNet (GCN + Contrastive) 0.9502 0.9482 0.9465 0.9485
BiasNet (GAT + Contrastive) 0.9502 0.9431 0.9426 0.9463

On the 150-article, out-of-distribution evaluation set, the best-performing configuration held up at 86.0% accuracy — evidence of meaningful generalization beyond the training distribution, across publishers it had never seen.

4.2 Embedding visualization (UMAP)

WITHOUT CONTRASTIVE WITH CONTRASTIVE
Illustrative recreation (not the original data) of the paper's UMAP finding: contrastive training produces tighter, more separated left / center / right clusters for both GCN and GAT.

4.3 Statistical significance

Table 4 — Paired t-tests on macro-F1 across five runs.
Comparison t-statistic p-value Significant?
GAT vs. GAT + Contrastive −13.454 0.000177 Yes (p < .05)
GCN vs. GCN + Contrastive −0.785 0.476313 No
GAT vs. GCN −16.078 0.000088 Yes
GAT+Contrastive vs. GCN+Contrastive 0.633 0.561100 No

Contrastive learning delivers a statistically significant lift for GAT, but not for GCN — while both contrastive variants converge to comparable, strong performance overall.

05 Limitations

01 · Scalability
Pairwise cosine similarity for graph construction is O(N²), growing expensive for large-scale streams or multi-year archives. ANN search or similarity pruning is proposed as a fix.
02 · Static graph
The pipeline currently assumes a fixed graph; adding new articles requires recomputing similarities and re-running inference, adding latency in streaming settings.
03 · Training cost
Dual augmented views, projection-head computation, and label-based NT-Xent increase GPU memory use and slow training versus non-contrastive GNNs.
04 · Embedding dependency
BiasNet relies on precomputed LaBSE embeddings; large multilingual encoders are themselves resource-intensive to run at scale.

06 Discussion

The gap between training and test accuracy — e.g. GCN + Contrastive reaches 99.8% train but 95.02% test — signals residual overfitting: models are still partly learning dataset- or source-specific artifacts rather than pure ideological structure. Contrastive learning narrows this gap but doesn't close it. The authors point to harder regularization, more aggressive graph augmentation, and more diverse training data as the likely next steps toward consistent performance on unseen or temporally shifting news content.

07 Conclusion

BiasNet reframes hyperpartisan news detection as a relational problem rather than an isolated text-classification one. By representing articles as nodes in a similarity graph and training a GNN with a joint classification + contrastive objective, it captures both content and structure — outperforming prior SemEval-2019 systems substantially and holding up on genuinely unseen, recent articles. Future work aims at heterogeneous graphs that jointly model articles, authors and sources, multilingual and cross-platform extension, and temporal modeling to track how bias evolves over time.

References

  1. Potthast M, Kiesel J, Reinartz K, Bevendorff J, Stein B. A Stylometric Inquiry into Hyperpartisan and Fake News. ACL 2018. aclanthology.org/P18-1022
  2. Srivastava V, et al. Vernon-Fenwick at SemEval-2019 Task 4: Hyperpartisan News Detection using Lexical and Semantic Features. aclanthology.org/S19-2189
  3. Jiang Y, Petrak J, Song X, Bontcheva K, Maynard D. Team Bertha von Suttner at SemEval-2019 Task 4. aclanthology.org/S19-2146
  4. Huang GKW, Lee JC. Hyperpartisan News and Articles Detection Using BERT and ELMo. IConDA 2019.
  5. Isbister T, Johansson F. Dick-Preston and Morbo at SemEval-2019 Task 4. aclanthology.org/S19-2160
  6. Shaprin D, Da San Martino G, Barrón-Cedeño A, Nakov P. Team Jack Ryder at SemEval-2019 Task 4. aclanthology.org/S19-2176
  7. Hanawa K, Sasaki S, Ouchi H, Suzuki J, Inui K. The Sally Smedley Hyperpartisan News Detector at SemEval-2019 Task 4. aclanthology.org/S19-2185
  8. Baly R, Da San Martino G, Glass J, Nakov P. We Can Detect Your Bias: Predicting the Political Ideology of News Articles. EMNLP 2020. aclanthology.org/2020.emnlp-main.404
  9. Ishlach K, Ben-David I, Fire M, Rokach L. A Novel Method for News Article Event-Based Embedding. 2024. arxiv.org/abs/2405.13071
  10. Raza S, Reji DJ, Ding C. Dbias: detecting biases and ensuring fairness in news articles. Intl J Data Sci & Analytics 2024;17(1):39-59. doi.org/10.1007/s41060-022-00359-4
  11. Ding K, Wang J, Li J, Li D, Liu H. Be More with Less: Hypergraph Attention Networks for Inductive Text Classification. EMNLP 2020. aclanthology.org/2020.emnlp-main.399
  12. You Y, Chen T, Sui Y, Chen T, Wang Z, Shen Y. Graph Contrastive Learning with Augmentations. NeurIPS 2020.
  13. Hamborg F, Donnay K, Gipp B. Automated identification of media bias in news articles: an interdisciplinary literature review. Intl J on Digital Libraries 2019;20(4):391-415. doi.org/10.1007/s00799-018-0261-y
  14. Naredla NR, Adedoyin FF. Detection of hyperpartisan news articles using natural language processing technique. Intl J of Information Management Data Insights 2022;2(1):100064. sciencedirect.com/…/S2667096822000088
  15. Mohan K, Chen P. Embedding-Based Approaches to Hyperpartisan News Detection. 2025. arxiv.org/abs/2501.01370
  16. Hasan MM, Hassan FB, Al Jubair M, Ahmed Z, Yeakin S, Billah MM. Bangla BERT for Hyperpartisan News Detection. NCIM 2025.
  17. Kiesel J, Mestre M, Shukla R, Vincent E, Adineh P, Corney D, et al. SemEval-2019 Task 4: Hyperpartisan News Detection. aclanthology.org/S19-2145