updated metadata parsing for results