perago.completed_result#
- perago.completed_result(output)[源代码]#
Build a completed worker attempt result.
The helper keeps success result construction consistent across workspace and workspace-free attempts after their output payload has already been validated by the execution layer.
- Parameters:
- outputdict of str to Any
Validated task output payload. Workspace tasks include both
workspaceandresultkeys; workspace-free tasks include onlyresult.
- Returns:
- RuntimeTaskResult
Result with status
"COMPLETED"and the suppliedoutput.
- 参数:
- 返回类型:
参见
RuntimeTaskResultValidated result model.
build_workspace_task_outputBuild a completed workspace task output.
build_workspace_free_task_outputBuild a completed workspace-free task output.
Examples
>>> completed_result({"result": {"valid": True}}).status 'COMPLETED'