Skip to content

Commit adfe9f9

Browse files
author
Your Name
committed
[JSON FIX]
1 parent 12aae2e commit adfe9f9

6 files changed

+18
-15
lines changed

agent_workspace/Medical-Summarization-Agent_state.json

+8-8
Large diffs are not rendered by default.

logs/medinsight_pro_history_time:2024-09-25_17-36-19.json

+1
Large diffs are not rendered by default.

logs/medinsight_pro_history_time:2024-09-25_17-49-41.json

+1
Large diffs are not rendered by default.

logs/medinsight_pro_history_time:2024-09-25_17-52-53.json

+1
Large diffs are not rendered by default.

medinsight/agent.py

+6-6
Original file line numberDiff line numberDiff line change
@@ -183,10 +183,10 @@ def run(self, task: str, *args, **kwargs):
183183

184184
# Summarize data with GPT-4
185185
# combined_summary_input = f"PubMed Data: {pubmed_data}\nSemantic Scholar Data: {semantic_scholar_data}"
186-
if pubmed_data:
187-
combined_summary_input = pubmed_data
188-
else:
189-
combined_summary_input = semantic_scholar_data
186+
# if pubmed_data:
187+
combined_summary_input = pubmed_data
188+
# else:
189+
# combined_summary_input = semantic_scholar_data
190190

191191
combined_summary = self.agent.run(combined_summary_input)
192192
logger.info(f"Summarization completed for task: {task}")
@@ -214,7 +214,7 @@ def run(self, task: str, *args, **kwargs):
214214
# return combined_summary
215215

216216
if self.return_json:
217-
return self.metadata_log.model_dump_json()
217+
return self.metadata_log.model_dump_json(indent=4)
218218

219219
else:
220220
return combined_summary
@@ -230,6 +230,6 @@ def save_metadata_log(self):
230230
log_file = f"medinsight_pro_history_time:{time_stamp}.json"
231231

232232
with open(log_file, "w") as file:
233-
json.dump(self.metadata_log.model_dump(), file)
233+
json.dump(self.metadata_log.model_dump_json(indent=4), file)
234234

235235
logger.info(f"Metadata log saved to {log_file}")

pyproject.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ build-backend = "poetry.core.masonry.api"
44

55
[tool.poetry]
66
name = "medinsight"
7-
version = "0.0.5"
7+
version = "0.0.6"
88
description = "MedInsight - Swarms - "
99
license = "MIT"
1010
authors = ["Kye Gomez <[email protected]>"]

0 commit comments

Comments
 (0)