broken_source:
"""Failure Map reference implementation. Python standard library only."""
import json
from fractions import Fraction
N = 1
observations = []
def solve(r):
    text = r['text']
    zulu = text == 'Z'
    shape = len(text) == 6 and text[3] == ':'
    digits = shape and all('0' <= c <= '9' for c in text[1:3]+text[4:6])
    hour = int(text[1:3]) if digits else 0
    minute = int(text[4:6]) if digits else 0
    range_ok = hour <= 14 and minute <= 59 and (hour != 14 or minute == 0)
    valid = zulu or (digits and range_ok)
    unknown = valid and text == '-00:00'
    offset = None if not valid or unknown else (0 if zulu else (-1 if text[0] == '-' else 1) * (hour * 60 + minute))
    return [valid,valid and not unknown,offset,unknown]
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('fixture 1', solve({'text': 'Z', 'probe': 0}), [True, True, 0, False])
check('fixture 2', solve({'text': 'z', 'probe': 0}), [False, False, None, False])
check('fixture 3', solve({'text': 'UTC', 'probe': 0}), [False, False, None, False])
check('fixture 4', solve({'text': '+00:00', 'probe': 0}), [True, True, 0, False])
check('fixture 5', solve({'text': '-00:00', 'probe': 0}), [True, False, None, True])
check('fixture 6', solve({'text': '-05:30', 'probe': 0}), [True, True, -330, False])
check('fixture 7', solve({'text': '+14:00', 'probe': 0}), [True, True, 840, False])
check('fixture 8', solve({'text': '+14:01', 'probe': 0}), [False, False, None, False])
check('fixture 9', solve({'text': '+12:59', 'probe': 0}), [True, True, 779, False])
check('fixture 10', solve({'text': '+12:60', 'probe': 0}), [False, False, None, False])
check('fixture 11', solve({'text': 'x01:00', 'probe': 0}), [False, False, None, False])
check('fixture 12', solve({'text': '+01x00', 'probe': 0}), [False, False, None, False])
check('fixture 13', solve({'text': '+٠١:٠٠', 'probe': 0}), [False, False, None, False])
check('fixture 14', solve({'text': ' Z ', 'probe': 0}), [False, False, None, False])
check('fixture 15', solve({'text': '+10:02', 'probe': 0}), [True, True, 602, False])
variant = [({'text': '+01:30', 'probe': 0}, [True, True, 90, False]), ({'text': '+02:30', 'probe': 0}, [True, True, 150, False]), ({'text': '+03:30', 'probe': 0}, [True, True, 210, False]), ({'text': '+04:30', 'probe': 0}, [True, True, 270, False]), ({'text': '+05:30', 'probe': 0}, [True, True, 330, False])]
check("variant capture", solve(variant[N-1][0]), variant[N-1][1])
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)

source:
"""Failure Map reference implementation. Python standard library only."""
import json
from fractions import Fraction
N = 1
observations = []
def solve(r):
    text = r['text']
    zulu = text == 'Z'
    shape = len(text) == 6 and text[0] in '+-'
    digits = shape and all('0' <= c <= '9' for c in text[1:3]+text[4:6])
    hour = int(text[1:3]) if digits else 0
    minute = int(text[4:6]) if digits else 0
    range_ok = hour <= 14 and minute <= 59 and (hour != 14 or minute == 0)
    valid = zulu or (digits and range_ok)
    unknown = valid and text == '-00:00'
    offset = None if not valid or unknown else (0 if zulu else (-1 if text[0] == '-' else 1) * (hour * 60 + minute))
    return [valid,valid and not unknown,offset,unknown]
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('fixture 1', solve({'text': 'Z', 'probe': 0}), [True, True, 0, False])
check('fixture 2', solve({'text': 'z', 'probe': 0}), [False, False, None, False])
check('fixture 3', solve({'text': 'UTC', 'probe': 0}), [False, False, None, False])
check('fixture 4', solve({'text': '+00:00', 'probe': 0}), [True, True, 0, False])
check('fixture 5', solve({'text': '-00:00', 'probe': 0}), [True, False, None, True])
check('fixture 6', solve({'text': '-05:30', 'probe': 0}), [True, True, -330, False])
check('fixture 7', solve({'text': '+14:00', 'probe': 0}), [True, True, 840, False])
check('fixture 8', solve({'text': '+14:01', 'probe': 0}), [False, False, None, False])
check('fixture 9', solve({'text': '+12:59', 'probe': 0}), [True, True, 779, False])
check('fixture 10', solve({'text': '+12:60', 'probe': 0}), [False, False, None, False])
check('fixture 11', solve({'text': 'x01:00', 'probe': 0}), [False, False, None, False])
check('fixture 12', solve({'text': '+01x00', 'probe': 0}), [False, False, None, False])
check('fixture 13', solve({'text': '+٠١:٠٠', 'probe': 0}), [False, False, None, False])
check('fixture 14', solve({'text': ' Z ', 'probe': 0}), [False, False, None, False])
check('fixture 15', solve({'text': '+10:02', 'probe': 0}), [True, True, 602, False])
variant = [({'text': '+01:30', 'probe': 0}, [True, True, 90, False]), ({'text': '+02:30', 'probe': 0}, [True, True, 150, False]), ({'text': '+03:30', 'probe': 0}, [True, True, 210, False]), ({'text': '+04:30', 'probe': 0}, [True, True, 270, False]), ({'text': '+05:30', 'probe': 0}, [True, True, 330, False])]
check("variant capture", solve(variant[N-1][0]), variant[N-1][1])
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)

prompt:
The decoded time state disagrees with the explicit regression oracle for shape.

Controlled offset lexeme is Z or signed HH:MM with ASCII digits, hour<=14, minute<=59 and hour14 only minute00. Negative zero means unknown local offset and has no numeric UTC offset; positive zero and Z are known UTC. Return accepted, known, signed minute displacement and original negative-zero marker. No timezone database is consulted.

split: open-access


broken_source:
"""Failure Map reference implementation. Python standard library only."""
import json
from fractions import Fraction
N = 1
observations = []
def solve(r):
    text = r['text']
    zulu = text == 'Z'
    shape = len(text) == 6 and text[0] in '+-' and text[3] == ':'
    digits = shape and (text[1:3]+text[4:6]).isdigit()
    hour = int(text[1:3]) if digits else 0
    minute = int(text[4:6]) if digits else 0
    range_ok = hour <= 14 and minute <= 59 and (hour != 14 or minute == 0)
    valid = zulu or (digits and range_ok)
    unknown = valid and text == '-00:00'
    offset = None if not valid or unknown else (0 if zulu else (-1 if text[0] == '-' else 1) * (hour * 60 + minute))
    return [valid,valid and not unknown,offset,unknown]
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('fixture 1', solve({'text': 'Z', 'probe': 0}), [True, True, 0, False])
check('fixture 2', solve({'text': 'z', 'probe': 0}), [False, False, None, False])
check('fixture 3', solve({'text': 'UTC', 'probe': 0}), [False, False, None, False])
check('fixture 4', solve({'text': '+00:00', 'probe': 0}), [True, True, 0, False])
check('fixture 5', solve({'text': '-00:00', 'probe': 0}), [True, False, None, True])
check('fixture 6', solve({'text': '-05:30', 'probe': 0}), [True, True, -330, False])
check('fixture 7', solve({'text': '+14:00', 'probe': 0}), [True, True, 840, False])
check('fixture 8', solve({'text': '+14:01', 'probe': 0}), [False, False, None, False])
check('fixture 9', solve({'text': '+12:59', 'probe': 0}), [True, True, 779, False])
check('fixture 10', solve({'text': '+12:60', 'probe': 0}), [False, False, None, False])
check('fixture 11', solve({'text': 'x01:00', 'probe': 0}), [False, False, None, False])
check('fixture 12', solve({'text': '+01x00', 'probe': 0}), [False, False, None, False])
check('fixture 13', solve({'text': '+٠١:٠٠', 'probe': 0}), [False, False, None, False])
check('fixture 14', solve({'text': ' Z ', 'probe': 0}), [False, False, None, False])
check('fixture 15', solve({'text': '+10:02', 'probe': 0}), [True, True, 602, False])
variant = [({'text': '+01:30', 'probe': 0}, [True, True, 90, False]), ({'text': '+02:30', 'probe': 0}, [True, True, 150, False]), ({'text': '+03:30', 'probe': 0}, [True, True, 210, False]), ({'text': '+04:30', 'probe': 0}, [True, True, 270, False]), ({'text': '+05:30', 'probe': 0}, [True, True, 330, False])]
check("variant capture", solve(variant[N-1][0]), variant[N-1][1])
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)

meaning: Fixture-count band, not measured model difficulty

deps: stdlib

