Elamur Research

Gender Swapping as a Data Augmentation Technique: Developing Gender-Balanced Datasets for Ukrainian Language Processing

Paper · 2025 · Olha Nahurna and Mariana Romanyshyn

Summary

A Ukrainian sentence can describe a woman while using a job title in its masculine form. That pattern matters for natural language processing because a system trained on such sentences sees relatively few examples of feminine titles and the words that agree with them. Ukraine’s 2019 spelling revision gave official guidance on forming feminine personal nouns, but those forms had been scarce in the corpora discussed by Nahurna and Romanyshyn. The authors use gender swapping to add examples. They take a sentence with a job title, rewrite it with the corresponding title of the other grammatical gender, and adjust other words as needed to keep the sentence grammatical.

The authors start with sentences from NER-UK 2.0, a Ukrainian corpus that already marks job titles and personal names. GPT-4o-mini drafts the alternate sentences, and native Ukrainian speakers accept, edit, or reject them. Review matters even when the output looks structurally similar to the original. Annotators corrected 37.6% of the drafts, addressing errors such as invented feminine titles, inconsistent agreement, and changes to words outside the target. The resulting parallel corpus contains 1,403 sentence pairs. The authors use the pairs and a dictionary of masculine and feminine counterparts for fine-tuning Aya-101, a multilingual system that follows editing instructions. On the held-out sentences it improves substantially over the original Aya-101 and performs broadly comparably to GPT-4o-mini, with better agreement on job titles and a slightly lower rate of verbatim sentence matches.

The second experiment asks whether adding the rewritten sentences helps named entity recognition, the task of finding and labeling expressions such as job titles and names. With the expanded training data, job-title F1, which combines precision and recall, rises from 79.18 to 85.42 on the swapped test subset and from 73.59 to 74.81 on the test set that combines original and swapped sentences. On the original test set, where masculine titles predominate, it falls from 69.64 to 66.10. The breakdown by grammatical gender shows the tradeoff directly. Recall, the share of annotated titles the system finds, improves from 0.69 to 0.80 for feminine titles and from 0.85 to 0.87 for common-gender titles. For masculine titles it falls from 0.64 to 0.59.

The authors release the parallel sentences, the swapped subset of NER-UK 2.0, and the fine-tuned Aya-101. The findings show that adding alternative forms can help a recognizer find an underrepresented kind of title, with results that depend on which sentences it encounters. The rewrite itself also has limits. It sees a sentence at a time, favors certain feminine names, sometimes invents names, and can turn a factual statement about a real person into an inaccurate one.

Deep dive: Gender Swapping as a Data Augmentation Technique: Developing Gender-Balanced Datasets for Ukrainian Language Processing

Gender swapping adds feminine job titles to Ukrainian training data, improving their recognition while making masculine titles easier to miss. · about 34 minutes to read

The problem and its context

What a corpus teaches about occupations

In Ukrainian, an occupation can be expressed by a noun with a masculine form and a distinct feminine counterpart, known as a feminitive. The authors describe a tradition of using masculine professional titles, including in sentences whose other words identify the person as a woman. Their introductory example describes a woman who helped the speaker and is praised as a doctor. The sentence uses feminine agreement elsewhere while retaining the masculine noun лікар. The feminine лікарка would bring the title into agreement with the surrounding construction in the authors’ analysis. A corpus can therefore contain references to women in professional roles while offering relatively few examples of the corresponding feminine job titles.

This distinction matters when the object of study is the linguistic evidence available for training. More occurrences of a woman’s name do not themselves supply examples of a feminine noun for her occupation. A tagger can encounter that name, a feminine pronoun, and a masculine professional title together. Those examples teach the system something about how the title is used in existing texts. They give it little direct practice locating a feminine counterpart in the same kinds of sentences. The paper turns this difference into an empirical question about what changes when the training material contains both variants.

The 2019 orthographic revision is part of the authors’ explanation for why the supply of examples is uneven. The revision gave official guidance on forming feminine personal nouns. The authors cite corpus research describing their sparse use before the revision, and they note that adoption of the newer practices is recent and sometimes controversial. The gap between guidance and the contents of existing corpora creates a practical problem. A processing system may be expected to handle expressions whose use is becoming more visible while learning mostly from material that reflects earlier conventions.

The paper situates this problem within research on bias, fairness, and safety. Its review describes how statistical systems can learn unequal associations already present in their data, with recruitment as an example of a setting in which inherited patterns can have consequences. The Ukrainian experiments narrow the question to occupational nouns and their linguistic context. They examine the production of alternate sentence forms and the detection of occupational expressions when the distribution of grammatical forms changes. Keeping the question at that level allows the authors to evaluate a specific intervention using annotated sentences.

Why swapping a word can require editing a sentence

The central linguistic difficulty is morphology, the way words take different forms. A dictionary can tell an editor that a masculine noun has a feminine counterpart. The editor still has to choose the counterpart’s form in context and work out which other words follow its gender. An adjective describing the person may need to change. A verb can also carry gender, as the paper’s example with a doctor on duty illustrates. Meanwhile, an adjective that describes a different noun may already be correct and need to stay as it is.

This creates a problem of scope as well as word formation. A sentence can mention several people, and grammatical cues can belong to different referents. An editor has to recognize which descriptive material goes with a target and which belongs to another expression. Some targets have no visible masculine and feminine alternation in the noun. A word such as суддя, meaning judge, can serve as a common-gender title while its surroundings supply the relevant agreement. Looking for a new ending on every targeted noun would miss this difference between the form of the noun and the grammatical work done by related words.

