Skip to content

feat(validation): add paired rating range evidence - #579

Closed
seonghobae wants to merge 19 commits into
mainfrom
feat/essay-range-compression-evidence
Closed

feat(validation): add paired rating range evidence#579
seonghobae wants to merge 19 commits into
mainfrom
feat/essay-range-compression-evidence

Conversation

@seonghobae

@seonghobae seonghobae commented Aug 9, 2026

Copy link
Copy Markdown
Contributor

Buyer-visible gap

Issue #397 requires evidence that an automated essay scorer is not merely agreeing on average while using a materially narrower portion of the ordinal rating scale. Existing validation exposes agreement, association, fairness/SMD, severity-related evidence and human-human degradation, but did not expose explicit paired category-range evidence.

Implemented bounded slice

The branch contains a Rust-owned descriptive diagnostic over the same paired automated/reference validation cases and a thin PyO3/Python product path.

mlsirm_core::rating_range::paired_rating_range_evidence owns all descriptive arithmetic and returns paired sample size, automated/reference minima/maxima, distinct-category counts, spans, population-divisor empirical SDs, relative ratios where identified, signed endpoint gaps, conservative narrower_observed_support, and stricter central_tendency_signal. Degenerate reference span/SD returns unavailable relative evidence rather than NaN/Inf; no universal acceptance threshold is encoded.

Rust/PyO3/Python ownership

  • Rust numerical/descriptive arithmetic: crates/mlsirm-core/src/rating_range.rs;
  • PyO3 marshalling only: crates/fast-mlsirm-py/src/rating_range_bindings.rs;
  • bounded Python validation/immutable transport: python/fast_mlsirm/rating_range.py;
  • package-root and historical validation exports reuse the same implementation;
  • direct-delegation tests compare every public Python result field with raw Rust output and protect caller-array immutability.

Python does not recompute the diagnostic.

Scientific boundary

This is descriptive paired-sample evidence, not a generalized many-facet range-restriction parameter. Rater severity, agreement, central-category support and inferential rater range restriction remain different constructs. A future MFRM/rMFRM range-restriction model requires a separate Rust likelihood/identification contract, connected-design tests, true-parameter bias/MAE/RMSE/coverage/convergence and uncertainty evidence, relation-safe model comparison and CPU/GPU parity where material.

Exact-current evidence

Freshly revalidated:

  • protected main: 8db4bf358b0a469915d6c5e336054f4a4f9c6b46;
  • exact Draft head: f11f46c3a4945c76779c545ba9d9cf9207410de0;
  • exact-head CI run 31309352764: Rust/PyO3, package/reinstall/release acceptance, enterprise sales-readiness smoke, explicit GPU no-skip and fuzz succeed; Python reaches the full suite with the paired-rating-range feature GREEN and fails only deterministic managed-CHANGELOG.md render parity;
  • ClusterFuzzLite 31309352732: success;
  • Security Scan 31309352750: success;
  • SAST Semgrep 31309352734: success;
  • a bounded current-main integration/changelog handoff is already bound to this exact source head and protected main; do not race or duplicate it while identities remain unchanged.

docs/doctoring/paired-rating-range-evidence.md and docs/changelog.d/397-paired-rating-range-evidence.md are authoritative branch evidence. Older body identities such as d8c06ace... are predecessor state only.

Remaining Draft gate

Keep Draft. Reconcile current protected main non-destructively, preserving accepted-main behavior and only this unique rating-range Rust/PyO3/Python/tests/doctoring/fragment slice; render/check authoritative changelog; then require one unchanged exact head with focused/full Python coverage/docstrings, Rust workspace/all-target/clippy/fmt, PyO3/wheel/package/reinstall, explicit GPU-no-skip, fuzz/ClusterFuzzLite, Security Scan, SAST, fresh current-head automated review, zero valid unresolved findings and repository approval/branch-protection policy.

No essay-report schema change, provider SDK, generated feedback, new likelihood, latent-space term, generalized rMFRM or release bump belongs here.

Advances #397.

@coderabbitai

coderabbitai Bot commented Aug 9, 2026

Copy link
Copy Markdown
Contributor

Important

Review skipped

Draft detected.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro Plus

Run ID: 33526f08-2c73-492b-8071-b1c44862ef1c

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

Copy link
Copy Markdown
Contributor Author

@opencode-agent address

Operate only on exact current Draft head 0e1550bbc5f5627c33b89a5e9ed8406d267f7f55; abort without writing if it moved. The RED phase is now independently observed in CI run 31290174663: Python reports exactly 17 failures, all from the intentionally missing fast_mlsirm.validation.paired_rating_range_evidence public API, with 2,915 passed / 2 skipped and no unrelated Python failure; Rust/PyO3, package/release acceptance, explicit GPU no-skip, and fuzz are green on the same head.

