SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2402.17826 · NeurIPS · 2024

Prediction-Powered Ranking of Large Language Models

Eleni Straitouri, Manuel Gomez-Rodriguez, Ivi Chatzi, Suhas Thejaswi

arXiv · PDF · Open in the Atlas

Code that ran

6 of 8 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, 0 violated it and 0 have no contract verdict; 6 failures of our instrument; 2 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/2402.17826.json · badge: /api/ran/2402.17826.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
Networks-Learning/prediction-powered-ranking canonical (classifier label)
classifier basis: census
5 ran · 2 no recorded run
networks-learning/prediction-powered-ranking community
Papers with Code archive
1 ran · 0 no recorded run
FunctionStatusWhere it lives
estimate Ran
ran; our contract draft was wrong, not the code
networks-learning/prediction-powered-ranking/src/estimate.py
code served (permissive licence) · get_code("cdbfedcc67b27ade")
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. The image it ran in was not recorded. If your copy returns the same type 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 numpy as np

# Set random seed for reproducibility
np.random.seed(0)

# Number of models
k = 3

# Number of samples in Dn (labeled dataset)
n = 5

# Number of samples in DN (unlabeled dataset)
N = 7

# Create model_a_matrix and model_b_matrix for Dn
# These are k x n matrices indicating which models are compared
M1n = np.array([
    [1, 0, 1, 0, 1],
    [0, 1, 1, 0, 0],
    [1, 1, 0, 1, 0]
], dtype=float)

M2n = np.array([
    [0, 1, 0, 1, 0],
    [1, 0, 0, 1, 1],
    [0, 0, 1, 0, 1]
], dtype=float)

# Create winner labels for Dn (human annotations)
winner1_human = np.array([[1, 0, 1, 0, 1]], dtype=float).T
winner2_human = np.array([[0, 1, 0, 1, 0]], dtype=float).T

# Create predicted winner labels for Dn
winner1_predicted_n = np.array([[1, 0, 1, 0, 0]], dtype=float).T
winner2_predicted_n = np.array([[0, 1, 0, 1, 1]], dtype=float).T

# Create model_a_matrix and model_b_matrix for DN
M1N = np.array([
    [1, 0, 1, 0, 1, 1, 0],
    [0, 1, 1, 0, 0, 1, 1],
    [1, 1, 0, 1, 0, 0, 1]
], dtype=float)

M2N = np.array([
    [0, 1, 0, 1, 0, 0, 1],
    [1, 0, 0, 1, 1, 0, 0],
    [0, 0, 1, 0, 1, 1, 0]
], dtype=float)

# Create predicted winner labels for DN
winner1_predicted_N = np.array([[1, 0, 1, 0, 1, 1, 0]], dtype=float).T
winner2_predicted_N = np.array([[0, 1, 0, 1, 0, 0, 1]], dtype=float).T

# Construct Dn dictionary
Dn = {
    'model_a_matrix': M1n,
    'model_b_matrix': M2n,
    'winner1_human': winner1_human,
    'winner2_human': winner2_human,
    'winner1_predicted': winner1_predicted_n,
    'winner2_predicted': winner2_predicted_n
}

# Construct DN dictionary
DN = {
    'model_a_matrix': M1N,
    'model_b_matrix': M2N,
    'winner1_predicted': winner1_predicted_N,
    'winner2_predicted': winner2_predicted_N
}

# lhat parameter (weight between 0 and 1)
lhat = 0.8

ARGS = {
    'k': k,
    'Dn': Dn,
    'DN': DN,
    'lhat': lhat
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1
Imports
numpy — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type tuple — a tuple output has no array shape of its own; none is stated
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
find_ranksets Ran
ran; our contract draft was wrong, not the code
Networks-Learning/prediction-powered-ranking/src/ranksets.py
code served (permissive licence) · get_code("261a0d1a62eaba83")
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, through the batch API) and returned list, 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 numpy as np
import scipy.stats as stats

np.random.seed(0)

# Define parameters for find_ranksets
k = 4  # number of models

# Create a thetahat vector - win probabilities for each model
# Values should be between 0 and 1, representing win probabilities
thetahat = np.array([0.2, 0.5, 0.7, 0.3])

# Create a sample covariance matrix
# Must be k x k, symmetric, and positive semi-definite
base_cov = np.random.randn(k, k)
Sigma = base_cov @ base_cov.T + np.eye(k) * 0.1  # Make it positive semi-definite