The authors place Ukrainian alongside other languages for which gender-aware editing can extend beyond pronouns. Their review points to work involving Spanish, Arabic, French, and Slovenian as examples of the broader challenges posed by gender marking. The point is concrete. Finding a counterpart answers a question about a lexical item. Inserting it into a usable sentence also requires decisions about agreement, interpretation, and which parts of the input to preserve. A substitution may be correct in a list of word pairs and still produce an inconsistent sentence when applied in isolation.

Earlier ways of changing the training data

The paper distinguishes gender neutralization from adding gender-marked alternatives. A neutral expression can be useful where a person’s gender is irrelevant to the message. The authors cite research in which learners of English could read the ending of an occupational term such as postman as a restriction on who can hold the job. They also describe work that assembled and checked a catalog of 692 gender-exclusive terms with neutral counterparts and used it to construct training examples. That approach aims to make the resulting expression usable without specifying gender. The Ukrainian study instead needs examples in which a particular grammatical form and its agreement remain visible.

The tradition it draws on is counterfactual data augmentation. Here, a counterfactual is an alternate version of a training sentence in which selected gender cues change while the surrounding situation is kept as stable as the rewrite allows. Adding that counterpart exposes the system to an occupation in a syntactic setting it might otherwise see mainly with one grammatical gender. The paper discusses early dictionary-based approaches in connection with Gender Bias in Neural Natural Language Processing. A paired dictionary gives a rule-based procedure a supply of possible replacements. Its coverage constrains which words it can change, and separate logic has to handle agreement.

Earlier work had already tackled that second problem. The authors describe counterfactual augmentation for languages with rich morphology using a Markov random field to coordinate agreement after a substitution, with an optional neural way to supply its parameters. They report that it was used to make datasets in Spanish, Hebrew, French, and Italian. They also discuss an English method for augmenting examples of singular they. It uses part-of-speech tagging to identify grammatical categories and dependency parsing to represent relationships between words relevant to agreement. In both cases, the operation extends past the item chosen for replacement.

The review also covers Fairflow, an English approach designed for settings with little suitable parallel data. It identifies gender-marked items using representations from BERT, generates counterfactual equivalents with a separate network, and applies an error correction stage to the resulting sentences. As described by the authors, its testing was confined to English. It is relevant to their design because it separates finding a target, producing an alternate form, and repairing the surrounding text, even though its components differ from the Ukrainian pipeline.

A large language model offers a way to carry out several of those edits together. Given a sentence and instructions, it can produce a complete rewrite, including substitutions and agreement changes, in one response. The authors also identify the risk in that freedom. A generator can make unsupported changes, invent a word or a name, or apply the requested pattern inconsistently. Their design uses a generator to propose candidates and native speakers to decide which forms belong in the training material. They describe this application of prompted counterfactual augmentation as a direction that, to their knowledge, had yet to be studied for Ukrainian.

The method, step by step

Select sentences and identify what can change

The pipeline starts with a collection of sentences containing expressions that could be rewritten for gender. In principle, the authors say, the target set can include personal names, pronouns, and nouns describing people. How to find them depends on the available resources. A researcher could identify them manually, use a lexicon or grammatical tags, or draw on entity labels already present in a corpus. In the Ukrainian experiment, the existing annotations provide a way to select occupational contexts without first running a search for every possible written form of a title.

NER-UK 2.0 combines Nashi Groshi, news material about the Ukrainian economy and anticorruption efforts, with the multigenre BRUK collection. Its linguistic annotation marks spans of text and assigns them entity types. The authors use JOB for occupational expressions and PERS for names of people. They take every sentence containing a JOB span. A personal name in such a sentence can help establish who occupies the role or become part of the rewrite. Names also occur elsewhere in the complete recognition corpus, so the names in the selected occupational sentences form a narrower collection.

A JOB label identifies an expression as a title, but its grammatical gender is separate information. The authors derive that information using three resources together. They use pymorphy3 for lemmatization, which relates an inflected word to its dictionary form. They use stanza to analyze syntax, and they consult a gender-paired dictionary assembled and checked with experts from GenderGid. The dictionary contains 1,102 entries. Linking a written word to a dictionary entry matters because a title in a sentence can appear in a grammatical case different from that of its headword. The syntactic analysis supplies information about the occurrence that the isolated dictionary entry cannot supply.

For the selected JOB and PERS spans, the classification procedure allows masculine, feminine, common, and unknown outcomes. Common gender covers words capable of combining with masculine or feminine agreement and, in some cases described by the authors, neuter agreement. Unknown covers instances for which the available evidence does not support a reliable assignment. Surnames are an important source of uncertainty. Their written forms can be compatible with more than one interpretation, and the sentence may contain too little evidence to disambiguate them. Keeping an unknown category preserves that uncertainty in the description of the corpus. The authors release their classification code and make the paired dictionary available as a separate resource.

Building and using Ukrainian gender-swapped data

The steps in order.

Building and using Ukrainian gender-swapped dataStep 1: Select sentences with annotated job titles1. Select sentences with annotated job titlesStep 2: Classify the gender of target entities2. Classify the gender of target entitiesStep 3: Prompt GPT-4o-mini to draft counterfactual sentences3. Prompt GPT-4o-mini to draft counterfactual sentencesStep 4: Review and filter the sentence pairs4. Review and filter the sentence pairsStep 5: Fine-tune Aya-101 on sentence and word pairs5. Fine-tune Aya-101 on sentence and word pairsStep 6: Transfer entity labels and recalculate span positions6. Transfer entity labels and recalculate span positionsStep 7: Train recognition on original and swapped sentences7. Train recognition on original and swapped sentences