Implement the minimal GREEN slice from the committed design and plan without scope expansion:

  1. In crates/mlsirm-core/src/agreement.rs, add public PairedRatingRangeEvidence and paired_rating_range_evidence() with Rust-side validation for paired equal length, at least two observations, category_count in 2..=1000, and labels in 0..category_count-1.
  2. Compute the exact committed fields: automated/reference min/max, distinct category counts, spans, population-divisor empirical SD (sqrt(sum((x-mean)^2)/n); the RED oracle intentionally uses ddof=0), optional span/SD ratios, distinct-category ratio, signed lower/upper endpoint gaps, conservative narrower_observed_support, and stricter central_tendency_signal. Degenerate reference span/SD returns None, never NaN/Inf.
  3. Expose only the Rust result through PyO3 in the existing _core module (for example agreement_paired_rating_range_evidence); Python must not recompute the numerical statistics.
  4. In python/fast_mlsirm/validation.py, add frozen RatingRangeEvidence and a strict paired-label validator. Reject Boolean arrays/values before integer coercion, non-integral values, negative/out-of-range labels, non-1-D arrays, unequal lengths, and invalid category_count. Do not silently relax or change the existing validate_judge behavior.
  5. Build the Python result solely from the raw Rust payload and add a direct delegation test that compares every public field with _core output. Preserve caller-array immutability.
  6. Add Rust oracle/degenerate/error-path tests and complete new-production statement/branch coverage plus public rustdoc/docstrings.
  7. Run pytest -q tests/test_paired_rating_range_evidence.py and the focused Rust/PyO3 tests. If and only if focused GREEN is established, add docs/doctoring/paired-rating-range-evidence.md with APA 7 primary-source traceability and docs/changelog.d/397-paired-rating-range-evidence.md, then render/check the authoritative changelog.

Keep the essay validation-report schema unchanged in this PR. Add no provider SDK, feedback generation, new likelihood, generalized rMFRM, latent-space term, workflow/dependency/version change, or Python numerical fallback. Keep Draft; do not mark Ready, enable auto-merge, approve, merge, release, or close issue #397. A final unchanged head still requires full Python, Rust/PyO3, package, GPU-no-skip, fuzz, Security Scan, SAST, exact-head review, qualifying independent approval, and branch protection.

Copy link
Copy Markdown
Contributor Author

@opencode-agent address

Refetch exact current head/base before writing. This Draft already has RED public-contract tests and an implementation plan for paired automated/reference rating-range evidence. Implement only the bounded first slice described in the branch plan: Rust-owned PairedRatingRangeEvidence + paired_rating_range_evidence() in the existing agreement layer, PyO3 exposure through the existing _core, and an immutable Python RatingRangeEvidence / paired_rating_range_evidence() wrapper that validates/marshals only and performs no numerical recomputation. Match the hand-calculated fixtures exactly, return None rather than NaN/Inf for ratios with degenerate reference span/SD, keep the sample-evidence interpretation separate from MFRM severity or a population range-restriction parameter, and preserve all existing validation ABI/semantics.

Add Rust oracle/branch tests and Python delegation/parity tests as required by the committed plan. Keep this PR Draft until GREEN and full gates. Do not add essay-report schema wiring, provider SDKs, generated feedback, a new likelihood, rMFRM, latent-space terms, universal thresholds/pass-fail policy, or external-repository changes. Add doctoring/changelog material only after the numerical contract is GREEN and render the authoritative CHANGELOG. If head/base moves before writing, refetch/reconcile and do not use stale assumptions.

Copy link
Copy Markdown
Contributor Author

Exact-head review finding for 0e1550bbc5f5627c33b89a5e9ed8406d267f7f55: test_public_result_is_an_immutable_copy_of_rust_evidence does not currently prove independence from caller-owned arrays. It assigns snapshot = result, mutates the inputs, and then compares the object to itself, so an implementation that retained mutable caller state could still satisfy the assertion depending on equality semantics. Before GREEN implementation, make the RED contract capture independent expected field values (or a separately constructed immutable value object), mutate both inputs, and assert every public field still equals the pre-mutation values. Also add the planned exact field-for-field comparison against the raw _core payload so Python cannot silently recompute or transform Rust-owned statistics. Keep the branch Draft and do not weaken the existing malformed-input/statistical-boundary cases.

