Skip to content
Prev Previous commit
Next Next commit
Update giskard/rag/report.py
  • Loading branch information
henchaves authored Oct 24, 2024
commit 8a7a414f6ed54052fe2dc4eb316ab6bec3b5b021
6 changes: 5 additions & 1 deletion giskard/rag/report.py
Original file line number Diff line number Diff line change
Expand Up @@ -165,7 +165,11 @@ def save(self, folder_path: str):
json.dump(self._knowledge_base.get_savable_data(), f, ensure_ascii=False)

with open(path / "agent_answer.json", "w", encoding="utf-8") as f:
json.dump([{"message": output.message, "documents": output.documents} for output in self._model_outputs], f, ensure_ascii=False)
json.dump(
[{"message": output.message, "documents": output.documents} for output in self._model_outputs],
f,
ensure_ascii=False
)

if self._metrics_results is not None:
with open(path / "metrics_results.json", "w", encoding="utf-8") as f:
Expand Down
Loading