Give the generator a constrained editing task

Each generation request includes the original sentence and a list of its target entities with their types. This gives GPT-4o-mini guidance about where the changes belong. The instructions ask for masculine expressions to take feminine counterparts and for feminine expressions to take masculine counterparts. They also ask the generator to preserve gender-neutral expressions and repair agreement around the changed targets. The full sentence is the output because the job title alone cannot account for all the edits the task may require.

The prompt uses few-shot learning in the sense of placing several hand-written demonstrations in the request. The demonstrations show the form of the requested edit and the relationship expected between the source and rewritten sentences. They work alongside explicit instructions and constraints. A demonstration can show, for example, that a dependent word is allowed to change even though the original target list names an entity span. It can also convey that the rest of the sentence should remain close to the source. The authors release the prompt template.

Each prompt additionally receives three male names and three female names sampled from a Ukrainian name frequency dictionary. This supplies possible substitutes without leaving the generator to draw every name from its own preferred vocabulary. A name change differs from many occupation changes because several names can serve as plausible replacements. A feminine job counterpart may be strongly constrained by the source noun and its meaning. The particular given name for the alternate person can admit more latitude. The candidate list addresses that choice at initial generation time and becomes important when interpreting metrics that compare names literally.

The paper’s example of a doctor on duty shows why both the span and its surroundings matter. The masculine черговий лікар becomes чергова лікарка. The title noun changes, and the adjective within the expression takes the feminine form. The past-tense verb поінформував, meaning informed, becomes поінформувала. That verb lies outside the occupational expression, yet it must agree with the person whose role the expression names. The example also shows that the information about what happened can remain stable even when several word forms are changed.

The pipeline’s notion of a counterpart is therefore more specific than an ordinary paraphrase. It asks the generator to keep the occupation and surrounding event recognizable while changing the relevant gender cues. The intended operation can reach across the sentence, although its scope is bounded by the target and the need for grammatical agreement. Editing an unrelated noun or introducing an extra name can produce a fluent sentence that is unsuitable as a matched alternative. The human review is where those decisions are checked against the source.

Review the alternate sentences and form the parallel corpus

The authors recruit sixteen native Ukrainian speakers from the Ukrainian NLP community. For each item, a reviewer sees the source sentence, the draft rewrite, and the entities in scope. The reviewer can accept a suitable draft, correct a draft that can be repaired, or dismiss a case in which a defensible rewrite is difficult to establish. The guidelines describe the editing procedure, grammatical constraints, and examples, and point reviewers to dictionaries. The authors publish those guidelines in Ukrainian and English.

The dismissal option addresses problems that go beyond selecting the right inflection. A reviewer may judge that the target lacks an appropriate counterpart in context or that the sentence should stay as written. A procedure that required an alternate string for every source would turn such cases into supervision for changes the reviewers could not justify. Correction deals with a different situation. A sentence can have a useful counterpart even if the generator missed an agreement change, chose an implausible occupational form, or rewrote a name unnecessarily. The edited output then becomes the counterpart that the later experiment uses.

The authors call the drafts bronze quality and the reviewed pairs silver quality. In practical terms, the distinction tells a reader which stage produced the text used for training. The final corpus contains accepted and corrected rewrites after filtering. The authors remove dismissed items and also remove the reported 4% of duplicates in which an item marked for correction ended up identical to the source and carried no gender modification. An unchanged pair would provide a different kind of instruction example from the intended examples of inversion.

The authors then check occupational counterparts against the GenderGid dictionary. They extract corresponding job-title expressions from the sentence pairs and look up the resulting candidate pairings. This check asks whether a recognized lexical pairing supports the substitution. Agreement elsewhere in the sentence remains a separate issue, and a pair can be absent from the dictionary even when a reviewer finds it acceptable in context. The check and the human review accordingly supply different kinds of evidence about the finished corpus.

Fine-tune a system to perform the rewrite

The authors divide the parallel sentence data into training and test portions and use the training examples to adapt Aya-101. It is already instruction-tuned, supports 101 languages including Ukrainian, and had been used for Ukrainian text editing in earlier work cited by the authors. The training objective in this experiment is to teach an existing instruction-following system to handle a narrowly defined Ukrainian rewrite.

The training examples use a sentence-level instruction and a word-level instruction. In the first task, the input contains a sentence and a request to invert its gender-marked entities. The output is the counterpart from the reviewed corpus. This gives Aya-101 examples in which a title, name, or other targeted expression can change along with related words. In the second task, the input is an individual word with an instruction to give the counterpart of the other gender. Randomly selected GenderGid word pairs supply these examples. The word task emphasizes lexical choice, while the sentence task supplies the context needed to learn coordinated edits.

The authors vary the order of the source and target sides in the parallel training examples and the order of words in the dictionary pairs. Most sentences in the original collection had been rewritten from masculine to feminine. Reversing the order in training gives the system examples in both directions. This choice matters for an instruction stated as inversion. A training collection that mostly shows masculine input followed by feminine output could make response direction easier to infer from the dominant pattern than from the actual input forms.

