{ "id": "single-software-execution--cli--blender--task-20--ubuntu", "snapshot": "Blender-4.2.3", "instruction": "FK/IK Switch via Driver `/home/user/Desktop/scene.blend` contains an armature object `Rig` at the origin with 3 connected bones `Upper` -> `Lower` -> `Tip` along +Z (each 1 BU long), an empty `IKTarget` at (1, 0, 2.5), and a float custom property `ik_blend` in [0, 1] (default 0.0) on the Rig object. Launch Blender by running `blender` from a terminal. Before starting the work, use `/opt/blender/blender` for Blender command-line or background runs when working on `scene.blend`.\n\nThere is no IK constraint yet and no driver. wire up an FK/IK switch and save the result as `/home/user/Desktop/answer.blend`. ## Requirements 1. Add an IK constraint (`type='IK'`) on pose bone `Tip` of `Rig` with: - `target = IKTarget` (the empty object). - `chain_count = 3` (so the whole chain is solved). - `influence = 0.0` initially (the driver will override it). 2. Add a `SCRIPTED` driver on the IK constraint's `.influence` property: - Create an F-curve via `ik_constraint.driver_add('influence')`. - Driver `type = 'SCRIPTED'`, `expression = 'var'` (pass through). - Create a driver variable of `type = 'SINGLE_PROP'` whose target id is the armature object `Rig` (`id_type='OBJECT'`) and whose `data_path = '[\"ik_blend\"]'` (reads the custom property). 3. Set a FK baseline rotation on the `Upper` pose bone so the FK tip position is clearly distinguishable from the IK tip position: - E.g. set `rotation_mode='QUATERNION'` and apply a rotation corresponding to Euler (0, 0.5, 0). Optionally keyframe the rotation. 4. Leave `Rig['ik_blend']` at 0.0 in the saved file. The driver must allow flipping between FK (`ik_blend=0`) and IK (`ik_blend=1`) behaviors at runtime. ## Requirements 1. The saved file opens as a valid Blender file. 2. Object `Rig` exists as an ARMATURE with exactly 3 bones named `Upper`, `Lower`, `Tip`. 3. Object `IKTarget` exists with `type == 'EMPTY'`. 4. Custom property `ik_blend` on `Rig` exists with a numeric value in `[0, 1]`. 5. Pose bone `Tip` carries an IK constraint with `target == IKTarget`. 6. The IK constraint's `.influence` property is controlled by a driver whose first variable reads `Rig['ik_blend']` (variable `id` is `Rig`, `data_path` contains `ik_blend`). 7. Setting `Rig['ik_blend'] = 0.0` (FK) vs. `Rig['ik_blend'] = 1.0` (IK) yields tip-tail world positions that differ by more than 0.1 BU. 8. At `Rig['ik_blend'] = 0.5` the tip-tail world position lies within 0.3 BU of the linear interpolation of the FK and IK positions. Save the result as `/home/user/Desktop/answer.blend`.", "source": "https://docs.blender.org/manual/en/4.1/; https://docs.blender.org/api/4.1/; https://developer.blender.org/docs/release_notes/4.1/; https://www.loc.gov/preservation/digital/formats/fdd/fdd000507.shtml", "config": [ { "type": "upload_file", "parameters": { "files": [ { "local_path": "task-20/init_file/scene.blend", "path": "/home/user/Desktop/scene.blend" } ] } } ], "trajectory": "trajectories/", "related_apps": [ "blender" ], "artifact_paths": [ "/home/user/Desktop/answer.blend" ], "evaluator": { "postconfig": [ { "type": "upload_file", "parameters": { "files": [ { "local_path": "task-20/eval.py", "path": "/home/user/Desktop/eval.py" } ] } } ], "func": "exact_match", "result": { "type": "vm_command_line", "command": "python3 /home/user/Desktop/eval.py", "shell": "true" }, "expected": { "type": "rule", "rules": { "expected": "True\n" } } }, "proxy": false, "fixed_ip": false, "possibility_of_env_change": "low" }