# Alpha value - error rate between 0 and 1
alpha = 0.05

ARGS = {
    "k": k,
    "thetahat": thetahat,
    "Sigma": Sigma,
    "alpha": alpha,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, scipy — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type list, ndim 2, dtype family int — a list 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
generate_data Ran
ran; our contract draft was wrong, not the code
Networks-Learning/prediction-powered-ranking/src/synthetic.py
code served (permissive licence) · get_code("89a90895358d82f5")
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, through the batch API) and returned list, ndim 1, dtype family float; 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 numpy as np

# Analyze the function:
# - k: integer, used to determine matrix dimensions and loop ranges
# - n: integer, used for array shapes and loop ranges
# - theta: array-like, indexed with m1 (model index), len used implicitly
# - thetatilde: list of array-likes, each indexed with m1, len(thetatilde) determines number of LLM models

# Set up small but distinct dimensions
k = 3  # number of models
n = 12  # number of samples (will be rounded to multiple of k)

# theta: shape (k,) - probability parameters for human model for each of k models
theta = np.array([0.3, 0.4, 0.5])

# thetatilde: list of arrays, each of shape (k,) - probability parameters for each LLM
thetatilde = [
    np.array([0.25, 0.35, 0.45]),
    np.array([0.2, 0.3, 0.4]),
]

ARGS = {
    "k": k,
    "n": n,
    "theta": theta,
    "thetatilde": thetatilde,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type list, ndim 1, dtype family float — a list 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
get_common_instances Ran
ran; our contract draft was wrong, not the code
Networks-Learning/prediction-powered-ranking/src/data_process.py
code served (permissive licence) · get_code("1e46229d93713b67")
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, through the batch API) and returned tuple, ndim 2, dtype family float; 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 random

def get_common_instances(seed, human_data, llm_data, models):
    random.seed(seed)
    human_instances = dict()
    llm_instances = dict()
    for i in range(len(human_data)):
        sample = human_data[i]
        if sample['model_a'] not in models or sample['model_b'] not in models:
            continue
        t = (sample['question_id'], sample['model_a'], sample['model_b'])
        if t not in human_instances:
            human_instances[t] = [i]
        else:
            human_instances[t].append(i)
    for i in range(len(llm_data)):
        sample = llm_data[i]
        if sample['model_a'] not in models or sample['model_b'] not in models:
            continue
        t = (sample['question_id'], sample['model_a'], sample['model_b'])
        if t not in llm_instances:
            llm_instances[t] = [i]
        else:
            llm_instances[t].append(i)
    common_data_human = []
    common_data_llm = []
    for t in human_instances:
        if t in llm_instances:
            subsamples = min(len(human_instances[t]), len(llm_instances[t]))
            subsamples_human = random.sample(human_instances[t], subsamples)
            subsamples_llm = random.sample(llm_instances[t], subsamples)
            for i in subsamples_human:
                common_data_human.append(human_data[i])
            for i in subsamples_llm:
                common_data_llm.append(llm_data[i])
    return (common_data_human, common_data_llm)

# Setup code
seed = 42

models = ['gpt-4', 'claude-2', 'llama-7b']

human_data = [
    {
        'question_id': 101,
        'model_a': 'gpt-4',
        'model_b': 'claude-2',
        'text': 'human response 1'
    },
    {
        'question_id': 101,
        'model_a': 'gpt-4',
        'model_b': 'claude-2',
        'text': 'human response 2'
    },
    {
        'question_id': 102,
        'model_a': 'llama-7b',
        'model_b': 'gpt-4',
        'text': 'human response 3'
    },
    {
        'question_id': 103,
        'model_a': 'gpt-4',
        'model_b': 'invalid-model',
        'text': 'human response 4'
    }
]

llm_data = [
    {
        'question_id': 101,
        'model_a': 'gpt-4',
        'model_b': 'claude-2',
        'text': 'llm response 1'
    },
    {
        'question_id': 101,
        'model_a': 'gpt-4',
        'model_b': 'claude-2',
        'text': 'llm response 2'
    },
    {
        'question_id': 102,
        'model_a': 'llama-7b',
        'model_b': 'gpt-4',
        'text': 'llm response 3'
    },
    {
        'question_id': 104,
        'model_a': 'claude-2',
        'model_b': 'llama-7b',
        'text': 'llm response 4'
    }
]