source:
"""Failure Map reference implementation. Python standard library only."""
import json
from fractions import Fraction
N = 1
observations = []
def solve(r):
    text = r['text']
    zulu = text == 'Z'
    shape = len(text) == 6 and text[0] in '+-' and text[3] == ':'
    digits = shape and (text[1:3]+text[4:6]).isdecimal()
    hour = int(text[1:3]) if digits else 0
    minute = int(text[4:6]) if digits else 0
    range_ok = hour <= 14 and minute <= 59 and (hour != 14 or minute == 0)
    valid = zulu or (digits and range_ok)
    unknown = valid and text == '-00:00'
    offset = None if not valid or unknown else (0 if zulu else (-1 if text[0] == '-' else 1) * (hour * 60 + minute))
    return [valid,valid and not unknown,offset,unknown]
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('fixture 1', solve({'text': 'Z', 'probe': 0}), [True, True, 0, False])
check('fixture 2', solve({'text': 'z', 'probe': 0}), [False, False, None, False])
check('fixture 3', solve({'text': 'UTC', 'probe': 0}), [False, False, None, False])
check('fixture 4', solve({'text': '+00:00', 'probe': 0}), [True, True, 0, False])
check('fixture 5', solve({'text': '-00:00', 'probe': 0}), [True, False, None, True])
check('fixture 6', solve({'text': '-05:30', 'probe': 0}), [True, True, -330, False])
check('fixture 7', solve({'text': '+14:00', 'probe': 0}), [True, True, 840, False])
check('fixture 8', solve({'text': '+14:01', 'probe': 0}), [False, False, None, False])
check('fixture 9', solve({'text': '+12:59', 'probe': 0}), [True, True, 779, False])
check('fixture 10', solve({'text': '+12:60', 'probe': 0}), [False, False, None, False])
check('fixture 11', solve({'text': 'x01:00', 'probe': 0}), [False, False, None, False])
check('fixture 12', solve({'text': '+01x00', 'probe': 0}), [False, False, None, False])
check('fixture 13', solve({'text': '+٠١:٠٠', 'probe': 0}), [False, False, None, False])
check('fixture 14', solve({'text': ' Z ', 'probe': 0}), [False, False, None, False])
check('fixture 15', solve({'text': '+10:02', 'probe': 0}), [True, True, 602, False])
variant = [({'text': '+01:30', 'probe': 0}, [True, True, 90, False]), ({'text': '+02:30', 'probe': 0}, [True, True, 150, False]), ({'text': '+03:30', 'probe': 0}, [True, True, 210, False]), ({'text': '+04:30', 'probe': 0}, [True, True, 270, False]), ({'text': '+05:30', 'probe': 0}, [True, True, 330, False])]
check("variant capture", solve(variant[N-1][0]), variant[N-1][1])
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)

prompt:
The decoded time state disagrees with the explicit regression oracle for digits.

Controlled offset lexeme is Z or signed HH:MM with ASCII digits, hour<=14, minute<=59 and hour14 only minute00. Negative zero means unknown local offset and has no numeric UTC offset; positive zero and Z are known UTC. Return accepted, known, signed minute displacement and original negative-zero marker. No timezone database is consulted.

split: open-access


broken_source:
"""Failure Map reference implementation. Python standard library only."""
import json
from fractions import Fraction
N = 1
observations = []
def solve(r):
    text = r['text']
    zulu = text == 'Z'
    shape = len(text) == 6 and text[0] in '+-' and text[3] == ':'
    digits = shape and all('0' <= c <= '9' for c in text[1:3]+text[4:6])
    hour = int(text[4:6]) if digits else 0
    minute = int(text[4:6]) if digits else 0
    range_ok = hour <= 14 and minute <= 59 and (hour != 14 or minute == 0)
    valid = zulu or (digits and range_ok)
    unknown = valid and text == '-00:00'
    offset = None if not valid or unknown else (0 if zulu else (-1 if text[0] == '-' else 1) * (hour * 60 + minute))
    return [valid,valid and not unknown,offset,unknown]
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('fixture 1', solve({'text': 'Z', 'probe': 0}), [True, True, 0, False])
check('fixture 2', solve({'text': 'z', 'probe': 0}), [False, False, None, False])
check('fixture 3', solve({'text': 'UTC', 'probe': 0}), [False, False, None, False])
check('fixture 4', solve({'text': '+00:00', 'probe': 0}), [True, True, 0, False])
check('fixture 5', solve({'text': '-00:00', 'probe': 0}), [True, False, None, True])
check('fixture 6', solve({'text': '-05:30', 'probe': 0}), [True, True, -330, False])
check('fixture 7', solve({'text': '+14:00', 'probe': 0}), [True, True, 840, False])
check('fixture 8', solve({'text': '+14:01', 'probe': 0}), [False, False, None, False])
check('fixture 9', solve({'text': '+12:59', 'probe': 0}), [True, True, 779, False])
check('fixture 10', solve({'text': '+12:60', 'probe': 0}), [False, False, None, False])
check('fixture 11', solve({'text': 'x01:00', 'probe': 0}), [False, False, None, False])
check('fixture 12', solve({'text': '+01x00', 'probe': 0}), [False, False, None, False])
check('fixture 13', solve({'text': '+٠١:٠٠', 'probe': 0}), [False, False, None, False])
check('fixture 14', solve({'text': ' Z ', 'probe': 0}), [False, False, None, False])
check('fixture 15', solve({'text': '+10:02', 'probe': 0}), [True, True, 602, False])
variant = [({'text': '+01:30', 'probe': 0}, [True, True, 90, False]), ({'text': '+02:30', 'probe': 0}, [True, True, 150, False]), ({'text': '+03:30', 'probe': 0}, [True, True, 210, False]), ({'text': '+04:30', 'probe': 0}, [True, True, 270, False]), ({'text': '+05:30', 'probe': 0}, [True, True, 330, False])]
check("variant capture", solve(variant[N-1][0]), variant[N-1][1])
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)

source:
"""Failure Map reference implementation. Python standard library only."""
import json
from fractions import Fraction
N = 1
observations = []
def solve(r):
    text = r['text']
    zulu = text == 'Z'
    shape = len(text) == 6 and text[0] in '+-' and text[3] == ':'
    digits = shape and all('0' <= c <= '9' for c in text[1:3]+text[4:6])
    hour = int(text[1]) if digits else 0
    minute = int(text[4:6]) if digits else 0
    range_ok = hour <= 14 and minute <= 59 and (hour != 14 or minute == 0)
    valid = zulu or (digits and range_ok)
    unknown = valid and text == '-00:00'
    offset = None if not valid or unknown else (0 if zulu else (-1 if text[0] == '-' else 1) * (hour * 60 + minute))
    return [valid,valid and not unknown,offset,unknown]
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('fixture 1', solve({'text': 'Z', 'probe': 0}), [True, True, 0, False])
check('fixture 2', solve({'text': 'z', 'probe': 0}), [False, False, None, False])
check('fixture 3', solve({'text': 'UTC', 'probe': 0}), [False, False, None, False])
check('fixture 4', solve({'text': '+00:00', 'probe': 0}), [True, True, 0, False])
check('fixture 5', solve({'text': '-00:00', 'probe': 0}), [True, False, None, True])
check('fixture 6', solve({'text': '-05:30', 'probe': 0}), [True, True, -330, False])
check('fixture 7', solve({'text': '+14:00', 'probe': 0}), [True, True, 840, False])
check('fixture 8', solve({'text': '+14:01', 'probe': 0}), [False, False, None, False])
check('fixture 9', solve({'text': '+12:59', 'probe': 0}), [True, True, 779, False])
check('fixture 10', solve({'text': '+12:60', 'probe': 0}), [False, False, None, False])
check('fixture 11', solve({'text': 'x01:00', 'probe': 0}), [False, False, None, False])
check('fixture 12', solve({'text': '+01x00', 'probe': 0}), [False, False, None, False])
check('fixture 13', solve({'text': '+٠١:٠٠', 'probe': 0}), [False, False, None, False])
check('fixture 14', solve({'text': ' Z ', 'probe': 0}), [False, False, None, False])
check('fixture 15', solve({'text': '+10:02', 'probe': 0}), [True, True, 602, False])
variant = [({'text': '+01:30', 'probe': 0}, [True, True, 90, False]), ({'text': '+02:30', 'probe': 0}, [True, True, 150, False]), ({'text': '+03:30', 'probe': 0}, [True, True, 210, False]), ({'text': '+04:30', 'probe': 0}, [True, True, 270, False]), ({'text': '+05:30', 'probe': 0}, [True, True, 330, False])]
check("variant capture", solve(variant[N-1][0]), variant[N-1][1])
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)

prompt:
The decoded time state disagrees with the explicit regression oracle for hour.

Controlled offset lexeme is Z or signed HH:MM with ASCII digits, hour<=14, minute<=59 and hour14 only minute00. Negative zero means unknown local offset and has no numeric UTC offset; positive zero and Z are known UTC. Return accepted, known, signed minute displacement and original negative-zero marker. No timezone database is consulted.

split: open-access


broken_source:
"""Failure Map reference implementation. Python standard library only."""
import json
from fractions import Fraction
N = 1
observations = []
def solve(r):
    text = r['text']
    zulu = text == 'Z'
    shape = len(text) == 6 and text[0] in '+-' and text[3] == ':'
    digits = shape and all('0' <= c <= '9' for c in text[1:3]+text[4:6])
    hour = int(text[1:3]) if digits else 0
    minute = int(text[1:3]) if digits else 0
    range_ok = hour <= 14 and minute <= 59 and (hour != 14 or minute == 0)
    valid = zulu or (digits and range_ok)
    unknown = valid and text == '-00:00'
    offset = None if not valid or unknown else (0 if zulu else (-1 if text[0] == '-' else 1) * (hour * 60 + minute))
    return [valid,valid and not unknown,offset,unknown]
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('fixture 1', solve({'text': 'Z', 'probe': 0}), [True, True, 0, False])
check('fixture 2', solve({'text': 'z', 'probe': 0}), [False, False, None, False])
check('fixture 3', solve({'text': 'UTC', 'probe': 0}), [False, False, None, False])
check('fixture 4', solve({'text': '+00:00', 'probe': 0}), [True, True, 0, False])
check('fixture 5', solve({'text': '-00:00', 'probe': 0}), [True, False, None, True])
check('fixture 6', solve({'text': '-05:30', 'probe': 0}), [True, True, -330, False])
check('fixture 7', solve({'text': '+14:00', 'probe': 0}), [True, True, 840, False])
check('fixture 8', solve({'text': '+14:01', 'probe': 0}), [False, False, None, False])
check('fixture 9', solve({'text': '+12:59', 'probe': 0}), [True, True, 779, False])
check('fixture 10', solve({'text': '+12:60', 'probe': 0}), [False, False, None, False])
check('fixture 11', solve({'text': 'x01:00', 'probe': 0}), [False, False, None, False])
check('fixture 12', solve({'text': '+01x00', 'probe': 0}), [False, False, None, False])
check('fixture 13', solve({'text': '+٠١:٠٠', 'probe': 0}), [False, False, None, False])
check('fixture 14', solve({'text': ' Z ', 'probe': 0}), [False, False, None, False])
check('fixture 15', solve({'text': '+10:02', 'probe': 0}), [True, True, 602, False])
variant = [({'text': '+01:30', 'probe': 0}, [True, True, 90, False]), ({'text': '+02:30', 'probe': 0}, [True, True, 150, False]), ({'text': '+03:30', 'probe': 0}, [True, True, 210, False]), ({'text': '+04:30', 'probe': 0}, [True, True, 270, False]), ({'text': '+05:30', 'probe': 0}, [True, True, 330, False])]
check("variant capture", solve(variant[N-1][0]), variant[N-1][1])
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)

