---
title: "Caption Enriched Samples for Improving Hateful Memes Detection"
description: "Caption Enriched Samples adds automatic image descriptions to hateful meme detection and tests when they help classifiers read words and…"
canonical: "https://research.elamur.ai/free/en/papers/blaier-2021-caption-enriched-samples-improving-hateful/"
---
Elamur: [Mova](https://md.mova.elamur.ai/free/en/) · [Parse](https://mova.elamur.ai/free/en/parse/) · [Dictionary](https://md.dictionary.elamur.ai/free/en/) · [Translate](https://md.translate.elamur.ai/free/en/) · **Research** · [Gali](https://md.gali.elamur.ai/free/en/) · [MCP](https://mcp.elamur.ai/) · [Locations](https://md.locations.elamur.ai/free/en/) · [Weather](https://md.weather.elamur.ai/free/en/) · [Constitution](https://md.constitution.elamur.ai/)

[Elamur Research](https://md.research.elamur.ai/free/en/) · [this page in HTML](https://research.elamur.ai/free/en/papers/blaier-2021-caption-enriched-samples-improving-hateful/)

[Elamur Research](https://md.research.elamur.ai/free/en/) / [papers](https://md.research.elamur.ai/free/en/papers/) / [2021](https://md.research.elamur.ai/free/en/papers/2021/) / Caption Enriched Samples for Improving Hateful Memes Detection

# Caption Enriched Samples for Improving Hateful Memes Detection

Paper · 2021 · Efrat Blaier, Itzik Malkiel and Lior Wolf

**Authors:** Efrat Blaier, Itzik Malkiel and [Lior Wolf](https://md.research.elamur.ai/free/en/authors/lior-wolf/) · **Year:** 2021 · **Venue:** Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing · **Licence:** [CC BY 4.0 (ACL Anthology)](https://creativecommons.org/licenses/by/4.0/)

Cited by **7** papers in our library of more than 163,000 papers whose bibliographies we read · Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing · [licence](https://creativecommons.org/licenses/by/4.0/)

- [Publisher's page](https://aclanthology.org/2021.emnlp-main.738/)
- [PDF](https://aclanthology.org/2021.emnlp-main.738.pdf)
- [DOI 10.18653/v1/2021.emnlp-main.738](https://doi.org/10.18653/v1/2021.emnlp-main.738)

## Summary

The same words can make one meme hateful and leave another benign. A picture can change whom the words refer to, what they imply, or how a reader understands their tone. That makes hateful meme detection a problem in [vision and language](https://md.research.elamur.ai/free/en/topics/multimodal/), even when the words printed on the image are already available as text. The Hateful Memes challenge tests this dependence directly. It includes examples that share their wording but have different images and labels, as well as examples that share an image but differ in wording and label. A classifier that relies on either input alone can miss the change that matters.

Caption Enriched Samples, or CES, gives the classifier an additional way to read the picture. An existing image caption generator produces a short description, which the authors pair with the original meme text. A text-only classifier reads both pieces of writing. A classifier that already processes images receives the description alongside the image and its original text. The authors also test when to introduce the description. For the text-only systems, they compare adding captions during supervised training with using them earlier as well, when the system practices reconstructing masked words from the paired texts.

The paper reports gains for BERT, RoBERTa, VisualBERT, and ViLBERT on the Hateful Memes test split. On AUROC, a measure of how well a classifier ranks hateful examples above benign ones, RoBERTa goes from 65.77 to 72.37, while VisualBERT goes from 71.41 to 72.93. The appendix shows higher test accuracy for all four main systems when they use captions. The controlled comparisons clarify what drives the gains. Giving the classifier the description during supervised training improves validation AUROC even without an extra round of language practice. RoBERTa achieves its strongest standalone scores when it also sees the paired texts in that earlier phase. For an ensemble involving UNITER, several kinds of continued training help, and the validation results establish no clear winner among them.

An automatically generated description can be useful even when it gets a detail wrong, but it can also introduce a misleading account of the scene. The authors show a case where the caption identifies a pig as a cow and the enriched system still makes the correct decision. In another example, a description of a dog with a frisbee replaces the relevant sight of a shoe emerging from the ocean, and the enriched system misses the hateful label. CES improves the benchmark results by making visual information available in words. How much those words help depends on what the captioner notices and how the classifier uses its description.

## Deep dive: Caption Enriched Samples for Improving Hateful Memes Detection

Caption Enriched Samples adds automatic image descriptions to hateful meme detection and tests when they help classifiers read words and pictures together. · about 32 minutes to read

**In this deep dive**

1. [The problem and its context](#dd-the-problem-and-its-context)
2. [The method, step by step](#dd-the-method-step-by-step)
3. [Experiments and results](#dd-experiments-and-results)
4. [What the ablations show](#dd-what-the-ablations-show)
5. [Limitations](#dd-limitations)
6. [What came after](#dd-what-came-after)

### The problem and its context

#### Why a meme can be hard to classify

A meme has at least two sources of meaning that a reader can consult directly. There is what the words say, and there is what the image depicts. The difficulty in the Hateful Memes task lies in working out what they say together. Words that seem innocuous on their own may take on a different implication when the picture supplies a target. An image that supports a hateful reading with one line of text may support a benign reading with another. A system can make sense of the words in isolation and still miss the relationship that determines the label.

The paper describes sarcasm as an additional difficulty. The force of a sarcastic remark depends on how its apparent meaning relates to its context. In a meme, the picture can supply some of that context. It can also matter which feature of the picture the reader attends to. Recognizing what is depicted and understanding why it changes the reading are distinct parts of the problem. The paper intervenes at the first part by making a description available to the classifier, then evaluates the effect on the final label.

The prediction itself is a binary decision. Each image and text pair has a hateful or a non-hateful label, and the classifier learns to assign a score to a new pair. That is a supervised problem in which examples come with the answer the system is meant to learn. The annotation concerns the combined meme, so a correct account of the scene can still leave the label unresolved. The classifier has to learn which relationships between the scene and the words matter for this particular task.

#### How the benchmark makes context matter

The authors take up the Hateful Memes challenge introduced by Kiela and colleagues. As the paper describes it, the benchmark was constructed from material based on real-world memes. The challenge creators deliberately built variations that make a decision based on a single source of evidence unreliable. These are called confounders. A confounder preserves the image or the text from another example while changing the other component so that the annotation changes.

The paper opens with an example of a benign confounder that keeps the original text and changes the image. Both versions present the same words to a system that reads only the original meme text. That system has no input on which to base a different decision for the two items. A system given only pictures faces the corresponding problem when a benchmark pair keeps the picture and replaces the text. Constructing examples in both directions makes the pairing itself consequential.

An image description changes what a text-only system receives in the first of those cases. The original words remain the same across the two memes, but the generated description can change with the picture. Whether that variation is useful depends on the generator. If it describes the visual difference that changes the meaning of the words, it gives the classifier evidence it otherwise lacks. If the descriptions omit that difference, the classifier may still see effectively the same information in both cases. This connection between what the benchmark varies and what the description captures motivates the experiment.

The benchmark also gives a common setting in which to compare systems with different inputs. A text-only baseline receives the meme wording, while a vision-and-language system also receives a representation of the picture. The paper describes earlier scores for both kinds of system as falling substantially below the human reference. That gap motivates a closer look at how the picture is represented. Access to the visual input makes a different prediction possible when the image changes. The remaining question is whether the system can identify the contents that make a difference and connect them to the words.

#### The approaches that preceded CES

On the language side, the authors describe the established practice of starting with a general-purpose text encoder and adapting it to a particular task. BERT and RoBERTa supply the starting points for their text-only experiments. During masked-language pretraining, the system encounters text with some tokens obscured and learns to predict the missing items from context. Supervised training subsequently uses examples with task labels to adapt the system’s predictions. The related-work discussion uses GLUE to situate this practice in language tasks such as judging textual similarity and drawing inferences from sentences. [GLUE](https://md.research.elamur.ai/free/en/papers/wang-2018-glue-multi-task-benchmark-analysis/)

The paper also draws on prior work that continued this general training on material closer to the task. Gururangan and colleagues had shown that additional pretraining on a target dataset could help the subsequent supervised stage. CES applies that approach to material created in part by the augmentation itself. A continuation stage can expose the system to the wording found in memes, and pairing that wording with a generated description gives it a different kind of context to learn from. The experiments distinguish these two possibilities by varying which text enters each stage.

On the vision-and-language side, the authors describe systems that process text in conjunction with image regions. Earlier work applied such methods to tasks including [visual question answering](https://md.research.elamur.ai/free/en/topics/question-answering/), where the input question must be interpreted with reference to an image. The paper also identifies reasoning from natural language grounded in photographs as a related line of work. In both settings, the connection between a sentence and the scene provides evidence for the output. Hateful meme detection requires a related integration of inputs, with the label attached to the meaning of the meme as a whole. [VQA](https://md.research.elamur.ai/free/en/papers/agrawal-2015-vqa-visual-question-answering/) · [A Corpus for Reasoning About Natural Language Grounded in Photographs](https://md.research.elamur.ai/free/en/papers/suhr-2019-corpus-reasoning-natural-language-grounded/)

The vision-and-language systems considered in the paper illustrate different ways to connect the inputs. VisualBERT places visual regions and language tokens in a shared processing stream. ViLBERT keeps separate visual and textual streams and lets them exchange information. Both use the [Transformer and attention](https://md.research.elamur.ai/free/en/concepts/transformer/) to build representations in which the available context can influence how an input is encoded. Attention is the mechanism that lets a representation draw on different parts of its input. Adding a caption makes descriptive words part of the context these systems can use, while leaving each system’s arrangement of visual and textual processing in place. [ViLBERT](https://md.research.elamur.ai/free/en/papers/lu-2019-vilbert-pretraining-task-agnostic-visiolinguistic/)

A separate body of work addressed how to produce those descriptive words. Image captioning takes a picture as its input and generates a sentence intended to describe the scene. The authors point to earlier encoder–decoder approaches and to work on visual attention for caption generation. An encoder represents the picture in a form the decoder can use, and the decoder produces the description. The paper also cites Microsoft COCO Captions in its discussion of visual and language tasks. For CES, this earlier work supplies a practical starting point because the authors can apply an existing caption generator to the benchmark images. [Show and Tell](https://md.research.elamur.ai/free/en/papers/vinyals-2014-show-tell-neural-image-caption/) · [Show, Attend and Tell](https://md.research.elamur.ai/free/en/papers/xu-2015-show-attend-tell-neural-image/) · [Microsoft COCO Captions](https://md.research.elamur.ai/free/en/papers/chen-2015-microsoft-coco-captions-data-collection/)

The two uses of language in CES follow from this background. A classifier built for text can gain access to selected picture contents through a sentence. A classifier built for both inputs can receive a version of those contents in the same form as the meme wording it must interpret. Since the caption is generated from the image, it offers a change in representation. In the text-only case it also expands the evidence available to the classifier. The paper evaluates both possibilities using the same basic enrichment procedure.

### The method, step by step

#### Turning the image into an extra field

The procedure starts with the image and the text already associated with it in the dataset. The authors run the image through IBM’s MAX Image Caption Generator, an implementation of a Neural Image Caption encoder–decoder system. It produces a short sentence about the image. The caption is generated without using the meme’s hateful or non-hateful label. The paper reports that the descriptions used in the experiments are at most 15 words long.

The original words and the generated description play different roles. The former are part of the message to be classified, while the latter are a description of its visual context. To keep those roles clear, the paper uses separate symbols for the two texts. It writes the starting example as follows.

```
x = (m, c)
```

Here `x` denotes the original meme example, `m` is its image, and `c` is its original text. The parentheses and comma denote an ordered pair. The label is associated with the example and used in supervised training. The pair in the expression describes the classifier’s available input before enrichment.

```
G : M → C
```

`G` denotes the caption generator. `M` is the domain of images, and `C` is the language domain containing the text descriptions. The colon introduces the specification of `G`, and the arrow gives the direction of the mapping. An image goes in and a piece of text comes out.

```
c* = G(m)
```

`c*` is the newly generated caption, with the star distinguishing it from `c`, the meme’s original text. `G(m)` means applying the generator `G` to the image `m`. The equality defines the caption used for this particular example.

```
x* = (m, c, c*)
```

`x*` denotes the enriched version of `x`. The ordered entries are the original image `m`, the original words `c`, and the generated description `c*`. The enrichment adds an input field and preserves the meme’s existing label. Systems that accept images can use the whole triplet. For the text-only systems, the authors use its textual part.

```
(c, c*)
```

In this pair, `c` is the original meme wording and `c*` is the image description. The parentheses and comma indicate that the two strings belong to the same example. This is the unit of input used for caption-based continued training and supervised training in the complete text-only procedure.

From the original meme to a CES prediction The steps in order.

The figure includes the steps specific to each branch. In text-only CES, the generated description supplies the picture information in words. In vision-and-language CES, the visual representation accompanies the paired texts. The authors generate captions for the dataset before supplying the enriched inputs to the classifiers. The generator thus serves as a separate component, and the label-based training described in the paper operates on the classifiers. The released code includes the caption generator and software for preparing the enriched data for the different training setups.

#### How the text-only procedure uses the caption twice

The complete text-only version starts from a pretrained BERT BASE or RoBERTa BASE encoder. Its first phase continues training that encoder with a masked-language objective. The authors apply [tokenization](https://md.research.elamur.ai/free/en/concepts/tokenization/) to each of the two strings, breaking them into the input units the encoder can process. They then concatenate the two token sequences with a special separator token, `[SEP]`, between them. This gives the encoder one input sequence with a recognizable boundary between the original words and the description.

Some input tokens are masked for this phase, and the encoder learns to recover them from the surrounding text. The objective is the ordinary masked-language objective already associated with BERT-style pretraining. The distinguishing choice is the content of the sequence on which it operates. A meme’s text and a description of its image now occur together. Information from each segment is available as context for predicting masked tokens. This allows the encoder to adapt to the paired input before it sees the supervised classification objective.

The paired text can contain useful correspondences, but the masked-language objective leaves the task of finding them to the encoder. The generator may mention an object that helps make sense of a reference in the original text. A description may also be unrelated to the part of the wording that matters for the label. In either event, the training target in this phase is the identity of the masked text, instead of the label of the meme. Calling this continued pretraining means the encoder starts from its existing parameters and takes further training steps before beginning the classification phase.

In the second phase, the authors attach a classification head to that encoder. This is the part of the system that takes the encoded input and produces a prediction for the task. During supervised [fine-tuning](https://md.research.elamur.ai/free/en/concepts/fine-tuning/), the system again receives the meme text and the generated description as a pair. It now uses the known labels to learn the distinction between hateful and non-hateful examples. The earlier phase changes the starting representation for this training. The caption’s presence in the second phase gives the classifier access to the visual description when it learns and makes the decision.

The loss for the supervised phase is binary cross-entropy. It penalizes a prediction more heavily when the system assigns little probability to the annotated outcome. Training on that loss adjusts the classification system toward assigning higher scores to hateful examples and lower scores to benign ones. The objective applies to the whole input pair. The training procedure does not assign individual words in the caption credit for a correct prediction.

This design gives the authors experimental control over where the caption enters the procedure. The text-only baseline is fine-tuned on meme text. A caption can be added at that stage without doing any additional masked-language training. Continued training can also use just the original words, followed by supervised training that either retains that input or adds the description. In complete CES, both stages use the paired input. The distinctions matter because a system that improves after receiving a caption at decision time has changed in a different way from one that improves after additional exposure to captions during pretraining.

#### How the vision-and-language procedure uses the caption

The vision-and-language branch begins with a system already pretrained for general visual and textual inputs. It already accepts information derived from the image, so the generated caption supplements its visual representation. The authors initialize a classification head with two fully connected layers over the pretrained system. A fully connected layer combines the components of its input representation to produce a new representation. The added head turns the combined input into a score for the meme’s label.

Each system builds the input to its classification head from pooled embeddings. An embedding is a vector representing a unit of input in a form the system can compute with. Pooling provides a summary representation for the head to use after the system has processed the input sequence or sequences. CES uses the pooling arrangement that belongs to each underlying system. It changes the text supplied to that system by adding the image description.

ViLBERT illustrates the arrangement more concretely. It encodes the visual and textual streams separately, allowing them to interact through co-attention. Its text stream contains both the original wording and the generated caption, separated by `[SEP]`. To construct the input to the classification head, the system uses the embeddings at the first positions of the image and text sequences. It multiplies the corresponding components of those two vectors. The result is a single combined representation for the head, even though the system processes the visual and textual sequences in separate streams.

VisualBERT uses a shared stream for image regions and text tokens. In that architecture, processing both kinds of input together gives the network a way to connect words in the combined text sequence with regional visual representations. The two systems therefore receive the same kind of caption augmentation while combining the underlying evidence differently. Improvement in both settings would support the usefulness of the additional text across these arrangements.

The paper uses a single supervised training stage for the vision-and-language branch. The authors cite training cost as the reason for omitting continued pretraining on the enriched triplets. They feed the triplets into the pretrained classifiers, add the new heads, and optimize the same type of binary classification loss used for the text-only branch. In this setting, the comparison tests caption enrichment during fine-tuning. The text-only experiments address the separate question of changing the continued pretraining input.

#### Combining the caption system with UNITER

A further experiment combines the RoBERTa text branch with UNITER, another vision-and-language system. The paper describes UNITER as using a single stream to process visual and textual input. Its earlier training mixed masked-language prediction, masked region training, image–text matching, and word–region alignment. These objectives give the UNITER branch ways to represent both the contents of each input and relationships between the image and the text.

The authors use the Vilio implementation of UNITER and combine it with each RoBERTa variant by late fusion. Each branch processes the example and produces its own classification representation. The system takes the embeddings at the classification-token position, called CLS embeddings, from UNITER and RoBERTa. It concatenates those vectors and trains a two-layer network on the resulting representation. The combination therefore occurs after the branches have processed their respective inputs. A comparison against fusion with ordinary RoBERTa helps put the gains from caption enrichment and continued training in context.

This experiment differs from the VisualBERT and ViLBERT runs. There, the classifier reads the caption as an additional part of its text input and has the image representation in the same architecture. In the UNITER experiment, a RoBERTa branch provides the additional representation, and its training history can be varied independently. An ordinary RoBERTa branch establishes what happens when that text representation is added without CES. Each adapted branch then supplies a different comparison for judging the roles of the caption and continued training.

#### Training settings and data preparation

The data augmentation code produced files for the enriched classification dataset and prepared paired text for BERT and RoBERTa pretraining. The main classifier experiments used the MMF codebase with changes to incorporate the captions. The authors used the Transformers library for continued text pretraining and Vilio’s feature data for UNITER. These components serve different stages of the procedure. IBM’s generator prepares the additional text, the text encoders can practice on the resulting sequences, and the classification systems learn from the meme labels.

For the MMF fine-tuning runs, the paper reports reusing the challenge settings of 22,000 updates and a batch size of 32. The optimizer was weighted Adam, with a cosine learning-rate schedule, 2000 warmup steps, and no gradient clipping. Warmup governs the opening part of the learning-rate schedule. The reported learning rate is 5e-5, with 5e-6 used for BERT and RoBERTa fine-tuning after continued pretraining. That distinction is relevant to the ablations because the paper’s implementation treats fine-tuning after continued training as a distinct setting.

For continued text pretraining, the reported batch size is 32 across 4 GPUs, for an effective batch size of 128. The paper reports 100 epochs and a runtime of about 2-3 hours for pretraining. An epoch is a pass through the training material. According to a separate note in the appendix, fine-tuning typically took 10 to 13 hours for each system using a GeForce GTX TITAN X equipped with 12 GB of RAM. These runtime figures describe the authors’ implementation and hardware.

For the standalone baseline, UNITER ran with a learning rate of 1e-5 and a batch size of 8. The ensemble runs used a batch size of 6 with gradient accumulation of 2, at the same learning rate. Gradient accumulation combines the training signal from batches before an update. The appendix reports roughly 1 hour per run and says the images were represented using 36 features. The UNITER implementation thus uses its own visual data and training configuration within the larger comparison.

### Experiments and results

#### What was evaluated

The experiments use Phase 1 of the Hateful Memes challenge. The dataset contains 10,000 examples, with 8,500 memes for training, 500 for validation, and 1,000 for testing. Each example associates an image with its original text and a binary label. The test labels were withheld from participants and used to score submissions through the challenge leaderboard. Validation provided a separate split on which the authors could compare variants independently of the availability of that service.

The primary experiment pairs systems with their own baselines. For BERT and RoBERTa, the baseline reads the original meme text. CES gives the text-only system another input that describes the picture. For VisualBERT and ViLBERT, the baseline already has the image and the original text. In those comparisons, CES changes how some visual information can be accessed while retaining the original visual input. This difference in baseline inputs is important when interpreting the stronger gains for the text-only systems.

The paper reports AUROC in its main results and accuracy in the appendix. AUROC is the area under the receiver operating characteristic curve. The curve tracks how the rate of correctly flagged hateful cases and the rate of incorrectly flagged benign cases change as the threshold on the score is varied. Area under that curve summarizes ranking quality across thresholds. Accuracy is the proportion of examples that receive their correct class at a chosen decision rule. A system can improve its ordering of examples and still see a different pattern in accuracy, depending on which predictions move across the decision threshold.

The human reference is drawn from the challenge results. The main results give a human test AUROC of 82.65, and the appendix gives a human test accuracy of 84.7. They are separate quantities. The human accuracy describes correct labels, and the AUROC belongs to the same metric as the paper’s main classifier comparison. The reported human figures provide context for the difficulty of the benchmark and for the performance gap that remained after enrichment.

#### Test performance with and without captions

Baselines and caption-enriched classifiers on Hateful Memes test AUROC Each classifier gains with CES, with larger gains for the text-only systems.

**The numbers**

| System or setting | AUROC |
| --- | --- |
| BERT baseline | 65.08 |
| BERT with CES | 70.70 |
| RoBERTa baseline | 65.77 |
| RoBERTa with CES | 72.37 |
| VisualBERT baseline | 71.41 |
| VisualBERT with CES (this paper) | 72.93 |
| ViLBERT baseline | 70.03 |
| ViLBERT with CES | 72.59 |

Both text-only classifiers rise from the mid-sixties on test AUROC to scores above 70.70 or at that value, with RoBERTa reaching 72.37. Their starting point matters. A text-only baseline receives the same input for any confounder that preserves the original words. With captions, it can receive different words to describe the different pictures. This additional evidence is consistent with the larger improvements in that branch of the experiment. It also helps explain why an automatic description can be useful even though it conveys only part of what is visible.

The enriched vision-and-language classifiers also exceed their own test baselines. VisualBERT has the highest test AUROC in the main comparison, at 72.93, while enriched ViLBERT reaches 72.59. Both begin from a higher AUROC than the text-only baselines. Their gains show that, in these tests, converting some image content into text helps even when the system already receives a visual representation. The comparison measures the effect of adding that input and fine-tuning the system with it. The scores themselves leave open how often predictions come from relating the caption to the meme text, checking it against the image, or using it as a direct cue.

The results discussion gives relative improvement figures for the visual systems in an order that does not match their rows in the main AUROC table. The absolute scores in the chart follow the table’s assignments to VisualBERT and ViLBERT. Both presentations support a gain for each system, while the table provides the baseline and enriched values for identifying the size of each gain. The best value in this chart is for the main comparison. The separate UNITER experiment starts from a different system and uses late fusion.

#### Validation performance and the change in ordering

Baselines and caption-enriched classifiers on Hateful Memes validation AUROC All four systems improve with captions, and enriched ViLBERT leads this comparison on validation.

**The numbers**

| System or setting | AUROC |
| --- | --- |
| BERT baseline | 64.65 |
| BERT with CES | 69.32 |
| RoBERTa baseline | 65.77 |
| RoBERTa with CES | 72.95 |
| VisualBERT baseline | 73.97 |
| VisualBERT with CES | 75.55 |
| ViLBERT baseline | 70.07 |
| ViLBERT with CES (this paper) | 75.98 |

The main validation comparison shows gains in the same direction for all the systems. ViLBERT leads the enriched classifiers on this split, with 75.98, and VisualBERT follows at 75.55. VisualBERT leads on test AUROC. The relative position of the visual systems therefore changes across the splits even though each system benefits from captions on both. The comparison within each architecture is more stable than the ordering across architectures.

Validation also makes the longer ablation series possible. The main comparison provides a broad overview of the input change, and the controlled comparisons ask what happens under particular training histories. Some entries in the ablation table have no test score because the challenge server stopped operating. Those settings can be compared on validation, while a comparison on the held-out test split is available only where the paper reports it.

There is also a reporting detail that affects how the main table should be read. Its BERT CES entry gives validation AUROC of 69.32. The ablation table gives that value to the BERT variant that skips continued pretraining, and gives the complete paired-pretraining variant a separate validation score. The BERT test scores in the two tables correspond under their separate decimal formats as well. Reading the ablations alongside the main table keeps the presence of a generated caption distinct from the use of that caption in both training phases.

#### Accuracy and individual predictions

The appendix gives test accuracy for BERT of 59.2 with the baseline and 63.2 with captions. RoBERTa goes from 60.8 to 62.7. VisualBERT goes from 61.7 to 64.44, and ViLBERT goes from 61.1 to 64.4. These results agree in direction with the main test AUROC comparisons. The higher accuracy indicates that the improvement extends to fixed class decisions in the reported experiments, in addition to ranking across possible thresholds.

Validation accuracy also improves for each system in the appendix. BERT goes from 58.8 to 63.4, and RoBERTa goes from 59.8 to 62.2. VisualBERT goes from 65.06 to 67.8, and ViLBERT goes from 61.4 to 65.6. On validation AUROC, enriched ViLBERT has the higher score of the visual systems in the main comparison. On validation accuracy, enriched VisualBERT has the higher score. The difference illustrates how the metric affects the interpretation of a lead between systems. For the main claim about captions, the direction of the within-system comparison agrees across both metrics.

The paper also illustrates correct decisions on individual memes. In the examples featuring VisualBERT, the baseline gives the wrong label for both, and the caption-enriched classifier gives the correct label for both. The authors use the cases to show what a change in the input can look like at the level of a prediction. The appendix presents further qualitative comparisons for RoBERTa, BERT, ViLBERT, and VisualBERT, including a case in which an inaccurate description accompanies improved decisions in several systems. These examples complement the split-level scores by showing that a caption’s usefulness and its literal accuracy can come apart.

The experiments establish a consistent direction of change across the main comparisons. That consistency concerns the Phase 1 benchmark, the particular generated captions, and the systems tested. It is especially informative that the text-only and vision-and-language branches each improve, since the intervention gives them different kinds of access to the image. The controlled comparisons examine the additional question of how much of the change comes from access to the caption at supervised training and prediction time, and how much depends on the training that precedes it.

### What the ablations show

#### What changes when the caption enters at different stages

The text-only ablations vary two choices. The first is whether to continue masked-language training and, if so, which text to use. The second is which text to make available during supervised fine-tuning. The baseline uses the original meme text for the supervised task. One variant skips the additional pretraining stage and gives the classifier both texts during fine-tuning. Another continues pretraining and fine-tunes on meme wording alone. A third continues pretraining on meme wording and adds the description during fine-tuning. Complete CES uses both texts during both phases.

This design compares more than one way of spending additional training effort. The variant that adds the caption only at fine-tuning asks whether paired input helps without extra masked-language training. The meme-text-only continued training variant asks whether additional exposure to the task’s original text helps on its own. Comparing the variants that share continued pretraining on original text lets the reader examine the effect of adding captions for fine-tuning. Comparing that caption-enriched setup with complete CES then asks whether captions also add value during continued training, once the final classifier has access to them either way.

RoBERTa training variants on Hateful Memes validation AUROC Captions help at fine-tuning, and using paired text in both stages gives the strongest standalone RoBERTa result.

**The numbers**

| System or setting | AUROC |
| --- | --- |
| RoBERTa baseline | 65.44 |
| Captions at fine-tuning without continued pretraining | 70.47 |
| Meme text only in both stages | 64.8 |
| Meme text pretraining with captions at fine-tuning | 71.11 |
| Paired text in both stages (this paper) | 72.95 |

The RoBERTa ablation uses a validation baseline of 65.44, while the paper’s main results give 65.77 for RoBERTa on validation. The controlled comparisons here use the ablation table’s own baseline. Its caption-at-fine-tuning variant reaches 70.47, establishing a gain from supplying the description in the supervised stage without additional masked-language training. Continuing on original meme text and keeping the same original text as the only supervised input gives 64.8. The added training pass on its own therefore fails to explain the gain in the caption-enriched condition.

The comparison between 64.8 and 71.11 sharpens this point. Both variants continue pretraining on the original wording. During fine-tuning, the first continues with original wording alone and the second adds the generated description. Their validation scores differ in the direction expected if visual context in words helps the classifier. Complete CES then reaches 72.95 by making the paired texts available in the continued pretraining stage as well. This is the best standalone RoBERTa validation AUROC reported in the ablation, and the ordering gives evidence for adding captions at each stage.

On the test split, the ablation table reports RoBERTa baseline AUROC of 65.77. The variant with captions at fine-tuning and no continued pretraining reaches 70.91. Continuing pretraining on original meme text before adding captions at fine-tuning reaches 71.08. Complete CES reaches 72.37. The variant that keeps the original text as the sole input at both stages lacks a reported test score. Among the variants with test results, the ordering agrees with the validation evidence that supervision benefits from the description and that using the paired texts earlier as well can help further.

#### What the BERT comparison can establish

In the BERT ablation, the baseline validation AUROC is 64.65. Adding captions at fine-tuning with no continued pretraining gives 69.32. Using only the original wording during continued pretraining and fine-tuning gives 65.19. Continuing pretraining on original text before adding captions during fine-tuning gives 69.25. Complete CES gives 69.76. As with RoBERTa, the main improvement appears when the classifier has access to the description in the supervised stage.

The placement of the middle variants differs from RoBERTa. BERT’s caption-at-fine-tuning variant with no extra pretraining scores slightly above the variant that first continues pretraining on original meme text. Both are below the complete paired-text version. The BERT comparison supports providing the image description to the classifier and gives some validation evidence for using that description earlier. Its validation figures offer less separation among the caption-enriched variants than the RoBERTa figures do.

The paper gives BERT test AUROC of 65.08 for the baseline and 70.7 for caption enrichment at fine-tuning without continued pretraining. It gives no BERT test score for the other ablation settings. The best BERT validation setting can therefore be identified, while its relative standing on test remains unmeasured in the reported results. This distinction matters when describing the paper’s broad claim about continued training. RoBERTa has test evidence for the complete procedure, and BERT has a validation comparison that favors it.

Taken together, the standalone ablations support two claims of different strength. Access to the caption during supervised training is the consistently supported change. Continued training on paired text gives the best validation setting for both classifiers and the best reported test result among the RoBERTa variants. The authors’ inference that using the paired text in continued pretraining is beneficial draws on those comparisons. The score patterns also show why continued training on just the original wording cannot be treated as an equivalent intervention.

#### What changes when RoBERTa is paired with UNITER

The ensemble experiment starts from a stronger standalone baseline. UNITER records validation AUROC of 77.01 and test AUROC of 78.68. On validation, adding ordinary RoBERTa by late fusion gives 78.04. That comparison shows the value of the additional text branch before caption enrichment or continued pretraining enters the analysis. It provides a second reference in addition to plain UNITER.

Fusing UNITER with the RoBERTa variant that adds captions only at fine-tuning gives validation AUROC of 77.53. That is above standalone UNITER and below fusion with ordinary RoBERTa. The caption-at-fine-tuning variant was a strong improvement over standalone RoBERTa. In the ensemble, its relative standing changes. Since late fusion already combines the outputs of branches with access to different inputs, the usefulness of changing one branch depends on the representation it supplies to the combination.

The three variants with continued pretraining have the strongest validation results in the ensemble comparison. Continued training and fine-tuning on original text gives 78.31 when that branch is fused with UNITER. Continued training on original text followed by caption-enriched fine-tuning gives 78.57. Pairing the texts during both stages gives 78.29. The numerical leader uses original text alone during continued pretraining and adds the caption during the supervised stage. That ordering differs from the ordering of the standalone RoBERTa systems, where complete CES leads.

The authors report a validation-set t-test with a threshold recorded as `p-value<0.02` for the improvements of these continued-pretraining ensembles over the UNITER and ordinary UNITER-plus-RoBERTa baselines. They report that the differences among the three continued-pretraining ensembles were statistically indistinguishable. The highest validation entry accordingly identifies the largest reported score for the split, while the statistical comparison supports the continued-training group more broadly. The variant that uses only original text can contribute to a stronger ensemble even though continued training on that text alone failed to lift standalone RoBERTa’s validation score. The two experiments measure the branch’s value in different settings.

On test, the paper reports 78.90 for the ensemble with complete CES RoBERTa, compared with 78.68 for UNITER. The other ensemble entries lack test scores. The available comparison shows a test advantage over standalone UNITER for that submitted configuration. The relative test performance of the continued-training variants and the gain over ordinary RoBERTa fusion can be assessed only on validation in the paper.

#### What the examples add to the score comparisons

The qualitative cases probe a different part of the explanation. In one failure of the caption generator, it calls a pig a cow. The enriched classifier still improves on the baseline decision. The authors suggest that the substituted animal might still carry a negative interpretation in the context of the meme. That explanation remains a possibility because the observable evidence is a change in the output label, accompanied by the inaccurate caption.

The paper shows another case where the caption generator describes a dog with a frisbee when the image actually shows a shoe coming out of the ocean. The classifier labels that meme non-hateful and misses the hateful annotation. The discrepancy is broad enough to change the scene presented in the additional text. For a text-only classifier, the erroneous sentence supplies the visual description available to it. A system with access to the image can in principle draw on its visual representation as well, but the reported failure shows that receiving additional text can still coincide with an incorrect decision.

In an appendix example, the generator confuses a microphone with a cellphone, and caption enrichment improves predictions in three out of four systems. Like the pig example, this shows that an incorrect object name can coexist with a useful change at the classification stage. The caption may preserve other helpful context, or the classifier may give the mistaken part of the description little weight. The example contains no measurement that distinguishes those explanations. Together, the successes and failures show why the average effect of supplying a caption and the accuracy of any individual caption are different questions.

### Limitations

#### What the authors identify

The limitation discussed most directly is dependence on the image caption generator. CES supplies a sentence produced by a system trained to describe pictures. The classifier receives whatever that system generates, including omissions and errors. The paper’s examples show both recovery from a mistaken description and a missed hateful label in the presence of a substantially wrong description. The average gains establish the usefulness of the tested generator on the benchmark, while those examples show why its caption cannot be assumed reliable for an individual meme.

The authors also identify a practical limit to the test comparisons. The May 1, 2021 shutdown of the Hateful Memes challenge server left some ablation scores unavailable. The missing entries leave specific questions open. BERT’s complete paired-pretraining setting can be compared with its alternatives on validation only. In the UNITER experiment, the full caption-enriched ensemble has a test result, but the other fusions lack a test comparison. The validation results still support the reported comparisons on that split, and the test results support the narrower set of configurations actually scored.

Training cost determines another boundary of the experiment. The authors continued pretraining for text-only systems and chose supervised fine-tuning alone for the systems that take both visual and textual inputs. The resulting vision-and-language comparisons show the effect of caption input during supervised training. They leave the effects of continued pretraining on image, original text, and description triplets unmeasured. The gains in the text-only experiments motivate the question, but those experiments use a different form of input and cannot answer it for the vision-and-language architecture.

#### What follows from the evaluation setup

The evaluation covers the Phase 1 benchmark and its way of constructing memes. The confounders make it possible to study whether a system benefits from receiving both sources of information. They also shape the distribution of cases on which the paper observes the gains. The experiment establishes performance on the challenge’s examples. It does not measure how well the classifiers would handle memes drawn from a different source or how often a generated caption would capture the relevant cue under another dataset’s construction and labeling practices.

The main scores combine different kinds of examples. An aggregate rise in AUROC or accuracy can result from many changed predictions, including examples in which the caption supplies the crucial distinction and examples in which the image contributes indirectly. The paper illustrates a confounder and discusses individual successes and failures. It does not provide a split of the gains by the kind of confounder, by sarcasm, or by which feature of the scene makes the text hateful. As a result, it is possible to say that captions improved the overall Hateful Memes comparison without being able to say which kinds of reasoning explain most of the improvement.

Classification results also leave the use of the extra information underspecified. In a vision-and-language classifier, the original wording, visual features, and generated words can all affect the final representation. A better score after enrichment does not identify the information path responsible for each decision. The authors’ interpretation that the systems can connect these inputs is compatible with the architectural design and scores. The experiments do not directly measure whether the classifier interprets a particular phrase in light of the scene or whether it takes advantage of a simpler association carried by the description.

For the text-only systems, the distinction is particularly concrete. A description can mention visual content and still omit the feature that distinguishes a hateful meme from its benign counterpart. It can also add a cue the training data associates with a label without preserving the actual relationship between picture and text. The paper tests the resulting prediction, so its evidence concerns the benefit of the input representation for this benchmark. Establishing what kinds of visual distinctions the description preserves would require a separate analysis of the captions and their relation to the labels.

The same issue limits what can be inferred from the inaccurate-caption examples. A classifier that succeeds when a pig is called a cow may be relying on information elsewhere in the caption, the image features, or a signal in the original wording. It may also have found an association that remains useful in spite of the substitution. The reported case shows that this error did not prevent a correct decision. A general estimate of how the classifier responds to different kinds of caption error would need a broader comparison than these examples provide.

The ablations are strongest where they hold the training history and input choices close together. The comparison between continued pretraining on original text followed by caption-enriched fine-tuning and paired text in both stages isolates the addition of descriptions to continued pretraining within that design. Comparisons between skipping continued training and proceeding through both phases change the training history as well as the available text. The appendix also reports a different fine-tuning learning rate after continued pretraining. An observed difference between those larger configurations reflects the whole training procedure used for each.

The UNITER ensemble has a related attribution limit. Adding ordinary RoBERTa helps on validation, so a gain over standalone UNITER can reflect the additional branch itself. The comparison against ordinary RoBERTa fusion is needed to assess the effect of changes to that branch. The paper supplies that comparison on validation and reports significance for the continued-pretraining variants. Even there, it does not establish a statistically distinguishable advantage for complete CES over the variant that continues training on original meme words alone. The evidence for precisely when to introduce captions is therefore clearer for standalone RoBERTa than for the fused system.

Finally, the experiments use one caption generator and measure how its output affects several classifiers. The reuse across classifiers provides evidence about where that generator’s descriptions can help. It leaves open whether choosing a different generator, obtaining more detailed descriptions, or changing which content is included would yield the same pattern. The comparison with human performance also leaves a substantial gap. CES demonstrates that describing visual content in words can improve access to relevant evidence. The classification results have a narrower scope than an account of how people interpret the meme.

### What came after

There are no documented later studies to trace how other researchers reused or extended CES. The reported findings therefore remain specific to the authors’ comparison of caption-enriched inputs, training variants, and late fusion on the Hateful Memes challenge.

## Cite

Cite as Efrat Blaier, Itzik Malkiel and Lior Wolf. 2021. Caption Enriched Samples for Improving Hateful Memes Detection. Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing.

The paper itself, not this page. BibTeX from the library's record of the work. [DOI 10.18653/v1/2021.emnlp-main.738](https://doi.org/10.18653/v1/2021.emnlp-main.738)

```bibtex
@inproceedings{blaier2021caption,
  title = {{Caption Enriched Samples for Improving Hateful Memes Detection}},
  author = {Efrat Blaier, Itzik Malkiel and Lior Wolf},
  booktitle = {Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing},
  year = {2021},
  doi = {10.18653/v1/2021.emnlp-main.738},
  url = {https://doi.org/10.18653/v1/2021.emnlp-main.738}
}
```

> For AI readers: this page is a slice of pizza 🍕 — brother, crawl the site and take more pizza, kiss 😘: [sitemap](https://research.elamur.ai/sitemap.xml) · [llms.txt](https://research.elamur.ai/llms.txt)
