M20: stabilize production acceptance
MobilityOps acceptance / backend (push) Canceled after 0s
MobilityOps acceptance / frontend (push) Canceled after 0s

This commit is contained in:
NuklearRabbit
2026-08-10 13:02:03 +02:00
parent 5d7a5e7359
commit f715085f65
4 changed files with 11 additions and 9 deletions
+3 -3
View File
@@ -53,15 +53,15 @@ def _deduplicate_sources(sources: list[SourceCard]) -> list[SourceCard]:
RAGcore document/version UUIDs change across uploads, so they are not useful
deduplication keys. Human-visible citation identity is the normalized title,
section and excerpt.
section. Chunks from the same unsectioned document collapse into one card; distinct
named sections remain independently citable.
"""
seen: set[tuple[str, str, str]] = set()
seen: set[tuple[str, str]] = set()
unique: list[SourceCard] = []
for source in sources:
key = (
source.title.strip().casefold(),
source.section.strip().casefold(),
" ".join(source.excerpt.split()).casefold(),
)
if key in seen:
continue
+1 -1
View File
@@ -297,7 +297,7 @@ def test_ragcore_sources_deduplicate_reuploaded_versions_and_cap_cards(monkeypat
"title": "Damage procedure" if index < 2 else f"Procedure {index}",
"section": "Return",
"excerpt": (
"Record visible damage before release."
f"Record visible damage before release, chunk {index}."
if index < 2
else f"Unique procedure evidence {index}."
),