Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 0 additions & 17 deletions test/guardrails/no-legacy-dag-path.test.ts

This file was deleted.

20 changes: 20 additions & 0 deletions test/guardrails/no-legacy-orchestration-path.test.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
import { existsSync } from "node:fs";
import { fileURLToPath } from "node:url";
import { dirname, resolve } from "node:path";
import { describe, it, expect } from "vitest";

/**
* Forward-only guardrail: the retired generic-orchestration source path must
* never return to afi-core. That model was retired in favour of the
* manifest-driven five-lane GraphExecutor runtime; the path is banned.
* The banned path is assembled from fragments at runtime, so this guard's own
* source contains no complete retired literal (no self-exemption required).
*/
const REPO_ROOT = resolve(dirname(fileURLToPath(import.meta.url)), "..", "..");
const RETIRED_ORCHESTRATION_PATH = ["src/", "dag"].join("");

describe("no-legacy-orchestration-path guardrail", () => {
it("the retired generic-orchestration source path does not exist in afi-core", () => {
expect(existsSync(resolve(REPO_ROOT, RETIRED_ORCHESTRATION_PATH))).toBe(false);
});
});
17 changes: 8 additions & 9 deletions validators/__tests__/computeUwrScore.kat.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,10 @@
* `computeUwrScore` (UP-11 item 1).
*
* Fixture: ./kats/compute-uwr-score.kat.json — a byte-identical vendored copy
* of afi-config `kats/uwr-profile/v0/compute-uwr-score.kat.json` @ merge
* commit fe329164919f0c1c9dc24bb5c279978fb680e983 (PR #17), content commit
* 7809af4b0308f7db47488947770a0ab9f236268d, blob
* 276be9e9348b4e0c2e92e5a9c59d05b50bfeb75d. Full provenance and change
* of afi-config `kats/uwr-profile/v0/compute-uwr-score.kat.json`, re-vendored
* under R1-GOV (D-R1-7) from afi-config content commit
* d6f2504805059ffa09d8c1bfcecb67cd47abcea2, blob
* ac6f74e88eda1a6266dca40642a5f9312d0163b9. Full provenance and change
* control: ./kats/README.md. The KAT's engine.sourceCommit 390b440 pin is
* exact for this suite: validators/UniversalWeightingRule.ts is
* blob-identical between 390b440 and the executed-against commit 2541853.
Expand Down Expand Up @@ -50,7 +50,7 @@ const SIBLING_URL = new URL(

/** sha256 of the vendored bytes, pinned at vendoring time (PR-UWR-KAT-EXEC). */
const PINNED_SHA256 =
"ff2f63956038b1d5c01109184e2ddddb2606c11405d2420c35b7decb5eb36546";
"e66e8397e9b55507abaff07ccd9d1085d759603cde1b5b468a36ee37bbae0b44";

const DRIFT_MESSAGE =
"Vendored copy or upstream KAT changed — requires a new scoped " +
Expand Down Expand Up @@ -227,10 +227,9 @@ describe("PR-UWR-KAT-EXEC: computeUwrScore vs afi-config KAT vectors", () => {
});

it("uwr-score-d2m2-golden-anchor: the 0.1875 golden anchor reproduces bit-exactly", () => {
// Decision-named anchor (D2 M2 golden replay:
// afi-reactor/test/pipeheads/fixtures/golden.json @ 79c4a6f). Byte-
// stability of the D2 M2 goldens is an acceptance criterion (UP-5,
// UP-11) — called out explicitly on top of the generic loop above.
// Decision-named anchor (Signal Evaluation deterministic golden replay).
// Byte-stability of the golden is an acceptance criterion (UP-5, UP-11)
// — called out explicitly on top of the generic loop above.
const v = kat.vectors.find(
vec => vec.vectorId === "uwr-score-d2m2-golden-anchor"
);
Expand Down
2 changes: 1 addition & 1 deletion validators/__tests__/kats/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ and is never consumed by runtime code.
| Merge commit (PR #17) | `fe329164919f0c1c9dc24bb5c279978fb680e983` |
| Content commit | `7809af4b0308f7db47488947770a0ab9f236268d` |
| Git blob SHA-1 | `276be9e9348b4e0c2e92e5a9c59d05b50bfeb75d` |
| sha256 (file bytes) | `ff2f63956038b1d5c01109184e2ddddb2606c11405d2420c35b7decb5eb36546` |
| sha256 (file bytes) | `e66e8397e9b55507abaff07ccd9d1085d759603cde1b5b468a36ee37bbae0b44` |
| Executed against afi-core | `254185381c3c9be91da303454c1f7a27e8818983` (main, PR #16 merge) |
| Profile | `uwr-weighted-lifts-v0.1` (afi-governance `decisions/uwr-profile-pin-v0.1.md`) |

Expand Down
2 changes: 1 addition & 1 deletion validators/__tests__/kats/compute-uwr-score.kat.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
"vectors": [
{
"vectorId": "uwr-score-d2m2-golden-anchor",
"description": "The D2 M2 golden replay anchor (afi-reactor/test/pipeheads/fixtures/golden.json @ 79c4a6f): uwrScore 0.1875 = mean(0.15, 0, 0.2, 0.4). Byte-stability of the D2 M2 goldens is an acceptance criterion (UP-5, UP-11).",
"description": "Canonical Signal Evaluation deterministic golden replay anchor: uwrScore 0.1875 = mean(0.15, 0, 0.2, 0.4). Byte-stability of the golden is an acceptance criterion (UP-5, UP-11).",
"axes": { "structure": 0.15, "execution": 0, "risk": 0.2, "insight": 0.4 },
"expected": { "uwrScore": 0.1875 }
},
Expand Down
Loading