source:
"""Failure Map reference implementation. Python standard library only."""
import json
from fractions import Fraction
N = 1
observations = []
def solve(r):
    text = r['text']
    zulu = text == 'Z'
    shape = len(text) == 6 and text[0] in '+-' and text[3] == ':'
    digits = shape and all('0' <= c <= '9' for c in text[1:3]+text[4:6])
    hour = int(text[1:3]) if digits else 0
    minute = int(text[4]) if digits else 0
    range_ok = hour <= 14 and minute <= 59 and (hour != 14 or minute == 0)
    valid = zulu or (digits and range_ok)
    unknown = valid and text == '-00:00'
    offset = None if not valid or unknown else (0 if zulu else (-1 if text[0] == '-' else 1) * (hour * 60 + minute))
    return [valid,valid and not unknown,offset,unknown]
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('fixture 1', solve({'text': 'Z', 'probe': 0}), [True, True, 0, False])
check('fixture 2', solve({'text': 'z', 'probe': 0}), [False, False, None, False])
check('fixture 3', solve({'text': 'UTC', 'probe': 0}), [False, False, None, False])
check('fixture 4', solve({'text': '+00:00', 'probe': 0}), [True, True, 0, False])
check('fixture 5', solve({'text': '-00:00', 'probe': 0}), [True, False, None, True])
check('fixture 6', solve({'text': '-05:30', 'probe': 0}), [True, True, -330, False])
check('fixture 7', solve({'text': '+14:00', 'probe': 0}), [True, True, 840, False])
check('fixture 8', solve({'text': '+14:01', 'probe': 0}), [False, False, None, False])
check('fixture 9', solve({'text': '+12:59', 'probe': 0}), [True, True, 779, False])
check('fixture 10', solve({'text': '+12:60', 'probe': 0}), [False, False, None, False])
check('fixture 11', solve({'text': 'x01:00', 'probe': 0}), [False, False, None, False])
check('fixture 12', solve({'text': '+01x00', 'probe': 0}), [False, False, None, False])
check('fixture 13', solve({'text': '+٠١:٠٠', 'probe': 0}), [False, False, None, False])
check('fixture 14', solve({'text': ' Z ', 'probe': 0}), [False, False, None, False])
check('fixture 15', solve({'text': '+10:02', 'probe': 0}), [True, True, 602, False])
variant = [({'text': '+01:30', 'probe': 0}, [True, True, 90, False]), ({'text': '+02:30', 'probe': 0}, [True, True, 150, False]), ({'text': '+03:30', 'probe': 0}, [True, True, 210, False]), ({'text': '+04:30', 'probe': 0}, [True, True, 270, False]), ({'text': '+05:30', 'probe': 0}, [True, True, 330, False])]
check("variant capture", solve(variant[N-1][0]), variant[N-1][1])
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)

prompt:
The decoded time state disagrees with the explicit regression oracle for minute.

Controlled offset lexeme is Z or signed HH:MM with ASCII digits, hour<=14, minute<=59 and hour14 only minute00. Negative zero means unknown local offset and has no numeric UTC offset; positive zero and Z are known UTC. Return accepted, known, signed minute displacement and original negative-zero marker. No timezone database is consulted.

split: open-access


broken_source:
"""Failure Map reference implementation. Python standard library only."""
import json
from fractions import Fraction
N = 1
observations = []
def solve(r):
    text = r['text']
    zulu = text == 'Z'
    shape = len(text) == 6 and text[0] in '+-' and text[3] == ':'
    digits = shape and all('0' <= c <= '9' for c in text[1:3]+text[4:6])
    hour = int(text[1:3]) if digits else 0
    minute = int(text[4:6]) if digits else 0
    range_ok = hour <= 14 and minute <= 59
    valid = zulu or (digits and range_ok)
    unknown = valid and text == '-00:00'
    offset = None if not valid or unknown else (0 if zulu else (-1 if text[0] == '-' else 1) * (hour * 60 + minute))
    return [valid,valid and not unknown,offset,unknown]
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('fixture 1', solve({'text': 'Z', 'probe': 0}), [True, True, 0, False])
check('fixture 2', solve({'text': 'z', 'probe': 0}), [False, False, None, False])
check('fixture 3', solve({'text': 'UTC', 'probe': 0}), [False, False, None, False])
check('fixture 4', solve({'text': '+00:00', 'probe': 0}), [True, True, 0, False])
check('fixture 5', solve({'text': '-00:00', 'probe': 0}), [True, False, None, True])
check('fixture 6', solve({'text': '-05:30', 'probe': 0}), [True, True, -330, False])
check('fixture 7', solve({'text': '+14:00', 'probe': 0}), [True, True, 840, False])
check('fixture 8', solve({'text': '+14:01', 'probe': 0}), [False, False, None, False])
check('fixture 9', solve({'text': '+12:59', 'probe': 0}), [True, True, 779, False])
check('fixture 10', solve({'text': '+12:60', 'probe': 0}), [False, False, None, False])
check('fixture 11', solve({'text': 'x01:00', 'probe': 0}), [False, False, None, False])
check('fixture 12', solve({'text': '+01x00', 'probe': 0}), [False, False, None, False])
check('fixture 13', solve({'text': '+٠١:٠٠', 'probe': 0}), [False, False, None, False])
check('fixture 14', solve({'text': ' Z ', 'probe': 0}), [False, False, None, False])
check('fixture 15', solve({'text': '+10:02', 'probe': 0}), [True, True, 602, False])
variant = [({'text': '+01:30', 'probe': 0}, [True, True, 90, False]), ({'text': '+02:30', 'probe': 0}, [True, True, 150, False]), ({'text': '+03:30', 'probe': 0}, [True, True, 210, False]), ({'text': '+04:30', 'probe': 0}, [True, True, 270, False]), ({'text': '+05:30', 'probe': 0}, [True, True, 330, False])]
check("variant capture", solve(variant[N-1][0]), variant[N-1][1])
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)

source:
"""Failure Map reference implementation. Python standard library only."""
import json
from fractions import Fraction
N = 1
observations = []
def solve(r):
    text = r['text']
    zulu = text == 'Z'
    shape = len(text) == 6 and text[0] in '+-' and text[3] == ':'
    digits = shape and all('0' <= c <= '9' for c in text[1:3]+text[4:6])
    hour = int(text[1:3]) if digits else 0
    minute = int(text[4:6]) if digits else 0
    range_ok = hour < 14 and minute <= 59
    valid = zulu or (digits and range_ok)
    unknown = valid and text == '-00:00'
    offset = None if not valid or unknown else (0 if zulu else (-1 if text[0] == '-' else 1) * (hour * 60 + minute))
    return [valid,valid and not unknown,offset,unknown]
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('fixture 1', solve({'text': 'Z', 'probe': 0}), [True, True, 0, False])
check('fixture 2', solve({'text': 'z', 'probe': 0}), [False, False, None, False])
check('fixture 3', solve({'text': 'UTC', 'probe': 0}), [False, False, None, False])
check('fixture 4', solve({'text': '+00:00', 'probe': 0}), [True, True, 0, False])
check('fixture 5', solve({'text': '-00:00', 'probe': 0}), [True, False, None, True])
check('fixture 6', solve({'text': '-05:30', 'probe': 0}), [True, True, -330, False])
check('fixture 7', solve({'text': '+14:00', 'probe': 0}), [True, True, 840, False])
check('fixture 8', solve({'text': '+14:01', 'probe': 0}), [False, False, None, False])
check('fixture 9', solve({'text': '+12:59', 'probe': 0}), [True, True, 779, False])
check('fixture 10', solve({'text': '+12:60', 'probe': 0}), [False, False, None, False])
check('fixture 11', solve({'text': 'x01:00', 'probe': 0}), [False, False, None, False])
check('fixture 12', solve({'text': '+01x00', 'probe': 0}), [False, False, None, False])
check('fixture 13', solve({'text': '+٠١:٠٠', 'probe': 0}), [False, False, None, False])
check('fixture 14', solve({'text': ' Z ', 'probe': 0}), [False, False, None, False])
check('fixture 15', solve({'text': '+10:02', 'probe': 0}), [True, True, 602, False])
variant = [({'text': '+01:30', 'probe': 0}, [True, True, 90, False]), ({'text': '+02:30', 'probe': 0}, [True, True, 150, False]), ({'text': '+03:30', 'probe': 0}, [True, True, 210, False]), ({'text': '+04:30', 'probe': 0}, [True, True, 270, False]), ({'text': '+05:30', 'probe': 0}, [True, True, 330, False])]
check("variant capture", solve(variant[N-1][0]), variant[N-1][1])
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)

prompt:
The decoded time state disagrees with the explicit regression oracle for range_ok.

Controlled offset lexeme is Z or signed HH:MM with ASCII digits, hour<=14, minute<=59 and hour14 only minute00. Negative zero means unknown local offset and has no numeric UTC offset; positive zero and Z are known UTC. Return accepted, known, signed minute displacement and original negative-zero marker. No timezone database is consulted.

