Dataset Viewer
Auto-converted to Parquet Duplicate
task
stringlengths
3
12
description
stringlengths
221
6.12k
variable_names
listlengths
9
102
variable_descriptions
listlengths
9
102
n_vars
int64
9
102
n_clauses
int64
17
130k
n_concept_vars
int64
4
21
βŒ€
ground_truth_dimacs
stringlengths
203
14.6M
oracle_source
stringlengths
1.21k
6.25k
license
stringclasses
1 value
bdd-oia-2
We want to formalize a decision task: choosing driving actions from a set of binary road-condition variables. Domain notes (background only, do NOT encode these as CNF clauses; the concept variables above are free inputs, not constrained against each other): - red_light and green_light are not physically both true a...
[ "green_light", "follow", "road_clear", "red_light", "traffic_sign", "car", "person", "rider", "other_obstacle", "move_forward", "stop_action" ]
[ "the traffic light ahead is green", "a lead vehicle is present and can be followed", "the road ahead is clear (no obstacles)", "the traffic light ahead is red", "a stop/yield sign is visible", "there is a car blocking the way", "there is a pedestrian crossing the street", "there is a rider blocking th...
11
17
9
p cnf 11 17 -10 1 2 3 0 -10 -4 0 -10 -5 0 -10 -6 0 -10 -7 0 -10 -8 0 -10 -9 0 10 -1 4 5 6 7 8 9 0 10 -2 4 5 6 7 8 9 0 10 -3 4 5 6 7 8 9 0 -11 4 5 6 7 8 9 0 11 -4 0 11 -5 0 11 -6 0 11 -7 0 11 -8 0 11 -9 0
""" BDD-OIA-2 (``bdd-oia-2``) oracle: move-forward/stop constraints. This is a **multi-label oracle**: it takes the 9 *concept* variables as input and returns 2 *action* output booleans (forward, stop). Simplified from the full BDD-OIA oracle (bdd-oia.py) by dropping the turn-left/turn-right concepts and actions entir...
cc-by-nc-sa-4.0
bdd-oia
We want to formalize a decision task: choosing driving actions from a set of binary road-condition variables. Domain notes (background only, do NOT encode these as CNF clauses; the concept variables above are free inputs, not constrained against each other): - red_light and green_light are not physically both true a...
[ "green_light", "follow", "road_clear", "red_light", "traffic_sign", "car", "person", "rider", "other_obstacle", "left_lane", "left_green_light", "left_follow", "no_left_lane", "left_obstacle", "left_solid_line", "right_lane", "right_green_light", "right_follow", "no_right_lane", ...
[ "the traffic light ahead is green", "a lead vehicle is present and can be followed", "the road ahead is clear (no obstacles)", "the traffic light ahead is red", "a stop/yield sign is visible", "there is a car blocking the way", "there is a pedestrian crossing the street", "there is a rider blocking th...
25
31
21
p cnf 25 31 -22 1 2 3 0 -22 -4 0 -22 -5 0 -22 -6 0 -22 -7 0 -22 -8 0 -22 -9 0 22 -1 4 5 6 7 8 9 0 22 -2 4 5 6 7 8 9 0 22 -3 4 5 6 7 8 9 0 -23 4 5 6 7 8 9 0 23 -4 0 23 -5 0 23 -6 0 23 -7 0 23 -8 0 23 -9 0 -24 10 11 12 0 -24 -13 0 -24 -14 0 -24 -15 0 24 -10 13 14 15 0 24 -11 13 14 15 0 24 -12 13 14 15 0 -25 16 17 18 0 -2...
""" BDD-OIA oracle for road-driving action constraints. This is a **multi-label oracle**: it takes the 21 *concept* variables as input and returns 4 *action* output booleans (forward, stop, left, right). The evaluator detects multi-label oracles via the presence of ``N_CONCEPT_VARS``. Variables --------- Concepts (v...
cc-by-nc-sa-4.0
cebab
We want to formalize an overall-sentiment aggregation rule for restaurant reviews. Logical constraints: - Exactly one output label must be true. - The label is positive if and only if positive sentiment is the most common sentiment across the five sentiments, including cases where it ties with neutral or unknown, but ...
[ "food_aspect_majority_positive", "food_aspect_majority_negative", "food_aspect_majority_neutral", "food_aspect_majority_unknown", "service_aspect_majority_positive", "service_aspect_majority_negative", "service_aspect_majority_neutral", "service_aspect_majority_unknown", "noise_aspect_majority_posit...
[ "positive sentiment toward the food", "negative sentiment toward the food", "neutral sentiment toward the food", "unknown sentiment toward the food", "positive sentiment toward the service", "negative sentiment toward the service", "neutral sentiment toward the service", "unknown sentiment toward the ...
25
1,070
20
p cnf 25 1070 1 2 3 4 0 -1 -2 0 -1 -3 0 -1 -4 0 -2 -3 0 -2 -4 0 -3 -4 0 5 6 7 8 0 -5 -6 0 -5 -7 0 -5 -8 0 -6 -7 0 -6 -8 0 -7 -8 0 9 10 11 12 0 -9 -10 0 -9 -11 0 -9 -12 0 -10 -11 0 -10 -12 0 -11 -12 0 13 14 15 16 0 -13 -14 0 -13 -15 0 -13 -16 0 -14 -15 0 -14 -16 0 -15 -16 0 17 18 19 20 0 -17 -18 0 -17 -19 0 -17 -20 0 -1...
""" CEBaB oracle: derive an overall review-sentiment label from 5 categorical aspect-majority concepts (4 of them are the original CEBaB aspects; the 5th, review_majority, was added on top so the concept-to-label mapping below is deterministic). Multi-label interface: variables 1-20 are INPUTS (5 concepts, one-hot 4-v...
cc-by-nc-sa-4.0
chx
We want to formalize a clinical severity-scoring rule for chest X-ray findings. Logical constraints: The severity code is determined by the number of findings that are present: - no findings correspond to healthy - one finding to green_code - two findings to yellow_code - three findings to orange_code - four findings ...
[ "fracture", "pneumothorax", "airspace_opacity", "nodule_mass", "healthy", "green_code", "yellow_code", "orange_code", "red_code" ]
[ "a bone fracture is visible", "a pneumothorax (collapsed lung) is visible", "airspace opacity (e.g. consolidation or infiltrate) is visible", "a nodule or mass is visible", "no findings are present", "green emergency code", "yellow emergency code", "orange emergency code", "red emergency code" ]
9
27
4
p cnf 9 27 5 6 7 8 9 0 -5 -6 0 -5 -7 0 -5 -8 0 -5 -9 0 -6 -7 0 -6 -8 0 -6 -9 0 -7 -8 0 -7 -9 0 -8 -9 0 1 2 3 4 5 0 1 2 3 -4 6 0 1 2 -3 4 6 0 1 2 -3 -4 7 0 1 -2 3 4 6 0 1 -2 3 -4 7 0 1 -2 -3 4 7 0 1 -2 -3 -4 8 0 -1 2 3 4 6 0 -1 2 3 -4 7 0 -1 2 -3 4 7 0 -1 2 -3 -4 8 0 -1 -2 3 4 7 0 -1 -2 3 -4 8 0 -1 -2 -3 4 8 0 -1 -2 -3 ...
""" ChestXRays (CHX) oracle: derive a 5-way severity code from 4 binary radiological findings. Multi-label interface: variables 1-4 are INPUTS (concept vars, one per finding), variables 5-9 are OUTPUTS derived by the oracle (severity code, one-hot). N_CONCEPT_VARS separates them. Variable layout: Variables 1-4 (con...
cc-by-nc-sa-4.0
cifar10
We want to formalize a object classification task. Logical constraints: - The object is an airplane if it has wings and is metallic, but has no wheels and is not an animal, hairy, horned, or snouted. - The object is either a car or truck if it has wheels and is metallic, but has no wings and is not an animal, hairy, h...
[ "whl", "met", "wng", "ani", "hai", "hrn", "snt", "label_airplane", "label_car_or_truck", "label_bird", "label_frog", "label_deer", "label_cat", "label_dog_or_horse", "label_ship" ]
[ "the object has wheels", "the object is metallic", "the object has wings", "the object is an animal", "the object is hairy", "the object has horns", "the object has a snout", "the object is an airplane", "the object is either a car or a truck", "the object is a bird", "the object is a frog", "...
15
157
null
p cnf 15 157 8 9 10 11 12 13 14 15 0 -8 -9 0 -8 -10 0 -8 -11 0 -8 -12 0 -8 -13 0 -8 -14 0 -8 -15 0 -9 -10 0 -9 -11 0 -9 -12 0 -9 -13 0 -9 -14 0 -9 -15 0 -10 -11 0 -10 -12 0 -10 -13 0 -10 -14 0 -10 -15 0 -11 -12 0 -11 -13 0 -11 -14 0 -11 -15 0 -12 -13 0 -12 -14 0 -12 -15 0 -13 -14 0 -13 -15 0 -14 -15 0 1 2 3 4 5 6 7 0 1...
""" CIFAR-10 concept-bottleneck oracle: assign one of 8 image-class labels from 7 binary visual concepts (designed concepts, deterministically derived from the ground-truth class β€” not learned/annotated independently). Whole-assignment-validity interface (no N_CONCEPT_VARS): the oracle checks the full 15-variable assi...
cc-by-nc-sa-4.0
cifar100
We want to formalize a constraint on a general object classification task: every image belongs to exactly one of the classes. Logical constraints: - The object belongs to exactly one class. - No two classes can be assigned to the same object.
[ "class_0", "class_1", "class_2", "class_3", "class_4", "class_5", "class_6", "class_7", "class_8", "class_9", "class_10", "class_11", "class_12", "class_13", "class_14", "class_15", "class_16", "class_17", "class_18", "class_19", "class_20", "class_21", "class_22", "cla...
[ "the image belongs to class 0", "the image belongs to class 1", "the image belongs to class 2", "the image belongs to class 3", "the image belongs to class 4", "the image belongs to class 5", "the image belongs to class 6", "the image belongs to class 7", "the image belongs to class 8", "the image...
100
4,951
null
p cnf 100 4951 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 0 -1 -2 0 -1 ...
""" CIFAR-100 (``cifar100``) oracle (100 vars): exactly-one mutual-exclusion constraint over 100 class indicators - the semi-supervised classification constraint from Section 4 (MNIST / Fashion-MNIST / CIFAR-10 / CIFAR-100 all share it), generalized from the paper's illustrative n=3 example ((x1 v x2 v x3) & (not x1 v ...
cc-by-nc-sa-4.0
cle4evr
We want to formalize a co-occurrence matching task between two objects in a scene. Logical constraints: - Both objects must have the same shape and the same color. - Each object must have exactly one shape and one color.
[ "obj1_shape_cube", "obj1_shape_sphere", "obj1_shape_cylinder", "obj1_color_red", "obj1_color_blue", "obj1_color_green", "obj2_shape_cube", "obj2_shape_sphere", "obj2_shape_cylinder", "obj2_color_red", "obj2_color_blue", "obj2_color_green" ]
[ "the first object is a cube", "the first object is a sphere", "the first object is a cylinder", "the first object is red", "the first object is blue", "the first object is green", "the second object is a cube", "the second object is a sphere", "the second object is a cylinder", "the second object ...
12
28
null
p cnf 12 28 1 2 3 0 -1 -2 0 -1 -3 0 -2 -3 0 4 5 6 0 -4 -5 0 -4 -6 0 -5 -6 0 7 8 9 0 -7 -8 0 -7 -9 0 -8 -9 0 10 11 12 0 -10 -11 0 -10 -12 0 -11 -12 0 -1 7 0 1 -7 0 -2 8 0 2 -8 0 -3 9 0 3 -9 0 -4 10 0 4 -10 0 -5 11 0 5 -11 0 -6 12 0 6 -12 0
""" CLE4EVR oracle β€” two objects share the same shape AND color. Variable layout (one-hot encoding): Object 1: vars 1-3 shape (cube, sphere, cylinder) vars 4-6 color (red, blue, green) Object 2: vars 7-9 shape vars 10-12 color The constraint is satisfied iff: - Each one-hot group is valid (ex...
cc-by-nc-sa-4.0
fashion
We want to formalize a constraint on a dress classification task: every clothing image belongs to exactly one of the classes. Logical constraints: - The item must belong to exactly one class. - No two classes can be assigned to the same item.
[ "class_0_tshirt_top", "class_1_trouser", "class_2_pullover", "class_3_dress", "class_4_coat", "class_5_sandal", "class_6_shirt", "class_7_sneaker", "class_8_bag", "class_9_ankle_boot" ]
[ "the clothing item is a t-shirt", "the clothing item is a pair of trousers", "the clothing item is a pullover", "the clothing item is a dress", "the clothing item is a coat", "the footwear is a sandal", "the clothing item is a shirt", "the footwear is a sneaker", "the item is a bag", "the footwear...
10
46
null
p cnf 10 46 1 2 3 4 5 6 7 8 9 10 0 -1 -2 0 -1 -3 0 -1 -4 0 -1 -5 0 -1 -6 0 -1 -7 0 -1 -8 0 -1 -9 0 -1 -10 0 -2 -3 0 -2 -4 0 -2 -5 0 -2 -6 0 -2 -7 0 -2 -8 0 -2 -9 0 -2 -10 0 -3 -4 0 -3 -5 0 -3 -6 0 -3 -7 0 -3 -8 0 -3 -9 0 -3 -10 0 -4 -5 0 -4 -6 0 -4 -7 0 -4 -8 0 -4 -9 0 -4 -10 0 -5 -6 0 -5 -7 0 -5 -8 0 -5 -9 0 -5 -10 0 ...
""" Fashion-Mut-Ex oracle (10 vars): exactly-one mutual-exclusion constraint over the 10 Fashion-MNIST class indicators - the semi-supervised classification constraint from Section 4 (MNIST / Fashion-MNIST / CIFAR-10 all share it), generalized from the paper's illustrative n=3 example ((x1 v x2 v x3) & (not x1 v not x2...
cc-by-nc-sa-4.0
kand-logic-2
"We want to formalize a pattern-recognition task: whether two images share a common shape/color patt(...TRUNCATED)
["im1_p1_shape_square","im1_p1_shape_triangle","im1_p1_shape_circle","im1_p1_color_red","im1_p1_colo(...TRUNCATED)
["primitive 1 in image 1 is a square","primitive 1 in image 1 is a triangle","primitive 1 in image 1(...TRUNCATED)
24
1,328
null
"p cnf 24 1328\n1 2 3 0\n-1 -2 0\n-1 -3 0\n-2 -3 0\n4 5 6 0\n-4 -5 0\n-4 -6 0\n-5 -6 0\n7 8 9 0\n-7 (...TRUNCATED)
"\"\"\"\nKand-Logic-Simple oracle β€” reduced pattern over two images (2 primitives\neach instead of(...TRUNCATED)
cc-by-nc-sa-4.0
kand-logic
"We want to formalize a pattern-recognition task: whether two images share a common shape/color patt(...TRUNCATED)
["im1_p1_shape_square","im1_p1_shape_triangle","im1_p1_shape_circle","im1_p1_color_red","im1_p1_colo(...TRUNCATED)
["primitive 1 in image 1 is a square","primitive 1 in image 1 is a triangle","primitive 1 in image 1(...TRUNCATED)
36
129,648
null
"p cnf 36 129648\n1 2 3 0\n-1 -2 0\n-1 -3 0\n-2 -3 0\n4 5 6 0\n-4 -5 0\n-4 -6 0\n-5 -6 0\n7 8 9 0\n-(...TRUNCATED)
"\"\"\"\nKand-Logic oracle β€” full pattern over two images.\n\nEach image contains 3 primitives; ea(...TRUNCATED)
cc-by-nc-sa-4.0
End of preview. Expand in Data Studio

auto-nesy-bench

auto-nesy-bench is a benchmark for auto-formalization in Neuro-Symbolic (NeSy) AI. Given a natural-language description of the domain knowledge of a NeSy task and the list of its Boolean variables, a model has to write the constraint in conjunctive normal form (CNF). The output is compared with an expert-written ground truth by model counting.

Usage

from datasets import load_dataset

detailed = load_dataset("unitn-sml/auto-nesy-bench", "detailed", split="test")
non_detailed = load_dataset("unitn-sml/auto-nesy-bench", "non_detailed", split="test")

task = detailed[0]
print(task["description"])
print(task["variable_names"])
print(task["ground_truth_dimacs"])

Configurations

There are 18 tasks, each available in two configurations that differ only in how the constraint is described:

  • detailed (default): the constraint is spelled out step by step.
  • non_detailed: a shorter description that leaves more to the model.

Each configuration has a single test split with one row per task.

Fields

Field Type Description
task string Task identifier
description string Natural-language description of the constraint
variable_names list[string] Name of each variable; variable i in the DIMACS is variable_names[i-1]
variable_descriptions list[string] or null Short description of each variable
n_vars int Number of variables in the ground-truth CNF
n_clauses int Number of clauses in the ground-truth CNF
n_concept_vars int or null Number of input (concept) variables; the remaining ones are outputs
ground_truth_dimacs string Expert-written ground truth in DIMACS CNF
oracle_source string Python oracle that declares the variables and maps concepts to labels
license string Licence of the task's ground truth

Tasks

Task Variables Clauses
bdd-oia-2 11 17
bdd-oia 25 31
cebab 25 1,070
chx 9 27
cifar10 15 157
cifar100 100 4,951
cle4evr 12 28
fashion 10 46
kand-logic-2 24 1,328
kand-logic 36 129,648
mn-add-bin 13 512
mn-add 39 364
mn-mul-bin 15 712
mn-mul 102 3,514
road-r 41 243
sudoku 64 400
sushi 16 56
warcraft 24 289

The perception data of each task (images, videos, text, features) is not included here, because most of it cannot be redistributed. The code repository has a make target that downloads or generates each one.

Evaluation

A generated CNF is converted to DIMACS over the same variables and compared with ground_truth_dimacs by model counting, which gives precision, recall, F1 and accuracy over the space of assignments. The code repository provides the evaluation pipeline, the prompts for five output formats (DIMACS, natural-language CNF, PySAT, CPMpy, SymPy), and the NeSy experiments (Semantic Probabilistic Layer and Semantic Loss).

How the ground truth was built

The ground-truth CNFs are compiled with PySAT from the task definitions, except road-r, which uses the requirements released with ROAD-R. Each CNF is checked against its Python oracle, exhaustively for tasks with at most 20 variables.

Licence

The dataset is released under CC BY-NC-SA 4.0. The road-r ground truth comes from ROAD-R, which uses this licence. The code is BSD-3-Clause. When using a task, please also cite the dataset it is built on (see the code repository for the list).

Citation

@misc{bortolotti2026autoformalizing,
  title={Auto-Formalizing Neuro-Symbolic Predictors},
  author={Samuele Bortolotti and Weixin Chen and Han Zhao and Andrea Passerini and Stefano Teso and Antonio Vergari},
  year={2026},
  eprint={2610.01519},
  archivePrefix={arXiv},
  primaryClass={cs.LG},
  url={https://arxiv.org/abs/2610.01519},
}
Downloads last month
3

Paper for unitn-sml/auto-nesy-bench