Repository navigation
SCRIP-METRIC-003: private local analysis with JSON and offline HTML - #270
andy-zen-dev wants to merge 1 commit into
Conversation
Refs #269. Reuse the deterministic engine, preserve all metric identities, add 22 positive/negative tests and atomic create-only output. Document working commands without corpus, source-text or parity promotion.
|
Exact-head verification completed for
No merge in this authoring run. This PR is independent of #268/#272 and is eligible for its own later fresh exact-head acceptance without waiting for that stack. |
andy-zen-dev
left a comment
There was a problem hiding this comment.
Owner-requested review, exact head 752f3c4.
Two reproduced findings in scriptorium/analyze.py (blob b99886b5ca46e175efc4c70b39b7b81408b12cd3):
- P1: main() calls Path.read_bytes()/read_text() before checking file type or size. A local FIFO with no writer blocks indefinitely; reproduced in a child process terminated after a 2-second deadline. Reject special files before blocking reads, bound manuscript/dictionary input, and test the actual CLI.
- P2: parser.error(str(exc)) discloses absolute input/output paths. Reproduced on an existing report; the old report was preserved, but stderr exposed its full path. Return actionable path-free errors.
The analyzer/output separation, unchanged metric engine, null handling and create-only writer are sound in the inspected scope. This is COMMENT-only solo-maintainer review, not GitHub self-approval or merge acceptance. The owner now requests one new integration PR against master; carry the existing implementation and these fixes into that delivery path, retaining #269 and this PR as provenance until the integration is accepted. No scientific gate or formula change is requested.
|
Superseded delivery path: #276, per the owner's 2026-10-18 request for one new PR covering remaining ready issues. The analyzer was adopted through #274 and retained in #276 with the FIFO/non-regular input and private-error fixes plus their regressions; no parallel reimplementation. #276 at This older head |
|
Superseded by merged #276 (merge commit Closing this stale Draft PR without deleting its branch, force-pushing or claiming that its own old checks now pass. The canonical follow-up belongs to the current master / new feature issues. |
Closes #269.
Product outcome
python -m scriptorium.analyze manuscript.txt --output analysis.jsonpython -m scriptorium.analyze manuscript.txt --format html --output report.htmlUses the existing deterministic engine directly: all 29 rows, units, profiles, dictionary identity and raw/normalized hashes. Optional UTF-8 dictionary/profile pairing; explicit short-input and unavailable-value limitations; no manuscript/dictionary contents or external services. Accessible offline HTML includes all metric families and profile details. Output publication is atomic and create-only, including existing files, aliases and dangling symlinks. No metric formulas or scientific gates change.
Verification at 752f3c4
Scope / integration
Independent of #268; only an additive README section overlaps that PR and it is at a different location. Adopts and hardens the pending local-analysis handoff rather than maintaining a parallel implementation. No Pages activation or package-registry publication. Later fresh acceptance is required before merge; this turn authors the change.