feat: grounding CPAM — tags DP/DAS/ANT/COMPL + fuzzy matching CIM-10 + prompt renforcé
Cause racine du Tier C : le LLM inventait des tags ([C83.3], [Antécédents]) car _build_tagged_context() ne taguait que bio/img/trt/actes. Le DP, les DAS, antécédents et complications n'avaient aucun tag citable. - cpam_context: 4 nouveaux types de tags [DP], [DAS-N], [ANT-N], [COMPL-N] - cpam_validation: fuzzy matching — résout les refs CIM-10 nues vers le tag contenant ce code - templates: liste explicite des tags valides, interdiction d'inventer des tags - tests: 18 nouveaux tests (tags, fuzzy match, grounding DAS/DP) Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -39,7 +39,7 @@ from .cpam_context import ( # noqa: F401
|
||||
_build_bio_summary,
|
||||
_check_das_bio_coherence,
|
||||
)
|
||||
from .cpam_validation import _CIM10_CODE_RE, _validate_adversarial as _validate_adversarial, _assess_quality_tier as _assess_quality_tier # noqa: F401
|
||||
from .cpam_validation import _CIM10_CODE_RE, _validate_adversarial as _validate_adversarial, _assess_quality_tier as _assess_quality_tier, _fuzzy_match_ref as _fuzzy_match_ref # noqa: F401
|
||||
|
||||
logger = logging.getLogger(__name__)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user