Interplane page as plain text, for reading tools and agents. English is the reference text: translate it with your own tool. Text in backticks and in ``` blocks (commands, fingerprints, file names) and link targets in <...> are exact: copy them, never translate them. Page: /drakestapleton/interplane-mv/patches/7dfa72f26237beef # interplane-mv INTERPLANE: open interoperability protocol between AI models and agent runtimes. Models express intent. Runtimes retain authority. Brought by drakestapleton Sign in to star 0 stars 0 watching About Files History Releases Proposed changes Issues For developers ## GitHub aien-dev/interplane-mv#69 (code only) closed derived `7dfa72f26237beef` #69 Imported from GitHub aien-dev/interplane-mv#69 (code only) GitHub's metadata for this pull request is unavailable: its state is DERIVED from the commits (merged: the head is reachable from this project's main; open: GitHub kept a merge ref; else closed). Base `204996832b1810673644169716518d42dcda3e0a` · Head `b89caf82cf6d37739297924254cc7e186ebfc0fe` ### Apply it ``` git checkout -b patch-7dfa72f26237beef 204996832b1810673644169716518d42dcda3e0a curl -fsSL https://interplane.io/drakestapleton/interplane-mv/patches/7dfa72f26237beef.patch | git am ``` Raw patch (mbox) · Diff ### Provenance This proposal is imported from GitHub; it is not signed by its author. Its import statement and source record: ``` github-import 1 aien-dev/interplane-mv 69 b89caf82cf6d37739297924254cc7e186ebfc0fe ``` ``` {"kind":"github-import","owner":"aien-dev","repo":"interplane-mv","number":69,"url":"https://github.com/aien-dev/interplane-mv/pull/69","export_sha256":"967c79e26a893657b5cdaa45efd442be5dbd2ecfe68e25f9a8c1b5da4d60d452","imported_utc":"2026-11-18T16:40:10Z","metadata":"unavailable","state_derived":true} ``` ### Changes ``` diff --git a/bench/heldout-0.2y/AUTHORING.md b/bench/heldout-0.2y/AUTHORING.md index 68e2bf2..f14d0fe 100644 --- a/bench/heldout-0.2y/AUTHORING.md +++ b/bench/heldout-0.2y/AUTHORING.md @@ -80,6 +80,13 @@ Rules for every workspace: logs, short letters, configuration, tables written as text). Each file is 5 to 40 lines. - Each workspace contains at least 40 distinct facts that someone could later ask about in a short question: who does something, when, how many, how much, where, which one, what was decided, what the status is. +- The person or team keeps their everyday records in the workspace next to their work files: for example saved + mail, meeting notes, contacts, to-do lists, notes, chat logs, things to remember, documents, notes on images. + Use whichever fit them. +- Give every fact an area: the everyday area of the record that holds it, one of mail, meetings, contacts, + to-dos, notes, chats, models, memory, documents, images, or other when it belongs to none of them. In each + workspace at least 20 facts have one of those ten areas, spread over at least 3 of them, and at least 20 + facts are other. - Every fact appears in exactly one file, once, stated plainly. No fact may be guessable from another file. Add a few look-alike distractors (similar names, older or superseded values) so that reading a wrong file gives a wrong answer. @@ -89,22 +96,29 @@ Rules for every workspace: Answer with one JSON object and nothing else: {"workspaces": [{"slug": "", "description": "", "files": {"": ""}, "facts": [{"fact": "", "file": ""}]}]} +sentence stating it>", "file": "", "area": ""}]}]} +``` -Fact sentences must not contain a path, a file name or a file extension (`authoring_02y.fact_errors` checks; -a failing fixture call is repeated whole, and the failing call stays in the record). +Bookkeeping (not sent to the author; amendment 3 moved it out of the verbatim block, attempt 1's fixture prompt +carried the paragraph below in its pre-amendment form): fact sentences must not contain a path, a file name or a file extension, every fact carries one of the ten areas +or `other`, and each workspace has at least 20 facts on each side and at least 3 distinct areas +(`authoring_02y.fact_errors` checks all of it; a failing fixture call is repeated whole, and the failing call stays +in the record). The area list is the one brief E already names (PREREG-0.2y section 5); the author never sees a +keyword list, a capability name or the selector. Area tags and balance: amendment 3, after attempt 1. "models" +stays in the area list because brief E names it, but the example list above leaves it out, since the brief also +says not to mention models. The 6 workspaces are the number `authoring_02y.workspaces_needed()` returns: both briefs together need 216 facts (2 x (36 + 12 + 24 + 36)) and 6 x 40 = 240. If `pool_check` still reports a shortfall on the returned workspaces, the fixture call is repeated for `extra_workspaces` more workspaces (deterministic, same brief, different invented lines of work), never edited by hand. -``` ### 4.2 Target requests, round 0 (sent once per brief type; same two briefs for the calibration set) Facts are handed over as `id` plus sentence only. The `file` field and every path are removed -(`authoring_02y.facts_for_author`). Brief E sees the facts with an odd serial inside their workspace, brief Q the -facts with an even serial (a deterministic split by fact id, `split_record`, written to -`authoring-inputs/fact-split.json`). The two briefs never share a fact. Facts used by an earlier request of the +(`authoring_02y.facts_for_author`). Brief E sees the facts the fixture author tagged with one of the ten everyday +areas, brief Q the facts tagged `other` (a deterministic split by the author's own tag, never by reading a fact, +`split_record`, written to `authoring-inputs/fact-split.json`; amendment 3 replaced attempt 1's odd/even split). +The two briefs never share a fact. The `area` tag is not shown to the request author. Facts used by an earlier request of the same brief are left out of its later calls. Brief E (everyday work), `{N}` = 36; `{WORKSPACES}` = slug, description and the id-plus-sentence facts of its subset, nothing else: @@ -201,7 +215,15 @@ workspaces only). The first 30 lint-passing requests in id order form the set (s `heldout-0.2y/authoring-log.jsonl`: `{"set": "target"|"calibration", "id": "q-NNNN", "round": 0..3, "brief": "everyday"|"question", "fixture": "", "request": "...", "answer": [...], "template": "...", "codes": [...], "lint": [], "detail": {...}, "group": "nonfile"|"default"|null, - "status": "accepted"|"discarded_lint"|"discarded_surplus"}`. `codes` and `detail` stay out of the author's sight. + "status": "accepted"|"discarded_lint"|"discarded_surplus"|"discarded_over_delivery"|"empty_call"}`. `codes` and `detail` + stay out of the author's sight. + **Over- and under-delivery (amendment 3).** One call asks for a number of requests (36 in round 0, 12, 24, 36 + in rounds 1 to 3). When it returns more, the first ones up to that number, in the author's array order, are + logged and decided; every later one is logged with status `discarded_over_delivery`, is never linted into a + group and never run, and its fact counts as unused for later calls. When it returns fewer, they are logged as + they are and the replay lists the shortfall as a note; the round still counts as one of the three top-ups. A call + that returns nothing is logged as one line with status `empty_call` and an empty request, so its round stays + visible in the log. `validate.py --corpus 0.2y` replays the log in id order and fails on any difference. 3. **Acceptance (section 5).** In id order, a request that passes the lint goes into the group the lint derives (`nonfile` or `default`); each group keeps the first 24 accepted; later passing requests are `discarded_surplus`. @@ -216,8 +238,9 @@ workspaces only). The first 30 lint-passing requests in id order form the set (s ## 6. Deviations from section 5 of the pre-registration -All are listed, each with its reason, in the dated section 11 amendment of the pre-registration (2026-10-05, -written before any task, fixture or request exists). None changes a threshold, arm or sample size. +All are listed, each with its reason, in the dated section 11 amendments of the pre-registration: items 1 to 10 in +amendment 2 (written before any task, fixture or request existed), items 11 to 13 in amendment 3 (written after +attempt 1 stopped short and before attempt 2). None changes a threshold, arm or sample size. 1. **Lint scope.** Applies to `discovery_needed` requests only (target and calibration), not to the 72 regression requests: their categories legitimately name files and tools and the author has no catalog. @@ -236,6 +259,16 @@ written before any task, fixture or request exists). None changes a threshold, a 9. **Fact pool.** Facts are shown as id plus sentence only; briefs E and Q draw disjoint subsets; 6 workspaces of 40 or more facts; `pool_check` enlarges the pool deterministically if base requests plus maximum top-ups do not fit. 10. **Calibration pooling.** The 30 calibration tasks use one pool, any group, the same lint. +11. **Area-tagged facts (amendment 3).** The fixture author tags each fact with one of the ten everyday areas of + brief E or `other`, with at least 20 on each side and 3 distinct areas per workspace; brief E draws the tagged + facts and brief Q the `other` facts, replacing the odd/even split. Reason: in attempt 1 every fact was a fact + about a workshop's own files, so the everyday-work brief had nothing from mail, meetings or notes to ask + about (6 of 89 lint-passing everyday requests derived a non-file domain). +12. **Over- and under-delivery (amendment 3).** Requests beyond the asked number of a call are logged as + `discarded_over_delivery`, never grouped, and their facts stay unused; a short call is a note. Reason: attempt 1's + top-up 2 returned 48 of 24 and used up the facts the third top-up needed. +13. **Bookkeeping outside the brief (amendment 3).** The paragraph on fact checks and pool size under 4.1 is not + sent to the author; attempt 1's fixture prompt carried it. ## 6b. Open points @@ -263,4 +296,5 @@ the same model and an empty scratch working directory for each call). **Attempt 1 stopped short (2026-10-05):** the non-file group reached 6 of 24 after three top-ups, so the corpus is not frozen (PREREG-0.2y section 5). Report, log and every prompt and answer: `attempt-1/REPORT.md`. The authoring rules -are revised under section 11 before attempt 2. +are revised under section 11 before attempt 2 (amendment 3: area-tagged facts, over-delivery rule). Attempt 2 uses +new fixtures, a new author run and none of attempt 1's requests. diff --git a/bench/tools/authoring_02y.py b/bench/tools/authoring_02y.py index f45e3e1..fefe51e 100644 --- a/bench/tools/authoring_02y.py +++ b/bench/tools/authoring_02y.py @@ -2,8 +2,9 @@ PREREG-0.2y section 5 / heldout-0.2y/AUTHORING.md section 4: * facts are handed to the author without their file (``facts_for_author``); - * brief E (everyday) and brief Q (question) draw from disjoint fact subsets, split by fact id - (odd serial -> E, even serial -> Q), and the split is recorded (``split_record``); + * brief E (everyday) and brief Q (question) draw from disjoint fact subsets, split by the ``area`` the + fixture author gave each fact (an everyday area -> E, ``other`` -> Q; PREREG-0.2y section 11 amendment 3, + replacing the odd/even split of attempt 1), and the split is recorded (``split_record``); * the fact pool must cover the base requests plus the maximum top-ups for each brief (``pool_check``); when it does not, the fixture step is repeated for the number of extra workspaces the check computes, never by hand. @@ -19,6 +20,12 @@ FIRST_PASS = 36 TOP_UP_STEP = 12 MAX_TOP_UPS = 3 FACTS_PER_WORKSPACE = 40 # minimum asked for in the fixture brief +# The life areas brief E names (PREREG-0.2y section 5), in its order; the fixture author tags each fact with one +# of them or with OTHER. Amendment 3: each workspace has at least MIN_PER_SIDE facts on each side. +AREAS = ("mail", "meetings", "contacts", "to-dos", "notes", "chats", "models", "memory", "documents", "images") +OTHER = "other" +MIN_PER_SIDE = FACTS_PER_WORKSPACE // 2 +MIN_AREAS = 3 # distinct everyday areas per workspace def per_brief_need() -> int: @@ -37,13 +44,20 @@ def with_ids(workspaces: list) -> list: out = [] for ws in workspaces: for n, f in enumerate(ws["facts"], 1): - out.append({"id": f"{ws['slug']}-{n:03d}", "slug": ws["slug"], "serial": n, "fact": f["fact"]}) + out.append({"id": f"{ws['slug']}-{n:03d}", "slug": ws["slug"], "serial": n, "fact": f["fact"], + "area": f.get("area")}) return out def brief_of(fact: dict) -> str: - """Odd serial -> everyday, even serial -> question. A pure function of the fact id.""" - return BRIEFS[0] if fact["serial"] % 2 == 1 else BRIEFS[1] + """An everyday area -> everyday, ``other`` -> question: a pure function of the author's own tag, never of + the fact's words. Untagged or unknown tags raise: ``fact_errors`` refuses them before any split is made, + and the split never guesses.""" + if fact["area"] in AREAS: + return BRIEFS[0] + if fact["area"] == OTHER: + return BRIEFS[1] + raise ValueError(f"{fact['id']}: area {fact['area']!r} is not one of the listed areas or other") def split_record(workspaces: list) -> dict: @@ -61,11 +75,20 @@ PATH_LIKE = re.compile(r"[/\\]|\.[a-z0-9]{1,5}(?![a-z0-9])") def fact_errors(workspaces: list, extension_pattern: str = None) -> list: """A fact must not carry a path, a file name or an extension (it is shown to the author, who must not - be able to copy a file name into a request). Returns the offending fact ids.""" + be able to copy a file name into a request), and must carry an ``area`` from AREAS or OTHER. A workspace + needs MIN_PER_SIDE facts in everyday areas, MIN_PER_SIDE ``other`` facts and MIN_AREAS distinct everyday + areas. Returns one message per offending fact or workspace; any message repeats the fixture call whole.""" errs = [] for ws in workspaces: names = {p.rsplit("/", 1)[-1].lower() for p in ws.get("files", {})} + tags = [f.get("area") for f in ws["facts"]] + everyday = [t for t in tags if t in AREAS] + if len(everyday) < MIN_PER_SIDE or tags.count(OTHER) < MIN_PER_SIDE or len(set(everyday)) < MIN_AREAS: + errs.append(f"{ws['slug']}: {len(everyday)} everyday facts in {len(set(everyday))} areas and " + f"{tags.count(OTHER)} other facts; need {MIN_PER_SIDE}, {MIN_AREAS} and {MIN_PER_SIDE}") for n, f in enumerate(ws["facts"], 1): + if f.get("area") not in AREAS and f.get("area") != OTHER: + errs.append(f"{ws['slug']}-{n:03d}: area {f.get('area')!r} is not one of the listed areas or other") text = f["fact"].lower() fid = f"{ws['slug']}-{n:03d}" if re.search(r"[/\\]", text) or any(re.search(r"(? dict: split = split_record(workspaces) need = per_brief_need() short = max(max(0, need - len(split[b])) for b in BRIEFS) - extra = math.ceil(short / (FACTS_PER_WORKSPACE // 2)) if short else 0 + extra = math.ceil(short / MIN_PER_SIDE) if short else 0 # a valid workspace gives each side MIN_PER_SIDE return {"ok": short == 0, "need_per_brief": need, "available": {b: len(split[b]) for b in BRIEFS}, "shortfall_per_brief": {b: max(0, need - len(split[b])) for b in BRIEFS}, "extra_workspaces": extra} diff --git a/bench/tools/lint_02y.py b/bench/tools/lint_02y.py index 206bc94..36a98b6 100644 --- a/bench/tools/lint_02y.py +++ b/bench/tools/lint_02y.py @@ -198,7 +198,13 @@ def replay(entries: list, catalog: Iterable, rule: dict, fixtures: dict, tool_do and "discarded_surplus" for a passing one beyond the group size (kept in the log, never run); * round r >= 1 (a top-up) may only use the brief of a group that was short after the rounds before it, and there are at most MAX_TOP_UPS such rounds; - * round 0 has exactly ``first_pass[brief]`` requests per brief (default 36 each, two briefs). + * one call = one (round, brief). It asks for ``first_pass[brief]`` requests in round 0 (default 36 each, + two briefs) and TOP_UP_STEP * r in round r. Amendment 3 (PREREG-0.2y section 11): when a call returns + more, the first ones up to the asked number count and every later one must carry status + "discarded_over_delivery" (logged, never linted into a group, never run); a call that returns fewer + is recorded in ``notes``, not an error. A call that returns nothing is one log line with status + "empty_call" and an empty request (it takes an id, so the round stays visible); it must be the only + line of its call. Round 0 must contain every brief of ``first_pass``. ``fixtures`` maps a fixture name to its file base names. With ``groups=("any",)`` (the calibration set, which has no group split) every passing request counts into one pool.""" target = target or {g: GROUP_SIZE for g in groups} @@ -221,23 +227,30 @@ def replay(entries: list, catalog: Iterable, rule: dict, fixtures: dict, tool_do errors.append(f"{e['id']}: round {e.get('round')} after round {prev} (ids must follow authoring order)") prev = max(prev, e.get("round", 0)) - briefs0: dict = {} - for e in ordered: - if e.get("round", 0) == 0: - briefs0[e.get("brief")] = briefs0.get(e.get("brief"), 0) + 1 want = first_pass if first_pass is not None else {"everyday": FIRST_PASS_PER_BRIEF, "question": FIRST_PASS_PER_BRIEF} - if briefs0 != want: - errors.append(f"first pass has {briefs0} requests per brief, expected {want}") - - # top-up sizes: round r asks for TOP_UP_STEP * r requests per call, one call per brief used in that round - per_call: dict = {} + calls: dict = {} for e in ordered: - if e.get("round", 0) >= 1: - key = (e["round"], e.get("brief")) - per_call[key] = per_call.get(key, 0) + 1 - for (r, brief), n in sorted(per_call.items(), key=lambda kv: (kv[0][0], str(kv[0][1]))): - if n != TOP_UP_STEP * r: - errors.append(f"top-up round {r}, brief {brief!r}: {n} requests, expected {TOP_UP_STEP * r}") + calls.setdefault((e.get("round", 0), e.get("brief")), []).append(e) + briefs0 = {b for (r, b) in calls if r == 0} + if briefs0 != set(want): + errors.append(f"first pass has briefs {sorted(map(str, briefs0))}, expected {sorted(want)}") + notes: list = [] + over: set = set() # ids beyond the asked number of their call + for (r, brief), es in sorted(calls.items(), key=lambda kv: (kv[0][0], str(kv[0][1]))): + asked = want.get(brief, 0) if r == 0 else TOP_UP_STEP * r + what = "first pass" if r == 0 else f"top-up round {r}" + empty = [e for e in es if e.get("status") == "empty_call"] + if empty and (len(es) != 1 or es[0].get("request", "") != ""): + errors.append(f"{empty[0]['id']}: an empty_call line must be the only line of its call and carry no request") + returned = 0 if empty else len(es) + if returned < asked: + notes.append(f"{what}, brief {brief!r}: {returned} requests returned, {asked} asked") + over.update(e["id"] for e in empty) # never linted + for e in es[asked:]: + over.add(e["id"]) + if e.get("status") != "discarded_over_delivery": + errors.append(f"{e['id']}: beyond the {asked} asked in {what}, brief {brief!r}, but recorded " + f"status {e.get('status')!r}, expected 'discarded_over_delivery'") count = {g: 0 for g in groups} short_before = {0: set(groups)} @@ -251,9 +264,11 @@ def replay(entries: list, catalog: Iterable, rule: dict, fixtures: dict, tool_do short_before[r] = {g for g in groups if count[g] < target[g]} if not short_before[r]: errors.append(f"{e['id']}: top-up round {r} although no group was short") - allowed = set(briefs0) if pooled else {brief_for_group[g] for g in short_before[r] if g in brief_for_group} + allowed = briefs0 if pooled else {brief_for_group[g] for g in short_before[r] if g in brief_for_group} if r >= 1 and e.get("brief") not in allowed: errors.append(f"{e['id']}: top-up brief {e.get('brief')!r} does not match a short group") + if e["id"] in over: + continue # checked above; an over-delivered request is never linted into a group if e.get("fixture") not in fixtures: errors.append(f"{e['id']}: unknown fixture {e.get('fixture')!r}") res = lint_request(e["request"], catalog, rule, fixtures.get(e.get("fixture"), ()), tool_domains) @@ -277,4 +292,4 @@ def replay(entries: list, catalog: Iterable, rule: dict, fixtures: dict, tool_do for g in groups: if count[g] != target[g]: errors.append(f"group {g}: {count[g]} accepted, need exactly {target[g]}") - return {"errors": errors, "accepted": accepted, "counts": count} + return {"errors": errors, "accepted": accepted, "counts": count, "notes": notes} diff --git a/bench/tools/test_authoring_02y.py b/bench/tools/test_authoring_02y.py index 673ad9c..ff4d269 100644 --- a/bench/tools/test_authoring_02y.py +++ b/bench/tools/test_authoring_02y.py @@ -10,8 +10,14 @@ sys.path.insert(0, str(Path(__file__).resolve().parent)) import authoring_02y as A # noqa: E402 +def area(i): + """Alternating tags (odd serial = an everyday area, even serial = other) keep the attempt-1 counts.""" + return A.AREAS[(i // 2) % len(A.AREAS)] if i % 2 == 0 else A.OTHER + + def ws(slug, n): - return {"slug": slug, "files": {"a/notes.txt": "x"}, "facts": [{"fact": f"Fact {i} of {slug}.", "file": "a/notes.txt"} for i in range(n)]} + return {"slug": slug, "files": {"a/notes.txt": "x"}, + "facts": [{"fact": f"Fact {i} of {slug}.", "file": "a/notes.txt", "area": area(i)} for i in range(n)]} class Authoring(unittest.TestCase): @@ -56,8 +62,43 @@ class Authoring(unittest.TestCase): self.assertFalse(odd["ok"]) self.assertEqual(odd["extra_workspaces"], 1) + def test_the_area_tag_decides_the_split_not_the_position(self): + w = ws("a", 40) + for f in w["facts"][:20]: + f["area"] = A.OTHER + for i, f in enumerate(w["facts"][20:]): + f["area"] = A.AREAS[i % 4] + rec = A.split_record([w]) + self.assertEqual(rec["question"], [f"a-{n:03d}" for n in range(1, 21)]) + self.assertEqual(rec["everyday"], [f"a-{n:03d}" for n in range(21, 41)]) + self.assertEqual(A.fact_errors([w]), []) + + def test_missing_or_unknown_area_is_refused(self): + w = ws("a", 40) + del w["facts"][0]["area"] + w["facts"][1]["area"] = "email" # a word, not one of the listed areas + errs = A.fact_errors([w]) + self.assertTrue(any(e.startswith("a-001: area None") for e in errs), errs) + self.assertTrue(any(e.startswith("a-002: area 'email'") for e in errs), errs) + with self.assertRaises(ValueError): # the split never guesses a side for a bad tag + A.split_record([w]) + + def test_workspace_balance_is_enforced(self): + self.assertEqual(A.fact_errors([ws("a", 40)]), []) + lopsided = ws("b", 40) + lopsided["facts"][0]["area"] = A.OTHER # fact 0 was everyday: now 19 everyday, 21 other + self.assertTrue(any(e.startswith("b: 19 everyday facts") for e in A.fact_errors([lopsided]))) + few_other = ws("d", 40) + few_other["facts"][1]["area"] = A.AREAS[0] # fact 1 was other: now 21 everyday, 19 other + self.assertTrue(any(e.startswith("d: 21 everyday facts in") and "19 other" in e for e in A.fact_errors([few_other]))) + narrow = ws("c", 40) + for f in narrow["facts"]: + if f["area"] != A.OTHER: + f["area"] = A.AREAS[0] if f is narrow["facts"][0] else A.AREAS[1] + self.assertTrue(any("in 2 areas" in e for e in A.fact_errors([narrow]))) + def test_facts_with_paths_or_file_names_are_flagged(self): - w = ws("a", 3) + w = ws("a", 40) w["facts"][0]["fact"] = "It is in notes.txt." w["facts"][1]["fact"] = "See docs/rota." w["facts"][2]["fact"] = "The depot opens at nine." diff --git a/bench/tools/test_lint_02y.py b/bench/tools/test_lint_02y.py index b251860..2d77d48 100644 --- a/bench/tools/test_lint_02y.py +++ b/bench/tools/test_lint_02y.py @@ -270,9 +270,40 @@ class Replay(unittest.TestCase): full = make_entries() self.assertTrue(any("no group was short" in x for x in replay(decide(full + self.top_up(73, 1, 12, True)))["errors"])) - def test_top_up_sizes_must_be_12_24_36(self): - errs = replay(decide(sized(36, 20) + self.top_up(73, 1, 6, True)))["errors"] - self.assertTrue(any("top-up round 1, brief 'question': 6 requests, expected 12" in x for x in errs), errs) + def test_top_up_under_delivery_is_a_note(self): + res = replay(decide(sized(36, 20) + self.top_up(73, 1, 6, True))) + self.assertEqual(res["errors"], []) + self.assertIn("top-up round 1, brief 'question': 6 requests returned, 12 asked", res["notes"]) + + def test_an_empty_call_keeps_its_round_visible(self): + ents = decide(sized(36, 0) + self.top_up(73, 1, 12, True)) + ents.append({"id": "q-0085", "round": 2, "brief": "question", "request": "", "fixture": "f1", + "set": "target", "status": "empty_call"}) + ents += decide(self.top_up(86, 3, 36, True)) + for e in ents[-36:]: + e["status"] = "accepted" if e["id"] <= "q-0097" else "discarded_surplus" + res = replay(ents) + self.assertEqual(res["errors"], []) + self.assertIn("top-up round 2, brief 'question': 0 requests returned, 24 asked", res["notes"]) + next(e for e in ents if e["id"] == "q-0085")["request"] = "Where is the depot rota kept?" # a marker may not carry a request + self.assertTrue(any("empty_call line must be the only line" in x for x in replay(ents)["errors"])) + + def test_over_delivery_beyond_the_asked_number_never_counts(self): + # round 1 asks for 12: the first 12 are rejected by the lint, 6 valid ones follow beyond the ask + ents = decide(sized(36, 20) + self.top_up(73, 1, 12, False) + self.top_up(85, 1, 6, True)) + errs = replay(ents)["errors"] + self.assertTrue(any(x.startswith("q-0085: beyond the 12 asked in top-up round 1") for x in errs), errs) + for e in ents[-6:]: + e["status"] = "discarded_over_delivery" + errs = replay(ents)["errors"] + # marked correctly they are not linted into a group, so the default group stays short + self.assertEqual(errs, ["group default: 20 accepted, need exactly 24"], errs) + ents = decide(sized(36, 20) + self.top_up(73, 1, 12, True) + self.top_up(85, 1, 6, True)) + for e in ents[-6:]: + e["status"] = "discarded_over_delivery" + self.assertEqual(replay(ents)["errors"], []) + ents[-7]["status"] = "discarded_over_delivery" # one inside the ask may not be marked + self.assertTrue(any(x.startswith("q-0084: recorded status") for x in replay(ents)["errors"])) def test_more_than_three_top_ups_fails(self): ents = sized(36, 0) @@ -298,8 +329,12 @@ class Replay(unittest.TestCase): ents = decide(make_entries()) ents[0], ents[1] = ents[1], ents[0] self.assertTrue(any("not in request-id order" in x for x in replay(ents)["errors"])) - ents = decide(make_entries(nonfile=30, default=36)) - self.assertTrue(any("first pass has" in x for x in replay(ents)["errors"])) + # amendment 3: a short first pass is a note, a missing brief is an error + res = replay(decide(make_entries(nonfile=30, default=36))) + self.assertEqual(res["errors"], []) + self.assertIn("first pass, brief 'everyday': 30 requests returned, 36 asked", res["notes"]) + ents = [e for e in decide(make_entries()) if e["brief"] == "question"] + self.assertTrue(any("first pass has briefs" in x for x in replay(ents)["errors"])) def test_calibration_pool_takes_the_first_30(self): ents = decide(make_entries(), target={"any": 30}, groups=("any",)) diff --git a/docs/prereg/PREREG-0.2y-base-set-discovery.md b/docs/prereg/PREREG-0.2y-base-set-discovery.md index 7fd66b4..b3ed998 100644 --- a/docs/prereg/PREREG-0.2y-base-set-discovery.md +++ b/docs/prereg/PREREG-0.2y-base-set-discovery.md @@ -245,3 +245,26 @@ Ollama 0.34.0 returned 500 on malformed `qwen3.5` tool calls (`docs/REPORT-0.2x. the pool is 6 workspaces of 40 or more facts and is enlarged deterministically if it cannot cover base requests plus maximum top-ups: removes a path leak and a shared-fact overlap. 10. Calibration tasks pool both groups (first 30 passing in id order): section 5 gives no group split for them. +- 2026-10-05 (amendment 3, after authoring attempt 1 stopped short and before attempt 2; no target or calibration + task exists, no model under test has received any request). Attempt 1 (`bench/heldout-0.2y/attempt-1/REPORT.md`) + filled the default group (24/24) but the non-file group reached 6 of 24 after three top-ups, so under section 5 + the corpus was not frozen and the authoring rules are revised here. Thresholds, arms, sample size, group sizes, + lint and acceptance rule are unchanged; the 24/24 requirement stays. + 11. Area-tagged facts. The fixture author keeps everyday records in each workspace and tags every fact with one + of the ten life areas brief E already names (mail, meetings, contacts, to-dos, notes, chats, models, memory, + documents, images) or `other`; each workspace has at least 20 facts on each side and 3 distinct areas. Brief E + draws the tagged facts, brief Q the `other` facts (replacing amendment 2 item 9's odd/even split). Reason: in + attempt 1 every fact was about a workshop's own files, so the everyday-work brief had no mail, meeting or note + to ask about (6 of 89 lint-passing everyday requests derived a non-file domain). The split uses the author's + tag, never a reading of the fact; the request author never sees the tag, a keyword list or the selector. This + is a hypothesis about the shortfall, not a tested one: if attempt 2 is short again, the corpus is again not + frozen. + 12. Over- and under-delivery. A call that returns more requests than it asked for keeps the first ones up to the + asked number in the author's order; the rest are logged as `discarded_over_delivery`, never grouped or run, + and their facts stay unused. A call that returns fewer is logged as it is (a replay note, not an error) and + the round still counts; a call that returns nothing is one `empty_call` log line. Reason: attempt 1's top-up 2 returned 48 of 24 and used up the facts the third top-up + needed. Attempt 1's record was replayed with the checker at 2049968; the amended checker is not applied to it. + 13. The bookkeeping paragraph under the fixture brief (check names and pool arithmetic) is moved outside the + verbatim brief; attempt 1's fixture prompt carried it (no catalog name, keyword or selector detail; recorded, + not changing attempt 1's outcome). + Attempt 2 uses new fixtures, a new author run (same author family, section 5) and none of attempt 1's requests. ```