# training_evaluation.py def promotion_readiness(checkpoint, runs, evaluations): successful = [r for r in runs if r["checkpoint"] == checkpoint and r["exitCode"] == 0] passing = [e for e in evaluations if e["checkpoint"] == checkpoint and e["passed"]] held_out = any(e.get("heldOut") for e in passing) independent = any(e.get("independentReview") for e in passing) return {"promotionCandidate": bool(successful and passing and held_out and independent), "accepted": False, "truth": {"trainingReceiptIsCapabilityProof": False, "evaluationPassIsProductionAcceptance": False}}