The Aya-101 base used for training is the 13B version. The authors use a parameter-efficient fine-tuning framework with QLoRA, which adapts a quantized base through trainable low-rank components. They run the training on an A100 GPU in Google Colab Pro+, with batch size 4, learning rate 5e-5, and the AdamW optimizer. The paired corpus and the adapted Aya-101 are released publicly. The generator used initially to draft examples and the system trained on the reviewed examples occupy distinct roles in the pipeline.

Put the alternate sentences back into a recognition dataset

For the recognition experiment, the authors treat the validated rewrites as alternate annotated examples of the source sentences. The original corpus already gives the type of each annotated span. A rewritten job title still has the JOB type, and a substituted name can still carry PERS. Other entities in the sentence can also retain their original type. This lets the researchers build on the existing annotation rather than label the rewritten collection from the beginning.

The position of a span requires a separate update. The corpus annotations locate entities by character offsets, which specify where a span starts and ends in the text. A longer or shorter spelling can shift the end of the edited span and the location of later entities. The authors recalculate the positions in the swapped text and record the original sentence IDs in .meta files. A nearly unchanged token count is compatible with shifted character offsets. A single token can keep its place in the sentence while changing its length enough to move all the subsequent spans.

The swapped sentences retain the partition of their originals in NER-UK 2.0. A counterpart to an original test sentence remains on the test side, and a counterpart to an original training sentence stays on the training side. The authors then merge the two versions to make the augmented corpus. Sentences without a retained counterpart remain represented by their original text. Since the selection was based on job titles, the added sentences contain other entity types as well, but those additions arise through the contexts in which occupational expressions occur.

The augmented training split is used to train a recognizer built on the Ukrainian version of RoBERTa-large from the WECHSEL work and implemented with spaCy. The authors follow the training setup and configuration described for the published NER-UK 2.0 baseline. This final stage tests what happens when the reviewed data change the examples available to an otherwise comparable recognition pipeline. It does not require running Aya-101 on the recognizer’s outputs or prompting it to classify titles.

Measure which annotated job titles the recognizer finds

For the gender-specific recognition analysis, the authors classify the correctly identified and missed JOB entities with the same grammatical gender procedure used to describe the source data. They then calculate recall separately for the categories in the following formula.

Recall_g = |TP_g| / (|TP_g| + |FN_g|), for g ∈ {male, female, common}

Recall_g is the share of annotated job-title occurrences in category g that the recognizer finds correctly. The subscript g indicates that the calculation uses just the category being evaluated. TP_g is the set of true positives in that category, meaning annotated titles correctly identified. FN_g is the set of false negatives, meaning annotated titles the recognizer misses. The vertical bars give the number of items in a set. The plus sign combines the found and missed occurrences to give the total available to find, and the slash divides the number found by that total. The symbol ∈ indicates that g is chosen from the categories in braces. In the terminology of the analysis, male and female correspond to masculine and feminine job-title forms, and common denotes the common-gender category. Unknown cases are outside the categories in the formula.

This calculation focuses on missed annotated titles. Precision answers a different question by considering which predicted spans are correct. The authors use both measures, along with F1, in the broader evaluation. The category-specific recall makes it possible to see whether the new training data change which grammatical forms tend to be found, even when a single aggregate F1 score blends those outcomes together.

Experiments and results

How much of the initial corpus could be reused?

Selecting the occupational sentences from NER-UK 2.0 yields 1,513 sentences containing 1,982 JOB spans and 1,384 PERS spans. These are span counts, so a sentence can contribute several entities. In the paper’s tabulated breakdown, the selected occupational spans include 1,646 masculine titles, 76 feminine titles, 223 common-gender titles, and 37 with unknown gender. The same table reports 83% masculine and 3.8% feminine. The sample is therefore strongly skewed toward masculine titles before any sentence is rewritten.

The subcorpora differ in their mix of forms, but the imbalance appears in both. In the selected Nashi Groshi material, 84.4% of JOB spans are masculine and 2.0% feminine. In BRUK, the corresponding figures are 80.0% and 7.6%. Feminine occupational forms are more frequent in the selected BRUK material, yet their share remains much smaller than the masculine share. Pooling the sources gives the augmentation a variety of contexts while retaining a substantial imbalance to address.

The names in the occupational sample have a different distribution. Among its PERS spans, 48.2% are classified as masculine and 16.7% as feminine, with 35.1% unknown. Those percentages concern names in sentences selected for containing an occupation. The wider corpus contains many additional names. The authors attribute much of the uncertainty to surnames whose forms alone are ambiguous. This matters for interpreting the distribution. An unknown name belongs in the count of annotated people’s names, even when the method cannot assign it to one of the reported gender categories.

Native speakers accept 58.5% of the GPT-4o-mini drafts without editing, correct 37.6%, and dismiss 3.9%. The corrections address several distinct problems. Some rewrites change names or nouns that should have stayed in place. Others mishandle plural titles, leave conflicting agreement, or produce rare or invented names. Some drafts use feminine forms of occupational nouns that reviewers judge invalid. Reviewers also encounter original sentences whose forms already disagree, making the appropriate rewrite harder to establish. The acceptance rate describes how frequently the drafts passed this review, while the corrections show how much of the usable corpus depended on edits after generation.

The token-count comparison looks more favorable than a simple reading of the correction rate might suggest. The match rate is 0.97 for original and GPT-generated sentences, 0.96 for GPT outputs and annotated versions, and 0.95 for originals and annotated versions. Here a match means equal token counts under the comparison. Several words can be substituted without adding or dropping a token, and a corrected ending can leave the count untouched. High rates therefore support the claim that the rewrites tend to stay close to the original in length. Review still catches errors within that shared length.

After review and filtering, the authors report 1,403 parallel pairs, with 1,733 JOB spans and 1,282 PERS spans in the resulting material. The dictionary check finds 83% of the evaluated occupational pairings in GenderGid. The check provides a second indication that many of the chosen counterparts correspond to entries validated by experts. Its coverage is especially relevant to the central operation of turning an occupational expression into the appropriate alternate form. The manual judgments also apply to cases where the dictionary cannot settle the question by itself.

How the trained swapper compares with the baselines

On the held-out parallel test split, the authors evaluate the original Aya-101, the fine-tuned Aya-101, and GPT-4o-mini. The original Aya-101 provides a baseline for what the already instruction-tuned system can do before this task-specific training. GPT-4o-mini provides a comparison with the system used to draft the initial pairs. The test targets are the reviewed counterparts. They can consequently agree with the original GPT draft, reflect a human correction, or otherwise differ from a fresh output by any of the systems.

Exact Match asks whether a generated sentence and its test counterpart agree as strings. This places all edits under a strict standard, including the name chosen for a person. Exact Match without PERS ignores personal names, so it asks whether the rest of the output matches. JOB Match narrows the comparison further to the occupational expressions. It measures agreement on the target job titles and is especially pertinent because correct occupational substitutions are the reason these sentences were chosen in the first place.

The broader similarity measures look at other properties of the output. The BLEU score considers overlap in sequences of tokens, giving credit for wording shared with the target when the strings differ. ROUGE-L uses a longest common subsequence, a sequence that appears in both texts in the same relative order and can have gaps. BERTScore F1 uses context-sensitive representations to compare the texts, making it possible for different forms or similar words to receive credit for resemblance. Token Count Match simply checks whether an output has the same token count as the reference. Each metric can register some kinds of preservation more readily than it detects an incorrect gender-bearing form.

JOB Match on the held-out Ukrainian gender-swapping test set

Fine-tuned Aya-101 matches the reference job titles most often.

JOB Match on the held-out Ukrainian gender-swapping test setOriginal Aya-101: 0.30Original Aya-1010.30GPT-4o-mini: 0.65GPT-4o-mini0.65Fine-tuned Aya-101 (this paper): 0.82Fine-tuned Aya-101 (this paper)0.82
The numbers
System or settingJOB Match
Original Aya-1010.30
GPT-4o-mini0.65
Fine-tuned Aya-101 (this paper)0.82

For full Exact Match, the original Aya-101 scores 0.15, fine-tuned Aya-101 scores 0.44, and GPT-4o-mini scores 0.45. With person names ignored, their scores in that order are 0.22, 0.64, and 0.62. The ordering of the latter two systems therefore depends on whether the choice of name enters the comparison. On a task with many possible names for a rewritten person, these two versions of Exact Match answer meaningfully different questions. The stricter score records exact agreement with the chosen reference. The version without names allows greater variation in a part of the output that can admit multiple plausible choices.

The original, fine-tuned, and GPT systems score 0.65, 0.82, and 0.82 on BLEU. Their corresponding BERTScore F1 results are 0.97, 0.99, and 0.99. ROUGE-L changes little, with 0.21 for both versions of Aya-101 and 0.22 for GPT-4o-mini. Token Count Match is 0.69 for original Aya-101, 0.92 after fine-tuning, and 0.91 for GPT-4o-mini. The separation between the systems is thus much clearer on some measures than others. The original Aya-101 already scores 0.97 on contextual similarity despite a JOB Match of 0.30. A sentence largely about the same event can receive high credit on contextual similarity while missing the requested occupational form.

These comparisons support the authors’ conclusion that fine-tuning improves Aya-101 on the rewrite task and brings its results broadly in line with GPT-4o-mini. On the metric centered on the selected occupational expression, the adapted Aya-101 has the highest reported score. On literal agreement with the entire reviewed sentence, GPT-4o-mini leads narrowly. The test accordingly provides evidence for the smaller task-specific system’s performance on Ukrainian gender swapping under the study’s conditions. It gives different answers depending on how much freedom the evaluation permits in the rewritten wording.

What changed in the recognition corpus?

The corpus inventories distinguish the original collection, the swapped subset, and the collection made by combining them. The original inventory contains 21,993 entity spans and the swapped inventory contains 5,385. The total reported for the augmented corpus is 27,378. For JOB, the inventories give 1,982 original spans, 1,733 swapped spans, and 3,715 augmented spans. The original corpus therefore retains its occupational examples and adds the counterparts that survived review and filtering. Because some sentences were excluded, an original occupational example does not always have a counterpart in the augmented set.

The composition of the occupational spans shifts from 83% masculine and 3.8% feminine in the original inventory to 49.2% masculine and 37.4% feminine in the augmented inventory. Common-gender and unknown instances remain in the data as well. Thus the added material changes the distribution considerably, with a remaining difference between the masculine and feminine shares. The term gender-balanced refers to that better representation in the augmented collection. The reported shares indicate the degree of balance the procedure actually achieves.

For PERS across the corpus inventories, the original counts include 6,235 spans and the augmented counts include 7,517. The masculine and feminine shares shift from 34.0% and 20.6% in the original inventory to 30.2% and 26.8% in the augmented inventory. The unknown category accounts for 45.4% of the original name spans and 42.9% of the augmented name spans. These are the wider corpus figures, distinct from the name distribution among the sentences first selected for rewriting. The relatively large unknown share limits how completely the name distribution can be described from the assigned categories.

