Update EdgeDTO to support extended provenance values and modify explanation building in retriever.py to accommodate new provenance types. This enhances the handling of edge data for improved accuracy in retrieval processes.

This commit is contained in:
Lars committed 2026-01-11 17:54:33 +01:00
1 parent 2445f7cb2b
commit 1df89205ac
2 files changed
+10 -2

No files matched your search

+8 -1
View File
@@ -46,7 +46,14 @@ class EdgeDTO(BaseModel):
target: str
weight: float
direction: Literal["out", "in", "undirected"] = "out"
provenance: Optional[Literal["explicit", "rule", "smart", "structure"]] = "explicit"
# WP-24c v4.5.3: Erweiterte Provenance-Werte für Chunk-Aware Edges
# Unterstützt alle tatsächlich verwendeten Provenance-Typen im System
provenance: Optional[Literal[
"explicit", "rule", "smart", "structure",
"explicit:callout", "explicit:wikilink", "explicit:note_zone", "explicit:note_scope",
"inline:rel", "callout:edge", "semantic_ai", "structure:belongs_to", "structure:order",
"derived:backlink", "edge_defaults", "global_pool"
]] = "explicit"
confidence: float = 1.0
target_section: Optional[str] = None