task_puzzles__arithmetic_panel__vertical_arithmetic_hidden_digit_value¶
1) Identity¶
- Domain:
puzzles - Scene id:
arithmetic_panel - Task id:
task_puzzles__arithmetic_panel__vertical_arithmetic_hidden_digit_value - Objective contract:
vertical_arithmetic_hidden_digit_value - Supported
query_idvalues:hidden_addition_digit_value,hidden_subtraction_digit_value - Prompt query key:
hidden_addition_digit_value,hidden_subtraction_digit_value - Answer schema:
integer - Annotation schema:
bbox - Program schema:
solve_digit(vertical_arithmetic, operation=addition|subtraction, target=question_mark_digit); scene=arithmetic_panel; scope=vertical_arithmetic_hidden_digit_value
Program Contract¶
Program: solve_digit(vertical_arithmetic, operation=addition|subtraction, target=question_mark_digit); scene=arithmetic_panel; scope=vertical_arithmetic_hidden_digit_value
Candidate set: the visible arithmetic panels, numeric entries, operators, totals, and marked target cell/node/brick inside the vertical_arithmetic_hidden_digit_value objective scope.
Operands: visible scene state and prompt-bound operands named by vertical_arithmetic, operation, addition, subtraction, question_mark_digit, arithmetic_panel, vertical_arithmetic_hidden_digit_value plus the active query_id branch.
Operation: evaluate solve_digit over the candidate set using the visible states, constraints, transforms, comparisons, counts, paths, or option-selection rules encoded in the program expression; generation enforces a unique final answer.
Output binding: answer uses the integer schema; generation binds a unique final answer.
Annotation witnesses: annotation uses the bbox schema; the scalar bbox is the pixel box around the single visible question-mark target cell, node, or brick. It is not a one-item set.
Query ids: hidden_addition_digit_value, hidden_subtraction_digit_value.
Reasoning Operations¶
Families: formula_evaluation
2) Scene + task contract¶
- Entities/relations: A vertical arithmetic layout with one question-mark digit cell and a visible addition or subtraction operator.
- Supported
query_idvalues:hidden_addition_digit_value,hidden_subtraction_digit_value answer_gt.type:integer- Default
annotation_gt.type:bbox - Alternate annotation forms: none
- Annotation witness policy: the scalar bbox is the pixel box around the single visible question-mark target cell, node, or brick. It is not a one-item set.
- Overlap/touch policy: the target bbox must correspond to the rendered
targetitem and must not use the surrounding diagram panel bbox.
3) Prompt contract¶
prompt_bundle_id:puzzles_arithmetic_panel_v1scene_key:arithmetic_paneltask_key:arithmetic_value_query- Optional query-id prompt mapping:
hidden_addition_digit_value,hidden_subtraction_digit_value - Required slots:
- answer output:
answer_hint,json_example_answer_only - answer+annotation mode:
annotation_hint,answer_hint,json_example - JSON example validity rule: the example must use a scalar
[x0, y0, x1, y1]bbox and an integer answer valid for this task's output schema. - Variant counts: 5 scene templates, 5 query templates per prompt query key, and 5 output templates per output mode.
- Output modes:
answer_only,answer_and_annotation
4) Determinism + constraints¶
- Seed namespaces used: scene/unit-size/layout/font/panel-style namespaces under
puzzles.arithmetic_panelplus task-local arithmetic construction namespaces. - Unique-answer policy: The sampled equation is regenerated until the hidden digit matches the target answer and the displayed arithmetic is valid.
- Reject/resample conditions: invalid arithmetic construction, missing render bbox, or a target outside the configured support raises and retries within
max_attempts. - No-auto-relaxation guarantee: semantic constraints are not relaxed; generation retries rather than accepting ambiguous or unsupported targets.
5) Tests¶
- Determinism test:
tests/test_puzzles_arithmetic_panel_tasks.py::test_arithmetic_panel_task_is_deterministic - Answer/annotation consistency test:
tests/test_puzzles_arithmetic_panel_tasks.py::test_arithmetic_panel_scene_tasks_use_scalar_target_bbox_annotation - Prompt metadata/placeholder test: covered by source-layout checks and prompt-system tests.
- Constraint-specific tests:
tests/test_puzzles_arithmetic_panel_tasks.py::test_forced_arithmetic_panel_branches_are_valid