split: open-access


broken_source:
"""Failure Map reference implementation. Python standard library only."""
import json
from fractions import Fraction
N = 1
observations = []
def solve(r):
    text = r['text']
    zulu = text == 'Z'
    shape = len(text) == 6 and text[0] in '+-' and text[3] == ':'
    digits = shape and all('0' <= c <= '9' for c in text[1:3]+text[4:6])
    hour = int(text[1:3]) if digits else 0
    minute = int(text[4:6]) if digits else 0
    range_ok = hour <= 14 and minute <= 59 and (hour != 14 or minute == 0)
    valid = zulu or digits
    unknown = valid and text == '-00:00'
    offset = None if not valid or unknown else (0 if zulu else (-1 if text[0] == '-' else 1) * (hour * 60 + minute))
    return [valid,valid and not unknown,offset,unknown]
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('fixture 1', solve({'text': 'Z', 'probe': 0}), [True, True, 0, False])
check('fixture 2', solve({'text': 'z', 'probe': 0}), [False, False, None, False])
check('fixture 3', solve({'text': 'UTC', 'probe': 0}), [False, False, None, False])
check('fixture 4', solve({'text': '+00:00', 'probe': 0}), [True, True, 0, False])
check('fixture 5', solve({'text': '-00:00', 'probe': 0}), [True, False, None, True])
check('fixture 6', solve({'text': '-05:30', 'probe': 0}), [True, True, -330, False])
check('fixture 7', solve({'text': '+14:00', 'probe': 0}), [True, True, 840, False])
check('fixture 8', solve({'text': '+14:01', 'probe': 0}), [False, False, None, False])
check('fixture 9', solve({'text': '+12:59', 'probe': 0}), [True, True, 779, False])
check('fixture 10', solve({'text': '+12:60', 'probe': 0}), [False, False, None, False])
check('fixture 11', solve({'text': 'x01:00', 'probe': 0}), [False, False, None, False])
check('fixture 12', solve({'text': '+01x00', 'probe': 0}), [False, False, None, False])
check('fixture 13', solve({'text': '+٠١:٠٠', 'probe': 0}), [False, False, None, False])
check('fixture 14', solve({'text': ' Z ', 'probe': 0}), [False, False, None, False])
check('fixture 15', solve({'text': '+10:02', 'probe': 0}), [True, True, 602, False])
variant = [({'text': '+01:30', 'probe': 0}, [True, True, 90, False]), ({'text': '+02:30', 'probe': 0}, [True, True, 150, False]), ({'text': '+03:30', 'probe': 0}, [True, True, 210, False]), ({'text': '+04:30', 'probe': 0}, [True, True, 270, False]), ({'text': '+05:30', 'probe': 0}, [True, True, 330, False])]
check("variant capture", solve(variant[N-1][0]), variant[N-1][1])
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)

source:
"""Failure Map reference implementation. Python standard library only."""
import json
from fractions import Fraction
N = 1
observations = []
def solve(r):
    text = r['text']
    zulu = text == 'Z'
    shape = len(text) == 6 and text[0] in '+-' and text[3] == ':'
    digits = shape and all('0' <= c <= '9' for c in text[1:3]+text[4:6])
    hour = int(text[1:3]) if digits else 0
    minute = int(text[4:6]) if digits else 0
    range_ok = hour <= 14 and minute <= 59 and (hour != 14 or minute == 0)
    valid = digits and range_ok
    unknown = valid and text == '-00:00'
    offset = None if not valid or unknown else (0 if zulu else (-1 if text[0] == '-' else 1) * (hour * 60 + minute))
    return [valid,valid and not unknown,offset,unknown]
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('fixture 1', solve({'text': 'Z', 'probe': 0}), [True, True, 0, False])
check('fixture 2', solve({'text': 'z', 'probe': 0}), [False, False, None, False])
check('fixture 3', solve({'text': 'UTC', 'probe': 0}), [False, False, None, False])
check('fixture 4', solve({'text': '+00:00', 'probe': 0}), [True, True, 0, False])
check('fixture 5', solve({'text': '-00:00', 'probe': 0}), [True, False, None, True])
check('fixture 6', solve({'text': '-05:30', 'probe': 0}), [True, True, -330, False])
check('fixture 7', solve({'text': '+14:00', 'probe': 0}), [True, True, 840, False])
check('fixture 8', solve({'text': '+14:01', 'probe': 0}), [False, False, None, False])
check('fixture 9', solve({'text': '+12:59', 'probe': 0}), [True, True, 779, False])
check('fixture 10', solve({'text': '+12:60', 'probe': 0}), [False, False, None, False])
check('fixture 11', solve({'text': 'x01:00', 'probe': 0}), [False, False, None, False])
check('fixture 12', solve({'text': '+01x00', 'probe': 0}), [False, False, None, False])
check('fixture 13', solve({'text': '+٠١:٠٠', 'probe': 0}), [False, False, None, False])
check('fixture 14', solve({'text': ' Z ', 'probe': 0}), [False, False, None, False])
check('fixture 15', solve({'text': '+10:02', 'probe': 0}), [True, True, 602, False])
variant = [({'text': '+01:30', 'probe': 0}, [True, True, 90, False]), ({'text': '+02:30', 'probe': 0}, [True, True, 150, False]), ({'text': '+03:30', 'probe': 0}, [True, True, 210, False]), ({'text': '+04:30', 'probe': 0}, [True, True, 270, False]), ({'text': '+05:30', 'probe': 0}, [True, True, 330, False])]
check("variant capture", solve(variant[N-1][0]), variant[N-1][1])
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)

prompt:
The decoded time state disagrees with the explicit regression oracle for valid.

Controlled offset lexeme is Z or signed HH:MM with ASCII digits, hour<=14, minute<=59 and hour14 only minute00. Negative zero means unknown local offset and has no numeric UTC offset; positive zero and Z are known UTC. Return accepted, known, signed minute displacement and original negative-zero marker. No timezone database is consulted.

split: open-access


broken_source:
"""Failure Map reference implementation. Python standard library only."""
import json
from fractions import Fraction
N = 1
observations = []
def solve(r):
    text = r['text']
    zulu = text == 'Z'
    shape = len(text) == 6 and text[0] in '+-' and text[3] == ':'
    digits = shape and all('0' <= c <= '9' for c in text[1:3]+text[4:6])
    hour = int(text[1:3]) if digits else 0
    minute = int(text[4:6]) if digits else 0
    range_ok = hour <= 14 and minute <= 59 and (hour != 14 or minute == 0)
    valid = zulu or (digits and range_ok)
    unknown = False
    offset = None if not valid or unknown else (0 if zulu else (-1 if text[0] == '-' else 1) * (hour * 60 + minute))
    return [valid,valid and not unknown,offset,unknown]
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('fixture 1', solve({'text': 'Z', 'probe': 0}), [True, True, 0, False])
check('fixture 2', solve({'text': 'z', 'probe': 0}), [False, False, None, False])
check('fixture 3', solve({'text': 'UTC', 'probe': 0}), [False, False, None, False])
check('fixture 4', solve({'text': '+00:00', 'probe': 0}), [True, True, 0, False])
check('fixture 5', solve({'text': '-00:00', 'probe': 0}), [True, False, None, True])
check('fixture 6', solve({'text': '-05:30', 'probe': 0}), [True, True, -330, False])
check('fixture 7', solve({'text': '+14:00', 'probe': 0}), [True, True, 840, False])
check('fixture 8', solve({'text': '+14:01', 'probe': 0}), [False, False, None, False])
check('fixture 9', solve({'text': '+12:59', 'probe': 0}), [True, True, 779, False])
check('fixture 10', solve({'text': '+12:60', 'probe': 0}), [False, False, None, False])
check('fixture 11', solve({'text': 'x01:00', 'probe': 0}), [False, False, None, False])
check('fixture 12', solve({'text': '+01x00', 'probe': 0}), [False, False, None, False])
check('fixture 13', solve({'text': '+٠١:٠٠', 'probe': 0}), [False, False, None, False])
check('fixture 14', solve({'text': ' Z ', 'probe': 0}), [False, False, None, False])
check('fixture 15', solve({'text': '+10:02', 'probe': 0}), [True, True, 602, False])
variant = [({'text': '+01:30', 'probe': 0}, [True, True, 90, False]), ({'text': '+02:30', 'probe': 0}, [True, True, 150, False]), ({'text': '+03:30', 'probe': 0}, [True, True, 210, False]), ({'text': '+04:30', 'probe': 0}, [True, True, 270, False]), ({'text': '+05:30', 'probe': 0}, [True, True, 330, False])]
check("variant capture", solve(variant[N-1][0]), variant[N-1][1])
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)

