Skip to content
intermediatetext

SwissGov-RSD Semantic Differences Between Parallel Texts

Highlight spans that differ in meaning between English and German texts and rate each difference from 1 to 5, using the span scheme. Items are illustrative.

Try it live — no install

Boot the real Potato server in your browser (WebAssembly) and annotate with this exact config. Nothing leaves your machine.

Run live in your browser

Get This Design

View on GitHub(opens in a new tab)

Clone or download from the repository

Quick start:

bash
git clone https://github.com/davidjurgens/potato-showcase.git
cd potato-showcase/text/cross-lingual/swissgov-rsd-semantic-differences
potato start config.yaml

About this dataset

SwissGov-RSD is a benchmark for token-level recognition of semantic differences between related documents, built by Michelle Wastl, Jannis Vamvas, and Rico Sennrich and published at ACL 2026. The texts come from Swiss federal authorities in several languages, and annotators mark which parts of a text differ in meaning from the other-language version. The labels are released on Hugging Face under CC BY 4.0, while the paper states that the copyright of the text remains with the Swiss federal authorities.

The paper's guideline asks annotators to identify differences and assign a label on a scale from 1 to 5, from mostly equivalent with unimportant details differing to completely dissimilar. The design reproduces the five levels as span labels with short names added, so annotators highlight a span in the English or German text and choose the level. The released data hold per-word labels for each text with no stored alignment, and the design matches that format. The paper allows an optional alignment to a span in the other language, which the design does not store. The ten English-German pairs are illustrative because the texts are not under the labels' license.

The config header describes a multi-stage protocol in which several annotators label each pair and a merge or review step follows, using num_annotators_per_item with the adjudication block, or data_files[].filter_by_prior_annotation and assignment_strategy: model_review. The model_training block lets the hf-token-classification trainer fine-tune a Hugging Face transformer to tag differing spans and write predictions back as pre-labels. The trainer needs the train-text extra, tags each text separately, and does not compare the two texts. From Potato 2.15.0, the pre_annotation export format writes the answers of one stage as the predictions_file of the next stage.

Sample items in this design
10 illustrative English-German pairs, not dataset texts
Difference levels
5 (paper, Appendix A.2)
Labels license
CC BY 4.0 (dataset card tag)

Configuration File

This Potato config reproduces the annotation task. Save it as config.yaml and run potato start config.yaml to try it.

yaml
# yaml-language-server: $schema=https://potatoannotator.readthedocs.io/en/latest/schemas/potato-config.schema.json
# SwissGov-RSD: token-level recognition of semantic differences between related documents
# Paper: Wastl, Vamvas and Sennrich (2026), "SwissGov-RSD: A Human-annotated, Cross-lingual Benchmark for
#   Token-level Recognition of Semantic Differences Between Related Documents", ACL 2026 (long, pages 31134-31163),
#   DOI 10.18653/v1/2026.acl-long.1437, https://aclanthology.org/2026.acl-long.1437/
#   (arXiv preprint: https://arxiv.org/abs/2512.07538)
# Dataset: https://huggingface.co/datasets/ZurichNLP/SwissGov-RSD (labels CC BY 4.0; "the copyright of
#   the text remains with the Swiss federal authorities"), code https://github.com/ZurichNLP/SwissGov-RSD
# Sample data: ten illustrative English-German pairs written for this design. None is a dataset item,
#   because the texts are not under the labels' licence.
# Guideline quotes (Appendix A.2 of the paper): "The task is to identify any such differences and
#   assign a label depending on the degree of semantic difference on a scale from 1 to 5."
#   1 "mostly equivalent, but some unimportant details differ"; 2 "roughly equivalent, but some
#   important information differs/missing"; 3 "not equivalent, but share some details"; 4 "not
#   equivalent, but are on the same topic"; 5 "completely dissimilar". Unannotated text counts as label 0.
# Adaptations: each annotation is one or more tokens in one text, "optionally aligned with a span in the other language"
#   (Section 3, Labeling Scheme). Here each span is labeled in its own text and no alignment link is stored,
#   so cross-text pairing of spans is lost. The released labels (HF card) are per-word labels for each text (labels_a,
#   labels_b) with no stored alignment, so this per-text design matches the released format. Tooltips drop the leading
#   "The two spans are" of the guideline wording; label names (e.g. "1 Minor detail") are short names added here.
# Alignment: a span_link scheme over the same span scheme can link a span in one text to a span in the other
#   (span_link works across two span_target fields). No link scheme is added here, to match the released per-word
#   labels.
# Multi-stage protocol: the design shows the span-labeling stage only, for one annotator. Several annotators per
#   pair, followed by a merge, could use num_annotators_per_item with the adjudication block, or chain a review
#   task with data_files[].filter_by_prior_annotation or assignment_strategy: model_review.
# model_training: the span scheme difference is consumed by the hf-token-classification trainer (pick it on
#   /admin/training), which fine-tunes a Hugging Face transformer to tag spans and writes predictions back as
#   pre-labels. It needs the train-text extra and a model download. The trainer tags spans in each text separately
#   and does not align the two texts or compare them.
#   From Potato 2.15.0, the pre_annotation export format (python -m potato.export --format pre_annotation)
#   writes stage 1's answers as the next stage's predictions_file.
annotation_task_name: "Semantic Differences Between Parallel Documents (SwissGov-RSD)"
task_dir: .
output_annotation_dir: annotation_output/
export_annotation_format: jsonl

