fix: PR8.1 — status healthy init + object_units rebuild + version bump

- status.py: healthy=True init before if exists: (was UnboundLocalError
  when vector DB doesn't exist)
- manifest.py: RETRIEVAL_POLICY_VERSION l4.body.v1 → l4.body.v2 to
  trigger object_units rebuild with PR7 fix (unit_id fallback)
- Object_units corrected from 20→311 after rebuild (was INSERT OR
  REPLACE overwrite from old empty unit_id)
- Coverage parity: 20 papers have body_units = 20 have object_units 
  (body=811 chunks, object=311 chunks, expected difference due to
   section-split vs 1:1 caption structure)
- Unit tests: 97 pass (subset)
This commit is contained in:
LLLin000 2026-07-06 20:08:51 +08:00
parent 0dfbf2a68d
commit 6afcdc1830
2 changed files with 2 additions and 1 deletions

View file

@ -48,6 +48,7 @@ def get_embed_status(vault: Path) -> dict:
body_chunk_count = 0
error = ""
corrupted = False
healthy = True
if exists:
# Count paperforge_fulltext
try:

View file

@ -12,7 +12,7 @@ from hashlib import sha256
from typing import Any
import json
RETRIEVAL_POLICY_VERSION = "l4.body.v1"
RETRIEVAL_POLICY_VERSION = "l4.body.v2"
def compute_body_units_hash(units: list[dict]) -> str: