Extract review-plan, report, quarantine, state, and config handlers into commands/ with shared cli_helpers; remove unused exceptions and duplicate plan summary wrappers. Archive superseded review markdown, sync docs to 517-test baseline, and fix empty series titles when only a quality tag remains. Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com> Co-authored-by: Cursor <cursoragent@cursor.com>
5.8 KiB
5.8 KiB
Changelog
2026-05-21
Functional code simplification
- Removed unused
src/vlm/exceptions.pyand consolidated plan summary helpers (preferred_plan_summaryeverywhere). - Extracted CLI implementations to
cli_helpers.pyandcommands/(review_plan,report,quarantine_cmd,state_cmd,config_cmd);cli.pyis now Click registration and thin delegation. - Moved
textualout of[dev]optional deps (install via[tui]or[dev,tui]). - Archived superseded review/audit markdown under
docs/archive/2026-pre-baseline/. - Fixed series parser empty title when the only title token is a quality tag (e.g.
UHD S01E01.mp4). - Verification:
pytest -q→ 517 passed.
2026-04-07
Review-plan Safety & Validation Hardening
- Made
vlm review-plan --tuia true optional runtime boundary by lazy-loading the Textual UI and guarding Textual imports. - Hardened execution safety so move/rename operations validate both source and destination against
library_root, while unsupported quarantine operations fail per-operation without aborting later work. - Removed silent duplicate-resolution fallback: unresolved
by_qualitygroups and unsupported strategies now surface as explicit manual-review outcomes. - Canonicalized duplicate path matching so duplicate analysis joins stay stable across path-format differences.
- Defined scanner behavior for non-zero
findexits: keep partial stdout with a warning, or return an empty deterministic result if no paths were emitted. - Moved plan loading onto a validated typed
ExecutionPlanboundary in the I/O layer. - Updated repository review artifacts and documentation to reflect the new baseline.
- Verification:
pytest -q→507 passed.
2026-04-02
Schema Validation & Deterministic Planning
- Added runtime validation for
identities.json,analysis.json, andplan.jsonon load/save. - Plan generation now records environment-derived checks in
validation_snapshotmetadata, keeping logical plan output reproducible. - Added targeted regression tests for plan round-trip validation and invalid-schema rejection.
- Verified the affected workflows with
uv run pytest tests/test_io.py tests/test_planner.py.
Logic Optimization & Human-in-the-Loop
-
Human-in-the-Loop Workflow Completion:
- Added
vlm apply-reviewcommand to sync modifications fromplan_manual_review.csvback toplan.json. - Implemented
apply_review_to_planinsrc/vlm/planner.pyto allow manual rejection/modification of high-risk operations via CSV.
- Added
-
Scanner Robustness & Environment Awareness:
- Added proactive
ffprobeavailability check at the start ofvlm scan. - Implemented graceful degradation: if
ffprobeis missing, the scanner automatically falls back to file-only metadata mode with a clear warning, instead of failing per-file.
- Added proactive
-
Parser Enhancements:
- Improved
src/vlm/parser.pyto better handle release group tags ([Group],(Group),Group_Subs). - Added support for hyphenated episode numbering (e.g.,
Name - 01) common in Anime, defaulting to Season 1 with reduced confidence. - Refined release group removal to be more robust against various bracket styles.
- Improved
-
CLI & UX:
vlm review-plannow prints a plan overview plus a structured high-risk operation preview in terminal output.- Added
--preview-limitand--show-allto control review-plan preview verbosity. - Added shared plan rendering helpers so
review-planandexecutereuse the same summary fallback behavior. - Added
vlm apply-reviewto the main CLI group.
2026-02-16
Artifact Path Governance
- Changed default workflow artifact outputs from repository root to
artifacts/:artifacts/inventory.csvartifacts/identities.jsonartifacts/analysis.jsonartifacts/plan.jsonartifacts/plan_manual_review.csv
- Added
workspace_dirto configuration (~/.vlm/config.yaml) to customize default artifact directory. - Stage-A compatibility: when a command uses default input path and only legacy root artifact exists, CLI now prints a migration warning and falls back to the legacy file.
- Added ignore rules for generated artifact directories in
.gitignore(artifacts/,runs/). - Removed temporary process document
ARTIFACTS_REFACTOR_PLAN_2026-02-16.md;CHANGELOG.mdremains the canonical change record.
Refactor Results
-
Modularized CLI command implementations:
- Added
src/vlm/commands/parse.py - Added
src/vlm/commands/enrich.py - Added
src/vlm/commands/execute.py - Refactored
src/vlm/cli.pyto delegateparse,enrich,execute, androllbackto command modules
- Added
-
Unified I/O layer for JSON handling:
- Added
load_json_file,save_json_file,save_analysis_jsoninsrc/vlm/io.py - Updated analyze/enrich paths to use unified I/O entry points
- Added
-
Parser/config consistency improvements:
- Added shared
DEFAULT_VIDEO_EXTENSIONSinsrc/vlm/config.py - Updated
src/vlm/parser.pyto use the shared config constant instead of local hardcoded defaults
- Added shared
-
Execution reliability hardening:
- Updated
src/vlm/executor.pytransaction logging to fail gracefully when~/.vlmis not writable (warn + continue)
- Updated
-
Test stability improvements:
- Standardized test timestamps to timezone-aware UTC (
datetime.now(timezone.utc)) - Added missing
timezoneimports where required
- Standardized test timestamps to timezone-aware UTC (
Verification
- Full test suite passed after refactor:
477 passed
Documentation Sync
- Updated repository documentation set to match the refactor baseline:
- Core docs:
README.md,AGENTS.md,CLAUDE.md,GEMINI.md - Skill docs:
skills/vlm-library-workflow/SKILL.mdand all references underskills/vlm-library-workflow/references/ - Legacy review/plan docs now explicitly marked as historical snapshots and redirected to
CHANGELOG.mdas the current source of truth
- Core docs: