Datasets:
cjvt
/

solar3 / README.md
Matej Klemen
Multiple fixes:
b2bdc31
|
raw
history blame
8.12 kB
metadata
annotations_creators:
  - expert-generated
language:
  - sl
language_creators:
  - other
license:
  - cc-by-nc-sa-4.0
multilinguality:
  - monolingual
pretty_name: solar3
size_categories:
  - 100K<n<1M
  - 1K<n<10K
source_datasets:
  - original
tags:
  - error correction
  - primary school
  - secondary school
task_categories:
  - text2text-generation
  - other
task_ids:
  - text2text-generation-other-grammatical-error-correction
  - other-other-token-classification-of-text-errors

Dataset Card for solar3

Dataset Summary

Šolar* is a developmental corpus of 5485 school texts (e.g., essays), written by students in Slovenian secondary schools (age 15-19) and pupils in the 7th-9th grade of primary school (13-15), with a small percentage also from the 6th grade. Part of the corpus (1516 texts) is annotated with teachers' corrections using a system of labels described in the document available at https://www.clarin.si/repository/xmlui/bitstream/handle/11356/1589/Smernice-za-oznacevanje-korpusa-Solar_V1.1.pdf (in Slovenian).

(*) pronounce "š" as "sh" in "shoe".

The dataset is provided at sentence-level (125867 instances): each instance contains a source (the original) and a target (the corrected) sentence. Note that either the source or the target sentence in an instance may be missing - this usually happens when a source sentence is marked as redundant or when a new sentence is added by the teacher.
To convert the dataset into document-level (5485 instances), group the data by id_doc.

import itertools
from datasets import load_dataset, Dataset, DatasetDict
import pandas as pd

data = load_dataset("cjvt/solar3")

doc_df = {"id_doc": [], "doc_title": [], "is_manually_validated": [],
          "src_tokens": [], "tgt_tokens": [], "corrections": []}
for curr_id, curr_group in data["train"].to_pandas().groupby("id_doc"):
    first_instance = curr_group.iloc[0]

    doc_df["id_doc"].append(first_instance["id_doc"])
    doc_df["doc_title"].append(first_instance["doc_title"])
    doc_df["is_manually_validated"].append(curr_group["is_manually_validated"].all())
    doc_df["src_tokens"].append(
        list(itertools.chain(*[curr_tokens.tolist() for curr_tokens in curr_group["src_tokens"].values]))
    )
    doc_df["tgt_tokens"].append(
        list(itertools.chain(*[curr_tokens.tolist() for curr_tokens in curr_group["tgt_tokens"].values]))
    )
    doc_df["corrections"].append(
        list(itertools.chain(*[curr_corrs.tolist() for curr_corrs in curr_group["corrections"].values]))
    )

data = DatasetDict({
    "train": Dataset.from_pandas(pd.DataFrame(doc_df))
})

Supported Tasks and Leaderboards

Error correction, e.g., at token/sequence level, as token/sequence classification or text2text generation.

Languages

Slovenian.

Dataset Structure

Data Instances

A sample instance from the dataset:

{
    'id_doc': 'solar1', 
    'doc_title': 'KUS-G-slo-1-GO-E-2009-10001', 
    'is_manually_validated': True,  
    'id_src_tokens': ['solar1s.3.1.1', 'solar1s.3.1.2', 'solar1s.3.1.3', 'solar1s.3.1.4', 'solar1s.3.1.5', 'solar1s.3.1.6', 'solar1s.3.1.7', 'solar1s.3.1.8', 'solar1s.3.1.9', 'solar1s.3.1.10', 'solar1s.3.1.11', 'solar1s.3.1.12', 'solar1s.3.1.13', 'solar1s.3.1.14', 'solar1s.3.1.15', 'solar1s.3.1.16', 'solar1s.3.1.17', 'solar1s.3.1.18', 'solar1s.3.1.19', 'solar1s.3.1.20', 'solar1s.3.1.21', 'solar1s.3.1.22', 'solar1s.3.1.23', 'solar1s.3.1.24', 'solar1s.3.1.25'], 
    'src_tokens': ['”', 'Ne', 'da', 'sovražim', ',', 'da', 'ljubim', 'sem', 'na', 'svetu', '”', ',', 'izreče', 'Antigona', 'v', 'bran', 'kralju', 'Kreonu', 'za', 'svoje', 'nasprotno', 'mišljenje', 'pred', 'smrtjo', '.'],
    'id_tgt_tokens': ['solar1t.3.1.1', 'solar1t.3.1.2', 'solar1t.3.1.3', 'solar1t.3.1.4', 'solar1t.3.1.5', 'solar1t.3.1.6', 'solar1t.3.1.7', 'solar1t.3.1.8', 'solar1t.3.1.9', 'solar1t.3.1.10', 'solar1t.3.1.11', 'solar1t.3.1.12', 'solar1t.3.1.13', 'solar1t.3.1.14', 'solar1t.3.1.15', 'solar1t.3.1.16', 'solar1t.3.1.17', 'solar1t.3.1.18', 'solar1t.3.1.19', 'solar1t.3.1.20', 'solar1t.3.1.21', 'solar1t.3.1.22', 'solar1t.3.1.23', 'solar1t.3.1.24', 'solar1t.3.1.25', 'solar1t.3.1.26'], 
    'tgt_tokens': ['„', 'Ne', 'da', 'sovražim', ',', 'da', 'ljubim', 'sem', 'na', 'svetu', ',', '”', 'izreče', 'Antigona', 'sebi', 'v', 'bran', 'kralju', 'Kreonu', 'za', 'svoje', 'nasprotno', 'mišljenje', 'pred', 'smrtjo', '.'],
    'corrections': [
        {'idx_src': [0], 'idx_tgt': [0], 'corr_types': ['Z/LOČ/nerazvrščeno']}, 
        {'idx_src': [10, 11], 'idx_tgt': [10, 11], 'corr_types': ['Z/LOČ/nerazvrščeno']}, 
        {'idx_src': [], 'idx_tgt': [14], 'corr_types': ['O/KAT/povratnost']}
    ]
}

