Qwen Test JSONL Schema and Usage
Date: June 28, 2026
Purpose
Summarize the JSONL format to be referenced when creating Godot code chunks with Qwen, attaching correct‑answer JSONL and incorrect‑answer JSONL to those code chunks, and performing “yes”/“no” verification. This document is not a sample‑data provision; it is a schema reference document for confirming which JSONL serves which role during testing and which fields are used for direct‑evidence judgments.
Common Rules
JSONL writes one JSON object per line.
{...}
{...}
{...}In the test, the wrapper surrounding the table name is omitted, and the fields corresponding to the target table's columns are placed at the top level.
Good:
{"chunk_id":"...","content":"...","code_blocks":[...]}
Avoid:
{"table":"docs_chunks","payload":{"chunk_id":"..."}}Fields that are automatically generated by the DB or written to the search index do not need to be filled in directly in the test JSONL.
| DB operation field | Test JSONL criteria |
|---|---|
id |
Exclude |
embedding |
Exclude or null |
search_tsv |
Exclude |
created_at |
Exclude |
Qwen direct evidence verification emphasizes “which field in the JSONL directly matches the actual string/API/pattern of the SOURCE_CODE.”
docs_chunks
Purpose
docs_chunks is a JSONL that stores official documentation explanations, tutorials, and class reference bodies in chunk units.
It is used for requesting code explanations, checking common API usage, and verifying explanations of common Godot 3/4 syntax. It serves as evidence to determine “whether this code is directly related to any official documentation explanation,” rather than the migration rules themselves.
JSONL Format
{
"chunk_id": "text, required",
"doc_version": "text, required",
"source_url": "text, required",
"source_file": "text, required",
"source_sha256": "text, required",
"doc_type": "text, required",
"symbol": "text or null",
"section_path": "array, required",
"heading": "text or null",
"content": "text, required",
"code_blocks": "array, required",
"language_tags": "array<string>",
"godot_version_tags": "array<string>",
"api_symbols": "array<string>",
"token_count": "integer or null",
"metadata": "object"
}Direct Evidence Fields
| Field | Direct Evidence Criteria |
|---|---|
content |
Must describe the API, function name, node name, or code pattern found in SOURCE_CODE |
code_blocks |
Must contain the same code string or call pattern as in SOURCE_CODE |
api_symbols |
Must directly match the API/symbols present in SOURCE_CODE |
heading |
Supplemental evidence. Weak if only the heading matches without supporting text/code |
godot_version_tags |
For version reference only. Should not be used alone to decide “yes” |
Role in Tests
| Case | Expectation |
|---|---|
SOURCE_CODE uses get_viewport_rect().size and the same expression appears in content or code_blocks |
Yes |
| Only a broad topic is shared with SOURCE_CODE, but no actual string/API is present | No |
| Describes common syntax for Godot 3/4 and the code string matches exactly | Yes |
| Only version tags match and there is no code evidence | No |
api_mapping
Purpose
api_mapping is a JSONL that records how names, class names, function names, and symbol names changed from Godot 3 to Godot 4.
It is used for simple name changes, renames, replacements, and deprecated/removed API determinations. Cases where the entire usage of a function changes are more appropriate for the label_prototypes side.
JSONL Format
{
"mapping_id": "text, required",
"source_api": "text, required",
"target_api": "text or null",
"change_type": "text, required",
"godot_from": "text, required",
"godot_to": "text, required",
"confidence": "text, required",
"evidence_chunk_ids": "array<string>",
"match_terms": "array<string>",
"notes": "text",
"negative_patterns": "array<string>"
}Direct Evidence Fields
| Field | Direct Evidence Criteria |
|---|---|
source_api |
Must actually appear in the SOURCE_CODE |
target_api |
Used to verify the transformed code or migration description |
match_terms |
Must directly match the actual string/API in the SOURCE_CODE |
notes |
Supplemental explanation. Viewed together with source_api/match_terms rather than as standalone evidence |
negative_patterns |
If the SOURCE_CODE matches this pattern, it actually serves as a no evidence |
Role in Tests
| Case | Expectation |
|---|---|
KinematicBody2D is present in the SOURCE_CODE and the JSONL source_api is also KinematicBody2D |
Yes |
yield( is present in the SOURCE_CODE and the JSONL match_terms contains yield( |
Yes |
The JSONL is Camera -> Camera3D but the SOURCE_CODE is KinematicBody2D |
No |
| Only broad terms like Godot 3/4, migration overlap | No |
label_prototypes
Purpose
label_prototypes is a JSONL that stores examples where not only the name changes but the entire usage pattern of a function—including argument composition and call pattern—changes.
If api_mapping answers “what name changed to what,” then label_prototypes is closer to “what pattern the code should be written in.”
{
"prototype_id": "text, required",
"label": "text, required",
"task_type": "text, required",
"input_pattern": "text, required",
"expected_finding": "text, required",
"recommended_action": "text, required",
"evidence_mapping_ids": "array<string>",
"evidence_chunk_ids": "array<string>",
"severity": "text",
"validator_rules": "object"
}validator_rules can have the following subfields.
{
"required_when_seen_in_code": "array<string>",
"before_code": "text",
"after_code": "text",
"reject_when_seen_in_code": "array<string>"
}Direct Evidence Based Fields
| Field | Direct Evidence Criteria |
|---|---|
input_pattern |
Must directly match the call pattern in SOURCE_CODE |
expected_finding |
Description of what problem/pattern should be found |
recommended_action |
Direction for transformation or explanation |
validator_rules.required_when_seen_in_code |
Becomes a yes evidence only if it actually exists in SOURCE_CODE |
validator_rules.before_code |
Strong yes evidence if it is the same preceding code pattern as in SOURCE_CODE |
validator_rules.reject_when_seen_in_code |
If SOURCE_CODE contains this pattern, the prototype is no |
Role in Tests
| Case | Expectation |
|---|---|
SOURCE_CODE contains yield(get_tree().create_timer(...), "timeout") and before_code is the same pattern |
yes |
SOURCE_CODE contains move_and_slide(velocity) and the prototype explains a change in that call style |
yes |
SOURCE_CODE is yield but the prototype is a Color8 conversion |
no |
| Only shares the same label as SOURCE_CODE but has no actual pattern | no |
Boundaries of the Three JSONLs
| JSONL | Core Question | What It Mainly Should Match |
|---|---|---|
docs_chunks |
Is this code directly related to any official documentation explanation/tutorial? | content, code_blocks, api_symbols |
api_mapping |
Have the APIs/symbols in this code changed name or target from Godot 3 → 4? | source_api, target_api, match_terms |
label_prototypes |
Does this code’s usage/arguments/call pattern belong to an example where everything changes? | input_pattern, validator_rules, before_code |
Common Syntax Handling
If the syntax is the same in Godot 3 and Godot 4, it is not considered a version difference.
| Situation | JSONL to Use | Judgment Criteria |
|---|---|---|
Code commonly used like _ready(), _process(delta), print() |
One JSONL for that code/function + one JSONL for a completely different function | yes if there is direct evidence based on the same code chunk; no if it’s a completely different function |
| Unrelated migration JSONL attached to common‑syntax code | api_mapping or label_prototypes incorrect |
no if there is no actual API/pattern |
| Godot 3‑specific API appears | Godot 3‑only JSONL + Godot 4‑only JSONL | yes for the JSONL that directly matches the Godot 3 string/pattern in SOURCE_CODE |
| Godot 4‑specific API appears | Godot 4‑only JSONL + Godot 3‑only JSONL | yes for the JSONL that directly matches the Godot 4 string/pattern in SOURCE_CODE |