step-6: add fix_chunks.py, make step-6 self-contained

- verify_chunks.py now reads from step-6/<stem>/chunks.json and
  auto-copies from step-5 on first run (input and output both in step-6)
- fix_chunks.py: new script that applies fixes directly on chunks.json
  (merge too-short/incomplete, split too-long, remove empty, add prefix)
  supports --dry-run to preview changes before applying
- step6-fix.md skill updated to use fix_chunks.py workflow:
  dry-run → user approval → apply → re-verify
This commit is contained in:
2026-04-13 14:03:41 +02:00
parent f80b77ab93
commit 386af44c83
5 changed files with 719 additions and 2 deletions
+2 -2
View File
@@ -422,10 +422,10 @@ da solo sarebbe ambiguo.
**Tipo:** automatico
**Input:** `step-5/<stem>/chunks.json`
**Output:** report problemi + statistiche
**Script:** `scripts/verify_chunks.py`
**Script:** `step-6/verify_chunks.py`
```bash
python scripts/verify_chunks.py step-5/documento/chunks.json
python step-6/verify_chunks.py --stem documento
```
Analizza ogni chunk e segnala i problemi. Non corregge nulla.