code: def verifier_for_task(
      task_type: Optional[TaskTypesEnum] = None,
      adapter: Optional[BaseOptimizationAdapter] = None,
  ):
      adapter = adapter or PipelineAdapter()
      return GraphVerifier(rules_by_task(task_type), adapter)
  
file_path: FEDOT/fedot/core/pipelines/verification.py
imports: from functools import partial
  from inspect import signature
  from typing import Callable, List, Sequence, Optional, Union
  from golem.core.adapter import BaseOptimizationAdapter
  from golem.core.dag.graph import Graph
  from golem.core.dag.graph_verifier import GraphVerifier, VerifierRuleType
  from golem.core.dag.verification_rules import has_no_cycle, has_no_isolated_nodes, has_no_self_cycled_nodes, has_one_root
  from golem.core.optimisers.graph import OptGraph
  from fedot.core.pipelines.adapters import PipelineAdapter
  from fedot.core.pipelines.verification_rules import has_correct_data_connections, has_correct_data_sources, has_correct_operations_for_task, has_final_operation_as_model, has_no_conflicts_after_class_decompose, has_no_conflicts_during_multitask, has_no_conflicts_in_decompose, has_no_conflicts_with_data_flow, has_no_data_flow_conflicts_in_ts_pipeline, has_primary_nodes, only_non_lagged_operations_are_primary, has_correct_location_of_resample
  from fedot.core.repository.tasks import TaskTypesEnum
label_desc: Use image node_id 1 for calling a global function with example usage: verifier_for_task(task_type, adapter) and returns: GraphVerifier