Sequence class implemented for NBest