There is the solution (https://github.com/jsuchal/hashugar) i often use.
opts = Hashugar.new({:a => 1, 'b' => {:c => 2, :d => [3, 4, {:e => 5}]}})
But you also need to do:
opts.b.d.last.e
I do not understand how do you want to name array's getters. As Arup Rakshit sayed: give us yaml example and expected output or behavior.