you could streamline this code by just creating the whole hash in the first line.  = { "network"=> { name => { "addresses" => ...