source:
"""Failure Map reference implementation. Python standard library only."""
import json
from fractions import Fraction
N = 1
observations = []
def solve(r):
    text = r['text']
    zulu = text == 'Z'
    shape = len(text) == 6 and text[0] in '+-' and text[3] == ':'
    digits = shape and all('0' <= c <= '9' for c in text[1:3]+text[4:6])
    hour = int(text[1:3]) if digits else 0
    minute = int(text[4:6]) if digits else 0
    range_ok = hour <= 14 and minute <= 59 and (hour != 14 or minute == 0)
    valid = zulu or (digits and range_ok)
    unknown = valid and hour == 0 and minute == 0
    offset = None if not valid or unknown else (0 if zulu else (-1 if text[0] == '-' else 1) * (hour * 60 + minute))
    return [valid,valid and not unknown,offset,unknown]
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('fixture 1', solve({'text': 'Z', 'probe': 0}), [True, True, 0, False])
check('fixture 2', solve({'text': 'z', 'probe': 0}), [False, False, None, False])
check('fixture 3', solve({'text': 'UTC', 'probe': 0}), [False, False, None, False])
check('fixture 4', solve({'text': '+00:00', 'probe': 0}), [True, True, 0, False])
check('fixture 5', solve({'text': '-00:00', 'probe': 0}), [True, False, None, True])
check('fixture 6', solve({'text': '-05:30', 'probe': 0}), [True, True, -330, False])
check('fixture 7', solve({'text': '+14:00', 'probe': 0}), [True, True, 840, False])
check('fixture 8', solve({'text': '+14:01', 'probe': 0}), [False, False, None, False])
check('fixture 9', solve({'text': '+12:59', 'probe': 0}), [True, True, 779, False])
check('fixture 10', solve({'text': '+12:60', 'probe': 0}), [False, False, None, False])
check('fixture 11', solve({'text': 'x01:00', 'probe': 0}), [False, False, None, False])
check('fixture 12', solve({'text': '+01x00', 'probe': 0}), [False, False, None, False])
check('fixture 13', solve({'text': '+٠١:٠٠', 'probe': 0}), [False, False, None, False])
check('fixture 14', solve({'text': ' Z ', 'probe': 0}), [False, False, None, False])
check('fixture 15', solve({'text': '+10:02', 'probe': 0}), [True, True, 602, False])
variant = [({'text': '+01:30', 'probe': 0}, [True, True, 90, False]), ({'text': '+02:30', 'probe': 0}, [True, True, 150, False]), ({'text': '+03:30', 'probe': 0}, [True, True, 210, False]), ({'text': '+04:30', 'probe': 0}, [True, True, 270, False]), ({'text': '+05:30', 'probe': 0}, [True, True, 330, False])]
check("variant capture", solve(variant[N-1][0]), variant[N-1][1])
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)

prompt:
The decoded time state disagrees with the explicit regression oracle for unknown.

Controlled offset lexeme is Z or signed HH:MM with ASCII digits, hour<=14, minute<=59 and hour14 only minute00. Negative zero means unknown local offset and has no numeric UTC offset; positive zero and Z are known UTC. Return accepted, known, signed minute displacement and original negative-zero marker. No timezone database is consulted.

split: open-access


broken_source:
"""Failure Map reference implementation. Python standard library only."""
import json
from fractions import Fraction
N = 1
observations = []
def solve(r):
    text = r['text']
    zulu = text == 'Z'
    shape = len(text) == 6 and text[0] in '+-' and text[3] == ':'
    digits = shape and all('0' <= c <= '9' for c in text[1:3]+text[4:6])
    hour = int(text[1:3]) if digits else 0
    minute = int(text[4:6]) if digits else 0
    range_ok = hour <= 14 and minute <= 59 and (hour != 14 or minute == 0)
    valid = zulu or (digits and range_ok)
    unknown = valid and text == '-00:00'
    offset = None if not valid or unknown else (hour * 60 + minute)
    return [valid,valid and not unknown,offset,unknown]
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('fixture 1', solve({'text': 'Z', 'probe': 0}), [True, True, 0, False])
check('fixture 2', solve({'text': 'z', 'probe': 0}), [False, False, None, False])
check('fixture 3', solve({'text': 'UTC', 'probe': 0}), [False, False, None, False])
check('fixture 4', solve({'text': '+00:00', 'probe': 0}), [True, True, 0, False])
check('fixture 5', solve({'text': '-00:00', 'probe': 0}), [True, False, None, True])
check('fixture 6', solve({'text': '-05:30', 'probe': 0}), [True, True, -330, False])
check('fixture 7', solve({'text': '+14:00', 'probe': 0}), [True, True, 840, False])
check('fixture 8', solve({'text': '+14:01', 'probe': 0}), [False, False, None, False])
check('fixture 9', solve({'text': '+12:59', 'probe': 0}), [True, True, 779, False])
check('fixture 10', solve({'text': '+12:60', 'probe': 0}), [False, False, None, False])
check('fixture 11', solve({'text': 'x01:00', 'probe': 0}), [False, False, None, False])
check('fixture 12', solve({'text': '+01x00', 'probe': 0}), [False, False, None, False])
check('fixture 13', solve({'text': '+٠١:٠٠', 'probe': 0}), [False, False, None, False])
check('fixture 14', solve({'text': ' Z ', 'probe': 0}), [False, False, None, False])
check('fixture 15', solve({'text': '+10:02', 'probe': 0}), [True, True, 602, False])
variant = [({'text': '+01:30', 'probe': 0}, [True, True, 90, False]), ({'text': '+02:30', 'probe': 0}, [True, True, 150, False]), ({'text': '+03:30', 'probe': 0}, [True, True, 210, False]), ({'text': '+04:30', 'probe': 0}, [True, True, 270, False]), ({'text': '+05:30', 'probe': 0}, [True, True, 330, False])]
check("variant capture", solve(variant[N-1][0]), variant[N-1][1])
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)

source:
"""Failure Map reference implementation. Python standard library only."""
import json
from fractions import Fraction
N = 1
observations = []
def solve(r):
    text = r['text']
    zulu = text == 'Z'
    shape = len(text) == 6 and text[0] in '+-' and text[3] == ':'
    digits = shape and all('0' <= c <= '9' for c in text[1:3]+text[4:6])
    hour = int(text[1:3]) if digits else 0
    minute = int(text[4:6]) if digits else 0
    range_ok = hour <= 14 and minute <= 59 and (hour != 14 or minute == 0)
    valid = zulu or (digits and range_ok)
    unknown = valid and text == '-00:00'
    offset = None if not valid or unknown else (0 if zulu else (-hour * 60 + minute if text[0] == '-' else hour * 60 + minute))
    return [valid,valid and not unknown,offset,unknown]
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('fixture 1', solve({'text': 'Z', 'probe': 0}), [True, True, 0, False])
check('fixture 2', solve({'text': 'z', 'probe': 0}), [False, False, None, False])
check('fixture 3', solve({'text': 'UTC', 'probe': 0}), [False, False, None, False])
check('fixture 4', solve({'text': '+00:00', 'probe': 0}), [True, True, 0, False])
check('fixture 5', solve({'text': '-00:00', 'probe': 0}), [True, False, None, True])
check('fixture 6', solve({'text': '-05:30', 'probe': 0}), [True, True, -330, False])
check('fixture 7', solve({'text': '+14:00', 'probe': 0}), [True, True, 840, False])
check('fixture 8', solve({'text': '+14:01', 'probe': 0}), [False, False, None, False])
check('fixture 9', solve({'text': '+12:59', 'probe': 0}), [True, True, 779, False])
check('fixture 10', solve({'text': '+12:60', 'probe': 0}), [False, False, None, False])
check('fixture 11', solve({'text': 'x01:00', 'probe': 0}), [False, False, None, False])
check('fixture 12', solve({'text': '+01x00', 'probe': 0}), [False, False, None, False])
check('fixture 13', solve({'text': '+٠١:٠٠', 'probe': 0}), [False, False, None, False])
check('fixture 14', solve({'text': ' Z ', 'probe': 0}), [False, False, None, False])
check('fixture 15', solve({'text': '+10:02', 'probe': 0}), [True, True, 602, False])
variant = [({'text': '+01:30', 'probe': 0}, [True, True, 90, False]), ({'text': '+02:30', 'probe': 0}, [True, True, 150, False]), ({'text': '+03:30', 'probe': 0}, [True, True, 210, False]), ({'text': '+04:30', 'probe': 0}, [True, True, 270, False]), ({'text': '+05:30', 'probe': 0}, [True, True, 330, False])]
check("variant capture", solve(variant[N-1][0]), variant[N-1][1])
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)

prompt:
The decoded time state disagrees with the explicit regression oracle for offset.

Controlled offset lexeme is Z or signed HH:MM with ASCII digits, hour<=14, minute<=59 and hour14 only minute00. Negative zero means unknown local offset and has no numeric UTC offset; positive zero and Z are known UTC. Return accepted, known, signed minute displacement and original negative-zero marker. No timezone database is consulted.

split: open-access


broken_source:
"""Failure Map reference implementation. Python standard library only."""
import json
from fractions import Fraction
N = 1
observations = []
def solve(r):
    first_span = r['switch']
    first_rate = Fraction(r['p0'],r['q0'])
    second_rate = Fraction(r['p1'],r['q1'])
    join = r['anchor'] + first_span * first_rate
    second = r['reading'] >= r['switch']
    delta = r['reading'] - (r['switch'] if second else r['mono_origin'])
    active = second_rate if second else first_rate
    coordinate = (join if second else r['anchor']) + delta * active
    until = r['target'] - coordinate
    inverse = r['switch'] + (r['target'] - join) / second_rate
    return [str(coordinate),str(active),str(join),str(until),str(inverse)]
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('fixture 1', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 5, 'target': 130}), ['185/2', '3/2', '115', '75/2', '85/2'])
check('fixture 2', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 10, 'target': 130}), ['100', '3/2', '115', '30', '85/2'])
check('fixture 3', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 19, 'target': 130}), ['227/2', '3/2', '115', '33/2', '85/2'])
check('fixture 4', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 20, 'target': 130}), ['115', '2/3', '115', '15', '85/2'])
check('fixture 5', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 21, 'target': 130}), ['347/3', '2/3', '115', '43/3', '85/2'])
check('fixture 6', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 30, 'target': 130}), ['365/3', '2/3', '115', '25/3', '85/2'])
check('fixture 7', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 50, 'target': 120}), ['135', '2/3', '115', '-15', '55/2'])
check('fixture 8', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 25, 'target': 115}), ['355/3', '2/3', '115', '-10/3', '20'])
check('fixture 9', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 15, 'target': 116}), ['215/2', '3/2', '115', '17/2', '43/2'])
check('fixture 10', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 100, 'target': 130}), ['505/3', '2/3', '115', '-115/3', '85/2'])
variant = [({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 6, 'target': 130}, ['94', '3/2', '115', '36', '85/2']), ({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 7, 'target': 130}, ['191/2', '3/2', '115', '69/2', '85/2']), ({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 8, 'target': 130}, ['97', '3/2', '115', '33', '85/2']), ({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 9, 'target': 130}, ['197/2', '3/2', '115', '63/2', '85/2']), ({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 10, 'target': 130}, ['100', '3/2', '115', '30', '85/2'])]
check("variant capture", solve(variant[N-1][0]), variant[N-1][1])
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)

