Added YAML reading logic.