ARGS = {
    'seed': seed,
    'human_data': human_data,
    'llm_data': llm_data,
    'models': models
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
none outside the standard library — 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 float — 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
input_json Ran
ran; our contract draft was wrong, not the code
Networks-Learning/prediction-powered-ranking/src/data_process.py
code served (permissive licence) · get_code("c29e47426e6fd79a")
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, through the batch API) and returned list, ndim 1, dtype family float; 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 json
import tempfile
import os

# Create a temporary JSON file with sample pairwise comparison data
temp_dir = tempfile.mkdtemp()
temp_file = os.path.join(temp_dir, "test_data.jsonl")

# Write sample data to the temporary file
sample_data = [
    {"question_id": "q1", "model_a": "gpt-4", "model_b": "claude-2", "winner": "model_a"},
    {"question_id": "q2", "model_a": "gpt-4", "model_b": "claude-2", "winner": "model_b"},
    {"question_id": "q3", "model_a": "gpt-4", "model_b": "claude-2", "winner": "tie"},
    {"question_id": "q4", "model_a": "gpt-4", "model_b": "claude-2", "winner": "model_a"},
]

with open(temp_file, 'w') as f:
    for data_point in sample_data:
        f.write(json.dumps(data_point) + "\n")

ARGS = {
    "path": temp_file,
    "ignore_ties": False,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
none outside the standard library — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type list, ndim 1, dtype family float — a list 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
model_list Ran
ran; our contract draft was wrong, not the code
Networks-Learning/prediction-powered-ranking/src/data_process.py
code served (permissive licence) · get_code("77d4e94ee72e5889")
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, through the batch API) and returned list, ndim 1, dtype family float; 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

torch.manual_seed(0)

data = [
    {
        'model_a': 'gpt-4',
        'model_b': 'claude-2'
    },
    {
        'model_a': 'gpt-3.5',
        'model_b': 'claude-2'
    },
    {
        'model_a': 'gpt-4',
        'model_b': 'llama-7b'
    }
]

ARGS = {
    'data': data
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type list, ndim 1, dtype family float — a list 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
lhat_opt Not yet run
unverified (harvested, no recorded run)
Networks-Learning/prediction-powered-ranking/src/estimate.py
code served (permissive licence) · get_code("a8295d36104f1f85")
How it ran

no invocation recorded.

sample_avg Not yet run
unverified (harvested, no recorded run)
Networks-Learning/prediction-powered-ranking/src/estimate.py
code served (permissive licence) · get_code("db81315466a224b1")
How it ran

no invocation recorded.

Also present in other papers' code

Of 8 samples lifted from this paper's linked repositories, 8 carry a function identity and 0 do not. Of the 8 distinct functions with an identity, 0 are also present in other papers whose code we hold (0 with at least one paper dated earlier, 0 the same month, 0 later) and 8 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.

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

Large language models are often ranked according to their level of alignment with human preferences-a model is better than other models if its outputs are more frequently preferred by humans. One of the popular ways to elicit human preferences utilizes pairwise comparisons between the outputs provided by different models to the same inputs. However, since gathering pairwise comparisons by humans is costly and time-consuming, it has become a common practice to gather pairwise comparisons by a strong large language model-a model strongly aligned with human preferences. Surprisingly, practitioners cannot currently measure the uncertainty that any mismatch between human and model preferences may introduce in the constructed rankings. In this work, we develop a statistical framework to bridge this gap. Given a (small) set of pairwise comparisons by humans and a large set of pairwise comparisons by a model, our framework provides a rank-set-a set of possible ranking positions-for each of the models under comparison. Moreover, it guarantees that, with a probability greater than or equal to a user-specified value, the rank-sets cover the true ranking consistent with the distribution of human pairwise preferences asymptotically. Using pairwise comparisons made by humans in the LMSYS Chatbot Arena platform and pairwise comparisons made by three strong large language models, we empirically demonstrate the effectivity of our framework and show that the rank-sets constructed using only pairwise comparisons by the strong large language models are often inconsistent with (the distribution of) human pairwise preferences.

For agents

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

get_harvested_code_for_paper("2402.17826")
get_code_for_paper("2402.17826")
have("2402.17826")

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

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

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

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

Connect an agent — have() is free.