altair823
c9e05941c5
feat(cli): activate per-page PDF OCR progress printer + test(app): ingest_progress emit verify + spec(pdf-ocr): align §4.6.1 literal with option_A (ms/chars)
Step 8 (Group H) of v0.20.0 sub-item 1 (scanned PDF OCR) plan +
Step 7 reviewer concern fix (spec literal deviation).
H1 — kebab-cli/src/progress.rs printer activation:
- 구 no-op stub `IngestEvent::PdfOcr* { .. } => {}` (Step 6 placeholder)
를 사람-친화 stderr line printer 로 활성화.
- spec §4.6.1 line 1085-1086 wording 그대로:
- PdfOcrStarted → ` 📷 OCR page {page}...`
- PdfOcrFinished (skipped=false) → ` ✓ OCR page {page} ({chars} chars, {ms}ms via {ocr_engine})`
- PdfOcrFinished (skipped=true) → ` ⊘ OCR page {page} skipped (no DCTDecode or engine fail, {ms}ms)` (M-4 의 skipped field carry 활용)
- `!quiet` gate 정합 (AssetStarted/Finished pattern mirror).
H2 — crates/kebab-app/tests/ingest_progress.rs 의 새 test:
- pdf_ocr_progress_emits_started_finished_events (real Ollama 의존, `#[ignore]`).
- F1 fixture (scanned_page1.pdf) ingest 시 pdf_ocr_started + pdf_ocr_finished
event 가 emit 됨을 verify. Started count == Finished count invariant.
- Manual invoke: `KEBAB_PDF_OCR_ENABLED=true cargo test -p kebab-app --test
ingest_progress --ignored`.
- mock OcrEngine inject path 부재 (Step 6 의 eager build), Step 9 I5 의
ocr_e2e pattern (real Ollama + `#[ignore]`) 와 동일.
Step 7 reviewer concern fix — spec §4.6.1 literal:
- line 1076-1077 의 `ocr_ms` / `ocr_chars` literal 을 wire schema 의 실제
field name `ms` / `chars` (option_A, Rust serde 와 정합) 로 갱신.
- line 1087 의 printer wording 도 `{ocr_chars}` / `{ocr_ms}` → `{chars}` / `{ms}`.
- line 1556 의 rationale 참조 `pdf_ocr_finished.ocr_ms` → `.ms`.
- `skipped` field 도 명시 (Step 6 reviewer M-4 결과).
spec: docs/superpowers/specs/2026-05-27-pdf-scanned-ocr-spec.md (§4.6.1)
plan: docs/superpowers/plans/2026-05-27-pdf-scanned-ocr-plan.md (Step 8 H1+H2)
prior: 4c5ccd5 (Step 7 wire schema) — Step 7 reviewer concern 1 의 fix
contract: §9 (additive minor wire bump — Step 7 commit 에서 완료)
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-27 09:18:49 +00:00
..
2026-05-26 15:00:59 +00:00
2026-05-04 14:47:28 +09:00
2026-05-04 17:27:06 +00:00
2026-05-04 16:11:17 +00:00
2026-05-05 11:21:42 +00:00
2026-05-07 19:11:47 +09:00
2026-05-07 10:58:24 +09:00
2026-05-07 14:44:09 +09:00
2026-05-07 17:29:30 +09:00
2026-05-08 18:00:10 +09:00
2026-05-09 14:10:08 +09:00
2026-05-09 17:36:51 +09:00
2026-05-10 00:45:29 +09:00
2026-05-10 03:26:40 +09:00
2026-05-10 12:05:31 +09:00
2026-05-10 17:40:47 +09:00
2026-05-10 22:05:09 +09:00
2026-05-10 22:59:03 +09:00
2026-05-10 18:55:05 +09:00
2026-05-10 20:05:27 +09:00
2026-05-20 13:24:16 +00:00
2026-05-23 00:43:31 +00:00
2026-05-26 05:18:08 +00:00
2026-05-25 06:22:08 +00:00
2026-05-26 23:34:17 +00:00
2026-05-26 06:52:04 +00:00
2026-05-26 15:00:59 +00:00
2026-05-26 09:12:21 +00:00
2026-05-26 12:19:32 +00:00
2026-05-27 09:18:49 +00:00