The merge also adds spans of other kinds because the selected sentences contain more than occupations and names. As an example, the paper reports 5,213 ORG spans in the original corpus and 6,480 in the augmented one. An organization may remain unchanged in a rewritten sentence while its nearby occupation changes. Its label still provides an additional training occurrence in that context. The recognition experiment therefore changes exposure to other labels as well as the quantity and relative frequency of gender-marked titles.

Where job-title recognition improves and where it declines

The recognition baseline is uk_ner_web_trf_13class, the system released with NER-UK 2.0 that the authors describe as the current benchmark for Ukrainian. The paper calls it Original NER and calls the recognizer trained on the expanded split Gender-Balanced NER. Both are tested on the original test split, the test subset made from gender-swapped counterparts, and the union of these two sets. The original split captures performance on the established benchmark. The swapped subset is drawn from occupational sentences whose validated counterparts could be constructed. The union tests performance with both kinds of material present.

Precision measures how often the spans predicted for an entity type are correct. Recall measures how often its annotated spans are identified. F1 combines the two, so a system can produce somewhat more accurate predictions while losing F1 if it misses sufficiently more of the entities. This is what happens for JOB on the original test split. Precision moves from 74.39 for Original NER to 75.05 for Gender-Balanced NER. Recall falls from 65.45 to 59.06. The original split’s job-title F1 falls from 69.64 to 66.10.

On the gender-swapped test subset, both measures favor the new recognizer. For JOB, precision rises from 89.08 to 90.63, while recall rises from 71.26 to 80.78. The increase in recall shows that the augmented system finds more of the annotated job titles in these alternative sentences. The corresponding F1 comparison is the strongest of the paper’s reported job-title F1 gains across the test settings.

Job-title recognition F1 on the swapped NER-UK 2.0 test subset

Training with augmented data improves job-title recognition on the swapped sentences.

Job-title recognition F1 on the swapped NER-UK 2.0 test subsetOriginal NER: 79.18Original NER79.18Gender-Balanced NER (this paper): 85.42Gender-Balanced NER (this paper)85.42
The numbers
System or settingF1
Original NER79.18
Gender-Balanced NER (this paper)85.42

On the augmented test set, JOB precision increases from 80.53 to 82.51 and recall increases from 67.75 to 68.43. F1 rises from 73.59 to 74.81. This pooled outcome reflects the collection formed by adding the retained alternate sentences to the original test data. It is smaller than the gain on the swapped subset by itself and accompanies a decline on the original split. Each comparison specifies which sentences the systems had to recognize. That context is necessary to interpret the pooled result.

The PERS scores are closer across the two recognizers. On the original split, PERS F1 is 96.40 for Original NER and 96.08 for Gender-Balanced NER. On the swapped subset, the corresponding figures are 98.60 and 98.74. On the augmented set, they are 96.79 and 96.38. The authors suggest that both genders in the original training data were already represented well enough for name recognition to have a stronger starting point than occupational-title recognition. The comparison itself establishes that the reported PERS scores change relatively little. It leaves the explanation about prior representation as a plausible interpretation.

The paper also reports weighted F1 across entity types. It changes from 88.13 to 88.42 on the original split, from 88.87 to 91.20 on the swapped subset, and from 88.34 to 88.89 on the augmented test set. These aggregate measures let the reader see the occupational experiment in the context of the full recognition task. The slight gain in weighted F1 on the original split coexists with the drop for JOB on that split. A weighted result can therefore indicate how the recognizer performs overall while leaving a specific loss visible only in the category-level results.

What the ablations show

The paper offers baseline comparisons, a round-trip rewriting test, an analysis of human corrections, and a recall breakdown by grammatical gender. It reports no component-by-component ablation in which the prompt demonstrations, candidate names, manual review, or word-pair training are individually removed. Its comparisons show the behavior of the complete pipelines and help locate where their outcomes change.

What survives a second rewrite?

The round-trip test asks a system to swap a sentence and then apply gender swapping again to its own output. The target for the resulting sentence is the original. This probes whether the edits can be reversed and whether the first rewrite preserves enough information and structure for the system to reconstruct the source. If a first pass drops or replaces a detail, the second pass has to recover it from a sentence in which that detail may no longer appear. That makes the diagnostic sensitive to accumulated changes as well as the choice of gendered forms.

On the round-trip test, Exact Match is 0.21 for original Aya-101, 0.52 for fine-tuned Aya-101, and 0.51 for GPT-4o-mini. Removing personal names from the exact comparison gives 0.34, 0.73, and 0.70, respectively. The fine-tuned Aya-101 again approaches or exceeds the GPT comparator on those reference-based measures, and disregarding names again yields more matches. The test tells the reader how closely systems can return to the starting text after two transformations, under both a strict and a name-insensitive comparison.

On round-trip JOB Match, the original Aya-101 scores 0.76, the fine-tuned version 0.87, and GPT-4o-mini 0.62. The original Aya-101’s 0.76 is much higher than its 0.30 for one-way JOB Match. That change is intelligible because the target is different in the two experiments. To match a one-way target, a system has to supply the alternate form. To match the final round-trip target, it has to end with the original form. A round trip could finish with the correct title even if an intermediate title were preserved or changed incorrectly. The paper does not identify that as the cause of a particular score, but the design explains why endpoint reconstruction and one-way transformation are separate tests.

