fix: ensure fact_embedding is removed from attributes in format_fact_… (#611)

fix: ensure fact_embedding is removed from attributes in format_fact_result

This ensures that fact_embedding is completely cleaned from the result,
both from the main level and from the attributes dictionary.
This commit is contained in:
robrichardson13 2025-06-23 22:01:26 -07:00 committed by GitHub
parent 25dfc10662
commit b8e6762cb2
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -628,12 +628,14 @@ def format_fact_result(edge: EntityEdge) -> dict[str, Any]:
Returns:
A dictionary representation of the edge with serialized dates and excluded embeddings
"""
return edge.model_dump(
result = edge.model_dump(
mode='json',
exclude={
'fact_embedding',
},
)
result.get('attributes', {}).pop('fact_embedding', None)
return result
# Dictionary to store queues for each group_id