exanding use of corpus mapper
fixed sorting for corpus terms and documents metadata
trying to avoid adding corpus id to documents
adjusting documents metadata