The remaining round-trip results give additional points of comparison. For original Aya-101, fine-tuned Aya-101, and GPT-4o-mini in that order, BLEU is 0.79, 0.87, and 0.85. ROUGE-L is 0.21, 0.21, and 0.22. BERTScore F1 is 0.97, 0.99, and 0.99. The token-count match rates are 0.64, 0.93, and 0.91. Fine-tuning shows a clearer advantage on several measures that track preservation of the actual text than on ROUGE-L or BERTScore. The evaluation of one-way title changes remains necessary because reversal alone can reward returning to the original form without a successful intermediate rewrite.

What human corrections reveal about the prompt

The comparison of GPT drafts and reviewed sentences supplies evidence about errors that generic overlap measures can miss. An invalid feminine occupational noun can be only a short edit away from a valid word. A verb with the wrong gender ending can preserve both the token count and much of its surface form. A substituted personal name can be plausible as a string while failing the instructions for which entities to rewrite. The annotators assess these details against the target list and the original sentence. Their decisions show why form, scope, and lexical validity each matter in a task designed to produce closely matched pairs.

Original sentences with inconsistent agreement expose another kind of difficulty. The starting material may already contain a masculine title with feminine context. A successful rewrite then depends on how the annotator interprets the intended person and what constitutes an appropriate counterpart for that occurrence. The diagnosis comes from the reported review of corrections and dismissals. It identifies a source of ambiguity even for native speakers applying guidelines, and it explains why the corpus construction allows cases to be removed rather than requiring each input to yield a validated alternate.

The two Exact Match variants expose the influence of name choice from another angle. On the one-way test, GPT-4o-mini has the higher full Exact Match, while the fine-tuned Aya-101 has the higher Exact Match once PERS is ignored. The paper also examines the names generated by Aya-101 directly. It finds that Наталія accounts for 25% of the feminine names generated during evaluation, and it observes occasional names that do not exist. The authors contrast that concentration with the name distribution of the original generated dataset, which they describe as reflecting the name frequency dictionary used for prompting. They suggest that pretraining may explain the fine-tuned system’s preference. The distributional observation supports the existence of the preference, while the experiment leaves its source open.

Which grammatical forms account for the recognition trade-off?

To examine the lower original-set job-title results and the higher swapped-set results, the authors group the annotated titles by grammatical gender and calculate recall for each group. This analysis counts correctly located titles and misses within each reported category. It targets the aspect of recognition most clearly affected in the test-set results. The big change for swapped JOB spans was in recall, and the original set’s F1 decline likewise accompanied a drop in recall. The breakdown asks which forms the recognizer is more or less likely to find after augmentation.

Feminine JOB recall in the NER-UK 2.0 gender breakdown

The recognizer trained with augmented examples finds more annotated feminine job titles.

Feminine JOB recall in the NER-UK 2.0 gender breakdownOriginal NER: 0.69Original NER0.69Gender-Balanced NER (this paper): 0.80Gender-Balanced NER (this paper)0.80
The numbers
System or settingRecall
Original NER0.69
Gender-Balanced NER (this paper)0.80

The other categories move differently. Masculine job-title recall is 0.64 for Original NER and 0.59 for Gender-Balanced NER. Common-gender recall is 0.85 and 0.87, respectively. The published breakdown presents a comparison for each grammatical category, without a full separate breakdown for every test split. Read alongside the split results, it suggests that the aggregate scores respond to the types of job titles encountered. The recognizer trained with the alternatives is better at finding feminine titles and worse at finding masculine ones in the gender-specific evaluation. Its common-gender recall is similar across training conditions.

This result explains why the choice of test distribution affects the apparent benefit. The paper characterizes the swapped set as predominantly feminine for JOB, and the original set draws on the corpus with predominantly masculine titles. A gain on the former can coexist with a loss on the latter. Even within the same entity type, adding training examples for a previously scarce class of forms can change the allocation of correct detections. Reporting only aggregate JOB F1 would leave the source of those differing test outcomes much harder to identify.

The full entity results show further variation. For DATE, F1 on the swapped subset falls from 92.97 to 91.01, while on that same subset ORG F1 moves from 93.02 to 94.62. These labels are carried over in the augmented examples even though the rewrite chiefly targets occupations. The authors suggest that duplication of some labeled entities could contribute to changes in performance, including through overfitting to repeated examples. The comparisons establish that gains and declines occur beyond JOB. They do not independently test the duplication explanation or isolate which additions caused a given change.

Limitations

Limits the authors identify

The unit of rewriting is an individual sentence. The authors point out that this deprives the generator of broader context that could clarify a name, reveal who a description refers to, or help determine whether an edit makes sense. The initial gender classification has a related problem with morphologically ambiguous surnames. Context from the wider text might resolve some of those cases. The proposed next direction is to move toward document-level gender swapping, where a person’s name, descriptions, and referring expressions can be handled consistently across sentences. The paper evaluates only the sentence-level procedure.

The generator used for initial drafting is proprietary. The authors identify this dependence on GPT-4o-mini as a limit on reproducibility. Their release of reviewed data, instructions, and code makes it possible to inspect the material, use it in further work, and see how candidate sentences were requested. Repeating the initial generation stage still depends on the system to which those requests were sent. This distinction matters because the publicly released Aya-101 comes later in the pipeline and was trained using examples created through that initial generation and review.