data_files:
  - sample-data.json

item_properties:
  id_key: id
  text_key: english

instance_display:
  layout:
    direction: vertical
    gap: 16px
  fields:
    - key: english
      type: text
      label: "English"
      span_target: true
    - key: german
      type: text
      label: "German"
      span_target: true

user_config:
  allow_all_users: true
  users: []

# Demo settings. Replace the key with your own value before a real study.
require_password: false
admin_api_key: "demo-admin-key"

model_training:
  enabled: true
  writeback:
    schemas: ["difference"]
    include_unlabeled: true
    min_confidence: 0.6

annotation_instructions: |
  Each item is a pair of texts that should convey the same information. Highlight every span that
  differs in meaning from the other text and give it a degree of difference from 1 (minor, unimportant
  detail) to 5 (completely dissimilar, including text that is missing on the other side). Leave text
  that means the same in both languages unmarked.

annotation_schemes:
  - annotation_type: span
    name: difference
    description: "Highlight differing spans in either text and rate the degree of semantic difference"
    labels:
      - name: "1 Minor detail"
        tooltip: "Mostly equivalent, but some unimportant details differ"
        color: "#fde68a"
      - name: "2 Important detail"
        tooltip: "Roughly equivalent, but some important information differs or is missing"
        color: "#fdba74"
      - name: "3 Some shared details"
        tooltip: "Not equivalent, but share some details"
        color: "#fb923c"
      - name: "4 Same topic"
        tooltip: "Not equivalent, but on the same topic"
        color: "#f87171"
      - name: "5 Dissimilar"
        tooltip: "Completely dissimilar"
        color: "#dc2626"
    sequential_key_binding: true

site_dir: default

Sample Data

json
[
  {
    "id": "rsd_001",
    "english": "The Federal Council meets every Wednesday. It consists of seven members who decide collectively. The office of Federal President rotates every year.",
    "german": "Der Bundesrat tagt jeden Mittwoch. Er besteht aus sieben Mitgliedern, die gemeinsam entscheiden. Das Amt der Bundespräsidentin oder des Bundespräsidenten wechselt jedes Jahr. Die Sitzungen finden in Bern statt."
  },
  {
    "id": "rsd_002",
    "english": "Applications must be submitted by 30 June. Late applications will not be considered.",
    "german": "Gesuche müssen bis zum 31. Juli eingereicht werden. Verspätete Gesuche werden nicht berücksichtigt."
  }
]

// ... and 8 more items

Dataset & paper

Wastl et al., ACL 2026

Paper DOI
10.18653/v1/2026.acl-long.1437

Citation (BibTeX)

bibtex
@inproceedings{wastl-etal-2026-swissgov,
    title = "{S}wiss{G}ov-{RSD}: A Human-annotated, Cross-lingual Benchmark for Token-level Recognition of Semantic Differences Between Related Documents",
    author = "Wastl, Michelle  and
      Vamvas, Jannis  and
      Sennrich, Rico",
    editor = "Liakata, Maria  and
      Moreira, Viviane P.  and
      Zhang, Jiajun  and
      Jurgens, David",
    booktitle = "Proceedings of the 64th Annual Meeting of the {A}ssociation for {C}omputational {L}inguistics (Volume 1: Long Papers)",
    month = jul,
    year = "2026",
    address = "San Diego, California, United States",
    publisher = "Association for Computational Linguistics",
    url = "https://aclanthology.org/2026.acl-long.1437/",
    doi = "10.18653/v1/2026.acl-long.1437",
    pages = "31134--31163",
    ISBN = "979-8-89176-390-6"
}

Details

Annotation Types

span

Domain

Computational LinguisticsCross-lingual NLPMachine Translation

Use Cases

Semantic Difference DetectionSpan AnnotationCross-lingual Comparison

Tags

swissgov-rsdsemantic differencesenglishgermancross-lingualtoken-level

Found an issue or want to improve this design?

Open an Issue(opens in a new tab)