Copy link
Copy Markdown
Contributor Author

@opencode-agent address

Operate only on exact current Draft head cff209a29a6c9c527e533fa02f870cac2227059c. A new public Rust-core integration test intentionally makes the current architecture RED: the numerical diagnostic is presently implemented inside the PyO3 crate, so mlsirm_core::rating_range does not exist. Do not weaken/delete that test or move arithmetic into Python.

Make the smallest architecture-correct GREEN change:

  1. move the reusable numerical implementation and public PairedRatingRangeEvidence/paired_rating_range_evidence() API into crates/mlsirm-core under a public rating_range module; register that module in crates/mlsirm-core/src/lib.rs;
  2. keep PyO3 rating_range_bindings.rs as marshalling only: import and call the core API, serialize its public fields, and retain only binding-specific shape/error conversion. Remove duplicate numerical/statistical implementation and duplicate core-unit tests from the PyO3 crate;
  3. preserve the exact population-divisor SD, conservative flags, category/resource bounds, degenerate-ratio None behavior, and all existing Python public fields. Avoid eager divide-by-zero expressions when ratios are unavailable;
  4. run the new crates/mlsirm-core/tests/rating_range_evidence.rs, the focused PyO3/Python range tests, cargo fmt --check, cargo clippy --workspace --all-targets -- -D warnings, and relevant full gates;
  5. after GREEN, add authoritative docs/doctoring/paired-rating-range-evidence.md using the already committed APA 7 source basis and docs/changelog.d/397-paired-rating-range-evidence.md, then render/check CHANGELOG.md;
  6. keep Draft. Do not change the essay report schema, add a likelihood/rMFRM/latent-space term, provider dependency, workflow, version bump, approval, merge, release, or new PR.

Copy link
Copy Markdown
Contributor Author

@opencode-agent address

Operate only on exact current Draft head cff209a29a6c9c527e533fa02f870cac2227059c; abort without writing if it moved. Predecessor requests target older heads and are void.

Exact-head CI 31304127729 proves Python, package/reinstall/release acceptance, explicit GPU-no-skip, and fuzz are green. Rust job 93221608783 fails first at cargo test --workspace with E0432 unresolved import mlsirm_core::rating_range from crates/mlsirm-core/tests/rating_range_evidence.rs. The root cause is architectural, not a test typo: the branch currently owns all descriptive arithmetic privately inside crates/fast-mlsirm-py/src/rating_range_bindings.rs, while the reusable Rust core exports no corresponding module. This violates the PR's Rust-core ownership contract and leaves the public core test uncompilable.

Complete the smallest GREEN repair without scope expansion:

  1. Move the PairedRatingRangeEvidence, RatingSummary, validation, Welford population-SD, ratio, endpoint-gap, and Boolean-signal arithmetic into the reusable mlsirm-core agreement layer as public rustdoc-complete PairedRatingRangeEvidence and paired_rating_range_evidence(); either use mlsirm_core::agreement::{...} consistently or add a documented root rating_range module, but do not duplicate arithmetic in PyO3.
  2. Make rating_range_bindings.rs a thin PyO3 adapter over that exact core result and retain only transport/result-dict code plus binding-specific validation. Remove its duplicate kernel and duplicate tests.
  3. Update the Rust integration test to the actual public core path and preserve all hand-calculated, degenerate, malformed-input, and category-boundary contracts. Rust must independently reject lengths <2, unequal pairs, category count outside 2..=1000, and out-of-range labels.
  4. Add the missing direct delegation regression: compare every public frozen Python field with the raw Rust extension payload for the same paired vectors. Preserve caller-array immutability and the existing Boolean/fractional/resource bounds; Python must not recompute statistics.
  5. Keep fast_mlsirm.validation compatibility explicit and deterministic. Do not add a second numerical fallback or alter existing validate_judge behavior.
  6. Add the planned APA 7 doctoring and authoritative changelog fragment only after focused GREEN; render and check CHANGELOG.md with the repository renderer.
  7. Run focused core/PyO3/Python tests, then cargo test --workspace, full Python coverage/docstring gates, package/reinstall/release acceptance, explicit GPU no-skip, and fuzz as available.

Keep Draft. Do not change essay-report schemas, providers, likelihoods, generalized rMFRM, workflows, dependencies, versioning, branch protection, approval, merge, release, or issue #397 state.

Copy link
Copy Markdown
Contributor Author

@opencode-agent Exact-head review follow-up on current d8c06ace4f227e0f0152103de778b649b65220d8; keep the existing writer lease and address only if still current.

