diff --git a/src/backend/langflow/processing/process.py b/src/backend/langflow/processing/process.py index 03587cd29..766027bdf 100644 --- a/src/backend/langflow/processing/process.py +++ b/src/backend/langflow/processing/process.py @@ -136,7 +136,12 @@ async def generate_result(langchain_object: Union[Chain, VectorStore], inputs: d elif isinstance(inputs, dict): call_func = langchain_object.ainvoke result = await call_func(inputs) - result = result.content if hasattr(result, "content") else result + if isinstance(result, list): + result = [r.content if hasattr(r, "content") else r for r in result] + elif hasattr(result, "content"): + result = result.content + else: + result = result elif hasattr(langchain_object, "run") and isinstance(langchain_object, CustomComponent): result = langchain_object.run(inputs)