From 14b465f076e532aae655248fb3e25daba09849e5 Mon Sep 17 00:00:00 2001 From: Daniel Chalef <131175+danielchalef@users.noreply.github.com> Date: Fri, 26 Sep 2025 14:15:54 -0700 Subject: [PATCH] document llm dedupe guardrails --- graphiti_core/utils/maintenance/node_operations.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/graphiti_core/utils/maintenance/node_operations.py b/graphiti_core/utils/maintenance/node_operations.py index 122dbc00..2d87d31b 100644 --- a/graphiti_core/utils/maintenance/node_operations.py +++ b/graphiti_core/utils/maintenance/node_operations.py @@ -241,7 +241,11 @@ async def _resolve_with_llm( previous_episodes: list[EpisodicNode] | None, entity_types: dict[str, type[BaseModel]] | None, ) -> None: - """Escalate unresolved nodes to the dedupe prompt so the LLM can select or reject duplicates.""" + """Escalate unresolved nodes to the dedupe prompt so the LLM can select or reject duplicates. + + The guardrails below defensively ignore malformed or duplicate LLM responses so the + ingestion workflow remains deterministic even when the model misbehaves. + """ if not state.unresolved_indices: return