HateCheckHIn: Evaluating Hindi Hate Speech Detection Models
Paper · 2022 · Mithun Das, Punyajoy Saha, Binny Mathew et al.
Summary
A hate speech detector can recognize an attack written in Devanagari and miss an attack written in Roman Hindi. It can also flag a message that quotes an attack in order to condemn it. A single accuracy score gives these errors the same weight and reveals little about the conditions that produced them. HateCheckHIn is a diagnostic test suite built around those conditions. Its authors write short examples for specific tasks, such as recognizing a threat, interpreting a group reference across sentences, or distinguishing a neutral mention of a community from abuse directed at it.
The suite contains 5,884 cases. It adapts 28 monolingual tests from the English-language HateCheck and adds 6 tests concerned with script and language. The additions cover Hindi written in Roman letters, English written in Devanagari, slurs written in a different script from their surroundings, and sentences that combine English with Hindi. The authors use templates to vary the identity under discussion and write individual cases where a template would be less suitable. Annotators review the expected labels and discuss disagreements.
The authors evaluate two versions of multilingual BERT, trained on different Hindi datasets, and the commercial Perspective API. Perspective has the highest accuracy across HateCheckHIn as a whole at 63.88%. On the multilingual cases, the version trained on the CONSTRAINT-2021 data leads at 44.95%, followed by Perspective at 30.35% and the version trained on the HASOC-2021 data at 13.98%. Every case in that multilingual subset is labeled hateful, so these figures describe how frequently the systems recognize hate in the selected forms. The monolingual tests expose a different error. The HASOC-trained classifier correctly handles just 14.66% of the cases that quote hate to condemn it. Accuracy also varies according to the community named in the examples.
The paper’s contribution is a way to locate failures that would be hard to interpret from the aggregate alone. The system with the highest overall accuracy misses most of the supplied examples in several multilingual categories. Meanwhile, a classifier that recognizes some forms of attack can still flag a reply that rejects one. The results describe behavior on deliberately constructed examples and identify specific distinctions that Hindi hate speech detectors need to handle.
Deep dive: HateCheckHIn: Evaluating Hindi Hate Speech Detection Models
HateCheckHIn tests Hindi hate speech detection and shows where changes in script, mixed languages, and counterspeech lead to errors. · about 32 minutes to read
The problem and its context
What an overall score leaves open
A conventional evaluation of hate speech detection begins with a collection of labeled messages and sets some of them aside for testing. A detector assigns a label to each of those messages. An overall score describes how frequently its choices agree with the reference labels, or how well it balances errors involving a particular class. The paper treats these scores as useful summaries. Its concern is that they give a reader few clues about why a system makes a mistake or what kind of example would be most informative to inspect next.
Consider a detector that does well when a message states hostility explicitly. The same detector may fail when a message first introduces a community and then refers to it indirectly. If explicit attacks are common in the held-out data, strong performance on them can dominate the score. A weak result on cases requiring the detector to resolve a reference may contribute very little to the aggregate. Even when an error is counted, the aggregate cannot tell a reader whether the difficulty involved a reference, the target of a threat, the function of a quotation, or the script in which the message was written. This is the problem HateCheckHIn addresses within evaluation and benchmarks.
Accuracy counts correct decisions across a set of messages. Precision asks how many messages flagged as hateful actually have the hate label. Recall asks how many messages labeled hateful the detector manages to flag. An F1 score combines precision and recall into a single measure. Each can describe a different aspect of performance on a test set. None on its own identifies the linguistic circumstances associated with the errors. A useful diagnostic therefore starts with a more specific question about what a detector should do when it encounters a recognizable kind of message.
The paper also gives a reason to be cautious about strong performance on a held-out split. Training and test examples drawn from the same collection can share incidental patterns. A detector might learn that a community name is associated with hateful examples in the training data and benefit from that association in the test split. The same shortcut can then lead it to flag a neutral statement about the community. The authors connect this concern to earlier work on bias in hate speech detection and to the effects of choices about sources, sampling, and labeling. The Risk of Racial Bias in Hate Speech Detection
This matters because the mistakes have different consequences. Missing an identity-directed attack leaves it undetected. Flagging a person who objects to such an attack puts a response to hate in the same category as the attack. The paper singles out the latter error in its discussion of moderation. A measurement that keeps these cases separate allows a reader to see where an apparently capable detector has difficulty, even before anyone tries to determine why the difficulty arose.
Earlier datasets and behavioral tests
The paper situates its work in a field that had already developed labeled social media datasets and shared tasks. Research cited by the authors includes work on finding hateful content on Twitter, distinguishing hate from offensive language, and benchmarking aggression. These lines of research supplied data on which detectors could be built and compared. The distinctions in their tasks also matter for interpreting a result. A system trained to identify broadly offensive language faces a different labeling problem from a system whose positive class is defined by an attack tied to identity. Hateful Symbols or Hateful People? · Automated Hate Speech Detection and the Problem of Offensive Language · Benchmarking Aggression Identification in Social Media
The authors describe English as the predominant language in earlier datasets, alongside work that broadened coverage to languages including Hindi, Greek, Danish, Mexican Spanish, and Turkish. They cite a Hindi–English social media dataset as evidence that mixed-language writing was already a subject of hate speech research. The distinction in their own study is the purpose of the data. A corpus collected to train a detector or score it on a held-out sample can serve as a starting point. A suite of functional tests deliberately assembles examples around particular decisions that a detector should be able to make. A Dataset of Hindi-English Code-Mixed Social Media Text for Hate Speech Detection
Functional testing draws on a software testing practice. A test presents an input, specifies what response is expected, and observes the response returned by the system. A black-box test uses this input–output behavior as its evidence. It can therefore be applied to a system whose training records or internal implementation are unavailable. For language tasks, the challenge is to frame an expectation in a way that can be applied to multiple examples. The paper cites CheckList as the earlier framework that showed how to organize this kind of behavioral assessment for natural language processing. CheckList
The most direct predecessor is HateCheck, which applied functional testing to English hate speech detection. As described by the authors, its categories came from earlier research and conversations with civil society stakeholders. Its 29 functionalities included 18 ways that hate could be expressed and 11 non-hateful contrasts. A functionality is a family of examples that asks a specific behavioral question. For instance, a test might ask whether a detector recognizes an identity-directed attack framed as an opinion. A contrasting test might ask whether it accepts an ordinary statement about a protected group. The preceding literature also included diagnostic material on context-dependent uses of language, including reclaimed slurs and ways that speakers distance themselves from offensive remarks.
Why Hindi changes the test
An English functional test can supply a useful starting question while leaving some of the writing practices in Hindi social media unexamined. The authors describe posts that combine English, Roman Hindi, and Devanagari Hindi. In one of their motivating examples, an English opening is followed by Roman Hindi, with a hashtag in Devanagari. The contents of that example illustrate how little the script of any one part of a message tells a detector about the language and meaning of the rest.
Code-mixing means using material from different languages within a message or utterance. Writing Hindi in Roman letters is a distinct phenomenon. In that case the spelling uses a different script, while the wording can remain Hindi throughout. Conversely, English words can be represented in Devanagari. A single sentence can combine both phenomena, bringing English and Hindi together while changing the script used for one portion. These distinctions matter in multilingual and cross-lingual NLP because they give an evaluator different questions to ask of a detector.
The authors choose Hindi because of its large speaker population and because they are proficient in reading and writing it. That practical qualification matters for a test suite built from judgments about whether a short text is plausible, whom it targets, and what it communicates. Their goal is to preserve the useful distinctions in the English suite while making room for forms that a straightforward translation would leave out. The resulting setup tests whether a detector can make the same broad hate judgment when the writing practices around that judgment change.
The method, step by step
Decide what counts as hate
The authors begin with a working definition drawn from the United Nations. In their setup, hate speech involves attacking or using disparaging or discriminatory language about people on the basis of identity. A message can concern a group or an individual identified with that group. Identity can involve, for instance, religion, national origin, caste, gender, or sexual orientation. The defining question for a case is what role identity plays in the attack.
This boundary determines how to handle negative language aimed elsewhere. An expression of hatred for a fruit can use the same emotional vocabulary as an expression of hatred for members of a religion. The examples belong to different classes because the fruit is an object and the religious group is an identity-based target. An insult directed at a person independently of a protected identity also belongs on the non-hateful side of the suite’s boundary. The label in this test answers a specific question about hate. A judgment about offensiveness, general toxicity, or any other moderation category could differ.
The expected answer for an individual case is its gold label. Across HateCheckHIn, the possible answers are hateful and non-hateful. Each functionality groups examples with the same expected answer. That property makes it possible to read a functionality’s accuracy as the success rate on a particular kind of decision. A low score on hateful examples means the detector typically failed to flag them. A low score on non-hateful examples means the detector typically flagged material that the test expected it to accept.
How the authors construct and use HateCheckHIn
The steps in order.
Adapt the monolingual tests
HateCheckHIn’s 34 functionalities include 28 monolingual categories taken from the earlier HateCheck design. The numbering used in the paper retains the earlier sequence. The original list includes a category for innocuous words that have the same form as slurs, identified as F8. The Hindi results table skips that category. The paper explains that it removed a functionality because the scenario was judged unrealistic for Hindi. The adaptation therefore starts from the English taxonomy and uses cases the authors consider suitable for the language in which they are testing.
Some retained categories distinguish the way hostility is expressed. An attack can directly state strong dislike, use an extremely negative description, dehumanize its target, or convey contempt indirectly. Threats receive separate treatment according to whether they are expressed directly or presented as something that ought to happen. The suite also includes hate voiced as a question or as an opinion. These categories let the authors ask whether a detector recognizes the meaning of an attack across different sentence forms.
Other categories depend on connecting text across clauses or sentences. A message can name a group and use a later reference to direct hostility toward it. Interpreting the target then requires reading beyond the clause that contains the hostile language. Negation presents a different challenge. A sentence can deny a favorable characterization and thereby disparage a group, or it can deny a hateful sentiment and receive the non-hateful label. The scope and meaning of the negation matter to the decision. Coreference resolution
The tests for slurs and profanity likewise distinguish between the presence of a word and what the speaker does with it. A slur may be used to attack or appear in a reclaimed use. Profanity can be part of group-directed abuse or can express emphasis in a remark with no identity-based attack. The suite also tests neutral and positive statements that name protected groups. A detector that treats a group name or a swear word as sufficient evidence of hate has several opportunities to make an error on these families.
Counterspeech gives the distinction a particularly concrete form. In one category the speaker quotes an expression of hate while objecting to it. In another, the speaker refers to the hate while denouncing it. The label follows the stance of the message as a whole. A quotation can contain language that would be hateful as an independent utterance, while the sentence containing the quotation rejects that position. A detector needs enough context to recognize what the writer is doing with the words.
Another part of the suite targets the boundary around protected groups. It includes attacks on objects, people addressed individually without an identity-based attack, and groups outside the protected categories used by the authors, such as occupational groups. These are assigned non-hateful labels even when they contain strongly hostile wording. Such cases complement neutral and positive group mentions. The latter contain an identity term without an attack, while the former contain an attack without a protected identity as its basis.
The final monolingual families change how hateful text is written. They cover transposed neighboring characters, omitted characters, removed word boundaries, extra spacing between characters, and spellings that substitute symbols or digits for letters. These changes probe whether a detector can recognize an attack even when its written form is altered. A character swap within a word and a missing space between words both disturb the surface form, but they do so at different places. Keeping them in separate families allows the evaluation to register different responses to those changes.
Separate language from script
The six new categories are marked MF1 through MF6. They all carry the hateful label. Each uses a particular combination of language, script, or placement of the slur. Roman Hindi means Hindi represented with Roman letters. Devanagari is the script used for the Hindi portion in the categories that contrast with Roman Hindi. English vocabulary and Roman lettering are therefore separate features of a message.
MF1 uses Hindi throughout and puts it in Roman letters. An expression of hostility towards a protected group remains an expression in Hindi, even though no Devanagari is visible. The category asks whether a detector recognizes the attack under that representation. The authors report 31 templates and 310 cases for this family. Its size matters when reading an aggregate for all multilingual cases, since each case contributes to that aggregate separately.
MF2 and MF3 place a slur in a different script from the rest of the text. MF2 uses Roman Hindi as the surrounding text and puts the slur in Devanagari. MF3 uses Devanagari for the surrounding Hindi and writes the slur in Roman characters. Each uses 16 templates and contains 160 cases. The two directions are kept separate because a detector may respond differently depending on which part of the message appears in the less familiar representation. The categories describe where the script switch occurs.
MF4 applies a different language–script combination. The underlying sentence is English, with Devanagari characters representing its English wording. A reader has to understand English to interpret the sentence after recognizing what the spelling represents. The authors write 19 templates and generate 190 cases. This category addresses whether a detector can recover an English attack from a script it might ordinarily associate with Hindi.
MF5 and MF6 combine English and Hindi words in the same message. In MF5 the Hindi material appears in Devanagari. Some of the examples use English to express agreement or introduce a proposal and Hindi to express the attack. The authors give this category 15 templates and 150 cases. In MF6 the Hindi material appears in Roman letters, so English and Hindi can share a script. This category uses 16 templates and contains 160 cases. Across these families, the intended distinction is between mixing languages across visibly different scripts and mixing languages in a common script.
These categories organize the multilingual material around properties a reader can identify in the input. A classifier might handle Hindi in Devanagari, for instance, while struggling with Hindi in Roman letters. The suite can show whether that difference coincides with a change in the label returned. It can also reveal a different problem when the classifier recognizes a Roman Hindi statement but misses English written in Devanagari. The design identifies cases in which those behaviors can be observed and compared.
Write and review the examples
For the monolingual families, the authors manually write short Hindi texts. For the multilingual families, they construct short texts using the relevant language and script arrangements. They seek diversity of vocabulary and sentence structure within a family so that its cases do not all present exactly the same wording. The expected label stays fixed for the family while the sentences vary in how they express the relevant behavior.
Templates make this process more systematic. An identity slot marks a place where the authors can insert a designation for a protected group. A slur slot marks a place where the appropriate derogatory term can be inserted. A pattern expressing hatred for a group, for example, can generate cases about different groups while retaining the surrounding sentence. The shared wording makes the resulting examples useful for asking whether the target changes the detector’s answer. Cases that could not be handled through these slots were written individually.
The suite covers 10 protected groups as the paper organizes them. They include Hindu and Muslim religious identities, Bangladeshi and Pakistani national origins, and the Dalit and lower-caste categories. The paper also includes women, a gender-identity category it calls eunuch, a British category it lists under race, and a category it calls homosexual under sexual orientation. These names describe the paper’s operational test categories. Their role is to provide different targets for otherwise comparable kinds of expression.
The 6 multilingual categories use 113 templates in total. For each category the paper lists 10 target groups. Across the full suite, the authors report 4,754 monolingual cases and 1,130 multilingual cases, for a total of 5,884. The main monolingual and multilingual sets thus differ in their size as well as their composition. The individual examples remain the units counted in the accuracy scores. A set with more examples has more influence when the paper pools the predictions.
The authors have two PhD students with experience on hate speech projects review the cases. The reviewers work with detailed guidelines and discuss disagreements until they settle on a label. The authors remove 43 cases they judge unrealistic. They report a Fleiss’ kappa of 0.95 for agreement. Kappa summarizes how closely the annotators agree while allowing for agreement expected by chance. In this setting it describes label consistency for purpose-written items under the study’s instructions. Linguistic annotation
This review serves a different purpose from testing the detectors. The annotators establish the intended category of the message and help screen the material for plausibility. The detectors are evaluated against the resulting labels. The full diagnostic dataset is released under the name HateCheckHIn.
Assemble the systems for comparison
The authors use multilingual BERT, abbreviated mBERT, as the common starting point for two classifiers. The paper describes mBERT as a pretrained encoder that learned from Wikipedia text in 104 languages. Its pretraining objective required it to predict masked material from surrounding text. The base architecture uses attention, which lets the encoder combine information from different positions in its input. By starting both Hindi classifiers from the same multilingual encoder, the authors can compare two versions that share a base architecture while having learned their hate classification task from different datasets. BERT · Transformer and attention
The study then applies supervised fine-tuning. In this procedure, the pretrained encoder is adjusted using examples with labels for the task at hand. One run uses the Hindi data associated with HASOC-2021. The other uses Hindi data from CONSTRAINT-2021. The authors use the train, validation, and test splits supplied with the respective datasets. They reduce each dataset to the hate and normal classes, keeping examples with those labels and discarding examples in the other categories. The run trained on the HASOC data is H-21, and the run trained on the CONSTRAINT data is C-21. HASOC at FIRE 2021
The reported settings are an Adam optimizer with an initial learning rate of 2e-5, a token setting of 256, and training for 10 epochs. The learning rate controls the scale of the parameter updates at the start of training. Tokens are the units the encoder consumes, and an epoch is a pass through the training data. The paper uses class weights to give greater influence to the less frequent class during training, which is typically the hateful class. For each run the authors keep the checkpoint with the best validation macro F1. Macro F1 gives each label’s F1 score equal standing in the average. Its role here is to select a checkpoint on the validation data. Tokenization
Perspective API is the third comparison system, abbreviated P. The service returns a score for toxicity, among other dimensions. The authors turn its toxicity score into a binary decision using a 50% cutoff. This gives them an output they can compare with the hate and non-hate labels. The paper describes Perspective as a commercial moderation tool whose architecture and training data are unknown to the authors. The evaluation reflects the service as accessed in December 2021.
The scoring rule on HateCheckHIn is the same for all three systems. The authors count a decision as correct when it matches the expected label for that example. For a functionality, accuracy is the percentage of its examples classified correctly. For pooled results, the paper micro-averages over cases, meaning that each included example contributes equally to the score. That procedure allows the authors to report accuracy over the whole test, over just the hateful or non-hateful cases, or over the cases associated with an individual target group.
Experiments and results
The datasets and what the scores measure
The datasets used to prepare H-21 and C-21 were originally organized around broader tasks. The source HASOC-2021 collection has 6,126 tweets and labels covering hate, offensive content, profanity, and a category for tweets outside those classes. The source CONSTRAINT-2021 collection has 8,192 tweets and includes fake news, hate speech, offensiveness, defamation, and a non-hostile category. Those are the original collection sizes. The authors’ binary filtering means that each fine-tuning run uses a subset of its source collection. The reported functional results come from HateCheckHIn, which is separate from those source splits.
HateCheckHIn’s monolingual portion includes both labels. The paper’s label-wise results table lists 3338 hateful monolingual cases and 1416 non-hateful monolingual cases. All 1,130 multilingual cases are hateful. This composition affects how to read accuracy. Overall accuracy includes both successes at detecting an attack and successes at leaving non-hateful material unflagged. Accuracy on the multilingual portion measures successes at detecting hateful examples in the selected language and script combinations.
The authors use 50% as a random-choice reference for the binary task and flag individual functionality scores below that figure. The reference answers how often an equally likely guess between the labels would be correct. A functionality, however, has a fixed true label. Scoring below the reference on a hateful category means the detector usually returns the non-hateful label for that category. Scoring below it on a non-hateful category means the detector usually flags cases that are supposed to pass. This difference is essential when comparing failures from the same results table.
Overall accuracy and label-wise results
Overall accuracy on HateCheckHIn
Perspective has the highest accuracy when all diagnostic cases are pooled.
The numbers
| System or setting | accuracy % |
|---|---|
| H-21 | 49.88 |
| C-21 | 53.87 |
| Perspective (this paper) | 63.88 |
Perspective leads on the complete suite at 63.88%, followed by C-21 at 53.87% and H-21 at 49.88%. The ordering also holds for the two labels when each is pooled across all applicable cases. On hateful examples overall, Perspective reaches 59.78%, H-21 reaches 55.14%, and C-21 reaches 51.32%. On non-hateful examples, all of which are monolingual, Perspective reaches 76.83%, C-21 reaches 61.86%, and H-21 reaches 33.26%. The positions of H-21 and C-21 reverse between the two labels.
The split between hateful and non-hateful material changes how to interpret H-21’s overall result. On hateful monolingual cases it gets 69.08%, close to Perspective’s 69.74% for the same cases. C-21 gets 53.47% there. H-21’s low score on non-hateful material shows that its relative success at flagging monolingual attacks accompanies frequent false alarms in the suite. C-21 has a different profile. It recognizes fewer hateful monolingual cases than H-21 and correctly accepts more non-hateful ones.
These results clarify the significance of Perspective’s lead. Its performance on non-hateful cases helps account for its position on the entire suite. Even there, the aggregate leaves room for large differences among kinds of non-hateful material. Straightforward positive and neutral group mentions are handled much more successfully than quoted material in counterspeech. A deployment question about whether people can safely quote the abuse they are opposing needs the latter distinction.
Multilingual accuracy
Accuracy on HateCheckHIn multilingual cases
C-21 detects the most hateful cases across the pooled multilingual tests.
The numbers
| System or setting | accuracy % |
|---|---|
| H-21 | 13.98 |
| C-21 (this paper) | 44.95 |
| Perspective | 30.35 |
C-21 leads on the multilingual subset with 44.95%, compared with 30.35% for Perspective and 13.98% for H-21. All three scores fall below the paper’s 50% reference. The ordering also differs from the overall ranking. The detector that is strongest when all diagnostic cases are pooled is overtaken by C-21 when the evaluation is restricted to the multilingual material. This is the subset on which the language and script additions to HateCheck are directly measured.
Roman Hindi gives the clearest example of the change. On MF1, H-21 correctly labels 0.0% of the 310 cases. C-21 correctly labels 59.03% and Perspective 25.48%. With a Devanagari slur in otherwise Roman Hindi text, the MF2 results are 0.0% for H-21, 58.75% for C-21, and 9.37% for Perspective. The complete failure of H-21 on these families is specific to those supplied inputs. Its much higher score on hateful monolingual material establishes that the classifier was able to detect many attacks elsewhere in the suite.
For MF3, where the slur appears in Roman letters inside Devanagari Hindi, all the results remain below the paper’s reference. H-21 gets 32.5%, C-21 gets 34.37%, and Perspective gets 19.37%. Each system reacts differently to the change in which portion of the text carries the script switch. C-21 and Perspective have lower accuracy on MF3 than on different parts of the broader multilingual suite, while H-21 recognizes some attacks in MF3 after recognizing none in MF2. The two families specify different writing arrangements, which makes their results more informative than an undifferentiated score for mixed scripts.
English represented in Devanagari is difficult for every system. On MF4, H-21 gets 12.63%, C-21 gets 1.05%, and Perspective gets 23.68%. C-21’s score is its weakest among both the multilingual and monolingual families. Its success on Roman Hindi consequently gives a poor indication of how well it will handle English under a script change in the other direction. Perspective leads on MF4, while still missing most of the hateful cases in that family.
The two forms of code-mixing also produce different results. On MF5, the English and Devanagari Hindi family, Perspective reaches 66.00%, H-21 reaches 49.33%, and C-21 reaches 46.66%. On MF6, where English and Roman Hindi are mixed, C-21 leads at 65.00%, Perspective gets 46.25%, and H-21 gets 5.0%. The strongest system on each family changes with the writing arrangement. Across all 6 multilingual functionalities, H-21 falls below 50% on 6, C-21 on 3, and Perspective on 5. Perspective’s MF5 result accounts for its one multilingual family above that reference.
What the monolingual tests disclose
On the monolingual families, H-21 falls below 50% accuracy on 6 out of 28, C-21 on 9 out of 28, and Perspective on 3 out of 28. Counting categories that fall below a reference and pooling cases answer different questions. A count treats each functionality as one opportunity to fall below the reference, regardless of its size. A micro-average counts each decision on each case equally. This is why a reader can reasonably inspect both the category counts and the aggregated label scores.
The direct-threat category, F5, illustrates a failure to identify hateful material. H-21 gets 69.47%, C-21 gets 26.84%, and Perspective gets 93.15%. When a threat is framed as something that ought to be done, in F6, H-21 gets 78.0%, C-21 gets 50.50%, and Perspective gets 92.50%. The low C-21 result on direct threats is particularly informative given its relative strength on the multilingual subset. A classifier that is useful on some kinds of unusual writing can still struggle with a direct expression of harm in monolingual Hindi.
Non-hateful group mentions expose a different feature of H-21’s predictions. On F18, the family of neutral statements about protected groups, H-21 gets 26.19%, C-21 gets 81.42%, and Perspective gets 96.66%. On F19, the positive statements, the corresponding results are 27.33%, 69.00%, and 96.33%. H-21 frequently flags even favorable statements when a protected identity is present. The scores identify a setting in which that error occurs, while leaving its underlying cause open.
Counterspeech creates a harder non-hateful contrast. On F20, which embeds the quoted hate in a condemnation, H-21 gets 14.66%, C-21 gets 44.66%, and Perspective gets 30.00%. On F21, which condemns the hate by referring to it, H-21 gets 15.55%, C-21 gets 43.33%, and Perspective gets 58.88%. Perspective’s strong results on ordinary group mentions give little indication of its F20 result. For a detector, accepting a benign sentence with an identity name and interpreting the stance of a sentence that repeats hostile words are distinct tasks.
A related contrast concerns negation. F15 contains non-hateful statements that negate hateful sentiments. H-21 correctly classifies 19.6%, C-21 classifies 37.6%, and Perspective classifies 86.40%. F14 contains hate expressed by negating a positive sentiment. Its results are 67.0% for H-21, 60.00% for C-21, and 67.00% for Perspective. The examples give opposite expected labels to different uses of negation. The H-21 results show a particular difficulty in recognizing the non-hateful alternative, while Perspective handles that alternative much more successfully in the supplied cases.
Which community is mentioned
The paper also groups predictions by the identity named in the cases. H-21 reaches 24.43% on the Bangladeshi target and 28.94% on the eunuch target, compared with 64.15% on the Muslim target and 61.92% on the Dalit target. The Bangladeshi and eunuch rows each contain 532 cases in the target-wise table. The Muslim row has 582, and the Dalit row has 583. These are case counts within the grouped evaluation, where the reported accuracy concerns the examples associated with that target.
C-21 reaches 38.72% on the eunuch cases, compared with 71.61% on the Hindu target and 71.18% on the Muslim target. Its Bangladeshi result is 46.61%. Perspective gets 69.36% on the eunuch target and 62.21% on the Bangladeshi target. Its results are around 60% for many groups, with results such as 51.11% on the British target and 79.55% on the target labeled homosexual in the study. The grouped results show that a target on which one system struggles can be handled more successfully by another system. They also make visible variation that the overall accuracy does not describe.
What the ablations show
The paper reports no formal ablation that disables a component or removes a training ingredient, and instead examines controlled contrasts in the test design and compares results across functionalities, labels, and targets.
The language of the attack and the way it is written
The multilingual breakdown provides the clearest evidence that the errors depend on the writing arrangement. H-21 is relatively successful on many hateful monolingual cases and fails on all the examples in the Roman Hindi family. It also fails on all the examples in the family where a Devanagari slur is surrounded by Roman Hindi. Making the surrounding Hindi Devanagari and writing the slur in Roman letters corresponds to a different result. This pattern narrows the observed difficulty to particular inputs, which is more informative than saying that the classifier generally performs poorly on hate speech.
The two code-mixing categories help separate language mixture from the script of the Hindi material. Both contain Hindi alongside English. Perspective does better when the Hindi portion is written in Devanagari, while C-21 does better when it is written in Roman letters. These are comparisons between categories, with their own templates and examples. They show that the difference matters in the test suite. They cannot establish how much of the difference would remain if each example were individually paired with a version that changed only its script.
C-21’s results on Roman Hindi and on English in Devanagari make another point about the scope of a successful test. Both forms put a language in a different script from the one used for much of the study’s monolingual material or for its English text. C-21’s success on Roman Hindi shows some ability to detect the hateful material in that form. Its exceptionally low MF4 score shows how narrowly that ability can carry over. Calling both cases transliteration, the representation of wording in a different script, would obscure the different language and script combinations the classifier has to handle.
The aggregate across multilingual cases establishes how frequently the systems detect the attacks in that portion of HateCheckHIn. The category results qualify what a lead on that aggregate means. C-21 leads overall on the multilingual material and is strongest on Roman Hindi mixed with English. Perspective leads when the Hindi portion of the mixed message appears in Devanagari. Each comparison supplies behavior-level evidence. The paper does not inspect the representations or processing steps that would establish why either system handles its stronger category better.
Recognizing an attack and recognizing a rejection of it
The monolingual results show how an error can change direction with the behavior under test. C-21 has substantial difficulty with direct threats. The expected decision is hateful, so its errors mainly miss attacks in this category. H-21 has substantial difficulty with condemnation of hate. The expected decision is non-hateful, so its errors mainly flag the condemnation. A single statement that either classifier is weak would leave out the distinction most relevant to the people whose messages would be classified.
The two counterspeech categories also help locate what makes the material difficult. H-21 scores poorly whether the text quotes the hate or refers to it directly. Perspective has a higher correct rate for the direct-reference family than for the quotation family. The authors treat these results as evidence that the systems can miss the context needed to recognize the message’s stance. The comparisons are based on families of purpose-written examples. An explanation involving quotation alone would require closer control over what the paired messages say and how the condemnation is phrased.
The positive and neutral identity cases give a complementary check. H-21’s low accuracy there shows that an example need contain neither a quotation of hate nor an actual attack to elicit a hateful decision. The shared fact across those two families is that a protected group is named in a benign statement. That observation is consistent with the authors’ concern that training data and sampling could teach a detector to react to an identity term. The test establishes the behavioral pattern. Examining what happened during training would require evidence beyond the returned labels.
The negation cases further show that the presence of overt negative language is a poor guide to the expected answer. Rejecting a favorable characterization and rejecting a hateful sentiment have opposite effects on the paper’s labels. A system can do reasonably well on the hateful use of negation while struggling with its non-hateful use. This helps distinguish difficulty interpreting the intent of a negated construction from a general tendency to fail on all examples containing negation.
The training source and the target group
H-21 and C-21 start from the same pretrained encoder and are prepared using the same reported fine-tuning settings. Changing the source dataset is therefore a meaningful comparison between the two resulting classifiers. C-21 handles some multilingual forms much more successfully and does better on the pooled non-hateful examples. H-21 identifies more hateful monolingual examples. The training source is associated with a change in the profile of errors, instead of a uniform change across every behavior.
The source datasets differ in the tasks for which they were collected and the original labels they use. Filtering each to hate and normal examples produces two binary datasets, but it does not equalize their contents. The paper discusses collection and sampling as possible explanations for the behavior it observes. The comparison cannot identify whether any particular property of one source, such as the kinds of language in it or the distribution of its targets, caused the advantage on a specific functional test.
Target substitutions are useful for a similar reason. Where a template holds the rest of a sentence steady, a change in prediction after exchanging the identity gives evidence of sensitivity to the target. The published target-wise table summarizes accuracy over the relevant cases, so it is broader than a tally of matched substitutions alone. Its uneven results make group-dependent behavior visible. Distinguishing an identity effect within matched sentences from the contributions of vocabulary and case mix would call for examining those comparisons individually.
Perspective supplies a different kind of comparison. Its overall lead and its weaker results on particular multilingual forms and counterspeech establish that the functional suite can be applied to a commercial service as well as to the authors’ two trained classifiers. Since the paper compares a thresholded toxicity score with the hate labels, any error reflects that whole classification procedure. The experiment measures where the procedure succeeds or fails under the selected setup.
Limitations
Limits the authors state
Hindi is the language for which the authors construct and validate examples. They suggest that the multilingual categories can guide the development of tests for other languages, including other Indic languages, and identify that extension as future work. The distinction between language and script gives the approach a plausible basis for adaptation. Its success elsewhere would still depend on selecting natural writing practices, identity terms, and contrasts for the language under study. The experiments establish results for the Hindi-based suite.
The authors also emphasize the difficulty of using automated judgments in real moderation. They give the example of a legitimate response to hate being classified as hateful. Their experiment establishes that this kind of error occurs on some constructed counterspeech examples. It does not observe how a platform acts on the decision or how frequently people encounter such an error in practice. The authors discuss more varied training data, augmentation, and possible human involvement in producing additional examples as ways to address weaknesses. These are proposed responses to the results. The study stops at diagnosis and evaluates no intervention.
For Perspective, the authors lack information about the service’s architecture and training data. They describe the service as regularly updated and give the date of their evaluation as December 2021. Its scores therefore refer to the version they accessed at that time, with the toxicity setting and cutoff they used. The authors can compare its returned decisions with the gold labels, but the result cannot identify the particular training choices that led the service to make them.
The case construction process has its own explicit boundary. The authors discard examples that annotators regard as unrealistic and omit a functionality from the earlier English suite because they judge the scenario unsuitable for Hindi. These decisions increase the relevance of the cases they retain. They also mean that what qualifies as plausible is filtered through the authors’ and reviewers’ judgments. The suite reports tests for the chosen families of cases, which are the scope of its coverage.
Limits visible in the setup
The most important interpretive constraint is that every multilingual example is hateful. A low score in that part of HateCheckHIn shows that many supplied attacks were missed. A detector that flagged all of the multilingual items would score well there, whatever it would do with an ordinary multilingual statement. A full picture of performance across both labels would require multilingual examples of benign identity references, profanity used without hate, and condemnation of attacks. The monolingual contrasts do provide evidence about those behaviors in their own writing setting.
The multilingual portion also brings different phenomena under one aggregate. Roman Hindi, English in Devanagari, a script change confined to a slur, and Hindi–English code-mixing can raise different problems for a detector. The categories contain different numbers of cases. Accordingly, the aggregate describes performance on the mixture the authors assembled, with the larger families having more weight. It supplies no estimate of which forms occur most often on social media or how frequently a real moderation stream would contain any particular case.
Purpose-written examples trade some of the complexity of real conversation for diagnostic control. A short statement can make its intended target and stance clear to annotators. A social media message may rely on a previous post, a speaker’s relationship to the target, or other surrounding text. The suite includes cases that require connecting clauses and sentences, which helps test some context-dependent judgments. Those cases still have the scope of the text the annotators wrote for the exercise. The high agreement score supports the consistency of the assigned labels in that setting. It does not imply the same agreement on open-ended conversations.
Templates make it possible to change the identity while preserving a recognizable expression. They also make examples related to one another. A system that responds to a repeated construction in the same way can obtain many successes or many failures within one family. The paper seeks variety in vocabulary and syntax, but the example count alone cannot say how broadly the suite samples independent ways to express the same behavior. The results are reported as accuracy figures, with no uncertainty estimate that accounts for groups of examples derived from the same template.
The target-wise analysis is useful for detecting uneven results under the study’s categories. Different targets have different case counts, and some cases use group-specific wording or slurs. A group’s pooled accuracy can therefore reflect several things, including its name, the other wording it tends to appear with, or the distribution of functionalities and labels in the cases counted. In matched template cases, the name can be varied more directly. The published pooled table cannot partition the observed differences by those possible causes. Nor does it identify how frequently people associated with any group would be affected in an operational system.
The paper uses toxicity as the Perspective score from which it constructs a binary hate decision. The hate label used by the authors is organized around identity-based targeting. It includes non-hateful cases that some other labeling policies might regard as abusive or offensive. Accordingly, a disagreement with the gold label can reflect the difference between the service’s scoring task and the study’s definition, as well as a failure to interpret the text. The authors evaluate one cutoff. They do not provide a threshold sweep that would show how changes to that decision rule affect missed attacks and false alarms on different functionalities.
The two trained classifiers share a starting encoder, and that comparison helps show how much their observed strengths can vary with the training source. There are other plausible explanations for particular failures, including what the encoder learned before fine-tuning and which spellings are easy for it to represent. The study makes no experimental change that isolates these factors. Similarly, it does not establish that the errors it observes would persist in every Hindi detector. Its evidence concerns the decisions of the evaluated systems on the supplied inputs.
Finally, the entire suite’s accuracy is best read alongside the per-functionality and per-label results. The total can be used to summarize this benchmark, whose examples are placed there to expose distinct behaviors. It cannot answer an operational question such as how frequently a detector would flag benign posts in a particular community. That question depends on the real distribution of messages, the policy applied to them, and the decisions made after classification. The paper’s strength is the narrower observation of where the benchmark’s explicit behavioral expectations are missed.
What came after
Airavata is a 2024 work on instruction tuning for Hindi that cites HateCheckHIn. Instruction tuning concerns preparing a system to respond to requests expressed as instructions. HateCheckHIn concerns a specific evaluation task for Hindi, with expected hate and non-hate decisions attached to particular forms of writing. The citation connects work on broader Hindi instruction following with an earlier study of how Hindi capabilities can be evaluated in detail.
The citation establishes a connection between the papers. It leaves open whether Airavata used HateCheckHIn as an evaluation dataset, incorporated any of its examples, or adopted its functional categories. The documented relationship is therefore a later citation from work on Hindi instruction tuning to a diagnostic study of Hindi hate speech detection.
Cite
Cite as Mithun Das, Punyajoy Saha, Binny Mathew and Animesh Mukherjee. 2022. HateCheckHIn: Evaluating Hindi Hate Speech Detection Models. Proceedings of the Thirteenth Language Resources and Evaluation Conference.
@inproceedings{das2022hatecheckhin,
title = {{HateCheckHIn: Evaluating Hindi Hate Speech Detection Models}},
author = {Mithun Das, Punyajoy Saha, Binny Mathew and Animesh Mukherjee},
booktitle = {Proceedings of the Thirteenth Language Resources and Evaluation Conference},
year = {2022},
url = {https://aclanthology.org/2022.lrec-1.575/}
}This page in Markdown https://md.research.elamur.ai/free/en/papers/das-2022-hatecheckhin-evaluating-hindi-hate-speech/