The Rust→PyO3→Python delegation and explicit Boolean/category-count validation are now present and the direct delegation test compares every public field. Two bounded hardening gaps remain before final GREEN:

  1. python/fast_mlsirm/rating_range.py::_rating_array should explicitly reject np.ma.MaskedArray before np.asarray. np.asarray(masked_array) can discard mask semantics and expose the underlying payload as ordinary labels; the existing general validation APIs already treat masked ratings as unsupported. Add a regression proving masked paired ratings fail closed rather than silently scoring masked data.
  2. In Rust, bool::then_some(...) eagerly evaluates its argument. The current span_ratio and sd_ratio expressions therefore still evaluate a zero-denominator floating division in the degenerate-reference branch even though the returned Option is None. Replace with explicit if or lazy then(|| ...) so the implementation matches its documented “unavailable rather than NaN/Inf” numerical boundary without creating a non-finite intermediate. Pin zero-span and zero-SD paths in Rust.

Do not expand into generalized rMFRM/rater inference or change the descriptive semantics. After these narrow repairs, focused tests plus exact-head CI/Security/SAST/fuzz and current-head review still govern Draft→Ready.

Copy link
Copy Markdown
Contributor Author

@jules address

Take a bounded writer lease on this Draft branch only. Exact head is now f11f46c3a4945c76779c545ba9d9cf9207410de0, an auditable fast-forward to GitHub's synthetic merge of prior feature head d8c06ace4f227e0f0152103de778b649b65220d8 with protected main 7516031df533d1131572eb07b6e3a86b04d12793. Re-read both before writing and abort if either moved.

Do not change numerical behavior unless a focused current-head test proves a defect. First run the repository changelog renderer so docs/changelog.d/397-paired-rating-range-evidence.md and every accepted-main fragment are represented exactly in CHANGELOG.md. Then run the focused Rust core integration tests, PyO3 binding tests, tests/test_paired_rating_range_evidence.py, tests/test_paired_rating_range_delegation.py, changelog fragment check, compilation, and the complete relevant Python/Rust coverage/docstring/package gates. Preserve the Rust-core numerical ownership, thin PyO3 marshalling, Python validation-only contract, descriptive-not-inferential interpretation, and all existing RED/GREEN adversarial cases.

Commit only rendered CHANGELOG.md plus a minimal source/test/doc correction if and only if the exact focused failure proves one is required. Keep Draft; do not create another PR, rewrite history, mark Ready, approve, merge, change dependencies/workflows/version, or expand into generalized rMFRM.

Copy link
Copy Markdown
Contributor Author

@opencode-agent address

Operate only on exact current Draft head f11f46c3a4945c76779c545ba9d9cf9207410de0; abort without writing if the PR head or live main tip moved before your write. Exact-current CI run 31309352764 checks out merge ref 7f16e64c0b7986c3cd8f0f0f6ce137458d69d48c over protected main 7516031df533d1131572eb07b6e3a86b04d12793. Rust, package/reinstall/release acceptance, explicit GPU-no-skip, fuzz, Security Scan, SAST and ClusterFuzzLite are green. Python job 93234640238 has exactly one deterministic failure after 2940 passed / 2 skipped: test_repository_changelog_is_rendered_from_current_fragments, with the explicit remedy render_changelog_fragments.py --update CHANGELOG.md.

Make one bounded deterministic repair only: run python scripts/render_changelog_fragments.py --update CHANGELOG.md, then python scripts/render_changelog_fragments.py --check CHANGELOG.md and pytest -q tests/test_changelog_fragment_contract.py. Commit only the renderer-produced CHANGELOG.md delta. Do not edit docs/changelog.d/397-paired-rating-range-evidence.md, numerical/source code, tests, dependencies, version/release state, PR Draft state, approval/merge state, or issue #397. If any unrelated diff would be required, stop without writing and report the exact evidence.

Copy link
Copy Markdown
Contributor Author

@opencode-agent address

Exact-current source head at handoff: f11f46c3a4945c76779c545ba9d9cf9207410de0. Exact-head CI run 31309352764 has one failing job only: Python. The full suite reached 1 failed, 2940 passed, 2 skipped; the sole failure is tests/test_changelog_fragment_contract.py::test_repository_changelog_is_rendered_from_current_fragments. Rust/PyO3, package/reinstall/release acceptance, explicit GPU no-skip, fuzz, ClusterFuzzLite, Security Scan, and SAST are successful. Root cause is deterministic and branch-local: docs/changelog.d/397-paired-rating-range-evidence.md is authoritative while the managed CHANGELOG.md fragment block is stale.

Before writing, refetch the branch head and abort if it moved. If unchanged, run python scripts/render_changelog_fragments.py --update CHANGELOG.md, verify python scripts/render_changelog_fragments.py --check CHANGELOG.md, run the focused changelog contract test, and commit only the deterministic changelog synchronization. Do not alter Rust rating-range arithmetic, PyO3 marshalling, Python validation, scoring/report schemas, dependencies, credentials, or workflows. Let normal exact-head CI/security/review run afterward.

Copy link
Copy Markdown
Contributor Author

@opencode-agent address

Operate only on exact current Draft head f11f46c3a4945c76779c545ba9d9cf9207410de0; abort without writing if it moved. Exact-head CI 31309352764 has exactly one deterministic Python failure: tests/test_changelog_fragment_contract.py::test_repository_changelog_is_rendered_from_current_fragments; 2,940 other tests pass with 2 skips, and Rust, package/reinstall/release acceptance, GPU-smoke, fuzz, ClusterFuzzLite, Security Scan, and SAST are green on this same head.

Perform only the release-note synchronization repair:

  1. run python scripts/render_changelog_fragments.py --update CHANGELOG.md;
  2. run python scripts/render_changelog_fragments.py --check CHANGELOG.md;
  3. run pytest tests/test_changelog_fragment_contract.py tests/test_paired_rating_range_evidence.py tests/test_paired_rating_range_delegation.py -q plus the focused Rust/PyO3 rating-range tests already present on the branch;
  4. commit only the generated CHANGELOG.md change if those checks pass.

Keep Draft. Do not alter rating-range arithmetic, PyO3 ownership, public API semantics, unrelated AGENTS/CLAUDE content, dependencies, workflows, review identities, version, release state, or issue #397.

Copy link
Copy Markdown
Contributor Author

@opencode-agent address

Reacquire one bounded integration writer lease only if a final refetch still shows Draft source head f11f46c3a4945c76779c545ba9d9cf9207410de0 and protected main exactly 8db4bf358b0a469915d6c5e336054f4a4f9c6b46; abort without writing if either moved or another active writer/source receipt appears. All prior same-head handoffs were bound to protected main 7516031... and are now stale.

The feature implementation itself already has strong predecessor evidence: exact CI previously reached 1 failed, 2940 passed, 2 skipped, with the sole failure deterministic changelog render parity; Rust/PyO3, package/reinstall/release acceptance, explicit GPU-no-skip, fuzz, ClusterFuzzLite, Security Scan and SAST were green. Do not change the Rust rating-range arithmetic unless current integration tests prove a source defect.

Perform the smallest current-main integration repair:

  1. reconcile exact protected main non-destructively, preserving 🧪 Add tests for Luce Spectral Ranking (LSR) #590 and all accepted-main files while retaining the unique paired-rating-range Rust core/PyO3/Python-validation/tests/doctoring/fragment slice;
  2. run python scripts/render_changelog_fragments.py --update CHANGELOG.md and then --check so all accepted-main and branch fragments are represented exactly;
  3. run focused tests/test_changelog_fragment_contract.py, paired-rating-range public/delegation tests and the focused Rust/PyO3 rating-range tests, then relevant full Python/Rust coverage/docstring/package validation and git diff --check;
  4. commit only deterministic reconciliation/changelog output plus a minimal source correction if a focused current-main integration test actually proves one;
  5. refresh the PR body to final exact head/base/evidence and keep Draft for fresh exact-head CI/security/SAST/current-head review.

Preserve Rust-owned descriptive arithmetic, thin PyO3 marshalling, Python validation-only behavior, descriptive-not-inferential interpretation, and no universal acceptance threshold. No essay-report schema, provider SDK, generalized rMFRM, dependencies/workflows/credentials/version/release or canonical #604 docs changes.

Copy link
Copy Markdown
Contributor Author

@opencode-agent address

The prior current-main integration handoff has had no receipt/reaction and no source movement for more than two hours. Reacquire one bounded writer lease only if a final refetch still shows Draft head f11f46c3a4945c76779c545ba9d9cf9207410de0, protected main 8db4bf358b0a469915d6c5e336054f4a4f9c6b46, and no current-head source-writer receipt; abort if any identity moved.

Do not change the validated paired-rating-range arithmetic unless current integration tests prove a source defect. Perform only the smallest integration repair: reconcile protected main non-destructively, preserving #590 and the unique rating-range Rust/PyO3/Python-validation/tests/doctoring/fragment slice; run the authoritative changelog renderer --update then --check; run the focused rating-range/delegation/changelog tests and Rust/PyO3 checks; commit only the integration/changelog synchronization needed for GREEN. Keep Draft and do not change dependencies, workflows, credentials, version/release, approval/merge state, or issue #397.