source:
"""Failure Map reference implementation. Python standard library only."""
import json
from fractions import Fraction
N = 1
observations = []
def solve(r):
    first_span = r['switch'] - r['reading']
    first_rate = Fraction(r['p0'],r['q0'])
    second_rate = Fraction(r['p1'],r['q1'])
    join = r['anchor'] + first_span * first_rate
    second = r['reading'] >= r['switch']
    delta = r['reading'] - (r['switch'] if second else r['mono_origin'])
    active = second_rate if second else first_rate
    coordinate = (join if second else r['anchor']) + delta * active
    until = r['target'] - coordinate
    inverse = r['switch'] + (r['target'] - join) / second_rate
    return [str(coordinate),str(active),str(join),str(until),str(inverse)]
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('fixture 1', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 5, 'target': 130}), ['185/2', '3/2', '115', '75/2', '85/2'])
check('fixture 2', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 10, 'target': 130}), ['100', '3/2', '115', '30', '85/2'])
check('fixture 3', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 19, 'target': 130}), ['227/2', '3/2', '115', '33/2', '85/2'])
check('fixture 4', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 20, 'target': 130}), ['115', '2/3', '115', '15', '85/2'])
check('fixture 5', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 21, 'target': 130}), ['347/3', '2/3', '115', '43/3', '85/2'])
check('fixture 6', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 30, 'target': 130}), ['365/3', '2/3', '115', '25/3', '85/2'])
check('fixture 7', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 50, 'target': 120}), ['135', '2/3', '115', '-15', '55/2'])
check('fixture 8', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 25, 'target': 115}), ['355/3', '2/3', '115', '-10/3', '20'])
check('fixture 9', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 15, 'target': 116}), ['215/2', '3/2', '115', '17/2', '43/2'])
check('fixture 10', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 100, 'target': 130}), ['505/3', '2/3', '115', '-115/3', '85/2'])
variant = [({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 6, 'target': 130}, ['94', '3/2', '115', '36', '85/2']), ({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 7, 'target': 130}, ['191/2', '3/2', '115', '69/2', '85/2']), ({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 8, 'target': 130}, ['97', '3/2', '115', '33', '85/2']), ({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 9, 'target': 130}, ['197/2', '3/2', '115', '63/2', '85/2']), ({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 10, 'target': 130}, ['100', '3/2', '115', '30', '85/2'])]
check("variant capture", solve(variant[N-1][0]), variant[N-1][1])
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)

prompt:
The decoded time state disagrees with the explicit regression oracle for first_span.

Virtual clock has anchor A at monotonic M0, rate p0/q0 until switch S, then p1/q1 thereafter. Readings may precede M0 and use first rate. The switch is continuous. Report exact coordinate, active rate, continuity anchor, next target delta and inverse monotonic coordinate for a target at or after switch. All rates positive.

split: open-access


broken_source:
"""Failure Map reference implementation. Python standard library only."""
import json
from fractions import Fraction
N = 1
observations = []
def solve(r):
    first_span = r['switch'] - r['mono_origin']
    first_rate = Fraction(r['q0'],r['p0'])
    second_rate = Fraction(r['p1'],r['q1'])
    join = r['anchor'] + first_span * first_rate
    second = r['reading'] >= r['switch']
    delta = r['reading'] - (r['switch'] if second else r['mono_origin'])
    active = second_rate if second else first_rate
    coordinate = (join if second else r['anchor']) + delta * active
    until = r['target'] - coordinate
    inverse = r['switch'] + (r['target'] - join) / second_rate
    return [str(coordinate),str(active),str(join),str(until),str(inverse)]
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('fixture 1', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 5, 'target': 130}), ['185/2', '3/2', '115', '75/2', '85/2'])
check('fixture 2', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 10, 'target': 130}), ['100', '3/2', '115', '30', '85/2'])
check('fixture 3', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 19, 'target': 130}), ['227/2', '3/2', '115', '33/2', '85/2'])
check('fixture 4', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 20, 'target': 130}), ['115', '2/3', '115', '15', '85/2'])
check('fixture 5', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 21, 'target': 130}), ['347/3', '2/3', '115', '43/3', '85/2'])
check('fixture 6', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 30, 'target': 130}), ['365/3', '2/3', '115', '25/3', '85/2'])
check('fixture 7', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 50, 'target': 120}), ['135', '2/3', '115', '-15', '55/2'])
check('fixture 8', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 25, 'target': 115}), ['355/3', '2/3', '115', '-10/3', '20'])
check('fixture 9', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 15, 'target': 116}), ['215/2', '3/2', '115', '17/2', '43/2'])
check('fixture 10', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 100, 'target': 130}), ['505/3', '2/3', '115', '-115/3', '85/2'])
variant = [({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 6, 'target': 130}, ['94', '3/2', '115', '36', '85/2']), ({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 7, 'target': 130}, ['191/2', '3/2', '115', '69/2', '85/2']), ({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 8, 'target': 130}, ['97', '3/2', '115', '33', '85/2']), ({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 9, 'target': 130}, ['197/2', '3/2', '115', '63/2', '85/2']), ({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 10, 'target': 130}, ['100', '3/2', '115', '30', '85/2'])]
check("variant capture", solve(variant[N-1][0]), variant[N-1][1])
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)

source:
"""Failure Map reference implementation. Python standard library only."""
import json
from fractions import Fraction
N = 1
observations = []
def solve(r):
    first_span = r['switch'] - r['mono_origin']
    first_rate = Fraction(r['p0']//r['q0'])
    second_rate = Fraction(r['p1'],r['q1'])
    join = r['anchor'] + first_span * first_rate
    second = r['reading'] >= r['switch']
    delta = r['reading'] - (r['switch'] if second else r['mono_origin'])
    active = second_rate if second else first_rate
    coordinate = (join if second else r['anchor']) + delta * active
    until = r['target'] - coordinate
    inverse = r['switch'] + (r['target'] - join) / second_rate
    return [str(coordinate),str(active),str(join),str(until),str(inverse)]
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('fixture 1', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 5, 'target': 130}), ['185/2', '3/2', '115', '75/2', '85/2'])
check('fixture 2', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 10, 'target': 130}), ['100', '3/2', '115', '30', '85/2'])
check('fixture 3', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 19, 'target': 130}), ['227/2', '3/2', '115', '33/2', '85/2'])
check('fixture 4', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 20, 'target': 130}), ['115', '2/3', '115', '15', '85/2'])
check('fixture 5', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 21, 'target': 130}), ['347/3', '2/3', '115', '43/3', '85/2'])
check('fixture 6', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 30, 'target': 130}), ['365/3', '2/3', '115', '25/3', '85/2'])
check('fixture 7', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 50, 'target': 120}), ['135', '2/3', '115', '-15', '55/2'])
check('fixture 8', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 25, 'target': 115}), ['355/3', '2/3', '115', '-10/3', '20'])
check('fixture 9', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 15, 'target': 116}), ['215/2', '3/2', '115', '17/2', '43/2'])
check('fixture 10', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 100, 'target': 130}), ['505/3', '2/3', '115', '-115/3', '85/2'])
variant = [({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 6, 'target': 130}, ['94', '3/2', '115', '36', '85/2']), ({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 7, 'target': 130}, ['191/2', '3/2', '115', '69/2', '85/2']), ({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 8, 'target': 130}, ['97', '3/2', '115', '33', '85/2']), ({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 9, 'target': 130}, ['197/2', '3/2', '115', '63/2', '85/2']), ({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 10, 'target': 130}, ['100', '3/2', '115', '30', '85/2'])]
check("variant capture", solve(variant[N-1][0]), variant[N-1][1])
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)

prompt:
The decoded time state disagrees with the explicit regression oracle for first_rate.

Virtual clock has anchor A at monotonic M0, rate p0/q0 until switch S, then p1/q1 thereafter. Readings may precede M0 and use first rate. The switch is continuous. Report exact coordinate, active rate, continuity anchor, next target delta and inverse monotonic coordinate for a target at or after switch. All rates positive.

split: open-access


broken_source:
"""Failure Map reference implementation. Python standard library only."""
import json
from fractions import Fraction
N = 1
observations = []
def solve(r):
    first_span = r['switch'] - r['mono_origin']
    first_rate = Fraction(r['p0'],r['q0'])
    second_rate = Fraction(r['p0'],r['q0'])
    join = r['anchor'] + first_span * first_rate
    second = r['reading'] >= r['switch']
    delta = r['reading'] - (r['switch'] if second else r['mono_origin'])
    active = second_rate if second else first_rate
    coordinate = (join if second else r['anchor']) + delta * active
    until = r['target'] - coordinate
    inverse = r['switch'] + (r['target'] - join) / second_rate
    return [str(coordinate),str(active),str(join),str(until),str(inverse)]
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('fixture 1', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 5, 'target': 130}), ['185/2', '3/2', '115', '75/2', '85/2'])
check('fixture 2', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 10, 'target': 130}), ['100', '3/2', '115', '30', '85/2'])
check('fixture 3', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 19, 'target': 130}), ['227/2', '3/2', '115', '33/2', '85/2'])
check('fixture 4', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 20, 'target': 130}), ['115', '2/3', '115', '15', '85/2'])
check('fixture 5', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 21, 'target': 130}), ['347/3', '2/3', '115', '43/3', '85/2'])
check('fixture 6', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 30, 'target': 130}), ['365/3', '2/3', '115', '25/3', '85/2'])
check('fixture 7', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 50, 'target': 120}), ['135', '2/3', '115', '-15', '55/2'])
check('fixture 8', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 25, 'target': 115}), ['355/3', '2/3', '115', '-10/3', '20'])
check('fixture 9', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 15, 'target': 116}), ['215/2', '3/2', '115', '17/2', '43/2'])
check('fixture 10', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 100, 'target': 130}), ['505/3', '2/3', '115', '-115/3', '85/2'])
variant = [({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 6, 'target': 130}, ['94', '3/2', '115', '36', '85/2']), ({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 7, 'target': 130}, ['191/2', '3/2', '115', '69/2', '85/2']), ({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 8, 'target': 130}, ['97', '3/2', '115', '33', '85/2']), ({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 9, 'target': 130}, ['197/2', '3/2', '115', '63/2', '85/2']), ({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 10, 'target': 130}, ['100', '3/2', '115', '30', '85/2'])]
check("variant capture", solve(variant[N-1][0]), variant[N-1][1])
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)

