Merge Graphs¶
merge_graphs
¶
Merge_graphs workflow action.
Merges multiple graphs into a probabilistic DAG (PDG). The action is stateless, so validation and execution delegate to module-level helpers and each step stays within the module and method limits.
Classes:
-
MergeGraphsAction–Merge multiple graphs into a probabilistic DAG.
MergeGraphsAction
¶
Merge multiple graphs into a probabilistic DAG.
Attributes:
-
action_name–Action name as used in workflow definitions.
-
pattern–Workflow action pattern used for cache validation.
Methods:
-
run–Execute graph merging to produce a PDG.
-
validate–Validate merge_graphs parameters before execution.
run
¶
run(
parameters: Dict[str, Any],
mode: str,
context: Optional[Any] = None,
logger: Optional[Any] = None,
) -> ActionResult
Execute graph merging to produce a PDG.
Aggregation mode merges graphs from pre-scanned cache entries passed via '_aggregation_entries'; direct mode merges graphs read from the 'input' file paths (.graphml or .db files).
Parameters:
-
(parameters¶Dict[str, Any]) –Action parameter values.
-
(mode¶str) –Execution mode ('dry-run', 'run' or 'compare').
-
(context¶Optional[Any], default:None) –Workflow context for optimisation.
-
(logger¶Optional[Any], default:None) –Logger for reporting.
Returns:
-
ActionResult–Tuple of (status, metadata, objects).
Raises:
-
ActionExecutionError–If execution fails.
validate
¶
validate(parameters: Dict[str, Any]) -> None
Validate merge_graphs parameters before execution.
Parameters:
-
(parameters¶Dict[str, Any]) –Action parameter values.
Raises:
-
ValueError–If a parameter is missing or invalid. The provider converts this to an ActionValidationError.