The instance represents a correction in the document 'solar1' (id_doc), which were manually assigned/validated (is_manually_validated). More concretely, the source sentence contains three errors (as indicated by three elements in corrections):

  • a punctuation change: '”' -> '„';
  • a punctuation change: ['”', ','] -> [',', '”'] (i.e. comma inside the quote, not outside);
  • addition of a new word: 'sebi'.

Data Fields

  • id_doc: a string containing the identifying name of the document in which the sentence appears;
  • doc_title: a string containing the assigned document title;
  • is_manually_validated: a bool indicating whether the document in which the sentence appears was reviewed by a teacher;
  • id_src_tokens: identifiers of words in the source sentence ([] if there is no source sentence);
  • src_tokens: words in the source sentence ([] if there is no source sentence);
  • id_tgt_tokens: identifiers of words in the target sentence ([] if there is no target sentence);
  • tgt_tokens: words in the target sentence ([] if there is no target sentence);
  • corrections: a list of the corrections, with each correction represented with a dictionary, containing the indices of the source tokens involved (idx_src), target tokens involved (idx_tgt), and the categories of the corrections made (corr_types). Please note that there can be multiple assigned categories for one annotated correction, in which case len(corr_types) > 1.

Note: idx_src_par, idx_src_sent, idx_tgt_par, idx_tgt_sent can be used to reconstruct the order of the sentences in the document (although in the above code snippet for grouping by documents, the instances are assumed to be listed in order of appearance).

Dataset Creation

The Developmental corpus Šolar consists of 5,485 texts written by students in Slovenian secondary schools (age 15-19) and pupils in the 7th-9th grade of primary school (13-15), with a small percentage also from the 6th grade. The information on school (elementary or secondary), subject, level (grade or year), type of text, region, and date of production is provided for each text. School essays form the majority of the corpus while other material includes texts created during lessons, such as text recapitulations or descriptions, examples of formal applications, etc.

Part of the corpus (1516 texts) is annotated with teachers' corrections using a system of labels described in the attached document (in Slovenian). Teacher corrections were part of the original files and reflect real classroom situations of essay marking. Corrections were then inserted into texts by annotators and subsequently categorized.

Additional Information

Dataset Curators

Špela Arhar Holdt; et al. (please see http://hdl.handle.net/11356/1589 for the full list)

Licensing Information

CC BY-NC-SA 4.0.

Citation Information

@misc{solar3,
  title = {Developmental corpus {\v S}olar 3.0},
  author = {Arhar Holdt, {\v S}pela and Rozman, Tadeja and Stritar Ku{\v c}uk, Mojca and Krek, Simon and Krap{\v s} Vodopivec, Irena and Stabej, Marko and Pori, Eva and Goli, Teja and Lavri{\v c}, Polona and Laskowski, Cyprian and Kocjan{\v c}i{\v c}, Polonca and Klemenc, Bojan and Krsnik, Luka and Kosem, Iztok},
   url = {http://hdl.handle.net/11356/1589},
   note = {Slovenian language resource repository {CLARIN}.{SI}},
   year = {2022}
 }

Contributions

Thanks to @matejklemen for adding this dataset.