source:
"""Failure Map reference implementation. Python standard library only."""
import json
from fractions import Fraction
N = 1
observations = []
def solve(r):
    first_span = r['switch'] - r['mono_origin']
    first_rate = Fraction(r['p0'],r['q0'])
    second_rate = Fraction(r['q1'],r['p1'])
    join = r['anchor'] + first_span * first_rate
    second = r['reading'] >= r['switch']
    delta = r['reading'] - (r['switch'] if second else r['mono_origin'])
    active = second_rate if second else first_rate
    coordinate = (join if second else r['anchor']) + delta * active
    until = r['target'] - coordinate
    inverse = r['switch'] + (r['target'] - join) / second_rate
    return [str(coordinate),str(active),str(join),str(until),str(inverse)]
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('fixture 1', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 5, 'target': 130}), ['185/2', '3/2', '115', '75/2', '85/2'])
check('fixture 2', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 10, 'target': 130}), ['100', '3/2', '115', '30', '85/2'])
check('fixture 3', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 19, 'target': 130}), ['227/2', '3/2', '115', '33/2', '85/2'])
check('fixture 4', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 20, 'target': 130}), ['115', '2/3', '115', '15', '85/2'])
check('fixture 5', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 21, 'target': 130}), ['347/3', '2/3', '115', '43/3', '85/2'])
check('fixture 6', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 30, 'target': 130}), ['365/3', '2/3', '115', '25/3', '85/2'])
check('fixture 7', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 50, 'target': 120}), ['135', '2/3', '115', '-15', '55/2'])
check('fixture 8', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 25, 'target': 115}), ['355/3', '2/3', '115', '-10/3', '20'])
check('fixture 9', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 15, 'target': 116}), ['215/2', '3/2', '115', '17/2', '43/2'])
check('fixture 10', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 100, 'target': 130}), ['505/3', '2/3', '115', '-115/3', '85/2'])
variant = [({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 6, 'target': 130}, ['94', '3/2', '115', '36', '85/2']), ({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 7, 'target': 130}, ['191/2', '3/2', '115', '69/2', '85/2']), ({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 8, 'target': 130}, ['97', '3/2', '115', '33', '85/2']), ({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 9, 'target': 130}, ['197/2', '3/2', '115', '63/2', '85/2']), ({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 10, 'target': 130}, ['100', '3/2', '115', '30', '85/2'])]
check("variant capture", solve(variant[N-1][0]), variant[N-1][1])
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)

prompt:
The decoded time state disagrees with the explicit regression oracle for second_rate.

Virtual clock has anchor A at monotonic M0, rate p0/q0 until switch S, then p1/q1 thereafter. Readings may precede M0 and use first rate. The switch is continuous. Report exact coordinate, active rate, continuity anchor, next target delta and inverse monotonic coordinate for a target at or after switch. All rates positive.

split: open-access


broken_source:
"""Failure Map reference implementation. Python standard library only."""
import json
from fractions import Fraction
N = 1
observations = []
def solve(r):
    first_span = r['switch'] - r['mono_origin']
    first_rate = Fraction(r['p0'],r['q0'])
    second_rate = Fraction(r['p1'],r['q1'])
    join = r['anchor'] + first_span * second_rate
    second = r['reading'] >= r['switch']
    delta = r['reading'] - (r['switch'] if second else r['mono_origin'])
    active = second_rate if second else first_rate
    coordinate = (join if second else r['anchor']) + delta * active
    until = r['target'] - coordinate
    inverse = r['switch'] + (r['target'] - join) / second_rate
    return [str(coordinate),str(active),str(join),str(until),str(inverse)]
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('fixture 1', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 5, 'target': 130}), ['185/2', '3/2', '115', '75/2', '85/2'])
check('fixture 2', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 10, 'target': 130}), ['100', '3/2', '115', '30', '85/2'])
check('fixture 3', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 19, 'target': 130}), ['227/2', '3/2', '115', '33/2', '85/2'])
check('fixture 4', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 20, 'target': 130}), ['115', '2/3', '115', '15', '85/2'])
check('fixture 5', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 21, 'target': 130}), ['347/3', '2/3', '115', '43/3', '85/2'])
check('fixture 6', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 30, 'target': 130}), ['365/3', '2/3', '115', '25/3', '85/2'])
check('fixture 7', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 50, 'target': 120}), ['135', '2/3', '115', '-15', '55/2'])
check('fixture 8', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 25, 'target': 115}), ['355/3', '2/3', '115', '-10/3', '20'])
check('fixture 9', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 15, 'target': 116}), ['215/2', '3/2', '115', '17/2', '43/2'])
check('fixture 10', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 100, 'target': 130}), ['505/3', '2/3', '115', '-115/3', '85/2'])
variant = [({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 6, 'target': 130}, ['94', '3/2', '115', '36', '85/2']), ({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 7, 'target': 130}, ['191/2', '3/2', '115', '69/2', '85/2']), ({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 8, 'target': 130}, ['97', '3/2', '115', '33', '85/2']), ({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 9, 'target': 130}, ['197/2', '3/2', '115', '63/2', '85/2']), ({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 10, 'target': 130}, ['100', '3/2', '115', '30', '85/2'])]
check("variant capture", solve(variant[N-1][0]), variant[N-1][1])
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)

source:
"""Failure Map reference implementation. Python standard library only."""
import json
from fractions import Fraction
N = 1
observations = []
def solve(r):
    first_span = r['switch'] - r['mono_origin']
    first_rate = Fraction(r['p0'],r['q0'])
    second_rate = Fraction(r['p1'],r['q1'])
    join = r['anchor']
    second = r['reading'] >= r['switch']
    delta = r['reading'] - (r['switch'] if second else r['mono_origin'])
    active = second_rate if second else first_rate
    coordinate = (join if second else r['anchor']) + delta * active
    until = r['target'] - coordinate
    inverse = r['switch'] + (r['target'] - join) / second_rate
    return [str(coordinate),str(active),str(join),str(until),str(inverse)]
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('fixture 1', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 5, 'target': 130}), ['185/2', '3/2', '115', '75/2', '85/2'])
check('fixture 2', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 10, 'target': 130}), ['100', '3/2', '115', '30', '85/2'])
check('fixture 3', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 19, 'target': 130}), ['227/2', '3/2', '115', '33/2', '85/2'])
check('fixture 4', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 20, 'target': 130}), ['115', '2/3', '115', '15', '85/2'])
check('fixture 5', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 21, 'target': 130}), ['347/3', '2/3', '115', '43/3', '85/2'])
check('fixture 6', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 30, 'target': 130}), ['365/3', '2/3', '115', '25/3', '85/2'])
check('fixture 7', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 50, 'target': 120}), ['135', '2/3', '115', '-15', '55/2'])
check('fixture 8', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 25, 'target': 115}), ['355/3', '2/3', '115', '-10/3', '20'])
check('fixture 9', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 15, 'target': 116}), ['215/2', '3/2', '115', '17/2', '43/2'])
check('fixture 10', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 100, 'target': 130}), ['505/3', '2/3', '115', '-115/3', '85/2'])
variant = [({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 6, 'target': 130}, ['94', '3/2', '115', '36', '85/2']), ({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 7, 'target': 130}, ['191/2', '3/2', '115', '69/2', '85/2']), ({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 8, 'target': 130}, ['97', '3/2', '115', '33', '85/2']), ({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 9, 'target': 130}, ['197/2', '3/2', '115', '63/2', '85/2']), ({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 10, 'target': 130}, ['100', '3/2', '115', '30', '85/2'])]
check("variant capture", solve(variant[N-1][0]), variant[N-1][1])
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)

prompt:
The decoded time state disagrees with the explicit regression oracle for join.

Virtual clock has anchor A at monotonic M0, rate p0/q0 until switch S, then p1/q1 thereafter. Readings may precede M0 and use first rate. The switch is continuous. Report exact coordinate, active rate, continuity anchor, next target delta and inverse monotonic coordinate for a target at or after switch. All rates positive.

split: open-access


