Datasets:
Cross-view consistency issues in the published columns (with reproduction and a repair patch)
Hello, and thank you for publishing this dataset and — importantly — for documenting the
pipeline that produced it. The data card states which tools were used and in what order, and
that is what made the analysis below possible at all.
We are software-engineering researchers auditing multi-view code corpora: datasets that ship
raw source alongside derived views of the same function. We built a checker that recomputes
each derived view from the raw view and compares. We ran it on several public corpora, this one
among them, and we found issues here that we think you would want to know about before others
build on the data. We are writing before publishing anything, and we would genuinely like your
reading of them — some of these may be intentional in ways the card does not spell out.
Everything below is reproducible from the published parquet with a few lines of standard
library code. Revision audited: 6b2513f5, all 1,676,250 rows.
1. function_body appears to have lost its line structure
No row in the dataset contains a newline character in function_body, and no row contains a
run of two spaces. Lines appear to have been stripped and concatenated without a separator, sodef sometimes fuses with the following identifier and one function's trailing return fuses
with the next function's def.
As a consequence 1,308,390 rows (78.05%) do not parse as Python. This is not an artefact of us
parsing fragments: 99.99% of the affected rows begin with def, async def or a decorator, and
a normalisation ladder (dedent, statement-list wrapping, newline repair) recovers only 4,347 of
them. Two further parsers — tree-sitter and parso — agree with CPython on 94.12% of the
rejections.
import ast, pandas as pd
df = pd.read_parquet("PyFuncAST-Lex.parquet")
print((df.function_body.str.contains("\n")).sum()) # 0
bad = 0
for b in df.function_body:
try: ast.parse(b)
except SyntaxError: bad += 1
print(bad, bad / len(df)) # ~1.31M, ~0.78
The card's own toolchain gives an independent signal here: it names lizard for the complexity
and size metrics, and lizard locates no function at all in the published function_body for
every row in our 18,392-row calibration sample, because its parser is line-oriented. The metrics
could be computed from the source at extraction time but cannot be recomputed from what was
published, which suggests the loss happened after extraction — possibly at the natural-language
rendering or the merge step, though we cannot tell which.
2. function_num_functions appears to hold the outgoing call count
On the 227,633 rows where both views are present, function_num_functions equalsoutgoing_function_count in 100.00% of rows. Against the AST count of nested definitions —
the card's documented meaning, "Number of functions declared inside" — it agrees on 29.70%.
A consumer querying for functions that declare a nested function currently gets 160,028 rows,
of which none actually do.
3. Some columns hold values from a different language's schema
class_modifiersis populated in 100% of rows, with three values:public(99.30%),protected,private. Python has no access modifiers.class_implementsandclass_extendsare documented as "Interfaces implemented" and "Class
inheritance" but contain only0and1.class_nameholds the stringpublicin 55.26% of rows.function_return_typeholdsReturns— a docstring section heading — in 21.10%.
These propagate into lexical_representation, which for many rows reads "defined within the
public class called public".
4. Two views go missing together
function_body_line_type and outgoing_function_names are either both present or both None.
We found no row where exactly one is missing, which looks like a merge that dropped one source's
columns wholesale rather than per-field damage.
5. num_token
The published value matches a standard Python tokenization minus one on 73.48% of parseable
rows. If that is the intended definition, documenting the convention would help consumers.
For context
We ran the same checks on three other public corpora. Raw-view parse failure was 0.84% and
0.86% in two CodeSearchNet packagings and 0% in BigCodeBench, so the pattern here is not what
derived code datasets normally look like — which is why we thought it worth writing to you
directly rather than only noting it in a paper.
What we can offer
- A repair patch. For the 21.95% of rows whose
function_bodystill parses, every derived
field can be recomputed deterministically. We have a manifest of row IDs and recomputed
values, and we are happy to hand it over. It contains no source code, only recomputed derived
values, so it applies on top of your copy. - The checker, so you can re-run it after any fix.
- The remaining 78% is not recoverable from the published data. Re-extracting from the upstream
repositories with the line structure preserved is the only route we can see.
Questions we would rather ask than assume
- Is the single-line form of
function_bodyintended, or a serialization side effect? The card
describes it as "Raw function body code", which is why we read it as unintended. - Is
function_num_functionsmeant to be the call count, with the card's description being the
thing to correct? Either reading is fine — we would just like to publish the right one. - Do
class_implements/class_extendsmean "has interfaces / has a base class" as booleans? - Does anything explain the co-missingness in item 4 — a merge key, a partial source?
About the paper
We are preparing a submission for IEEE BigData 2026 (deadline 21 August 2026) on executable
cross-view contracts for multi-view code corpora. This dataset is one of four we audit and the
one where the checker finds the most. The paper is about the method and the class of defect, not
about you; we cite the dataset properly and we describe these as pipeline defects throughout.
We would rather publish with your response included than without it. If you tell us any of the
above is intentional or mistaken, we will correct the paper accordingly. If you would prefer
more time before we submit, please say so and we will discuss it.
Thank you again for releasing and documenting the data.