Add strict evidence service boundary

This commit is contained in:
732642856
2026-07-16 22:41:10 +08:00
parent ed502e3ab2
commit 20fe32fc53
2 changed files with 31 additions and 2 deletions
@@ -13,7 +13,7 @@ ROOT = Path(__file__).resolve().parents[1]
if str(ROOT) not in sys.path:
sys.path.insert(0, str(ROOT))
from mcp_server import _existing_interpretation_source_pack # noqa: E402
from scripts.strict_evidence_service import existing_interpretation_source_pack # noqa: E402
REQUIRED_LAYERS = [
@@ -100,7 +100,7 @@ CANDIDATE_KEYWORDS = [
def build_report() -> dict[str, Any]:
source_pack = _existing_interpretation_source_pack()
source_pack = existing_interpretation_source_pack()
inventory = source_pack.get("interpretation_source_inventory") if isinstance(source_pack, dict) else {}
if not isinstance(inventory, dict):
inventory = {}
+29
View File
@@ -0,0 +1,29 @@
#!/usr/bin/env python3
"""Stable strict-evidence service boundary.
This module is the import target for engine/API code. The current implementation
delegates to the legacy MCP implementation while the large helper stack is being
extracted out of `mcp_server.py`.
"""
from __future__ import annotations
import sys
from pathlib import Path
from typing import Any
ROOT = Path(__file__).resolve().parents[1]
if str(ROOT) not in sys.path:
sys.path.insert(0, str(ROOT))
def collect_strict_evidence(route: str, result: dict[str, Any]) -> dict[str, Any]:
from mcp_server import _collect_strict_evidence
return _collect_strict_evidence(route, result)
def existing_interpretation_source_pack() -> dict[str, Any]:
from mcp_server import _existing_interpretation_source_pack
return _existing_interpretation_source_pack()