Copy link
Copy Markdown
Contributor Author

@opencode-agent address

Take a bounded writer lease only if a final refetch still shows Draft head fa5ad82116e32b177d48cb6e31b9f41d2bd92788 over protected main a6b7ecc680b73a277714a795143c7a27125022c3; abort without writing if either moved or another source writer appears.

The paired rating-range branch has already been reconciled non-destructively with current protected main as a two-parent merge commit and now retains only the 14 Rust/PyO3/Python/tests/doctoring/fragment paths belonging to this diagnostic. Preserve Rust ownership and current-main report/scaling behavior.

Complete only deterministic acceptance cleanup:

  1. Run python scripts/render_changelog_fragments.py --update CHANGELOG.md then python scripts/render_changelog_fragments.py --check CHANGELOG.md, preserving current-main notes plus docs/changelog.d/397-paired-rating-range-evidence.md through the repository renderer.
  2. Run focused Python tests pytest -q tests/test_paired_rating_range_evidence.py tests/test_paired_rating_range_delegation.py tests/test_changelog_fragment_contract.py and the focused Rust/PyO3 rating-range tests, plus formatting/git diff --check as required.
  3. Commit only deterministic renderer/formatting corrections required by those checks; do not change the diagnostic fields/equations or add a Python numerical fallback.

Keep Draft. Do not change essay-report schema, add provider SDK/feedback/new likelihood/generalized rMFRM/latent-space terms, alter dependencies/workflows/version/release, modify canonical #604, mark Ready, approve, merge, or close #397. Stop after exact-head deterministic evidence.

Copy link
Copy Markdown
Contributor Author

@opencode-agent address

Take a bounded writer lease on PR #579 only if a final refetch still shows exact Draft head fa5ad82116e32b177d48cb6e31b9f41d2bd92788 and protected main f43a466b1441b27bd2ac4a71be8aa3e4f08c8e8f; abort without writing if either moved or another source writer is active. Existing handoffs are predecessor-head evidence only.

The Rust-owned paired rating-range implementation, PyO3 marshalling, Python validation/transport, direct-delegation tests and scientific boundary are already present. Exact-head Security, SAST and ClusterFuzzLite are green; the known remaining repository integration failure is managed changelog parity, and protected main has since advanced through #618.

Execute only deterministic integration cleanup:

  1. reconcile protected main non-destructively, preserving accepted-main behavior and only feat(validation): add paired rating range evidence #579's unique rating-range Rust/PyO3/Python/tests/doctoring/fragment slice;
  2. run python scripts/render_changelog_fragments.py --update, then --check;
  3. run the focused paired-rating-range Python/Rust/PyO3 tests, pytest -q tests/test_changelog_fragment_contract.py, and git diff --check;
  4. push only if focused evidence is green and the exact branch lease still holds.

Keep Draft. Do not change the essay report schema, add provider/feedback generation, generalized rMFRM or latent-space arithmetic, modify dependencies/workflows/version/release, or touch canonical architecture PR #604.

seonghobae commented Aug 10, 2026

Copy link
Copy Markdown
Contributor Author

Superseded bookkeeping note: the exact-current writer handoff for head fa5ad82116e32b177d48cb6e31b9f41d2bd92788 over protected main f43a466b1441b27bd2ac4a71be8aa3e4f08c8e8f already exists earlier in this conversation. This duplicate request is withdrawn; do not create an additional writer from this comment.

Copy link
Copy Markdown
Contributor Author

@opencode-agent address

Take a bounded writer lease only if a final refetch still shows Draft head fa5ad82116e32b177d48cb6e31b9f41d2bd92788 and protected main f43a466b1441b27bd2ac4a71be8aa3e4f08c8e8f; abort without writing if either moved or another current-head source writer appears. Prior handoffs are predecessor-head evidence only.

Current exact-head Security Scan 31335042544, SAST 31335042465, and ClusterFuzzLite 31335042458 are successful; CI 31335042488 is not merge evidence and must be re-evaluated after current-main reconciliation. Preserve only the bounded paired rating-range slice: Rust owns every descriptive statistic; PyO3 marshals; Python validates/transports without recomputation; degenerate relative evidence stays unavailable rather than NaN/Inf; no universal threshold or generalized rMFRM claim.