broken_source:
"""Failure Map reference implementation. Python standard library only."""
import json
from fractions import Fraction
N = 1
observations = []
def solve(r):
    first_span = r['switch'] - r['mono_origin']
    first_rate = Fraction(r['p0'],r['q0'])
    second_rate = Fraction(r['p1'],r['q1'])
    join = r['anchor'] + first_span * first_rate
    second = r['reading'] > r['switch']
    delta = r['reading'] - (r['switch'] if second else r['mono_origin'])
    active = second_rate if second else first_rate
    coordinate = (join if second else r['anchor']) + delta * active
    until = r['target'] - coordinate
    inverse = r['switch'] + (r['target'] - join) / second_rate
    return [str(coordinate),str(active),str(join),str(until),str(inverse)]
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('fixture 1', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 5, 'target': 130}), ['185/2', '3/2', '115', '75/2', '85/2'])
check('fixture 2', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 10, 'target': 130}), ['100', '3/2', '115', '30', '85/2'])
check('fixture 3', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 19, 'target': 130}), ['227/2', '3/2', '115', '33/2', '85/2'])
check('fixture 4', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 20, 'target': 130}), ['115', '2/3', '115', '15', '85/2'])
check('fixture 5', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 21, 'target': 130}), ['347/3', '2/3', '115', '43/3', '85/2'])
check('fixture 6', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 30, 'target': 130}), ['365/3', '2/3', '115', '25/3', '85/2'])
check('fixture 7', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 50, 'target': 120}), ['135', '2/3', '115', '-15', '55/2'])
check('fixture 8', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 25, 'target': 115}), ['355/3', '2/3', '115', '-10/3', '20'])
check('fixture 9', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 15, 'target': 116}), ['215/2', '3/2', '115', '17/2', '43/2'])
check('fixture 10', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 100, 'target': 130}), ['505/3', '2/3', '115', '-115/3', '85/2'])
variant = [({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 6, 'target': 130}, ['94', '3/2', '115', '36', '85/2']), ({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 7, 'target': 130}, ['191/2', '3/2', '115', '69/2', '85/2']), ({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 8, 'target': 130}, ['97', '3/2', '115', '33', '85/2']), ({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 9, 'target': 130}, ['197/2', '3/2', '115', '63/2', '85/2']), ({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 10, 'target': 130}, ['100', '3/2', '115', '30', '85/2'])]
check("variant capture", solve(variant[N-1][0]), variant[N-1][1])
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)

source:
"""Failure Map reference implementation. Python standard library only."""
import json
from fractions import Fraction
N = 1
observations = []
def solve(r):
    first_span = r['switch'] - r['mono_origin']
    first_rate = Fraction(r['p0'],r['q0'])
    second_rate = Fraction(r['p1'],r['q1'])
    join = r['anchor'] + first_span * first_rate
    second = True
    delta = r['reading'] - (r['switch'] if second else r['mono_origin'])
    active = second_rate if second else first_rate
    coordinate = (join if second else r['anchor']) + delta * active
    until = r['target'] - coordinate
    inverse = r['switch'] + (r['target'] - join) / second_rate
    return [str(coordinate),str(active),str(join),str(until),str(inverse)]
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('fixture 1', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 5, 'target': 130}), ['185/2', '3/2', '115', '75/2', '85/2'])
check('fixture 2', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 10, 'target': 130}), ['100', '3/2', '115', '30', '85/2'])
check('fixture 3', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 19, 'target': 130}), ['227/2', '3/2', '115', '33/2', '85/2'])
check('fixture 4', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 20, 'target': 130}), ['115', '2/3', '115', '15', '85/2'])
check('fixture 5', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 21, 'target': 130}), ['347/3', '2/3', '115', '43/3', '85/2'])
check('fixture 6', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 30, 'target': 130}), ['365/3', '2/3', '115', '25/3', '85/2'])
check('fixture 7', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 50, 'target': 120}), ['135', '2/3', '115', '-15', '55/2'])
check('fixture 8', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 25, 'target': 115}), ['355/3', '2/3', '115', '-10/3', '20'])
check('fixture 9', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 15, 'target': 116}), ['215/2', '3/2', '115', '17/2', '43/2'])
check('fixture 10', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 100, 'target': 130}), ['505/3', '2/3', '115', '-115/3', '85/2'])
variant = [({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 6, 'target': 130}, ['94', '3/2', '115', '36', '85/2']), ({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 7, 'target': 130}, ['191/2', '3/2', '115', '69/2', '85/2']), ({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 8, 'target': 130}, ['97', '3/2', '115', '33', '85/2']), ({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 9, 'target': 130}, ['197/2', '3/2', '115', '63/2', '85/2']), ({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 10, 'target': 130}, ['100', '3/2', '115', '30', '85/2'])]
check("variant capture", solve(variant[N-1][0]), variant[N-1][1])
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)

prompt:
The decoded time state disagrees with the explicit regression oracle for second.

Virtual clock has anchor A at monotonic M0, rate p0/q0 until switch S, then p1/q1 thereafter. Readings may precede M0 and use first rate. The switch is continuous. Report exact coordinate, active rate, continuity anchor, next target delta and inverse monotonic coordinate for a target at or after switch. All rates positive.

split: open-access


broken_source:
"""Failure Map reference implementation. Python standard library only."""
import json
from fractions import Fraction
N = 1
observations = []
def solve(r):
    first_span = r['switch'] - r['mono_origin']
    first_rate = Fraction(r['p0'],r['q0'])
    second_rate = Fraction(r['p1'],r['q1'])
    join = r['anchor'] + first_span * first_rate
    second = r['reading'] >= r['switch']
    delta = r['reading'] - r['mono_origin']
    active = second_rate if second else first_rate
    coordinate = (join if second else r['anchor']) + delta * active
    until = r['target'] - coordinate
    inverse = r['switch'] + (r['target'] - join) / second_rate
    return [str(coordinate),str(active),str(join),str(until),str(inverse)]
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('fixture 1', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 5, 'target': 130}), ['185/2', '3/2', '115', '75/2', '85/2'])
check('fixture 2', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 10, 'target': 130}), ['100', '3/2', '115', '30', '85/2'])
check('fixture 3', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 19, 'target': 130}), ['227/2', '3/2', '115', '33/2', '85/2'])
check('fixture 4', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 20, 'target': 130}), ['115', '2/3', '115', '15', '85/2'])
check('fixture 5', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 21, 'target': 130}), ['347/3', '2/3', '115', '43/3', '85/2'])
check('fixture 6', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 30, 'target': 130}), ['365/3', '2/3', '115', '25/3', '85/2'])
check('fixture 7', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 50, 'target': 120}), ['135', '2/3', '115', '-15', '55/2'])
check('fixture 8', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 25, 'target': 115}), ['355/3', '2/3', '115', '-10/3', '20'])
check('fixture 9', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 15, 'target': 116}), ['215/2', '3/2', '115', '17/2', '43/2'])
check('fixture 10', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 100, 'target': 130}), ['505/3', '2/3', '115', '-115/3', '85/2'])
variant = [({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 6, 'target': 130}, ['94', '3/2', '115', '36', '85/2']), ({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 7, 'target': 130}, ['191/2', '3/2', '115', '69/2', '85/2']), ({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 8, 'target': 130}, ['97', '3/2', '115', '33', '85/2']), ({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 9, 'target': 130}, ['197/2', '3/2', '115', '63/2', '85/2']), ({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 10, 'target': 130}, ['100', '3/2', '115', '30', '85/2'])]
check("variant capture", solve(variant[N-1][0]), variant[N-1][1])
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)

source:
"""Failure Map reference implementation. Python standard library only."""
import json
from fractions import Fraction
N = 1
observations = []
def solve(r):
    first_span = r['switch'] - r['mono_origin']
    first_rate = Fraction(r['p0'],r['q0'])
    second_rate = Fraction(r['p1'],r['q1'])
    join = r['anchor'] + first_span * first_rate
    second = r['reading'] >= r['switch']
    delta = r['reading'] - r['switch']
    active = second_rate if second else first_rate
    coordinate = (join if second else r['anchor']) + delta * active
    until = r['target'] - coordinate
    inverse = r['switch'] + (r['target'] - join) / second_rate
    return [str(coordinate),str(active),str(join),str(until),str(inverse)]
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('fixture 1', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 5, 'target': 130}), ['185/2', '3/2', '115', '75/2', '85/2'])
check('fixture 2', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 10, 'target': 130}), ['100', '3/2', '115', '30', '85/2'])
check('fixture 3', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 19, 'target': 130}), ['227/2', '3/2', '115', '33/2', '85/2'])
check('fixture 4', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 20, 'target': 130}), ['115', '2/3', '115', '15', '85/2'])
check('fixture 5', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 21, 'target': 130}), ['347/3', '2/3', '115', '43/3', '85/2'])
check('fixture 6', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 30, 'target': 130}), ['365/3', '2/3', '115', '25/3', '85/2'])
check('fixture 7', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 50, 'target': 120}), ['135', '2/3', '115', '-15', '55/2'])
check('fixture 8', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 25, 'target': 115}), ['355/3', '2/3', '115', '-10/3', '20'])
check('fixture 9', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 15, 'target': 116}), ['215/2', '3/2', '115', '17/2', '43/2'])
check('fixture 10', solve({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 100, 'target': 130}), ['505/3', '2/3', '115', '-115/3', '85/2'])
variant = [({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 6, 'target': 130}, ['94', '3/2', '115', '36', '85/2']), ({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 7, 'target': 130}, ['191/2', '3/2', '115', '69/2', '85/2']), ({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 8, 'target': 130}, ['97', '3/2', '115', '33', '85/2']), ({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 9, 'target': 130}, ['197/2', '3/2', '115', '63/2', '85/2']), ({'mono_origin': 10, 'anchor': 100, 'switch': 20, 'p0': 3, 'q0': 2, 'p1': 2, 'q1': 3, 'reading': 10, 'target': 130}, ['100', '3/2', '115', '30', '85/2'])]
check("variant capture", solve(variant[N-1][0]), variant[N-1][1])
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)

prompt:
The decoded time state disagrees with the explicit regression oracle for delta.

Virtual clock has anchor A at monotonic M0, rate p0/q0 until switch S, then p1/q1 thereafter. Readings may precede M0 and use first rate. The switch is continuous. Report exact coordinate, active rate, continuity anchor, next target delta and inverse monotonic coordinate for a target at or after switch. All rates positive.

split: open-access