diff --git a/agents-api/agents_api/models/execution/create_execution.py b/agents-api/agents_api/models/execution/create_execution.py index 2b509cda4..832532d6d 100644 --- a/agents-api/agents_api/models/execution/create_execution.py +++ b/agents-api/agents_api/models/execution/create_execution.py @@ -60,7 +60,9 @@ def create_execution( data["metadata"] = data.get("metadata", {}) execution_data = data - if execution_data["output"] is not None and not isinstance(execution_data["output"], dict): + if execution_data["output"] is not None and not isinstance( + execution_data["output"], dict + ): execution_data["output"] = {OUTPUT_UNNEST_KEY: execution_data["output"]} columns, values = cozo_process_mutate_data( diff --git a/agents-api/agents_api/models/execution/get_execution.py b/agents-api/agents_api/models/execution/get_execution.py index 11eb1e107..da76701f4 100644 --- a/agents-api/agents_api/models/execution/get_execution.py +++ b/agents-api/agents_api/models/execution/get_execution.py @@ -32,7 +32,9 @@ one=True, transform=lambda d: { **d, - "output": d["output"][OUTPUT_UNNEST_KEY] if OUTPUT_UNNEST_KEY in d["output"] else d["output"], + "output": d["output"][OUTPUT_UNNEST_KEY] + if OUTPUT_UNNEST_KEY in d["output"] + else d["output"], }, ) @cozo_query