Non-destructively reconcile protected main, retaining #618 and all accepted-main behavior, then run the focused paired-rating-range Rust/PyO3/Python delegation/parity tests, render/check authoritative changelog, formatting/lint and git diff --check; fix only genuine integration failures and commit one bounded reconciliation/cleanup. Keep Draft. Do not change essay-report schema, add provider SDKs, new likelihood/latent-space/rMFRM work, alter architecture PR #604, dependencies/workflows/version/release, mark Ready, approve, merge, close #397, or create another PR. Stop if exact head/base moves while writing.

Copy link
Copy Markdown
Contributor Author

@opencode-agent address

Take a bounded writer lease only if a final refetch still shows Draft head c4a290b87b7676c4fc59c28b923377a85319ee95 and protected main f43a466b1441b27bd2ac4a71be8aa3e4f08c8e8f; abort if either moved or another current-head source writer appears. This exact head is now a non-destructive two-parent reconciliation of the paired rating-range Rust/PyO3/Python slice over current protected main; predecessor handoffs are stale.

Do not change the diagnostic semantics. Run focused Rust rating-range tests, PyO3/delegation tests, Python evidence tests, then synchronize only managed release notes using the authoritative changelog renderer (--update then --check), run the changelog contract, formatting/lint and git diff --check, and commit the minimum renderer result if GREEN. Preserve Rust ownership of every descriptive statistic, thin PyO3 marshalling, Python validation/transport only, unavailable degenerate relative ratios rather than NaN/Inf, and no universal threshold/generalized rMFRM claim. Keep Draft. Do not change essay report schemas, add providers/likelihood/latent-space/rMFRM work, alter dependencies/workflows/version/release/canonical docs #604, mark Ready, approve, merge, close #397, or create another PR. Stop if exact head/base moves during the write.

Copy link
Copy Markdown
Contributor Author

@jules address

Fallback bounded writer handoff for exact Draft head c4a290b87b7676c4fc59c28b923377a85319ee95 over protected main f43a466b1441b27bd2ac4a71be8aa3e4f08c8e8f. The prior exact-head OpenCode handoff has no receipt/reaction and no source movement after the exact-current CI completed; treat it as inactive, but perform a final head/base/comment refetch before writing and abort if another writer appears or either ref moved.

Do not change paired rating-range diagnostic semantics. Exact-head Rust/PyO3, package/reinstall, GPU, fuzz, ClusterFuzzLite, Security Scan and SAST are green; the feature tests are green and the remaining Python failure is deterministic managed changelog parity. Run focused Rust rating-range, PyO3/delegation and Python evidence tests, then only python scripts/render_changelog_fragments.py --update CHANGELOG.md and --check CHANGELOG.md, the changelog contract, formatting/lint as applicable, and git diff --check. Commit only the generated CHANGELOG.md synchronization if all focused verification is green. Preserve Rust ownership of all descriptive arithmetic, thin PyO3 marshalling, Python validation/transport, and degenerate unavailable ratios. Keep Draft. Do not change source/tests/dependencies/workflows/version/release/canonical docs #604, mark Ready, approve, merge, close #397, or open another PR. Stop writing if exact head/base changes.

Copy link
Copy Markdown
Contributor Author

@jules address

Superseding paired-rating-range integration handoff after both CodeQL dependency merges. Fresh identities: Draft #579 exact head c4a290b87b7676c4fc59c28b923377a85319ee95; protected main a7be9eb8ca0b807364173f8471fc300e3cf9350f; compare = diverged, ahead 19 / behind 2, with the net feature limited to the Rust/PyO3/Python rating-range slice, tests, doctoring/plans and changelog fragment. Prior handoffs were bound to older bases and explicitly abort on base movement. Refetch head/main/comments before writing and abort if either moves or another current-head source writer appears.

Do not change diagnostic semantics. Predecessor exact-head evidence has Rust/PyO3/package/GPU/fuzz/ClusterFuzzLite/Security/SAST and feature tests GREEN with only deterministic managed changelog parity outstanding. Reconcile protected main non-destructively, preserving both CodeQL init/analyze 4.37.6 pins. Run focused Rust rating-range, PyO3/delegation and Python evidence tests; then only repository-authoritative CHANGELOG render/check, changelog contract, formatting/lint and git diff --check; commit the minimum integration/renderer result if GREEN. Preserve Rust ownership of all descriptive arithmetic, thin PyO3 marshalling, Python validation/transport, unavailable degenerate ratios instead of NaN/Inf, and no universal threshold/generalized rMFRM claim.

Keep Draft. No essay-report/provider/likelihood/latent-space/rMFRM/dependency/workflow/version/release/canonical-docs #604/Ready/approval/merge/issue-closure expansion. Stop source writes after one coherent verified update; fresh exact-head full CI/Security/SAST/review returns to the maintainer loop.

