Skip to content

Add trust-oriented provenance and recovery surfaces to Night Shift#32

Closed
Fuiste wants to merge 4 commits into
mainfrom
codex/research-trustfirst-agents
Closed

Add trust-oriented provenance and recovery surfaces to Night Shift#32
Fuiste wants to merge 4 commits into
mainfrom
codex/research-trustfirst-agents

Conversation

@Fuiste

@Fuiste Fuiste commented Apr 13, 2026

Copy link
Copy Markdown
Owner

Summary

  • add night-shift provenance, night-shift doctor, and night-shift resume --explain
  • persist per-run provenance.json and surface confidence posture in status, report, and dashboard payloads
  • add deterministic confidence and recovery assessment logic for run inspection
  • update docs and QA skill guidance to cover provenance, doctor, and the new trust signals
  • add CLI and trust-surface tests for the new behavior

Testing

  • gleam test

@Fuiste Fuiste left a comment

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I found one blocking issue in the recovery path.

  • src/night_shift/usecase/doctor.gleam:188-191 asks git.has_changes to log into filepath.join(task.worktree_path, ".night-shift-doctor.log"). But src/night_shift_shell.erl:57-65 truncates or creates the log file before the command runs. On an otherwise clean interrupted worktree, the probe itself therefore creates an untracked file inside the worktree, and git status --short --untracked-files=all reports dirty. That means doctor will classify clean running tasks as manual_attention instead of safe_to_resume, which defeats the main purpose of resume --explain / doctor. The log needs to live outside the inspected worktree (for example under the run's logs/ directory).

Fuiste commented Apr 14, 2026

Copy link
Copy Markdown
Owner Author

QA completed on the combined stack branch and the work has been superseded by #35.

What I validated:

  • combined-branch end-to-end QA in the scratch repo
  • intentional interruption followed by doctor, resume --explain, and resume
  • successful verification, provenance/runtime artifacts, and delivery on the resumed run

Closing this PR in favor of the QAed combined branch.

@Fuiste Fuiste closed this Apr 14, 2026
Fuiste added a commit that referenced this pull request Apr 14, 2026
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