extract documents into files