refactor(ingest): drop obsolete queue_halachot flag + dead imports (FU-1 review)

pipeline always queues both extraction kinds (INV-ING3); remove the
now-meaningless queue_halachot param from ingest_internal_decision and
migrate_from_style_corpus. Also trim chunker/extractor/rerank from the
precedent_library module-top import (chunking/extraction moved to ingest.py).

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-05-30 19:26:53 +00:00
parent 5104db8f4e
commit 3c431403f6
2 changed files with 2 additions and 4 deletions

View File

@@ -111,7 +111,6 @@ async def ingest_internal_decision(
file_path: str | Path | None = None, file_path: str | Path | None = None,
text: str | None = None, text: str | None = None,
document_id: UUID | None = None, document_id: UUID | None = None,
queue_halachot: bool = True, # retained for signature compat; pipeline always queues
proceeding_type: str = "", proceeding_type: str = "",
) -> dict: ) -> dict:
"""Ingest one appeals-committee decision. Thin wrapper over the canonical pipeline.""" """Ingest one appeals-committee decision. Thin wrapper over the canonical pipeline."""
@@ -130,7 +129,7 @@ async def ingest_internal_decision(
"chunks": out["chunks"], "halachot_pending": True} "chunks": out["chunks"], "halachot_pending": True}
async def migrate_from_style_corpus(dry_run: bool = False, queue_halachot: bool = True) -> dict: async def migrate_from_style_corpus(dry_run: bool = False) -> dict:
"""Re-index all style_corpus entries as searchable internal committee decisions. """Re-index all style_corpus entries as searchable internal committee decisions.
Does NOT delete style_corpus rows — they remain for style analysis. Does NOT delete style_corpus rows — they remain for style analysis.
@@ -188,7 +187,6 @@ async def migrate_from_style_corpus(dry_run: bool = False, queue_halachot: bool
appeal_subtype=subtype, appeal_subtype=subtype,
subject_tags=subject_tags, subject_tags=subject_tags,
text=row["full_text"], text=row["full_text"],
queue_halachot=queue_halachot,
) )
results["ingested"] += 1 results["ingested"] += 1
logger.info("Migrated style_corpus entry: %s", case_number) logger.info("Migrated style_corpus entry: %s", case_number)

View File

@@ -20,7 +20,7 @@ from typing import Awaitable, Callable
from uuid import UUID from uuid import UUID
from legal_mcp import config from legal_mcp import config
from legal_mcp.services import chunker, db, embeddings, extractor, hybrid_search, ingest, rerank # noqa: F401 from legal_mcp.services import db, embeddings, hybrid_search, ingest # noqa: F401
# Note: halacha_extractor and precedent_metadata_extractor are NOT imported # Note: halacha_extractor and precedent_metadata_extractor are NOT imported
# at module load. They are imported lazily inside the dedicated re-extract # at module load. They are imported lazily inside the dedicated re-extract