canvas-humanizer-looplisted
Install: claude install-skill X-isdoingreat/canvas-pilot
# canvas-humanizer-loop
Wrap `canvas-humanizer` in a bounded repair loop. The purpose is to catch
damage introduced by rewriting, not to keep rewriting until an external score
changes.
## Inputs and boundaries
Accept the same paths and voice inputs as `canvas-humanizer`, plus:
- `course_id`, `assignment_id`, and the stable assignment `work_dir`;
- optional `spec_path`, `rubric_path`, `source_paths`, and `hard_locks`;
- `max_iter`, default 3 and hard-capped at 3.
Require `work_dir` to end in
`course-<course_id>__assignment-<assignment_id>`. Write loop artifacts below
`<output_dir>/_loop_iter_<N>/` and `loop_log.json` beside the final output.
Validate the path against `src.course_artifacts.stable_work_dir` before writing.
This skill performs local file work only. It does not call Canvas, write an
assignment `result.json`, or declare submission readiness. The caller must run
its course-level verification after the loop.
Use `src.humanizer_segmentation.split_sentences` and
`paragraph_segment_counts`; do not invent another splitter.
## Iteration layout
```text
_loop_iter_1/
humanized.docx
humanizer_log.json
audit-a.json
audit-b.json
audit-c.json
merged-audit.json
repair-log.json
_loop_iter_2/
...
loop_log.json
```
Use atomic JSON/text writes. Keep the original draft and every iteration so the
best safe artifact can be recovered.
## Stage 1: preflight
1. Read the complete original, spec, rubric, and necessary source excerpts.
2. Confirm hard locks are uniq