@seonghobae
seonghobae force-pushed the feat/essay-range-compression-evidence branch from c4a290b to 0d3ba94 Compare August 11, 2026 05:20
@seonghobae
seonghobae marked this pull request as ready for review August 11, 2026 05:20
@seonghobae
seonghobae marked this pull request as draft August 11, 2026 05:21
@seonghobae
seonghobae force-pushed the feat/essay-range-compression-evidence branch from 0d3ba94 to c4a290b Compare August 11, 2026 05:21

Copy link
Copy Markdown
Contributor Author

@opencode-agent address

Fresh current-main reconciliation handoff for Draft #579. Immediately refetch exact source head, protected main, comments/reviews and the rating-range/PyO3/export paths; proceed only if source remains c4a290b87b7676c4fc59c28b923377a85319ee95, live main is still compatible with d2301dccb7d39a794d08cc96ea8c858b9ff49125, and no other writer targets these files. Abort on any movement.

Fresh compare is diverged, ahead 19 / behind 157, merge base f43a466b1441b27bd2ac4a71be8aa3e4f08c8e8f. Preserve only the paired rating-range Rust/PyO3/Python/tests/doctoring/changelog slice; current protected main has materially changed PyO3 registration, validation/backend/security/support/release evidence, so reconcile non-destructively rather than replaying old ancestry.

Revalidate the feature itself on the reconciled head: Rust remains the sole descriptive-arithmetic owner; Python performs bounded validation/marshalling only; paired observations remain exact same-case evidence; population-divisor SD, span/distinct-category ratios, endpoint gaps and degenerate-reference unavailable semantics remain unchanged; no universal range-compression threshold or validity claim is introduced. Re-run direct field-by-field Rust↔Python delegation, caller immutability, degenerate/error tests and realistic paired range-compression fixtures, then full same-head gates and changelog render/check. Keep Draft; do not widen to generalized rMFRM, essay report schema/provider/likelihood work, workflows/dependencies/version/release or canonical #604/#621 docs.

Copy link
Copy Markdown
Contributor Author

@opencode-agent address

Fresh exact-current reconciliation/replacement handoff for Draft #579 / issue #397. Before any source write, refetch exact branch head c4a290b87b7676c4fc59c28b923377a85319ee95, protected main bb30b196d2f83df5117a6bebf5e9680faf18c841, comments/reviews/threads, and the current PyO3 registration/export paths; abort if either ref moves or another writer targets the rating-range files. The previous current-main handoff 5251216619 was explicitly bound to d2301dcc... and therefore self-invalidated when main moved.

Fresh compare is diverged, ahead 19 / behind 198 from merge base f43a466b1441b27bd2ac4a71be8aa3e4f08c8e8f. The unique product slice is small and explicit: Rust rating_range arithmetic, thin PyO3 exposure, Python validation/immutable transport/public export, paired-rating-range tests, doctoring and changelog material. Because protected main has materially evolved PyO3 registration/export/security/coverage conventions, do not replay old ancestry blindly. Derive the exact unique diff first and prefer a clean-lineage replacement from live main if reconciliation is conflict-heavy; if a replacement is created, create exactly one, absorb every non-duplicative file/contract, document the lineage, and close #579 so there is no competing implementation writer.

Preserve the intended scientific contract: descriptive paired-category support/dispersion evidence only; Rust owns min/max/distinct counts/spans/population-divisor SDs/ratios/endpoint gaps and conservative range-compression flags; degenerate reference span/SD returns unavailable ratios rather than NaN/Inf; Python rejects invalid/Boolean/non-integral labels before coercion, marshals immutable arrays, and never recomputes statistics; no universal threshold, generalized rMFRM, construct-validity/fairness claim, provider SDK or generated feedback. Reuse the current package's canonical PyO3 registration pattern rather than resurrecting obsolete extension-module registration.

Re-establish focused RED→GREEN/parity against the integrated/replacement branch, then run Rust unit/integration, PyO3/public delegation, Python rating-range tests, meaningful statement/branch/docstrings, repository-authoritative changelog render/check, git diff --check, full Python 3.12/3.14, Rust/PyO3/package/reinstall/GPU-existing/fuzz, Security Scan and SAST. Keep Draft until current-head review and zero valid unresolved findings. Do not widen into essay report schemas, new likelihoods, dependencies/workflows/version/release or canonical docs #604.

@seonghobae

Copy link
Copy Markdown
Contributor Author

Superseded by surgical #748 (or next number) on current main.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant