I want convert string:
"---
contract_field_values:
- |
  --- !NAME_1/hash:ActiveSupport::HashWithIndifferentAccess
  '164': abvgde
- |
  --- !NAME_1/hash:ActiveSupport::HashWithIndifferentAccess
  '164': abvg
delivery_method:
- 0
- 1"

to NAME_1 Hash:
{"contract_field_values"=> [{"164"=>"abvgde", {"164"=>"abvg"}], "delivery_method"=>[0, 1]}