Answer architecture round 1: Failure and the file modules get truthful homes, the interrupt question is a pure function, the judge grounds on what it saw
This commit is contained in:
@@ -3,9 +3,9 @@ import os
|
||||
import pathlib
|
||||
import sys
|
||||
|
||||
from file_io.failure import Failure
|
||||
from failure import Failure
|
||||
from loop_claude.claude_code.transcript import first_timestamped_line
|
||||
from file_io.writes import make_private, replace_file
|
||||
from files.writes import make_private, replace_file
|
||||
from loop_claude.paths import Paths
|
||||
from loop_claude.claude_code.session import session_files
|
||||
|
||||
@@ -24,7 +24,8 @@ def archive(project_key: str, path: str, task: str, outcome: str, paths: Paths)
|
||||
return unkept
|
||||
copy = folder / f"{hashlib.sha256(raw).hexdigest()}.jsonl"
|
||||
outcomes = copy.with_suffix(".outcomes.md")
|
||||
if copy.exists():
|
||||
# A copy whose outcomes file is missing is written afresh, outcomes first.
|
||||
if copy.exists() and outcomes.exists():
|
||||
return add_outcome(outcomes, outcome)
|
||||
# The copy lands last, so a copy on disk always has its outcomes and its session's files beside it.
|
||||
for dest, data in ((outcomes, f"Task: {task}\n\n{outcome}\n".encode()), (copy, raw)):
|
||||
|
||||
Reference in New Issue
Block a user