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.
Hello,
Thank you very much for reaching out and, particularly, for conducting such a thorough analysis of the dataset before publishing your findings. I genuinely appreciate both the level of detail in your report and your decision to contact me directly so that I have the opportunity to investigate and respond.
I had independently identified several issues in the originally published dataset and subsequently revised the data processing pipeline. A new version of the dataset has now been published on Zenodo:
The revised dataset addresses issues that I had identified during my own validation. However, given the findings you have reported, I would be very interested in running your checker against the revised dataset as an additional independent validation step. If you are willing to share the checker, I would greatly appreciate access to it. I would also be happy to share the results of running it on the revised version with you.
Regarding your specific questions:
1. Is the single-line form of function_body intended, or a serialization side effect?
It is not intended. The loss of line structure in function_body is a serialization/processing side effect. The intention was for this field to preserve the extracted raw function body, including its original line structure. Your interpretation of the data card is therefore correct.
2. Is function_num_functions meant to be the call count, with the card's description being the thing to correct?
Yes. function_num_functions is intended to represent the number of function calls occurring within the function. Therefore, the issue here is with the description/documentation of the field rather than the intended underlying concept. I will make this definition explicit in the revised documentation to avoid ambiguity.
3. Do class_implements / class_extends mean "has interfaces / has a base class" as booleans?
Yes. These fields were designed as binary indicators. class_implements indicates whether the class implements an interface, while class_extends indicates whether the class inherits from another class. I agree that their binary representation and Python-specific interpretation need to be documented more clearly.
Your observation regarding class_modifiers, class_name, and function_return_type is also important. These values appear to reflect problems in the lexical representation pipeline rather than meaningful Python semantics, and I am reviewing this part of the pipeline accordingly.
4. Does anything explain the co-missingness of function_body_line_type and outgoing_function_names?
I do not yet have a confirmed explanation for this observation. The fact that the two fields are consistently missing together is useful evidence, and I am reviewing the relevant extraction and merge stages to determine whether they originate from the same intermediate processing step or whether a merge operation caused the co-missingness. I would prefer not to attribute it to a specific cause until I have reproduced and traced the behavior.
Regarding num_token, thank you for identifying the apparent convention. I will also review how this value was generated and ensure that its exact definition is documented.
I would be very interested in receiving both the checker and, if possible, the repair manifest you mentioned. Even though the revised dataset has already been regenerated, comparing your independently recomputed fields against the revised pipeline would be extremely valuable for validation and for documenting any remaining discrepancies.
I also appreciate the way you are positioning the dataset in your IEEE BigData 2026 submission as an instance of a broader class of pipeline defects rather than treating it as an issue specific to this dataset or its authors. Please feel free to include my clarification that the single-line function_body representation was unintended, that function_num_functions is intended to represent function-call count, and that class_implements and class_extends were designed as binary indicators.
If possible, I would appreciate the opportunity to review the results of your checker on the revised Zenodo dataset before your final submission. I would be very happy to collaborate with you in validating the revised version and ensuring that the description of the dataset in your paper accurately reflects both the original issues and the subsequent corrections.
Thank you again for contacting me and for offering the checker and repair materials. I appreciate the constructive approach and believe this independent audit can help improve the reliability and documentation of the dataset.
Best regards,
Reem Alehaidib