# Function createStateComparisonVerifier

- createStateComparisonVerifier(
  fields: readonly string[],
  ): (preState: Readonly<GraphState>) => NodeHook

  Creates a state-comparison verification hook. Checks that specified state fields changed after node execution.

  #### Parameters

  - fields: readonly string[]

  #### Returns (preState: Readonly<GraphState>) => NodeHook

  - Defined in packages/nexus-agents/src/orchestration/graph/graph-hooks.ts:141