Name generation remains a problem after fine-tuning. The authors report the preference for a particular feminine name and occasional invented names. They propose selecting from valid name variants and seeking a distribution that more closely reflects actual use. Plausibility and distribution are distinct aims. A generated name can be valid every time while the system repeatedly chooses the same valid name. Conversely, a more varied output can contain forms that reviewers would reject. An evaluation aimed at realistic replacements would need to address both aspects of the name choices.

The authors also limit the substantive scope of the experiments to Ukrainian occupational feminitives. The pipeline permits other gender-marked personal nouns in principle, but it was developed and tested around job titles and the contexts in which they occur. They identify nouns relating to ethnicity, religion, political views, and character as directions for possible validation. The existence of a workflow for identifying a counterpart and adjusting agreement leaves open whether suitable counterparts can be chosen consistently in those additional categories. An alternation can carry implications beyond the grammatical change that is central to the occupation experiment.

Their ethical discussion addresses the appropriateness of the entire operation. A well-formed counterfactual based on a public figure can state something factually wrong if read as an account of that person. A generator trained to transform gender-marked sentences can apply the instruction even when the source asserts a real event or identifies a specific individual for whom the substitution would be inappropriate. The authors propose work on identifying such cases. Human review supported the construction of the corpus, while the learned editing task itself provides no demonstrated safeguard for deciding whether a new sentence should be rewritten.

Limits of the experimental comparisons

The recognition experiment changes several properties of the training material together. Augmentation adds new occupational forms, raises the number of training spans, and repeats much of the context from the selected source sentences. It also adds examples of other labels that happen to co-occur with occupations. Following the baseline training configuration helps focus the comparison on the training data as a package. It leaves several explanations open for the direction and size of individual effects. In particular, a controlled comparison with a similar volume of added material and a different distribution of gendered forms would be needed to isolate the role of that distribution from the role of added examples.

Similarly, the trained swapper uses reviewed sentence pairs, dictionary word pairs, and examples ordered in both directions. Its improvement over original Aya-101 measures their combined effect in the authors’ setup. The result gives no separate estimate of how much sentence editing improves because the training includes isolated word pairs, or of how much reversing the order affects each direction. The candidate name list and the human review are also embedded in the procedure that constructs the training data. The paper documents what these components do and detects errors they are intended to address. It does not estimate each component’s marginal contribution through a separate training run.

The three recognition test settings also differ in more than grammatical gender. The original test split includes the original range of sentences. The swapped test subset includes only counterparts to selected occupational sentences that could be retained after review. Its sentences are human-reviewed transformations of existing examples. As a result, a difference between scores on the original and swapped sets is partly a difference in the collections being tested. The most direct comparisons are between the recognizers evaluated on the same set. The gender recall analysis helps clarify the occupational pattern within the evaluation, while the selected subset still leaves performance on a separately collected body of naturally occurring feminine titles unmeasured.

The split policy protects a practical boundary by keeping counterparts on the same side of the recognition partition as their source sentences. The augmented test score itself nevertheless comes from a union that includes both members of retained pairs. A shared sentence frame can therefore influence the experience summarized by that score more than an unpaired frame. This is appropriate for measuring performance over the paper’s constructed augmented test set. The score alone leaves open how the observed tradeoff would look in an independent collection with different topics, genres, or frequencies of feminine job titles.

The name results have an additional measurement limit. Corpus-wide PERS F1 reports entity recognition across names as a class. It does not expose detection rates for all gender categories of names, and many names in the data have unknown gender under the classification procedure. The near stability of aggregate name F1 therefore says little about whether recognition disparities among kinds of names improved. Likewise, the gender-specific JOB calculation measures recall among annotated titles. It gives no category-specific precision estimate for cases where the system predicts a feminine, masculine, or common-gender title incorrectly.

Finally, the reference metrics for rewriting have a bounded interpretation. Exact Match measures recovery of a particular reviewed string. Alternate grammatical rewrites can differ from that string, while high BLEU or BERTScore can coexist with crucial mistakes in an occupational form. The name-insensitive and job-specific measures make the reference comparison more informative, and the human review shows concrete error types. Taken together, they support claims about performance on the paper’s editing and recognition tasks. The measured gain for feminine job-title recall describes one aspect of representation in recognition, alongside the measured loss for masculine titles. Broader changes in fairness, factual reliability, or behavior on documents remain unmeasured.

What came after

There are no documented follow-up papers to describe. Open directions include testing the approach across whole documents, improving the selection of replacement names, and extending evaluation beyond occupational terms. In the paper, these are proposed extensions whose effects have yet to be established.

Cite

Cite as Olha Nahurna and Mariana Romanyshyn. 2025. Gender Swapping as a Data Augmentation Technique: Developing Gender-Balanced Datasets for Ukrainian Language Processing. Proceedings of the Fourth Ukrainian Natural Language Processing Workshop (UNLP 2025).

The paper itself, not this page. BibTeX from the library's record of the work. DOI 10.18653/v1/2025.unlp-1.16

@inproceedings{nahurna2025gender,
  title = {{Gender Swapping as a Data Augmentation Technique: Developing Gender-Balanced Datasets for Ukrainian Language Processing}},
  author = {Olha Nahurna and Mariana Romanyshyn},
  booktitle = {Proceedings of the Fourth Ukrainian Natural Language Processing Workshop (UNLP 2025)},
  year = {2025},
  doi = {10.18653/v1/2025.unlp-1.16},
  url = {https://doi.org/10.18653/v1/2025.unlp-1.16}
}

↑ back to top

This page in Markdown https://md.research.elamur.ai/free/en/papers/nahurna-2025-gender-swapping-as-data-augmentation/