Dataset Viewer
Auto-converted to Parquet Duplicate
language
stringclasses
6 values
search_id
stringclasses
99 values
function_id
stringlengths
7
15
relevance
float64
0
3
relevant
bool
2 classes
source
stringclasses
2 values
expert_ratings
listlengths
0
6
judge_rating
int64
0
3
rated_because
stringclasses
3 values
python
q00
python/0067
0
false
judge
[]
0
sample
python
q00
python/0094
0
false
judge
[]
0
sample
python
q00
python/0120
0
false
judge
[]
0
sample
python
q00
python/0151
3
true
judge
[]
3
pooled
python
q00
python/0247
0
false
judge
[]
0
sample
python
q00
python/0248
3
true
judge
[]
3
pooled
python
q00
python/0249
3
true
judge
[]
3
pooled
python
q00
python/0278
0
false
judge
[]
0
sample
python
q00
python/0354
3
true
expert
[ 3, 3 ]
3
expert
python
q00
python/0356
0
false
expert
[ 0 ]
0
expert
python
q00
python/0386
0
false
expert
[ 0, 0, 0 ]
1
expert
python
q00
python/0402
1
false
judge
[]
1
pooled
python
q00
python/0403
3
true
judge
[]
3
pooled
python
q00
python/0465
3
true
expert
[ 3, 3 ]
3
expert
python
q00
python/0470
2.5
true
expert
[ 3, 2 ]
3
expert
python
q00
python/0491
3
true
expert
[ 3, 3 ]
3
expert
python
q00
python/0499
3
true
judge
[]
3
pooled
python
q00
python/0513
1.5
false
expert
[ 0, 3 ]
1
expert
python
q00
python/0655
0
false
judge
[]
0
sample
python
q00
python/0657
3
true
judge
[]
3
pooled
python
q00
python/0658
2.5
true
expert
[ 2, 3 ]
3
expert
python
q00
python/0683
0
false
judge
[]
0
sample
python
q00
python/0693
2.75
true
expert
[ 3, 2, 3, 3 ]
3
expert
python
q00
python/0745
2.5
true
expert
[ 2, 2, 3, 3 ]
3
expert
python
q00
python/0826
0
false
judge
[]
0
sample
python
q00
python/0860
3
true
judge
[]
3
pooled
python
q00
python/0883
0
false
judge
[]
0
sample
python
q00
python/0885
0
false
judge
[]
0
sample
python
q00
python/0903
0
false
judge
[]
0
sample
python
q01
python/0015
3
true
expert
[ 3, 3 ]
3
expert
python
q01
python/0050
1
false
expert
[ 0, 2 ]
1
expert
python
q01
python/0071
1
false
expert
[ 2, 0 ]
0
expert
python
q01
python/0092
0
false
judge
[]
0
sample
python
q01
python/0130
0
false
judge
[]
0
sample
python
q01
python/0138
0
false
judge
[]
0
sample
python
q01
python/0157
0.5
false
expert
[ 1, 0 ]
1
expert
python
q01
python/0186
0
false
judge
[]
0
sample
python
q01
python/0195
0
false
judge
[]
0
sample
python
q01
python/0197
0
false
judge
[]
0
sample
python
q01
python/0210
0
false
judge
[]
0
sample
python
q01
python/0223
0
false
expert
[ 0, 0 ]
0
expert
python
q01
python/0284
0
false
judge
[]
0
sample
python
q01
python/0308
0
false
judge
[]
0
sample
python
q01
python/0325
0
false
judge
[]
0
sample
python
q01
python/0349
3
true
expert
[ 3, 3 ]
3
expert
python
q01
python/0363
0
false
judge
[]
0
sample
python
q01
python/0364
0
false
judge
[]
0
sample
python
q01
python/0391
0
false
judge
[]
0
sample
python
q01
python/0399
0
false
judge
[]
0
sample
python
q01
python/0410
1
false
judge
[]
1
pooled
python
q01
python/0427
0
false
judge
[]
0
sample
python
q01
python/0458
0
false
judge
[]
0
sample
python
q01
python/0468
0
false
judge
[]
0
sample
python
q01
python/0530
0
false
judge
[]
0
sample
python
q01
python/0549
0.5
false
expert
[ 1, 0 ]
0
expert
python
q01
python/0552
0.5
false
expert
[ 0, 1 ]
1
expert
python
q01
python/0573
0
false
judge
[]
0
sample
python
q01
python/0578
0
false
judge
[]
0
sample
python
q01
python/0632
0
false
judge
[]
0
sample
python
q01
python/0646
3
true
expert
[ 3, 3 ]
3
expert
python
q01
python/0671
0
false
judge
[]
0
sample
python
q01
python/0712
0
false
judge
[]
0
sample
python
q01
python/0751
0
false
judge
[]
0
sample
python
q01
python/0774
0
false
judge
[]
0
sample
python
q01
python/0822
0
false
judge
[]
0
sample
python
q01
python/0824
0
false
judge
[]
0
sample
python
q01
python/0840
0
false
judge
[]
0
sample
python
q01
python/0851
0.5
false
expert
[ 0, 1 ]
1
expert
python
q01
python/0870
0
false
judge
[]
0
sample
python
q01
python/0872
0
false
judge
[]
0
sample
python
q02
python/0071
0
false
judge
[]
0
sample
python
q02
python/0092
0
false
judge
[]
0
sample
python
q02
python/0118
3
true
expert
[ 3, 3 ]
3
expert
python
q02
python/0148
0
false
judge
[]
0
sample
python
q02
python/0154
1
false
expert
[ 1, 1 ]
1
expert
python
q02
python/0156
0
false
judge
[]
0
sample
python
q02
python/0180
1
false
judge
[]
1
sample
python
q02
python/0198
0
false
judge
[]
0
sample
python
q02
python/0202
0
false
judge
[]
0
sample
python
q02
python/0276
1
false
expert
[ 0, 2 ]
1
expert
python
q02
python/0277
2.6667
true
expert
[ 2, 3, 3, 3, 2, 3 ]
1
expert
python
q02
python/0296
0
false
judge
[]
0
sample
python
q02
python/0314
0.5
false
expert
[ 1, 0 ]
0
expert
python
q02
python/0315
0
false
judge
[]
0
sample
python
q02
python/0336
0
false
judge
[]
0
sample
python
q02
python/0339
0
false
expert
[ 0, 0 ]
0
expert
python
q02
python/0401
0
false
judge
[]
0
sample
python
q02
python/0423
0
false
judge
[]
0
sample
python
q02
python/0464
0
false
judge
[]
0
sample
python
q02
python/0481
1
false
judge
[]
1
sample
python
q02
python/0482
0
false
judge
[]
0
sample
python
q02
python/0545
3
true
expert
[ 3, 3 ]
3
expert
python
q02
python/0556
0
false
judge
[]
0
sample
python
q02
python/0677
0
false
judge
[]
0
sample
python
q02
python/0723
0
false
expert
[ 0, 0, 0 ]
0
expert
python
q02
python/0740
0
false
judge
[]
0
sample
python
q02
python/0741
1
false
expert
[ 1, 1 ]
0
expert
python
q02
python/0742
0
false
judge
[]
0
sample
python
q02
python/0862
0
false
judge
[]
0
sample
python
q02
python/0863
0
false
judge
[]
0
sample
End of preview. Expand in Data Studio

