diff --git a/bin/judge_replay/test_judge_replay.py b/bin/judge_replay/test_judge_replay.py index 90a26fc4..fd037710 100644 --- a/bin/judge_replay/test_judge_replay.py +++ b/bin/judge_replay/test_judge_replay.py @@ -403,6 +403,14 @@ class JudgeArchivedRuns(unittest.TestCase): self.assertIsInstance(self.judged(evidence="Do it.")[0], Unfinished) self.assertIsInstance(self.judged(evidence="Do it. ... Use Postgres.")[0], Unfinished) + def test_splits_the_prompt_into_the_premises_the_task_and_the_transcript_at_the_first_heading_of_each(self): + heading = transcript_heading(LOOP_CLAUDE) + again = self.PROMPT.replace("Worker chose option B.", f"Worker chose option B. {heading}Again.", 1) + for prompt in (self.PROMPT, again): + grounds = grounds_of(prompt, self.ENTRIES) + self.assertEqual((grounds.quotable, grounds.task), ("HEAD: Ship fast.", "Do it.")) + self.assertEqual(grounds_of(self.PROMPT, self.ENTRIES).shown, "Worker chose option B.\n[human] Use Postgres.") + def test_keeps_the_cost_and_the_run_of_a_rejected_reply(self): rejected, _ = self.judged(evidence="Never said.") self.assertEqual((rejected.cost, rejected.run.prompt), (0.25, self.PROMPT))