diff --git a/README.md b/README.md index a9978de..c7276e6 100644 --- a/README.md +++ b/README.md @@ -145,11 +145,12 @@ python3 scripts/yao.py package-verify . --package-dir dist --require-zip python3 scripts/yao.py install-simulate . --package-dir dist python3 scripts/yao.py upgrade-check . --previous-package-json registry/examples/yao-meta-skill-1.0.0.json python3 scripts/yao.py world-class-evidence . -python3 scripts/yao.py world-class-submission-kit . --output-dir /tmp/yao-world-class-submission-kit -python3 scripts/yao.py world-class-ledger . -python3 scripts/yao.py world-class-intake . -python3 scripts/yao.py world-class-submission-review . -python3 scripts/yao.py world-class-runbook . +SUBMISSIONS_DIR="${SUBMISSIONS_DIR:-evidence/world_class/submissions}" +python3 scripts/yao.py world-class-submission-kit . --output-dir "$SUBMISSIONS_DIR" +python3 scripts/yao.py world-class-intake . --submissions-dir "$SUBMISSIONS_DIR" +python3 scripts/yao.py world-class-submission-review . --submissions-dir "$SUBMISSIONS_DIR" +python3 scripts/yao.py world-class-ledger . --submissions-dir "$SUBMISSIONS_DIR" +python3 scripts/yao.py world-class-runbook . --submissions-dir "$SUBMISSIONS_DIR" python3 scripts/yao.py world-class-claim-guard . python3 scripts/yao.py benchmark-reproducibility . ``` diff --git a/evidence/world_class/README.md b/evidence/world_class/README.md index dda9f53..f50106a 100644 --- a/evidence/world_class/README.md +++ b/evidence/world_class/README.md @@ -7,9 +7,11 @@ The templates in `templates/` are review aids only. They do not count as accepte Run: ```bash -python3 scripts/yao.py world-class-submission-kit . --output-dir /tmp/yao-world-class-submission-kit -python3 scripts/yao.py world-class-intake . -python3 scripts/yao.py world-class-submission-review . +SUBMISSIONS_DIR="${SUBMISSIONS_DIR:-evidence/world_class/submissions}" +python3 scripts/yao.py world-class-submission-kit . --output-dir "$SUBMISSIONS_DIR" +python3 scripts/yao.py world-class-intake . --submissions-dir "$SUBMISSIONS_DIR" +python3 scripts/yao.py world-class-submission-review . --submissions-dir "$SUBMISSIONS_DIR" +python3 scripts/yao.py world-class-ledger . --submissions-dir "$SUBMISSIONS_DIR" ``` The intake validator checks: diff --git a/scripts/render_benchmark_reproducibility.py b/scripts/render_benchmark_reproducibility.py index ba60929..1ca3f40 100644 --- a/scripts/render_benchmark_reproducibility.py +++ b/scripts/render_benchmark_reproducibility.py @@ -126,22 +126,22 @@ REPRODUCTION_COMMANDS = [ }, { "label": "world-class evidence ledger", - "command": "python3 scripts/yao.py world-class-ledger .", + "command": "python3 scripts/yao.py world-class-ledger . --submissions-dir evidence/world_class/submissions", "evidence": "reports/world_class_evidence_ledger.json", }, { "label": "world-class evidence intake", - "command": "python3 scripts/yao.py world-class-intake .", + "command": "python3 scripts/yao.py world-class-intake . --submissions-dir evidence/world_class/submissions", "evidence": "reports/world_class_evidence_intake.json", }, { "label": "world-class submission review", - "command": "python3 scripts/yao.py world-class-submission-review .", + "command": "python3 scripts/yao.py world-class-submission-review . --submissions-dir evidence/world_class/submissions", "evidence": "reports/world_class_submission_review.json", }, { "label": "world-class operator runbook", - "command": "python3 scripts/yao.py world-class-runbook .", + "command": "python3 scripts/yao.py world-class-runbook . --submissions-dir evidence/world_class/submissions", "evidence": "reports/world_class_operator_runbook.json", }, { diff --git a/scripts/render_review_waivers.py b/scripts/render_review_waivers.py index fcd6815..5936148 100644 --- a/scripts/render_review_waivers.py +++ b/scripts/render_review_waivers.py @@ -201,7 +201,10 @@ def world_class_boundary(skill_dir: Path) -> dict[str, Any] | None: "Keep claim guard active until ledger summary.ready_to_claim_world_class is true.", ], "suggested_evidence": "reports/world_class_evidence_ledger.md", - "suggested_command": "python3 scripts/yao.py world-class-ledger . && python3 scripts/yao.py world-class-claim-guard .", + "suggested_command": ( + "python3 scripts/yao.py world-class-ledger . --submissions-dir evidence/world_class/submissions " + "&& python3 scripts/yao.py world-class-claim-guard ." + ), "world_class_boundary": "Non-waivable completion boundary.", } diff --git a/scripts/render_world_class_evidence_plan.py b/scripts/render_world_class_evidence_plan.py index 31c097e..48d339c 100644 --- a/scripts/render_world_class_evidence_plan.py +++ b/scripts/render_world_class_evidence_plan.py @@ -149,7 +149,7 @@ def build_task(item: dict[str, Any]) -> dict[str, Any]: ) intake_runbook = [ f"Copy evidence/world_class/templates/{item['key']}.intake.json to evidence/world_class/submissions/{item['key']}.json and fill only real evidence fields.", - "python3 scripts/yao.py world-class-intake .", + "python3 scripts/yao.py world-class-intake . --submissions-dir evidence/world_class/submissions", ] intake_artifacts = [ "evidence/world_class/intake.schema.json", diff --git a/scripts/review_studio_actions.py b/scripts/review_studio_actions.py index e7aa3ef..7f8a2c5 100644 --- a/scripts/review_studio_actions.py +++ b/scripts/review_studio_actions.py @@ -220,7 +220,11 @@ ACTION_GUIDANCE: dict[str, dict[str, Any]] = { {"path": "reports/runtime_permission_probes.md", "label": "runtime permission probes", "kind": "report", "patterns": ["# Runtime"]}, {"path": "reports/adoption_drift_report.md", "label": "adoption drift", "kind": "report", "patterns": ["# Adoption"]}, ], - "verification": "python3 scripts/yao.py world-class-runbook . && python3 scripts/yao.py world-class-ledger . && python3 scripts/yao.py review-studio .", + "verification": ( + "python3 scripts/yao.py world-class-runbook . --submissions-dir evidence/world_class/submissions " + "&& python3 scripts/yao.py world-class-ledger . --submissions-dir evidence/world_class/submissions " + "&& python3 scripts/yao.py review-studio ." + ), }, "registry-audit": { "summary": "补齐 registry package metadata、checksum、license、owner、review cadence 和 install evidence。", diff --git a/tests/verify_benchmark_reproducibility.py b/tests/verify_benchmark_reproducibility.py index 8b9e4f2..5c60bfc 100644 --- a/tests/verify_benchmark_reproducibility.py +++ b/tests/verify_benchmark_reproducibility.py @@ -160,10 +160,10 @@ def main() -> None: assert artifacts["reports/world_class_claim_guard.json"]["exists"], artifacts assert artifacts["reports/python_compatibility.json"]["exists"], artifacts assert any(command["command"] == "make ci-test" for command in payload["reproduction_commands"]), payload - assert any(command["command"] == "python3 scripts/yao.py world-class-ledger ." for command in payload["reproduction_commands"]), payload - assert any(command["command"] == "python3 scripts/yao.py world-class-intake ." for command in payload["reproduction_commands"]), payload - assert any(command["command"] == "python3 scripts/yao.py world-class-submission-review ." for command in payload["reproduction_commands"]), payload - assert any(command["command"] == "python3 scripts/yao.py world-class-runbook ." for command in payload["reproduction_commands"]), payload + assert any(command["command"] == "python3 scripts/yao.py world-class-ledger . --submissions-dir evidence/world_class/submissions" for command in payload["reproduction_commands"]), payload + assert any(command["command"] == "python3 scripts/yao.py world-class-intake . --submissions-dir evidence/world_class/submissions" for command in payload["reproduction_commands"]), payload + assert any(command["command"] == "python3 scripts/yao.py world-class-submission-review . --submissions-dir evidence/world_class/submissions" for command in payload["reproduction_commands"]), payload + assert any(command["command"] == "python3 scripts/yao.py world-class-runbook . --submissions-dir evidence/world_class/submissions" for command in payload["reproduction_commands"]), payload assert any(command["command"] == "python3 scripts/yao.py world-class-claim-guard ." for command in payload["reproduction_commands"]), payload assert any(command["command"] == "python3 scripts/yao.py python-compat ." for command in payload["reproduction_commands"]), payload assert any("provider-backed" in item for item in payload["limitations"]), payload["limitations"] @@ -178,7 +178,7 @@ def main() -> None: assert "## Evidence Bundle" in markdown, markdown assert "reports/benchmark_methodology.md" in markdown, markdown assert "reports/world_class_operator_runbook.html" in markdown, markdown - assert "python3 scripts/yao.py world-class-runbook ." in markdown, markdown + assert "python3 scripts/yao.py world-class-runbook . --submissions-dir evidence/world_class/submissions" in markdown, markdown assert "make ci-test" in markdown, markdown print(json.dumps({"ok": True}, ensure_ascii=False, indent=2)) diff --git a/tests/verify_review_studio.py b/tests/verify_review_studio.py index 97ac71e..6ee762f 100644 --- a/tests/verify_review_studio.py +++ b/tests/verify_review_studio.py @@ -474,6 +474,7 @@ def main() -> None: }, world_class_action assert all(item["exists"] for item in world_class_action["source_refs"]), world_class_action assert "world-class-runbook" in world_class_action["verification_command"], world_class_action + assert "--submissions-dir evidence/world_class/submissions" in world_class_action["verification_command"], world_class_action assert "reports/world_class_operator_runbook.html" in world_class_action["source_fix"], world_class_action assert full_payload["data"]["world_class_evidence_ledger"]["summary"]["pending_count"] == 4, full_payload["data"]["world_class_evidence_ledger"] assert full_payload["data"]["world_class_evidence_intake"]["summary"]["decision"] == "awaiting-submissions", full_payload["data"]["world_class_evidence_intake"] diff --git a/tests/verify_review_waivers.py b/tests/verify_review_waivers.py index 62b817f..248565c 100644 --- a/tests/verify_review_waivers.py +++ b/tests/verify_review_waivers.py @@ -119,6 +119,7 @@ def main() -> None: assert candidates["world-class-evidence"]["waiver_allowed"] is False, candidates assert candidates["world-class-evidence"]["status"] == "cannot-waive", candidates assert "Non-waivable completion boundary" in candidates["world-class-evidence"]["world_class_boundary"], candidates + assert "--submissions-dir evidence/world_class/submissions" in candidates["world-class-evidence"]["suggested_command"], candidates root_markdown = root_report_md.read_text(encoding="utf-8") assert "Candidate Actions" in root_markdown, root_markdown assert "World-class evidence completion cannot be waived" in root_markdown, root_markdown diff --git a/tests/verify_world_class_evidence_intake.py b/tests/verify_world_class_evidence_intake.py index 4780b04..5e37ea9 100644 --- a/tests/verify_world_class_evidence_intake.py +++ b/tests/verify_world_class_evidence_intake.py @@ -100,9 +100,25 @@ def provider_submission(*, valid: bool, artifact_path: str = "reports/output_exe } +def assert_documented_submission_commands() -> None: + expected_fragments = [ + 'SUBMISSIONS_DIR="${SUBMISSIONS_DIR:-evidence/world_class/submissions}"', + 'world-class-submission-kit . --output-dir "$SUBMISSIONS_DIR"', + 'world-class-intake . --submissions-dir "$SUBMISSIONS_DIR"', + 'world-class-submission-review . --submissions-dir "$SUBMISSIONS_DIR"', + 'world-class-ledger . --submissions-dir "$SUBMISSIONS_DIR"', + ] + for relative_path in ("README.md", "evidence/world_class/README.md"): + text = (ROOT / relative_path).read_text(encoding="utf-8") + for fragment in expected_fragments: + assert fragment in text, (relative_path, fragment) + assert "/tmp/yao-world-class-submission-kit" not in text, relative_path + + def main() -> None: shutil.rmtree(TMP, ignore_errors=True) TMP.mkdir(parents=True, exist_ok=True) + assert_documented_submission_commands() default_json = TMP / "world_class_evidence_intake.json" default_md = TMP / "world_class_evidence_intake.md" payload = run_intake("--output-json", str(default_json), "--output-md", str(default_md)) diff --git a/tests/verify_world_class_evidence_plan.py b/tests/verify_world_class_evidence_plan.py index 548eaf1..1e16d69 100644 --- a/tests/verify_world_class_evidence_plan.py +++ b/tests/verify_world_class_evidence_plan.py @@ -55,7 +55,7 @@ def main() -> None: }, tasks assert set(requirements) == set(tasks), requirements assert any("--provider-runner openai" in command for command in tasks["provider-holdout"]["runbook"]), tasks["provider-holdout"] - assert any("world-class-intake" in command for command in tasks["provider-holdout"]["runbook"]), tasks["provider-holdout"] + assert any("world-class-intake . --submissions-dir evidence/world_class/submissions" in command for command in tasks["provider-holdout"]["runbook"]), tasks["provider-holdout"] assert any("evidence/world_class/templates/provider-holdout.intake.json" in command for command in tasks["provider-holdout"]["runbook"]), tasks["provider-holdout"] assert any("output_review_decisions.json" in command for command in tasks["human-adjudication"]["runbook"]), tasks["human-adjudication"] assert any("runtime-permissions" in command for command in tasks["native-permission-enforcement"]["runbook"]), tasks["native-permission-enforcement"]