CodeSearchNet Challenge, extended: every search over every function

The CodeSearchNet Challenge (Husain et al., 2019) has 99 natural-language code searches, and experts rated a few candidate functions for each. This dataset treats every rated function of a language as one codebase and searches all of it: for each search, every function in its language is a candidate. The experts' ratings are kept, and the pairs they never rated but a search tool returned were rated on the same scale by a judge model, validated against the experts first. Random samples of the pairs only a loose any-keyword grep returned, and of the pairs nothing returned, were rated too.

Language Searches Functions Rated by experts Rated by the judge Relevant
Python 99 943 956 3,857 787
Java 99 758 769 3,561 512
JavaScript 96 304 305 3,004 247
PHP 99 288 289 2,976 232
Ruby 97 292 300 2,814 189
Go 83 161 162 2,133 79

It was made for the jevpipe code search benchmark, which describes the method, the judge's validation and the results in full.

Configurations

  • queries: language, search_id, search (the text), split (tuning for the 20 Python searches used to tune the benchmark's tools, test for all others).
  • corpus: one row per function: id, language, code (the rated lines at the rated commit), url, repository, commit, path, first_line, last_line, license (the repository's SPDX license id as GitHub reported it in September 2026, NOASSERTION or null) and sha256 of code.
  • qrels: one row per rated search-function pair: relevance (the experts' mean rating, else the judge's rating, 0 to 3), relevant (relevance of 2 or more), source (expert or judge), expert_ratings, judge_rating (also given for expert-rated pairs, to check the judge), and rated_because (expert, pooled: a search tool returned it, or sample: one of the random samples above).

How the judge rated

GPT-6 Astra through the Codex CLI, low reasoning effort, no tools, in batches of 40 pairs mixed across searches, seeing an opaque id, the search and the code (cut at 20,000 characters), never which tool returned the pair. The prompt gave the Challenge's 0-3 scale and its description of each level. Before any of its ratings were used, it rated every expert-rated pair of the language; the gate, set in advance, was an F1 of 0.67 on "relevant" against the experts:

Language Expert-rated pairs Same verdict as the experts F1 Gate
Python 956 76% 0.745 passed
Java 769 79% 0.719 passed
JavaScript 305 83% 0.781 passed
PHP 289 79% 0.760 passed
Ruby 300 83% 0.709 passed
Go 162 80% 0.629 missed

Where two experts rated the same pair (848 Python pairs), they agree on 70% of verdicts, F1 0.711. In Go the judge missed the gate on only 40 relevant expert pairs, and calls more pairs relevant (49) than its experts did (40); use its ratings there with that in mind.

Pooled pairs came from four searches: grep with a pattern a coding agent wrote per search, grep for all of the search's keywords, jevpipe with a probability of 0.3 or more, and DeepSeek V4.1 Flash answering yes or with a probability of 0.3 or more.

Use it with care

  • Unrated is unknown, not irrelevant. The judged pairs were found by the three tools above; a new tool will return relevant functions nobody rated. Treat pairs missing from qrels as unjudged, use a metric that allows for that, or rate the new pairs the same way.
  • Judge ratings are model output, checked against the experts but not expert ratings.
  • Relevance is from 2019 searches on public code that may be in any model's training data.

Licenses

The functions come from the CodeSearchNet corpus, which kept only projects whose license allows redistributing parts of them. Each function in corpus stays under its repository's license, named in license and traceable through url. NOASSERTION means the repository has a license file that GitHub cannot match to a standard license; read it in the repository. null means GitHub finds no license in the repository today; CodeSearchNet selected the project in 2019 because its license then permitted redistribution, and that license still covers the code at the rated commit that url points to. The Challenge's ratings are from its MIT-licensed repository. The searches' split, the judge ratings and the dataset's structure are released under the MIT license.

Citation

Husain, H., Wu, H.-H., Gazit, T., Allamanis, M., & Brockschmidt, M. (2019). CodeSearchNet Challenge: Evaluating the State of Semantic Code Search. arXiv:1909.09436.

Downloads last month
39

Paper for Scoolar/codesearchnet-challenge-extended