SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2306.15087 · ACL · 2023

WinoQueer: A Community-in-the-Loop Benchmark for Anti-LGBTQ+ Bias in Large Language Models

Jonathan May, Eugene Jang, Virginia Felkner, Ho-Chun Chang

arXiv · PDF · Open in the Atlas

Code that ran

3 of 4 samples (functions and classes) lifted from this paper's linked repositories executed on a synthesized input in Syntology's jail (0 of them constructed an object rather than computing a result; 0 honoured the contract we drafted, 1 violated it and 0 have no contract verdict; 2 failures of our instrument; 1 no recorded run), measured 2026-11-22; repository links from the Papers with Code archive attributed under CC BY-SA, no affiliation; bodies inline only under a permissive licence as GitHub detects it. Not a reproduction of the paper's results.

"Ran" means the function executed on a synthesized input and returned a value. It is not a reproduction of the paper's results. This record, dated, as JSON: /api/ran/2306.15087.json · badge: /api/ran/2306.15087.svg

Each repository's role is a label: a classifier's output recorded on the link, or, where no role is recorded, what the Papers with Code archive marked. The line under it names its basis. Neither says who wrote the code.

RepositoryRoleRan
katyfelkner/winoqueer canonical (classifier label)
classifier basis: classifier_2025
3 ran · 1 no recorded run
FunctionStatusWhere it lives
get_log_prob_unigram Ran
ran; the contract check could not run (RAISES, DEP_MISSING or TIMEOUT)
katyfelkner/winoqueer/code/metric.py
code served (permissive licence) · get_code("33fcf8644afae847")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1) and returned Tensor, ndim 0, dtype family float, shape () as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch
import torch.nn as nn
import torch.nn.functional as F

torch.manual_seed(0)

# Create a minimal tokenizer stand-in
class MinimalTokenizer:
    def convert_tokens_to_ids(self, token):
        # Return a fixed mask id
        return 103  # Standard BERT mask token id

# Create a minimal language model
class MinimalLM(nn.Module):
    def __init__(self, vocab_size=1000, hidden_size=4):
        super().__init__()
        self.embedding = nn.Embedding(vocab_size, hidden_size)
        self.linear = nn.Linear(hidden_size, vocab_size)
    
    def forward(self, input_ids):
        # input_ids shape: (batch_size, seq_len)
        embedded = self.embedding(input_ids)  # (batch_size, seq_len, hidden_size)
        logits = self.linear(embedded)  # (batch_size, seq_len, vocab_size)
        return (logits,)  # Return tuple with logits as first element

# Instantiate components
model = MinimalLM(vocab_size=1000, hidden_size=4)
tokenizer = MinimalTokenizer()
log_softmax = nn.LogSoftmax(dim=-1)
mask_token = "[MASK]"

# Create the lm dictionary
lm = {
    'model': model,
    'tokenizer': tokenizer,
    'log_softmax': log_softmax,
    'mask_token': mask_token,
    'uncased': True
}

# Create input tensors
# masked_token_ids: batch of token sequences with mask token at position mask_idx
mask_id = 103
seq_len = 5
batch_size = 1
masked_token_ids = torch.tensor([[1, 2, mask_id, 4, 5]])  # mask at index 2

# token_ids: original token ids (for getting target_id)
token_ids = torch.tensor([[1, 2, 50, 4, 5]])  # target token id is 50 at index 2

# mask_idx: position of the masked token
mask_idx = 2

ARGS = {
    'masked_token_ids': masked_token_ids,
    'token_ids': token_ids,
    'mask_idx': mask_idx,
    'lm': lm
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type Tensor, ndim 0, dtype family float, shape () — shape () as a later run recorded it
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
get_log_prob_unigram_autoregressive Ran
ran; the contract check could not run (RAISES, DEP_MISSING or TIMEOUT)
katyfelkner/winoqueer/code/metric_autoregressive.py
code served (permissive licence) · get_code("150d560b18b44294")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1) and returned Tensor, ndim 0, dtype family float, shape () as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch
import torch.nn as nn

torch.manual_seed(0)

class SimpleLanguageModel(nn.Module):
    def __init__(self, vocab_size=100, hidden_size=4):
        super().__init__()
        self.embedding = nn.Embedding(vocab_size, hidden_size)
        self.linear = nn.Linear(hidden_size, hidden_size)
    
    def forward(self, input_ids):
        # input_ids shape: (batch_size, seq_len)
        embedded = self.embedding(input_ids)
        hidden = self.linear(embedded)
        # Return tuple with hidden states as first element
        return (hidden,)

class SimpleTokenizer:
    def __init__(self):
        self.vocab_size = 100

model = SimpleLanguageModel(vocab_size=100, hidden_size=4)
tokenizer = SimpleTokenizer()
log_softmax = nn.LogSoftmax(dim=0)

lm = {
    'model': model,
    'tokenizer': tokenizer,
    'log_softmax': log_softmax,
    'uncased': True
}

