{"abstract":"Deleting text leaves a bookmark endpoint inside removed content in the controlled document model.","category":"Document structure integrity","checks":6,"contract":"Given a valid bookmark [start,end] and deleted half-open text range [a,b], transform both endpoints: before stays, inside clamps to a, after shifts by b-a.","evaluation_group":"model-010fdfe11711d2f6","failed_approach":"Shifting endpoints after deletion fails to clamp endpoints lying inside the removed interval.","family":"z-documents-bookmark-delete-clamp","id":"FA-11826","implementations":{"attempt":{"sha256":"9dccac182cb24d3f6b47ab213eb8ba648cf8dc8a19e70f10989942c28f26a1d3","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\n\nN = 1\nobservations = []\ndef solve(start, end, a, b):\n    return [p-(b-a) if p>=b else p for p in (start,end)]\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\nfixtures = [((N,N+4,N+1,N+3),[N,N+2]), ((N+1,N+2,N,N+3),[N,N]), ((0,1,3,5),[0,1]), ((5,7,1,3),[3,5]), ((1,3,1,3),[1,1]), ((2,4,3,3),[2,4])]\nfor i, (args, expected) in enumerate(fixtures):\n    check(\"document fixture \" + str(i), solve(*args), expected)\nprint(json.dumps({\"observations\": observations, \"passed\": all(x[\"passed\"] for x in observations)}, ensure_ascii=False))\nraise SystemExit(0 if all(x[\"passed\"] for x in observations) else 1)\n"},"broken":{"sha256":"6c5fb9106731d716523959c87f60137ba45a972847b206e0f41dcfdb65e24c78","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\n\nN = 1\nobservations = []\ndef solve(start, end, a, b):\n    return [start,end]\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\nfixtures = [((N,N+4,N+1,N+3),[N,N+2]), ((N+1,N+2,N,N+3),[N,N]), ((0,1,3,5),[0,1]), ((5,7,1,3),[3,5]), ((1,3,1,3),[1,1]), ((2,4,3,3),[2,4])]\nfor i, (args, expected) in enumerate(fixtures):\n    check(\"document fixture \" + str(i), solve(*args), expected)\nprint(json.dumps({\"observations\": observations, \"passed\": all(x[\"passed\"] for x in observations)}, ensure_ascii=False))\nraise SystemExit(0 if all(x[\"passed\"] for x in observations) else 1)\n"},"fixed":{"sha256":"a3e8d4992772b39ffac224b0b6b0e9267d7eacf03e4339d0f60f67e5b04e6f36","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\n\nN = 1\nobservations = []\ndef solve(start, end, a, b):\n    return [p if p<=a else a if p<b else p-(b-a) for p in (start,end)]\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\nfixtures = [((N,N+4,N+1,N+3),[N,N+2]), ((N+1,N+2,N,N+3),[N,N]), ((0,1,3,5),[0,1]), ((5,7,1,3),[3,5]), ((1,3,1,3),[1,1]), ((2,4,3,3),[2,4])]\nfor i, (args, expected) in enumerate(fixtures):\n    check(\"document fixture \" + str(i), solve(*args), expected)\nprint(json.dumps({\"observations\": observations, \"passed\": all(x[\"passed\"] for x in observations)}, ensure_ascii=False))\nraise SystemExit(0 if all(x[\"passed\"] for x in observations) else 1)\n"}},"limitations":"An offline simplified document model, not a claim of conformance to any office file format. This reproducer isolates one failure mechanism. Results cover the supplied fixtures. Variants within a family share a test contract and should remain grouped when constructing evaluation splits. Related mechanisms with a shared evaluation_group must also remain together; these controlled models are not independent production incidents.","method":"Deterministic executable model with adversarial boundary fixtures.","provenance":{"created_by":"Failure Map","dependencies":"Python standard library","family":"z-documents-bookmark-delete-clamp","generated_at":"2026-09-29T14:38:51.330529+00:00","license":"CC0-1.0","python":"3.12.14","seed":1,"split":"open-access"},"relevance":"Structured editing must preserve document semantics independently of visual rendering.","repair":"Map both endpoints through the deletion coordinate transform, retaining collapsed bookmarks.","root_cause":"Bookmark coordinates remain in the pre-edit coordinate system.","sha256":"4ef961b0ccb55eefa8d1ae78caf65cb7746b77c9a6f3a06add5f8e8d77400eb5","title":"Deleting text leaves a bookmark endpoint inside removed content · case 01","variant":1,"variant_policy":"Five numbered records share a model and may reuse boundary fixtures.","verification":{"attempt":{"elapsed_ms":38.969,"exit_code":1,"observations":[{"actual":[1,3],"check":"document fixture 0","expected":[1,3],"passed":true},{"actual":[2,3],"check":"document fixture 1","expected":[1,1],"passed":false},{"actual":[0,1],"check":"document fixture 2","expected":[0,1],"passed":true},{"actual":[3,5],"check":"document fixture 3","expected":[3,5],"passed":true},{"actual":[1,1],"check":"document fixture 4","expected":[1,1],"passed":true},{"actual":[2,4],"check":"document fixture 5","expected":[2,4],"passed":true}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"document fixture 0\", \"actual\": [1, 3], \"expected\": [1, 3], \"passed\": true}, {\"check\": \"document fixture 1\", \"actual\": [2, 3], \"expected\": [1, 1], \"passed\": false}, {\"check\": \"document fixture 2\", \"actual\": [0, 1], \"expected\": [0, 1], \"passed\": true}, {\"check\": \"document fixture 3\", \"actual\": [3, 5], \"expected\": [3, 5], \"passed\": true}, {\"check\": \"document fixture 4\", \"actual\": [1, 1], \"expected\": [1, 1], \"passed\": true}, {\"check\": \"document fixture 5\", \"actual\": [2, 4], \"expected\": [2, 4], \"passed\": true}], \"passed\": false}\n"},"broken":{"elapsed_ms":39.363,"exit_code":1,"observations":[{"actual":[1,5],"check":"document fixture 0","expected":[1,3],"passed":false},{"actual":[2,3],"check":"document fixture 1","expected":[1,1],"passed":false},{"actual":[0,1],"check":"document fixture 2","expected":[0,1],"passed":true},{"actual":[5,7],"check":"document fixture 3","expected":[3,5],"passed":false},{"actual":[1,3],"check":"document fixture 4","expected":[1,1],"passed":false},{"actual":[2,4],"check":"document fixture 5","expected":[2,4],"passed":true}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"document fixture 0\", \"actual\": [1, 5], \"expected\": [1, 3], \"passed\": false}, {\"check\": \"document fixture 1\", \"actual\": [2, 3], \"expected\": [1, 1], \"passed\": false}, {\"check\": \"document fixture 2\", \"actual\": [0, 1], \"expected\": [0, 1], \"passed\": true}, {\"check\": \"document fixture 3\", \"actual\": [5, 7], \"expected\": [3, 5], \"passed\": false}, {\"check\": \"document fixture 4\", \"actual\": [1, 3], \"expected\": [1, 1], \"passed\": false}, {\"check\": \"document fixture 5\", \"actual\": [2, 4], \"expected\": [2, 4], \"passed\": true}], \"passed\": false}\n"},"fixed":{"elapsed_ms":39.843,"exit_code":0,"observations":[{"actual":[1,3],"check":"document fixture 0","expected":[1,3],"passed":true},{"actual":[1,1],"check":"document fixture 1","expected":[1,1],"passed":true},{"actual":[0,1],"check":"document fixture 2","expected":[0,1],"passed":true},{"actual":[3,5],"check":"document fixture 3","expected":[3,5],"passed":true},{"actual":[1,1],"check":"document fixture 4","expected":[1,1],"passed":true},{"actual":[2,4],"check":"document fixture 5","expected":[2,4],"passed":true}],"passed":true,"stderr":"","stdout":"{\"observations\": [{\"check\": \"document fixture 0\", \"actual\": [1, 3], \"expected\": [1, 3], \"passed\": true}, {\"check\": \"document fixture 1\", \"actual\": [1, 1], \"expected\": [1, 1], \"passed\": true}, {\"check\": \"document fixture 2\", \"actual\": [0, 1], \"expected\": [0, 1], \"passed\": true}, {\"check\": \"document fixture 3\", \"actual\": [3, 5], \"expected\": [3, 5], \"passed\": true}, {\"check\": \"document fixture 4\", \"actual\": [1, 1], \"expected\": [1, 1], \"passed\": true}, {\"check\": \"document fixture 5\", \"actual\": [2, 4], \"expected\": [2, 4], \"passed\": true}], \"passed\": true}\n"}},"verified":true,"visibility":"public"}