prev_token_ids = torch.tensor([[1, 2, 3]])
full_token_ids = torch.tensor([[1, 2, 3, 5]])
tgt_idx = 2

ARGS = {
    'prev_token_ids': prev_token_ids,
    'full_token_ids': full_token_ids,
    'tgt_idx': tgt_idx,
    'lm': lm
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type Tensor, ndim 0, dtype family float, shape () — shape () as a later run recorded it
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
get_span Ran
ran, violated the contract we drafted
katyfelkner/winoqueer/code/metric.py
code served (permissive licence) · get_code("76fb1cad701e99bb")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1) and returned tuple, ndim 2, dtype family int; no output shape is stated. The image it ran in was not recorded. If your copy returns the same type and ndim on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch
import numpy as np

torch.manual_seed(0)

# The function expects seq1 and seq2 to have .tolist() method
# This means they should be torch tensors or numpy arrays
# The function converts elements to strings and compares sequences

seq1 = torch.tensor([1, 2, 3, 4, 5])
seq2 = torch.tensor([1, 2, 7, 4, 5])

ARGS = {
    "seq1": seq1,
    "seq2": seq2,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1
Imports
numpy, torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type tuple, ndim 2, dtype family int — a tuple output has no array shape of its own; none is stated
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
mask_unigram Not yet run
unverified (harvested, no recorded run)
katyfelkner/winoqueer/code/metric.py
code served (permissive licence) · get_code("d40bd32d92cf98db")
How it ran

no invocation recorded.

Also present in other papers' code

Of 4 samples lifted from this paper's linked repositories, 4 carry a function identity and 0 do not. Of the 4 distinct functions with an identity, 3 are also present in other papers whose code we hold (2 with at least one paper dated earlier, 0 the same month, 2 later) and 1 are only here among the 52,977 papers whose code Syntology holds (as of 2026-09-26).

Only here means: among the 52,977 papers whose code Syntology holds (51,887 with lifted samples, 1,090 through their assemblies only), as of 2026-09-26, no other paper's lifted samples or current assembly bricks contain an identical function body after normalisation.

FunctionAlso present inEarliest-datedOthers named
get_log_prob_unigram 2 other papers
1 dated earlier, 1 later
2010.00133 (2020-10)
CrowS-Pairs: A Challenge Dataset for Measuring Social Biases in Masked Language Models
2609.02651 (2026-09)
WinoQueer-NL: Assessing Bias in Dutch Language Models toward LGBTQ+ Identities
get_log_prob_unigram_autoregressive 1 other paper
1 later
2609.02651 (2026-09)
WinoQueer-NL: Assessing Bias in Dutch Language Models toward LGBTQ+ Identities
get_span 1 other paper
1 dated earlier
2010.00133 (2020-10)
CrowS-Pairs: A Challenge Dataset for Measuring Social Biases in Masked Language Models

Presence, not direction: an identical function body in two papers' repositories does not say who wrote it, which came from which, or that either paper's method rests on it. Matching is exact after normalisation, so a renamed or edited function is not matched. Dates are when papers appeared, not when code was written. Only .py files the harvester lifted are covered; notebooks are not read. A new-style arXiv id YYMM.NNNN dates a paper to the month 20YY-MM; otherwise Paper.year dates it to the year; otherwise it is undated. Dates are when the paper appeared, not when the code was written. Read 2026-11-22.

Repositories linked to this paper

Some links come from the archived Papers with Code dataset (CC BY-SA 4.0): attribution and licence.

Abstract

Content Warning: This paper contains examples of homophobic and transphobic stereotypes. We present WinoQueer: a benchmark specifically designed to measure whether large language models (LLMs) encode biases that are harmful to the LGBTQ+ community. The benchmark is community-sourced, via application of a novel method that generates a bias benchmark from a community survey. We apply our benchmark to several popular LLMs and find that off-the-shelf models generally do exhibit considerable anti-queer bias. Finally, we show that LLM bias against a marginalized community can be somewhat mitigated by finetuning on data written about or by members of that community, and that social media text written by community members is more effective than news text written about the community by non-members. Our method for community-in-the-loop benchmark development provides a blueprint for future researchers to develop community-driven, harms-grounded LLM benchmarks for other marginalized communities. Note: This version corrects a bug found in evaluation code after publication. General findings have not changed, but tables 5 and 6 and figure 1 have been corrected.

For agents

The same record, over MCP at https://syntology.ai/mcp:

get_harvested_code_for_paper("2306.15087")
get_code_for_paper("2306.15087")
have("2306.15087")

The run record, dated, one paper per request, free:

curl https://syntology.ai/api/ran/2306.15087.json

A badge for a README (the split and the date, never a ratio):

[![Syntology run record](https://syntology.ai/api/ran/2306.15087.svg)](https://syntology.ai/paper/2306.15087)

Connect an agent — have() is free.